Re: [AD] [A4.4.1.1SVN] 3 Patch Submissions |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
On 2011-03-13, Edgar <edgarreynaldo@xxxxxxxxxx> wrote:
> Peter Wang wrote:
> > On 2011-03-13, Edgar <edgarreynaldo@xxxxxxxxxx> wrote:
> >
> >> Over the last week or two, I've had a couple problems building
> >> Allegro 4.4.1.1. Here are the 3 patches that fix the problems I was
> >> having.
> >>
> >> 1) CMakeLists.txt.diff, applies to allegro/CMakeLists.txt. Fixes a
> >> problem on Windows with MinGW where the allegro library build was
> >> not being linked with '-pg'.
> >>
> >
> > This looks like a hack. I would prefer to understand why it is needed.
> >
> >
> If the profiling allegro library is not linked with '-pg' then it fails
> with many undefined references to 'mcount'. I just used the variable
> ALLEGRO_LINK_FLAGS since it was already being used in the LINK_FLAGS
> property of the allegro target. If you have a better way to do it, I'm
> all ears.
The question is why CMAKE_EXE_LINKER_FLAGS_PROFILE is not working as it
should. I will take a look at it some time.
> > I'm not sure why zlib.h needs to be included though, but it doesn't
> > really matter.
> >
> > Peter
> >
> Thanks for letting me know. If zlib.h is not included then there are
> errors because of undeclared symbols from zlib.h. loadpng.c only
> includes png.h, and as I said, the latest version (1.5.1) of libpng's
> png.h no longer includes zlib.h.
As far as I remember it should not be necessary as loadpng doesn't
call zlib functions directly.
Peter