podofo-0.9.7 FTBFS on OS X
A PDF parsing, modification and creation library.
Brought to you by:
domseichter
0.9.6 built fine (all dependencies supplied by fink), but 0.9.7:
[ 4%] Building CXX object src/podofo/CMakeFiles/podofo_shared.dir/base/PdfDate.cpp.o cd /sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/build/src/podofo && /sw/var/lib/fink/path-prefix-clang/c++ -Dpodofo_shared_EXPORTS -I/sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/build -I/sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/src -I/sw/include -I/sw/include/cppunit -I/sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/src/podofo -I/sw/include/freetype2 -I/sw/lib/fontconfig2/include -MD -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -mmacosx-version-min=10.13 -fPIC -DBUILDING_PODOFO -o CMakeFiles/podofo_shared.dir/base/PdfDate.cpp.o -c /sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/src/podofo/base/PdfDate.cpp /sw/build.build/podofo0.9.7-shlibs-0.9.7-1/podofo-0.9.7/src/podofo/base/PdfDate.cpp:199:18: error: expected ';' at end of declaration struct tm _tm{}; ^ ; 1 error generated.
This is on OS X 10.13, using Apple LLVM version 10.0.0 (clang-1000.11.45.5)
Same on 10.14.6 in a Homebrew environment with Apple clang version 11.0.0 (clang-1100.0.33.8). Trunk [r2033].
Related
Commit: [r2033]
Telling CMake to use a C++11 compiler seems to work. I don't know if this is the right way to do this or the right place to put it.
I had already added that flag for test/unit/CMakeLists.txt (required for recent cppunit versions (see https://sourceforge.net/p/podofo/mailman/podofo-users/thread/1501515201.2032.64.camel%40litePDF.cz) via the more generic ADD_DEFINITIONS() function, so a more specific tool like the CXX_STANDARD variables seems better already.