void-packages/srcpkgs/qca-qt5/patches/ansi.patch
q66 0c11013fb2 qca-qt5: patch out -ansi from CXXFLAGS
This is completely wrong because -ansi when used with g++ disables
C++11 features, which Qt relies on, resulting in megabytes of
errors printed into the console. I'm not sure how this ever
built but it's definitely not right.

[ci skip]
2019-08-12 16:40:03 +02:00

15 lines
981 B
Diff

Not quite sure what the purpose of -ansi for C++ was meant to be, but it
breaks build because it will make the compiler deactivate C++11 features
that Qt relies on.
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -127,7 +127,7 @@ if (CMAKE_COMPILER_IS_GNUCXX)
endif()
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Werror-implicit-function-declaration -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
- set ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-check-new -fno-common")
+ set ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -Wundef -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-check-new -fno-common")
endif (CMAKE_SYSTEM_NAME MATCHES Linux)
endif (CMAKE_COMPILER_IS_GNUCXX)