X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=Makefile.in;h=338d1039681b7e07cb820507c9bf9de4c692dd0d;hp=c5d5027a09858b256660b18fb67bb26efe34d5c4;hb=0845d4aad5a6de08ceeae1700ef86bb38f9dc477;hpb=5c556c52f1196cea4536d36b683372de532943a9 diff --git a/Makefile.in b/Makefile.in index c5d5027a..338d1039 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,17 +1,18 @@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ +prefix := @prefix@ +exec_prefix := @exec_prefix@ -BINDIR = @bindir@ -VARDIR = /var/paraslash -PKGDATADIR = @datarootdir@/@PACKAGE_NAME@ -MANDIR = @datarootdir@/man/man1 +BINDIR := @bindir@ +VARDIR := /var/paraslash +PKGDATADIR := @datarootdir@/@PACKAGE_NAME@ +MANDIR := @datarootdir@/man/man1 -install_sh = @install_sh@ +install_sh := @install_sh@ -build_date = $(shell date) -system = $(shell uname -rs) -cc_version = $(shell $(CC) --version | head -n 1) -codename = solar saturation +build_date := $(shell date) +uname_s := $(shell uname -s 2>/dev/null || echo "UNKNOWN_OS") +uname_rs := $(shell uname -rs) +cc_version := $(shell $(CC) --version | head -n 1) +codename := liquid interaction DEBUG_CPPFLAGS += -Wno-sign-compare -g -Wunused -Wundef -W DEBUG_CPPFLAGS += -Wredundant-decls @@ -26,26 +27,26 @@ DEBUG_CPPFLAGS += -Wredundant-decls # many warnings about trivial stuff # CPPFLAGS += -Wconversion -# uncomment this if your compiler supports it -# LDFLAGS += -Wl,--gc-sections - +ifeq ($(uname_s),Linux) + CPPFLAGS += -fdata-sections -ffunction-sections + LDFLAGS += -Wl,--gc-sections + CPPFLAGS += -Wstrict-prototypes + CPPFLAGS += -Wshadow +endif CPPFLAGS += -Os CPPFLAGS += -Wall CPPFLAGS += -Wuninitialized -CPPFLAGS += -Wstrict-prototypes CPPFLAGS += -Wchar-subscripts CPPFLAGS += -Wformat-security CPPFLAGS += -DBINDIR='"$(BINDIR)"' CPPFLAGS += -DBUILD_DATE='"$(build_date)"' -CPPFLAGS += -DSYSTEM='"$(system)"' +CPPFLAGS += -DUNAME_RS='"$(uname_rs)"' CPPFLAGS += -DCODENAME='"$(codename)"' CPPFLAGS += -DCC_VERSION='"$(cc_version)"' CPPFLAGS += -Werror-implicit-function-declaration CPPFLAGS += -Wmissing-format-attribute CPPFLAGS += -Wunused-macros -CPPFLAGS += -Wshadow CPPFLAGS += -Wbad-function-cast -CPPFLAGS += -fdata-sections -ffunction-sections CPPFLAGS += -DMAIN_INPUT_FILE_IS_$(*F) CPPFLAGS += @SSL_CPPFLAGS@ CPPFLAGS += @ncurses_cppflags@ @@ -67,12 +68,12 @@ tarball_add := $(gengetopts_c) $(gengetopts_h) $(autocrap) tarball := @PACKAGE_TARNAME@-@PACKAGE_VERSION@.tar.bz2 .PHONY: clean distclean maintainer-clean install man tarball -all: $(BINARIES) +all: $(BINARIES) $(man_pages) man: $(man_pages) tarball: $(tarball) -fade_objs = fade.cmdline.o fade.o exec.o close_on_fork.o string.o fd.o -fsck_objs = osl.o rbtree.o fsck.o string.o sha1.o fsck.cmdline.o +fade_objs := fade.cmdline.o fade.o exec.o close_on_fork.o string.o fd.o +fsck_objs := osl.o rbtree.o fsck.o string.o sha1.o fsck.cmdline.o *.o: para.h config.h gcc-compat.h @@ -215,6 +216,7 @@ para_write: @write_objs@ clean: rm -f *.o $(BINARIES) + rm -rf man distclean: clean rm -f Makefile autoscan.log config.status config.log && \ rm -rf web/sync/* autom4te.cache aclocal.m4 @@ -233,14 +235,12 @@ install: all man $(install_sh) -m 644 $(man_pages) $(MANDIR) mkdir -p $(VARDIR) >/dev/null 2>&1 || true # not fatal, so don't complain -@PACKAGE_TARNAME@-@PACKAGE_VERSION@.tar.bz2: $(tarball_add) $(man_pages) +@PACKAGE_TARNAME@-@PACKAGE_VERSION@.tar.bz2: $(tarball_add) rm -rf $(tarball_pfx).tar.bz2 $(tarball_pfx) git-archive --format=tar --prefix=$(tarball_pfx)/ HEAD \ | tar --delete $(tarball_delete) > $(tarball_pfx).tar mkdir $(tarball_pfx) cp -r $(tarball_add) $(tarball_pfx) - mkdir -p $(tarball_pfx)/man/man1 - cp -r $(man_pages) $(tarball_pfx)/man/man1 tar rf $(tarball_pfx).tar $(tarball_pfx)/* rm -rf $(tarball_pfx) bzip2 -9 $(tarball_pfx).tar