diff --git a/.travis.yml b/.travis.yml index be5556850..547cad344 100644 --- a/.travis.yml +++ b/.travis.yml @@ -34,7 +34,7 @@ before_install: script: # download 3.14-rc6 kernel, compile cppcheck, run cppcheck on the kernel to look for crashes in cppcheck. if this is done, terminate build to prevent it from timing out - - if [[ "$CHECK_KERNEL" == "yes" ]] && [[ "$CC" == "gcc" ]]; then wget https://www.kernel.org/pub/linux/kernel/v3.x/testing/linux-3.14-rc6.tar.xz; mkdir kernel; tar -xJf linux-3.14-rc6.tar.xz -C kernel & make -j 4 & wait; touch /tmp/kernel.cppcheck; ./cppcheck kernel --max-configs=1 -j 2 |& tee /tmp/kernel.cppcheck; ! grep "process crashed with signal 11" /tmp/kernel.cppcheck; exit; fi + - if [[ "$CHECK_KERNEL" == "yes" ]] && [[ "$CC" == "gcc" ]]; then wget https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.14.tar.xz; mkdir kernel; tar -xJf linux-3.14.tar.xz -C kernel & make -j 4 & wait; touch /tmp/kernel.cppcheck; ./cppcheck kernel --max-configs=1 -j 2 |& tee /tmp/kernel.cppcheck; ! grep "process crashed with signal 11" /tmp/kernel.cppcheck; exit; fi # compile cppcheck, default build - make -j4 - make test -j4 @@ -81,7 +81,6 @@ script: # check if Makefile needs to be regenerated - git clean -dfx - make dmake - - ./dmake # now, if dmake modified the makefile, return false! - git diff --exit-code diff --git a/Makefile b/Makefile index 4a7cf3738..cf13c21db 100644 --- a/Makefile +++ b/Makefile @@ -209,6 +209,8 @@ endif EXTOBJ += $(TINYXML) +.PHONY: dmake + ###### Targets @@ -228,6 +230,7 @@ check: all dmake: tools/dmake.cpp $(CXX) -std=c++0x -o dmake tools/dmake.cpp cli/filelister.cpp lib/path.cpp -Ilib $(LDFLAGS) + ./dmake reduce: tools/reduce.cpp $(CXX) -std=c++0x -g -o reduce tools/reduce.cpp -Ilib -Iexternals/tinyxml lib/*.cpp externals/tinyxml/tinyxml2.cpp diff --git a/tools/dmake.cpp b/tools/dmake.cpp index 35e96c809..d66d1bacf 100644 --- a/tools/dmake.cpp +++ b/tools/dmake.cpp @@ -365,6 +365,7 @@ int main(int argc, char **argv) makeExtObj(fout, externalfiles); + fout << ".PHONY: dmake\n\n"; fout << "\n###### Targets\n\n"; fout << "cppcheck: $(LIBOBJ) $(CLIOBJ) $(EXTOBJ)\n"; fout << "\t$(CXX) $(CPPFLAGS) $(CXXFLAGS) -std=c++0x -o cppcheck $(CLIOBJ) $(LIBOBJ) $(EXTOBJ) $(LIBS) $(LDFLAGS) $(RDYNAMIC)\n\n"; @@ -376,7 +377,8 @@ int main(int argc, char **argv) fout << "check:\tall\n"; fout << "\t./testrunner -g -q\n\n"; fout << "dmake:\ttools/dmake.cpp\n"; - fout << "\t$(CXX) -std=c++0x -o dmake tools/dmake.cpp cli/filelister.cpp lib/path.cpp -Ilib $(LDFLAGS)\n\n"; + fout << "\t$(CXX) -std=c++0x -o dmake tools/dmake.cpp cli/filelister.cpp lib/path.cpp -Ilib $(LDFLAGS)\n"; + fout << "\t./dmake\n\n"; fout << "reduce:\ttools/reduce.cpp\n"; fout << "\t$(CXX) -std=c++0x -g -o reduce tools/reduce.cpp -Ilib -Iexternals/tinyxml lib/*.cpp externals/tinyxml/tinyxml2.cpp\n\n"; fout << "clean:\n";