opkg

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

gen.lua (3843B)


      1 cflags({
      2 	'-std=c99', '-Wall', '-Wpedantic', '-Wno-maybe-uninitialized',
      3 	'-D _DEFAULT_SOURCE',
      4 	'-D HAVE_CONFIG_H',
      5 	'-D BUILDING_LIBCURL',
      6 	'-D CURL_STATICLIB',
      7 	'-I $outdir',
      8 	'-I $outdir/include/curl',
      9 	'-I $outdir/include',
     10 	'-I $srcdir/lib',
     11 	'-I $srcdir/src',
     12 	'-isystem $builddir/pkg/libs/bearssl/include',
     13 	'-isystem $builddir/pkg/devel/linux-headers/include',
     14 	'-isystem $builddir/pkg/libs/zlib/include',
     15 })
     16 
     17 build('cat', '$outdir/curl_config.h', {
     18 	'$dir/curl_config.h',
     19 	'$builddir/probe/SIZEOF_LONG',
     20 	'$builddir/probe/SIZEOF_SIZE_T',
     21 	'$builddir/probe/SIZEOF_TIME_T',
     22 })
     23 
     24 -- src/include/curl/Makefile.am:/^pkginclude_HEADERS
     25 pkg.hdrs = copy('$outdir/include/curl', '$srcdir/include/curl', {
     26 	'curl.h', 'curlver.h', 'easy.h', 'mprintf.h', 'stdcheaders.h', 'multi.h',
     27 	'typecheck-gcc.h', 'system.h', 'urlapi.h', 'options.h', 'header.h', 'websockets.h',
     28 })
     29 pkg.deps = {
     30 	'$outdir/curl_config.h',
     31 	'$gendir/headers',
     32 	'pkg/libs/bearssl/headers',
     33 	'pkg/devel/linux-headers/headers',
     34 	'pkg/libs/zlib/headers',
     35 }
     36 
     37 -- src/lib/Makefile.inc:/^CSOURCES
     38 lib('libcurl.a', [[
     39 	lib/(
     40 		altsvc.c amigaos.c asyn-ares.c asyn-thread.c base64.c bufq.c
     41 		bufref.c c-hyper.c cf-h1-proxy.c cf-h2-proxy.c cf-haproxy.c
     42 		cf-https-connect.c cf-socket.c cfilters.c conncache.c connect.c
     43 		content_encoding.c cookie.c curl_addrinfo.c curl_des.c
     44 		curl_endian.c curl_fnmatch.c curl_get_line.c curl_gethostname.c
     45 		curl_gssapi.c curl_memrchr.c curl_multibyte.c curl_ntlm_core.c
     46 		curl_ntlm_wb.c curl_path.c curl_range.c curl_rtmp.c curl_sasl.c
     47 		curl_sspi.c curl_threads.c curl_trc.c dict.c doh.c dynbuf.c
     48 		dynhds.c easy.c easygetopt.c easyoptions.c escape.c file.c
     49 		fileinfo.c fopen.c formdata.c ftp.c ftplistparser.c getenv.c
     50 		getinfo.c gopher.c hash.c headers.c hmac.c hostasyn.c hostip.c
     51 		hostip4.c hostip6.c hostsyn.c hsts.c http.c http1.c http2.c
     52 		http_aws_sigv4.c http_chunks.c http_digest.c http_negotiate.c
     53 		http_ntlm.c http_proxy.c idn.c if2ip.c imap.c inet_ntop.c
     54 		inet_pton.c krb5.c ldap.c llist.c macos.c md4.c md5.c memdebug.c
     55 		mime.c mprintf.c mqtt.c multi.c netrc.c nonblock.c noproxy.c
     56 		openldap.c parsedate.c pingpong.c pop3.c progress.c psl.c rand.c
     57 		rename.c rtsp.c select.c sendf.c setopt.c sha256.c share.c
     58 		slist.c smb.c smtp.c socketpair.c socks.c socks_gssapi.c
     59 		socks_sspi.c speedcheck.c splay.c strcase.c strdup.c strerror.c
     60 		strtok.c strtoofft.c system_win32.c telnet.c tftp.c timediff.c
     61 		timeval.c transfer.c url.c urlapi.c version.c version_win32.c
     62 		warnless.c ws.c
     63 		vauth/(
     64 			cleartext.c cram.c digest.c digest_sspi.c
     65 			gsasl.c krb5_gssapi.c krb5_sspi.c ntlm.c
     66 			ntlm_sspi.c oauth2.c spnego_gssapi.c
     67 			spnego_sspi.c vauth.c
     68 		)
     69 		vtls/(
     70 			bearssl.c gtls.c hostcheck.c keylog.c mbedtls.c
     71 			mbedtls_threadlock.c openssl.c rustls.c schannel.c
     72 			schannel_verify.c sectransp.c vtls.c wolfssl.c
     73 			x509asn1.c
     74 		)
     75 		vquic/(curl_msh3.c curl_ngtcp2.c curl_quiche.c vquic.c)
     76 		vssh/(libssh.c libssh2.c wolfssh.c)
     77 	)
     78 	$builddir/pkg/libs/bearssl/libbearssl.a
     79 	$builddir/pkg/libs/zlib/libz.a
     80 ]])
     81 
     82 -- src/src/Makefile.inc:/^CURL_CFILES
     83 exe('curl', [[
     84 	src/(
     85 		slist_wc.c
     86 		tool_binmode.c
     87 		tool_bname.c
     88 		tool_cb_dbg.c
     89 		tool_cb_hdr.c
     90 		tool_cb_prg.c
     91 		tool_cb_rea.c
     92 		tool_cb_see.c
     93 		tool_cb_wrt.c
     94 		tool_cfgable.c
     95 		tool_dirhie.c
     96 		tool_doswin.c
     97 		tool_easysrc.c
     98 		tool_filetime.c
     99 		tool_findfile.c
    100 		tool_formparse.c
    101 		tool_getparam.c
    102 		tool_getpass.c
    103 		tool_help.c
    104 		tool_helpers.c
    105 		tool_ipfs.c
    106 		tool_libinfo.c
    107 		tool_listhelp.c
    108 		tool_main.c
    109 		tool_msgs.c
    110 		tool_operate.c
    111 		tool_operhlp.c
    112 		tool_paramhlp.c
    113 		tool_parsecfg.c
    114 		tool_progress.c
    115 		tool_setopt.c
    116 		tool_sleep.c
    117 		tool_stderr.c
    118 		tool_strdup.c
    119 		tool_urlglob.c
    120 		tool_util.c
    121 		tool_vms.c
    122 		tool_writeout.c
    123 		tool_writeout_json.c
    124 		tool_xattr.c
    125 		var.c
    126 	)
    127 	libcurl.a.d
    128 ]])
    129 
    130 file('bin/curl', '755', '$outdir/curl')
    131 man({'docs/curl.1'})
    132 
    133 fetch('curl')