EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
<== Date ==> <== Thread ==>

Subject: Re: forcing rpath
From: Michael Davidsaver via Tech-talk <tech-talk at aps.anl.gov>
To: Pierrick M Hanlet <hanlet at fnal.gov>
Cc: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Sun, 14 Aug 2022 21:24:50 -0700
On 8/12/22 08:27, Pierrick M Hanlet via Tech-talk wrote:
Hi,
I'm using v7.0.5.1 with buildroot to build for several platforms. The
build is done in a /scratch
area, but I'd like the -Wl,-rpath, to point to /usr/local.  I believe
that I found the documentation
for it, namely:
https://epics-base.github.io/epics-base/releasenotes.html, but it's not
clear to me
that I'm doing things correctly; it's certainly not changing my rpath at
link time.

LINKER_USE_RPATH=ORIGIN
LINKER_ORIGIN_ROOT=/scratch/products

Are you setting $(INSTALL_LOCATION) as well?

If so, then you should set LINKER_ORIGIN_ROOT=$INSTALL_LOCATION
(which is the default), or a parent of $INSTALL_LOCATION .


If not, do you see any errors from makeRPath.py?

eg. https://github.com/epics-base/epics-base/blob/424d678abff19887cd2fa9ff5af82e33806a3712/src/tools/makeRPath.py#L61

For a working example see:

https://github.com/mdavidsaver/build-epics/blob/d70458fa0f15fb444954a55afa9d284f8e5fbcac/build-epics.sh#L47

With these in CONFIG_SITE, I'm expecting -Wl,-rpath,/scratch/products to
change to -Wl,-rpath,$ORIGIN

which I can then define as I'd like.

I'm a little confused by this.  In the context of
"-rpath", "$ORIGIN" is not an environment variable.
This isn't something you set explicitly.  Rather
"$ORIGIN" is computed automatically by the runtime
linker based on the directory containing an executable
or shared library.

References:
forcing rpath Pierrick M Hanlet via Tech-talk

Navigate by Date:
Prev: CSS spinner and text box instant write Wang, Andrew via Tech-talk
Next: Re: Makefile rule differences with base 3.14 vs 3.15+ in ADCore build with pvi Michael Davidsaver via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
Navigate by Thread:
Prev: forcing rpath Pierrick M Hanlet via Tech-talk
Next: CSS spinner and text box instant write Wang, Andrew via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
ANJ, 14 Sep 2022 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·