[ltrace-commits] 02/06: test suite now infers language and standard from file extension
Petr Machata
pmachata-guest at moszumanska.debian.org
Tue Sep 2 13:26:54 UTC 2014
This is an automated email from the git hooks/post-receive script.
pmachata-guest pushed a commit to branch pmachata/dima-rebase
in repository ltrace.
commit 2f97352d8167237bf29d9fb63ac7d1a537350861
Author: Petr Machata <pmachata at redhat.com>
Date: Tue Sep 2 15:12:14 2014 +0200
test suite now infers language and standard from file extension
.c11 is C-11
.cc and .cpp is C++
.cc11 is C++-11
This was written by Dima Kogan <lists at dima.secretsauce.net>.
---
testsuite/lib/ltrace.exp | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/testsuite/lib/ltrace.exp b/testsuite/lib/ltrace.exp
index 9931794..a717cd3 100644
--- a/testsuite/lib/ltrace.exp
+++ b/testsuite/lib/ltrace.exp
@@ -100,6 +100,20 @@ proc ltrace_compile {source dest type options} {
set options $new_options
}
+ # .c11 is C-11
+ # .cc and .cpp is C++
+ # .cc11 is C++-11
+ if {[string match "*.c11" $source]} {
+ lappend options "additional_flags=-x c -std=gnu11"
+ }
+ if {[string match "*.cc" $source] ||
+ [string match "*.cpp" $source]} {
+ lappend options c++
+ }
+ if {[string match "*.cc11" $source]} {
+ lappend options c++ "additional_flags=-x c++ -std=gnu++11"
+ }
+
# dump some information for debug purpose.
verbose "options are $options"
verbose "source is $source $dest $type $options"
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/collab-maint/ltrace.git
More information about the ltrace-commits
mailing list