source: project/chicken/trunk/defaults.make @ 13735

Last change on this file since 13735 was 13735, checked in by felix winkelmann, 11 years ago

makedist.scm fixes; removed texinfo for the time being

File size: 14.8 KB
Line 
1# defaults.make - default settings -*- Makefile -*-
2#
3# Copyright (c) 2007, Felix L. Winkelmann
4# Copyright (c) 2008-2009, The Chicken Team
5# All rights reserved.
6#
7# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following
8# conditions are met:
9#
10#   Redistributions of source code must retain the above copyright notice, this list of conditions and the following
11#     disclaimer.
12#   Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following
13#     disclaimer in the documentation and/or other materials provided with the distribution.
14#   Neither the name of the author nor the names of its contributors may be used to endorse or promote
15#     products derived from this software without specific prior written permission.
16#
17# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS
18# OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
19# AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR
20# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
22# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
24# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25# POSSIBILITY OF SUCH DAMAGE.
26
27
28# basic parameters
29
30BINARYVERSION = 4
31STACKDIRECTION ?= 1
32CROSS_CHICKEN ?= 0
33
34ifeq ($(ARCH),x86-64)
35NURSERY ?= (256*1024)
36else
37NURSERY ?= (128*1024)
38endif
39
40# directories
41
42SEP ?= /
43SRCDIR ?= .$(SEP)
44DESTDIR ?=
45PREFIX ?= /usr/local
46
47BINDIR = $(PREFIX)/bin
48LIBDIR = $(PREFIX)/lib
49SHAREDIR = $(PREFIX)/share
50DATADIR = $(SHAREDIR)/chicken
51TOPMANDIR = $(SHAREDIR)/man
52MANDIR = $(TOPMANDIR)/man1
53INCDIR = $(PREFIX)/include
54DOCDIR = $(DATADIR)/doc
55CHICKENLIBDIR = $(LIBDIR)/chicken
56EGGDIR = $(CHICKENLIBDIR)/$(BINARYVERSION)
57
58ifdef WINDOWS_SHELL
59SPREFIX = $(subst /,\\,$(PREFIX))
60IBINDIR = $(SPREFIX)$(SEP)bin
61ILIBDIR = $(SPREFIX)$(SEP)lib
62ISHAREDIR = $(SPREFIX)$(SEP)share
63IDATADIR = $(ISHAREDIR)$(SEP)chicken
64ITOPMANDIR = $(ISHAREDIR)$(SEP)man
65IMANDIR = $(ITOPMANDIR)$(SEP)man1
66IINCDIR = $(SPREFIX)$(SEP)include
67IDOCDIR = $(IDATADIR)$(SEP)doc
68ICHICKENLIBDIR = $(ILIBDIR)$(SEP)chicken
69IEGGDIR = $(ICHICKENLIBDIR)$(SEP)$(BINARYVERSION)
70else
71SPREFIX = $(PREFIX)
72IBINDIR = $(BINDIR)
73ILIBDIR = $(LIBDIR)
74ISHAREDIR = $(SHAREDIR)
75IDATADIR = $(DATADIR)
76ITOPMANDIR = $(TOPMANDIR)
77IMANDIR = $(MANDIR)
78IINCDIR = $(INCDIR)
79IDOCDIR = $(DOCDIR)
80ICHICKENLIBDIR = $(CHICKENLIBDIR)
81IEGGDIR = $(EGGDIR)
82endif
83
84RUNTIME_LINKER_PATH ?= .
85
86# commands
87
88ifdef HOSTSYSTEM
89C_COMPILER ?= $(HOSTSYSTEM)-gcc
90CXX_COMPILER ?= $(HOSTSYSTEM)-g++
91LIBRARIAN ?= $(HOSTSYSTEM)-ar
92else
93C_COMPILER ?= gcc
94CXX_COMPILER ?= g++
95LIBRARIAN ?= ar
96endif
97LINKER ?= $(C_COMPILER)
98ifdef WINDOWS_SHELL
99REMOVE_COMMAND ?= del
100else
101REMOVE_COMMAND ?= rm
102endif
103ASSEMBLER ?= $(C_COMPILER)
104ifdef WINDOWS_SHELL
105INSTALL_PROGRAM ?= xcopy
106MAKEDIR_COMMAND ?= -mkdir
107else
108INSTALL_PROGRAM ?= install
109MAKEDIR_COMMAND ?= mkdir
110endif
111POSTINSTALL_STATIC_LIBRARY ?= true
112POSTINSTALL_PROGRAM ?= true
113
114# cross tools
115
116HOST_C_COMPILER ?= $(C_COMPILER)
117HOST_LIBRARIAN ?= $(LIBRARIAN)
118
119# target variables
120
121ifdef TARGETSYSTEM
122TARGET_C_COMPILER ?= $(TARGETSYSTEM)-$(C_COMPILER)
123TARGET_CXX_COMPILER ?= $(TARGETSYSTEM)-$(CXX_COMPILER)
124else
125TARGET_C_COMPILER ?= $(C_COMPILER)
126TARGET_CXX_COMPILER ?= $(CXX_COMPILER)
127endif
128
129TARGET_C_COMPILER_OPTIONS ?= $(C_COMPILER_OPTIONS)
130TARGET_C_COMPILER_OPTIMIZATION_OPTIONS ?= $(C_COMPILER_OPTIMIZATION_OPTIONS)
131TARGET_PREFIX ?= $(PREFIX)
132TARGET_RUN_PREFIX ?= $(TARGET_PREFIX)
133TARGET_LIBRARIES ?= $(LIBRARIES)
134TARGET_LINKER_OPTIONS ?= $(LINKER_OPTIONS)
135
136ifneq ($(TARGET_C_COMPILER),$(C_COMPILER))
137CROSS_CHICKEN = 1
138else
139CROSS_CHICKEN = 0
140endif
141
142
143# options
144
145ifndef NOPTABLES
146C_COMPILER_PTABLES_OPTIONS ?= -DC_ENABLE_PTABLES
147endif
148INCLUDES ?= -I. -I$(SRCDIR)
149C_COMPILER_COMPILE_OPTION ?= -c
150C_COMPILER_OUTPUT_OPTION ?= -o
151C_COMPILER_OUTPUT ?= $(C_COMPILER_OUTPUT_OPTION) $@
152
153ifdef DEBUGBUILD
154ifeq ($(C_COMPILER),gcc)
155C_COMPILER_OPTIMIZATION_OPTIONS ?= -g -Wall -Wno-unused
156endif
157endif
158C_COMPILER_BUILD_RUNTIME_OPTIONS ?= -DC_BUILDING_LIBCHICKEN
159C_COMPILER_BUILD_UNSAFE_RUNTIME_OPTIONS ?= $(C_COMPILER_BUILD_RUNTIME_OPTIONS) -DNDEBUG -DC_UNSAFE_RUNTIME
160C_COMPILER_SHARED_OPTIONS ?= -fPIC -DPIC
161LINKER_EXECUTABLE_OPTIONS ?= -L.
162LINKER_STATIC_OPTIONS ?= $(LINKER_EXECUTABLE_OPTIONS)
163LINKER_OUTPUT_OPTION ?= -o
164LINKER_OUTPUT ?= $(LINKER_OUTPUT_OPTION) $@
165LINKER_LIBRARY_OPTION ?= -l
166ifdef STATICBUILD
167LINKER_LIBRARY_PREFIX ?= lib
168LINKER_LIBRARY_SUFFIX ?= .a
169else
170LINKER_LIBRARY_PREFIX ?= -l
171LINKER_LIBRARY_SUFFIX ?= 
172endif
173LINKER_LINK_SHARED_LIBRARY_OPTIONS ?= -shared
174LINKER_LINK_SHARED_DLOADABLE_OPTIONS ?= -shared -L.
175LIBRARIAN_OPTIONS ?= cru
176LIBRARIAN_OUTPUT_OPTION ?=
177LIBRARIAN_OUTPUT ?= $(LIBRARIAN_OUTPUT_OPTION) $@
178LIBRARIES ?= -lm
179ifdef WINDOWS_SHELL
180REMOVE_COMMAND_OPTIONS ?= /f /q
181REMOVE_COMMAND_RECURSIVE_OPTIONS ?= /f /s /q
182MAKE_WRITABLE_COMMAND ?= rem
183else
184REMOVE_COMMAND_OPTIONS ?= -f
185REMOVE_COMMAND_RECURSIVE_OPTIONS ?= -fr
186MAKE_WRITABLE_COMMAND ?= chmod 0755
187endif
188ifndef WINDOWS_SHELL
189INSTALL_PROGRAM_SHARED_LIBRARY_OPTIONS ?= -m755
190INSTALL_PROGRAM_STATIC_LIBRARY_OPTIONS ?= -m644
191INSTALL_PROGRAM_EXECUTABLE_OPTIONS ?= -m755
192INSTALL_PROGRAM_FILE_OPTIONS ?= -m644
193MAKEDIR_COMMAND_OPTIONS ?= -p
194endif
195ASSEMBLER_OPTIONS ?= $(C_COMPILER_OPTIONS)
196ASSEMBLER_OUTPUT_OPTION ?= -o
197ASSEMBLER_OUTPUT ?= $(ASSEMBLER_OUTPUT_OPTION) $@
198ASSEMBLER_COMPILE_OPTION ?= -c
199ifdef STATICBUILD
200PRIMARY_LIBCHICKEN ?= libchicken$(A)
201else
202ifeq ($(PLATFORM),cygwin)
203PRIMARY_LIBCHICKEN = cygchicken-0.dll
204LIBCHICKEN_SO_FILE = cygchicken-0.dll
205LIBUCHICKEN_SO_FILE = cyguchicken-0.dll
206LIBCHICKENGUI_SO_FILE ?= 
207else
208PRIMARY_LIBCHICKEN ?= libchicken$(SO)$(SONAME_VERSION)
209LIBCHICKEN_SO_FILE ?= libchicken$(SO)$(SONAME_VERSION)
210LIBUCHICKEN_SO_FILE ?= libuchicken$(SO)$(SONAME_VERSION)
211LIBCHICKENGUI_SO_FILE ?= 
212endif
213endif
214LIBCHICKEN_SO_LIBRARIES ?= $(LIBRARIES)
215LIBUCHICKEN_SO_LIBRARIES ?= $(LIBRARIES)
216LIBCHICKENGUI_SO_LIBRARIES ?= $(LIBRARIES)
217
218# cross settings
219
220HOST_C_COMPILER_OPTIONS ?= $(C_COMPILER_OPTIONS)
221HOST_C_COMPILER_PTABLES_OPTIONS ?= $(C_COMPILER_PTABLES_OPTIONS)
222HOST_C_COMPILER_COMPILE_OPTION ?= $(C_COMPILER_COMPILE_OPTION)
223HOST_C_COMPILER_OPTIMIZATION_OPTIONS ?= $(C_COMPILER_OPTIMIZATION_OPTIONS)
224HOST_C_COMPILER_SHARED_OPTIONS ?= $(C_COMPILER_SHARED_OPTIONS)
225HOST_C_COMPILER_BUILD_RUNTIME_OPTIONS ?= $(C_COMPILER_BUILD_RUNTIME_OPTIONS)
226HOST_C_COMPILER_OUTPUT ?= $(C_COMPILER_OUTPUT)
227HOST_INCLUDES ?= $(INCLUDES)
228HOST_LINKER ?= $(LINKER)
229HOST_LINKER_OPTIONS ?= $(LINKER_OPTIONS)
230HOST_LINKER_LINK_SHARED_DLOADABLE_OPTIONS ?= $(LINKER_LINK_SHARED_DLOADABLE_OPTIONS)
231HOST_LINKER_OUTPUT_OPTION ?= $(LINKER_OUTPUT_OPTION)
232HOST_LINKER_LIBRARY_PREFIX ?= $(LINKER_LIBRARY_PREFIX)
233HOST_LINKER_LIBRARY_SUFFIX ?= $(LINKER_LIBRARY_SUFFIX)
234HOST_LIBRARIES ?= $(LIBRARIES)
235
236# other settings
237
238HOSTNAME ?= $(shell hostname)
239
240ifdef WINDOWS_SHELL
241BUILD_TIME ?= $(shell date /t)
242COPY_COMMAND = copy /Y
243else
244BUILD_TIME ?= $(shell date +%Y-%m-%d)
245UNAME_SYS ?= $(shell uname)
246COPY_COMMAND = cp
247endif
248BUILD_TAG ?= compiled $(BUILD_TIME) on $(HOSTNAME) ($(UNAME_SYS))
249COPYMANY =
250
251
252# file extensions
253
254O ?= .o
255A ?= .a
256# EXE ?=
257SO ?= .so
258ASM ?= .s
259
260# special files
261
262POSIXFILE ?= posixunix
263CHICKEN_CONFIG_H = chicken-config.h
264
265ifneq ($(ARCH),)
266HACKED_APPLY ?= 1
267APPLY_HACK_SRC ?= apply-hack.$(ARCH)$(ASM)
268APPLY_HACK_OBJECT ?= apply-hack.$(ARCH)$(O)
269endif
270
271# bootstrapping compiler
272
273CHICKEN ?= chicken$(EXE)
274
275# interpreter for scripts
276
277CSI ?= csi$(EXE)
278
279# Scheme compiler flags
280
281CHICKEN_OPTIONS = \
282        -no-trace -optimize-level 2 \
283        -include-path . -include-path $(SRCDIR)
284ifdef DEBUGBUILD
285CHICKEN_OPTIONS += -feature debugbuild
286endif
287CHICKEN_LIBRARY_OPTIONS = $(CHICKEN_OPTIONS) -explicit-use
288CHICKEN_PROGRAM_OPTIONS = $(CHICKEN_OPTIONS) -no-lambda-info -inline -local
289CHICKEN_COMPILER_OPTIONS = $(CHICKEN_PROGRAM_OPTIONS) -extend private-namespace.scm
290CHICKEN_UNSAFE_OPTIONS = -unsafe -no-lambda-info
291CHICKEN_DYNAMIC_OPTIONS = $(CHICKEN_OPTIONS) -feature chicken-compile-shared -dynamic
292CHICKEN_IMPORT_LIBRARY_OPTIONS = $(CHICKEN_DYNAMIC_OPTIONS)
293
294# targets
295
296CHICKEN_PROGRAM = $(PROGRAM_PREFIX)chicken$(PROGRAM_SUFFIX)
297CSC_PROGRAM = $(PROGRAM_PREFIX)csc$(PROGRAM_SUFFIX)
298CSI_PROGRAM = $(PROGRAM_PREFIX)csi$(PROGRAM_SUFFIX)
299CHICKEN_PROFILE_PROGRAM = $(PROGRAM_PREFIX)chicken-profile$(PROGRAM_SUFFIX)
300CHICKEN_INSTALL_PROGRAM = $(PROGRAM_PREFIX)chicken-install$(PROGRAM_SUFFIX)
301CHICKEN_UNINSTALL_PROGRAM = $(PROGRAM_PREFIX)chicken-uninstall$(PROGRAM_SUFFIX)
302CHICKEN_STATUS_PROGRAM = $(PROGRAM_PREFIX)chicken-status$(PROGRAM_SUFFIX)
303CHICKEN_BUG_PROGRAM = $(PROGRAM_PREFIX)chicken-bug$(PROGRAM_SUFFIX)
304IMPORT_LIBRARIES = chicken lolevel srfi-1 srfi-4 data-structures ports files posix srfi-13 srfi-69 extras \
305        regex srfi-14 tcp foreign compiler scheme srfi-18 utils csi irregex
306IMPORT_LIBRARIES += setup-api setup-download
307
308ifdef STATICBUILD
309CHICKEN_STATIC_EXECUTABLE = $(CHICKEN_PROGRAM)$(EXE)
310CSI_STATIC_EXECUTABLE = $(CSI_PROGRAM)$(EXE)
311CHICKEN_SHARED_EXECUTABLE = $(CHICKEN_PROGRAM)-shared$(EXE)
312CSI_SHARED_EXECUTABLE = $(CSI_PROGRAM)-shared$(EXE)
313TARGETLIBS ?= libchicken$(A) libuchicken$(A)
314TARGETS ?= $(TARGETLIBS) $(CHICKEN_STATIC_EXECUTABLE) \
315        $(CSI_STATIC_EXECUTABLE) $(CHICKEN_PROFILE_PROGRAM)$(EXE) \
316        $(CSC_PROGRAM)$(EXE) \
317        $(CHICKEN_BUG_PROGRAM)$(EXE)
318else
319CHICKEN_STATIC_EXECUTABLE = $(CHICKEN_PROGRAM)-static$(EXE)
320CSI_STATIC_EXECUTABLE = $(CSI_PROGRAM)-static$(EXE)
321CHICKEN_SHARED_EXECUTABLE = $(CHICKEN_PROGRAM)$(EXE)
322CSI_SHARED_EXECUTABLE = $(CSI_PROGRAM)$(EXE)
323TARGETLIBS ?= libchicken$(A) libuchicken$(A) \
324        $(LIBCHICKEN_SO_FILE) $(LIBUCHICKEN_SO_FILE)
325TARGETS ?= $(TARGETLIBS) $(CHICKEN_SHARED_EXECUTABLE) \
326        $(CSI_SHARED_EXECUTABLE) $(CHICKEN_PROFILE_PROGRAM)$(EXE) \
327        $(CSC_PROGRAM)$(EXE) $(CHICKEN_INSTALL_PROGRAM)$(EXE) $(CHICKEN_UNINSTALL_PROGRAM)$(EXE) \
328        $(CHICKEN_STATUS_PROGRAM)$(EXE) setup-download.so setup-api.so \
329        $(CHICKEN_BUG_PROGRAM)$(EXE) \
330        $(IMPORT_LIBRARIES:%=%.import.so)
331endif
332
333# main rule
334
335.PHONY: all
336
337all: buildsvnrevision $(TARGETS)
338
339buildsvnrevision:
340ifdef WINDOWS_SHELL
341        echo 0 >buildsvnrevision
342else
343        sh $(SRCDIR)svnrevision.sh
344endif
345
346# generic part of chicken-config.h
347
348ifndef CUSTOM_CHICKEN_DEFAULTS
349chicken-defaults.h: buildsvnrevision
350        echo "/* generated */" >$@
351        echo "#define C_BUILD_TAG \"$(BUILD_TAG)\"" >>$@
352        echo "#define C_CHICKEN_PROGRAM \"$(CHICKEN_PROGRAM)$(EXE)\"" >>$@
353        echo "#define C_SVN_REVISION $(shell cat buildsvnrevision)" >>$@
354        echo "#ifndef C_INSTALL_CC" >>$@
355        echo "# define C_INSTALL_CC \"$(C_COMPILER)\"" >>$@
356        echo "#endif" >>$@
357        echo "#ifndef C_INSTALL_CXX" >>$@
358        echo "# define C_INSTALL_CXX \"$(CXX_COMPILER)\"" >>$@
359        echo "#endif" >>$@
360        echo "#ifndef C_INSTALL_CFLAGS" >>$@
361        echo "# define C_INSTALL_CFLAGS \"$(C_COMPILER_OPTIONS) $(C_COMPILER_OPTIMIZATION_OPTIONS)\"" >>$@
362        echo "#endif" >>$@
363        echo "#ifndef C_INSTALL_LDFLAGS" >>$@
364        echo "# define C_INSTALL_LDFLAGS \"$(LINKER_OPTIONS) $(LINKER_OPTIMIZATION_OPTIONS)\"" >>$@
365        echo "#endif" >>$@
366        echo "#ifndef C_INSTALL_SHARE_HOME" >>$@
367        echo "# define C_INSTALL_SHARE_HOME \"$(DATADIR)\"" >>$@
368        echo "#endif" >>$@
369        echo "#ifndef C_INSTALL_BIN_HOME" >>$@
370        echo "# define C_INSTALL_BIN_HOME \"$(BINDIR)\"" >>$@
371        echo "#endif" >>$@
372        echo "#ifndef C_INSTALL_EGG_HOME" >>$@
373        echo "# define C_INSTALL_EGG_HOME \"$(EGGDIR)\"" >>$@
374        echo "#endif" >>$@
375        echo "#ifndef C_INSTALL_LIB_HOME" >>$@
376        echo "# define C_INSTALL_LIB_HOME \"$(LIBDIR)\"" >>$@
377        echo "#endif" >>$@
378        echo "#ifndef C_INSTALL_STATIC_LIB_HOME" >>$@
379        echo "# define C_INSTALL_STATIC_LIB_HOME \"$(LIBDIR)\"" >>$@
380        echo "#endif" >>$@
381        echo "#ifndef C_INSTALL_INCLUDE_HOME" >>$@
382        echo "# define C_INSTALL_INCLUDE_HOME \"$(INCDIR)\"" >>$@
383        echo "#endif" >>$@
384        echo "#ifndef C_INSTALL_MORE_LIBS" >>$@
385        echo "# define C_INSTALL_MORE_LIBS \"$(LIBRARIES)\"" >>$@
386        echo "#endif" >>$@
387        echo "#ifndef C_INSTALL_MORE_STATIC_LIBS" >>$@
388        echo "# define C_INSTALL_MORE_STATIC_LIBS \"$(LIBRARIES)\"" >>$@
389        echo "#endif" >>$@
390        echo "#ifndef C_DEFAULT_TARGET_STACK_SIZE" >>$@
391        echo "# define C_DEFAULT_TARGET_STACK_SIZE $(NURSERY)" >>$@
392        echo "#endif" >>$@
393        echo "#ifndef C_DEFAULT_TARGET_HEAP_SIZE" >>$@
394        echo "# define C_DEFAULT_TARGET_HEAP_SIZE 0" >>$@
395        echo "#endif" >>$@
396        echo "#ifndef C_STACK_GROWS_DOWNWARD" >>$@
397        echo "# define C_STACK_GROWS_DOWNWARD $(STACKDIRECTION)" >>$@
398        echo "#endif" >>$@
399        echo "#ifndef C_TARGET_MORE_LIBS" >>$@
400        echo "# define C_TARGET_MORE_LIBS \"$(TARGET_LIBRARIES)\"" >>$@
401        echo "#endif" >>$@
402        echo "#ifndef C_TARGET_MORE_STATIC_LIBS" >>$@
403        echo "# define C_TARGET_MORE_STATIC_LIBS \"$(TARGET_LIBRARIES)\"" >>$@
404        echo "#endif" >>$@
405        echo "#ifndef C_TARGET_CC" >>$@
406        echo "# define C_TARGET_CC \"$(TARGET_C_COMPILER)\"" >>$@
407        echo "#endif" >>$@
408        echo "#ifndef C_TARGET_CXX" >>$@
409        echo "# define C_TARGET_CXX \"$(TARGET_CXX_COMPILER)\"" >>$@
410        echo "#endif" >>$@
411        echo "#ifndef C_TARGET_CFLAGS" >>$@
412        echo "# define C_TARGET_CFLAGS \"$(TARGET_C_COMPILER_OPTIONS) $(TARGET_C_COMPILER_OPTIMIZATION_OPTIONS)\"" >>$@
413        echo "#endif" >>$@
414        echo "#ifndef C_TARGET_LDFLAGS" >>$@
415        echo "# define C_TARGET_LDFLAGS \"$(TARGET_LINKER_OPTIONS) $(TARGET_LINKER_OPTIMIZATION_OPTIONS)\"" >>$@
416        echo "#endif" >>$@
417        echo "#ifndef C_CROSS_CHICKEN" >>$@
418        echo "# define C_CROSS_CHICKEN $(CROSS_CHICKEN)" >>$@
419        echo "#endif" >>$@
420        echo "#ifndef C_TARGET_BIN_HOME" >>$@
421        echo "# define C_TARGET_BIN_HOME \"$(TARGET_PREFIX)/bin\"" >>$@
422        echo "#endif" >>$@
423        echo "#ifndef C_TARGET_LIB_HOME" >>$@
424        echo "# define C_TARGET_LIB_HOME \"$(TARGET_PREFIX)/lib\"" >>$@
425        echo "#endif" >>$@
426        echo "#ifndef C_TARGET_RUN_LIB_HOME" >>$@
427        echo "# define C_TARGET_RUN_LIB_HOME \"$(TARGET_RUN_PREFIX)/lib\"" >>$@
428        echo "#endif" >>$@
429        echo "#ifndef C_TARGET_SHARE_HOME" >>$@
430        echo "# define C_TARGET_SHARE_HOME \"$(TARGET_PREFIX)/share\"" >>$@
431        echo "#endif" >>$@
432        echo "#ifndef C_TARGET_INCLUDE_HOME" >>$@
433        echo "# define C_TARGET_INCLUDE_HOME \"$(TARGET_PREFIX)/include\"" >>$@
434        echo "#endif" >>$@
435        echo "#ifndef C_TARGET_STATIC_LIB_HOME" >>$@
436        echo "# define C_TARGET_STATIC_LIB_HOME \"$(TARGET_PREFIX)/lib\"" >>$@
437        echo "#endif" >>$@
438        echo "#ifndef C_CHICKEN_PROGRAM" >>$@
439        echo "# define C_CHICKEN_PROGRAM \"$(CHICKEN_PROGRAM)\"" >>$@
440        echo "#endif" >>$@
441        echo "#ifndef C_CSC_PROGRAM" >>$@
442        echo "# define C_CSC_PROGRAM \"$(CSC_PROGRAM)\"" >>$@
443        echo "#endif" >>$@
444        echo "#ifndef C_CSI_PROGRAM" >>$@
445        echo "# define C_CSI_PROGRAM \"$(CSI_PROGRAM)\"" >>$@
446        echo "#endif" >>$@
447        echo "#ifndef C_CHICKEN_BUG_PROGRAM" >>$@
448        echo "# define C_CHICKEN_BUG_PROGRAM \"$(CHICKEN_BUG_PROGRAM)\"" >>$@
449        echo "#endif" >>$@
450        echo "#ifndef C_WINDOWS_SHELL" >>$@
451ifdef WINDOWS_SHELL
452        echo "# define C_WINDOWS_SHELL 1" >>$@
453else
454        echo "# define C_WINDOWS_SHELL 0" >>$@
455endif
456        echo "#endif" >>$@
457        echo "#ifndef C_BINARY_VERSION" >>$@
458        echo "# define C_BINARY_VERSION $(BINARYVERSION)" >>$@
459        echo "#endif" >>$@
460endif
Note: See TracBrowser for help on using the repository browser.