1

I just want to build static poco library using CC compiler v5.12 on Solaris 11 Sparc machine

My poco source directory is kept here:

/poco-1.9.4-all/< all modules are here like Foundation, Crypto, etc >

OpenSSL headers (openssl1.1.1) are kept at:

/poco-1.9.4-all/Crypto/include/openssl

I am using following export variables:

export OSARCH_64BITS=1
export POCO_BASE="/poco-1.9.4-all"

Configuration is done as follows:

./configure --config=SunOS-SunStudio11 --omit=CppUnit,Data,Data/SQLite,Data/MySQL,Data/ODBC,Zip,PageCompiler,PageCompiler/File2Page, --cflags=-KPIC --static  --no-tests  --no-samples

Getting below errors in Crypto module:

** Compiling src/ECKeyImpl.cpp (debug, shared)

    CC -Iinclude -I/poco-1.9.4-all/CppUnit/include -I/poco-1.9.4-all/CppUnit \
/WinTestRunner/include -I/poco-1.9.4-all/Foundation/include -I/poco-1.9.4-all/Encodings/include \ 
-I/poco-1.9.4-all/XML/include -I/poco-1.9.4-all/JSON/include -I/poco-1.9.4-all/Util/include \ 
-I/poco-1.9.4-all/Net/include -I/poco-1.9.4-all/Crypto/include -I/poco-1.9.4-all/NetSSL_OpenSSL/include \ 
-I/poco-1.9.4-all/Data/include -I/poco-1.9.4-all/Data/SQLite/include -I/poco-1.9.4-all/Data/ODBC/include \ 
-I/poco-1.9.4-all/Data/MySQL/include -I/poco-1.9.4-all/Zip/include -I/poco-1.9.4-all/PageCompiler/include \ 
-I/poco-1.9.4-all/PageCompiler/File2Page/include -I/poco-1.9.4-all/MongoDB/include -I/poco-1.9.4-all/Redis/include   \ 
-mt -library=stlport4 -erroff=hidevf -DPOCO_BUILD_HOST='"'vlicsol11sparcbld1'"' \
-DPOCO_TARGET_OSNAME='"'SunOS'"' -DPOCO_TARGET_OSARCH='"'sun4v'"'  -D_REENTRANT \
 -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS -D_POSIX_C_SOURCE=199506L \ 
-D__EXTENSIONS__ -m64 -g -xs -D_DEBUG= -KPIC -c src/ECKeyImpl.cpp \ 
-o /poco-1.9.4-all/Crypto/obj/SunOS/sun4v/debug_shared64/ECKeyImpl.o



"src/ECKeyImpl.cpp", line 85: Error: Could not find a match for Poco::Crypto::EVPPKey::loadKey<Poco::Crypto::EVPPKey::K, Poco::Crypto::EVPPKey::F>(ec_key_st**, extern "C" evp_pkey_st*(__FILE*,evp_pkey_st**,extern "C" int(*)(char*,int,int,void*),void*), extern "C" ec_key_st*(evp_pkey_st*), const std::string, const std::string ) needed in Poco::Crypto::ECKeyImpl::ECKeyImpl(const std::string &, const std::string &, const std::string &).

"src/ECKeyImpl.cpp", line 94: Error: Could not find a match for Poco::Crypto::EVPPKey::loadKey<Poco::Crypto::EVPPKey::K, Poco::Crypto::EVPPKey::F>(ec_key_st**, extern "C" evp_pkey_st*(__FILE*,evp_pkey_st**,extern "C" int(*)(char*,int,int,void*),void*), extern "C" ec_key_st*(evp_pkey_st*), const std::string ) needed in Poco::Crypto::ECKeyImpl::ECKeyImpl(const std::string &, const std::string &, const std::string &).


"src/ECKeyImpl.cpp", line 108: Error: Could not find a match for Poco::Crypto::EVPPKey::loadKey<Poco::Crypto::EVPPKey::K, Poco::Crypto::EVPPKey::F>(ec_key_st**, extern "C" evp_pkey_st*(bio_st*,evp_pkey_st**,extern "C" int(*)(char*,int,int,void*),void*), extern "C" ec_key_st*(evp_pkey_st*), std::istream *, const std::string ) needed in Poco::Crypto::ECKeyImpl::ECKeyImpl(std::istream *, std::istream *, const std::string &).


"src/ECKeyImpl.cpp", line 117: Error: Could not find a match for Poco::Crypto::EVPPKey::loadKey<Poco::Crypto::EVPPKey::K, Poco::Crypto::EVPPKey::F>(ec_key_st**, extern "C" evp_pkey_st*(bio_st*,evp_pkey_st**,extern "C" int(*)(char*,int,int,void*),void*), extern "C" ec_key_st*(evp_pkey_st*), std::istream *) needed in Poco::Crypto::ECKeyImpl::ECKeyImpl(std::istream *, std::istream *, const std::string &).


"src/ECKeyImpl.cpp", line 238: Error: The function "strncmp" must have a prototype.

5 Error(s) detected.

I have browsed entire Internet but didn't find a fix for it. I am also not sure if poco-1.9.4 is compatible with solaris 11 sparc with CC v5.12 or not.

Romeo Ninov
  • 6,538
  • 1
  • 22
  • 31
Jatin
  • 1,857
  • 4
  • 24
  • 37
  • Version 5.12 is Solaris Studio 12.3. If you don't have a support contract for updates and bug fixes, that's 8 years out-of-date. The current version is Developer Studio 12.6. The first thing you need to do is update your compiler. – Andrew Henle Dec 24 '19 at 22:49
  • Thanks @Andrew Henle. I have to build poco on CC v5.12 only. Is there any patch available which I need to download to fix these errors? Please help. I am totally stuck. – Jatin Jan 03 '20 at 08:32
  • Unfortunately, without any Oracle support contract you can't get access to any patches - unless they're available in a later publicly-available release of the compiler. And pulling any patches from later compiler packages is pretty much rolling your own compiler package without any insight into any dependencies. What about not using `stlport4`? Does Poco require that? You might get a response on Oracle's forums at https://community.oracle.com/community/groundbreakers/server_&_storage_systems/application_development_in_c__c++__and_fortran/developer_studio_c_c++_fortran_compilers – Andrew Henle Jan 03 '20 at 15:51
  • (cont) Unfortunately, the Oracle forums may be all but dead. The person who used to be the compiler expert - Steve Clamage - doesn't appear to have been active since Aug 2017. You probably should try a later compiler anyway - just to see if that does work. – Andrew Henle Jan 03 '20 at 15:54

0 Answers0