diff --git a/test/railsys.py b/test/railsys.py new file mode 100644 index 000000000..1581a0e31 --- /dev/null +++ b/test/railsys.py @@ -0,0 +1,15 @@ +#!/usr/bin/python + +# Copyright (C) Vladimir Prus 2003. Permission to copy, use, modify, sell and +# distribute this software is granted provided this copyright notice appears in +# all copies. This software is provided "as is" without express or implied +# warranty, and with no claim as to its suitability for any purpose. + +from BoostBuild import Tester, List + +t = Tester() + +t.set_tree("railsys") +t.run_build_system("--v2", subdir="program") + +t.cleanup() diff --git a/test/railsys/libx/include/libx/test_libx.h b/test/railsys/libx/include/libx/test_libx.h index 016cb0615..15e3db978 100644 --- a/test/railsys/libx/include/libx/test_libx.h +++ b/test/railsys/libx/include/libx/test_libx.h @@ -12,4 +12,8 @@ class TestLibX public: TestLibX(); + + // Needed to suppress 'unused variable' warning + // in some cases. + void do_something() {} }; diff --git a/test/railsys/libx/project-root.jam b/test/railsys/libx/project-root.jam index 5e727508f..acee942fa 100644 --- a/test/railsys/libx/project-root.jam +++ b/test/railsys/libx/project-root.jam @@ -1,10 +1,9 @@ -import gcc ; import toolset ; # Tell that QT should be used. QTDIR will give installation # prefix. toolset.using qt ; -#Alternatively, the prefix can be given as second argument -#toolset.using qt : /usr/share/qt ; \ No newline at end of file +# Not that good, but sufficient for testing +toolset.using stlport : /path/to/stlport ; diff --git a/test/railsys/program/include/test_a.h b/test/railsys/program/include/test_a.h index d86a7dd95..f49218a1f 100644 --- a/test/railsys/program/include/test_a.h +++ b/test/railsys/program/include/test_a.h @@ -17,4 +17,7 @@ class TestA : public QObject public: TestA(); + + // Needed to suppress 'unused variable' varning. + void do_something() { } }; diff --git a/test/railsys/program/liba/test_a.cpp b/test/railsys/program/liba/test_a.cpp index b2aa64fc6..f459114ee 100644 --- a/test/railsys/program/liba/test_a.cpp +++ b/test/railsys/program/liba/test_a.cpp @@ -14,4 +14,5 @@ TestA::TestA() { TestLibX aTestLibX; + aTestLibX.do_something(); } diff --git a/test/railsys/program/main/main.cpp b/test/railsys/program/main/main.cpp index 3ce665738..bd9a166d3 100644 --- a/test/railsys/program/main/main.cpp +++ b/test/railsys/program/main/main.cpp @@ -15,4 +15,6 @@ int main() { TestLibX stTestLibX; TestA stTestA; + + stTestLibX.do_something(); }; diff --git a/test/railsys/program/project-root.jam b/test/railsys/program/project-root.jam index 33ce8decc..acee942fa 100644 --- a/test/railsys/program/project-root.jam +++ b/test/railsys/program/project-root.jam @@ -1,11 +1,9 @@ -import gcc ; -#import msvc ; import toolset ; # Tell that QT should be used. QTDIR will give installation # prefix. toolset.using qt ; -#Alternatively, the prefix can be given as second argument -#toolset.using qt : /usr/share/qt ; +# Not that good, but sufficient for testing +toolset.using stlport : /path/to/stlport ; diff --git a/test/test_all.py b/test/test_all.py index f98343c7c..17cb6cc60 100644 --- a/test/test_all.py +++ b/test/test_all.py @@ -85,6 +85,7 @@ tests = [ "project_test1", "alternatives", "unused", "default_features", + "railsys", ] if os.name == 'posix': diff --git a/v2/test/railsys.py b/v2/test/railsys.py new file mode 100644 index 000000000..1581a0e31 --- /dev/null +++ b/v2/test/railsys.py @@ -0,0 +1,15 @@ +#!/usr/bin/python + +# Copyright (C) Vladimir Prus 2003. Permission to copy, use, modify, sell and +# distribute this software is granted provided this copyright notice appears in +# all copies. This software is provided "as is" without express or implied +# warranty, and with no claim as to its suitability for any purpose. + +from BoostBuild import Tester, List + +t = Tester() + +t.set_tree("railsys") +t.run_build_system("--v2", subdir="program") + +t.cleanup() diff --git a/v2/test/railsys/libx/include/libx/test_libx.h b/v2/test/railsys/libx/include/libx/test_libx.h index 016cb0615..15e3db978 100644 --- a/v2/test/railsys/libx/include/libx/test_libx.h +++ b/v2/test/railsys/libx/include/libx/test_libx.h @@ -12,4 +12,8 @@ class TestLibX public: TestLibX(); + + // Needed to suppress 'unused variable' warning + // in some cases. + void do_something() {} }; diff --git a/v2/test/railsys/libx/project-root.jam b/v2/test/railsys/libx/project-root.jam index 5e727508f..acee942fa 100644 --- a/v2/test/railsys/libx/project-root.jam +++ b/v2/test/railsys/libx/project-root.jam @@ -1,10 +1,9 @@ -import gcc ; import toolset ; # Tell that QT should be used. QTDIR will give installation # prefix. toolset.using qt ; -#Alternatively, the prefix can be given as second argument -#toolset.using qt : /usr/share/qt ; \ No newline at end of file +# Not that good, but sufficient for testing +toolset.using stlport : /path/to/stlport ; diff --git a/v2/test/railsys/program/include/test_a.h b/v2/test/railsys/program/include/test_a.h index d86a7dd95..f49218a1f 100644 --- a/v2/test/railsys/program/include/test_a.h +++ b/v2/test/railsys/program/include/test_a.h @@ -17,4 +17,7 @@ class TestA : public QObject public: TestA(); + + // Needed to suppress 'unused variable' varning. + void do_something() { } }; diff --git a/v2/test/railsys/program/liba/test_a.cpp b/v2/test/railsys/program/liba/test_a.cpp index b2aa64fc6..f459114ee 100644 --- a/v2/test/railsys/program/liba/test_a.cpp +++ b/v2/test/railsys/program/liba/test_a.cpp @@ -14,4 +14,5 @@ TestA::TestA() { TestLibX aTestLibX; + aTestLibX.do_something(); } diff --git a/v2/test/railsys/program/main/main.cpp b/v2/test/railsys/program/main/main.cpp index 3ce665738..bd9a166d3 100644 --- a/v2/test/railsys/program/main/main.cpp +++ b/v2/test/railsys/program/main/main.cpp @@ -15,4 +15,6 @@ int main() { TestLibX stTestLibX; TestA stTestA; + + stTestLibX.do_something(); }; diff --git a/v2/test/railsys/program/project-root.jam b/v2/test/railsys/program/project-root.jam index 33ce8decc..acee942fa 100644 --- a/v2/test/railsys/program/project-root.jam +++ b/v2/test/railsys/program/project-root.jam @@ -1,11 +1,9 @@ -import gcc ; -#import msvc ; import toolset ; # Tell that QT should be used. QTDIR will give installation # prefix. toolset.using qt ; -#Alternatively, the prefix can be given as second argument -#toolset.using qt : /usr/share/qt ; +# Not that good, but sufficient for testing +toolset.using stlport : /path/to/stlport ; diff --git a/v2/test/test_all.py b/v2/test/test_all.py index f98343c7c..17cb6cc60 100644 --- a/v2/test/test_all.py +++ b/v2/test/test_all.py @@ -85,6 +85,7 @@ tests = [ "project_test1", "alternatives", "unused", "default_features", + "railsys", ] if os.name == 'posix':