Skip to content
Snippets Groups Projects
Commit dea96d0d authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Add -MP with -MMD

This creates a .PHONY target for each file so that if a header is
renamed, the impact will be the files that include it being rebuilt
instead of the previous behaviour where the build would simply fail
and complain that the file doesn't exist.
parent a31c44be
No related branches found
No related tags found
1 merge request!455Update branch with changes from master
...@@ -173,7 +173,7 @@ ifdef WALL ...@@ -173,7 +173,7 @@ ifdef WALL
endif endif
# Compiler-specific options # Compiler-specific options
CFLAGS += -MMD CFLAGS += -MMD -MP
CC ?= gcc CC ?= gcc
CCPRE ?= ${shell if [ `echo __clang__ | $(CC) -E - | grep -v '^\#'` != __clang__ ] ; then echo clang ; elif [ `echo __INTEL_COMPILER | $(CC) -E - | grep -v '^\#'` != __INTEL_COMPILER ] ; then echo icc ; else echo gcc ; fi} CCPRE ?= ${shell if [ `echo __clang__ | $(CC) -E - | grep -v '^\#'` != __clang__ ] ; then echo clang ; elif [ `echo __INTEL_COMPILER | $(CC) -E - | grep -v '^\#'` != __INTEL_COMPILER ] ; then echo icc ; else echo gcc ; fi}
ifeq ($(CCPRE),clang) ifeq ($(CCPRE),clang)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment