Date: Sat, 06 Oct 2018 13:29:38 +0000 From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 231998] security/cryptopp: undefined reference to `CryptoPP::AlignedDeallocate(void*)' Message-ID: <bug-231998-7788@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D231998 Bug ID: 231998 Summary: security/cryptopp: undefined reference to `CryptoPP::AlignedDeallocate(void*)' Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Individual Port(s) Assignee: jhale@FreeBSD.org Reporter: andreas.sommer87@googlemail.com Flags: maintainer-feedback?(jhale@FreeBSD.org) Assignee: jhale@FreeBSD.org Created attachment 197832 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D197832&action= =3Dedit cryptopp 7.0.0 build log on 2018Q4 / FreeBSD 11.2 amd64 By default, the SIMD option is off, resulting in disabling certain features: c++ -O2 -pipe -fstack-protector -fno-strict-aliasing -std=3Dc++11 -stdlib= =3Dlibc++ -Wno-deprecated-declarations -fPIC -DNDEBUG -DCRYPTOPP_DISABLE_ASM -DCRYPTOPP_DISABLE_SSE2 -DCRYPTOPP_DISABLE_SSSE3 -DCRYPTOPP_DISABLE_SSE4 -pthread -pipe -c misc.cpp Thus, the `AlignedDeallocate` function does not get compiled. Trying to use the shared object with `-lcryptopp` results in the above link= er error because `config.h` determines enabled features by the `CRYPTOPP_DISABLE_*` macros. In this case: #if (CRYPTOPP_BOOL_X86 || CRYPTOPP_BOOL_X32 || CRYPTOPP_BOOL_X64 || CRYPTOPP_BOOL_PPC32 || CRYPTOPP_BOOL_PPC64) && !defined(CRYPTOPP_DISABLE_AS= M) #define CRYPTOPP_BOOL_ALIGN16 1 #else #define CRYPTOPP_BOOL_ALIGN16 0 #endif So a program linking against libcryptopp will think that CRYPTOPP_BOOL_ALIGN16=3D1 while it was actually compiled (using default opt= ion) with CRYPTOPP_BOOL_ALIGN16=3D0, leading to the missing function. Not sure how to approach this. Maybe write the chosen `CRYPTOPP_DISABLE_*` = into the installed `config.h`?! --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-231998-7788>