1# Copyright (C) 2001-2020 Artifex Software, Inc. 2# All Rights Reserved. 3# 4# This software is provided AS-IS with no warranty, either express or 5# implied. 6# 7# This software is distributed under license and may not be copied, 8# modified or distributed except as expressly authorized under the terms 9# of the license contained in the file LICENSE in this distribution. 10# 11# Refer to licensing information at http://www.artifex.com or contact 12# Artifex Software, Inc., 1305 Grant Avenue - Suite 200, Novato, 13# CA 94945, U.S.A., +1(415)492-9861, for further information. 14# 15# makefile template for/from the autoconf build. 16# @configure_input@ 17 18# ------------------------------- Options ------------------------------- # 19 20####### The following are the only parts of the file you should need to edit. 21 22# Define the directory for the final executable, and the 23# source, generated intermediate file, and object directories 24# for the graphics library (GL) and the PostScript/PDF interpreter (PS). 25 26PACKAGE=ghostscript 27BINDIR=./$(BUILDDIRPREFIX)bin 28GLSRCDIR=@srcdir@/base 29DEVSRCDIR=@srcdir@/devices 30GENORDERED_SRCDIR=@srcdir@/toolbin/halftone/gen_ordered 31GLGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 32GLOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 33DEVGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 34DEVOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 35AUXDIR=$(GLGENDIR)/aux@AUXDIRPOSTFIX@ 36PSSRCDIR=@srcdir@/psi 37PSLIBDIR=@srcdir@/lib 38PSRESDIR=@srcdir@/Resource 39PSGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 40PSOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 41 42PCL5SRCDIR=@srcdir@/pcl/pcl 43PCL5GENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 44PCL5OBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 45 46PXLSRCDIR=@srcdir@/pcl/pxl 47PXLGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 48PXLOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 49 50PLSRCDIR=@srcdir@/pcl/pl 51PLGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 52PLOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 53 54XPSSRCDIR=@srcdir@/xps 55XPSGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 56XPSOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 57 58GPDLSRCDIR=@srcdir@/gpdl 59GPDLGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 60GPDLOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 61 62URFSRCDIR=@srcdir@/urf 63URFGENDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 64URFOBJDIR=./$(BUILDDIRPREFIX)@OBJDIR_BSDMAKE_WORKAROUND@ 65 66CONTRIBDIR=@srcdir@/contrib 67 68# Do not edit the next group of lines. 69 70include $(GLSRCDIR)/version.mak 71DD=$(GLGENDIR)/ 72GLD=$(GLGENDIR)/ 73PSD=$(PSGENDIR)/ 74 75# ------ Generic options ------ # 76 77# Define the installation commands and target directories for 78# executables and files. The commands are only relevant to `make install'; 79# the directories also define the default search path for the 80# initialization files (gs_*.ps) and the fonts. 81 82INSTALL = $(GLSRCDIR)/instcopy -c 83INSTALL_PROGRAM = $(INSTALL) -m 755 84INSTALL_DATA = $(INSTALL) -m 644 85INSTALL_SHARED = @INSTALL_SHARED@ 86 87prefix = @prefix@ 88datarootdir = @datarootdir@ 89exec_prefix = @exec_prefix@ 90bindir = @bindir@ 91scriptdir = $(bindir) 92includedir = @includedir@ 93libdir = @libdir@ 94mandir = @mandir@ 95man1ext = 1 96man1dir = $(mandir)/man$(man1ext) 97datadir = @datadir@ 98docdir = @docdir@@VERSIONED_PATH@ 99 100# The following must be substituted using @datadir@ and @libdir@ 101# to avoid adding RPM generation paths (CUPS STR #1112) 102gsdir = @datadir@/ghostscript 103gsdatadir = $(gsdir)@VERSIONED_PATH@ 104gssharedir = @libdir@/ghostscript@VERSIONED_PATH@ 105gsincludedir = @includedir@/ghostscript/ 106 107exdir=$(gsdatadir)/examples 108GS_DOCDIR=$(docdir) 109 110# Choose whether to compile the .ps initialization files into the executable. 111# See gs.mak for details. 112 113COMPILE_INITS=@COMPILE_INITS@ 114 115# Define the default directory/ies for the runtime 116# initialization and font files. Separate multiple directories with a :. 117 118GS_LIB_DEFAULT=$(gsdatadir)/Resource/Init:$(gsdatadir)/lib:$(gsdatadir)/Resource/Font:$(gsdir)/fonts:@fontpath@ 119 120# Define the default directory for cached data files 121# this must be a single path. 122 123GS_CACHE_DIR="~/.ghostscript/cache/" 124 125# Define whether or not searching for initialization files should always 126# look in the current directory first. This leads to well-known security 127# and confusion problems, but may be convenient sometimes. 128 129SEARCH_HERE_FIRST=0 130 131# Define the name of the interpreter initialization file. 132# (There is no reason to change this.) 133 134GS_INIT=gs_init.ps 135 136# Choose generic configuration options. 137 138TARGET_ARCH_FILE=@ARCH_CONF_HEADER@ 139 140# -DDEBUG 141# includes debugging features (-Z switch) in the code. 142# Code runs substantially slower even if no debugging switches 143# are set. 144 145GENOPT= 146GENOPTAUX= 147 148# Choose capability options. 149 150# -DHAVE_BSWAP32 151# use bswap32 intrinsic 152# -DHAVE_BYTESWAP_H 153# use byteswap.h functions 154# 155# -DHAVE_MKSTEMP 156# uses mkstemp instead of mktemp 157# This uses the more secure temporary file creation call 158# Enable this if it is available on your platform. 159# -DHAVE_FILE64 160# use marked versions of the stdio FILE calls, fopen64() et al. 161# 162# -DHAVE_MKSTEMP64 163# use non-standard function mkstemp64() 164# 165# -DHAVE_LIBIDN 166# use libidn to canonicalize Unicode passwords 167# 168# -DHAVE_SETLOCALE 169# call setlocale(LC_CTYPE) when running as a standalone app 170# -DHAVE_SSE2 171# use sse2 intrinsics 172 173CAPOPT= @HAVE_MKSTEMP@ @HAVE_FILE64@ @HAVE_FSEEKO@ @HAVE_MKSTEMP64@ @HAVE_FONTCONFIG@ @HAVE_LIBIDN@ @HAVE_SETLOCALE@ @HAVE_SSE2@ @HAVE_DBUS@ @HAVE_BSWAP32@ @HAVE_BYTESWAP_H@ @HAVE_STRERROR@ @HAVE_ISNAN@ @HAVE_ISINF@ @HAVE_FPCLASSIFY@ @HAVE_PREAD_PWRITE@ @RECURSIVE_MUTEXATTR@ 174 175# Define the name of the executable file. 176 177GS=@GS@ 178GS_SO_BASE=@GS@ 179GS_SONAME=@GS_SONAME@ 180GS_SONAME_MAJOR=@GS_SONAME_MAJOR@ 181GS_SONAME_MAJOR_MINOR=@GS_SONAME_MAJOR_MINOR@ 182 183PCL=@PCL@ 184PCL_SO_BASE=@PCL@ 185PCL_SONAME=@PCL_SONAME@ 186PCL_SONAME_MAJOR=@PCL_SONAME_MAJOR@ 187PCL_SONAME_MAJOR_MINOR=@PCL_SONAME_MAJOR_MINOR@ 188 189XPS=@XPS@ 190XPS_SO_BASE=@XPS@ 191XPS_SONAME=@XPS_SONAME@ 192XPS_SONAME_MAJOR=@XPS_SONAME_MAJOR@ 193XPS_SONAME_MAJOR_MINOR=@XPS_SONAME_MAJOR_MINOR@ 194 195GPDL=@GPDL@ 196GPDL_SO_BASE=@GPDL@ 197GPDL_SONAME=@GPDL_SONAME@ 198GPDL_SONAME_MAJOR=@GPDL_SONAME_MAJOR@ 199GPDL_SONAME_MAJOR_MINOR=@GPDL_SONAME_MAJOR_MINOR@ 200 201XE=@EXEEXT@ 202XEAUX=@AUXEXEEXT@ 203 204PCL_TARGET=@PCL_TARGET@ 205XPS_TARGET=@XPS_TARGET@ 206GPDL_TARGET=@GPDL_TARGET@ 207 208PCL_XPS_PDL_TARGETS=$(PCL_TARGET) $(XPS_TARGET) $(GPDL_TARGET) 209 210# Define the directories for debugging and profiling binaries, relative to 211# the standard binaries. 212 213DEBUGDIRPREFIX=debug 214MEMENTODIRPREFIX=mem 215SANITIZEDIRPREFIX=san 216PGDIRPREFIX=pg 217 218# Are we include the CAL library? 219WITH_CAL=@WITH_CAL@ 220CALSRCDIR=@CALSRCDIR@ 221CAL_CFLAGS=@CAL_CFLAGS@ 222CAL_SSE4_2_CFLAGS=@CAL_SSE4_2_CFLAGS@ 223CAL_AVX2_CFLAGS=@CAL_AVX2_CFLAGS@ 224CAL_NEON_CFLAGS=@CAL_NEON_CFLAGS@ 225 226# Define whether to compile in the FreeType library, and if so, where 227# the source tree is location. Otherwise, what library name to use 228# in linking to a shared implementation. 229 230FT_BRIDGE=@FT_BRIDGE@ 231SHARE_FT=@SHARE_FT@ 232FTSRCDIR=@FTSRCDIR@ 233FT_CFLAGS=@FT_CFLAGS@ -DSHARE_FT=@SHARE_FT@ 234FT_LIBS=@FT_LIBS@ 235FT_CONFIG_SYSTEM_ZLIB=@FT_SYS_ZLIB@ 236 237# Define whether to compile in UFST. 238# FAPI/UFST depends on UFST_BRIDGE being undefined - hence the construct below. 239# (i.e. use "UFST_BRIDGE=1" or *not to define UFST_BRIDGE to anything*) 240# As UFST is not used for fonts embedded in input files, we should still have 241# Freetype enabled, above. 242@INSERT_UFST_BRIDGE_EQUAL_ONE@ 243UFST_ROOT=@UFST_ROOT@ 244UFST_LIB_EXT=@UFST_LIB_EXT@ 245 246UFST_ROMFS_ARGS?=-b \ 247 -P $(UFST_ROOT)/fontdata/mtfonts/pcl45/mt3/ -d fontdata/mtfonts/pcl45/mt3/ pcl___xj.fco plug__xi.fco wd____xh.fco \ 248 -P $(UFST_ROOT)/fontdata/mtfonts/pclps2/mt3/ -d fontdata/mtfonts/pclps2/mt3/ pclp2_xj.fco \ 249 -c -P $(PSSRCDIR)/../lib/ -d Resource/Init/ FAPIconfig-FCO 250 251UFSTROMFONTDIR=\"%rom%fontdata/\" 252UFSTDISCFONTDIR?=\"$(UFST_ROOT)/fontdata/\" 253 254 255UFST_CFLAGS=@UFST_CFLAGS@ 256 257# Define the directory where the IJG JPEG library sources are stored, 258# and the major version of the library that is stored there. 259# You may need to change this if the IJG library version changes. 260# See jpeg.mak for more information. 261 262JSRCDIR=@LIBJPEGDIR@ 263 264# Note: if a shared library is used, it may not contain the 265# D_MAX_BLOCKS_IN_MCU patch, and thus may not be able to read 266# some older JPEG streams that violate the standard. If the JPEG 267# library built from local sources, the patch will be applied. 268 269SHARE_JPEG=@SHARE_LIBJPEG@ 270JPEG_NAME=jpeg 271 272# Define the directory where the PNG library sources are stored, 273# and the version of the library that is stored there. 274# You may need to change this if the libpng version changes. 275# See png.mak for more information. 276 277SHARE_LIBPNG=@SHARE_LIBPNG@ 278PNGSRCDIR=@LIBPNGDIR@ 279LIBPNG_NAME=png 280 281# libtiff 282SHARE_LIBTIFF=@SHARE_LIBTIFF@ 283TIFFSRCDIR=@LIBTIFFDIR@ 284TIFFCONFDIR=@LIBTIFFCONFDIR@ 285TIFFPLATFORM=unix 286TIFFCONFIG_SUFFIX= 287LIBTIFF_NAME=tiff 288TIFF_CFLAGS=@TIFFCFLAGS@ 289ENABLE_TIFF=@ENABLETIFF@ 290 291# Define the directory where the zlib sources are stored. 292# See zlib.mak for more information. 293 294SHARE_ZLIB=@SHARE_ZLIB@ 295ZSRCDIR=@ZLIBDIR@ 296#ZLIB_NAME=gz 297ZLIB_NAME=z 298ZLIB_CFLAGS=@ZLIBCFLAGS@ 299 300# Choose shared or compiled in libjbig2dec and source location 301# JBIG2_LIB=jbig2dec 302JBIG2_LIB=@JBIG2_DECODER@ 303SHARE_JBIG2=@SHARE_JBIG2@ 304JBIG2SRCDIR=@JBIG2DIR@ 305JBIG2_CFLAGS=@JBIG2_AUTOCONF_CFLAGS@ 306 307# uncomment the following three lines and one of the last two to 308# compile in the Luratech ldf_jb2 codec 309#JBIG2_LIB=luratech 310#SHARE_JBIG2=0 311#JBIG2SRCDIR=ldf_jb2 312#JBIG2_CFLAGS=-DUSE_LDF_JB2 -DLINUX 313#JBIG2_CFLAGS=-DUSE_LDF_JB2 -DMAC -DMAC_OS_X_BUILD 314 315 316# Choose the library to use for (JPXDecode support) 317# whether to link to an external build or compile in from source 318# and source location and configuration flags for compiling in 319JPX_LIB=@JPX_DECODER@ 320SHARE_JPX=@SHARE_JPX@ 321JPXSRCDIR=@JPXDIR@ 322JPX_CFLAGS=-DSHARE_JPX=$(SHARE_JPX) @JPX_AUTOCONF_CFLAGS@ @JPX_SSE_CFLAGS@ 323 324# uncomment the following three lines and one of the last two to 325# compile in the Luratech lwf_jp2 codec 326#JPX_LIB=luratech 327#SHARE_JPX=0 328#JPXSRCDIR=lwf_jp2 329#JPX_CFLAGS=-DUSE_LWF_JP2 -DLINUX 330#JPX_CFLAGS=-DUSE_LWF_JP2 -DMAC -DMAC_OS_X_BUILD 331 332# Uncomment the following 4 lines to to compile in OpenJPEG codec 333#JPX_LIB=openjpeg 334#SHARE_JPX=0 335#JPXSRCDIR=openjpeg 336#JPX_CFLAGS=-DUSE_OPENJPEG_JP2 -DOPJ_STATIC 337 338# options for lcms color management library 339SHARE_LCMS=@SHARELCMS@ 340LCMS2SRCDIR=@LCMS2DIR@ 341LCMS2MTSRCDIR=@LCMS2MTDIR@ 342LCMS2_CFLAGS=-DSHARE_LCMS=$(SHARE_LCMS) @LCMS2_ENDIAN@ @SQRTF_SUBST@ @LCMS2_PTR_ALIGNMENT@ 343 344# Which CMS are we using? 345# Options are currently lcms or lcms2 346WHICH_CMS=@WHICHLCMS@ 347 348# Do we have URF support? 349ENABLE_URF=@ENABLEURF@ 350GPDL_URF_TOP_OBJ=@GPDL_URF_TOP_OBJ@ 351URF_INCLUDE=@URF_INCLUDE@ 352URF_DEV=@URF_DEV@ 353SURFX_H=@SURFX_H@ 354 355EXPATSRCDIR=@EXPATDIR@ 356EXPAT_CFLAGS=@EXPAT_CFLAGS@ 357EXPATGENDIR=$(GLGENDIR) 358EXPATOBJDIR=$(GLOBJDIR) 359EXPATINCDIR = $(EXPATSRCDIR)$(D)lib 360SHARE_EXPAT=@SHARE_EXPAT@ 361 362JPEGXR_SRCDIR=@SRCDIR@/jpegxr 363SHARE_JPEGXR=0 364JPEGXR_GENDIR=$(GLGENDIR) 365JPEGXR_OBJDIR=$(GLOBJDIR) 366 367# Define the directory where the ijs source is stored, 368# and the process forking method to use for the server. 369# See ijs.mak for more information. 370 371SHARE_IJS=@SHAREIJS@ 372IJS_NAME=@IJSLIB@ 373IJSSRCDIR=@IJSDIR@ 374IJSEXECTYPE=unix 375 376# Define install location for 'cups' device/filter support 377CUPSLIBS=@CUPSLIBS@ 378CUPSLIBDIRS=@CUPSLIBDIRS@ 379CUPSSERVERBIN=@CUPSSERVERBIN@ 380CUPSSERVERROOT=@CUPSSERVERROOT@ 381CUPSDATA=@CUPSDATA@ 382CUPSPDFTORASTER=@CUPSPDFTORASTER@ 383 384SHARE_LCUPS=@SHARELCUPS@ 385LCUPS_NAME=cups 386LCUPSSRCDIR=@CUPS_DIR@ 387LCUPSBUILDTYPE=@LCUPSBUILDTYPE@ 388CUPS_CC=$(CC) 389 390SHARE_LCUPSI=@SHARELCUPSI@ 391LCUPSI_NAME=cupsimage 392LCUPSISRCDIR=@CUPS_DIR@ 393CUPS_CC=$(CC) 394 395CUPSCFLAGS=@CUPSCFLAGS@ -DSHARE_LCUPS=$(SHARE_LCUPS) -DSHARE_LCUPSI=$(SHARE_LCUPSI) 396 397# Define how to build the library archives. (These are not used in any 398# standard configuration.) 399 400AR=ar 401ARFLAGS=qc 402RANLIB=@RANLIB@ 403STRIP_XE=@STRIP_XE@ 404STRIP_XE_OPTS= 405 406# ------ Platform-specific options ------ # 407 408# Define the name of the C compiler (target and host (AUX)) 409 410CC=@CC@ 411CCAUX=@CCAUX@ 412 413# Define the name of the linker for the final link step. 414# Normally this is the same as the C compiler. 415 416CCLD=$(CC) 417CCAUXLD=$(CCAUX) 418 419# Define the default gcc flags. 420GCFLAGS=@CPPFLAGS@ @GCFLAGS@ @CFLAGS@ @HAVE_POPEN_PROTO@ 421GCFLAGSAUX=@GCFLAGSAUX@ @HAVE_POPEN_PROTO@ 422 423# Define the added flags for standard, debugging, profiling 424# and shared object builds. 425 426CFLAGS_STANDARD=@OPT_CFLAGS@ 427CFLAGS_DEBUG=@DBG_CFLAGS@ 428CFLAGS_PROFILE=-pg @OPT_CFLAGS@ 429CFLAGS_SO=@DYNAMIC_CFLAGS@ 430 431CFLAGSAUX_STANDARD=@CFLAGSAUX_STANDARD@ 432CFLAGSAUX_DEBUG=@CFLAGSAUX_DEBUG@ 433CFLAGSAUX_PROFILE=-pg @CFLAGSAUX_STANDARD@ 434 435# Define the extra flags added for address sanitizer builds 436 437CFLAGS_SANITIZE=@CFLAGS_SANITIZE@ 438LDFLAGS_SANITIZE=$(CFLAGS_SANITIZE) 439 440# Define the other compilation flags. Add at most one of the following: 441# -DBSD4_2 for 4.2bsd systems. 442# -DSYSV for System V or DG/UX. 443# -DSYSV -D__SVR3 for SCO ODT, ISC Unix 2.2 or before, 444# or any System III Unix, or System V release 3-or-older Unix. 445# -DSVR4 -DSVR4_0 (not -DSYSV) for System V release 4.0. 446# -DSVR4 (not -DSYSV) for System V release 4.2 (or later) and Solaris 2. 447# XCFLAGS can be set from the command line. 448# We don't include -ansi, because this gets in the way of the platform- 449# specific stuff that <math.h> typically needs; nevertheless, we expect 450# gcc to accept ANSI-style function prototypes and function definitions. 451# CFLAGS from autoconf 452AC_CFLAGS=@DYNAMIC_FLAGS@ 453 454# fontconfig flags, used by unix-aux.mak 455FONTCONFIG_CFLAGS=@FONTCONFIG_CFLAGS@ 456FONTCONFIG_LIBS=@FONTCONFIG_LIBS@ 457 458# DBus flags, used by cups.mak 459DBUS_CFLAGS=@DBUS_CFLAGS@ 460DBUS_LIBS=@DBUS_LIBS@ 461 462# defines from autoconf; note that we don't use all of these at present. 463ACDEFS=@DEFS@ 464 465CFLAGS_VISIBILITY="-fvisibility=hidden" 466 467CFLAGS=$(CFLAGS_STANDARD) $(GCFLAGS) $(AC_CFLAGS) $(XCFLAGS) @CLUSTER_CFLAGS@ 468CFLAGSAUX=$(CFLAGSAUX_STANDARD) $(GCFLAGSAUX) $(XCFLAGSAUX) 469 470# Define platform flags for ld. 471# SunOS 4.n may need -Bstatic. 472# Solaris 2.6 (and possibly some other versions) with any of the SHARE_ 473# parameters set to 1 may need 474# -R /usr/local/xxx/lib:/usr/local/lib 475# giving the full path names of the shared library directories. 476# XLDFLAGS can be set from the command line. 477# AC_LDFLAGS from autoconf 478AC_LDFLAGS=@X_LDFLAGS@ 479 480LDFLAGS=@LDFLAGS@ $(AC_LDFLAGS) $(XLDFLAGS) 481 482LDFLAGSAUX=@LDFLAGSAUX@ 483 484GS_LDFLAGS=$(LDFLAGS) 485PCL_LDFLAGS=$(LDFLAGS) 486XPS_LDFLAGS=$(LDFLAGS) 487PDL_LDFLAGS=$(LDFLAGS) 488 489GS_LDFLAGS_SO=@GS_DYNAMIC_LDFLAGS@ 490PCL_LDFLAGS_SO=@PCL_DYNAMIC_LDFLAGS@ 491XPS_LDFLAGS_SO=@XPS_DYNAMIC_LDFLAGS@ 492PDL_LDFLAGS_SO=@PDL_DYNAMIC_LDFLAGS@ 493 494# Define any extra libraries to link into the executable. 495# ISC Unix 2.2 wants -linet. 496# SCO Unix needs -lsocket if you aren't including the X11 driver. 497# SVR4 may need -lnsl. 498# Solaris may need -lnsl -lsocket -lposix4. 499# (Libraries required by individual drivers are handled automatically.) 500 501EXTRALIBS=$(XTRALIBS) @LIBS@ @DYNAMIC_LIBS@ @FONTCONFIG_LIBS@ @FT_LIBS@ @JPX_AUTOCONF_LIBS@ @EXPAT_LIBS@ 502AUXEXTRALIBS=@AUXEXTRALIBS@ @AUX_SHARED_ZLIB@ 503 504# Define the standard libraries to search at the end of linking. 505# Most platforms require -lpthread for the POSIX threads library; 506# on FreeBSD, change -lpthread to -lc_r; BSDI and perhaps some others 507# include pthreads in libc and don't require any additional library. 508# All reasonable platforms require -lm, but Rhapsody and perhaps one or 509# two others fold libm into libc and don't require any additional library. 510 511STDLIBS=@PTHREAD_LIBS@ -lm 512 513# Define the include switch(es) for the X11 header files. 514# This can be null if handled in some other way (e.g., the files are 515# in /usr/include, or the directory is supplied by an environment variable) 516 517XINCLUDE=@X_CFLAGS@ 518 519# Define the directory/ies and library names for the X11 library files. 520# XLIBDIRS is for ld and should include -L; XLIBDIR is for LD_RUN_PATH 521# (dynamic libraries on SVR4) and should not include -L. 522# Newer SVR4 systems can use -R in XLIBDIRS rather than setting XLIBDIR. 523# Both can be null if these files are in the default linker search path. 524 525# Solaris and other SVR4 systems with dynamic linking probably want 526#XLIBDIRS=-L/usr/openwin/lib -R/usr/openwin/lib 527# X11R6 (on any platform) may need 528#XLIBS=Xt SM ICE Xext X11 529 530# We use the autoconf macro AC_PATH_XTRA which defines X_LIBS with 531# the -L (or whatever). It also defines X_PRE_LIBS and X_EXTRA_LIBS 532# all three of which are stripped and slotted into XLIBS below. 533# Usually however, all but X_LIBS are empty on modern platforms. 534XLIBDIRS=@X_LDFLAGS@ 535XLIBDIR= 536#XLIBS=Xt Xext X11 537XLIBS=@X_LIBS@ 538 539# Define the .dev module that implements thread and synchronization 540# primitives for this platform. 541 542# If POSIX sync primitives are used, also change the STDLIBS to include 543# the pthread library. Otherwise use SYNC=nosync 544#SYNC=posync 545#SYNC=nosync 546SYNC=@SYNC@ 547 548# programs we use 549RM=rm -f 550 551# ------ Dynamic loader options ------- # 552SOC_CFLAGS = @SOC_CFLAGS@ 553SOC_LIBS = @SOC_LIBS@ 554SOC_LOADER = @SOC_LOADER@ 555 556# on virtually every Unix-a-like system, this is "so", 557# but Apple just had to be different, so it's now set 558# by configure 559SO_LIB_EXT=@SO_LIB_EXT@ 560DLL_EXT=@DLL_EXT@ 561SO_LIB_VERSION_SEPARATOR=@SO_LIB_VERSION_SEPARATOR@ 562 563#CAIRO_CFLAGS = @CAIRO_CFLAGS@ 564#CAIRO_LIBS = @CAIRO_LIBS@ 565 566# AUX Tools flags 567MKROMFS_FLAGS=@MKROMFS_FLAGS@ 568 569# ------ Devices and features ------ # 570 571# Choose the language feature(s) to include. See gs.mak for details. 572 573# if it's included, $(PSD)gs_pdfwr.dev should always be one of the last in the list 574PSI_FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev $(PSD)epsf.dev $(PSD)ttfont.dev \ 575 @UTF8DEVS@ $(PSD)fapi_ps.dev $(PSD)jpx.dev $(PSD)jbig2.dev $(PSD)gs_pdfwr.dev 576 577 578PCL_FEATURE_DEVS=$(PLOBJDIR)/pl.dev $(PLOBJDIR)/pjl.dev $(PXLOBJDIR)/pxl.dev $(PCL5OBJDIR)/pcl5c.dev \ 579 $(PCL5OBJDIR)/hpgl2c.dev 580 581XPS_FEATURE_DEVS=$(XPSOBJDIR)/pl.dev $(XPSOBJDIR)/xps.dev 582 583FEATURE_DEVS=$(GLD)pipe.dev $(GLD)gsnogc.dev $(GLD)htxlib.dev $(GLD)psl3lib.dev $(GLD)psl2lib.dev \ 584 $(GLD)dps2lib.dev $(GLD)path1lib.dev $(GLD)patlib.dev $(GLD)psl2cs.dev $(GLD)rld.dev $(GLD)gxfapiu$(UFST_BRIDGE).dev\ 585 $(GLD)ttflib.dev $(GLD)cielib.dev $(GLD)pipe.dev $(GLD)htxlib.dev $(GLD)sdct.dev $(GLD)libpng.dev\ 586 $(GLD)seprlib.dev $(GLD)translib.dev $(GLD)cidlib.dev $(GLD)psf0lib.dev $(GLD)psf1lib.dev\ 587 $(GLD)psf2lib.dev $(GLD)lzwd.dev $(GLD)sicclib.dev \ 588 $(GLD)sjbig2.dev $(GLD)sjpx.dev $(GLD)ramfs.dev \ 589 $(GLD)pwgd.dev $(GLD)siscale.dev $(URF_DEV) 590 591#FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev 592#FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev $(PSD)ttfont.dev $(GLD)pipe.dev 593# The following is strictly for testing. 594FEATURE_DEVS_ALL=$(PSD)psl3.dev $(PSD)pdf.dev $(PSD)ttfont.dev $(PSD)double.dev $(PSD)trapping.dev $(PSD)stocht.dev $(GLD)pipe.dev $(GLD)gsnogc.dev $(GLD)htxlib.dev @JBIG2DEVS@ @JPXDEVS@ @UTF8DEVS@ $(GLD)ramfs.dev 595#FEATURE_DEVS=$(FEATURE_DEVS_ALL) 596 597# The list of resources to be included in the %rom% file system. 598# This is in the top makefile since the file descriptors are platform specific 599RESOURCE_LIST=Resource/CMap/ Resource/ColorSpace/ Resource/Decoding/ Resource/Font/ Resource/ProcSet/ Resource/IdiomSet/ Resource/CIDFont/ 600 601# Choose whether to store band lists on files or in memory. 602# The choices are 'file' or 'memory'. 603 604BAND_LIST_STORAGE=file 605 606# Choose which compression method to use when storing band lists in memory. 607# The choices are 'lzw' or 'zlib'. 608 609BAND_LIST_COMPRESSOR=zlib 610 611# Choose the implementation of file I/O: 'stdio', 'fd', or 'both'. 612# See gs.mak and sfxfd.c for more details. 613 614FILE_IMPLEMENTATION=stdio 615 616# List of default devices, in order of priority. They need not be 617# present in the actual build. 618GS_DEV_DEFAULT="x11alpha bbox" 619 620# Fallback default device. This is set to 'display' by 621# unix-dll.mak when building a shared object. 622DISPLAY_DEV=$(DD)bbox.dev 623 624# Choose the device(s) to include. See devs.mak for details, 625# devs.mak and contrib.mak for the list of available devices. 626 627#DEVICE_DEVS=$(DISPLAY_DEV) $(DD)x11.dev $(DD)x11alpha.dev $(DD)x11cmyk.dev $(DD)x11gray2.dev $(DD)x11gray4.dev $(DD)x11mono.dev 628#DEVICE_DEVS=$(DISPLAY_DEV) @X11DEVS@ 629#DEVICE_DEVS=$(DISPLAY_DEV) @X_DEVS@ 630 631#DEVICE_DEVS1=$(DD)bmpmono.dev $(DD)bmpgray.dev $(DD)bmpsep1.dev $(DD)bmpsep8.dev $(DD)bmp16.dev $(DD)bmp256.dev $(DD)bmp16m.dev $(DD)bmp32b.dev 632#DEVICE_DEVS2=#$(DD)gdevjbig2.dev $(DD)gdevjpx.dev #$(DD)rinkj.dev 633#DEVICE_DEVS3=$(DD)deskjet.dev $(DD)djet500.dev $(DD)laserjet.dev $(DD)ljetplus.dev $(DD)ljet2p.dev $(DD)ljet3.dev $(DD)ljet3d.dev $(DD)ljet4.dev $(DD)ljet4d.dev $(DD)lj5mono.dev $(DD)lj5gray.dev 634#DEVICE_DEVS4=$(DD)cdeskjet.dev $(DD)cdjcolor.dev $(DD)cdjmono.dev $(DD)cdj550.dev $(DD)pj.dev $(DD)pjxl.dev $(DD)pjxl300.dev 635#DEVICE_DEVS5=$(DD)uniprint.dev @IJSDEVS@ 636#DEVICE_DEVS6=$(DD)bj10e.dev $(DD)bj200.dev $(DD)bjc600.dev $(DD)bjc800.dev 637#DEVICE_DEVS7=$(DD)faxg3.dev $(DD)faxg32d.dev $(DD)faxg4.dev $(DD)cfax.dev 638#DEVICE_DEVS8=$(DD)pcxmono.dev $(DD)pcxgray.dev $(DD)pcx16.dev $(DD)pcx256.dev $(DD)pcx24b.dev $(DD)pcxcmyk.dev 639#DEVICE_DEVS9=$(DD)pbm.dev $(DD)pbmraw.dev $(DD)pgm.dev $(DD)pgmraw.dev $(DD)pgnm.dev $(DD)pgnmraw.dev $(DD)pnm.dev $(DD)pnmraw.dev $(DD)ppm.dev $(DD)ppmraw.dev $(DD)pkm.dev $(DD)pkmraw.dev $(DD)pksm.dev $(DD)pksmraw.dev 640#DEVICE_DEVS10=$(DD)tiffcrle.dev $(DD)tiffg3.dev $(DD)tiffg32d.dev $(DD)tiffg4.dev $(DD)tifflzw.dev $(DD)tiffpack.dev 641#DEVICE_DEVS11=$(DD)tiff12nc.dev $(DD)tiff24nc.dev $(DD)tiff48nc.dev $(DD)tiffgray.dev $(DD)tiff32nc.dev $(DD)tiff64nc $(DD)tiffsep.dev $(DD)tiffsep1.dev 642#DEVICE_DEVS12=$(DD)bit.dev $(DD)bitrgb.dev $(DD)bitcmyk.dev 643#DEVICE_DEVS13=$(DD)pngmono.dev $(DD)pnggray.dev $(DD)png16.dev $(DD)png256.dev $(DD)png16m.dev 644#DEVICE_DEVS13=@PNGDEVS@ 645#DEVICE_DEVS14=$(DD)jpeg.dev $(DD)jpeggray.dev 646#DEVICE_DEVS15=$(DD)pdfwrite.dev $(DD)ps2write.dev $(DD)eps2write.dev $(DD)txtwrite.dev $(DD)pxlmono.dev $(DD)pxlcolor.dev 647#DEVICE_DEVS16=$(DD)bbox.dev 648 649#DEVICE_DEVS17= 650#DEVICE_DEVS18= 651#DEVICE_DEVS19= 652#DEVICE_DEVS20=$(DD)cljet5.dev $(DD)cljet5c.dev 653#DEVICE_DEVS21=$(DD)spotcmyk.dev $(DD)devicen.dev $(DD)xcf.dev $(DD)psdcmyk.dev $(DD)psdrgb.dev $(DD)psdcmykog.dev $(DD)fpng.dev 654DEVICE_DEVS=$(DISPLAY_DEV) @X11_DEVS@ 655DEVICE_DEVS1=@F_DEVS@ 656DEVICE_DEVS2=@P_DEVS@ 657DEVICE_DEVS3=@CUPS_DEVS@ 658DEVICE_DEVS4=@IJS_DEVS@ 659DEVICE_DEVS5= 660DEVICE_DEVS6=@PNG_DEVS@ 661DEVICE_DEVS7=@JBIG2_DEVS@ 662DEVICE_DEVS8= 663DEVICE_DEVS9=@XPS_DEVS@ 664DEVICE_DEVS10= 665DEVICE_DEVS11= 666DEVICE_DEVS12= 667DEVICE_DEVS13= 668DEVICE_DEVS14= 669DEVICE_DEVS15= 670DEVICE_DEVS16= 671DEVICE_DEVS17= 672DEVICE_DEVS18= 673DEVICE_DEVS19= 674DEVICE_DEVS20= 675DEVICE_DEVS21= 676 677 678# Shared library target to build. 679GS_SHARED_OBJS=@DYNAMIC_DEVS@ 680 681# ---------------------------- End of options --------------------------- # 682 683# Define the name of the partial makefile that specifies options -- 684# used in dependencies. 685 686MAKEFILE=Makefile 687TOP_MAKEFILES=$(MAKEFILE) $(GLSRCDIR)/unixhead.mak 688 689# for use in unix-dll.mak and unix-end.mak 690# if you rename the Makefile, you *must* also set this to the new name 691SUB_MAKE_OPTION=@SUB_MAKE_OPTION@ 692 693# Define the auxiliary program dependency. We don't use this. 694 695AK= 696 697# Define the compilation rules and flags. 698 699CCFLAGS=$(GENOPT) $(CAPOPT) $(CFLAGS) 700CC_=$(CC) $(CCFLAGS) 701CC_LEAF=$(CC_) 702 703CCFLAGSAUX=$(GENOPTAUX) $(CAPOPTAUX) $(CFLAGSAUX) 704CCAUX_=$(CCAUX) $(CCFLAGSAUX) 705 706# note gcc can't use -fomit-frame-pointer with -pg. 707CC_LEAF_PG=$(CC_) 708# These are the specific warnings we have to turn off to compile those 709# specific few files that need this. We may turn off others in the future. 710CC_NO_WARN=$(CC_) 711CCAUX_NO_WARN=$(CCAUX_) 712CC_SHARED=$(CC_) @DYNAMIC_CFLAGS@ 713 714LD_SET_DT_SONAME=@SET_DT_SONAME@ 715 716# MAKEDIRS = the dependency on ALL object files (must be the last one on 717# the line. Requires GNU make to make it an 'order only' dependency 718# MAKEDIRSTOP = the topmost dependency - set this if you can't set MAKEDIRS 719 720MAKEDIRS=@ORDER_ONLY@ directories 721MAKEDIRSTOP= 722 723# ---------------- End of platform-specific section ---------------- # 724 725INSTALL_CONTRIB=@INSTALL_CONTRIB@ 726include $(GLSRCDIR)/unixhead.mak 727include $(GLSRCDIR)/gs.mak 728# *romfs.mak must precede lib.mak 729include @PLROMFS_MAK@ # plromfs.mak 730include @XPSROMFS_MAK@ # xpsromfs.mak 731 732include $(PSSRCDIR)/psromfs.mak 733include $(GLSRCDIR)/lib.mak 734include $(PSSRCDIR)/int.mak 735 736include @PL_MAK@ # pl.mak 737include @PCL_MAK@ # pcl.mak 738include @PCL_TOP_MAK@ # pcl_top.mak 739include @PXL_MAK@ # pxl.mak 740 741include @XPS_MAK@ # xps.mak 742 743include @GPDL_MAK@ # gpdl.mak 744 745include $(GLSRCDIR)/freetype.mak 746include @FAPIUFST_MAK@ 747include $(GLSRCDIR)/jpeg.mak 748# zlib.mak must precede png.mak 749include $(GLSRCDIR)/zlib.mak 750include $(GLSRCDIR)/png.mak 751include $(GLSRCDIR)/tiff.mak 752include $(GLSRCDIR)/jbig2.mak 753include $(GLSRCDIR)/ldf_jb2.mak 754include $(GLSRCDIR)/lwf_jp2.mak 755include $(GLSRCDIR)/openjpeg.mak 756include $(GLSRCDIR)/cal.mak 757 758include $(GLSRCDIR)/jpegxr.mak 759include $(GLSRCDIR)/expat.mak 760 761include $(GLSRCDIR)/$(WHICH_CMS).mak 762include $(GLSRCDIR)/ijs.mak 763@LCUPSINCLUDE@ 764@LCUPSIINCLUDE@ 765include $(DEVSRCDIR)/devs.mak 766include $(DEVSRCDIR)/contrib.mak 767include $(GLSRCDIR)/unix-aux.mak 768include $(GLSRCDIR)/unixlink.mak 769include $(GLSRCDIR)/unix-dll.mak 770include $(GLSRCDIR)/unix-end.mak 771include $(GLSRCDIR)/unixinst.mak 772@CONTRIBINCLUDE@ 773@CUPSINCLUDE@ 774 775# Clean up after the autotools scripts 776distclean : clean config-clean soclean pgclean debugclean mementoclean 777 -$(RM_) -r $(BINDIR) $(GLOBJDIR) $(PSOBJDIR) $(AUXDIR) 778 -$(RM_) -r autom4te.cache 779 -$(RM_) config.log config.status configaux.log @ARCH_AUTOCONF_HEADER@ 780 -$(RM_) -r $(TIFFCONFDIR) 781 -$(RM_) Makefile 782 783# a debug-clean target for consistency with the ghostpdl builds 784debug-clean : debugclean 785 786memento-clean : mementoclean 787 788maintainer-clean : distclean 789 -$(RM_) configure 790 791check : default 792 $(NO_OP) 793