Re: [Podofo-users] Getting Segmentation fault when trying to access PdfVecObjects
Hello Georg, hello all, > On 10 May 2018 at 19:28 Georg Funk wrote: > > > Hi Joerg, > > thanks for this hint. > > I thought maybe I'm misusing PdfObject::Reference() and > PdfObject::GetReference() in my code This could explain the null > pointer. > that could also be a problem, however GetObject() returning NULL should mean that no object with the reference numbers given to the method was found in the PdfDocument or PdfVecObjects your PdfObject belongs to, so please check if this is the case (no such object exists). Only if it isn't, you could have found a bug in PoDoFo. > I want to get an object's Reference number by calling > PdfObject::Reference() and get a pointer to a eventually existing > indirect object by calling PdfObject::GetReference(). > > Is this the correct use case? > Only the former is correct, whereas PdfObject::GetReference() is inherited from PdfVariant and throws a PdfError exception if IsReference() returns false, so it is only for "converting" (de-capsulating) a reference in PdfObject form to PdfReference (returns a C++ reference to a PdfReference object, no pointer). > Thanks in advance! > > Georg > > Hope this helps. Best regards, mabri -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Podofo-users mailing list Podofo-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/podofo-users
Re: [Podofo-users] build error
On Tue, May 15, 2018 at 12:02:30PM +0200, M. Froese wrote: > cmake -G "Visual Studio 15 2017" .\src > -DCMAKE_INCLUDE_PATH="%FTDIR%\include;%JPEGDIR%\include;%JPEGDIR%;%ZLIBDIR%\include" This tells cmake to configure the src directory, not the current directory. Joerg -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Podofo-users mailing list Podofo-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/podofo-users
[Podofo-users] build error
hi everyone, i have downloaded the latest podofo-0.9.6-rc1 and want to build it on a win10 machine using the visual studio 2017 command prompt. i have cmake 3.11.1 and all the nescessary libs installed/built. i created a build.cmd as described in the readme file, first in an empty subdirectory, then after the same error in the podofo root dir: del cmakecache.txt set FTDIR=C:\ecworks_mep\freetype-2.8.1 set FTLIBDIR=C:\ecworks_mep\freetype-2.8.1\objs set JPEGDIR=C:\ecworks_mep\jpeg-9b set ZLIBDIR=C:\ecworks_mep\zlib-1.2.11 cmake -G "Visual Studio 15 2017" .\src -DCMAKE_INCLUDE_PATH="%FTDIR%\include;%JPEGDIR%\include;%JPEGDIR%;%ZLIBDIR%\include" the command output shows: C:\ecworks_mep\podofo-0.9.6-rc1>build.cmd C:\ecworks_mep\podofo-0.9.6-rc1>del cmakecache.txt C:\ecworks_mep\podofo-0.9.6-rc1>set FTDIR=C:\ecworks_mep\freetype-2.8.1 C:\ecworks_mep\podofo-0.9.6-rc1>set FTLIBDIR=C:\ecworks_mep\freetype-2.8.1\objs C:\ecworks_mep\podofo-0.9.6-rc1>set JPEGDIR=C:\ecworks_mep\jpeg-9b C:\ecworks_mep\podofo-0.9.6-rc1>set ZLIBDIR=C:\ecworks_mep\zlib-1.2.11 C:\ecworks_mep\podofo-0.9.6-rc1>cmake -G "Visual Studio 15 2017" .\src -DCMAKE_INCLUDE_PATH="C:\ecworks_mep\freetype-2.8.1\include;C:\ecworks_mep\jpeg-9b\include;C:\ecworks_mep\jpeg-9b;C:\ecworks_mep\zlib-1.2.11\include" -- The C compiler identification is MSVC 19.14.26428.1 -- The CXX compiler identification is MSVC 19.14.26428.1 -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Enterprise/VC/Tools/MSVC/14.14.26428/bin/Hostx86/x86/cl.exe -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Enterprise/VC/Tools/MSVC/14.14.26428/bin/Hostx86/x86/cl.exe -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Enterprise/VC/Tools/MSVC/14.14.26428/bin/Hostx86/x86/cl.exe -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Enterprise/VC/Tools/MSVC/14.14.26428/bin/Hostx86/x86/cl.exe -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:4 (MESSAGE): Run cmake on the CMakeLists.txt in the project root, not the one in the 'src' directory. You will need to delete CMakeCache.txt from the current directory. -- Configuring incomplete, errors occurred! See also "C:/ecworks_mep/podofo-0.9.6-rc1/CMakeFiles/CMakeOutput.log". this output log does not show any errors, all the entries end with "0 warnings, 0 errors". i do run cmake in the project root, so what is wrong? thank you! -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Podofo-users mailing list Podofo-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/podofo-users