thecatalinstan / Criollo

A powerful Cocoa web framework and HTTP server for macOS, iOS and tvOS.
https://criollo.io/
MIT License
290 stars 51 forks source link

Xcode-12: Unable to determine target or target not included in OpenSSL build #69

Closed kshamashuttl closed 3 years ago

kshamashuttl commented 4 years ago

OpenSSL issue with Xcode 12.

SwiftLocalhost uses Criollo library.

Compilation error:

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/opensslconf.h:26:3: **Unable to determine target or target not included in OpenSSL build**

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bio.h:667:1: expected function body after function declarator
DEPRECATEDIN_1_1_0(int BIO_get_port(const char *str, unsigned short *port_ptr))

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/err.h:248:1: expected function body after function declarator
DEPRECATEDIN_1_0_0(void ERR_remove_state(unsigned long pid))

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:144:43: unknown type name 'BN_ULONG'
int BN_abs_is_word(const BIGNUM *a, const BN_ULONG w);

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:147:39: unknown type name 'BN_ULONG'
int BN_is_word(const BIGNUM *a, const BN_ULONG w);

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:173:22: unknown type name 'BN_ULONG'
int BN_num_bits_word(BN_ULONG l);

- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:225:1: unknown type name 'BN_ULONG'
BN_ULONG BN_mod_word(const BIGNUM *a, BN_ULONG w);
           ^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:225:39: unknown type name 'BN_ULONG'
BN_ULONG BN_mod_word(const BIGNUM *a, BN_ULONG w);
^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:226:1: unknown type name 'BN_ULONG'
BN_ULONG BN_div_word(BIGNUM *a, BN_ULONG w);
                                      ^
-  /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:226:33: unknown type name 'BN_ULONG'
BN_ULONG BN_div_word(BIGNUM *a, BN_ULONG w);
^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:227:28: unknown type name 'BN_ULONG'
int BN_mul_word(BIGNUM *a, BN_ULONG w);
                                ^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:228:28: unknown type name 'BN_ULONG'
int BN_add_word(BIGNUM *a, BN_ULONG w);
                           ^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:229:28: unknown type name 'BN_ULONG'
int BN_sub_word(BIGNUM *a, BN_ULONG w);
                           ^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:230:28: unknown type name 'BN_ULONG'
int BN_set_word(BIGNUM *a, BN_ULONG w);
                           ^
- /Users/vagrant/git/PROJECT_NAME/Pods/Criollo/Libraries/OpenSSL/openssl.framework/Headers/bn.h:231:1: unknown type name 'BN_ULONG'
BN_ULONG BN_get_word(const BIGNUM *a);
thecatalinstan commented 3 years ago

It sounds like you are trying to build for "Catalyst" as well. I've only pre-built OpenSSL for iOS and tvOS. Are you using HTTPS at all?

I will try to build for Catalyst as well, but I'm tempted to remove OpenSSL altogether since the only thing that it's used for is to parse PEM and DER files on iOS and tvOS. Basically developers would have to pass in a PKCS#12 identity in order to enable HTTPS. Would such a change cause a lot of issues for you?

Thanks, Catalin

ajit-singh-ggn commented 3 years ago

@kshamashuttl Have you found any workaround for this issue?