Mercurial > hg > openttd
changeset 1955:31e2da65513c draft
(svn r2461) -Feature [Makefile] libpng-config can now be called something else in Makefile.config
useful if you for some reason got a libpng-config, which is called something else
author | bjarni <bjarni@openttd.org> |
---|---|
date | Sun, 19 Jun 2005 17:05:24 +0000 |
parents | 33916fc46768 |
children | 5667abf403a8 |
files | Makefile makefiledir/Makefile.config_writer makefiledir/Makefile.libdetection |
diffstat | 3 files changed, 10 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/Makefile +++ b/Makefile @@ -149,6 +149,10 @@ CONFIG_INCLUDED:=1 endif +ifndef LIBPNG-CONFIG +LIBPNG-CONFIG :=libpng-config +endif + # updates Makefile.config if it's outdated ifneq ($(MAKEFILE_VERSION),$(CONFIG_VERSION)) ifndef MANUAL_CONFIG # manual config should not check this @@ -461,19 +465,19 @@ # libpng config ifdef WITH_PNG CDEFS += -DWITH_PNG -CFLAGS += $(shell libpng-config --cflags) +CFLAGS += $(shell $(LIBPNG-CONFIG) --cflags) # seems like older libpng versions are broken and need this PNGCONFIG_FLAGS = --ldflags --libs ifdef STATIC ifdef OSX # Seems like we need a tiny hack for OSX static to work -LIBS += $(shell libpng-config --prefix)/lib/libpng.a +LIBS += $(shell $(LIBPNG-CONFIG) --prefix)/lib/libpng.a else -LIBS += $(shell libpng-config --static $(PNGCONFIG_FLAGS)) +LIBS += $(shell $(LIBPNG-CONFIG) --static $(PNGCONFIG_FLAGS)) endif else -LIBS += $(shell libpng-config --L_opts $(PNGCONFIG_FLAGS)) +LIBS += $(shell $(LIBPNG-CONFIG) --L_opts $(PNGCONFIG_FLAGS)) endif endif
--- a/makefiledir/Makefile.config_writer +++ b/makefiledir/Makefile.config_writer @@ -97,6 +97,7 @@ $(call CONFIG_LINE,\# misc) $(call CONFIG_LINE,SDL-CONFIG:=$(SDL-CONFIG)) + $(call CONFIG_LINE,LIBPNG-CONFIG:=$(LIBPNG-CONFIG)) $(call CONFIG_LINE,BEOS_NET_SERVER:=$(BEOS_NET_SERVER)) $(call CONFIG_LINE,CONFIG_INCLUDED:=yes) $(call CONFIG_LINE,PATH_SET:=$(PATH_SET))
--- a/makefiledir/Makefile.libdetection +++ b/makefiledir/Makefile.libdetection @@ -66,7 +66,7 @@ WITH_SDL:=$(shell $(SDL-CONFIG) --version 2>/dev/null) # libpng detection -WITH_PNG:=$(shell libpng-config --version 2>/dev/null) +WITH_PNG:=$(shell $(LIBPNG-CONFIG) --version 2>/dev/null) ifdef WITH_PNG # LibPNG depends on Zlib