Repository: spack/spack

Issue:
Installation issue: Rose
Trying to install chill, its dependency rose 9.10.0 fails to build with the error output below. I think the critical error is failure to download EDG but there are some other potential issues mentioned. I am building with gcc-7.3.0 on a RHEL6 system. 

```
==> Executing phase: 'build'
==> Error: ProcessError: Command exited with status 2:
    'make' '-j12'

18 errors found in build log:
     444     Successfully ran a simple program with the backend C compiler: /storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc
             /gcc
     445     => cross-compiling... false
     446     build input file for backend compiler
     447     int main(int argc, char** argv){ asm("nop");}
     448     run backend compiler on input file: /storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/gcc -std=c99 -Werror=impli
             cit-function-declaration -c conftest_asm.c
     449     conftest_asm.c: In function 'main':
  >> 450     conftest_asm.c:1:34: error: implicit declaration of function 'asm' [-Werror=implicit-function-declaration]
     451      int main(int argc, char** argv){ asm("nop");}
     452                                       ^~~
     453     cc1: some warnings being treated as errors
     454     status = 1
     455     true case: set asm_ok=no
     456     checking does the backend C compiler (/storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/gcc) support asm stateme
             nts... no

     ...

     460     status = 0
     461     false case: set underscore_asm_ok=yes
     462     checking does the backend C compiler (/storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/gcc) support __asm__ sta
             tements... yes
     463     build input file for backend compiler
     464     asm(".symver ff_av_gettime,av_gettime@LIBAVFORMAT_54");
     465     run backend compiler on input file: /storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/gcc -std=c99 -Werror=impli
             cit-function-declaration -c conftest_long_string_asm.c
  >> 466     conftest_long_string_asm.c:1:5: error: expected declaration specifiers or '...' before string constant
     467      asm(".symver ff_av_gettime,av_gettime@LIBAVFORMAT_54");
     468          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     469     status = 1
     470     true case: set long_string_asm_ok=no
     471     checking does the backend C compiler (/storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/gcc) support asm stateme
             nts... no
     472     checking for C++ compiler vendor... gnu

     ...

     1361    checking for POET... In ROSE SUPPORT MACRO: with_poet no
     1362    Skipping installation for POET!
     1363    Setup installation for POET in ROSE! with_poet = no
     1364    checking for fgrep... /bin/grep -F
     1365    checking for objdump... objdump
     1366    checking for a sed that does not truncate output... (cached) sed
  >> 1367    checking dynamic linker characteristics... /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spac
             k-src/configure: line 23835:  /storage/users/wspear/bin/SPACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0
             -pjk43on4l6bychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/:/storage/users/wspear/bin/SPACK/spack/opt/spack/l
             inux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../..
             /x86_64-pc-linux-gnu/lib/x86_64-pc-linux-gnu/7.3.0/:/storage/users/wspear/bin/SPACK/spack/opt/spack/linux-rhel6-westme
             re/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../x86_64-pc-linux-
             gnu/lib/../lib64/:/storage/users/wspear/bin/SPACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6b
             ychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../x86_64-pc-linux-gnu/7.3.0/:/storage/users/wspear/bin/
             SPACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linu
             x-gnu/7.3.0/../../../../lib64/:/lib/x86_64-pc-linux-gnu/7.3.0/:/lib/../lib64/:/usr/lib/x86_64-pc-linux-gnu/7.3.0/:/usr
             /lib/../lib64/:/storage/users/wspear/bin/SPACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bych
             pz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../x86_64-pc-linux-gnu/lib/:/storage/users/wspear/bin/SP
             ACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bychpz2rowuk6somtudjdm/lib/gcc/x86_64-pc-linux-
             gnu/7.3.0/../../../:/lib/:/usr/lib/: No such file or directory
     1368    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 23876: : command not 
             found
     1369    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 23883: : command not 
             found
     1370    GNU/Linux ld.so
     1371    checking how to run the C++ preprocessor... /storage/users/wspear/bin/SPACK/spack/lib/spack/env/gcc/g++ -E
     1372    checking for flex... flex
     1373    checking lex output file root... lex.yy

     ...

     1544    configure:     PYTHON_VERSION_PATCH_VERSION =
     1545    configure:     ROSE_USE_PYTHON              = /usr/local/packages/python/2.7.7/bin/python2.7
     1546    
     1547    LLVM
     1548    In ROSE SUPPORT MACRO: with_llvm no
     1549    Skipping use of LLVM support (and opt)!
  >> 1550    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33264: /bin/llvm-conf
             ig: No such file or directory
  >> 1551    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33265: /bin/llvm-conf
             ig: No such file or directory
  >> 1552    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33284: /bin/llvm-conf
             ig: No such file or directory
  >> 1553    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33285: /bin/llvm-conf
             ig: No such file or directory
  >> 1554    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33287: /bin/llvm-conf
             ig: No such file or directory
  >> 1555    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33288: /bin/llvm-conf
             ig: No such file or directory
  >> 1556    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33289: /bin/llvm-conf
             ig: No such file or directory
  >> 1557    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/configure: line 33290: /bin/llvm-conf
             ig: No such file or directory
     1558    checking for Wine -- Wine is not an emulator... In ROSE SUPPORT MACRO: with_wine no
     1559    Skipping use of Wine for Windows Binary Analysis!
     1560    checking for specification of EDG union/struct debugging support... In ROSE SUPPORT MACRO: enable_edg_union_struct_deb
             ugging no
     1561    Skipping use of EDG Union/Struct debugging support!
     1562    checking for OpenMP using Omni runtime library... In ROSE SUPPORT MACRO: with_omni_omp_runtime_support no
     1563    Skipping use of Omni OpenMP Runtime support!

     ...

     1797     int main() {return 0;}
     1798         ^~~~
     1799    /tmp/rose_support_i386_28343.c:1:5: warning: function declaration isn't a prototype [-Wstrict-prototypes]
     1800     int main() {return 0;}
     1801         ^~~~
     1802    /storage/users/wspear/bin/SPACK/spack/opt/spack/linux-rhel6-westmere/gcc-6.1.0/gcc-7.3.0-pjk43on4l6bychpz2rowuk6somtud
             jdm/lib/gcc/x86_64-pc-linux-gnu/7.3.0/crtbegin.o: could not read symbols: File in wrong format
  >> 1803    collect2: error: ld returned 1 exit status
     1804    no
     1805    In ROSE SUPPORT MACRO: with_sat no
     1806    Skipping use of internal SAT Solver support!
     1807    with_sat = no
     1808    checking for IntelPin... In ROSE SUPPORT MACRO: with_IntelPin no
     1809    Skipping use of Intel Pin package support!

     ...

     4356    make[5]: Entering directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-bui
             ld/src/ROSETTA/src'
     4357    make[5]: Nothing to be done for `all-am'.
     4358    make[5]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/ROSETTA/src'
     4359    make[4]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/ROSETTA/src'
     4360    /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/scripts/edg-generate-sig /tmp/wspear/
             spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src ../../.. >edg-generate-sig.output.tmp
     4361    diff -q edg-generate-sig.output edg-generate-sig.output.tmp || mv edg-generate-sig.output.tmp edg-generate-sig.output
  >> 4362    diff: edg-generate-sig.output: No such file or directory
     4363    make[4]: Entering directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-bui
             ld/src/frontend/CxxFrontend'
     4364    make[4]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/frontend/CxxFrontend'
     4365    Downloading EDG binary tarball: roseBinaryEDG-4-12-x86_64-pc-linux-gnu-gnu-7.3-4.5d9f1499e6eb31c0440db039b45336adf4e5a
             c6b.tar.gz
  >> 4366    error: the EDG binary tarball is not available (or the web site is not reachable).
     4367    Please contact rose-public@nersc.gov to troubleshoot this error.
  >> 4368    make[3]: *** [EDG.tar.gz] Error 1
     4369    make[3]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/frontend/CxxFrontend'
  >> 4370    make[2]: *** [all-recursive] Error 1
     4371    make[2]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/frontend/CxxFrontend'
  >> 4372    make[1]: *** [all-recursive] Error 1
     4373    make[1]: Leaving directory `/tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-src/rose-buil
             d/src/frontend'
  >> 4374    make: *** [all-recursive] Error 1

See build log for details:
  /tmp/wspear/spack-stage/rose-0.9.10.0-36tk7qmn7j7hv5snpcsplwglv65nkx4z/spack-build-out.txt
```




