2009-11-09 10:38:14 +03:00
|
|
|
# $NetBSD: bsd.x11.mk,v 1.79 2009/11/09 07:38:14 mrg Exp $
|
2003-09-12 11:40:34 +04:00
|
|
|
|
|
|
|
.include <bsd.init.mk>
|
|
|
|
|
2003-09-14 00:10:44 +04:00
|
|
|
BINDIR= ${X11BINDIR}
|
|
|
|
LIBDIR= ${X11USRLIBDIR}
|
|
|
|
MANDIR= ${X11MANDIR}
|
|
|
|
|
2005-03-21 17:10:29 +03:00
|
|
|
COPTS+= -fno-strict-aliasing
|
|
|
|
|
2007-06-07 15:49:17 +04:00
|
|
|
.if defined(USE_SSP) && (${USE_SSP} != "no")
|
|
|
|
CPPFLAGS+= -DNO_ALLOCA
|
|
|
|
.endif
|
|
|
|
|
2003-09-12 11:40:34 +04:00
|
|
|
X11FLAGS.VERSION= -DOSMAJORVERSION=1 -DOSMINORVERSION=6 # XXX
|
|
|
|
|
2003-11-17 08:14:21 +03:00
|
|
|
# THREADS_DEFINES
|
2003-09-12 11:40:34 +04:00
|
|
|
X11FLAGS.THREADS= -DXTHREADS -D_REENTRANT -DXUSE_MTSAFE_API \
|
|
|
|
-DXNO_MTSAFE_PWDAPI
|
|
|
|
|
2003-11-17 08:14:21 +03:00
|
|
|
# CONNECTION_FLAGS
|
Enable IPv6 in XFree86 4.4.0 reachover build. Usage is describe
in "/usr/X11R6/lib/X11/doc/RELNOTES". Note particularly that "tcp",
as in "X -nolisten tcp" or "xhost +tcp/host:0", now means *both*
IP transport protocols. Use "inet" or "inet6", instead, to specify
only one or the other.
XDMCP support for IPv6 -- such as it is -- is disabled, just as
it is in the native, out-of-the-box build. XDM-AUTHORIZATION-1
does not really support IPv6 addresses, in any case. (It is
possible to build "xdm" with -DIPv6, but that presumes support
for IPv6-mapped IPv4 addresses in the default installation, for
one thing, and there are unexplored issues with all that.)
2004-03-27 00:29:54 +03:00
|
|
|
X11FLAGS.CONNECTION= -DTCPCONN -DUNIXCONN -DHAS_STICKY_DIR_BIT \
|
2005-01-10 05:58:58 +03:00
|
|
|
-DHAS_FCHOWN
|
|
|
|
|
|
|
|
.if (${USE_INET6} != "no")
|
|
|
|
X11FLAGS.CONNECTION+= -DIPv6
|
|
|
|
.endif
|
2003-09-12 11:40:34 +04:00
|
|
|
|
2003-11-17 08:14:21 +03:00
|
|
|
# EXT_DEFINES
|
2008-11-10 02:02:28 +03:00
|
|
|
.if ${X11FLAVOUR} == "Xorg"
|
2008-07-29 08:40:14 +04:00
|
|
|
X11FLAGS.BASE_EXTENSION= -DMITMISC -DXTEST -DXTRAP -DXSYNC -DXCMISC \
|
|
|
|
-DXRECORD -DMITSHM -DBIGREQS -DXF86VIDMODE \
|
|
|
|
-DXF86MISC -DDPMSExtension -DEVI \
|
|
|
|
-DSCREENSAVER -DXV -DXVMC -DGLXEXT \
|
2009-06-10 12:28:20 +04:00
|
|
|
-DRES
|
2008-07-29 08:40:14 +04:00
|
|
|
|
|
|
|
X11FLAGS.PERVASIVE_EXTENSION= -DSHAPE -DXINPUT -DXKB -DLBX -DXAPPGROUP \
|
|
|
|
-DXCSECURITY -DTOGCUP -DXF86BIGFONT \
|
|
|
|
-DDPMSExtension -DPIXPRIV -DPANORAMIX \
|
|
|
|
-DRENDER -DRANDR -DXFIXES -DDAMAGE \
|
|
|
|
-DCOMPOSITE -DXEVIE
|
|
|
|
X11FLAGS.EXTENSION= ${X11FLAGS.BASE_EXTENSION} \
|
|
|
|
${X11FLAGS.PERVASIVE_EXTENSION}
|
2008-08-02 08:36:12 +04:00
|
|
|
|
|
|
|
X11FLAGS.DIX= -DHAVE_DIX_CONFIG_H -D_BSD_SOURCE -DHAS_FCHOWN \
|
|
|
|
-DHAS_STICKY_DIR_BIT -D_POSIX_THREAD_SAFE_FUNCTIONS
|
|
|
|
X11INCS.DIX= -I${X11INCSDIR}/freetype2 \
|
|
|
|
-I${X11INCSDIR}/pixman-1 \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/include \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/Xext \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/composite \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/damageext \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/xfixes \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/Xi \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/mi \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/miext/shadow \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/miext/damage \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/render \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/randr \
|
|
|
|
-I$(X11SRCDIR.xorg-server)/fb
|
2008-07-29 08:40:14 +04:00
|
|
|
.else
|
2003-09-12 11:40:34 +04:00
|
|
|
X11FLAGS.EXTENSION= -DMITMISC -DXTEST -DXTRAP -DXSYNC -DXCMISC -DXRECORD \
|
2003-12-20 17:24:29 +03:00
|
|
|
-DMITSHM -DBIGREQS -DXF86MISC -DDBE -DDPMSExtension \
|
|
|
|
-DEVI -DSCREENSAVER -DXV -DXVMC -DGLXEXT \
|
|
|
|
-DGLX_USE_MESA -DFONTCACHE -DRES
|
2008-07-29 08:40:14 +04:00
|
|
|
.endif
|
2003-09-12 11:40:34 +04:00
|
|
|
|
2004-03-04 16:14:57 +03:00
|
|
|
X11FLAGS.DRI= -DGLXEXT -DXF86DRI -DGLX_DIRECT_RENDERING \
|
|
|
|
-DGLX_USE_DLOPEN -DGLX_USE_MESA
|
|
|
|
|
|
|
|
.if ${X11DRI} != "no"
|
|
|
|
X11FLAGS.EXTENSION+= ${X11FLAGS.DRI}
|
|
|
|
.endif
|
|
|
|
|
2003-11-17 08:14:21 +03:00
|
|
|
# ServerDefines
|
2003-12-20 17:24:29 +03:00
|
|
|
X11FLAGS.SERVER= -DSHAPE -DXKB -DLBX -DXAPPGROUP -DXCSECURITY \
|
2003-09-12 11:40:34 +04:00
|
|
|
-DTOGCUP -DXF86BIGFONT -DDPMSExtension -DPIXPRIV \
|
|
|
|
-DPANORAMIX -DRENDER -DRANDR -DGCCUSESGAS \
|
2003-12-20 17:24:29 +03:00
|
|
|
-DAVOID_GLYPHBLT -DSINGLEDEPTH -DXvExtension \
|
|
|
|
-DXFree86Server -DXvMCExtension -DSMART_SCHEDULE \
|
2003-12-23 18:36:45 +03:00
|
|
|
-DBUILDDEBUG -DXResExtension -DNDEBUG
|
|
|
|
|
2003-11-17 08:14:21 +03:00
|
|
|
# OS_DEFINES
|
2004-01-01 15:36:14 +03:00
|
|
|
X11FLAGS.OS_DEFINES= -DDDXOSINIT -DSERVER_LOCK -DDDXOSFATALERROR \
|
2005-11-13 01:57:46 +03:00
|
|
|
-DDDXOSVERRORF -DDDXTIME -DUSB_HID
|
2003-12-20 17:24:29 +03:00
|
|
|
|
2004-01-18 09:38:16 +03:00
|
|
|
.if !(${MACHINE} == "acorn32" || \
|
2009-01-24 20:24:52 +03:00
|
|
|
(${MACHINE} == "alpha" && ${X11FLAVOUR} != "Xorg") || \
|
2004-01-18 09:38:16 +03:00
|
|
|
${MACHINE} == "amiga" || \
|
|
|
|
${MACHINE} == "pmax" || \
|
2004-03-10 19:21:16 +03:00
|
|
|
${MACHINE} == "sun3" || \
|
2004-01-18 09:38:16 +03:00
|
|
|
${MACHINE} == "vax")
|
2003-12-20 17:24:29 +03:00
|
|
|
# EXT_DEFINES
|
|
|
|
X11FLAGS.EXTENSION+= -DXF86VIDMODE
|
|
|
|
|
|
|
|
# ServerDefines
|
2004-01-20 19:40:11 +03:00
|
|
|
X11FLAGS.SERVER+= -DXINPUT -DXFreeXDGA -DXF86VIDMODE
|
2004-01-18 08:43:16 +03:00
|
|
|
.endif
|
2003-12-20 17:24:29 +03:00
|
|
|
|
2004-01-18 11:24:16 +03:00
|
|
|
.if ${MACHINE_ARCH} == "alpha" || \
|
|
|
|
${MACHINE_ARCH} == "sparc64" || \
|
|
|
|
${MACHINE_ARCH} == "x86_64"
|
2003-12-23 14:12:35 +03:00
|
|
|
# ServerDefines
|
|
|
|
X11FLAGS.SERVER+= -D_XSERVER64
|
2004-01-25 05:15:51 +03:00
|
|
|
X11FLAGS.EXTENSION+= -D__GLX_ALIGN64
|
2003-12-23 14:12:35 +03:00
|
|
|
.endif
|
2003-12-20 17:24:29 +03:00
|
|
|
|
2004-01-18 09:38:16 +03:00
|
|
|
.if ${MACHINE} == "amd64" || \
|
|
|
|
${MACHINE} == "cats" || \
|
|
|
|
${MACHINE} == "i386" || \
|
2004-07-13 13:29:45 +04:00
|
|
|
${MACHINE} == "macppc" || \
|
2006-04-17 16:50:51 +04:00
|
|
|
${MACHINE} == "netwinder" || \
|
2008-03-08 13:37:48 +03:00
|
|
|
${MACHINE} == "ofppc" || \
|
2005-03-26 13:31:51 +03:00
|
|
|
${MACHINE} == "sgimips" || \
|
2005-10-02 02:51:31 +04:00
|
|
|
${MACHINE} == "sparc64" || \
|
2006-12-21 04:45:32 +03:00
|
|
|
${MACHINE} == "sparc" || \
|
|
|
|
${MACHINE} == "shark"
|
2003-12-20 17:24:29 +03:00
|
|
|
# LOADABLE
|
2005-04-06 12:32:11 +04:00
|
|
|
X11FLAGS.LOADABLE= -DXFree86LOADER -DIN_MODULE -DXFree86Module \
|
|
|
|
-fno-merge-constants
|
2003-12-20 17:24:29 +03:00
|
|
|
.endif
|
2008-07-29 08:40:14 +04:00
|
|
|
|
|
|
|
# XXX FIX ME
|
2008-11-10 02:02:28 +03:00
|
|
|
.if ${X11FLAVOUR} == "Xorg"
|
2008-07-29 08:40:14 +04:00
|
|
|
XVENDORNAMESHORT= '"X.Org"'
|
|
|
|
XVENDORNAME= '"The X.Org Foundation"'
|
2009-11-09 10:38:14 +03:00
|
|
|
XORG_RELEASE= '"Release 1.6.5"'
|
2008-07-29 08:40:14 +04:00
|
|
|
__XKBDEFRULES__= '"xorg"'
|
2008-09-07 17:10:22 +04:00
|
|
|
XLOCALE.DEFINES= -DXLOCALEDIR=\"${X11LIBDIR}/locale\" \
|
|
|
|
-DXLOCALELIBDIR=\"${X11LIBDIR}/locale\"
|
2008-07-29 08:40:14 +04:00
|
|
|
|
|
|
|
# XXX oh yeah, fix me later
|
2009-11-09 10:38:14 +03:00
|
|
|
XORG_VERSION_CURRENT="(((1) * 10000000) + ((6) * 100000) + ((5) * 1000) + 0)"
|
2008-07-29 08:40:14 +04:00
|
|
|
.endif
|
2003-11-17 08:14:21 +03:00
|
|
|
|
2008-09-13 08:28:37 +04:00
|
|
|
PRINT_PACKAGE_VERSION= awk '/^PACKAGE_VERSION=/ { \
|
|
|
|
match($$1, "([0-9]+\\.)+[0-9]+"); \
|
|
|
|
version = substr($$1, RSTART, RLENGTH); \
|
|
|
|
} END { print version }'
|
|
|
|
|
|
|
|
|
2004-02-06 14:52:48 +03:00
|
|
|
# Extract X11VERSION
|
2008-10-20 02:05:19 +04:00
|
|
|
PRINTX11VERSION=${TOOL_AWK} ' \
|
|
|
|
/^\#define XF86_VERSION_MAJOR/ {major = $$3} \
|
2004-02-06 14:52:48 +03:00
|
|
|
/^\#define XF86_VERSION_MINOR/ {minor = $$3} \
|
|
|
|
/^\#define XF86_VERSION_PATCH/ {patch = $$3} \
|
|
|
|
/^\#define XF86_VERSION_SNAP/ {snap = $$3} \
|
|
|
|
END { print "((("major") * 10000000) + (("minor") * 100000) + (("patch") * 1000) + "snap")"}' \
|
|
|
|
${X11SRCDIR.xc}/programs/Xserver/hw/xfree86/xf86Version.h
|
2003-11-17 08:14:21 +03:00
|
|
|
|
2004-03-27 23:16:16 +03:00
|
|
|
# Commandline to convert 'XCOMM' comments and 'XHASH' to '#', among other
|
|
|
|
# things. Transformed from the "CppSedMagic" macro from "Imake.rules".
|
2003-11-17 08:14:21 +03:00
|
|
|
#
|
2008-10-26 02:27:34 +04:00
|
|
|
X11TOOL_UNXCOMM= ${TOOL_SED} -e '/^\# *[0-9][0-9]* *.*$$/d' \
|
2004-03-27 23:16:16 +03:00
|
|
|
-e '/^\#line *[0-9][0-9]* *.*$$/d' \
|
|
|
|
-e '/^[ ]*XCOMM$$/s/XCOMM/\#/' \
|
|
|
|
-e '/^[ ]*XCOMM[^a-zA-Z0-9_]/s/XCOMM/\#/' \
|
|
|
|
-e '/^[ ]*XHASH/s/XHASH/\#/' \
|
|
|
|
-e '/\@\@$$/s/\@\@$$/\\/'
|
2003-09-12 11:40:34 +04:00
|
|
|
|
2003-09-14 00:10:44 +04:00
|
|
|
|
2003-09-12 11:40:34 +04:00
|
|
|
CPPFLAGS+= -DCSRG_BASED -DFUNCPROTO=15 -DNARROWPROTO
|
2003-09-13 04:16:10 +04:00
|
|
|
CPPFLAGS+= -I${DESTDIR}${X11INCDIR}
|
2003-09-12 11:40:34 +04:00
|
|
|
|
2004-04-15 18:48:41 +04:00
|
|
|
.if ${MACHINE_ARCH} == "x86_64"
|
|
|
|
CPPFLAGS+= -D__AMD64__
|
|
|
|
.endif
|
|
|
|
|
2003-09-12 11:40:34 +04:00
|
|
|
LDFLAGS+= -Wl,-rpath-link,${DESTDIR}${X11USRLIBDIR} \
|
|
|
|
-R${X11USRLIBDIR} \
|
|
|
|
-L${DESTDIR}${X11USRLIBDIR}
|
|
|
|
|
2003-09-14 00:10:44 +04:00
|
|
|
|
2003-09-12 11:40:34 +04:00
|
|
|
#
|
|
|
|
# .cpp -> "" handling
|
|
|
|
# CPPSCRIPTS list of files/scripts to run through cpp
|
|
|
|
# CPPSCRIPTFLAGS extra flags to ${CPP}
|
|
|
|
# CPPSCRIPTFLAGS_fn extra flags to ${CPP} for file `fn'
|
|
|
|
#
|
|
|
|
.if defined(CPPSCRIPTS) # {
|
|
|
|
.SUFFIXES: .cpp
|
|
|
|
|
|
|
|
.cpp:
|
2003-10-21 14:01:19 +04:00
|
|
|
${_MKTARGET_CREATE}
|
2003-10-18 19:37:29 +04:00
|
|
|
rm -f ${.TARGET}
|
2003-09-12 11:40:34 +04:00
|
|
|
${CPP} -undef -traditional \
|
|
|
|
${CPPSCRIPTFLAGS_${.TARGET}:U${CPPSCRIPTFLAGS}} \
|
|
|
|
< ${.IMPSRC} | ${X11TOOL_UNXCOMM} > ${.TARGET}
|
|
|
|
|
|
|
|
realall: ${CPPSCRIPTS}
|
|
|
|
|
|
|
|
clean: cleancppscripts
|
2004-01-29 03:02:04 +03:00
|
|
|
cleancppscripts: .PHONY
|
2003-09-12 11:40:34 +04:00
|
|
|
rm -f ${CPPSCRIPTS}
|
|
|
|
.endif # }
|
|
|
|
|
2008-09-13 08:28:37 +04:00
|
|
|
#
|
|
|
|
# X.Org pkgconfig files handling
|
|
|
|
#
|
|
|
|
# PKGCONFIG is expected to contain a list of pkgconfig module names.
|
|
|
|
# They will produce the files <module1>.pc, <module2>.pc, etc, to be
|
|
|
|
# put in X11USRLIBDIR/pkgconfig.
|
|
|
|
#
|
|
|
|
# PKGDIST contains the name of a X11SRCDIR subscript where to find the
|
|
|
|
# source file for the pkgconfig files.
|
|
|
|
#
|
|
|
|
# If PKGDIST is not suitable, a consumer can set PKGDIST.<module> with
|
|
|
|
# the full path to the source file.
|
|
|
|
#
|
|
|
|
# Also, the consumer can use PKGDIST alone, and a PKGCONFIG will be
|
|
|
|
# derived from it. Many times, PKGDIST is capitalized and PKGCONFIG is
|
|
|
|
# the lower case version.
|
|
|
|
#
|
|
|
|
|
|
|
|
.if defined(PKGDIST) && !defined(PKGCONFIG)
|
|
|
|
PKGCONFIG= ${PKGDIST:tl}
|
|
|
|
.endif
|
|
|
|
.if defined(PKGCONFIG)
|
|
|
|
|
|
|
|
.include <bsd.files.mk>
|
|
|
|
|
|
|
|
_PKGCONFIG_FILES= ${PKGCONFIG:C/$/.pc/}
|
|
|
|
|
|
|
|
.PHONY: pkgconfig-install
|
|
|
|
pkgconfig-install:
|
|
|
|
|
|
|
|
realall: ${_PKGCONFIG_FILES:O:u}
|
|
|
|
realinstall: pkgconfig-install
|
|
|
|
|
|
|
|
.for _pkg in ${PKGCONFIG:O:u}
|
|
|
|
PKGDIST.${_pkg}?= ${X11SRCDIR.${PKGDIST:U${_pkg}}}
|
|
|
|
_PKGDEST.${_pkg}= ${DESTDIR}/${X11USRLIBDIR}/pkgconfig/${_pkg}.pc
|
|
|
|
|
|
|
|
.PATH: ${PKGDIST.${_pkg}}
|
|
|
|
|
|
|
|
FILESOWN_${_pkg}.pc= ${BINOWN}
|
|
|
|
FILESGRP_${_pkg}.pc= ${BINGRP}
|
|
|
|
FILESMODE_${_pkg}.pc= ${NONBINMODE}
|
|
|
|
|
|
|
|
${_PKGDEST.${_pkg}}: ${_pkg}.pc __fileinstall
|
|
|
|
pkgconfig-install: ${_PKGDEST.${_pkg}}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
# XXX
|
|
|
|
# The sed script is very, very ugly. What we actually need is a
|
|
|
|
# mknative-xorg script that will generate all the .pc files from
|
|
|
|
# running the autoconfigure script.
|
|
|
|
# And yes, it has to be splitted in two otherwise it's too long
|
|
|
|
# for sed to handle.
|
|
|
|
|
|
|
|
.SUFFIXES: .pc.in .pc
|
|
|
|
.pc.in.pc:
|
|
|
|
${_MKTARGET_CREATE}
|
|
|
|
rm -f ${.TARGET}
|
|
|
|
if [ -n '${PKGCONFIG_VERSION.${.PREFIX}}' ]; then \
|
|
|
|
_pkg_version='${PKGCONFIG_VERSION.${.PREFIX}}'; \
|
|
|
|
else \
|
|
|
|
_pkg_version=$$(${PRINT_PACKAGE_VERSION} \
|
|
|
|
${PKGDIST.${.PREFIX}}/configure); \
|
|
|
|
fi; \
|
2008-09-15 22:21:48 +04:00
|
|
|
${TOOL_SED} \
|
2008-09-13 08:28:37 +04:00
|
|
|
-e "s,@prefix@,${X11ROOTDIR},; \
|
|
|
|
s,@INSTALL_DIR@,${X11ROOTDIR},; \
|
|
|
|
s,@exec_prefix@,\\$$\{prefix\},; \
|
|
|
|
s,@libdir@,\\$$\{prefix\}/lib,; \
|
|
|
|
s,@includedir@,\\$$\{prefix\}/include,; \
|
|
|
|
s,@datarootdir@,\\$$\{prefix\}/share,; \
|
|
|
|
s,@appdefaultdir@,\\$$\{libdir}/X11/app-default,; \
|
|
|
|
s,@MAPDIR@,\\$$\{libdir\}/X11/fonts/util,; \
|
|
|
|
s,@ICONDIR@,\\$$\{datarootdir\}/icons,; \
|
|
|
|
s,@PACKAGE_VERSION@,$${_pkg_version},; \
|
|
|
|
s,@VERSION@,$${_pkg_version},; \
|
|
|
|
s,@COMPOSITEEXT_VERSION@,$${_pkg_version%.*},; \
|
|
|
|
s,@DAMAGEEXT_VERSION@,$${_pkg_version%.*},; \
|
|
|
|
s,@FIXESEXT_VERSION@,$${_pkg_version%.*},; \
|
|
|
|
s,@RANDR_VERSION@,$${_pkg_version%.*},; \
|
|
|
|
s,@RENDER_VERSION@,$${_pkg_version%.*}," \
|
|
|
|
-e "s,@moduledir@,\\$$\{libdir\}/modules,; \
|
|
|
|
s,@sdkdir@,\\$$\{includedir\}/xorg,; \
|
|
|
|
s,@PIXMAN_CFLAGS@,,; \
|
|
|
|
s,@LIB_DIR@,/lib,; \
|
2009-06-11 09:34:22 +04:00
|
|
|
s,@INSTALL_LIB_DIR@,\\$$\{prefix\}/lib,; \
|
|
|
|
s,@INSTALL_INC_DIR@,\\$$\{prefix\}/include,; \
|
2008-09-13 08:28:37 +04:00
|
|
|
s,@XKBPROTO_REQUIRES@,kbproto,; \
|
|
|
|
s,@FREETYPE_REQUIRES@,freetype2,; \
|
|
|
|
s,@EXPAT_LIBS@,-lexpat,; \
|
|
|
|
s,@FREETYPE_LIBS@,-lfreetype,; \
|
|
|
|
s,@DEP_CFLAGS@,,; \
|
|
|
|
s,@DEP_LIBS@,,; \
|
|
|
|
s,@X11_EXTRA_DEPS@,,; \
|
2008-09-15 12:05:19 +04:00
|
|
|
s,@XTHREAD_CFLAGS@,-D_REENTRANT,; \
|
2008-09-13 08:28:37 +04:00
|
|
|
s,@XTHREADLIB@,-lpthread,; \
|
2009-06-11 09:34:22 +04:00
|
|
|
s,@GL_PC_REQ_PRIV@,x11 xext,; \
|
|
|
|
s,@GL_PC_LIB_PRIV@,-lm -lpthread,; \
|
|
|
|
s,@GL_PC_CFLAGS@,,; \
|
2009-06-23 08:40:29 +04:00
|
|
|
s,@GLU_PC_REQ_PRIV@,,; \
|
|
|
|
s,@GLU_PC_LIB_PRIV@,-lGLU,; \
|
|
|
|
s,@GLU_PC_CFLAGS@,,; \
|
|
|
|
s,@GLUT_PC_REQ_PRIV@,gl glu,; \
|
|
|
|
s,@GLUT_PC_LIB_PRIV@,-lglut,; \
|
|
|
|
s,@GLUT_PC_CFLAGS@,,; \
|
|
|
|
s,@abi_ansic@,0.4,; \
|
|
|
|
s,@abi_videodrv@,5.0,; \
|
|
|
|
s,@abi_xinput@,4.0,; \
|
|
|
|
s,@abi_extension@,2.0,; \
|
|
|
|
s,@abi_font@,0.6,; \
|
2008-09-13 08:28:37 +04:00
|
|
|
s,@fchown_define@,-DHAS_FCHOWN,; \
|
|
|
|
s,@sticky_bit_define@,-DHAS_STICKY_DIR_BIT," \
|
2008-09-15 22:21:48 +04:00
|
|
|
-e '/^Libs:/ s%-L\([^ ]*\)%-Wl,-R\1 &%g' \
|
2008-09-13 08:28:37 +04:00
|
|
|
< ${.IMPSRC} > ${.TARGET}.tmp && \
|
|
|
|
mv -f ${.TARGET}.tmp ${.TARGET}
|
|
|
|
|
|
|
|
CLEANFILES+= ${_PKGCONFIG_FILES} ${_PKGCONFIG_FILES:C/$/.tmp/}
|
|
|
|
.endif
|
2003-09-12 11:40:34 +04:00
|
|
|
|
|
|
|
#
|
|
|
|
# APPDEFS (app defaults) handling
|
|
|
|
#
|
|
|
|
.if defined(APPDEFS) # {
|
2004-01-29 03:21:31 +03:00
|
|
|
appdefsinstall:: .PHONY ${APPDEFS:@S@${DESTDIR}${X11LIBDIR}/app-defaults/${S:T:R}@}
|
|
|
|
.PRECIOUS: ${APPDEFS:@S@${DESTDIR}${X11LIBDIR}/app-defaults/${S:T:R}@}
|
2003-09-12 11:40:34 +04:00
|
|
|
|
|
|
|
__appdefinstall: .USE
|
2007-08-06 08:25:57 +04:00
|
|
|
${_MKTARGET_INSTALL}
|
2003-12-08 13:10:46 +03:00
|
|
|
${INSTALL_FILE} -o ${BINOWN} -g ${BINGRP} -m ${NONBINMODE} \
|
2006-03-16 21:43:34 +03:00
|
|
|
${.ALLSRC} ${.TARGET}
|
2003-09-12 11:40:34 +04:00
|
|
|
|
|
|
|
.for S in ${APPDEFS:O:u}
|
|
|
|
${DESTDIR}${X11LIBDIR}/app-defaults/${S:T:R}: ${S} __appdefinstall
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
realinstall: appdefsinstall
|
|
|
|
.endif # }
|
|
|
|
|
|
|
|
|
|
|
|
#
|
|
|
|
# .man page handling
|
|
|
|
#
|
2003-09-14 00:39:45 +04:00
|
|
|
.if (${MKMAN} != "no" && (${MAN:U} != "" || ${PROG:U} != "")) # {
|
2003-09-12 11:40:34 +04:00
|
|
|
cleandir: cleanx11man
|
2004-01-29 03:02:04 +03:00
|
|
|
cleanx11man: .PHONY
|
2003-09-14 00:39:45 +04:00
|
|
|
rm -f ${MAN:U${PROG:D${PROG.1}}}
|
2003-09-12 11:40:34 +04:00
|
|
|
.endif # }
|
|
|
|
|
2008-10-15 03:33:55 +04:00
|
|
|
.SUFFIXES: .man .man.pre .1 .3 .4 .5 .7
|
|
|
|
|
|
|
|
_X11MANTRANSFORM= \
|
|
|
|
__adminmansuffix__ 8 \
|
|
|
|
__apploaddir__ ${X11ROOTDIR}/lib/X11/app-defaults \
|
|
|
|
__appmansuffix__ 1 \
|
|
|
|
__bindir__ ${X11BINDIR} \
|
|
|
|
__drivermansuffix__ 4 \
|
|
|
|
__filemansuffix__ 5 \
|
|
|
|
__LIB_MAN_SUFFIX__ 3 \
|
|
|
|
__libmansuffix__ 3 \
|
|
|
|
__logdir__ /var/log \
|
|
|
|
__mandir__ ${X11MANDIR} \
|
|
|
|
__miscmansuffix__ 7 \
|
|
|
|
__oslibmansuffix__ 3 \
|
|
|
|
__projectroot__ ${X11ROOTDIR} \
|
|
|
|
${X11EXTRAMANTRANSFORMS}
|
|
|
|
|
|
|
|
# Note the escaping trick for _X11MANTRANSFORM using % to replace spaces
|
2008-11-10 02:02:28 +03:00
|
|
|
.if ${X11FLAVOUR} != "Xorg"
|
2008-10-15 03:33:55 +04:00
|
|
|
X11VERSION= "XFree86 4.5.0"
|
|
|
|
X11MANCPP?= yes
|
|
|
|
_X11MANTRANSFORM+= \
|
|
|
|
__vendorversion__ ${X11VERSION:C/ /%/gW}
|
|
|
|
.else
|
|
|
|
XORGVERSION= '"X.Org 7.3nb20081014" "X Version 11"'
|
|
|
|
X11MANCPP?= no
|
|
|
|
_X11MANTRANSFORM+= \
|
|
|
|
__vendorversion__ ${XORGVERSION:C/ /%/gW} \
|
|
|
|
__XCONFIGFILE__ xorg.conf \
|
|
|
|
__xconfigfile__ xorg.conf \
|
|
|
|
__xorgversion__ ${XORGVERSION:C/ /%/gW} \
|
|
|
|
__XSERVERNAME__ Xorg \
|
|
|
|
__xservername__ Xorg
|
|
|
|
.endif
|
|
|
|
|
|
|
|
_X11MANTRANSFORMCMD= ${TOOL_SED} -e 's/\\$$/\\ /' ${.IMPSRC}
|
|
|
|
|
|
|
|
.if ${X11MANCPP} != "no"
|
|
|
|
_X11MANTRANSFORMCMD+= | ${CPP} -undef -traditional
|
|
|
|
. for __def__ __value__ in ${_X11MANTRANSFORM}
|
|
|
|
_X11MANTRANSFORMCMD+= -D${__def__}=${__value__:C/%/ /gW}
|
|
|
|
. endfor
|
|
|
|
.else
|
|
|
|
_X11MANTRANSFORMCMD+= | ${TOOL_SED}
|
|
|
|
. for __def__ __value__ in ${_X11MANTRANSFORM}
|
|
|
|
_X11MANTRANSFORMCMD+= -e s,${__def__},${__value__:C/%/ /gW},g
|
|
|
|
. endfor
|
|
|
|
.endif
|
|
|
|
_X11MANTRANSFORMCMD+= ${X11EXTRAMANDEFS}
|
2003-09-12 11:40:34 +04:00
|
|
|
|
2008-10-15 03:33:55 +04:00
|
|
|
.man.1 .man.3 .man.4 .man.5 .man.7 .man.pre.1 .man.pre.4 .man.pre.5:
|
2003-10-21 14:01:19 +04:00
|
|
|
${_MKTARGET_CREATE}
|
2003-09-12 11:40:34 +04:00
|
|
|
rm -f ${.TARGET}
|
2008-10-15 03:33:55 +04:00
|
|
|
${_X11MANTRANSFORMCMD} | ${X11TOOL_UNXCOMM} > ${.TARGET}
|