summaryrefslogtreecommitdiff
path: root/tools/build/test/prebuilt/ext
diff options
context:
space:
mode:
Diffstat (limited to 'tools/build/test/prebuilt/ext')
-rw-r--r--tools/build/test/prebuilt/ext/a.cpp17
-rw-r--r--tools/build/test/prebuilt/ext/debug/a.h13
-rw-r--r--tools/build/test/prebuilt/ext/jamfile.jam13
-rw-r--r--tools/build/test/prebuilt/ext/jamfile2.jam39
-rw-r--r--tools/build/test/prebuilt/ext/jamfile3.jam46
-rw-r--r--tools/build/test/prebuilt/ext/jamroot.jam5
-rw-r--r--tools/build/test/prebuilt/ext/release/a.h13
7 files changed, 146 insertions, 0 deletions
diff --git a/tools/build/test/prebuilt/ext/a.cpp b/tools/build/test/prebuilt/ext/a.cpp
new file mode 100644
index 0000000000..c49a041533
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/a.cpp
@@ -0,0 +1,17 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// http://www.boost.org
+//
+
+#ifdef _WIN32
+__declspec(dllexport)
+#endif
+#ifdef RELEASE
+void release() {}
+#else
+void debug() {}
+#endif
diff --git a/tools/build/test/prebuilt/ext/debug/a.h b/tools/build/test/prebuilt/ext/debug/a.h
new file mode 100644
index 0000000000..31b3182265
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/debug/a.h
@@ -0,0 +1,13 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// http://www.boost.org
+//
+
+#ifdef _WIN32
+__declspec(dllimport)
+#endif
+void debug();
diff --git a/tools/build/test/prebuilt/ext/jamfile.jam b/tools/build/test/prebuilt/ext/jamfile.jam
new file mode 100644
index 0000000000..e563f0d741
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/jamfile.jam
@@ -0,0 +1,13 @@
+# Copyright 2002 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
+
+
+project ext
+ : requirements <variant>release:<define>RELEASE
+ ;
+
+lib a : a.cpp ;
+
+install dist : a : <variant>release:<location>release
+ <variant>debug:<location>debug ;
diff --git a/tools/build/test/prebuilt/ext/jamfile2.jam b/tools/build/test/prebuilt/ext/jamfile2.jam
new file mode 100644
index 0000000000..a38bfa7654
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/jamfile2.jam
@@ -0,0 +1,39 @@
+
+import os ;
+
+local dll-suffix = so ;
+local prefix = "" ;
+if [ os.name ] in CYGWIN NT
+{
+ if [ MATCH ^(gcc) : $toolset ]
+ {
+ dll-suffix = dll ;
+ }
+ else
+ {
+ dll-suffix = lib ;
+ }
+}
+else
+{
+ prefix = "lib" ;
+}
+if [ MATCH ^(clang-)?(darwin) : $toolset ]
+{
+ dll-suffix = dylib ;
+}
+
+project ext ;
+
+lib a :
+ : <file>debug/$(prefix)a.$(dll-suffix) <variant>debug
+ :
+ : <include>debug
+ ;
+
+lib a :
+ : <file>release/$(prefix)a.$(dll-suffix) <variant>release
+ :
+ : <include>release
+ ;
+
diff --git a/tools/build/test/prebuilt/ext/jamfile3.jam b/tools/build/test/prebuilt/ext/jamfile3.jam
new file mode 100644
index 0000000000..1731f1743b
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/jamfile3.jam
@@ -0,0 +1,46 @@
+
+# This Jamfile is the same as Jamfile2, except that
+# it tries to access prebuilt targets using absolute
+# paths. It used to be broken on Windows.
+
+import os ;
+
+local dll-suffix = so ;
+local prefix = "" ;
+if [ os.name ] in CYGWIN NT
+{
+ if [ MATCH ^(gcc) : $toolset ]
+ {
+ dll-suffix = dll ;
+ }
+ else
+ {
+ dll-suffix = lib ;
+ }
+}
+else
+{
+ prefix = "lib" ;
+}
+if [ MATCH ^(clang-)?(darwin) : $toolset ]
+{
+ dll-suffix = dylib ;
+}
+
+project ext ;
+
+# Assumed bjam was invoked from the project root
+local pwd = [ PWD ] ;
+
+lib a :
+ : <file>$(pwd)/ext/debug/$(prefix)a.$(dll-suffix) <variant>debug
+ :
+ : <include>debug
+ ;
+
+lib a :
+ : <file>$(pwd)/ext/release/$(prefix)a.$(dll-suffix) <variant>release
+ :
+ : <include>release
+ ;
+
diff --git a/tools/build/test/prebuilt/ext/jamroot.jam b/tools/build/test/prebuilt/ext/jamroot.jam
new file mode 100644
index 0000000000..c7617d5d33
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/jamroot.jam
@@ -0,0 +1,5 @@
+# Copyright 2002, 2004 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
+
+
diff --git a/tools/build/test/prebuilt/ext/release/a.h b/tools/build/test/prebuilt/ext/release/a.h
new file mode 100644
index 0000000000..9ab71d88ce
--- /dev/null
+++ b/tools/build/test/prebuilt/ext/release/a.h
@@ -0,0 +1,13 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// http://www.boost.org
+//
+
+#ifdef _WIN32
+__declspec(dllimport)
+#endif
+void release();