Skip to content
Snippets Groups Projects
Commit f4c8476f authored by Werner Lemberg's avatar Werner Lemberg
Browse files

Make ft2demos support a separate build directory.

* Makefile (have_makefile): New variable.  Set if the build
directory is the same as the source directory.
(GRAPH_DIR): Give full path.
(BIN_DIR, OBJ_DIR): Updated.
(FT_INCLUDES): Include $(OBJ_BUILD).
(LINK) <unix>: Fix path to `libtool'.

* README: Updated.
parent 52285249
No related branches found
No related tags found
No related merge requests found
2005-02-12 Werner Lemberg <wl@gnu.org>
Make ft2demos support a separate build directory.
* Makefile (have_makefile): New variable. Set if the build
directory is the same as the source directory.
(GRAPH_DIR): Give full path.
(BIN_DIR, OBJ_DIR): Updated.
(FT_INCLUDES): Include $(OBJ_BUILD).
(LINK) <unix>: Fix path to `libtool'.
* README: Updated.
2004-12-15 Werner Lemberg <wl@gnu.org>
* src/ftcommon.i (glyph_to_bitmap): Don't convert 1bpp bitmaps.
......
......@@ -29,8 +29,8 @@ endif
######################################################################
#
# MY_CONFIG_MK points to the current `config.mk' to use. It is
# defined by default as $(TOP_DIR)/config.mk.
# CONFIG_MK points to the current `config.mk' to use. It is defined
# by default as $(TOP_DIR)/config.mk.
#
ifndef CONFIG_MK
PROJECT := freetype
......@@ -64,6 +64,7 @@ else
#
include $(CONFIG_MK)
have_makefile := $(strip $(wildcard Makefile))
####################################################################
#
......@@ -73,14 +74,24 @@ else
# without absolute paths libtool fails
TOP_DIR := $(shell cd $(TOP_DIR); pwd)
TOP_DIR_2 := $(shell cd $(TOP_DIR_2); pwd)
BIN_DIR := $(TOP_DIR_2)/bin
OBJ_DIR := $(TOP_DIR_2)/obj
ifneq ($(have_makefile),)
BIN_DIR := $(TOP_DIR_2)/bin
OBJ_DIR := $(TOP_DIR_2)/obj
else
BIN_DIR := .
OBJ_DIR := .
endif
else
BIN_DIR := bin
OBJ_DIR := obj
ifneq ($(have_makefile),)
BIN_DIR := bin
OBJ_DIR := obj
else
BIN_DIR := .
OBJ_DIR := .
endif
endif
GRAPH_DIR := graph
GRAPH_DIR := $(TOP_DIR_2)/graph
ifeq ($(TOP_DIR),..)
SRC_DIR := src
......@@ -88,7 +99,7 @@ else
SRC_DIR := $(TOP_DIR_2)/src
endif
FT_INCLUDES := $(BUILD_DIR) $(TOP_DIR)/include $(SRC_DIR)
FT_INCLUDES := $(OBJ_BUILD) $(BUILD_DIR) $(TOP_DIR)/include $(SRC_DIR)
COMPILE = $(CC) $(CFLAGS) $(INCLUDES:%=$I%)
......@@ -109,7 +120,7 @@ else
#
ifeq ($(PLATFORM),unix)
CC = $(CCraw)
LINK = $(subst /,$(SEP),$(BUILD_DIR)/libtool) --mode=link $(CC) \
LINK = $(subst /,$(SEP),$(OBJ_BUILD)/libtool) --mode=link $(CC) \
$T$(subst /,$(COMPILER_SEP),$@ $< $(LDFLAGS) $(FTLIB) $(EFENCE))
else
ifeq ($(PLATFORM),unixdev)
......
This package contains example programs for the FreeType 2 library.
WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
The Makefile and Jamfile contained in this directory assume that the
......@@ -20,7 +23,11 @@ WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
BeOS, Mac, and OS/2. The build system should automatically detect
which driver to use based on the current platform.
UNIX USERS:
UNIX USERS
==========
X11 issues
----------
When building the demos, the build system tries to detect your X11
path by looking for the patterns `X11/bin', `X11R6/bin', and
......@@ -34,3 +41,17 @@ WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
If you don't have X11 at all, fix the definition of the EXES
variable as described in the top-level Makefile.
Using a different build directory
---------------------------------
If the `configure' script of the FreeType 2 library is run from a
separate build directory, it creates a dummy Makefile which sets
some variables before including the top-level Makefile of the
source directory. This dummy Makefile can also be used for the
ft2demos package to be compiled in a different build directory:
make FT2DEMOS=1 -f /path/to/freetype2/build-dir/Makefile
If necessary, adapt the `TOP_DIR_2' variable to make it point to
the ft2demos source directory.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment