I did forget to mention one additional thing that I had to do, and to ask a related question.
Once I built freetype2 using the FREETYPE2_STATIC directive, I also had to add this to podofo_static (in the preprocessor definitions section). I manually edited the solution generated by cmake to add this. What is the correct way to have cmake add FREETYPE2_STATIC to the preprocessor definitions for podofo_static? -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sargrad, Dave Sent: Wednesday, November 07, 2007 12:44 PM To: Craig Ringer Cc: [email protected] Subject: Re: [Podofo-users] trying to build podofo using visual studio Yay, Yay, Yay! I finally have what seems like a clean podofo build/link/execute. Instead of using the pre-built freetype I built my own. The key to this build was the "inconsistent dll linkage" warnings that were visible in the freetype build. I searched around the freetype code for a bit, and decided to apply the following precompiler directive: FREETYPE2_STATIC This eliminated the FREETYPE2 warnings, and as well it eliminated the podofo linker failures. I just now, for the first time, hit a break point in the PoDoFo ParserTest entry point (main). Now for the real fun of trying to understand what podofo is all about. My initial goal with PDF handling will be to develop a renderer within the graphics environment that we are using to develop our application suite (Ogre3D). Ogre3D is a renderer that wraps Direct3D and OpenGL. Any suggestions relative to the rapid prototype of a PDF viewer would be appreciated. The document viewer is simply a starting point relative to my goals relative to PDF. I have joined the freetype forum and will send them a question relative to the inconsistencies in the generation of a shared library. I'll let you know what I hear back. -----Original Message----- From: Craig Ringer [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 07, 2007 12:02 PM To: Sargrad, Dave Cc: [email protected] Subject: Re: [Podofo-users] trying to build podofo using visual studio Sargrad, Dave wrote: > > Well, Not sure what else to try. I've simply copied the > libfreetype.dll.a to libfreetype.lib. This seems to compile now. I did > some google searches and see that I'm not alone in not being able to > find libfreetype.a in the freetype distribution. I'm beginning to think that the Gnuwin32 folks have changed how they build freetype. The old one used to work fine with VC++, but it seems entirely possible that this build may not. Alternately, perhaps VC++ 2008 is less tolerant of using GCC archives than 2005 was. Either way things aren't behaving well right now. I'm having some issues myself with my current build - but I *am* trying to get things up and running on Vista for the first time. "Hello world" works but not much else does - I'm seeing DEP crashes in CRT startup for both release and debug builds. Yay. Looking into it. > The following is my complete build log. There are a lot of compiler > warnings and there is also a strange linker message : > "libfreetype.lib(d000098.o) : warning LNK4078: multiple '.text' > sections found with different attributes (E0000020)" This tells me > that simply copying libfreetype.dll.a to libfreetype.lib is probably > not the best thing to be doing. Probably not, no. > The compiler warning that also leaves me concerned is: warning C4251: > 'PoDoFo::PdfError::m_callStack' : class 'std::deque<_Ty>' needs to > have dll-interface to be used by clients of class 'PoDoFo::PdfError' So you're building PoDoFo as a DLL? > 1>Both PODOFO_BUILD_SHARED and PODOFO_BUILD_STATIC set > 1> so disabling static library generation (CMake version < 2.5) Yep. Did you try a static library? > 3>PdfXRefStream.cpp > 3>c:\development\build\podofo\src\PdfError.h(342) : warning C4251: > 'PoDoFo::PdfError::m_callStack' : class 'std::deque<_Ty>' needs to > have dll-interface to be used by clients of class 'PoDoFo::PdfError' > 3> with > 3> [ > 3> _Ty=PoDoFo::PdfErrorInfo > 3> ] These warnings are new with VC++ 2008. They may indeed indicate a real issue - perhaps there were code generation changes in VC++ 2008 that make this more of an issue. At this point I recommend building PoDoFo as a static library as per the README. I will change the default in CMake right now. I'm also testing some changes to the CMake dependency locator files that'll make things a bit nicer when you're building your own custom libraries. Especially since the GnuWin32 folks are mucking with things. -- Craig Ringer ------------------------------------------------------------------------ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Podofo-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/podofo-users ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Podofo-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/podofo-users
