Allow compilation without debug info under MSVC.

This commit is contained in:
goffioul 2005-09-05 09:27:02 +00:00
parent 797ffafcb5
commit ff0f03ef28
4 changed files with 28 additions and 16 deletions

View file

@ -10,7 +10,7 @@ srcdir = ..\src
SHORT_SITE_NAME =
LONG_SITE_NAME =
ECL_VERSION = 0.9g
ECL_VERSION = 0.9h
ARCHITECTURE = PENTIUM4
MACHINE_INSTANCE = localhost
MACHINE =
@ -29,6 +29,9 @@ GMP_TYPE = gc
# Set it to non-empty to include Win32 thread support
ECL_THREADS =
# Set it to non-empty to enable Win32 debug support
ECL_DEBUG = 1
# Add the extensions to include in the build process. Comment any
# of the following lines to remove a feature from the build process
# LISP->C compiled
@ -49,9 +52,10 @@ TAR_DIR = %%CD%%\ecl-$(ECL_VERSION)
#
CC = cl
CFLAGS = /MD /DGC_NOT_DLL
CFLAGS = -MD -DGC_NOT_DLL -nologo
LIBS = eclgc.lib eclgmp.lib user32.lib ws2_32.lib
LDFLAGS = -MD -Zi
LDFLAGS = -MD
SHARED_LDFLAGS = -LD
RM = del
RMDIR = rmdir /Q /S
MKDIR = mkdir
@ -88,6 +92,14 @@ LIBRARIES =
TARGETS = ecl2$(EXE)
DEF = ecl.def
# Enable debug information
#
!if "$(ECL_DEBUG)" != ""
CFLAGS = $(CFLAGS) -Zi
LDFLAGS = $(LDFLAGS) -Zi
SHARED_LDFLAGS = -LDd
!endif
# Additional configuration for thread support
#
!if "$(ECL_THREADS)" == ""
@ -168,9 +180,9 @@ compile.lsp: bare.lsp $(srcdir)/compile.lsp.in Makefile
"@ECL_CFLAGS@" "" \
"@CPPFLAGS@" "" \
"@LDRPATH@" "" \
"@LDFLAGS@" "/MD /link /LIBPATH:~S" \
"@SHARED_LDFLAGS@" "/LDd" \
"@BUNDLE_LDFLAGS@" "/LDd" \
"@LDFLAGS@" "$(LDFLAGS) /link /LIBPATH:~S" \
"@SHARED_LDFLAGS@" "$(SHARED_LDFLAGS)" \
"@BUNDLE_LDFLAGS@" "$(SHARED_LDFLAGS)" \
"@CLIBS@" "user32.lib ws2_32.lib" \
"@STATICLIBS@" "eclgmp.lib eclgc.lib" \
"@LIBS@" "user32.lib ws2_32.lib" \
@ -204,9 +216,9 @@ cmp/cmpcfg.lsp: $(srcdir)/cmp/cmpcfg.lsp.in Makefile
"@ECL_CFLAGS@" "" \
"@CPPFLAGS@" "" \
"@LDRPATH@" "" \
"@LDFLAGS@" "/MD /link /LIBPATH:~S" \
"@SHARED_LDFLAGS@" "/LDd" \
"@BUNDLE_LDFLAGS@" "/LDd" \
"@LDFLAGS@" "$(LDFLAGS) /link /LIBPATH:~S" \
"@SHARED_LDFLAGS@" "$(SHARED_LDFLAGS)" \
"@BUNDLE_LDFLAGS@" "$(SHARED_LDFLAGS)" \
"@CLIBS@" "user32.lib ws2_32.lib" \
"@STATICLIBS@" "eclgmp.lib eclgc.lib" \
"@OBJEXT@" "obj" \
@ -220,7 +232,7 @@ ecl-config.bat: util\ecl-config.bat Makefile
c\cut "~A" "$(libdir:\=/)"\
"~*" "" \
"@ECL_CFLAGS@" "$(CFLAGS)" \
"@LDFLAGS@" "" \
"@LDFLAGS@" "$(LDFLAGS)" \
"@CLIBS@" "" \
"@libdir@" "$(libdir:\=/)" \
"@includedir@" "$(libdir:\=/)/h" \
@ -229,7 +241,7 @@ ecl-config.bat: util\ecl-config.bat Makefile
eclmin.lib: eclgmp.lib eclgc.lib lsp/config.lsp
cd c
$(MAKE) "ECL_THREADS = $(ECL_THREADS)"
$(MAKE) "ECL_THREADS = $(ECL_THREADS)" "ECL_CFLAGS = $(CFLAGS)"
cd ..
eclgc.lib:
cd gc

