Contents of /smage/trunk/core/mcore-tools/mcore-tools-0.1_svn2792-r2.smage2
Parent Directory | Revision Log
Revision 9047 -
(show annotations)
(download)
Fri Jun 10 10:52:21 2016 UTC (8 years, 3 months ago) by niro
File size: 2934 byte(s)
Fri Jun 10 10:52:21 2016 UTC (8 years, 3 months ago) by niro
File size: 2934 byte(s)
-fixed user specific installation targets like /usr/share/factory/home/mcore/.xinitrc
1 | # $Id$ |
2 | |
3 | PNAME="mcore-tools" |
4 | PVER="0.1_svn2792" |
5 | PBUILD="r2" |
6 | |
7 | SPLIT_PACKAGES="mcore-tools-common mcore-tools mcore-controld" |
8 | |
9 | PCAT="app-mage" |
10 | HOMEPAGE="http://www.magellan-linux.net/" |
11 | |
12 | COMMON_DEPEND=">= net-misc/sslsvd-1 |
13 | >= net-misc/nssl-005 |
14 | >= sys-apps/hwinfo-20 |
15 | >= x11-libs/libX11-1.6" |
16 | |
17 | CONTROLD_DEPEND="${COMMON_DEPEND} |
18 | >= app-text/xmlstarlet-1.6 |
19 | >= x11-base/xvfb-1.18" |
20 | |
21 | # storefront-cron requires xfvb-run -> xorg-server-dev |
22 | # mcore-controld requires xml -> xmlstartlet |
23 | |
24 | SDEPEND="${COMMON_DEPEND} |
25 | ${CONTROL_DEPEND} |
26 | >= dev-util/pkgconfig-0.25 |
27 | >= x11-libs/libX11-dev-1.6 |
28 | >= x11-proto/xproto-7" |
29 | |
30 | SRCFILE="${PNAME}-${PVER}.tar.bz2" |
31 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
32 | |
33 | sminclude systemd |
34 | |
35 | SRC_URI=( mirror://${PNAME}/${SRCFILE} ) |
36 | |
37 | split_info_mcore-tools-common() |
38 | { |
39 | DESCRIPTION="mcore common files." |
40 | DEPEND="" |
41 | } |
42 | |
43 | split_info_mcore-tools() |
44 | { |
45 | DESCRIPTION="mcore client daemon." |
46 | DEPEND="${COMMON_DEPEND} |
47 | == app-mage/mcore-tools-common-${PVER}" |
48 | } |
49 | |
50 | split_info_mcore-controld() |
51 | { |
52 | DESCRIPTION="mcore control daemon." |
53 | DEPEND="${CONTROLD_DEPEND} |
54 | == app-mage/mcore-tools-common-${PVER} |
55 | == app-mage/mcore-tools-${PVER}" |
56 | } |
57 | |
58 | src_prepare() |
59 | { |
60 | munpack ${SRCFILE} || die |
61 | cd ${SRCDIR} |
62 | |
63 | # use package version and build |
64 | echo "${PVER}-${PBUILD}" > VERSION || die |
65 | } |
66 | |
67 | src_compile() |
68 | { |
69 | cd ${SRCDIR} |
70 | mmake \ |
71 | MCORE_UNPRIV_USER=station \ |
72 | MCORE_DISTRIBUTION=ALX \ |
73 | MCORE_DEFAULT_HOSTNAME=alx-unconfigured \ |
74 | MCORE_DEFAULT_DOMAIN=dom-aka-nt.intern \ |
75 | SYSTEM_ICAROOT=/opt/Citrix/ICAClient \ |
76 | PNABROWSE_CITRIX_BROWSER=ica.dom-aka-nt.intern \ |
77 | PNABROWSE_SERVER_EXCLUDE=ESA-TS-CLEAN \ |
78 | DEFAULT_STOREFRONT_STORE="https://storefront.dom-aka-nt.intern/Citrix/ALX/PNAgent/config.xml" \ |
79 | STOREFRONT_ADDSTORE_REQUIRED=0 \ |
80 | STOREFRONT_SUBSCRIBE_APP=0 \ |
81 | MCORE_CONTROL_SERVER="alx-control.dom-aka-nt.intern" \ |
82 | MCORE_SQL_HOST="localhost" \ |
83 | MCORE_SQL_DB="mcore" \ |
84 | MCORE_SQL_USER="alx_install" \ |
85 | MCORE_SQL_PASS="@lx" \ |
86 | || die |
87 | } |
88 | |
89 | src_install_mcore-tools-common() |
90 | { |
91 | cd ${SRCDIR} |
92 | make MCORE_UNPRIV_USER=station DESTDIR=${BINDIR} install-common || die |
93 | |
94 | # needed directory |
95 | mkeepdir /var/lib/mcored || die |
96 | } |
97 | |
98 | src_install_mcore-tools() |
99 | { |
100 | cd ${SRCDIR} |
101 | make MCORE_UNPRIV_USER=station DESTDIR=${BINDIR} install-client || die |
102 | } |
103 | |
104 | src_install_mcore-controld() |
105 | { |
106 | cd ${SRCDIR} |
107 | make MCORE_UNPRIV_USER=station DESTDIR=${BINDIR} install-control || die |
108 | } |
109 | |
110 | preinstall_mcore-tools() |
111 | { |
112 | museradd -o "-g users -d /home/station -s /bin/bash" station |
113 | } |
114 | |
115 | postinstall_mcore-tools() |
116 | { |
117 | mstartunit mcored |
118 | mstartunit mcore-register-client |
119 | mstartunit mcore-request-configuration |
120 | } |
121 | |
122 | postremove_mcore-tools() |
123 | { |
124 | mstopunit mcored |
125 | mstopunit mcore-register-client |
126 | mstopunit mcore-request-configuration |
127 | } |
128 | |
129 | postinstall_mcore-controld() |
130 | { |
131 | # remove mcored |
132 | mstopunit mcored |
133 | mstopunit mcore-register-client |
134 | mstopunit mcore-request-configuration |
135 | |
136 | # start mcore-controld |
137 | mstartunit mcore-controld |
138 | } |
139 | |
140 | postremove_mcore-controld() |
141 | { |
142 | mstopunit mcore-controld |
143 | } |