[Olsr-cvs] olsrd-current Makefile, 1.87, 1.88 Makefile.inc, 1.19, 1.20

Bernd Petrovitsch (spam-protected)
Thu Jul 26 19:34:56 CEST 2007


Update of /cvsroot/olsrd/olsrd-current
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv28549

Modified Files:
	Makefile Makefile.inc 
Log Message:
* the contents of INCLUDES and DEFINES should now be placed into CPPFLAGS
  as it belongs in there
* also all -I and -D options from CFALGS are now there
* however, we add for the time being INCLUDES and DEFINES to CPPFLAGS
  (and warn) to not break ouf of tree modules.
* and the -DSUPPORT_OLD_PLUGIN_VERSIONS=1 is now fixed as it should have
  been right from the start


Index: Makefile
===================================================================
RCS file: /cvsroot/olsrd/olsrd-current/Makefile,v
retrieving revision 1.87
retrieving revision 1.88
diff -C2 -d -r1.87 -r1.88
*** Makefile	17 Jul 2007 13:13:08 -0000	1.87
--- Makefile	26 Jul 2007 17:34:53 -0000	1.88
***************
*** 40,47 ****
  VERS =		0.5.3pre
  
  TOPDIR = .
  include Makefile.inc
  
! CFLAGS +=	-DVERSION=\"$(VERS)\"
  
  MAKECMD = $(MAKE) OS="$(OS)" WARNINGS="$(WARNINGS)"
--- 40,49 ----
  VERS =		0.5.3pre
  
+ all:
+ 
  TOPDIR = .
  include Makefile.inc
  
! CPPFLAGS +=	-DVERSION=\"$(VERS)\"
  
  MAKECMD = $(MAKE) OS="$(OS)" WARNINGS="$(WARNINGS)"
***************
*** 73,77 ****
  		$(MAKECMD) -C $(CFGDIR)
  
! .PHONY: help libs clean_libs libs_clean clean uberclean install_libs libs_install install_bin install_olsrd install build_all install_all clean_all
  
  clean:
--- 75,79 ----
  		$(MAKECMD) -C $(CFGDIR)
  
! .PHONY: help libs clean_libs libs_clean clean uberclean install_libs libs_install install_bin install_olsrd install build_all install_all clean_all 
  
  clean:
***************
*** 84,88 ****
  		find . \( -name '*.[od]' -o -name '*~' \) -print | xargs -r rm -f
  		$(MAKECMD) -C $(CFGDIR) uberclean
- 		$(MAKECMD) -C $(SWITCHDIR) clean
  
  install: install_olsrd
--- 86,89 ----

Index: Makefile.inc
===================================================================
RCS file: /cvsroot/olsrd/olsrd-current/Makefile.inc,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** Makefile.inc	26 Jul 2007 16:03:40 -0000	1.19
--- Makefile.inc	26 Jul 2007 17:34:53 -0000	1.20
***************
*** 21,25 ****
  EXENAME ?= olsrd
  
! INCLUDES =	-Isrc -I$(TOPDIR)/src 
  
  # add gcc warnings and optimizations if CFLAGS not set
--- 21,25 ----
  EXENAME ?= olsrd
  
! CPPFLAGS =	-Isrc -I$(TOPDIR)/src 
  
  # add gcc warnings and optimizations if CFLAGS not set
***************
*** 54,58 ****
  ifdef OLSRD_PLUGIN
  # c and ld flags for libraries (plugins)
! CFLAGS +=	-DOLSR_PLUGIN
  LDFLAGS +=	-shared -Wl,-soname,$(PLUGIN_NAME)
  LDFLAGS +=	-Wl,--version-script=version-script.txt 
--- 54,58 ----
  ifdef OLSRD_PLUGIN
  # c and ld flags for libraries (plugins)
! CPPFLAGS +=	-DOLSR_PLUGIN
  LDFLAGS +=	-shared -Wl,-soname,$(PLUGIN_NAME)
  LDFLAGS +=	-Wl,--version-script=version-script.txt 
***************
*** 67,77 ****
  
  # we have plugins with the old interface
! CFLAGS +=       -DSUPPORT_OLD_PLUGIN_VERSIONS=1
  
  # search sources and headers in current dir and in src/
! SRCS =		$(wildcard src/*.c)
! SRCS +=		$(wildcard *.c)
! HDRS =		$(wildcard src/*.h)
! HDRS +=		$(wildcard *.h)
  
  all: default_target
--- 67,75 ----
  
  # we have plugins with the old interface
! CPPFLAGS +=	-DSUPPORT_OLD_PLUGIN_VERSIONS=1
  
  # search sources and headers in current dir and in src/
! SRCS +=		$(wildcard src/*.c *.c)
! HDRS +=		$(wildcard src/*.h *.h)
  
  all: default_target
***************
*** 79,86 ****
  # OS detection
  ifeq ($(OS),Windows_NT)
! OS = win32
  endif
  ifeq ($(OS),)
! OS :=		$(shell sh $(TOPDIR)/make/guess_os.sh)
  endif
  ifeq ($(OS),UNKNOWN)
--- 77,84 ----
  # OS detection
  ifeq ($(OS),Windows_NT)
! OS := win32
  endif
  ifeq ($(OS),)
! OS := $(shell sh $(TOPDIR)/make/guess_os.sh)
  endif
  ifeq ($(OS),UNKNOWN)
***************
*** 93,111 ****
  
  # one object for each source file
! OBJS +=		$(patsubst %.c,%.o,$(SRCS))
  
  # debugging or non-debugging flags
  ifdef DEBUG
! CFLAGS +=	-DDEBUG
  endif
  ifdef NODEBUG
! CFLAGS +=	-DNODEBUG
  endif
  
! # let gcc generate dependency information (*.d)
! CFLAGS +=	-MD
  
  # we always need the includes and defines
! CFLAGS += $(INCLUDES) $(DEFINES)
  
  TAGFILE ?=	src/TAGS
--- 91,117 ----
  
  # one object for each source file
! OBJS +=		$(SRCS:%.c=%.o)
  
  # debugging or non-debugging flags
  ifdef DEBUG
! CPPFLAGS +=	-DDEBUG
  endif
  ifdef NODEBUG
! CPPFLAGS +=	-DNODEBUG
  endif
  
! # fully automatic and working dependency generation
! %.d: %.c
! 	@$(CC) -M $(CPPFLAGS) "$<" | sed -e '1s|\($(*F)\)\.o[ :]*|$(*D)/\1.o $@: Makefile $(TOPDIR)$(if $(TOPDIR),/)Makefile.inc \\\n  |g' >"$@"
  
  # we always need the includes and defines
! # for legacy since now
! CPPFLAGS += $(INCLUDES) $(DEFINES)
! ifneq ($(INCLUDES),)
! $(warning Use CPPFLAGS instead of INCLUDES for -I)
! endif
! ifneq ($(DEFINES),)
! $(warning Use CPPFLAGS instead of DEFINES for -D)
! endif
  
  TAGFILE ?=	src/TAGS





More information about the Olsr-cvs mailing list