Makefile

changeset 14
7a98c853715e
parent 13
973a377aa562
child 18
320dc6206f52
     1.1 --- a/Makefile	Sun Nov 28 23:05:31 2010 +0000
     1.2 +++ b/Makefile	Sun Nov 28 23:07:17 2010 +0000
     1.3 @@ -1,6 +1,6 @@
     1.4  # Phil's multiplatform makefile template
     1.5  # With auto-incrementing build number and automatic version.h generation
     1.6 -# Version 1.8, 2010-02-15
     1.7 +# Version 1.9, 2010-02-15
     1.8  #
     1.9  # The latest version of this Makefile can be found at http://www.philpem.me.uk/
    1.10  #
    1.11 @@ -84,6 +84,9 @@
    1.12  #
    1.13  #
    1.14  # Change history:
    1.15 +#   1.9 - Bugfix -- if CFLAGS contained a forward-slash, sed would fall over.
    1.16 +#         Also added SDL support and fixed the date/time formats. To use SDL,
    1.17 +#         set ENABLE_SDL to "yes".
    1.18  #   1.8 - Now supports the use of the wxWidgets GUI framework. To turn
    1.19  #         this on, set ENABLE_WX to "yes".
    1.20  #   1.7 - Now creates a basic Hgignore file and directory keepers for the
    1.21 @@ -337,7 +340,7 @@
    1.22  		 -e 's/@@vcsrev@@/$(VER_VCSREV)/g'					\
    1.23  		 -e 's/@@vcsstr@@/$(VER_VCSSTR)/g'					\
    1.24  		 -e 's/@@fullverstr@@/$(VER_FULLSTR)/g'				\
    1.25 -		 -e 's:@@cflags@@:$(CFLAGS):g'						\
    1.26 +		 -e 's#@@cflags@@#$(CFLAGS)#g'						\
    1.27  		 < src/version.h.in > src/version.h
    1.28  
    1.29  # version.h creation stuff based on code from the Xen makefile
    1.30 @@ -359,22 +362,22 @@
    1.31  	@echo '*~' >> .hgignore
    1.32  	@echo '.*.sw?' >> .hgignore
    1.33  	@echo '#define VER_COMPILE_DATETIME	"@@datetime@@"'			> src/version.h.in
    1.34 -	@echo '#define VER_COMPILE_DATE	"@@date@@"'				>> src/version.h.in
    1.35 -	@echo '#define VER_COMPILE_TIME	"@@time@@"'				>> src/version.h.in
    1.36 -	@echo '#define VER_COMPILE_BY		"@@whoami@@"'		>> src/version.h.in
    1.37 -	@echo '#define VER_COMPILE_HOST	"@@hostname@@"'			>> src/version.h.in
    1.38 -	@echo '#define VER_COMPILER		"@@compiler@@"'			>> src/version.h.in
    1.39 -	@echo '#define VER_BUILD_TYPE		"@@buildtype@@"'	>> src/version.h.in
    1.40 -	@echo '#define VER_CFLAGS			"@@cflags@@"'		>> src/version.h.in
    1.41 -	@echo ''												>> src/version.h.in
    1.42 -	@echo '#define VER_MAJOR			@@majorver@@'		>> src/version.h.in
    1.43 -	@echo '#define VER_MINOR			@@minorver@@'		>> src/version.h.in
    1.44 -	@echo '#define VER_BUILDNUM		@@buildnum@@'			>> src/version.h.in
    1.45 -	@echo '#define VER_EXTRA			"@@extraver@@"'		>> src/version.h.in
    1.46 -	@echo '#define VER_VCSREV			"@@vcsstr@@"'		>> src/version.h.in
    1.47 -	@echo ''												>> src/version.h.in
    1.48 -	@echo '#define VER_FULLSTR			"@@fullverstr@@"'	>> src/version.h.in
    1.49 -	@echo ''												>> src/version.h.in
    1.50 +	@echo '#define VER_COMPILE_DATE		"@@date@@"'				>> src/version.h.in
    1.51 +	@echo '#define VER_COMPILE_TIME		"@@time@@"'				>> src/version.h.in
    1.52 +	@echo '#define VER_COMPILE_BY			"@@whoami@@"'		>> src/version.h.in
    1.53 +	@echo '#define VER_COMPILE_HOST		"@@hostname@@"'			>> src/version.h.in
    1.54 +	@echo '#define VER_COMPILER			"@@compiler@@"'			>> src/version.h.in
    1.55 +	@echo '#define VER_BUILD_TYPE			"@@buildtype@@"'	>> src/version.h.in
    1.56 +	@echo '#define VER_CFLAGS				"@@cflags@@"'		>> src/version.h.in
    1.57 +	@echo ''													>> src/version.h.in
    1.58 +	@echo '#define VER_MAJOR				@@majorver@@'		>> src/version.h.in
    1.59 +	@echo '#define VER_MINOR				@@minorver@@'		>> src/version.h.in
    1.60 +	@echo '#define VER_BUILDNUM			@@buildnum@@'			>> src/version.h.in
    1.61 +	@echo '#define VER_EXTRA				"@@extraver@@"'		>> src/version.h.in
    1.62 +	@echo '#define VER_VCSREV				"@@vcsstr@@"'		>> src/version.h.in
    1.63 +	@echo ''													>> src/version.h.in
    1.64 +	@echo '#define VER_FULLSTR				"@@fullverstr@@"'	>> src/version.h.in
    1.65 +	@echo ''													>> src/version.h.in
    1.66  	@echo Build system initialised
    1.67  
    1.68  # remove the dependency files