diff options
author | kpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-11-19 21:34:47 +0000 |
---|---|---|
committer | kpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-11-19 21:34:47 +0000 |
commit | 9668b8c888bcb4e2c459832ab2b06245ab5262e2 (patch) | |
tree | 78f43b76335f3a7b2a96a014ef9d4dab5a4f6b1f /main | |
parent | a234ce6b3b592cb8424e396f74a201a8c99088fd (diff) |
the gcc optimizer frequently finds broken code (use of uninitalized variables, unreachable code, etc.), which is good. however, developers usually compile with the optimizer turned off, because if they need to debug the resulting code, optimized code makes that process very difficult. this means that we get code changes committed that weren't adequately checked over for these sorts of problems.
with this build system change, if (and only if) --enable-dev-mode was used and DONT_OPTIMIZE is turned on, when a source file is compiled it will actually be preprocessed (into a .i or .ii file), then compiled once with optimization (with the result sent to /dev/null) and again without optimization (but only if the first compile succeeded, of course).
while making these changes, i did some cleanup work in Makefile.rules to move commonly-used combinations of flag variables into their own variables, to make the file easier to read and maintain
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@157859 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main')
-rw-r--r-- | main/db1-ast/Makefile | 2 | ||||
-rw-r--r-- | main/stdtime/Makefile | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/main/db1-ast/Makefile b/main/db1-ast/Makefile index 4b9bb25d7..c9d29b369 100644 --- a/main/db1-ast/Makefile +++ b/main/db1-ast/Makefile @@ -46,7 +46,7 @@ $(PROG): db_dump185.o $(LIBDBSO) clean-depend: clean: - rm -f $(LIBDB) $(LIBDBSO) $(OBJS) $(SHOBJS) *.s *.i + rm -f $(LIBDB) $(LIBDBSO) $(OBJS) $(SHOBJS) */*.s */*.i ASTCFLAGS:=-Wall -D__DBINTERFACE_PRIVATE -I. -I.. -Iinclude -Ihash -Ibtree -Irecno $(ASTCFLAGS) diff --git a/main/stdtime/Makefile b/main/stdtime/Makefile index cbe3c48f7..d4b7f0093 100644 --- a/main/stdtime/Makefile +++ b/main/stdtime/Makefile @@ -14,7 +14,7 @@ clean-depend: rm -f .depend clean: clean-depend - rm -f libtime.a *.o test + rm -f libtime.a *.o test *.i depend: .depend |