Changeset - r1168:5cd9dec0a3eb
[Not reviewed]
master
0 1 0
tron - 20 years ago 2005-01-25 15:59:01
tron@openttd.org
(svn r1670) Garbage collect some variables, because they are only used once and hide magic, like containing -o where a filename must be the next parameter
1 file changed with 3 insertions and 12 deletions:
Makefile
3
12
0 comments (0 inline, 0 general)
Makefile
Show inline comments
 
@@ -677,21 +677,12 @@ endif
 
DEPS1 = $(foreach obj,$(OBJS),.deps/$(obj))
 
DEPS = $(DEPS1:%.o=%.P)
 

	
 
LANG_TXT = $(filter-out %.unfinished.txt,$(wildcard lang/*.txt))
 
LANGS = $(LANG_TXT:%.txt=%.lng)
 

	
 
C_COMPILE = $(CC) $(CFLAGS) $(CDEFS)
 
CXX_COMPILE = $(CXX) $(CFLAGS) $(CDEFS)
 

	
 
C_BUILD = $(C_COMPILE) -c
 
CXX_BUILD = $(CXX_COMPILE) -c
 

	
 
C_LINK = $(CC) $(LDFLAGS) -o
 

	
 

	
 

	
 
##############################################################################
 
#
 
# Targets
 
#
 

	
 
@@ -714,13 +705,13 @@ endian.h: $(ENDIAN_CHECK)
 
	@echo '===> Compiling and Linking $@'
 
	@$(CC) $(BASECFLAGS) $(CDEFS) endian_check.c -o $@
 

	
 

	
 
$(TTD): table/strings.h $(OBJS) $(MAKE_CONFIG)
 
	@echo '===> Linking $@'
 
	@$(C_LINK) $@ $(TTDLDFLAGS) $(OBJS) $(LIBS)
 
	@$(CC) $(LDFLAGS) $(TTDLDFLAGS) $(OBJS) $(LIBS) -o $@
 

	
 
$(OSX): $(TTD)
 
	@rm -fr "$(OSXAPP)"
 
	@mkdir -p "$(OSXAPP)"/Contents/MacOS
 
	@mkdir -p "$(OSXAPP)"/Contents/Resources
 
	@mkdir -p "$(OSXAPP)"/Contents/Data
 
@@ -928,23 +919,23 @@ DEPS_MAGIC := $(shell mkdir .deps > /dev
 
# first compilation round as we just build everything at that time anyway,
 
# therefore we do not need to watch deps.
 

	
 

	
 
%.o: %.c $(MAKE_CONFIG) endian.h table/strings.h
 
	@echo '===> Compiling $<'
 
	@$(C_BUILD) $< -Wp,-MD,.deps/$(*F).pp
 
	@$(CC) $(CFLAGS) $(CDEFS) -Wp,-MD,.deps/$(*F).pp -c $< -o $@
 
	@-cp .deps/$(*F).pp .deps/$(*F).P; \
 
		tr ' ' '\012' < .deps/$(*F).pp \
 
		| sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \
 
		>> .deps/$(*F).P; \
 
	rm .deps/$(*F).pp
 

	
 
# For DirectMusic build and BeOS specific parts
 
%.o: %.cpp  $(MAKE_CONFIG) endian.h table/strings.h
 
	@echo '===> Compiling $<'
 
	@$(CXX_BUILD) $< -o $@
 
	@$(CXX) $(CFLAGS) $(CDEFS) -c $< -o $@
 

	
 

	
 
info:
 
	@echo 'CFLAGS  = $(CFLAGS)'
 
	@echo 'LDFLAGS = $(LDFLAGS)'
 
	@echo 'LIBS    = $(LIBS)'
0 comments (0 inline, 0 general)