Magellan Linux

Contents of /smage/branches/alx-0_6_0/core/mage/mage-0.4.29-r3.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6954 - (show annotations) (download)
Tue Jul 28 10:10:34 2015 UTC (8 years, 9 months ago) by niro
File size: 1951 byte(s)
auto added: ver bump to 0.4.29-r3
1 # $Id$
2
3 PNAME="mage"
4 PVER="0.4.29"
5 PBUILD="r3"
6
7 PCATEGORIE="app-mage"
8
9 # keep this state here for older smage versions (< 0.4.27)
10 # which cannot handle a global distribution file
11 #
12 # on all other smagefiles this variable can be kept too,
13 # but it gets always overriden by the global distribution
14 # file params and it is suggested to drop the local STATE variable
15 #
16 STATE="unstable"
17
18 DESCRIPTION="Magellan Package Manager."
19 HOMEPAGE="http://magellan-linux.de/"
20
21 DEPEND=""
22
23 SRCFILE="${PNAME}-${PVER}.tar.bz2"
24 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
25
26 REMOVE_DEPRECATED_MAGE_TARGETS=1
27 sminclude alx
28
29 SRC_URI=(
30 mirror://${PNAME}/${SRCFILE}
31 mirror://${PNAME}/${PNAME}-${PVER}-busybox-tar-does-not-support-J-option-for-xz.patch
32 mirror://${PNAME}/${PNAME}-${PVER}-unpack-pkgs-while-installation.patch
33 )
34
35 src_prepare()
36 {
37 munpack ${SRCFILE} || die
38 cd ${SRCDIR}
39
40 # unpack packages while installation phase, no extra unpack phase to save space
41 # upstream patch from 0.4.94
42 mpatch ${PNAME}-${PVER}-unpack-pkgs-while-installation.patch || die
43
44 # busybox tar does not support -J option for xz
45 mpatch ${PNAME}-${PVER}-busybox-tar-does-not-support-J-option-for-xz.patch || die
46 }
47
48 src_install()
49 {
50 cd ${SRCDIR}
51 make DESTDIR=${BINDIR} install || die
52
53 # fix version
54 echo "${PVER}-${PBUILD}" > ${BINDIR}/usr/lib/mage/version || die
55 }
56
57 preinstall()
58 {
59 add_conf_prot_mask /etc/mage.rc.example /etc/etc-update.conf
60 }
61
62 postinstall()
63 {
64 local PVER
65 PVER="$(echo ${PKGNAME} | cut -d- -f2)"
66
67 echo
68 echo -e "Important:"
69 echo -e "\tIf you upgraded mage from a version < ${PVER},"
70 echo -e "\tcheck '/etc/mage.rc.example' for new pathnames"
71 echo -e "\tand copy expected files there."
72 echo -e "\tEdit your /etc/mage.rc that it fits to the example file."
73 echo
74 echo -e "\tAlso select an profile from ${MAGEDIR}/profiles and link"
75 echo -e "\tit to /etc/mage-profile."
76 echo -e "\tex. 'ln -snf ${MAGEDIR}/profiles/kernel26 /etc/mage-profile'"
77 echo
78
79 alx_postinstall
80 }