opkg

statically linked package installer
git clone anongit@rnpnr.xyz:opkg.git
Log | Files | Refs | Feed | Submodules | README | LICENSE

gen.lua (947B)


      1 cflags({
      2 	'-Wall', '-Wextra', '-Wpedantic',
      3 	'-include $dir/config.h',
      4 })
      5 
      6 pkg.hdrs = {
      7 	copy('$outdir/include', '$srcdir/lib', {'zstd.h', 'zdict.h', 'zstd_errors.h'}),
      8 }
      9 pkg.deps = {
     10 	'$gendir/headers',
     11 	'$dir/config.h',
     12 }
     13 
     14 lib('libzstd.a', [[lib/(
     15 	common/(
     16 		debug.c
     17 		entropy_common.c
     18 		error_private.c
     19 		fse_decompress.c
     20 		pool.c
     21 		threading.c
     22 		xxhash.c
     23 		zstd_common.c
     24 	)
     25 	compress/(
     26 		fse_compress.c
     27 		hist.c
     28 		huf_compress.c
     29 		zstd_compress.c
     30 		zstd_compress_literals.c
     31 		zstd_compress_sequences.c
     32 		zstd_compress_superblock.c
     33 		zstd_double_fast.c
     34 		zstd_fast.c
     35 		zstd_lazy.c
     36 		zstd_ldm.c
     37 		zstd_opt.c
     38 		zstdmt_compress.c
     39 	)
     40 	decompress/(
     41 		huf_decompress.c
     42 		zstd_ddict.c
     43 		zstd_decompress.c
     44 		zstd_decompress_block.c
     45 	)
     46 )]])
     47 
     48 exe('zstd', [[
     49 	programs/(zstdcli.c util.c timefn.c fileio.c)
     50 	libzstd.a
     51 ]])
     52 file('bin/zstd', '755', '$outdir/zstd')
     53 sym('bin/unzstd', 'zstd')
     54 sym('bin/zstdcat', 'zstd')
     55 
     56 man({'programs/zstd.1'})
     57 
     58 fetch('git')