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