]> git.saurik.com Git - apt.git/commitdiff
some CXXFLAGS housekeeping
authorDavid Kalnischkies <david@kalnischkies.de>
Wed, 17 Jun 2015 20:15:01 +0000 (22:15 +0200)
committerDavid Kalnischkies <david@kalnischkies.de>
Mon, 10 Aug 2015 15:25:25 +0000 (17:25 +0200)
More warnings are always better.

Git-Dch: Ignore

apt-pkg/aptconfiguration.h
apt-pkg/contrib/sptr.h
apt-pkg/edsp.h
buildlib/environment.mak.in
test/libapt/makefile

index 353843c3e737e864b72cb9cd2c597cfd6fced73e..fbd9b02e6ef06320fb32a928672dd0d96cc1310d 100644 (file)
@@ -122,7 +122,7 @@ namespace Configuration {                                                   /*{{{*/
        /** \return Return a comma-separated list of enabled build profile specifications */
        std::string const getBuildProfilesString();
                                                                        /*}}}*/
-};
+}
                                                                        /*}}}*/
 }
 #endif
index 9df0e44a71b0b8ae862a98dc9f1b606315fccf92..e2e811b1d1696937776ee38f367feae88073a0c9 100644 (file)
@@ -60,7 +60,15 @@ class SPtrArray
    
    inline SPtrArray(T *Ptr) : Ptr(Ptr) {};
    inline SPtrArray() : Ptr(0) {};
+#if __GNUC__ >= 4
+       #pragma GCC diagnostic push
+       #pragma GCC diagnostic ignored "-Wunsafe-loop-optimizations"
+       // gcc warns about this, but we can do nothing hereā€¦
+#endif
    inline ~SPtrArray() {delete [] Ptr;};
+#if __GNUC__ >= 4
+       #pragma GCC diagnostic pop
+#endif
 };
 
 #endif
index 72b886a319da56dccd7dcf22fa73d0b581a6279a..4f5f500a1957f76771dd25dac3b09e166cb4e7e4 100644 (file)
@@ -211,6 +211,6 @@ namespace EDSP                                                              /*{{{*/
        bool ResolveExternal(const char* const solver, pkgDepCache &Cache,
                                    bool const upgrade, bool const distUpgrade,
                                    bool const autoRemove, OpProgress *Progress = NULL);
-};
+}
                                                                        /*}}}*/
 #endif
index b0a8d9d357c8b3b1d1ae89274b5bbc65641cce7a..0dff02e69e5d174873a4dc6951362cde0fe7b768 100644 (file)
@@ -11,7 +11,11 @@ CPPFLAGS+= @CPPFLAGS@ @DEFS@ -D_REENTRANT -D_FORTIFY_SOURCE=2
 CXX = @CXX@
 CXXFLAGS+= @CXXFLAGS@ -Wall -Wextra
 CXXFLAGS+= -Wcast-align -Wlogical-op -Wredundant-decls -Wmissing-declarations -Wunsafe-loop-optimizations
-CXXFLAGS+= -Wsuggest-attribute=pure -Wsuggest-attribute=const -Wsuggest-attribute=noreturn
+CXXFLAGS+= -Wctor-dtor-privacy -Wdisabled-optimization -Winit-self -Wmissing-include-dirs -Wnoexcept -Wsign-promo -Wundef
+# suggests methods which already have such an attribute
+#CXXFLAGS+= -Wsuggest-attribute=pure -Wsuggest-attribute=const -Wsuggest-attribute=noreturn
+# gcc reports currently lots of them at the end of file - unknown reason
+CXXFLAGS+= -Wno-deprecated-declarations
 # a bit too pedantic to be run by default
 #CXXFLAGS+= -Wpedantic -Wno-long-long -Wno-vla -Wno-variadic-macros
 NUM_PROCS = @NUM_PROCS@
index 61a8aaf317341b6f82986c603b06e7713a4e5dbd..c078cc568e487635bbc1c8656bbf020d5bd6e662 100644 (file)
@@ -33,7 +33,7 @@ GTEST_DIR = /usr/src/gtest
 # Flags passed to the preprocessor.
 # Set Google Test's header directory as a system directory, such that
 # the compiler doesn't generate warnings in Google Test headers.
-CPPFLAGS += -isystem $(GTEST_DIR)/include
+#CPPFLAGS += -isystem $(GTEST_DIR)/include
 
 # Flags passed to the C++ compiler.
 CXXFLAGS += -pthread
@@ -41,6 +41,7 @@ CXXFLAGS += -pthread
 CXXFLAGS+= -Wno-missing-declarations
 CXXFLAGS+= -Wno-missing-field-initializers
 CXXFLAGS+= -Wno-suggest-attribute=pure -Wno-suggest-attribute=const -Wno-suggest-attribute=noreturn
+CXXFLAGS+= -Wno-undef
 
 # All Google Test headers.  Usually you shouldn't change this definition.
 GTEST_HEADERS = /usr/include/gtest/*.h \