summaryrefslogtreecommitdiff
path: root/acprep
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2010-06-23 19:31:06 -0400
committerJohn Wiegley <johnw@newartisans.com>2010-06-23 19:31:06 -0400
commiteda6cbd0146d371653feec70e0eb3ee4e4c56379 (patch)
treeaeb4e1ace0f9b284789f66f3ceb30bed66946b93 /acprep
parent014fde3418783d1ee1ec7fe4ea6c8b04ae7f6cd8 (diff)
parent93807fade69dd4f0ec575eda78fe1a77a85c24e3 (diff)
downloadfork-ledger-eda6cbd0146d371653feec70e0eb3ee4e4c56379.tar.gz
fork-ledger-eda6cbd0146d371653feec70e0eb3ee4e4c56379.tar.bz2
fork-ledger-eda6cbd0146d371653feec70e0eb3ee4e4c56379.zip
Merge branch 'next'
Diffstat (limited to 'acprep')
-rwxr-xr-xacprep15
1 files changed, 11 insertions, 4 deletions
diff --git a/acprep b/acprep
index dac869dd..b6aa7cf9 100755
--- a/acprep
+++ b/acprep
@@ -955,7 +955,10 @@ class PrepareBuild(CommandLineApp):
else:
gcc_version = "42"
- if self.current_flavor == 'debug' or self.current_flavor == 'gcov':
+ if gcc_version != "42":
+ self.CPPFLAGS.append('-D_GLIBCXX_FULLY_DYNAMIC_STRING=1')
+
+ if self.current_flavor == 'debug':
if exists('/usr/local/stow/cppunit-gcc%s/include' % gcc_version):
self.sys_include_dirs.insert(
0, '/usr/local/stow/cppunit-gcc%s/include' % gcc_version)
@@ -968,10 +971,11 @@ class PrepareBuild(CommandLineApp):
self.sys_library_dirs.insert(
0, '/usr/local/stow/icu-gcc%s/lib' % gcc_version)
- self.CPPFLAGS.append('-D_GLIBCXX_FULLY_DYNAMIC_STRING=1')
self.configure_args.append('--disable-shared')
self.options.use_glibcxx_debug = True
+ elif self.current_flavor == 'gcov':
+ self.configure_args.append('--disable-shared')
else:
self.CXXFLAGS.append('-march=nocona')
self.CXXFLAGS.append('-msse3')
@@ -1201,7 +1205,7 @@ class PrepareBuild(CommandLineApp):
self.log.debug('Using gcc version: %s' % gcc_version)
- if self.current_flavor == 'debug' or self.current_flavor == 'gcov':
+ if self.current_flavor == 'debug':
if self.options.use_glibcxx_debug:
self.log.debug('We are using GLIBCXX_DEBUG, so setting up flags')
self.CPPFLAGS.append('-D_GLIBCXX_DEBUG=1')
@@ -1282,6 +1286,9 @@ class PrepareBuild(CommandLineApp):
self.LDFLAGS.append(i)
def setup_flavor_gcov(self):
+ # NDEBUG is set so that branch coverage ignores the never-taken else
+ # branch inside assert statements.
+ self.CPPFLAGS.append('-DNDEBUG=1')
self.CXXFLAGS.append('-g')
self.CXXFLAGS.append('-fprofile-arcs')
self.CXXFLAGS.append('-ftest-coverage')
@@ -1405,7 +1412,7 @@ class PrepareBuild(CommandLineApp):
else:
make_args.append(arg)
- if self.options.jobs > 1:
+ if self.options.jobs > 1 and self.current_flavor != 'gcov':
make_args.append('-j%d' % self.options.jobs)
make_args.append('JOBS=%d' % self.options.jobs)