# Contributor: Natanael Copa # Maintainer: Natanael Copa global pkgname := 'dhex' global pkgver := '0.68' global pkgrel := '1' global pkgdesc := '"Ncurses hex editor'" global url := '"http://www.dettus.net/dhex/'" global arch := '"all'" global license := '"GPL2+'" global depends := ''"" global makedepends := '"ncurses-dev'" global install := ''"" global subpackages := ""$pkgname-doc"" global source := ""http://www.dettus.net/dhex/dhex_$pkgver.tar.gz makefile.patch"" global _builddir := ""$srcdir"/dhex_$pkgver" proc prepare { var i = '' cd $_builddir for i in [$source] { matchstr $i { *.patch { msg $i; patch -p1 -i "$srcdir"/$i || return 1} } } } proc build { cd $_builddir make || return 1 } proc package { cd $_builddir make install DESTDIR="$pkgdir" \ mandir=/usr/share/man \ prefix=/usr || return 1 } global md5sums := '"5109b3d50053553e41d75c8e5c0a0175 dhex_0.68.tar.gz de16e09d3b416650d84ef39235cd2917 makefile.patch'" global sha256sums := '"126c34745b48a07448cfe36fe5913d37ec562ad72d3f732b99bd40f761f4da08 dhex_0.68.tar.gz e29f8279a25c6bcc6f43f61c80d08948e40cea67866eed5e745ea5f63af3d291 makefile.patch'" global sha512sums := '"9397ec0574652022387f4108613f839b9262841c436079249fb325011b0a0e3c5bbd32d323f37b0f30e643f7060c1275337710c237ab68fb0c3f8096651a2421 dhex_0.68.tar.gz 0e2aa694723afd859f97f8ea02a79fec02bcbd70b9f4bd8ba1e33743f1fa72fa8810bfb7bac2c7a855bf407cd7c0cbb3ef82c7fea1fcb19a2701ab2d55baf7e3 makefile.patch'" (CommandList children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgname) op:Equal rhs:{(dhex)} spids:[6])] spids: [6] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:pkgver) op:Equal rhs:{(0.68)} 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 ("Ncurses hex editor"))} spids: [15] ) ] spids: [15] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:url) op: Equal rhs: {(DQ ("http://www.dettus.net/dhex/"))} 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 ("GPL2+"))} spids:[30])] spids: [30] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:depends) op:Equal rhs:{(DQ )} spids:[35])] spids: [35] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:makedepends) op: Equal rhs: {(DQ (ncurses-dev))} spids: [39] ) ] spids: [39] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:install) op:Equal rhs:{(DQ )} spids:[44])] spids: [44] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:subpackages) op: Equal rhs: {(DQ ($ VSub_Name "$pkgname") (-doc))} spids: [48] ) ] spids: [48] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:source) op: Equal rhs: { (DQ ("http://www.dettus.net/dhex/dhex_") ($ VSub_Name "$pkgver") (".tar.gz\n") ("\t\tmakefile.patch") ) } spids: [54] ) ] spids: [54] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:_builddir) op: Equal rhs: {(DQ ($ VSub_Name "$srcdir")) (/dhex_) ($ VSub_Name "$pkgver")} spids: [62] ) ] spids: [62] ) (FuncDef name: prepare body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [(assign_pair lhs:(LhsName name:i) op:Equal spids:[79])] spids: [77] ) (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: [108 110 134 -1] ) ] spids: [101 105 137] ) ] spids: [98 140] ) spids: [94 96] ) ] spids: [74] ) spids: [70 73] ) (FuncDef name: build body: (BraceGroup children: [ (C {(cd)} {(DQ ($ VSub_Name "$_builddir"))}) (AndOr children: [(C {(make)}) (ControlFlow token: arg_word:{(1)})] op_id: Op_DPipe ) ] spids: [149] ) spids: [145 148] ) (FuncDef name: package body: (BraceGroup children: [ (C {(cd)} {(DQ ($ VSub_Name "$_builddir"))}) (AndOr children: [ (C {(make)} {(install)} {(Lit_VarLike "DESTDIR=") (DQ ($ VSub_Name "$pkgdir"))} {(Lit_VarLike "mandir=") (/usr/share/man)} {(Lit_VarLike "prefix=") (/usr)} ) (ControlFlow token: arg_word:{(1)}) ] op_id: Op_DPipe ) ] spids: [174] ) spids: [170 173] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:md5sums) op: Equal rhs: { (DQ ("5109b3d50053553e41d75c8e5c0a0175 dhex_0.68.tar.gz\n") ("de16e09d3b416650d84ef39235cd2917 makefile.patch") ) } spids: [212] ) ] spids: [212] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:sha256sums) op: Equal rhs: { (DQ ( "126c34745b48a07448cfe36fe5913d37ec562ad72d3f732b99bd40f761f4da08 dhex_0.68.tar.gz\n" ) ("e29f8279a25c6bcc6f43f61c80d08948e40cea67866eed5e745ea5f63af3d291 makefile.patch") ) } spids: [218] ) ] spids: [218] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:sha512sums) op: Equal rhs: { (DQ ( "9397ec0574652022387f4108613f839b9262841c436079249fb325011b0a0e3c5bbd32d323f37b0f30e643f7060c1275337710c237ab68fb0c3f8096651a2421 dhex_0.68.tar.gz\n" ) ( "0e2aa694723afd859f97f8ea02a79fec02bcbd70b9f4bd8ba1e33743f1fa72fa8810bfb7bac2c7a855bf407cd7c0cbb3ef82c7fea1fcb19a2701ab2d55baf7e3 makefile.patch" ) ) } spids: [224] ) ] spids: [224] ) ] )