Discussion:
I tried spack install rose@develop and got this:

```
==> Executing phase: 'autoreconf'
==> Error: ProcessError: Command exited with status 127:
    '/bin/bash' 'build'

1 error found in build log:
     1    ==> Executing phase: 'autoreconf'
     2    ==> [2019-09-30-12:52:17.921359] '/bin/bash' 'build'
  >> 3    /bin/bash: build: No such file or directory

See build log for details:
  /tmp/wspear/spack-stage/rose-develop-ztjkkswuwevnxhamljxvuokkycujp6tt/spack-build-out.txt

```
@justintoo 
Version 0.9.10.0 of rose did not support gcc-7. I'm working on an updated version of ROSE in spack that will support gcc-7.

Resolving patch:
diff --git a/var/spack/repos/builtin/packages/rose/package.py b/var/spack/repos/builtin/packages/rose/package.py
--- a/var/spack/repos/builtin/packages/rose/package.py
+++ b/var/spack/repos/builtin/packages/rose/package.py
@@ -3,10 +3,6 @@
 #
 # SPDX-License-Identifier: (Apache-2.0 OR MIT)
 
-# -----------------------------------------------------------------------------
-# Author: Justin Too
-# -----------------------------------------------------------------------------
-
 from spack import *
 
 
@@ -16,17 +12,49 @@ class Rose(AutotoolsPackage):
        (Developed at Lawrence Livermore National Lab)"""
 
     homepage = "http://rosecompiler.org/"
-    url = "https://github.com/rose-compiler/rose-develop/archive/v0.9.10.0.zip"
-    git = "https://github.com/rose-compiler/rose-develop.git"
+    url = "https://github.com/rose-compiler/rose/archive/v0.9.13.0.zip"
+    git = "https://github.com/rose-compiler/rose.git"
+
+    maintainers = ['pinnown']
 
     # --------------------------------------------------------------------------
     # ROSE Versions
     # --------------------------------------------------------------------------
-    version("0.9.10.0", sha256="7b53b6913fd6ca0c5050b630dae380f3e6b0897cde6148172ba01095f71cbaca")
 
-    # git versions
-    version("0.9.9.52", commit="bd4fc0cc332ce62d9fa54db19879507d9e4f239b")
-    version("develop", branch="master")
+    version("0.9.13.0", sha256="64092793dfd38d476152696721e29a410bb31dc3eeb6064c7520087aa8c904a6")
+
+    # Version for edg binary is found in src/frontend/CxxFrontend/EDG_VERSION
+    # EDG_VERSION may be different from ROSE_VERSION
+    resource(name="roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-4.9-5.0.9.12.52.tar.gz",
+             expand=False,
+             placement="rose-build/src/frontend/CxxFrontend/",
+             when="@0.9.13.0 %gcc@4.9.0:4.9.99",
+             url="http://edg-binaries.rosecompiler.org/roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-4.9-5.0.9.12.52.tar.gz",
+             sha256="fb4b50606bdc681b864bbece46d344d7775780ffe7883aa96305d732c9c04a1c")
+
+    resource(name="roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-5-5.0.9.12.52.tar.gz",
+             expand=False,
+             placement="rose-build/src/frontend/CxxFrontend/",
+             when="@0.9.13.0 %gcc@5.0:5.99",
+             url="http://edg-binaries.rosecompiler.org/roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-5-5.0.9.12.52.tar.gz",
+             sha256="584f8f721274f0f2d5c9a0c7701c045af99580ea7cd1d50999e20c2a897298fb")
+
+    resource(name="roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-6-5.0.9.12.52.tar.gz",
+             expand=False,
+             placement="rose-build/src/frontend/CxxFrontend/",
+             when="@0.9.13.0 %gcc@6.0:6.99",
+             url="http://edg-binaries.rosecompiler.org/roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-6-5.0.9.12.52.tar.gz",
+             sha256="561cd5a944d0dd01689aa0bea8eccf30fc994cd20c4c05da7943c6f36cec25b5")
+
+    resource(name="roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-7-5.0.9.12.52.tar.gz",
+             expand=False,
+             placement="rose-build/src/frontend/CxxFrontend/",
+             when="@0.9.13.0 %gcc@7.0:7.99",
+             url="http://edg-binaries.rosecompiler.org/roseBinaryEDG-5-0-x86_64-pc-linux-gnu-gnu-7-5.0.9.12.52.tar.gz",
+             sha256="800a178804e8b5e936942b4eb036cc61e5d5ad43551cb4fd901ec42ba7e7a176")
+
+    # git versions depends on internet connection at build time
+    version("develop", branch="develop")
 
     # --------------------------------------------------------------------------
     # Dependencies
@@ -34,15 +62,10 @@ class Rose(AutotoolsPackage):
     depends_on("autoconf@2.69:", type="build")
     depends_on("automake@1.14:", type="build")
     depends_on("libtool@2.4:", type="build")
-    depends_on("boost@1.56.0:", when="~cxx11")
 
     # C++11 compatible boost and gcc versions required for +cxx11 variant:
-    # https://github.com/spack/spack/wiki/Telcon%3A-2015-05-14
-    depends_on("boost@1.60.0: cxxstd=11", when="+cxx11")
-
-    # TODO: Doesn't seem to be a way to require a specific compiler: https://github.com/spack/spack/issues/896
-    # https://www.gnu.org/software/gcc/projects/cxx-status.html#cxx11
-    # depends_on("%gcc@4.8.1:", when="^boost@1.60.0: cxxstd=11")
+    depends_on("boost@1.60.0:1.64.0,1.65.1,1.66.0:1.67.0 cxxstd=11", when="+cxx11")
+    depends_on("boost@1.60.0:1.64.0,1.65.1,1.66.0:1.67.0",           when="~cxx11")
 
     # --------------------------------------------------------------------------
     # Variants
@@ -53,6 +76,8 @@ class Rose(AutotoolsPackage):
     variant("tests", default=False, description="Build the tests directory")
     variant("tutorial", default=False, description="Build the tutorial directory")
 
+    variant("tools", default=False, description="Build a selection of ROSE based tools")
+
     variant(
         "mvapich2_backend",
         default=False,
@@ -68,12 +93,10 @@ class Rose(AutotoolsPackage):
     variant("cxx", default=True, description="Enable c++ language support")
 
     # Use spack install cxxflags=-std=c++11
-    variant("cxx11", default=False, description="Enable c++11 language support")
+    variant("cxx11", default=True, description="Enable c++11 language support")
 
     variant("fortran", default=False, description="Enable fortran language support")
-
-    variant("java", default=False, description="Enable java language support")
-    depends_on("jdk", when="+java")
+    depends_on("java@8", when="+fortran")
 
     variant("z3", default=False, description="Enable z3 theorem prover")
     depends_on("z3", when="+z3")
@@ -98,34 +121,7 @@ class Rose(AutotoolsPackage):
 
     build_directory = "rose-build"
 
-    def patch(self):
-        spec = self.spec
-
-        # ROSE needs its   to compute its EDG
-        # binary compatibility signature for C/C++ and for its
-        # --version information.
-        #
-        #       git rev-parse HEAD
-        #     git log -1 --format="%at"
-        #
-        with open("VERSION", "w") as f:
-            if "@0.9.9.104:" in spec:
-                # EDG: 27acd506c6b0e4b1c5f7573c642e3e407237eddd
-                f.write("66c87e9395126a7ab8663d81f0e0b99d6e09131e 1504924600")
-            elif "@0.9.9.0:" in spec:
-                # EDG: 46306e9f73d3ccd690be300aefdaf766a9ba3f70
-                f.write("14d3ebdd7f83cbcc295e6ed45b45d2e9ed32b5ff 1492716108")
-            elif "@0.9.7.0:" in spec:
-                # EDG: 8e63f421f9107ef6c7882b57f9c83e3878623ffa
-                f.write("992c21ad06893bc1e9e7688afe0562eee0fda021 1460595442")
-            elif "@0.9.10.0:" in spec:
-                # EDG: f4624773cb93dfcc67a00efb5e9e8affeb57fb73
-                f.write("277fea7e1e5305e5b3c86b550a0c1354e8285b96 1523991417")
-            else:
-                raise InstallError("Unknown ROSE version!")
-
     def autoreconf(self, spec, prefix):
-        #        if not spec.satisfies('@develop'):
         with working_dir(self.stage.source_path):
             bash = which("bash")
             bash("build")
@@ -145,7 +141,6 @@ def languages(self):
             "binaries" if "+binanalysis" in spec else "",
             "c" if "+c" in spec else "",
             "c++" if "+cxx" in spec else "",
-            "java" if "+java" in spec else "",
             "fortran" if "+fortran" in spec else "",
         ]
         return list(filter(None, langs))
@@ -160,14 +155,8 @@ def configure_args(self):
             cc = spack_cc
             cxx = spack_cxx
 
-        if spec.satisfies("@0.9.8:"):
-            edg = "4.12"
-        else:
-            edg = "4.9"
-
         args = [
             "--disable-boost-version-check",
-            "--enable-edg_version={0}".format(edg),
             "--with-alternate_backend_C_compiler={0}".format(cc),
             "--with-alternate_backend_Cxx_compiler={0}".format(cxx),
             "--with-boost={0}".format(spec["boost"].prefix),
@@ -189,7 +178,7 @@ def configure_args(self):
         else:
             args.append("--disable-tutorial-directory")
 
-        if "+java" in spec:
+        if "+fortran" in spec:
             args.append("--with-java={0}".format(spec["java"].prefix))
         else:
             args.append("--without-java")
@@ -223,45 +212,23 @@ def build(self, spec, prefix):
         #   $ srun -n1 spack install rose
         #
         with working_dir(self.build_directory):
-            # ROSE needs the EDG version for C/C++
-            with open("src/frontend/CxxFrontend/EDG-submodule-sha1", "w") as f:
-                if "@0.9.9.104" in spec:
-                    f.write("27acd506c6b0e4b1c5f7573c642e3e407237eddd")
-                elif "@0.9.9.52" in spec:
-                    f.write("56a826126289414db5436e6c49879b99d046d26d")
-                elif "@0.9.9.0" in spec:
-                    f.write("46306e9f73d3ccd690be300aefdaf766a9ba3f70")
-                elif "@0.9.7.0" in spec:
-                    f.write("8e63f421f9107ef6c7882b57f9c83e3878623ffa")
-                elif "@0.9.10.0" in spec:
-                    f.write("f4624773cb93dfcc67a00efb5e9e8affeb57fb73")
-                else:
-                    raise InstallError("Unknown ROSE version for EDG!")
 
             # Compile librose
-            with working_dir("src"):
-                make()
-
-            # Install librose
-            with working_dir("src"):
-                make("install")
+            make("core")
 
-            # Install "official" ROSE-based tools
-            make("install-core")
-
-            with working_dir("tools"):
-                make("install")
+            if "+tools" in spec:
+                make("tools")
 
             # -----------------------------------------------------------------
             # ROSE-based Projects
             # -----------------------------------------------------------------
             if "+codethorn" in spec:
                 with working_dir("projects/CodeThorn"):
-                    make("install")
+                    make()
 
             if "+autopar" in spec:
                 with working_dir("projects/autoParallelization"):
-                    make("install")
+                    make()
 
             if "+polyopt" in spec:
                 mkdir = which("mkdir")
@@ -277,3 +244,23 @@ def build(self, spec, prefix):
                             "projects/PolyOpt2/install.sh"
                         )
                     )
+
+    def install(self, spec, prefix):
+        with working_dir(self.build_directory):
+
+            # Compile and Install librose
+            make("install-core")
+
+            if "+tools" in spec:
+                make("install-tools")
+
+            # -----------------------------------------------------------------
+            # ROSE-based Projects
+            # -----------------------------------------------------------------
+            if "+codethorn" in spec:
+                with working_dir("projects/CodeThorn"):
+                    make("install")
+
+            if "+autopar" in spec:
+                with working_dir("projects/autoParallelization"):
+                    make("install")


Test patch: