Magellan Linux

Annotation of /branches/R11-unstable/include/ggz.sminc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 24893 - (hide annotations) (download)
Tue Nov 25 02:21:44 2014 UTC (9 years, 5 months ago) by niro
File size: 1628 byte(s)
-release R11-unstable
1 niro 2 # $Header: /magellan-cvs/smage/include/ggz.sminc,v 1.3 2008/03/31 21:51:32 niro Exp $
2     #
3     # sminc for ggz-gaming-zone packages
4     #
5    
6     sminclude mbuild
7    
8     # some sane default values
9 niro 9863 : ${PCAT="dev-games"}
10 niro 2 : ${SRCFILE="${PNAME}-${PVER}.tar.gz"}
11     : ${SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"}
12     : ${DESCRIPTION="The GGZ Gaming Zone - ${PNAME}"}
13     : ${HOMEPAGE="http://www.ggzgamingzone.org/"}
14    
15     # functions to include in the mage file
16 niro 4788 SPECIAL_FUNCTIONS="${SPECIAL_FUNCTIONS} ggz_update_modules ggz_postinstall ggz_postremove"
17 niro 2
18     SRC_URI=(
19     ${SRC_URI[*]}
20     http://ftp.belnet.be/packages/ggzgamingzone/ggz/${PVER}/${SRCFILE}
21     http://mirrors.dotsrc.org/ggzgamingzone/ggz/${PVER}/${SRCFILE}
22     http://mirrors.ibiblio.org/pub/mirrors/ggzgamingzone/ggz/${PVER}/${SRCFILE}
23     mirror://${PNAME}/${SRCFILE}
24     )
25    
26     ggz_configure()
27     {
28     local configure_opts
29    
30     # add commandline given arguments
31     configure_opts="$@"
32    
33     mconfigure \
34     --disable-dependency-tracking \
35     --enable-noregistry=/usr/share/ggz/modules \
36     --disable-debug \
37     ${configure_opts} \
38     || die
39     }
40    
41     ggz_src_compile()
42     {
43     cd ${SRCDIR}
44    
45     ggz_configure || die
46     mmake || die
47     }
48    
49     ggz_update_modules()
50     {
51     ggz-config -h &> /dev/null
52    
53     install -d ${MROOT}/etc
54     :> ${MROOT}/etc/ggz.modules
55    
56     if [[ -d ${MROOT}/usr/share/ggz/modules ]]
57     then
58     echo -ne "${COLBLUE} --- ${COLDEFAULT}"
59     echo "updating GGZ modules ..."
60     cd ${MROOT}/usr/share/ggz/modules
61    
62     local dsc
63     find . -type f -name '*.dsc' | while read dsc
64     do
65     DESTDIR=${MROOT} ggz-config -Dim "${dsc}"
66     done
67     fi
68     }
69    
70     ggz_postinstall()
71     {
72     ggz_update_modules
73     }
74    
75     ggz_postremove()
76     {
77     ggz_update_modules
78     }
79    
80     export_inherits ggz src_compile postinstall postremove