diff options
author | tsi <tsi> | 2009-02-01 20:55:56 +0000 |
---|---|---|
committer | tsi <tsi> | 2009-02-01 20:55:56 +0000 |
commit | 1d6ed10d93eb6dfb373d670538afe61d606b69d5 (patch) | |
tree | ffb860fccd8fa20b4af4af53bad113714158f322 | |
parent | e42b3fc0dbc5513548bd3d31fdbd967601ded6ff (diff) |
7. Deal with a build issue introduced by "security" update 2007-004 to
MacOSX. This update, present in MacOSX 10.5, by default disables the use
of the DYLD_LIBRARY_PATH environment variable that supplemented the
run-time library search path. To overcome this, change the build to link
bdftopcf, fc-cache, mkfontdir, mkfontscale, xcursorgen and xkbcomp
utilities against static versions of the libraries generated by the
build. Although this is currently only done for Darwin 9 and later, this
is written in such a way that this can be done on any other platform
should the need arise (Marc La France).
-rw-r--r-- | config/cf/X11.tmpl | 8 | ||||
-rw-r--r-- | config/cf/darwin.cf | 19 | ||||
-rw-r--r-- | programs/Xserver/hw/xfree86/CHANGELOG | 11 | ||||
-rw-r--r-- | programs/bdftopcf/Imakefile | 9 | ||||
-rw-r--r-- | programs/fc-cache/Imakefile | 30 | ||||
-rw-r--r-- | programs/mkfontdir/Imakefile | 11 | ||||
-rw-r--r-- | programs/mkfontscale/Imakefile | 32 | ||||
-rw-r--r-- | programs/xcursorgen/Imakefile | 17 | ||||
-rw-r--r-- | programs/xkbcomp/Imakefile | 25 |
9 files changed, 126 insertions, 36 deletions
diff --git a/config/cf/X11.tmpl b/config/cf/X11.tmpl index 1cb38744e..578b02758 100644 --- a/config/cf/X11.tmpl +++ b/config/cf/X11.tmpl @@ -1,6 +1,6 @@ XCOMM ---------------------------------------------------------------------- XCOMM X Window System Build Parameters and Rules -XCOMM $XFree86: xc/config/cf/X11.tmpl,v 1.299tsi Exp $ +XCOMM $XFree86: xc/config/cf/X11.tmpl,v 1.300tsi Exp $ /* * Copyright (c) 1994-2005 by The XFree86 Project, Inc. * All rights reserved. @@ -1937,7 +1937,6 @@ XCOMM X Window System make variables; these need to be coordinated with rules INSTAPPFLAGS = $(INSTDATFLAGS) /* XXX - this should go away - XXX */ #if UseInstalledX11 - RGB = $(BINDIR)/rgb FONTC = $(BINDIR)/bdftopcf MKFONTSCALE = $(BINDIR)/mkfontscale MKFONTDIR = $(BINDIR)/mkfontdir @@ -1947,7 +1946,6 @@ XCOMM X Window System make variables; these need to be coordinated with rules UCSMAPPREFIX = $(FONTDIR)/util/map- XCURSORGEN = $(BINDIR)/xcursorgen #else - RGB = $(CLIENTENVSETUP) $(XBUILDBINDIR)/rgb # if !CrossCompiling FONTC = $(CLIENTENVSETUP) $(PRELOADFONTSETUP) $(XBUILDBINDIR)/bdftopcf MKFONTSCALE = $(CLIENTENVSETUP) $(PRELOADFREETYPESETUP) $(XBUILDBINDIR)/mkfontscale @@ -2009,6 +2007,10 @@ XCOMM X Window System make variables; these need to be coordinated with rules VENDORMANDEFS = VendorManDefs +#ifndef StaticUtils +#define StaticUtils NO +#endif + #if HasSharedLibraries #ifndef DontUseLibPathVar #ifndef BuildLibPathVar diff --git a/config/cf/darwin.cf b/config/cf/darwin.cf index a567a3df9..e0e77aec4 100644 --- a/config/cf/darwin.cf +++ b/config/cf/darwin.cf @@ -1,4 +1,4 @@ -XCOMM platform: $XFree86: xc/config/cf/darwin.cf,v 1.58tsi Exp $ +XCOMM platform: $XFree86: xc/config/cf/darwin.cf,v 1.59tsi Exp $ /* Darwin / Mac OS X configuration by John Carmack <johnc@idsoftware.com> */ @@ -152,6 +152,8 @@ XCOMM operating system: OSName (OSMajorVersion./**/OSMinorVersion./**/OSTeenyVe /* we don't need -lm */ #define MathLibrary /**/ +#define LdPostLib /**/ + #define TermcapLibrary -lcurses #define SetTtyGroup YES /* for xterm */ @@ -313,7 +315,22 @@ XCOMM operating system: OSName (OSMajorVersion./**/OSMinorVersion./**/OSTeenyVe /* no XFree86-VidMode extension */ #define BuildXF86VidModeExt NO +/* No longer works after security update 2007-004 */ +#if OSMajorVersion < 9 #define BuildLibPathVar DYLD_LIBRARY_PATH +#else +#undef DontUseLibPathVar +#define DontUseLibPathVar YES +#undef BuildClients +#define BuildClients YES +#undef BuildLibraries +#define BuildLibraries YES +/* So we can statically link certain utilities */ +#undef ForceNormalLib +#define ForceNormalLib YES +#undef StaticUtils +#define StaticUtils YES +#endif #ifndef DefaultUserPath #define DefaultUserPath /bin:/sbin:/usr/bin:/usr/sbin:$(BINDIR) diff --git a/programs/Xserver/hw/xfree86/CHANGELOG b/programs/Xserver/hw/xfree86/CHANGELOG index 1a4563e62..02aa70e3c 100644 --- a/programs/Xserver/hw/xfree86/CHANGELOG +++ b/programs/Xserver/hw/xfree86/CHANGELOG @@ -1,4 +1,13 @@ XFree86 4.8.99.1 (?? February 2009) + 7. Deal with a build issue introduced by "security" update 2007-004 to + MacOSX. This update, present in MacOSX 10.5, by default disables the use + of the DYLD_LIBRARY_PATH environment variable that supplemented the + run-time library search path. To overcome this, change the build to link + bdftopcf, fc-cache, mkfontdir, mkfontscale, xcursorgen and xkbcomp + utilities against static versions of the libraries generated by the + build. Although this is currently only done for Darwin 9 and later, this + is written in such a way that this can be done on any other platform + should the need arise (Marc La France). 6. Fix links against libGL that arises on MacOSX Jaguar due to its confusion over whether to use the build-generated library or a system-provided one (Marc La France). @@ -20852,4 +20861,4 @@ XFree86 3.0a (28 April 1994) XFree86 3.0 (26 April 1994) -$XFree86: xc/programs/Xserver/hw/xfree86/CHANGELOG,v 3.3990 2009/02/01 20:23:31 tsi Exp $ +$XFree86: xc/programs/Xserver/hw/xfree86/CHANGELOG,v 3.3991 2009/02/01 20:37:06 tsi Exp $ diff --git a/programs/bdftopcf/Imakefile b/programs/bdftopcf/Imakefile index 59a8a213a..3bdf1a041 100644 --- a/programs/bdftopcf/Imakefile +++ b/programs/bdftopcf/Imakefile @@ -1,8 +1,15 @@ -XCOMM $XFree86: xc/programs/bdftopcf/Imakefile,v 3.10tsi Exp $ +XCOMM $XFree86: xc/programs/bdftopcf/Imakefile,v 3.11tsi Exp $ #if GzipFontCompression +#if StaticUtils && BuildZlib +ZLIB = $(BUILDLIBDIR)/LibraryTargetName(z) +#else ZLIB = GzipLibrary #endif +#endif +#if StaticUtils +FONTLIB = $(BUILDLIBDIR)/LibraryTargetName(Xfont) +#endif LOCAL_LIBRARIES = $(FONTLIB) SYS_LIBRARIES = $(ZLIB) MathLibrary DEPLIBS = $(DEPFONTLIB) diff --git a/programs/fc-cache/Imakefile b/programs/fc-cache/Imakefile index a30625d19..eeef99359 100644 --- a/programs/fc-cache/Imakefile +++ b/programs/fc-cache/Imakefile @@ -1,14 +1,30 @@ -XCOMM $XFree86: xc/programs/fc-cache/Imakefile,v 1.1 2003/06/09 15:11:16 dawes Exp $ +XCOMM $XFree86: xc/programs/fc-cache/Imakefile,v 1.2tsi Exp $ -FONTCONFIGDIR = $(TOP)/extras/fontconfig + FONTCONFIGDIR = $(TOP)/extras/fontconfig -INCLUDES=$(FREETYPE2INCLUDES) -I$(FONTCONFIGDIR) + INCLUDES = $(FREETYPE2INCLUDES) -I$(FONTCONFIGDIR) -LOCAL_LIBRARIES=FontconfigClientLibs - DEPLIBS=FontconfigClientDepLibs +#if StaticUtils +# if BuildFontconfigLibrary + FONTCONFIGLIB = $(BUILDLIBDIR)/LibraryTargetName(fontconfig) +# endif +# if BuildFreetype2Library +# if defined(DarwinArchitecture) && DarwinQuartzSupport + FRAMEWORKS = -framework CoreServices -framework ApplicationServices +# endif + FREETYPE2LIB = $(BUILDLIBDIR)/LibraryTargetName(freetype) $(FRAMEWORKS) +# endif +# if BuildExpatLibrary + EXPATLIB = $(BUILDLIBDIR)/LibraryTargetName(expat) +# endif +LOCAL_LIBRARIES = $(FONTCONFIGLIB) $(FREETYPE2LIB) $(EXPATLIB) +#else +LOCAL_LIBRARIES = FontconfigClientLibs +#endif + DEPLIBS = FontconfigClientDepLibs -SRCS=fc-cache.c -OBJS=fc-cache.o + SRCS = fc-cache.c + OBJS = fc-cache.o ComplexProgramTarget(fc-cache) LinkBuildBinary(ProgramTargetName(fc-cache)) diff --git a/programs/mkfontdir/Imakefile b/programs/mkfontdir/Imakefile index b21e8774e..7c4fd0756 100644 --- a/programs/mkfontdir/Imakefile +++ b/programs/mkfontdir/Imakefile @@ -1,4 +1,4 @@ -XCOMM $XFree86: xc/programs/mkfontdir/Imakefile,v 3.14tsi Exp $ +XCOMM $XFree86: xc/programs/mkfontdir/Imakefile,v 3.15tsi Exp $ /* * Copyright (c) 2004 by The XFree86 Project, Inc. @@ -47,11 +47,20 @@ XCOMM $XFree86: xc/programs/mkfontdir/Imakefile,v 3.14tsi Exp $ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#if StaticUtils + LOCAL_LIBRARIES = $(BUILDLIBDIR)/LibraryTargetName(Xfont) \ + $(BUILDLIBDIR)/LibraryTargetName(fntstubs) +#else LOCAL_LIBRARIES = $(FONTLIB) +#endif DEPLIBS = $(DEPFONTLIB) INCLUDES = -I$(FONTLIBSRC)/include #if GzipFontCompression +#if StaticUtils && BuildZlib + ZLIB = $(BUILDLIBDIR)/LibraryTargetName(z) +#else ZLIB = GzipLibrary +#endif ZDEFINES = -DX_GZIP_FONT_COMPRESSION #endif SYS_LIBRARIES = MathLibrary $(ZLIB) diff --git a/programs/mkfontscale/Imakefile b/programs/mkfontscale/Imakefile index 8878cc129..7e0741a50 100644 --- a/programs/mkfontscale/Imakefile +++ b/programs/mkfontscale/Imakefile @@ -1,21 +1,33 @@ -XCOMM $XFree86: xc/programs/mkfontscale/Imakefile,v 1.9tsi Exp $ - -LOCAL_LIBRARIES = $(XFONTENCLIB) $(FREETYPE2LIB) - DEPLIBS = $(DEPXFONTENCLIB) $(DEPFREETYPE2LIB) - -SYS_LIBRARIES = GzipLibrary +XCOMM $XFree86: xc/programs/mkfontscale/Imakefile,v 1.10tsi Exp $ + +#if StaticUtils + XFONTENCLIB = $(BUILDLIBDIR)/LibraryTargetName(fontenc) +# if BuildFreetype2Library +# if defined(DarwinArchitecture) && DarwinQuartzSupport + FRAMEWORKS = -framework CoreServices -framework ApplicationServices +# endif + FREETYPE2LIB = $(BUILDLIBDIR)/LibraryTargetName(freetype) $(FRAMEWORKS) +# endif +#endif + LOCAL_LIBRARIES = $(XFONTENCLIB) $(FREETYPE2LIB) + DEPLIBS = $(DEPXFONTENCLIB) $(DEPFREETYPE2LIB) +#if StaticUtils && BuildZlib + SYS_LIBRARIES = $(BUILDLIBDIR)/LibraryTargetName(z) +#else + SYS_LIBRARIES = GzipLibrary +#endif -SRCS = mkfontscale.c list.c hash.c ident.c + SRCS = mkfontscale.c list.c hash.c ident.c -OBJS = mkfontscale.o list.o hash.o ident.o + OBJS = mkfontscale.o list.o hash.o ident.o #if !HasSnprintf SNPRINTF_DEFINES = -DNEED_SNPRINTF SNPRINTF_INCLUDES = -I$(LIBSRC)/misc #endif -INCLUDES = $(FREETYPE2INCLUDES) $(SNPRINTF_INCLUDES) -DEFINES = $(FREETYPE2DEFINES) $(SNPRINTF_DEFINES) + INCLUDES = $(FREETYPE2INCLUDES) $(SNPRINTF_INCLUDES) + DEFINES = $(FREETYPE2DEFINES) $(SNPRINTF_DEFINES) ComplexProgramTarget(mkfontscale) LinkBuildBinary(ProgramTargetName(mkfontscale)) diff --git a/programs/xcursorgen/Imakefile b/programs/xcursorgen/Imakefile index 9979bf6cf..25de8837a 100644 --- a/programs/xcursorgen/Imakefile +++ b/programs/xcursorgen/Imakefile @@ -1,7 +1,20 @@ -XCOMM $XFree86: xc/programs/xcursorgen/Imakefile,v 1.6 2002/12/07 20:43:43 herrb Exp $ +XCOMM $XFree86: xc/programs/xcursorgen/Imakefile,v 1.7tsi Exp $ + #define IHaveSubdirs #define PassCDebugFlags CDEBUGFLAGS="$(CDEBUGFLAGS)" +#if StaticUtils + XCURSORLIB = $(BUILDLIBDIR)/LibraryTargetName(Xcursor) + XRENDERLIB = $(BUILDLIBDIR)/LibraryTargetName(Xrender) + XLIB = $(BUILDLIBDIR)/LibraryTargetName(Xext) \ + $(BUILDLIBDIR)/LibraryTargetName(X11) +#endif +#if StaticUtils && BuildZlib + ZLIB = $(BUILDLIBDIR)/LibraryTargetName(z) +#else + ZLIB = GzipLibrary +#endif + SUBDIRS = redglass whiteglass handhelds DEFAULT_THEME = DefaultCursorTheme ICONDIR = $(LIBDIR)/icons @@ -9,7 +22,7 @@ XCOMM $XFree86: xc/programs/xcursorgen/Imakefile,v 1.6 2002/12/07 20:43:43 herrb INCLUDES = $(LIBPNGINC) DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XCURSORLIB) $(XRENDERLIB) $(XLIB) $(LIBPNGLIB) \ - MathLibrary GzipLibrary + MathLibrary $(ZLIB) SRCS = xcursorgen.c OBJS = xcursorgen.o diff --git a/programs/xkbcomp/Imakefile b/programs/xkbcomp/Imakefile index 7fab3a3ec..c05cfa0d2 100644 --- a/programs/xkbcomp/Imakefile +++ b/programs/xkbcomp/Imakefile @@ -1,19 +1,24 @@ -XCOMM $XFree86: xc/programs/xkbcomp/Imakefile,v 3.25tsi Exp $ +XCOMM $XFree86: xc/programs/xkbcomp/Imakefile,v 3.26tsi Exp $ #define IHaveSubdirs #define PassCDebugFlags 'CDEBUGFLAGS=$(CDEBUGFLAGS)' +#if StaticUtils + XKBFILELIB = $(BUILDLIBDIR)/LibraryTargetName(xkbfile) + XONLYLIB = $(BUILDLIBDIR)/LibraryTargetName(X11) +#endif + #if CrossCompiling - CROSS = cross + CROSS = cross #endif - SRCS = xkbcomp.c xkbscan.c expr.c vmod.c indicators.c misc.c \ - keymap.c keycodes.c keytypes.c compat.c action.c alias.c \ - symbols.c geometry.c xkbpath.c listing.c \ - xkbparse.c parseutils.c utils.c - OBJS = xkbcomp.o xkbscan.o expr.o vmod.o indicators.o misc.o alias.o \ - keymap.o keycodes.o keytypes.o compat.o action.o \ - symbols.o geometry.o xkbpath.o listing.o \ - xkbparse.o parseutils.o utils.o + SRCS = xkbcomp.c xkbscan.c expr.c vmod.c indicators.c misc.c \ + keymap.c keycodes.c keytypes.c compat.c action.c alias.c \ + symbols.c geometry.c xkbpath.c listing.c \ + xkbparse.c parseutils.c utils.c + OBJS = xkbcomp.o xkbscan.o expr.o vmod.o indicators.o misc.o \ + keymap.o keycodes.o keytypes.o compat.o action.o alias.o \ + symbols.o geometry.o xkbpath.o listing.o \ + xkbparse.o parseutils.o utils.o DEPLIBS = $(DEPXKBFILELIB) $(DEPXONLYLIB) LOCAL_LIBRARIES = $(XKBFILELIB) $(XONLYLIB) SUBDIRS = compat compiled $(CROSS) geometry keycodes keymap rules \ |