2 # We need to extend flags to the C compiler and the linker
3 # here. sb-posix, sb-grovel, and sb-bsd-sockets depends upon these
4 # being set on x86_64. Setting these in their Makefiles is not
5 # adequate since, while we're building contrib, they can be compiled
6 # directly via ASDF from a non-C-aware module which has these tricky
7 # ones as dependencies.
9 UNAME
:=$(shell uname
-s
)
12 EXTRA_CFLAGS
=-D_XOPEN_SOURCE
=500 -D__EXTENSIONS__
13 PATH
:=/usr
/xpg4
/bin
:${PATH}
15 ifeq (CYGWIN
,$(findstring CYGWIN
,$(UNAME
)))
16 EXTRA_CFLAGS
=-mno-cygwin
17 # GCC 4.x doesn't accept -mno-cygwin.
19 # SBCL can't read cygwin symlinks, and cygwin likes to symlink
20 # gcc. To further complicate things, SBCL can't handle cygwin
22 CC
:=$(shell cygpath
-m
$(shell readlink
-fn
$(shell which
$(CC
))))
25 EXTRA_CFLAGS
=-D_GNU_SOURCE
28 export CC SBCL EXTRA_CFLAGS EXTRA_LDFLAGS
30 all: $(EXTRA_ALL_TARGETS
)
32 $(SBCL
) --eval
'(defvar *system* "$(SYSTEM)")' --load ..
/asdf-stub.lisp
--eval
'(exit)'
35 echo
"(pushnew :sb-testing-contrib *features*)" \
36 "(asdf:operate (quote asdf:load-op) :$(SYSTEM))" \
37 "(asdf:operate (quote asdf:test-op) :$(SYSTEM))" | \
38 $(SBCL
) --eval
'(load "../asdf/asdf")'
40 # KLUDGE: There seems to be no portable way to tell tar to not to
41 # preserve owner, so chown after installing for the current user.
42 install: $(EXTRA_INSTALL_TARGETS
)
43 tar cf
- . |
( cd
"$(BUILD_ROOT)$(INSTALL_DIR)" && tar xpvf
- )
44 find
"$(BUILD_ROOT)$(INSTALL_DIR)" -exec chown
`id -u`:`id -g` {} \
;