diff --git a/examples/ap_fixed/Makefile b/examples/ap_fixed/Makefile index 016b7df..d4ca0e1 100644 --- a/examples/ap_fixed/Makefile +++ b/examples/ap_fixed/Makefile @@ -13,8 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. # + +CXXFLAGS= -std=c++14 -Wall -O3 + a.out: test.cpp - g++ -I../../include test.cpp + g++ -I../../include $(CXXFLAGS) test.cpp ./a.out .PHONY: clean diff --git a/examples/ap_int/Makefile b/examples/ap_int/Makefile index 4ef871f..51d7cc0 100644 --- a/examples/ap_int/Makefile +++ b/examples/ap_int/Makefile @@ -15,22 +15,25 @@ # limitations under the License. # +CXXFLAGS= -std=c++14 -Wall -O3 +CXX=g++ + all: a.out ex1.out ex2.out ex3.out a.out: test.cpp - g++ -I../../include test.cpp -std=c++14 -o a.out + $(CXX) -I../../include test.cpp $(CXXFLAGS) -o a.out ./a.out ex1.out: ap_int_manip_ex.cpp - g++ -I../../include ap_int_manip_ex.cpp -std=c++14 -o ex1.out + $(CXX) -I../../include ap_int_manip_ex.cpp $(CXXFLAGS) -o ex1.out ./ex1.out ex2.out: ap_int_manip_ex2.cpp - g++ -I../../include ap_int_manip_ex2.cpp -std=c++14 -o ex2.out + $(CXX) -I../../include ap_int_manip_ex2.cpp $(CXXFLAGS) -o ex2.out ./ex2.out ex3.out: ap_int_manip_ex3.cpp - g++ -I../../include ap_int_manip_ex3.cpp -std=c++14 -o ex3.out + $(CXX) -I../../include ap_int_manip_ex3.cpp $(CXXFLAGS) -o ex3.out ./ex3.out .PHONY: clean diff --git a/include/etc/ap_private.h b/include/etc/ap_private.h index cfb9ac9..8385974 100644 --- a/include/etc/ap_private.h +++ b/include/etc/ap_private.h @@ -24,6 +24,14 @@ #error "etc/ap_private.h cannot be included directly." #endif +#if defined( __clang__ ) +#elif defined ( __GNUC__ ) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wmaybe-uninitialized" +#pragma GCC diagnostic ignored "-Wint-in-bool-context" +#pragma GCC diagnostic ignored "-Wuninitialized" +#endif + // forward declarations //template //class ap_private; // moved to ap_common.h @@ -7202,6 +7210,11 @@ REF_BIN_OP(<<, arg1) // when both sides are signed. //************************************************************************ +#if defined( __clang__ ) +#elif defined ( __GNUC__ ) +#pragma GCC diagnostic pop +#endif + #endif // ifndef __AP_PRIVATE_H__ // -*- cpp -*-