1# Copyright (C) 2001-2019 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# Makefile.  Generated from Makefile.in by configure.
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
26BINDIR=./$(BUILDDIRPREFIX)bin
27GLSRCDIR=./base
28DEVSRCDIR=./devices
29GLGENDIR=./$(BUILDDIRPREFIX)obj
30GLOBJDIR=./$(BUILDDIRPREFIX)obj
31DEVGENDIR=./$(BUILDDIRPREFIX)obj
32DEVOBJDIR=./$(BUILDDIRPREFIX)obj
33AUXDIR=$(GLGENDIR)/aux
34PSSRCDIR=./psi
35PSLIBDIR=./lib
36PSRESDIR=./Resource
37PSGENDIR=./$(BUILDDIRPREFIX)obj
38PSOBJDIR=./$(BUILDDIRPREFIX)obj
39
40PCL5SRCDIR=./pcl/pcl
41PCL5GENDIR=./$(BUILDDIRPREFIX)obj
42PCL5OBJDIR=./$(BUILDDIRPREFIX)obj
43
44PXLSRCDIR=./pcl/pxl
45PXLGENDIR=./$(BUILDDIRPREFIX)obj
46PXLOBJDIR=./$(BUILDDIRPREFIX)obj
47
48PLSRCDIR=./pcl/pl
49PLGENDIR=./$(BUILDDIRPREFIX)obj
50PLOBJDIR=./$(BUILDDIRPREFIX)obj
51
52XPSSRCDIR=./xps
53XPSGENDIR=./$(BUILDDIRPREFIX)obj
54XPSOBJDIR=./$(BUILDDIRPREFIX)obj
55
56GPDLSRCDIR=./gpdl
57GPDLGENDIR=./$(BUILDDIRPREFIX)obj
58GPDLOBJDIR=./$(BUILDDIRPREFIX)obj
59
60
61CONTRIBDIR=./contrib
62
63# Do not edit the next group of lines.
64
65include $(GLSRCDIR)/version.mak
66DD=$(GLGENDIR)/
67GLD=$(GLGENDIR)/
68PSD=$(PSGENDIR)/
69
70# ------ Generic options ------ #
71
72# Define the installation commands and target directories for
73# executables and files.  The commands are only relevant to `make install';
74# the directories also define the default search path for the
75# initialization files (gs_*.ps) and the fonts.
76
77INSTALL = $(GLSRCDIR)/instcopy -c
78INSTALL_PROGRAM = $(INSTALL) -m 755
79INSTALL_DATA = $(INSTALL) -m 644
80INSTALL_SHARED =
81
82prefix = /usr/local
83exec_prefix = ${prefix}
84bindir = ${exec_prefix}/bin
85scriptdir = $(bindir)
86includedir = ${prefix}/include
87libdir = ${exec_prefix}/lib
88mandir = ${datarootdir}/man
89man1ext = 1
90man1dir = $(mandir)/man$(man1ext)
91datadir = ${datarootdir}
92datarootdir = ${prefix}/share
93
94# The following must be substituted using ${datarootdir} and ${exec_prefix}/lib
95# to avoid adding RPM generation paths (CUPS STR #1112)
96gsdir = ${datarootdir}/ghostscript
97gsdatadir = $(gsdir)/$(GS_DOT_VERSION)
98gssharedir = ${exec_prefix}/lib/ghostscript/$(GS_DOT_VERSION)
99gsincludedir = ${prefix}/include/ghostscript/
100
101docdir=$(gsdatadir)/doc
102exdir=$(gsdatadir)/examples
103GS_DOCDIR=$(docdir)
104
105# Choose whether to compile the .ps initialization files into the executable.
106# See gs.mak for details.
107
108COMPILE_INITS=1
109
110# Define the default directory/ies for the runtime
111# initialization and font files.  Separate multiple directories with a :.
112
113GS_LIB_DEFAULT=$(gsdatadir)/Resource/Init:$(gsdatadir)/lib:$(gsdatadir)/Resource/Font:$(gsdir)/fonts:${datarootdir}/fonts/default/ghostscript:${datarootdir}/fonts/default/Type1:${datarootdir}/fonts/default/TrueType:/usr/lib/DPS/outline/base:/usr/openwin/lib/X11/fonts/Type1:/usr/openwin/lib/X11/fonts/TrueType
114
115# Define the default directory for cached data files
116# this must be a single path.
117
118GS_CACHE_DIR="~/.ghostscript/cache/"
119
120# Define whether or not searching for initialization files should always
121# look in the current directory first.  This leads to well-known security
122# and confusion problems,  but may be convenient sometimes.
123
124SEARCH_HERE_FIRST=0
125
126# Define the name of the interpreter initialization file.
127# (There is no reason to change this.)
128
129GS_INIT=gs_init.ps
130
131# Choose generic configuration options.
132
133TARGET_ARCH_FILE=
134
135# -DDEBUG
136#	includes debugging features (-Z switch) in the code.
137#	  Code runs substantially slower even if no debugging switches
138#	  are set.
139
140GENOPT=
141
142# Choose capability options.
143
144# -DHAVE_BSWAP32
145#       use bswap32 intrinsic
146# -DHAVE_BYTESWAP_H
147#       use byteswap.h functions
148#
149# -DHAVE_MKSTEMP
150#	uses mkstemp instead of mktemp
151#		This uses the more secure temporary file creation call
152#		Enable this if it is available on your platform.
153# -DHAVE_FILE64
154#	use marked versions of the stdio FILE calls, fopen64() et al.
155#
156# -DHAVE_MKSTEMP64
157#	use non-standard function mkstemp64()
158#
159# -DHAVE_LIBIDN
160#	use libidn to canonicalize Unicode passwords
161#
162# -DHAVE_SETLOCALE
163#	call setlocale(LC_CTYPE) when running as a standalone app
164# -DHAVE_SSE2
165#       use sse2 intrinsics
166
167CAPOPT= -DHAVE_MKSTEMP -DHAVE_FILE64 -DHAVE_FSEEKO -DHAVE_MKSTEMP64   -DHAVE_SETLOCALE -DHAVE_SSE2  -DHAVE_BSWAP32 -DHAVE_BYTESWAP_H -DHAVE_STRERROR -DHAVE_PREAD_PWRITE=1 -DGS_RECURSIVE_MUTEXATTR=PTHREAD_MUTEX_RECURSIVE
168
169# Define the name of the executable file.
170
171GS=gs
172GS_SO_BASE=gs
173
174PCL=gpcl6
175XPS=gxps
176GPDL=gpdl
177
178XE=
179XEAUX=
180
181PCL_XPS_PDL_TARGETS=
182
183# Define the directories for debugging and profiling binaries, relative to
184# the standard binaries.
185
186DEBUGDIRPREFIX=debug
187MEMENTODIRPREFIX=mem
188PGDIRPREFIX=pg
189
190# Define whether to compile in the FreeType library, and if so, where
191# the source tree is location. Otherwise, what library name to use
192# in linking to a shared implementation.
193
194FT_BRIDGE=1
195SHARE_FT=0
196FTSRCDIR=./freetype
197FT_CFLAGS=-I./freetype/include
198FT_LIBS=
199FT_CONFIG_SYSTEM_ZLIB=
200
201# Define whether to compile in UFST.
202# FAPI/UFST depends on UFST_BRIDGE being undefined - hence the construct below.
203# (i.e. use "UFST_BRIDGE=1" or *not to define UFST_BRIDGE to anything*)
204# As UFST is not used for fonts embedded in input files, we should still have
205# Freetype enabled, above.
206
207UFST_ROOT=
208UFST_LIB_EXT=
209
210UFST_ROMFS_ARGS?=-b \
211 -P $(UFST_ROOT)/fontdata/mtfonts/pcl45/mt3/ -d fontdata/mtfonts/pcl45/mt3/ pcl___xj.fco plug__xi.fco wd____xh.fco \
212 -P $(UFST_ROOT)/fontdata/mtfonts/pclps2/mt3/ -d fontdata/mtfonts/pclps2/mt3/ pclp2_xj.fco \
213 -c -P $(PSSRCDIR)/../lib/ -d Resource/Init/ FAPIconfig-FCO
214
215UFSTROMFONTDIR=\"%rom%fontdata/\"
216UFSTDISCFONTDIR?=\"$(UFST_ROOT)/fontdata/\"
217
218
219UFST_CFLAGS=
220
221# Define the directory where the IJG JPEG library sources are stored,
222# and the major version of the library that is stored there.
223# You may need to change this if the IJG library version changes.
224# See jpeg.mak for more information.
225
226JSRCDIR=./jpeg
227
228# Note: if a shared library is used, it may not contain the
229# D_MAX_BLOCKS_IN_MCU patch, and thus may not be able to read
230# some older JPEG streams that violate the standard. If the JPEG
231# library built from local sources, the patch will be applied.
232
233SHARE_JPEG=0
234JPEG_NAME=jpeg
235
236# Define the directory where the PNG library sources are stored,
237# and the version of the library that is stored there.
238# You may need to change this if the libpng version changes.
239# See png.mak for more information.
240
241SHARE_LIBPNG=0
242PNGSRCDIR=./libpng
243LIBPNG_NAME=png
244
245# libtiff
246SHARE_LIBTIFF=0
247TIFFSRCDIR=
248TIFFCONFDIR=
249TIFFPLATFORM=unix
250TIFFCONFIG_SUFFIX=
251LIBTIFF_NAME=tiff
252
253# Define the directory where the zlib sources are stored.
254# See zlib.mak for more information.
255
256SHARE_ZLIB=0
257ZSRCDIR=./zlib
258#ZLIB_NAME=gz
259ZLIB_NAME=z
260
261# Choose shared or compiled in libjbig2dec and source location
262# JBIG2_LIB=jbig2dec
263JBIG2_LIB=jbig2dec
264SHARE_JBIG2=0
265JBIG2SRCDIR=./jbig2dec
266JBIG2_CFLAGS=-DHAVE_STDINT_H=1
267
268# uncomment the following three lines and one of the last two to
269# compile in the Luratech ldf_jb2 codec
270#JBIG2_LIB=luratech
271#SHARE_JBIG2=0
272#JBIG2SRCDIR=ldf_jb2
273#JBIG2_CFLAGS=-DUSE_LDF_JB2 -DLINUX
274#JBIG2_CFLAGS=-DUSE_LDF_JB2 -DMAC -DMAC_OS_X_BUILD
275
276
277# Choose the library to use for (JPXDecode support)
278# whether to link to an external build or compile in from source
279# and source location and configuration flags for compiling in
280JPX_LIB=openjpeg
281SHARE_JPX=0
282JPXSRCDIR=./openjpeg
283JPX_CFLAGS=  -DUSE_JPIP -DUSE_OPENJPEG_JP2 -DOPJ_HAVE_STDINT_H=1 -DOPJ_HAVE_INTTYPES_H=1  -DOPJ_HAVE_FSEEKO=1
284
285# uncomment the following three lines and one of the last two to
286# compile in the Luratech lwf_jp2 codec
287#JPX_LIB=luratech
288#SHARE_JPX=0
289#JPXSRCDIR=lwf_jp2
290#JPX_CFLAGS=-DUSE_LWF_JP2 -DLINUX
291#JPX_CFLAGS=-DUSE_LWF_JP2 -DMAC -DMAC_OS_X_BUILD
292
293# Uncomment the following 4 lines to to compile in OpenJPEG codec
294#JPX_LIB=openjpeg
295#SHARE_JPX=0
296#JPXSRCDIR=openjpeg
297#JPX_CFLAGS=-DUSE_OPENJPEG_JP2 -DOPJ_STATIC
298
299# options for lcms color management library
300SHARE_LCMS=0
301LCMS2SRCDIR=./lcms2mt
302LCMS2_CFLAGS=-DSHARE_LCMS=$(SHARE_LCMS) -DCMS_USE_BIG_ENDIAN=0
303
304LCMS2MTSRCDIR=./lcms2mt
305LCMS2_CFLAGS=-DSHARE_LCMS=$(SHARE_LCMS) -DCMS_USE_BIG_ENDIAN=0
306
307# Which CMS are we using?
308# Options are currently lcms2mt or lcms2
309WHICH_CMS=lcms2mt
310
311EXPATSRCDIR=./expat
312EXPAT_CFLAGS=-DHAVE_MEMMOVE
313EXPATGENDIR=$(GLGENDIR)
314EXPATOBJDIR=$(GLOBJDIR)
315EXPATINCDIR = $(EXPATSRCDIR)$(D)lib
316SHARE_EXPAT=0
317
318JPEGXR_SRCDIR=./jpegxr
319SHARE_JPEGXR=0
320JPEGXR_GENDIR=$(GLGENDIR)
321JPEGXR_OBJDIR=$(GLOBJDIR)
322
323# Define the directory where the ijs source is stored,
324# and the process forking method to use for the server.
325# See ijs.mak for more information.
326
327SHARE_IJS=0
328IJS_NAME=
329IJSSRCDIR=./ijs
330IJSEXECTYPE=unix
331
332# Define install location for 'cups' device/filter support
333CUPSLIBS=
334CUPSLIBDIRS=
335CUPSSERVERBIN=
336CUPSSERVERROOT=
337CUPSDATA=
338CUPSPDFTORASTER=0
339
340SHARE_LCUPS=1
341LCUPS_NAME=cups
342LCUPSSRCDIR=./cups
343LCUPSBUILDTYPE=
344CUPS_CC=$(CC)
345
346SHARE_LCUPSI=1
347LCUPSI_NAME=cupsimage
348LCUPSISRCDIR=./cups
349CUPS_CC=$(CC)
350
351CUPSCFLAGS= -DSHARE_LCUPS=$(SHARE_LCUPS) -DSHARE_LCUPSI=$(SHARE_LCUPSI)
352
353# Define how to build the library archives.  (These are not used in any
354# standard configuration.)
355
356AR=ar
357ARFLAGS=qc
358RANLIB=ranlib
359
360# ------ Platform-specific options ------ #
361
362# Define the name of the C compiler (target and host (AUX))
363
364CC=gcc
365CCAUX=gcc
366
367# Define the name of the linker for the final link step.
368# Normally this is the same as the C compiler.
369
370CCLD=$(CC)
371CCAUXLD=$(CCAUX)
372
373# Define the default gcc flags.
374GCFLAGS=  -Wall -Wstrict-prototypes -Wundef -Wmissing-declarations -Wmissing-prototypes -Wwrite-strings -Wno-strict-aliasing -Werror=declaration-after-statement -fno-builtin -fno-common -Werror=return-type -DHAVE_STDINT_H=1 -DHAVE_DIRENT_H=1 -DHAVE_SYS_DIR_H=1 -DHAVE_SYS_TIME_H=1 -DHAVE_SYS_TIMES_H=1 -DHAVE_INTTYPES_H=1 -DGX_COLOR_INDEX_TYPE="unsigned long int" -D__USE_UNIX98=1   -DNOCONTRIB
375
376# Define the added flags for standard, debugging, profiling
377# and shared object builds.
378
379CFLAGS_STANDARD= -O2 -DNDEBUG
380CFLAGS_DEBUG= -g -O0
381CFLAGS_PROFILE=-pg  -O2 -DNDEBUG
382CFLAGS_SO=-fPIC
383
384# Define the other compilation flags.  Add at most one of the following:
385#	-DBSD4_2 for 4.2bsd systems.
386#	-DSYSV for System V or DG/UX.
387# 	-DSYSV -D__SVR3 for SCO ODT, ISC Unix 2.2 or before,
388#	   or any System III Unix, or System V release 3-or-older Unix.
389#	-DSVR4 -DSVR4_0 (not -DSYSV) for System V release 4.0.
390#	-DSVR4 (not -DSYSV) for System V release 4.2 (or later) and Solaris 2.
391# XCFLAGS can be set from the command line.
392# We don't include -ansi, because this gets in the way of the platform-
393#   specific stuff that <math.h> typically needs; nevertheless, we expect
394#   gcc to accept ANSI-style function prototypes and function definitions.
395# CFLAGS from autoconf
396AC_CFLAGS=
397
398# fontconfig flags, used by unix-aux.mak
399FONTCONFIG_CFLAGS=
400FONTCONFIG_LIBS=
401
402# DBus flags, used by cups.mak
403DBUS_CFLAGS=
404DBUS_LIBS=
405
406# defines from autoconf; note that we don't use all of these at present.
407ACDEFS=-DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DHAVE_DIRENT_H=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_ERRNO_H=1 -DHAVE_FCNTL_H=1 -DHAVE_LIMITS_H=1 -DHAVE_MALLOC_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_STRINGS_H=1 -DHAVE_SYS_IOCTL_H=1 -DHAVE_SYS_PARAM_H=1 -DHAVE_SYS_TIME_H=1 -DHAVE_SYS_TIMES_H=1 -DHAVE_SYSLOG_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DIRENT_H=1 -DHAVE_SYS_DIR_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STRUCT_STAT_ST_BLOCKS=1 -DHAVE_ST_BLOCKS=1 -DTIME_WITH_SYS_TIME=1 -DSIZEOF_UNSIGNED_LONG_INT=8 -DHAVE_LIBM=1 -DHAVE_PREAD=1 -DHAVE_PWRITE=1 -DHAVE_DECL_PWRITE=1 -DHAVE_DECL_PREAD=1 -DHAVE_LIBDL=1 -DHAVE_FSEEKO=1 -DHAVE_MEMALIGN=1 -DX_DISPLAY_MISSING=1 -DHAVE_MKSTEMP=1 -DHAVE_FOPEN64=1 -DHAVE_FSEEKO=1 -DHAVE_MKSTEMP64=1 -DHAVE_SETLOCALE=1 -DHAVE_STRERROR=1 -DHAVE_FORK=1 -DHAVE_VFORK=1 -DHAVE_WORKING_VFORK=1 -DHAVE_WORKING_FORK=1 -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=1 -DRETSIGTYPE=void -DLSTAT_FOLLOWS_SLASHED_SYMLINK=1 -DHAVE_VPRINTF=1 -DHAVE_BZERO=1 -DHAVE_DUP2=1 -DHAVE_FLOOR=1 -DHAVE_GETTIMEOFDAY=1 -DHAVE_MEMCHR=1 -DHAVE_MEMMOVE=1 -DHAVE_MEMSET=1 -DHAVE_MKDIR=1 -DHAVE_MKFIFO=1 -DHAVE_MODF=1 -DHAVE_POW=1 -DHAVE_PUTENV=1 -DHAVE_RINT=1 -DHAVE_SETENV=1 -DHAVE_SQRT=1 -DHAVE_STRCHR=1 -DHAVE_STRRCHR=1 -DHAVE_STRSPN=1 -DHAVE_STRSTR=1 -DHAVE_STRNLEN=1
408
409CFLAGS=$(CFLAGS_STANDARD) $(GCFLAGS) $(AC_CFLAGS) $(XCFLAGS)
410
411# Define platform flags for ld.
412# SunOS 4.n may need -Bstatic.
413# Solaris 2.6 (and possibly some other versions) with any of the SHARE_
414# parameters set to 1 may need
415#	-R /usr/local/xxx/lib:/usr/local/lib
416# giving the full path names of the shared library directories.
417# XLDFLAGS can be set from the command line.
418# AC_LDFLAGS from autoconf
419AC_LDFLAGS=
420
421LDFLAGS= $(AC_LDFLAGS) $(XLDFLAGS)
422
423GS_LDFLAGS=$(LDFLAGS)
424PCL_LDFLAGS=$(LDFLAGS)
425XPS_LDFLAGS=$(LDFLAGS)
426
427GS_LDFLAGS_SO=-shared -Wl,$(LD_SET_DT_SONAME)$(LDFLAGS_SO_PREFIX)$(GS_SONAME_MAJOR)
428PCL_LDFLAGS_SO=-shared -Wl,$(LD_SET_DT_SONAME)$(LDFLAGS_SO_PREFIX)$(PCL_SONAME_MAJOR)
429XPS_LDFLAGS_SO=-shared -Wl,$(LD_SET_DT_SONAME)$(LDFLAGS_SO_PREFIX)$(XPS_SONAME_MAJOR)
430
431# Define any extra libraries to link into the executable.
432# ISC Unix 2.2 wants -linet.
433# SCO Unix needs -lsocket if you aren't including the X11 driver.
434# SVR4 may need -lnsl.
435# Solaris may need -lnsl -lsocket -lposix4.
436# (Libraries required by individual drivers are handled automatically.)
437
438EXTRALIBS=$(XTRALIBS) -ldl -lm  -rdynamic -ldl
439AUXEXTRALIBS=$(XTRALIBS) -ldl -lm  -rdynamic -ldl
440
441# Define the standard libraries to search at the end of linking.
442# Most platforms require -lpthread for the POSIX threads library;
443# on FreeBSD, change -lpthread to -lc_r; BSDI and perhaps some others
444# include pthreads in libc and don't require any additional library.
445# All reasonable platforms require -lm, but Rhapsody and perhaps one or
446# two others fold libm into libc and don't require any additional library.
447
448# STDLIBS=-lpthread -lm
449STDLIBS=-lm
450
451# Define the include switch(es) for the X11 header files.
452# This can be null if handled in some other way (e.g., the files are
453# in /usr/include, or the directory is supplied by an environment variable)
454
455XINCLUDE=
456
457# Define the directory/ies and library names for the X11 library files.
458# XLIBDIRS is for ld and should include -L; XLIBDIR is for LD_RUN_PATH
459# (dynamic libraries on SVR4) and should not include -L.
460# Newer SVR4 systems can use -R in XLIBDIRS rather than setting XLIBDIR.
461# Both can be null if these files are in the default linker search path.
462
463# Solaris and other SVR4 systems with dynamic linking probably want
464#XLIBDIRS=-L/usr/openwin/lib -R/usr/openwin/lib
465# X11R6 (on any platform) may need
466#XLIBS=Xt SM ICE Xext X11
467
468# We use the autoconf macro AC_PATH_XTRA which defines X_LIBS with
469# the -L (or whatever). It also defines X_PRE_LIBS and X_EXTRA_LIBS
470# all three of which are stripped and slotted into XLIBS below.
471# Usually however, all but X_LIBS are empty on modern platforms.
472XLIBDIRS=
473XLIBDIR=
474# XLIBS= Xt Xext X11
475XLIBS=
476
477# Define the .dev module that implements thread and synchronization
478# primitives for this platform.
479
480# If POSIX sync primitives are used, also change the STDLIBS to include
481# the pthread library. Otherwise use SYNC=nosync
482#SYNC=posync
483#SYNC=nosync
484SYNC=nosync
485
486# programs we use
487RM=rm -f
488
489# ------ Dynamic loader options ------- #
490SOC_CFLAGS	=
491SOC_LIBS	=
492SOC_LOADER	=	dxmainc.c
493
494# on virtually every Unix-a-like system, this is "so",
495# but Apple just had to be different, so it's now set
496# by configure
497SO_LIB_EXT=.so
498DLL_EXT=
499SO_LIB_VERSION_SEPARATOR=.
500
501#CAIRO_CFLAGS	=	@CAIRO_CFLAGS@
502#CAIRO_LIBS	=	@CAIRO_LIBS@
503
504# ------ Devices and features ------ #
505
506# Choose the language feature(s) to include.  See gs.mak for details.
507
508# if it's included, $(PSD)gs_pdfwr.dev should always be one of the last in the list
509PSI_FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev $(PSD)epsf.dev $(PSD)ttfont.dev \
510                  $(PSD)fapi_ps.dev $(PSD)jpx.dev $(PSD)jbig2.dev $(PSD)gs_pdfwr.dev
511
512
513PCL_FEATURE_DEVS=$(PLOBJDIR)/pl.dev $(PLOBJDIR)/pjl.dev $(PXLOBJDIR)/pxl.dev $(PCL5OBJDIR)/pcl5c.dev \
514             $(PCL5OBJDIR)/hpgl2c.dev
515
516XPS_FEATURE_DEVS=$(XPSOBJDIR)/pl.dev $(XPSOBJDIR)/xps.dev
517
518FEATURE_DEVS=$(GLD)pipe.dev $(GLD)gsnogc.dev $(GLD)htxlib.dev $(GLD)psl3lib.dev $(GLD)psl2lib.dev \
519             $(GLD)dps2lib.dev $(GLD)path1lib.dev $(GLD)patlib.dev $(GLD)psl2cs.dev $(GLD)rld.dev $(GLD)gxfapiu$(UFST_BRIDGE).dev\
520             $(GLD)ttflib.dev  $(GLD)cielib.dev $(GLD)pipe.dev $(GLD)htxlib.dev $(GLD)sdct.dev $(GLD)libpng.dev\
521	     $(GLD)seprlib.dev $(GLD)translib.dev $(GLD)cidlib.dev $(GLD)psf0lib.dev $(GLD)psf1lib.dev\
522             $(GLD)psf2lib.dev $(GLD)lzwd.dev $(GLD)sicclib.dev \
523             $(GLD)sjbig2.dev $(GLD)sjpx.dev $(GLD)ramfs.dev \
524             $(GLD)pwgd.dev $(GLD)urfd.dev
525
526
527
528
529#FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev
530#FEATURE_DEVS=$(PSD)psl3.dev $(PSD)pdf.dev $(PSD)ttfont.dev $(GLD)pipe.dev
531# The following is strictly for testing.
532FEATURE_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 $(PSD)jbig2.dev $(PSD)jpx.dev  $(GLD)ramfs.dev
533#FEATURE_DEVS=$(FEATURE_DEVS_ALL)
534
535# The list of resources to be included in the %rom% file system.
536# This is in the top makefile since the file descriptors are platform specific
537RESOURCE_LIST=Resource/CMap/ Resource/ColorSpace/ Resource/Decoding/ Resource/Font/ Resource/ProcSet/ Resource/IdiomSet/ Resource/CIDFont/
538
539# Choose whether to store band lists on files or in memory.
540# The choices are 'file' or 'memory'.
541
542BAND_LIST_STORAGE=file
543
544# Choose which compression method to use when storing band lists in memory.
545# The choices are 'lzw' or 'zlib'.
546
547BAND_LIST_COMPRESSOR=zlib
548
549# Choose the implementation of file I/O: 'stdio', 'fd', or 'both'.
550# See gs.mak and sfxfd.c for more details.
551
552FILE_IMPLEMENTATION=stdio
553
554# List of default devices, in order of priority. They need not be
555# present in the actual build.
556GS_DEV_DEFAULT="x11alpha bbox"
557
558# Fallback default device.  This is set to 'display' by
559# unix-dll.mak when building a shared object.
560DISPLAY_DEV=$(DD)bbox.dev
561
562# Choose the device(s) to include.  See devs.mak for details,
563# devs.mak and contrib.mak for the list of available devices.
564# DEVICE_DEVS=$(DISPLAY_DEV) $(DD)x11.dev $(DD)x11_.dev $(DD)x11alpha.dev $(DD)x11alt_.dev $(DD)x11cmyk.dev $(DD)x11cmyk2.dev $(DD)x11cmyk4.dev $(DD)x11cmyk8.dev $(DD)x11gray2.dev $(DD)x11gray4.dev $(DD)x11mono.dev $(DD)x11rg16x.dev $(DD)x11rg32x.dev
565DEVICE_DEVS=$(DISPLAY_DEV)
566DEVICE_DEVS1=$(DD)bit.dev $(DD)bitcmyk.dev $(DD)bitrgb.dev $(DD)bitrgbtags.dev $(DD)bmp16.dev $(DD)bmp16m.dev $(DD)bmp256.dev $(DD)bmp32b.dev $(DD)bmpgray.dev $(DD)bmpmono.dev $(DD)bmpsep1.dev $(DD)bmpsep8.dev $(DD)ccr.dev $(DD)cif.dev $(DD)devicen.dev $(DD)eps2write.dev $(DD)fpng.dev $(DD)inferno.dev $(DD)ink_cov.dev $(DD)inkcov.dev $(DD)jpeg.dev $(DD)jpegcmyk.dev $(DD)jpeggray.dev $(DD)mgr4.dev $(DD)mgr8.dev $(DD)mgrgray2.dev $(DD)mgrgray4.dev $(DD)mgrgray8.dev $(DD)mgrmono.dev $(DD)miff24.dev $(DD)pam.dev $(DD)pamcmyk32.dev $(DD)pamcmyk4.dev $(DD)pbm.dev $(DD)pbmraw.dev $(DD)pcx16.dev $(DD)pcx24b.dev $(DD)pcx256.dev $(DD)pcxcmyk.dev $(DD)pcxgray.dev $(DD)pcxmono.dev $(DD)pdfwrite.dev $(DD)pgm.dev $(DD)pgmraw.dev $(DD)pgnm.dev $(DD)pgnmraw.dev $(DD)pkm.dev $(DD)pkmraw.dev $(DD)pksm.dev $(DD)pksmraw.dev $(DD)plan.dev $(DD)plan9bm.dev $(DD)planc.dev $(DD)plang.dev $(DD)plank.dev $(DD)planm.dev $(DD)plank.dev $(DD)plib.dev $(DD)plibc.dev $(DD)plibg.dev $(DD)plibk.dev $(DD)plibm.dev $(DD)pnm.dev $(DD)pnmraw.dev $(DD)ppm.dev $(DD)ppmraw.dev $(DD)ps2write.dev $(DD)psdcmyk.dev $(DD)psdcmykog.dev $(DD)psdf.dev $(DD)psdrgb.dev $(DD)spotcmyk.dev $(DD)txtwrite.dev $(DD)xcf.dev $(DD)psdcmyk16.dev $(DD)psdrgb16.dev
567DEVICE_DEVS2=$(DD)ap3250.dev $(DD)atx23.dev $(DD)atx24.dev $(DD)atx38.dev $(DD)bj10e.dev $(DD)bj200.dev $(DD)bjc600.dev $(DD)bjc800.dev $(DD)cdeskjet.dev $(DD)cdj500.dev $(DD)cdj550.dev $(DD)cdjcolor.dev $(DD)cdjmono.dev $(DD)cljet5.dev $(DD)cljet5c.dev $(DD)cljet5pr.dev $(DD)coslw2p.dev $(DD)coslwxl.dev $(DD)declj250.dev $(DD)deskjet.dev $(DD)dj505j.dev $(DD)djet500.dev $(DD)djet500c.dev $(DD)dnj650c.dev $(DD)eps9high.dev $(DD)eps9mid.dev $(DD)epson.dev $(DD)epsonc.dev $(DD)escp.dev $(DD)fs600.dev $(DD)hl7x0.dev $(DD)ibmpro.dev $(DD)imagen.dev $(DD)itk24i.dev $(DD)itk38.dev $(DD)jetp3852.dev $(DD)laserjet.dev $(DD)lbp8.dev $(DD)lips3.dev $(DD)lj250.dev $(DD)lj3100sw.dev $(DD)lj4dith.dev $(DD)lj4dithp.dev $(DD)lj5gray.dev $(DD)lj5mono.dev $(DD)ljet2p.dev $(DD)ljet3.dev $(DD)ljet3d.dev $(DD)ljet4.dev $(DD)ljet4d.dev $(DD)ljet4pjl.dev $(DD)ljetplus.dev $(DD)lp2563.dev $(DD)lp8000.dev $(DD)lq850.dev $(DD)lxm5700m.dev $(DD)m8510.dev $(DD)necp6.dev $(DD)oce9050.dev $(DD)oki182.dev $(DD)okiibm.dev $(DD)paintjet.dev $(DD)photoex.dev $(DD)picty180.dev $(DD)pj.dev $(DD)pjetxl.dev $(DD)pjxl.dev $(DD)pjxl300.dev $(DD)pxlcolor.dev $(DD)pxlmono.dev $(DD)r4081.dev $(DD)rinkj.dev $(DD)sj48.dev $(DD)st800.dev $(DD)stcolor.dev $(DD)t4693d2.dev $(DD)t4693d4.dev $(DD)t4693d8.dev $(DD)tek4696.dev $(DD)uniprint.dev
568DEVICE_DEVS3=
569DEVICE_DEVS4=$(DD)ijs.dev
570DEVICE_DEVS5=
571DEVICE_DEVS6=$(DD)png16.dev $(DD)png16m.dev $(DD)png256.dev $(DD)png48.dev $(DD)pngalpha.dev $(DD)pnggray.dev $(DD)pngmono.dev
572DEVICE_DEVS7=
573DEVICE_DEVS8=
574DEVICE_DEVS9=
575DEVICE_DEVS10=
576DEVICE_DEVS11=
577DEVICE_DEVS12=
578DEVICE_DEVS13=
579DEVICE_DEVS14=
580DEVICE_DEVS15=
581DEVICE_DEVS16=
582DEVICE_DEVS17=
583DEVICE_DEVS18=
584DEVICE_DEVS19=
585DEVICE_DEVS20=
586DEVICE_DEVS21=
587
588
589# Shared library target to build.
590GS_SHARED_OBJS=
591
592# ---------------------------- End of options --------------------------- #
593
594# Define the name of the partial makefile that specifies options --
595# used in dependencies.
596
597MAKEFILE=$(GLSRCDIR)/unix-gcc.mak
598TOP_MAKEFILES=$(MAKEFILE) $(GLSRCDIR)/unixhead.mak
599
600# for use in unix-dll.mak and unix-end.mak
601# if you rename the Makefile, you *must* also set this to the new name
602SUB_MAKE_OPTION=-f $(MAKEFILE)
603
604# Define the auxiliary program dependency. We don't use this.
605
606AK=
607
608# Define the compilation rules and flags.
609
610CCFLAGS=$(GENOPT) $(CAPOPT) $(CFLAGS)
611CC_=$(CC) $(CCFLAGS)
612CCAUX_=$(CCAUX) $(CFLAGS)
613CC_LEAF=$(CC_)
614# note gcc can't use -fomit-frame-pointer with -pg.
615CC_LEAF_PG=$(CC_)
616# These are the specific warnings we have to turn off to compile those
617# specific few files that need this.  We may turn off others in the future.
618CC_NO_WARN=$(CC_)
619CCAUX_NO_WARN=$(CCAUX_)
620CC_SHARED=$(CC_) -fPIC
621
622LD_SET_DT_SONAME=-soname=
623
624# MAKEDIRS = the dependency on ALL object files (must be the last one on
625# the line. Requires GNU make to make it an 'order only' dependency
626# MAKEDIRSTOP = the topmost dependency - set this if you can't set MAKEDIRS
627
628MAKEDIRS=| directories
629MAKEDIRSTOP=
630
631# ---------------- End of platform-specific section ---------------- #
632
633INSTALL_CONTRIB=
634include $(GLSRCDIR)/unixhead.mak
635include $(GLSRCDIR)/gs.mak
636# *romfs.mak must precede lib.mak
637
638# The following can be uncommented if the PCL/XPS/PDL sources
639# are available
640# include $(PLSRCDIR)$(D)plromfs.mak   # plromfs.mak
641# include $(XPSSRCDIR)$(D)xpsromfs.mak # xpsromfs.mak
642
643include $(PSSRCDIR)/psromfs.mak
644include $(GLSRCDIR)/lib.mak
645include $(PSSRCDIR)/int.mak
646
647# The following can be uncommented if the PCL/XPS/PDL sources
648# are available
649# include $(PLSRCDIR)$(D)pl.mak # pl.mak
650# include $(PCL5SRCDIR)$(D)pcl.mak # pcl.mak
651# include $(PCL5SRCDIR)$(D)pcl_top.mak # pcl_top.mak
652# include $(PXLSRCDIR)$(D)pxl.mak # pxl.mak
653
654# include $(XPSSRCDIR)$(D)xps.mak # xps.mak
655
656# include $(GPDLSRCDIR)$(D)gpdl.mak # gpdl.mak
657
658include $(GLSRCDIR)/freetype.mak
659include $(GLSRCDIR)$(D)stub.mak
660include $(GLSRCDIR)/jpeg.mak
661# zlib.mak must precede png.mak
662include $(GLSRCDIR)/zlib.mak
663include $(GLSRCDIR)/png.mak
664include $(GLSRCDIR)/tiff.mak
665include $(GLSRCDIR)/jbig2.mak
666include $(GLSRCDIR)/ldf_jb2.mak
667include $(GLSRCDIR)/lwf_jp2.mak
668include $(GLSRCDIR)/openjpeg.mak
669include $(GLSRCDIR)/cal.mak
670
671include $(GLSRCDIR)/jpegxr.mak
672include $(GLSRCDIR)/expat.mak
673
674include $(GLSRCDIR)/$(WHICH_CMS).mak
675include $(GLSRCDIR)/ijs.mak
676
677
678include $(DEVSRCDIR)/devs.mak
679include $(DEVSRCDIR)/contrib.mak
680include $(GLSRCDIR)/unix-aux.mak
681include $(GLSRCDIR)/unixlink.mak
682include $(GLSRCDIR)/unix-dll.mak
683include $(GLSRCDIR)/unix-end.mak
684include $(GLSRCDIR)/unixinst.mak
685
686
687
688# Clean up after the autotools scripts
689distclean : clean config-clean soclean pgclean debugclean mementoclean
690	-$(RM_) -r $(BINDIR) $(GLOBJDIR) $(PSOBJDIR) $(AUXDIR)
691	-$(RM_) -r autom4te.cache
692	-$(RM_) config.log config.status
693	-$(RM_) -r $(TIFFCONFDIR)
694	-$(RM_) Makefile
695
696# a debug-clean target for consistency with the ghostpdl builds
697debug-clean : debugclean
698
699memento-clean : mementoclean
700
701maintainer-clean : distclean
702	-$(RM_) configure
703
704check : default
705	$(NO_OP)
706