# Contributor: Leonardo Arena # Maintainer: Leonardo Arena global pkgname := 'milter-greylist' global pkgver := '4.6.2' global pkgrel := '1' global pkgdesc := '"Stand-alone milter written in C that implements the greylist filtering method'" global url := '"http://hcpnet.free.fr/milter-greylist'" global arch := '"all'" global license := '"GPL'" global depends := '' global depends_dev := '' global makedepends := ""$depends_dev bison flex geoip-dev libmilter-dev libspf2-dev"" global install := ""$pkgname.pre-install"" global subpackages := ""$pkgname-doc"" global pkgusers := '"smmsp'" global pkggroups := '"smmsp'" global source := ""ftp://ftp.espci.fr/pub/milter-greylist/$pkgname-$pkgver.tgz milter-greylist-conf.patch "" global builddir := ""$srcdir"/$pkgname-$pkgver" proc prepare { cd $builddir for i in [$source] { matchstr $i { *.patch { msg $i; patch -p1 -i "$srcdir"/$i || return 1} } } #autoreconf -vif } proc build { cd $builddir ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr \ --sysconfdir=/etc \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --localstatedir=/var/lib \ --with-libspf2 \ --with-user=smmsp \ --with-conffile=/etc/$pkgname/greylist.conf \ --with-dumpfile=/var/lib/$pkgname/greylist.db \ --with-thread-safe-resolver \ --with-libGeoIP \ --enable-postfix \ --enable-spamassassin \ --enable-dnsrbl \ --disable-rpath make -j1 || return 1 } proc package { cd $builddir make DESTDIR="$pkgdir" install || return 1 install -m755 -D ../../$pkgname.initd "$pkgdir"/etc/init.d/$pkgname || return 1 install -m644 -D greylist2.conf "$pkgdir"/etc/$pkgname/greylist2.conf mkdir -p "$pkgdir"/var/lib/$pkgname chown -R smmsp:smmsp "$pkgdir"/var/lib/$pkgname } global md5sums := '"8872008db2fc6b93dd9ab8576383fec2 milter-greylist-4.6.2.tgz 141e3b79fcea533cdd9ae57f2d731f24 milter-greylist-conf.patch'" global sha256sums := '"5405a71bc8273848a1e14cecc010b95491e754307b005c96d35081ab2f9b8bd5 milter-greylist-4.6.2.tgz 973788cd06c96d7e9c02d9ccfc1dd62f85c3ef635b44873755575033b7a97336 milter-greylist-conf.patch'" global sha512sums := '"458b4e74cadca6cb50838b87a192392cc19bde61062d2b25b2ca0fc515a277b53d177d9605f34aff1671f7722462c31ce419a4e058ca6ea23b80a8debf33079c milter-greylist-4.6.2.tgz 4057061fae24a8d008c6a8aed82018a4bb9f6e9ce72a13d9369d54b192e9a6e99b0e72db8905aa182879c9522b87a92844d0be92773843773508a21e42dbd447 milter-greylist-conf.patch'" (CommandList children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgname) op:Equal rhs:{(milter-greylist)} spids:[6])] spids: [6] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgver) op:Equal rhs:{(4.6.2)} spids:[9])] spids: [9] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgrel) op:Equal rhs:{(1)} spids:[12])] spids: [12] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:pkgdesc) op: Equal rhs: {(DQ ("Stand-alone milter written in C that implements the greylist filtering method"))} spids: [15] ) ] spids: [15] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:url) op: Equal rhs: {(DQ ("http://hcpnet.free.fr/milter-greylist"))} spids: [20] ) ] spids: [20] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:arch) op:Equal rhs:{(DQ (all))} spids:[25])] spids: [25] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:license) op:Equal rhs:{(DQ (GPL))} spids:[30])] spids: [30] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:depends) op:Equal rhs:{(SQ )} spids:[35])] spids: [35] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:depends_dev) op:Equal rhs:{(SQ )} spids:[37])] spids: [37] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:makedepends) op: Equal rhs: {(DQ ($ VSub_Name "$depends_dev") (" bison flex geoip-dev libmilter-dev libspf2-dev"))} spids: [39] ) ] spids: [39] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:install) op: Equal rhs: {(DQ ($ VSub_Name "$pkgname") (.pre-install))} spids: [45] ) ] spids: [45] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:subpackages) op: Equal rhs: {(DQ ($ VSub_Name "$pkgname") (-doc))} spids: [51] ) ] spids: [51] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgusers) op:Equal rhs:{(DQ (smmsp))} spids:[57])] spids: [57] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkggroups) op:Equal rhs:{(DQ (smmsp))} spids:[62])] spids: [62] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:source) op: Equal rhs: { (DQ ("ftp://ftp.espci.fr/pub/milter-greylist/") ($ VSub_Name "$pkgname") (-) ($ VSub_Name "$pkgver") (".tgz\n") ("\tmilter-greylist-conf.patch\n") ("\t") ) } spids: [67] ) ] spids: [67] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:builddir) op: Equal rhs: {(DQ ($ VSub_Name "$srcdir")) (/) ($ VSub_Name "$pkgname") (-) ($ VSub_Name "$pkgver")} spids: [79] ) ] spids: [79] ) (FuncDef name: prepare body: (BraceGroup children: [ (C {(cd)} {(DQ ($ VSub_Name "$builddir"))}) (ForEach iter_name: i iter_words: [{($ VSub_Name "$source")}] do_arg_iter: False body: (DoGroup children: [ (Case to_match: {($ VSub_Name "$i")} arms: [ (case_arm pat_list: [{(Lit_Other "*") (.patch)}] action: [ (Sentence child: (C {(msg)} {($ VSub_Name "$i")}) terminator: ) (AndOr children: [ (C {(patch)} {(-p1)} {(-i)} {(DQ ($ VSub_Name "$srcdir")) (/) ($ VSub_Name "$i")} ) (ControlFlow token: arg_word: {(1)} ) ] op_id: Op_DPipe ) ] spids: [122 124 148 -1] ) ] spids: [115 119 151] ) ] spids: [112 154] ) spids: [108 110] ) ] spids: [93] ) spids: [89 92] ) (FuncDef name: build body: (BraceGroup children: [ (C {(cd)} {(DQ ($ VSub_Name "$builddir"))}) (C {(./configure)} {(--build) (Lit_Other "=") ($ VSub_Name "$CBUILD")} {(--host) (Lit_Other "=") ($ VSub_Name "$CHOST")} {(--prefix) (Lit_Other "=") (/usr)} {(--sysconfdir) (Lit_Other "=") (/etc)} {(--mandir) (Lit_Other "=") (/usr/share/man)} {(--infodir) (Lit_Other "=") (/usr/share/info)} {(--localstatedir) (Lit_Other "=") (/var/lib)} {(--with-libspf2)} {(--with-user) (Lit_Other "=") (smmsp)} {(--with-conffile) (Lit_Other "=") (/etc/) ($ VSub_Name "$pkgname") (/greylist.conf)} {(--with-dumpfile) (Lit_Other "=") (/var/lib/) ($ VSub_Name "$pkgname") (/greylist.db)} {(--with-thread-safe-resolver)} {(--with-libGeoIP)} {(--enable-postfix)} {(--enable-spamassassin)} {(--enable-dnsrbl)} {(--disable-rpath)} ) (AndOr children: [ (C {(make)} {(-j1)}) (ControlFlow token: arg_word:{(1)}) ] op_id: Op_DPipe ) ] spids: [167] ) spids: [163 166] ) (FuncDef name: package body: (BraceGroup children: [ (C {(cd)} {(DQ ($ VSub_Name "$builddir"))}) (AndOr children: [ (C {(make)} {(Lit_VarLike "DESTDIR=") (DQ ($ VSub_Name "$pkgdir"))} {(install)}) (ControlFlow token: arg_word:{(1)}) ] op_id: Op_DPipe ) (AndOr children: [ (C {(install)} {(-m755)} {(-D)} {(../../) ($ VSub_Name "$pkgname") (.initd)} {(DQ ($ VSub_Name "$pkgdir")) (/etc/init.d/) ($ VSub_Name "$pkgname")} ) (ControlFlow token: arg_word:{(1)}) ] op_id: Op_DPipe ) (C {(install)} {(-m644)} {(-D)} {(greylist2.conf)} {(DQ ($ VSub_Name "$pkgdir")) (/etc/) ($ VSub_Name "$pkgname") (/greylist2.conf)} ) (C {(mkdir)} {(-p)} {(DQ ($ VSub_Name "$pkgdir")) (/var/lib/) ($ VSub_Name "$pkgname")}) (C {(chown)} {(-R)} {(smmsp) (Lit_Other ":") (smmsp)} {(DQ ($ VSub_Name "$pkgdir")) (/var/lib/) ($ VSub_Name "$pkgname")} ) ] spids: [289] ) spids: [285 288] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:md5sums) op: Equal rhs: { (DQ ("8872008db2fc6b93dd9ab8576383fec2 milter-greylist-4.6.2.tgz\n") ("141e3b79fcea533cdd9ae57f2d731f24 milter-greylist-conf.patch") ) } spids: [382] ) ] spids: [382] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:sha256sums) op: Equal rhs: { (DQ ( "5405a71bc8273848a1e14cecc010b95491e754307b005c96d35081ab2f9b8bd5 milter-greylist-4.6.2.tgz\n" ) ("973788cd06c96d7e9c02d9ccfc1dd62f85c3ef635b44873755575033b7a97336 milter-greylist-conf.patch") ) } spids: [388] ) ] spids: [388] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:sha512sums) op: Equal rhs: { (DQ ( "458b4e74cadca6cb50838b87a192392cc19bde61062d2b25b2ca0fc515a277b53d177d9605f34aff1671f7722462c31ce419a4e058ca6ea23b80a8debf33079c milter-greylist-4.6.2.tgz\n" ) ( "4057061fae24a8d008c6a8aed82018a4bb9f6e9ce72a13d9369d54b192e9a6e99b0e72db8905aa182879c9522b87a92844d0be92773843773508a21e42dbd447 milter-greylist-conf.patch" ) ) } spids: [394] ) ] spids: [394] ) ] )