forked from DigitalBox98/SimpleExtJSApp
-
Notifications
You must be signed in to change notification settings - Fork 40
/
Makefile
109 lines (90 loc) · 4.51 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
SPK_NAME = rr-manager
SPK_VERS = 2.0
SPK_REV = 74
SPK_ICON = src/rr-manager.png
DSM_UI_DIR = app
DSM_UI_CONFIG = src/app/config
DSM_APP_NAME = SYNOCOMMUNITY.RRManager.AppInstance
PYTHON_PACKAGE = python311
SPK_DEPENDS = "python311>=3.11.5-8"
MAINTAINER = T-REX-XP
DESCRIPTION = RR Manager is a Redpill Recovery DSM application aimed to provide the ability to configure/update RR without booting to RR recovery. This package is for experienced users.
STARTABLE = no
DISPLAY_NAME = RR Manager
HOMEPAGE = https://github.com/T-REX-XP/RRManager
CONF_DIR = src/conf
SYSTEM_GROUP = http
SERVICE_USER = auto
SERVICE_SETUP = src/service-setup.sh
SSS_SCRIPT = src/dsm-control.sh
COPY_TARGET = nop
POST_STRIP_TARGET = rr-manager_extra_install
include ../../mk/spksrc.common.mk
include ../../mk/spksrc.directories.mk
SERVICE_WIZARD_SHARE = wizard_download_dir
WIZARDS_DIR = $(WORK_DIR)/generated-wizards
WIZARDS = install_uifile upgrade_uifile
SUPPORTED_LANGUAGES = fre
wizards: generated-wizards
include ../../mk/spksrc.spk.mk
.PHONY: generated-wizards
generated-wizards:
@mkdir -p $(WIZARDS_DIR)
@for template in $(WIZARDS); do \
for suffix in '' $(patsubst %,_%,$(SUPPORTED_LANGUAGES)) ; do \
{\
echo "#!/bin/sh";\
echo "";\
cat src/wizard_templates/uifile_vars$${suffix} | sed -e 's/\\/\\\\/g' -e 's/\"/\\\"/g' -e 's/^\([^=]*\)=\\"\(.*\)\\"$$/\1="\2"/g';\
echo "";\
cat "$(SPKSRC_MK)spksrc.service.installer.functions";\
echo "";\
cat src/wizard_templates/shared_uifile_setup.sh;\
echo "";\
cat src/wizard_templates/$${template}.sh;\
}>$(WIZARDS_DIR)/$${template}$${suffix}.sh;\
done;\
done
.PHONY: rr-manager_extra_install
rr-manager_extra_install:
install -m 755 -d $(STAGING_DIR)/share $(STAGING_DIR)/var
install -m 755 -d $(STAGING_DIR)/share/wheelhouse/
install -m 644 src/requirements.txt $(STAGING_DIR)/share/wheelhouse/requirements.txt
install -m 755 -d $(STAGING_DIR)/app/
install -m 755 -d $(STAGING_DIR)/app/libs/
install -m 755 -d $(STAGING_DIR)/app/scripts/
install -m 755 -d $(STAGING_DIR)/app/images/
install -m 755 -d $(STAGING_DIR)/app/images/1x
install -m 755 src/scripts/checkUpdateStatus.cgi $(STAGING_DIR)/app/scripts/checkUpdateStatus.cgi
install -m 755 src/scripts/getAddons.cgi $(STAGING_DIR)/app/scripts/getAddons.cgi
install -m 755 src/scripts/getAvailableUpdates.cgi $(STAGING_DIR)/app/scripts/getAvailableUpdates.cgi
install -m 755 src/scripts/getConfig.cgi $(STAGING_DIR)/app/scripts/getConfig.cgi
install -m 755 src/scripts/getModules.cgi $(STAGING_DIR)/app/scripts/getModules.cgi
install -m 755 src/scripts/getNetworkInfo.cgi $(STAGING_DIR)/app/scripts/getNetworkInfo.cgi
install -m 755 src/scripts/getRrReleaseInfo.cgi $(STAGING_DIR)/app/scripts/getRrReleaseInfo.cgi
install -m 755 src/scripts/readUpdateFile.cgi $(STAGING_DIR)/app/scripts/readUpdateFile.cgi
install -m 755 src/scripts/uploadConfigFile.cgi $(STAGING_DIR)/app/scripts/uploadConfigFile.cgi
install -m 755 src/scripts/uploadUpdateFileInfo.cgi $(STAGING_DIR)/app/scripts/uploadUpdateFileInfo.cgi
install -m 644 src/app/alias.syno-app-portal.RRM.conf $(STAGING_DIR)/app/alias.syno-app-portal.RRM.conf
install -m 644 src/app/config $(STAGING_DIR)/app/config
install -m 755 src/app/config.txt $(STAGING_DIR)/app/config.txt
install -m 644 src/app/helptoc.conf $(STAGING_DIR)/app/helptoc.conf
install -m 644 src/app/index.conf $(STAGING_DIR)/app/index.conf
install -m 755 src/app/install.sh $(STAGING_DIR)/app/install.sh
install -m 644 src/app/rr-manager.js $(STAGING_DIR)/app/rr-manager.js
install -m 644 src/app/rr-manager.widget.js $(STAGING_DIR)/app/rr-manager.widget.js
install -m 755 src/app/style.css $(STAGING_DIR)/app/style.css
install -m 755 src/images/1x/cate_icn_addons.png $(STAGING_DIR)/app/images/1x/cate_icn_addons.png
install -m 755 src/images/1x/cate_icn_overview.png $(STAGING_DIR)/app/images/1x/cate_icn_overview.png
install -m 755 src/images/1x/cate_icn_setting.png $(STAGING_DIR)/app/images/1x/cate_icn_setting.png
install -m 755 src/app/tasks.sql $(STAGING_DIR)/app/tasks.sql
install -m 755 -d $(STAGING_DIR)/app/help
for language in enu fre; do \
install -m 755 -d $(STAGING_DIR)/app/help/$${language}; \
install -m 644 src/app/help/$${language}/simpleapp_index.html $(STAGING_DIR)/app/help/$${language}/simpleapp_index.html; \
done
install -m 755 -d $(STAGING_DIR)/app/texts
for language in enu rus chs cht krn; do \
install -m 755 -d $(STAGING_DIR)/app/texts/$${language}; \
install -m 644 src/app/texts/$${language}/strings $(STAGING_DIR)/app/texts/$${language}/strings; \
done