Makefile: move -MMD option out of CFLAGS
This commit is contained in:
		
							
								
								
									
										4
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								Makefile
									
									
									
									
									
								
							@@ -11,7 +11,7 @@ VPATH = $(SPATH) $(IPATH) $(DPATH) $(OPATH)
 | 
			
		||||
 | 
			
		||||
# compiler and compiler flags
 | 
			
		||||
CC = g++
 | 
			
		||||
CFLAGS = -MMD -I$(IPATH) -pthread -lrt
 | 
			
		||||
CFLAGS = -I$(IPATH) -pthread -lrt
 | 
			
		||||
 | 
			
		||||
# list of object files
 | 
			
		||||
SOURCES = $(wildcard $(SPATH)/*.cpp)
 | 
			
		||||
@@ -39,7 +39,7 @@ $(DPATH) $(OPATH):
 | 
			
		||||
	$(CC) $(CFLAGS) -o $@ $^
 | 
			
		||||
# Make the object and dependency files
 | 
			
		||||
$(OPATH)/%.o: $(SPATH)/%.cpp
 | 
			
		||||
	$(CC) $(CFLAGS) -MF $(DPATH)/$(@F:.o=.d) -o $@ -c $<
 | 
			
		||||
	$(CC) $(CFLAGS) -MMD -MF $(DPATH)/$(@F:.o=.d) -o $@ -c $<
 | 
			
		||||
 | 
			
		||||
# Don't autodelete object files:
 | 
			
		||||
.SECONDARY: $(OPATH)/%.o
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user