Magellan Linux

Contents of /smage/branches/alx-0_6_0/core/alxconfig-ng/alxconfig-ng-0.6.11-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 7982 - (show annotations) (download)
Thu Dec 10 09:45:13 2015 UTC (8 years, 4 months ago) by niro
File size: 2434 byte(s)
auto added: ver bump to 0.6.11-r1
1 # $Id$
2
3 PNAME="alxconfig-ng"
4 PVER="0.6.11"
5 PBUILD="r1"
6
7 SPLIT_PACKAGES="alxconfig-ng-dhcp-tools alxconfig-ng"
8
9 PCATEGORIE="app-alx"
10 HOMEPAGE="http://www.magellan-linux.net"
11
12 ALXCONFIG_DEPEND=">= sys-apps/mage-release-0
13 >= app-text/xmlstarlet-1.1
14 >= dev-db/mysql-5.1
15 >= sys-apps/hwinfo-18"
16
17 SDEPEND="${ALXCONFIG_DEPEND}"
18
19 SRCFILE="${PNAME}-${PVER/_/-}.tar.bz2"
20 SRCDIR="${BUILDDIR}/${PNAME}-${PVER/_/-}"
21
22 REMOVE_DEPRECATED_MAGE_TARGETS=1
23 sminclude mtools alx
24
25 SRC_URI=( mirror://${PNAME}/${SRCFILE} )
26
27 split_info_alxconfig-ng-dhcp-tools()
28 {
29 DESCRIPTION="alxconfig-ng dhcp configuration fixes."
30 PCATEGORIE="app-alx"
31 DEPEND=">= sys-apps/mage-release-0"
32 }
33
34 split_info_alxconfig-ng()
35 {
36 DESCRIPTION="alxconfig-ng, configures alx clients via mysql."
37 PCATEGORIE="app-alx"
38 DEPEND="${ALXCONFIG_DEPEND}
39 == app-alx/alxconfig-ng-dhcp-tools-${PVER}"
40
41 preinstall()
42 {
43 add_conf_prot_mask /etc/rc.d /etc/alxconfig-ng/skel \
44 /etc/alxconfig-ng/ica-sessions/icons \
45 /etc/conf.d/hwsetup
46
47 add_conf_prot_ignore /etc/alxconfig-ng/config.rc
48 add_conf_prot_ignore /etc/alxconfig-ng/storefront.rc
49 }
50
51 postinstall()
52 {
53 # install user station if needed (uucp is needed to access serial ports [ica-mappings])
54 ${MLIBDIR}/museradd -o "-g users -G audio,video,uucp -d /home/station -s /bin/bash" station
55 [ ! -d ${MROOT}/home/station ] && install -o station -g users -d ${MROOT}/home/station
56
57 # setup runlevels
58 # but never start the services!
59 MAGE_BOOTSTRAP=true mstartservice alxsettings
60 MAGE_BOOTSTRAP=true mstartservice alxsetstate
61
62 # not needed with alxconfig >= 0.6.0
63 local i
64 for i in skel/fluxbox/init \
65 skel/fluxbox/apps \
66 skel/fluxbox/keys \
67 skel/idesk \
68 skel/samba \
69 skel/xtdesktop
70 do
71 if [[ -f ${MROOT}/etc/alxconfig-ng/${i} ]]
72 then
73 rm ${MROOT}/etc/alxconfig-ng/${i} || die ${i}
74 fi
75 if [[ -d ${MROOT}/etc/alxconfig-ng/${i} ]]
76 then
77 rm -r ${MROOT}/etc/alxconfig-ng/${i} || die ${i}
78 fi
79 done
80
81 alx_postinstall
82 }
83 }
84
85 src_prepare()
86 {
87 munpack ${SRCFILE} || die
88 }
89
90 src_install_alxconfig-ng-dhcp-tools()
91 {
92 cd ${SRCDIR}
93
94 minstalldir /usr/sbin || die
95 minstallexec bin/alx-iface.sh /usr/sbin/alx-iface || die
96 minstallexec bin/dhcp-identifier.sh /usr/sbin/dhcp-identifier || die
97 }
98
99 src_install_alxconfig-ng()
100 {
101 cd ${SRCDIR}
102 make DESTDIR=${BINDIR} install || die
103
104 # provided by dhcp-tools
105 rm ${BINDIR}/usr/sbin/alx-iface || die
106 rm ${BINDIR}/usr/sbin/dhcp-identifier || die
107 }