[CMake] Re: RPATH and $ORIGIN

David Cole david.cole at kitware.com
Thu Jan 17 15:55:19 EST 2008


Did you try "\\\$"?

Both $ and \ need escaping inside the CMake set statement so that you end up
with "\$" in the variable's value...

And if it goes through another round of CMake substitution, you may even
need something crazy like:
"\\\\\\\$"


HTH,
David


On 1/17/08, Iker Arizmendi <iker at research.att.com> wrote:
>
> Sorry, I should have been clearer in my last post. I also
> tried escaping the value I put into CMAKE_INSTALL_RPATH but
> CMake successfully fought me off. Below are some of the
> results for an installed executable. Each "SET" is followed
> by the rpath that actually made it to the executable:
>
>     SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_RPATH}:\$ORIGIN/xxx")
>     Library rpath: [/home/iker/tmp/rpath_test/:RIGIN/xxx]
>
>     SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_RPATH}:$$ORIGIN/xxx")
>     Library rpath: [/home/iker/tmp/rpath_test/:/xxx]
>
>     SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_RPATH}:\\$ORIGIN/xxx")
>     Library rpath: [/home/iker/tmp/rpath_test/:/RIGIN/xxx]
>
>     SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_RPATH}:\\$$ORIGIN/xxx")
>     Library rpath: [/home/iker/tmp/rpath_test/://xxx]
>
> Iker
>
> James Bigler wrote:
> > I asked if you had tried various permutations of escapes with the
> > original command [SET(CMAKE_INSTALL_RPATH
> > "${CMAKE_INSTALL_RPATH}:$ORIGIN/../xxx")] not the ones with the hard
> > coded -Wl,-rpath.  From your original email it appears you only tried
> > various permutations with the setting the linker path directly:
>
>
> --
> Iker Arizmendi
> AT&T Labs - Research
> Speech and Image Processing Lab
> e: iker at research.att.com
> w: http://research.att.com
> p: 973-360-8516
>
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20080117/95e2807f/attachment.htm


More information about the CMake mailing list