Tue 26 Feb 2013 02:18:17 PM UTC, original submission:
We are building freetype2 using an out-of-source build, and I'm trying hard to get ft2demos built against it.
First, I have tried:
make TOP_DIR=../freetype-2.4.11 OBJ_DIR=../freetype-2.4.11-amd64
but it fails trying to find 'ftconfig.h'.
If I hack the Makefile to include $(OBJ_DIR) in FT_INCLUDES, it compiles fine but fails to find libtool for linking:
make: ../freetype-2.4.11/builds/unix/libtool: Command not found
Looking at the Makefile, it seems that OBJ_BUILD is used to find it (and the includes), so I actually have to set both OBJ_DIR and OBJ_BUILD:
make TOP_DIR=../freetype-2.4.11 OBJ_{BUILD,DIR}=../freetype-2.4.11-amd64
It compiles some of the demos fine but then fail to find libtool again, for grblit.lo:
/bin/sh: 1: ../freetype-2.4.11/builds/unix/libtool: not found
Looking further, it seems that OBJ_BUILD defaults to BUILD_DIR. If I set BUILD_DIR instead of it:
make TOP_DIR=../freetype-2.4.11 {OBJ_DIR,BUILD_DIR}=../freetype-2.4.11-amd64
demos finally build.
After the long story, my question is: does it have to be that hard? Could you please consider making building demos against out-of-source build simpler, or at least documenting the way of doing it?
|