opkg

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

gen.lua (7233B)


      1 cflags({
      2 	'-Wall',
      3 	'-I $srcdir/src',
      4 	'-I $srcdir/inc',
      5 	'-D BR_RDRAND=0',
      6 	'-D BR_USE_GETENTROPY',
      7 })
      8 
      9 pkg.hdrs = copy('$outdir/include', '$srcdir/inc', {
     10 	'bearssl.h',
     11 	'bearssl_aead.h',
     12 	'bearssl_block.h',
     13 	'bearssl_ec.h',
     14 	'bearssl_hash.h',
     15 	'bearssl_hmac.h',
     16 	'bearssl_kdf.h',
     17 	'bearssl_pem.h',
     18 	'bearssl_prf.h',
     19 	'bearssl_rand.h',
     20 	'bearssl_rsa.h',
     21 	'bearssl_ssl.h',
     22 	'bearssl_x509.h',
     23 })
     24 pkg.hdrs.install = true
     25 
     26 lib('libbearssl.a', [[src/(
     27 	settings.c
     28 	aead/ccm.c
     29 	aead/eax.c
     30 	aead/gcm.c
     31 	codec/ccopy.c
     32 	codec/dec16be.c
     33 	codec/dec16le.c
     34 	codec/dec32be.c
     35 	codec/dec32le.c
     36 	codec/dec64be.c
     37 	codec/dec64le.c
     38 	codec/enc16be.c
     39 	codec/enc16le.c
     40 	codec/enc32be.c
     41 	codec/enc32le.c
     42 	codec/enc64be.c
     43 	codec/enc64le.c
     44 	codec/pemdec.c
     45 	codec/pemenc.c
     46 	ec/ec_all_m15.c
     47 	ec/ec_all_m31.c
     48 	ec/ec_c25519_i15.c
     49 	ec/ec_c25519_i31.c
     50 	ec/ec_c25519_m15.c
     51 	ec/ec_c25519_m31.c
     52 	ec/ec_c25519_m62.c
     53 	ec/ec_c25519_m64.c
     54 	ec/ec_curve25519.c
     55 	ec/ec_default.c
     56 	ec/ec_keygen.c
     57 	ec/ec_p256_m15.c
     58 	ec/ec_p256_m31.c
     59 	ec/ec_p256_m62.c
     60 	ec/ec_p256_m64.c
     61 	ec/ec_prime_i15.c
     62 	ec/ec_prime_i31.c
     63 	ec/ec_pubkey.c
     64 	ec/ec_secp256r1.c
     65 	ec/ec_secp384r1.c
     66 	ec/ec_secp521r1.c
     67 	ec/ecdsa_atr.c
     68 	ec/ecdsa_default_sign_asn1.c
     69 	ec/ecdsa_default_sign_raw.c
     70 	ec/ecdsa_default_vrfy_asn1.c
     71 	ec/ecdsa_default_vrfy_raw.c
     72 	ec/ecdsa_i15_bits.c
     73 	ec/ecdsa_i15_sign_asn1.c
     74 	ec/ecdsa_i15_sign_raw.c
     75 	ec/ecdsa_i15_vrfy_asn1.c
     76 	ec/ecdsa_i15_vrfy_raw.c
     77 	ec/ecdsa_i31_bits.c
     78 	ec/ecdsa_i31_sign_asn1.c
     79 	ec/ecdsa_i31_sign_raw.c
     80 	ec/ecdsa_i31_vrfy_asn1.c
     81 	ec/ecdsa_i31_vrfy_raw.c
     82 	ec/ecdsa_rta.c
     83 	hash/dig_oid.c
     84 	hash/dig_size.c
     85 	hash/ghash_ctmul.c
     86 	hash/ghash_ctmul32.c
     87 	hash/ghash_ctmul64.c
     88 	hash/ghash_pclmul.c
     89 	hash/ghash_pwr8.c
     90 	hash/md5.c
     91 	hash/md5sha1.c
     92 	hash/mgf1.c
     93 	hash/multihash.c
     94 	hash/sha1.c
     95 	hash/sha2big.c
     96 	hash/sha2small.c
     97 	int/i15_add.c
     98 	int/i15_bitlen.c
     99 	int/i15_decmod.c
    100 	int/i15_decode.c
    101 	int/i15_decred.c
    102 	int/i15_encode.c
    103 	int/i15_fmont.c
    104 	int/i15_iszero.c
    105 	int/i15_moddiv.c
    106 	int/i15_modpow.c
    107 	int/i15_modpow2.c
    108 	int/i15_montmul.c
    109 	int/i15_mulacc.c
    110 	int/i15_muladd.c
    111 	int/i15_ninv15.c
    112 	int/i15_reduce.c
    113 	int/i15_rshift.c
    114 	int/i15_sub.c
    115 	int/i15_tmont.c
    116 	int/i31_add.c
    117 	int/i31_bitlen.c
    118 	int/i31_decmod.c
    119 	int/i31_decode.c
    120 	int/i31_decred.c
    121 	int/i31_encode.c
    122 	int/i31_fmont.c
    123 	int/i31_iszero.c
    124 	int/i31_moddiv.c
    125 	int/i31_modpow.c
    126 	int/i31_modpow2.c
    127 	int/i31_montmul.c
    128 	int/i31_mulacc.c
    129 	int/i31_muladd.c
    130 	int/i31_ninv31.c
    131 	int/i31_reduce.c
    132 	int/i31_rshift.c
    133 	int/i31_sub.c
    134 	int/i31_tmont.c
    135 	int/i32_add.c
    136 	int/i32_bitlen.c
    137 	int/i32_decmod.c
    138 	int/i32_decode.c
    139 	int/i32_decred.c
    140 	int/i32_div32.c
    141 	int/i32_encode.c
    142 	int/i32_fmont.c
    143 	int/i32_iszero.c
    144 	int/i32_modpow.c
    145 	int/i32_montmul.c
    146 	int/i32_mulacc.c
    147 	int/i32_muladd.c
    148 	int/i32_ninv32.c
    149 	int/i32_reduce.c
    150 	int/i32_sub.c
    151 	int/i32_tmont.c
    152 	int/i62_modpow2.c
    153 	kdf/hkdf.c
    154 	kdf/shake.c
    155 	mac/hmac.c
    156 	mac/hmac_ct.c
    157 	rand/aesctr_drbg.c
    158 	rand/hmac_drbg.c
    159 	rand/sysrng.c
    160 	rsa/rsa_default_keygen.c
    161 	rsa/rsa_default_modulus.c
    162 	rsa/rsa_default_oaep_decrypt.c
    163 	rsa/rsa_default_oaep_encrypt.c
    164 	rsa/rsa_default_pkcs1_sign.c
    165 	rsa/rsa_default_pkcs1_vrfy.c
    166 	rsa/rsa_default_priv.c
    167 	rsa/rsa_default_privexp.c
    168 	rsa/rsa_default_pss_sign.c
    169 	rsa/rsa_default_pss_vrfy.c
    170 	rsa/rsa_default_pub.c
    171 	rsa/rsa_default_pubexp.c
    172 	rsa/rsa_i15_keygen.c
    173 	rsa/rsa_i15_modulus.c
    174 	rsa/rsa_i15_oaep_decrypt.c
    175 	rsa/rsa_i15_oaep_encrypt.c
    176 	rsa/rsa_i15_pkcs1_sign.c
    177 	rsa/rsa_i15_pkcs1_vrfy.c
    178 	rsa/rsa_i15_priv.c
    179 	rsa/rsa_i15_privexp.c
    180 	rsa/rsa_i15_pss_sign.c
    181 	rsa/rsa_i15_pss_vrfy.c
    182 	rsa/rsa_i15_pub.c
    183 	rsa/rsa_i15_pubexp.c
    184 	rsa/rsa_i31_keygen.c
    185 	rsa/rsa_i31_keygen_inner.c
    186 	rsa/rsa_i31_modulus.c
    187 	rsa/rsa_i31_oaep_decrypt.c
    188 	rsa/rsa_i31_oaep_encrypt.c
    189 	rsa/rsa_i31_pkcs1_sign.c
    190 	rsa/rsa_i31_pkcs1_vrfy.c
    191 	rsa/rsa_i31_priv.c
    192 	rsa/rsa_i31_privexp.c
    193 	rsa/rsa_i31_pss_sign.c
    194 	rsa/rsa_i31_pss_vrfy.c
    195 	rsa/rsa_i31_pub.c
    196 	rsa/rsa_i31_pubexp.c
    197 	rsa/rsa_i32_oaep_decrypt.c
    198 	rsa/rsa_i32_oaep_encrypt.c
    199 	rsa/rsa_i32_pkcs1_sign.c
    200 	rsa/rsa_i32_pkcs1_vrfy.c
    201 	rsa/rsa_i32_priv.c
    202 	rsa/rsa_i32_pss_sign.c
    203 	rsa/rsa_i32_pss_vrfy.c
    204 	rsa/rsa_i32_pub.c
    205 	rsa/rsa_i62_keygen.c
    206 	rsa/rsa_i62_oaep_decrypt.c
    207 	rsa/rsa_i62_oaep_encrypt.c
    208 	rsa/rsa_i62_pkcs1_sign.c
    209 	rsa/rsa_i62_pkcs1_vrfy.c
    210 	rsa/rsa_i62_priv.c
    211 	rsa/rsa_i62_pss_sign.c
    212 	rsa/rsa_i62_pss_vrfy.c
    213 	rsa/rsa_i62_pub.c
    214 	rsa/rsa_oaep_pad.c
    215 	rsa/rsa_oaep_unpad.c
    216 	rsa/rsa_pkcs1_sig_pad.c
    217 	rsa/rsa_pkcs1_sig_unpad.c
    218 	rsa/rsa_pss_sig_pad.c
    219 	rsa/rsa_pss_sig_unpad.c
    220 	rsa/rsa_ssl_decrypt.c
    221 	ssl/prf.c
    222 	ssl/prf_md5sha1.c
    223 	ssl/prf_sha256.c
    224 	ssl/prf_sha384.c
    225 	ssl/ssl_ccert_single_ec.c
    226 	ssl/ssl_ccert_single_rsa.c
    227 	ssl/ssl_client.c
    228 	ssl/ssl_client_default_rsapub.c
    229 	ssl/ssl_client_full.c
    230 	ssl/ssl_engine.c
    231 	ssl/ssl_engine_default_aescbc.c
    232 	ssl/ssl_engine_default_aesccm.c
    233 	ssl/ssl_engine_default_aesgcm.c
    234 	ssl/ssl_engine_default_chapol.c
    235 	ssl/ssl_engine_default_descbc.c
    236 	ssl/ssl_engine_default_ec.c
    237 	ssl/ssl_engine_default_ecdsa.c
    238 	ssl/ssl_engine_default_rsavrfy.c
    239 	ssl/ssl_hashes.c
    240 	ssl/ssl_hs_client.c
    241 	ssl/ssl_hs_server.c
    242 	ssl/ssl_io.c
    243 	ssl/ssl_keyexport.c
    244 	ssl/ssl_lru.c
    245 	ssl/ssl_rec_cbc.c
    246 	ssl/ssl_rec_ccm.c
    247 	ssl/ssl_rec_chapol.c
    248 	ssl/ssl_rec_gcm.c
    249 	ssl/ssl_scert_single_ec.c
    250 	ssl/ssl_scert_single_rsa.c
    251 	ssl/ssl_server.c
    252 	ssl/ssl_server_full_ec.c
    253 	ssl/ssl_server_full_rsa.c
    254 	ssl/ssl_server_mine2c.c
    255 	ssl/ssl_server_mine2g.c
    256 	ssl/ssl_server_minf2c.c
    257 	ssl/ssl_server_minf2g.c
    258 	ssl/ssl_server_minr2g.c
    259 	ssl/ssl_server_minu2g.c
    260 	ssl/ssl_server_minv2g.c
    261 	symcipher/aes_big_cbcdec.c
    262 	symcipher/aes_big_cbcenc.c
    263 	symcipher/aes_big_ctr.c
    264 	symcipher/aes_big_ctrcbc.c
    265 	symcipher/aes_big_dec.c
    266 	symcipher/aes_big_enc.c
    267 	symcipher/aes_common.c
    268 	symcipher/aes_ct.c
    269 	symcipher/aes_ct64.c
    270 	symcipher/aes_ct64_cbcdec.c
    271 	symcipher/aes_ct64_cbcenc.c
    272 	symcipher/aes_ct64_ctr.c
    273 	symcipher/aes_ct64_ctrcbc.c
    274 	symcipher/aes_ct64_dec.c
    275 	symcipher/aes_ct64_enc.c
    276 	symcipher/aes_ct_cbcdec.c
    277 	symcipher/aes_ct_cbcenc.c
    278 	symcipher/aes_ct_ctr.c
    279 	symcipher/aes_ct_ctrcbc.c
    280 	symcipher/aes_ct_dec.c
    281 	symcipher/aes_ct_enc.c
    282 	symcipher/aes_pwr8.c
    283 	symcipher/aes_pwr8_cbcdec.c
    284 	symcipher/aes_pwr8_cbcenc.c
    285 	symcipher/aes_pwr8_ctr.c
    286 	symcipher/aes_pwr8_ctrcbc.c
    287 	symcipher/aes_small_cbcdec.c
    288 	symcipher/aes_small_cbcenc.c
    289 	symcipher/aes_small_ctr.c
    290 	symcipher/aes_small_ctrcbc.c
    291 	symcipher/aes_small_dec.c
    292 	symcipher/aes_small_enc.c
    293 	symcipher/aes_x86ni.c
    294 	symcipher/aes_x86ni_cbcdec.c
    295 	symcipher/aes_x86ni_cbcenc.c
    296 	symcipher/aes_x86ni_ctr.c
    297 	symcipher/aes_x86ni_ctrcbc.c
    298 	symcipher/chacha20_ct.c
    299 	symcipher/chacha20_sse2.c
    300 	symcipher/des_ct.c
    301 	symcipher/des_ct_cbcdec.c
    302 	symcipher/des_ct_cbcenc.c
    303 	symcipher/des_support.c
    304 	symcipher/des_tab.c
    305 	symcipher/des_tab_cbcdec.c
    306 	symcipher/des_tab_cbcenc.c
    307 	symcipher/poly1305_ctmul.c
    308 	symcipher/poly1305_ctmul32.c
    309 	symcipher/poly1305_ctmulq.c
    310 	symcipher/poly1305_i15.c
    311 	x509/asn1enc.c
    312 	x509/encode_ec_pk8der.c
    313 	x509/encode_ec_rawder.c
    314 	x509/encode_rsa_pk8der.c
    315 	x509/encode_rsa_rawder.c
    316 	x509/skey_decoder.c
    317 	x509/x509_decoder.c
    318 	x509/x509_knownkey.c
    319 	x509/x509_minimal.c
    320 	x509/x509_minimal_full.c
    321 )]])
    322 file('lib/libbearssl.a', '644', '$outdir/libbearssl.a')
    323 
    324 exe('brssl', [[
    325 	tools/(
    326 		brssl.c
    327 		certs.c
    328 		chain.c
    329 		client.c
    330 		errors.c
    331 		files.c
    332 		impl.c
    333 		keys.c
    334 		names.c
    335 		server.c
    336 		skey.c
    337 		sslio.c
    338 		ta.c
    339 		twrch.c
    340 		vector.c
    341 		verify.c
    342 		xmem.c
    343 	)
    344 	libbearssl.a
    345 ]])
    346 file('bin/brssl', '755', '$outdir/brssl')
    347 
    348 fetch('git')