View file

@ -16,7 +16,7 @@ THREADS_FLAGS=
#
TRUE_CC = cl
CC = cl
CFLAGS = -c -MD -Zi -I./ -I$(srcdir) -I$(HDIR) -I../h -I$(top_srcdir)/gc/include -DHAVE_ISATTY $(THREADS_FLAGS) -DGC_NOT_DLL
CFLAGS = -c $(ECL_CFLAGS) -I./ -I$(srcdir) -I$(HDIR) -I../h -I$(top_srcdir)/gc/include -DHAVE_ISATTY $(THREADS_FLAGS)
# -Wall -W -Wfloat-equal -Wundef -Wendif-labels -Wpointer-arith -Wcast-align \
# -Wwrite-strings -Wconversion -Wsign-compare -Wmissing-prototypes -Wredundant-decls \
# -Wunreachable-code -Winline

View file

@ -9,9 +9,9 @@
(setq *cc-optimize* #-msvc "-O"
#+msvc "-O2")
(setq *ld-format* #-msvc "~A -o ~S -L~S ~{~S ~} ~@?"
#+msvc "~A -Zi -Fe~S~* ~{~S ~} ~@?")
#+msvc "~A -Fe~S~* ~{~S ~} ~@?")
(setq *cc-format* #-msvc "~A ~A ~:[~*~;~A~] \"-I~A/h\" -w -c \"~A\" -o \"~A\""
#+msvc "~A ~A ~:[~*~;~A~] -I\"~A/h\" -Zi -w -nologo -c \"~A\" -Fo\"~A\"")
#+msvc "~A ~A ~:[~*~;~A~] -I\"~A/h\" -w -c \"~A\" -Fo\"~A\"")
#-dlopen
(setq *ld-flags* "@LDRPATH@ @LDFLAGS@ -lecl @CORE_LIBS@ @LIBS@ @FASL_LIBS@")
#+dlopen

View file

@ -42,10 +42,10 @@
#+msvc "@CFLAGS@ @ECL_CFLAGS@ -I\"@true_srcdir@\"/h -I\"@true_builddir@\"/h"
c::*cc-format*
#-msvc "~A ~A ~:[~*~;~A~] -I\"@true_builddir@\"/h~* -w -c ~S -o ~S"
#+msvc "~A ~A ~:[~*~;~A~] -I\"@true_builddir@\"/h~* -Zi -w -nologo -c ~S -Fo~S"
#+msvc "~A ~A ~:[~*~;~A~] -I\"@true_builddir@\"/h~* -w -c ~S -Fo~S"
c::*ld-format*
#-msvc "~A -o ~S -L\"@true_builddir@\"~* ~{~S ~} ~@?"
#+msvc "~A -Zi -Fe~S~* ~{~S ~} ~@?")
#+msvc "~A -Fe~S~* ~{~S ~} ~@?")
#-:wants-dlopen
(setf c::*ld-flags*
"@LDFLAGS@ @LDRPATH@ @LIBPREFIX@ecl.@LIBEXT@ @CORE_LIBS@ @LIBS@ @FASL_LIBS@")