Opened 7 years ago

Closed 7 years ago

#55630 closed defect (fixed)

port:clang-5.0 : ClangTargets-${cmake.build_type}.cmake refers to clang-5.0

Reported by: RJVB (René Bertin) Owned by: jeremyhu (Jeremy Huddleston Sequoia)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: jeremyhu (Jeremy Huddleston Sequoia), larryv (Lawrence Velázquez)
Port: clang-5.0

Description

The file ${prefix}/libexec/llvm-5.0/lib/cmake/clang/ClangTargets-${cmake.build_type}.cmake is installed with post-processing; it should get a reinplace:

        file rename ${destroot}${sub_prefix}/bin/clang-${clang_executable_version} ${destroot}${sub_prefix}/bin/clang
+        reinplace "s|/bin/clang-${clang_executable_version}|/bin/clang|g" \
            "${destroot}${sub_prefix}/lib/cmake/clang/ClangTargets-[string tolower ${cmake.build_type}].cmake"

(cmake.build_type is defined by the cmake-1.1 PG)

Attachments (1)

clang-cmake-module.diff (2.9 KB) - added by RJVB (René Bertin) 7 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 7 years ago by jeremyhu (Jeremy Huddleston Sequoia)

LGTM. Please do that for all the relevant ports and revbump the clang sub-port. Thanks.

comment:2 Changed 7 years ago by RJVB (René Bertin)

FWIW, I cannot remember running into this with clang 4 (I have a local patch for the lldb subport that makes it do a standalone build) so maybe it's not required. I'll fetch the binary tarball and check in there.

You know I don't have commit access, right?

Changed 7 years ago by RJVB (René Bertin)

Attachment: clang-cmake-module.diff added

comment:3 Changed 7 years ago by RJVB (René Bertin)

Patch attached. I think the "clang" target is new in 4.0(.1) (and apparently I fixed it in my own build without creating a patch).

NB, clang takes way too long to build so I have NOT tested these mods after adapting them for use without cmake.build_type.

comment:4 Changed 7 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Owner: set to jeremyhu
Resolution: fixed
Status: newclosed

In 70206c8dcaec0e73e04df6e09ff720b476a4ea2f/macports-ports:

clang-{4.0,5.0,devel}: Fix the path to clang in ClangTargets-${cmake.build_type}.cmake

Fixes #55630

Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@…>

Note: See TracTickets for help on using tickets.