Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,15 @@ ifndef CXXFLAGS
CXXFLAGS=-pedantic -Wall -Wextra -Wcast-qual -Wno-deprecated-declarations -Wfloat-equal -Wmissing-declarations -Wmissing-format-attribute -Wno-long-long -Wpacked -Wredundant-decls -Wundef -Wno-shadow -Wno-missing-field-initializers -Wno-missing-braces -Wno-sign-compare -Wno-multichar $(CPPCHK_GLIBCXX_DEBUG) -g
endif

# Increase stack size for Cygwin builds to avoid segmentation fault in limited recursive tests.
ifdef COMSPEC
uname_S := $(shell uname -s)

ifneq (,$(findstring CYGWIN,$(uname_S)))
CXXFLAGS+=-Wl,--stack,8388608
endif # CYGWIN
endif # COMSPEC

ifeq (g++, $(findstring g++,$(CXX)))
override CXXFLAGS += -std=c++0x
else ifeq (clang++, $(findstring clang++,$(CXX)))
Expand Down
10 changes: 10 additions & 0 deletions tools/dmake.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,16 @@ int main(int argc, char **argv)
"-g");
}

fout << "# Increase stack size for Cygwin builds to avoid segmentation fault in limited recursive tests.\n"
<< "ifdef COMSPEC\n"
<< " uname_S := $(shell uname -s)\n"
<< "\n"
<< " ifneq (,$(findstring CYGWIN,$(uname_S)))\n"
<< " CXXFLAGS+=-Wl,--stack,8388608\n"
<< " endif # CYGWIN\n"
<< "endif # COMSPEC\n"
<< "\n";

fout << "ifeq (g++, $(findstring g++,$(CXX)))\n"
<< " override CXXFLAGS += -std=c++0x\n"
<< "else ifeq (clang++, $(findstring clang++,$(CXX)))\n"
Expand Down