2000-09-16 00:42:06 +02:00
|
|
|
#
|
|
|
|
# FreeType 2 configuration rules templates for Unix + configure
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2017-01-04 20:16:34 +01:00
|
|
|
# Copyright 1996-2017 by
|
2000-09-16 00:42:06 +02:00
|
|
|
# David Turner, Robert Wilhelm, and Werner Lemberg.
|
|
|
|
#
|
|
|
|
# This file is part of the FreeType project, and may only be used, modified,
|
|
|
|
# and distributed under the terms of the FreeType project license,
|
|
|
|
# LICENSE.TXT. By continuing to use, modify, or distribute this file you
|
|
|
|
# indicate that you have read the license and understand and accept it
|
|
|
|
# fully.
|
|
|
|
|
2013-03-21 19:58:40 +01:00
|
|
|
SHELL := @SHELL@
|
2000-09-16 00:42:06 +02:00
|
|
|
|
2002-06-14 10:09:25 +02:00
|
|
|
TOP_DIR := $(shell cd $(TOP_DIR); pwd)
|
2000-09-16 00:42:06 +02:00
|
|
|
|
2013-02-08 12:49:41 +01:00
|
|
|
DELETE := rm -f
|
Another adjustment to header locations.
This change is a result of a discussion thread on freetype-devel
http://lists.nongnu.org/archive/html/freetype-devel/2015-06/msg00041.html
Re-introduce the `freetype2' subdirectory for all FreeType header
files after installation, and rename the `freetype2' subdirectory in
the git repository to `freetype'.
* include/freetype2: Renamed to...
* include/freetype: This.
* CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
PRIVATE_HEADERS): Updated.
Update creation of `ftconfig.h'.
Install generated `ftconfig.h'.
* Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
* builds/amiga/include/config/ftconfig.h, builds/freetype.mk
(PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
builds/unix/freetype2.in: Updated.
* builds/unix/freetype-config.in: Updated.
* builds/unix/configure.raw: Don't check for `rmdir'.
* builds/unix/unix-def.in (DELDIR): Use `rm -rf', which is portable
according to the autoconf info manual.
* builds/unix/install.mk (install, uninstall,
distclean_project_unix): Update and simplify.
* builds/wince/*, builds/windows/*: Updated.
* devel/ft2build.h, include/ft2build.h: Updated.
* include/freetype2/config/ftheader.h,
include/freetype2/internal/ftserv.h,
include/freetype2/internal/internal.h: Update all header file
macros.
* src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
* docs/*: Updated.
2015-06-25 13:04:57 +02:00
|
|
|
DELDIR := rm -rf
|
2013-02-08 12:49:41 +01:00
|
|
|
CAT := cat
|
|
|
|
SEP := /
|
2002-05-05 12:57:06 +02:00
|
|
|
|
|
|
|
# this is used for `make distclean' and `make install'
|
2006-02-01 08:54:07 +01:00
|
|
|
OBJ_BUILD ?= $(BUILD_DIR)
|
2000-09-16 00:42:06 +02:00
|
|
|
|
|
|
|
# don't use `:=' here since the path stuff will be included after this file
|
|
|
|
#
|
|
|
|
FTSYS_SRC = @FTSYS_SRC@
|
|
|
|
|
2000-11-11 09:29:17 +01:00
|
|
|
INSTALL := @INSTALL@
|
|
|
|
INSTALL_DATA := @INSTALL_DATA@
|
|
|
|
INSTALL_PROGRAM := @INSTALL_PROGRAM@
|
|
|
|
INSTALL_SCRIPT := @INSTALL_SCRIPT@
|
2015-09-13 23:53:16 +02:00
|
|
|
MKINSTALLDIRS := @MKDIR_P@
|
2000-09-16 00:42:06 +02:00
|
|
|
|
2014-03-01 12:48:07 +01:00
|
|
|
CLEAN += $(OBJ_BUILD)/freetype-config \
|
|
|
|
$(OBJ_BUILD)/freetype2.pc
|
2014-02-12 23:27:41 +01:00
|
|
|
|
2014-03-01 12:48:07 +01:00
|
|
|
DISTCLEAN += $(OBJ_BUILD)/config.cache \
|
|
|
|
$(OBJ_BUILD)/config.log \
|
|
|
|
$(OBJ_BUILD)/config.status \
|
|
|
|
$(OBJ_BUILD)/unix-def.mk \
|
|
|
|
$(OBJ_BUILD)/unix-cc.mk \
|
|
|
|
$(OBJ_BUILD)/ftconfig.h \
|
|
|
|
$(LIBTOOL) \
|
2002-05-05 12:57:06 +02:00
|
|
|
$(OBJ_BUILD)/Makefile
|
2000-09-16 00:42:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
# Standard installation variables.
|
|
|
|
#
|
|
|
|
prefix := @prefix@
|
|
|
|
exec_prefix := @exec_prefix@
|
|
|
|
libdir := @libdir@
|
|
|
|
bindir := @bindir@
|
|
|
|
includedir := @includedir@
|
2006-04-29 09:53:40 +02:00
|
|
|
datarootdir := @datarootdir@
|
2002-09-04 21:58:47 +02:00
|
|
|
datadir := @datadir@
|
2014-01-06 07:53:10 +01:00
|
|
|
mandir := @mandir@
|
2000-09-16 00:42:06 +02:00
|
|
|
|
|
|
|
version_info := @version_info@
|
|
|
|
|
2013-02-08 12:49:41 +01:00
|
|
|
# Variables needed for `freetype-config' and `freetype.pc'.
|
|
|
|
#
|
2017-06-20 12:24:05 +02:00
|
|
|
PKG_CONFIG := @PKG_CONFIG@
|
Rewrite library option handling in `configure'; improve `freetype-config'.
o Introduce `auto' value for `--with-XXX' library options; this is
now the default.
o First use `pkg-config' for library detection, then fall back to
other tests.
* builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
--with-harfbuzz): Rewrite.
Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
variables to collect data for `freetype2.pc' and `freetype-config'.
(FT2_EXTRA_LIBS): Renamed to ...
(ft2_extra_libs): This since it gets no longer substituted.
(REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
New output variables, replacing `XXX_PKG' and `LIBXXX'.
Add notice at the end of `configure' showing the library
configuration.
* builds/unix/freetype-config.in (--static): New command line
option.
(libs): Updated.
(staticlibs): New variable, to be used if `--static' is given.
* builds/doc/freetype-config.1: Document `--static'.
* builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
2014-03-03 07:13:45 +01:00
|
|
|
REQUIRES_PRIVATE := @REQUIRES_PRIVATE@
|
|
|
|
LIBS_PRIVATE := @LIBS_PRIVATE@
|
|
|
|
LIBSSTATIC_CONFIG := @LIBSSTATIC_CONFIG@
|
2013-02-08 12:49:41 +01:00
|
|
|
build_libtool_libs := @build_libtool_libs@
|
|
|
|
ft_version := @ft_version@
|
2000-09-16 00:42:06 +02:00
|
|
|
|
|
|
|
# The directory where all library files are placed.
|
|
|
|
#
|
2000-09-22 23:23:29 +02:00
|
|
|
# By default, this is the same as $(OBJ_DIR); however, this can be changed
|
2000-09-16 00:42:06 +02:00
|
|
|
# to suit particular needs.
|
|
|
|
#
|
|
|
|
LIB_DIR := $(OBJ_DIR)
|
|
|
|
|
2008-09-30 18:21:07 +02:00
|
|
|
# The BASE_SRC macro lists all source files that should be included in
|
2008-10-01 06:41:46 +02:00
|
|
|
# src/base/ftbase.c. When configure sets up CFLAGS to build ftmac.c,
|
2008-09-30 18:21:07 +02:00
|
|
|
# ftmac.c should be added to BASE_SRC.
|
|
|
|
ftmac_c := @ftmac_c@
|
2000-09-16 00:42:06 +02:00
|
|
|
|
2002-12-23 23:40:21 +01:00
|
|
|
# The SYSTEM_ZLIB macro is defined if the user wishes to link dynamically
|
|
|
|
# with its system wide zlib. If SYSTEM_ZLIB is 'yes', the zlib part of the
|
2002-12-16 22:51:24 +01:00
|
|
|
# ftgzip module is not compiled in.
|
|
|
|
SYSTEM_ZLIB := @SYSTEM_ZLIB@
|
|
|
|
|
|
|
|
|
2000-09-22 23:23:29 +02:00
|
|
|
# The NO_OUTPUT macro is appended to command lines in order to ignore
|
|
|
|
# the output of some programs.
|
2000-09-16 01:47:42 +02:00
|
|
|
#
|
|
|
|
NO_OUTPUT := 2> /dev/null
|
2000-09-16 00:42:06 +02:00
|
|
|
|
2003-06-09 06:46:30 +02:00
|
|
|
|
2013-02-08 12:49:41 +01:00
|
|
|
# To support calls like
|
|
|
|
#
|
|
|
|
# configure --includedir='${libdir}'/freetype2/include
|
|
|
|
#
|
|
|
|
# we generate `freetype-config' and `freetype.pc' at compile time so that
|
|
|
|
# those variables are properly expanded.
|
|
|
|
|
|
|
|
$(OBJ_BUILD)/freetype-config: $(TOP_DIR)/builds/unix/freetype-config.in
|
|
|
|
rm -f $@ $@.tmp
|
2014-03-24 19:45:03 +01:00
|
|
|
sed -e 's|%LIBSSTATIC_CONFIG%|$(LIBSSTATIC_CONFIG)|' \
|
2017-06-20 12:24:05 +02:00
|
|
|
-e 's|%PKG_CONFIG%|$(PKG_CONFIG)|' \
|
2013-02-08 12:49:41 +01:00
|
|
|
-e 's|%build_libtool_libs%|$(build_libtool_libs)|' \
|
Rewrite library option handling in `configure'; improve `freetype-config'.
o Introduce `auto' value for `--with-XXX' library options; this is
now the default.
o First use `pkg-config' for library detection, then fall back to
other tests.
* builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
--with-harfbuzz): Rewrite.
Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
variables to collect data for `freetype2.pc' and `freetype-config'.
(FT2_EXTRA_LIBS): Renamed to ...
(ft2_extra_libs): This since it gets no longer substituted.
(REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
New output variables, replacing `XXX_PKG' and `LIBXXX'.
Add notice at the end of `configure' showing the library
configuration.
* builds/unix/freetype-config.in (--static): New command line
option.
(libs): Updated.
(staticlibs): New variable, to be used if `--static' is given.
* builds/doc/freetype-config.1: Document `--static'.
* builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
2014-03-03 07:13:45 +01:00
|
|
|
-e 's|%exec_prefix%|$(exec_prefix)|' \
|
|
|
|
-e 's|%ft_version%|$(ft_version)|' \
|
|
|
|
-e 's|%includedir%|$(includedir)|' \
|
|
|
|
-e 's|%libdir%|$(libdir)|' \
|
|
|
|
-e 's|%prefix%|$(prefix)|' \
|
|
|
|
$< \
|
2013-02-08 12:49:41 +01:00
|
|
|
> $@.tmp
|
|
|
|
chmod +x $@.tmp
|
2017-02-04 16:08:08 +01:00
|
|
|
chmod go-w $@.tmp
|
2013-02-08 12:49:41 +01:00
|
|
|
mv $@.tmp $@
|
|
|
|
|
2014-03-27 17:38:23 +01:00
|
|
|
# To support directory names with spaces (as might easily happen on Windows
|
|
|
|
# platforms), the right solution would be to surround the pkg-variables in
|
|
|
|
# `freetype2.pc' with double quotes. However, doing so ironically disables
|
|
|
|
# the prefix override mechanism especially written for Windows. This is a
|
|
|
|
# bug in pkg-config version 0.28 and earlier.
|
|
|
|
#
|
|
|
|
# For this reason, we escape spaces with backslashes.
|
|
|
|
|
|
|
|
exec_prefix_x := $(subst $(space),\\$(space),$(exec_prefix))
|
|
|
|
includedir_x := $(subst $(space),\\$(space),$(includedir))
|
|
|
|
libdir_x := $(subst $(space),\\$(space),$(libdir))
|
|
|
|
prefix_x := $(subst $(space),\\$(space),$(prefix))
|
|
|
|
|
2013-02-08 12:49:41 +01:00
|
|
|
$(OBJ_BUILD)/freetype2.pc: $(TOP_DIR)/builds/unix/freetype2.in
|
|
|
|
rm -f $@ $@.tmp
|
Rewrite library option handling in `configure'; improve `freetype-config'.
o Introduce `auto' value for `--with-XXX' library options; this is
now the default.
o First use `pkg-config' for library detection, then fall back to
other tests.
* builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
--with-harfbuzz): Rewrite.
Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
variables to collect data for `freetype2.pc' and `freetype-config'.
(FT2_EXTRA_LIBS): Renamed to ...
(ft2_extra_libs): This since it gets no longer substituted.
(REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
New output variables, replacing `XXX_PKG' and `LIBXXX'.
Add notice at the end of `configure' showing the library
configuration.
* builds/unix/freetype-config.in (--static): New command line
option.
(libs): Updated.
(staticlibs): New variable, to be used if `--static' is given.
* builds/doc/freetype-config.1: Document `--static'.
* builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
2014-03-03 07:13:45 +01:00
|
|
|
sed -e 's|%REQUIRES_PRIVATE%|$(REQUIRES_PRIVATE)|' \
|
|
|
|
-e 's|%LIBS_PRIVATE%|$(LIBS_PRIVATE)|' \
|
2013-02-08 12:49:41 +01:00
|
|
|
-e 's|%build_libtool_libs%|$(build_libtool_libs)|' \
|
2014-03-27 17:38:23 +01:00
|
|
|
-e 's|%exec_prefix%|$(exec_prefix_x)|' \
|
Rewrite library option handling in `configure'; improve `freetype-config'.
o Introduce `auto' value for `--with-XXX' library options; this is
now the default.
o First use `pkg-config' for library detection, then fall back to
other tests.
* builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
--with-harfbuzz): Rewrite.
Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
variables to collect data for `freetype2.pc' and `freetype-config'.
(FT2_EXTRA_LIBS): Renamed to ...
(ft2_extra_libs): This since it gets no longer substituted.
(REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
New output variables, replacing `XXX_PKG' and `LIBXXX'.
Add notice at the end of `configure' showing the library
configuration.
* builds/unix/freetype-config.in (--static): New command line
option.
(libs): Updated.
(staticlibs): New variable, to be used if `--static' is given.
* builds/doc/freetype-config.1: Document `--static'.
* builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
2014-03-03 07:13:45 +01:00
|
|
|
-e 's|%ft_version%|$(ft_version)|' \
|
2014-03-27 17:38:23 +01:00
|
|
|
-e 's|%includedir%|$(includedir_x)|' \
|
|
|
|
-e 's|%libdir%|$(libdir_x)|' \
|
|
|
|
-e 's|%prefix%|$(prefix_x)|' \
|
Rewrite library option handling in `configure'; improve `freetype-config'.
o Introduce `auto' value for `--with-XXX' library options; this is
now the default.
o First use `pkg-config' for library detection, then fall back to
other tests.
* builds/unix/configure.raw (--with-zlib, --with-bzip2, --with-png,
--with-harfbuzz): Rewrite.
Use new `xxx_reqpriv', `xxx_libpriv', and `xxx_libstaticconf'
variables to collect data for `freetype2.pc' and `freetype-config'.
(FT2_EXTRA_LIBS): Renamed to ...
(ft2_extra_libs): This since it gets no longer substituted.
(REQUIRES_PRIVATE, LIBS_PRIVATE, LIBS_CONFIG, LIBSSTATIC_CONFIG):
New output variables, replacing `XXX_PKG' and `LIBXXX'.
Add notice at the end of `configure' showing the library
configuration.
* builds/unix/freetype-config.in (--static): New command line
option.
(libs): Updated.
(staticlibs): New variable, to be used if `--static' is given.
* builds/doc/freetype-config.1: Document `--static'.
* builds/unix/freetype2.in, builds/unix/unix-def.in: Updated.
2014-03-03 07:13:45 +01:00
|
|
|
$< \
|
2013-02-08 12:49:41 +01:00
|
|
|
> $@.tmp
|
|
|
|
chmod a-w $@.tmp
|
|
|
|
mv $@.tmp $@
|
|
|
|
|
2016-02-05 18:42:19 +01:00
|
|
|
all install: $(OBJ_BUILD)/freetype-config \
|
2013-02-08 12:49:41 +01:00
|
|
|
$(OBJ_BUILD)/freetype2.pc
|
|
|
|
|
2000-09-16 00:42:06 +02:00
|
|
|
# EOF
|