summaryrefslogtreecommitdiffstats
path: root/src/boost/tools/build/test/project-test3
diff options
context:
space:
mode:
Diffstat (limited to 'src/boost/tools/build/test/project-test3')
-rw-r--r--src/boost/tools/build/test/project-test3/a.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/jamfile.jam13
-rw-r--r--src/boost/tools/build/test/project-test3/jamroot.jam67
-rw-r--r--src/boost/tools/build/test/project-test3/lib/b.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/lib/jamfile.jam9
-rw-r--r--src/boost/tools/build/test/project-test3/lib2/c.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/lib2/d.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/lib2/helper/e.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/lib2/helper/jamfile.jam9
-rw-r--r--src/boost/tools/build/test/project-test3/lib2/jamfile.jam11
-rw-r--r--src/boost/tools/build/test/project-test3/lib3/f.cpp5
-rw-r--r--src/boost/tools/build/test/project-test3/lib3/jamfile.jam47
-rw-r--r--src/boost/tools/build/test/project-test3/lib3/jamroot.jam5
-rw-r--r--src/boost/tools/build/test/project-test3/readme.txt7
14 files changed, 198 insertions, 0 deletions
diff --git a/src/boost/tools/build/test/project-test3/a.cpp b/src/boost/tools/build/test/project-test3/a.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/a.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/jamfile.jam b/src/boost/tools/build/test/project-test3/jamfile.jam
new file mode 100644
index 000000000..1151d5943
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/jamfile.jam
@@ -0,0 +1,13 @@
+# Copyright 2002, 2003 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+
+use-project /lib2 : lib2 ;
+use-project /lib3 : lib3 ;
+
+make a.exe : a.obj lib//b.obj /lib2//c.obj lib2//d.obj lib2/helper//e.obj /lib3//f.obj : yfc-link ;
+make a.obj : a.cpp : yfc-compile ;
+
+build-project lib2 ;
+build-project lib ;
diff --git a/src/boost/tools/build/test/project-test3/jamroot.jam b/src/boost/tools/build/test/project-test3/jamroot.jam
new file mode 100644
index 000000000..e27103dce
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/jamroot.jam
@@ -0,0 +1,67 @@
+# Copyright 2002-2005 Vladimir Prus.
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or copy at
+# https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+import os ;
+import gcc ;
+import property ;
+import toolset ;
+
+rule properties-as-path ( properties * )
+{
+ local r ;
+ for local p in $(properties)
+ {
+ if $(p:G) != <action>
+ {
+ r += $(p) ;
+ }
+ }
+ return [ property.as-path
+ [ property.remove incidental : $(r) ] ] ;
+}
+
+toolset.flags yfc-compile KNOWN-PROPERTIES : <toolset> <optimization> ;
+toolset.flags yfc-link KNOWN-PROPERTIES : <toolset> <optimization> ;
+
+rule yfc-compile ( target : sources * : property-set * )
+{
+ PROPERTIES on $(target) = [ properties-as-path $(property-set) ] ;
+}
+
+actions yfc-compile
+{
+ echo $(PROPERTIES) > $(<)
+ echo $(>) >> $(<)
+}
+
+rule yfc-link ( target : sources * : property-set * )
+{
+ PROPERTIES on $(target) = [ properties-as-path $(property-set) ] ;
+}
+
+actions yfc-link
+{
+ echo $(PROPERTIES) > $(<)
+ echo $(>) >> $(<)
+}
+
+if [ os.name ] = VMS
+{
+ actions yfc-compile
+ {
+ PIPE WRITE SYS$OUTPUT "$(PROPERTIES)" | TYPE SYS$INPUT /OUT=$(<:W)
+ PIPE WRITE SYS$OUTPUT "$(>:J= ",")" | APPEND /NEW SYS$INPUT $(<:W)
+ }
+
+ actions yfc-link
+ {
+ PIPE WRITE SYS$OUTPUT "$(PROPERTIES)" | TYPE SYS$INPUT /OUT=$(<:W)
+ OPEN /APPEND FOUT $(<:W)
+ WRITE FOUT "$(>:J= ",")"
+ CLOSE FOUT
+ }
+}
+
+IMPORT $(__name__) : yfc-compile yfc-link : : yfc-compile yfc-link ;
diff --git a/src/boost/tools/build/test/project-test3/lib/b.cpp b/src/boost/tools/build/test/project-test3/lib/b.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib/b.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/lib/jamfile.jam b/src/boost/tools/build/test/project-test3/lib/jamfile.jam
new file mode 100644
index 000000000..bae24c16b
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib/jamfile.jam
@@ -0,0 +1,9 @@
+# Copyright 2002, 2003 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+
+use-project /lib2 : ../lib2 ;
+
+make b.obj : b.cpp : yfc-compile ;
+make m.exe : b.obj /lib2//c.obj : yfc-link ;
diff --git a/src/boost/tools/build/test/project-test3/lib2/c.cpp b/src/boost/tools/build/test/project-test3/lib2/c.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib2/c.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/lib2/d.cpp b/src/boost/tools/build/test/project-test3/lib2/d.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib2/d.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/lib2/helper/e.cpp b/src/boost/tools/build/test/project-test3/lib2/helper/e.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib2/helper/e.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/lib2/helper/jamfile.jam b/src/boost/tools/build/test/project-test3/lib2/helper/jamfile.jam
new file mode 100644
index 000000000..7d8966a98
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib2/helper/jamfile.jam
@@ -0,0 +1,9 @@
+# Copyright 2002 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+
+project lib2/helper ;
+
+make e.obj : e.cpp : yfc-compile ;
+
diff --git a/src/boost/tools/build/test/project-test3/lib2/jamfile.jam b/src/boost/tools/build/test/project-test3/lib2/jamfile.jam
new file mode 100644
index 000000000..300aa3228
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib2/jamfile.jam
@@ -0,0 +1,11 @@
+# Copyright 2002, 2003 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+
+project lib2 ;
+use-project /lib2/helper : helper ;
+
+make c.obj : c.cpp : yfc-compile ;
+make d.obj : d.cpp : yfc-compile ;
+make l.exe : c.obj ..//a.obj : yfc-link ;
diff --git a/src/boost/tools/build/test/project-test3/lib3/f.cpp b/src/boost/tools/build/test/project-test3/lib3/f.cpp
new file mode 100644
index 000000000..6547c9232
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib3/f.cpp
@@ -0,0 +1,5 @@
+// Copyright (c) 2003 Vladimir Prus
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE.txt or copy at
+// https://www.bfgroup.xyz/b2/LICENSE.txt)
diff --git a/src/boost/tools/build/test/project-test3/lib3/jamfile.jam b/src/boost/tools/build/test/project-test3/lib3/jamfile.jam
new file mode 100644
index 000000000..7c4a70398
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib3/jamfile.jam
@@ -0,0 +1,47 @@
+# Copyright 2003, 2005 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
+# This project-root.jam also serves the role of Jamfile
+project lib3 ;
+
+use-project /lib2/helper : ../lib2/helper ;
+
+import os ;
+import property ;
+
+rule properties-as-path ( properties * )
+{
+ local r ;
+ for local p in $(properties)
+ {
+ if $(p:G) != <action>
+ {
+ r += $(p) ;
+ }
+ }
+ return [ property.as-path
+ [ property.remove incidental : $(r) ] ] ;
+}
+
+rule mfc-compile ( target : sources * : property-set * )
+{
+ PROPERTIES on $(target) = [ properties-as-path $(property-set) ] ;
+}
+
+actions mfc-compile
+{
+ echo $(PROPERTIES) > $(<)
+ echo $(>) >> $(<)
+}
+
+if [ os.name ] = VMS
+{
+ actions mfc-compile
+ {
+ PIPE WRITE SYS$OUTPUT "$(PROPERTIES)" | TYPE SYS$INPUT /OUT=$(<:W)
+ PIPE WRITE SYS$OUTPUT "$(>:J= ",")" | APPEND /NEW SYS$INPUT $(<:W)
+ }
+}
+
+make f.obj : f.cpp /lib2/helper//e.obj : mfc-compile ;
diff --git a/src/boost/tools/build/test/project-test3/lib3/jamroot.jam b/src/boost/tools/build/test/project-test3/lib3/jamroot.jam
new file mode 100644
index 000000000..2344236fe
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/lib3/jamroot.jam
@@ -0,0 +1,5 @@
+# Copyright 2002 Rene Rivera
+# Copyright 2002, 2003 Vladimir Prus
+# Distributed under the Boost Software License, Version 1.0.
+# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
+
diff --git a/src/boost/tools/build/test/project-test3/readme.txt b/src/boost/tools/build/test/project-test3/readme.txt
new file mode 100644
index 000000000..da27e54b2
--- /dev/null
+++ b/src/boost/tools/build/test/project-test3/readme.txt
@@ -0,0 +1,7 @@
+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)
+
+
+This test checks that we have minimally working 'make' rule and that we can use target from
+different project with different project roots.