mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-05-19 21:59:17 +02:00
Fixing -ldl flags for Linux build.
This commit is contained in:
parent
c93dbe3607
commit
befd0ecfd9
2 changed files with 24 additions and 24 deletions
24
Makefile
24
Makefile
|
@ -14,30 +14,6 @@ GENSTATIC ?= ./tools/chibi-genstatic
|
|||
CHIBI ?= LD_LIBRARY_PATH=".:$(LD_LIBRARY_PATH)" ./chibi-scheme$(EXE)
|
||||
CHIBI_DEPENDENCIES = ./chibi-scheme$(EXE)
|
||||
|
||||
########################################################################
|
||||
# Library config.
|
||||
#
|
||||
# This is to allow "make SEXP_USE_BOEHM=1" and "make SEXP_USE_DL=0" to
|
||||
# automatically include the necessary compiler and linker flags in
|
||||
# addition to setting those features. If not using GNU make just
|
||||
# comment out the ifs and use the else branches for the defaults.
|
||||
|
||||
ifeq ($(SEXP_USE_BOEHM),1)
|
||||
GCLDFLAGS := -lgc
|
||||
XCPPFLAGS := $(CPPFLAGS) -Iinclude $(D:%=-DSEXP_USE_%) -DSEXP_USE_BOEHM=1
|
||||
else
|
||||
GCLDFLAGS :=
|
||||
XCPPFLAGS := $(CPPFLAGS) -Iinclude $(D:%=-DSEXP_USE_%)
|
||||
endif
|
||||
|
||||
ifeq ($(SEXP_USE_DL),0)
|
||||
XLDFLAGS := $(LDFLAGS) $(RLDFLAGS) $(GCLDFLAGS) -lm
|
||||
XCFLAGS := -Wall -DSEXP_USE_DL=0 -g -g3 -Os $(CFLAGS)
|
||||
else
|
||||
XLDFLAGS := $(LDFLAGS) $(RLDFLAGS) $(GCLDFLAGS) $(LIBDL) -lm
|
||||
XCFLAGS := -Wall -g -g3 -Os $(CFLAGS)
|
||||
endif
|
||||
|
||||
########################################################################
|
||||
|
||||
CHIBI_COMPILED_LIBS = lib/chibi/filesystem$(SO) lib/chibi/process$(SO) \
|
||||
|
|
|
@ -42,6 +42,30 @@ CHIBI_DOC ?= chibi-doc
|
|||
|
||||
include Makefile.detect
|
||||
|
||||
########################################################################
|
||||
# Library config.
|
||||
#
|
||||
# This is to allow "make SEXP_USE_BOEHM=1" and "make SEXP_USE_DL=0" to
|
||||
# automatically include the necessary compiler and linker flags in
|
||||
# addition to setting those features. If not using GNU make just
|
||||
# comment out the ifs and use the else branches for the defaults.
|
||||
|
||||
ifeq ($(SEXP_USE_BOEHM),1)
|
||||
GCLDFLAGS := -lgc
|
||||
XCPPFLAGS := $(CPPFLAGS) -Iinclude $(D:%=-DSEXP_USE_%) -DSEXP_USE_BOEHM=1
|
||||
else
|
||||
GCLDFLAGS :=
|
||||
XCPPFLAGS := $(CPPFLAGS) -Iinclude $(D:%=-DSEXP_USE_%)
|
||||
endif
|
||||
|
||||
ifeq ($(SEXP_USE_DL),0)
|
||||
XLDFLAGS := $(LDFLAGS) $(RLDFLAGS) $(GCLDFLAGS) -lm
|
||||
XCFLAGS := -Wall -DSEXP_USE_DL=0 -g -g3 -Os $(CFLAGS)
|
||||
else
|
||||
XLDFLAGS := $(LDFLAGS) $(RLDFLAGS) $(GCLDFLAGS) $(LIBDL) -lm
|
||||
XCFLAGS := -Wall -g -g3 -Os $(CFLAGS)
|
||||
endif
|
||||
|
||||
########################################################################
|
||||
|
||||
all-libs: $(COMPILED_LIBS)
|
||||
|
|
Loading…
Add table
Reference in a new issue