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  <20172018  2019  2020  2021  2022  2023  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  <20172018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: EPICS build system DESTDIR support
From: "J. Lewis Muir" <[email protected]>
To: Andrew Johnson <[email protected]>
Cc: [email protected]
Date: Wed, 5 Jul 2017 12:25:23 -0500
On 07/05, Andrew Johnson wrote:
> On 06/20/2017 03:38 PM, J. Lewis Muir wrote:
> > On top of that, I'm thinking the environment variable approach won't
> > even work on macOS Sierra (and El Capitan too?) with SIP enabled
> > since /bin/sh is a so-called protected process, and [1] says:
> > 
> >   Spawning children processes of processes restricted by System
> >   Integrity Protection, such as by launching a helper process in a
> >   bundle with NSTask or calling the exec(2) command, resets the Mach
> >   special ports of that child process. Any dynamic linker (dyld)
> >   environment variables, such as DYLD_LIBRARY_PATH, are purged when
> >   launching protected processes.
> >
> > So, even if DYLD_LIBRARY_PATH was set, it might get removed from the
> > executable's environment by SIP depending on how it gets executed.
> 
> That quotation is discussing launching processes inside a bundle. I
> don't think we would do that — I'm not a MacOS expert, but we don't
> create an EPICS Base bundle for the Mac, so that seems irrelevant to me.

I don't think so.  Just invoking /bin/sh from a shell exhibits the
purging of the DYLD_LIBRARY_PATH environment variable.  Consider the
following (on macOS Sierra):

===
% export DYLD_LIBRARY_PATH=a
% echo $DYLD_LIBRARY_PATH
a
% export MY_VAR=b
% echo $MY_VAR
b
% /bin/sh -c 'echo $DYLD_LIBRARY_PATH'

% /bin/sh -c 'echo $MY_VAR'
b
===

Lewis

Replies:
Re: EPICS build system DESTDIR support Andrew Johnson
References:
Re: EPICS build system DESTDIR support J. Lewis Muir
Re: EPICS build system DESTDIR support Andrew Johnson

Navigate by Date:
Prev: Re: EPICS build system DESTDIR support Andrew Johnson
Next: Re: EPICS build system DESTDIR support Andrew Johnson
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: EPICS build system DESTDIR support Andrew Johnson
Next: Re: EPICS build system DESTDIR support Andrew Johnson
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <20172018  2019  2020  2021  2022  2023  2024 
ANJ, 21 Dec 2017 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·