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 2022 2023 2024 2025 | 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 2022 2023 2024 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: Problem building aravisGigE on Centos 7 |
From: | Ralph Lange <[email protected]> |
To: | EPICS Tech Talk <[email protected]> |
Date: | Mon, 2 Jul 2018 09:12:58 +0200 |
On 06/30/2018 06:41 AM, Mark Rivers wrote:
> Hi Michael,
>
> Thanks, adding the second line below to the Makefile fixed it.
>
> PROD_SYS_LIBS += giomm-2.4
> PROD_SYS_LIBS += gio-2.0 gobject-2.0 gthread-2.0 glib-2.0
>
> I was puzzled why it worked previously when the Makefile contained only the first line, i.e. giomm=2.4.
>
> I think I have figured it out. If I add this line to the Makefile it builds fine without the second line above:
>
> STATIC_BUILD=NO
>
> If it is building dynamically then libgiomm-2.4.so has the information it needs to know what other libraries are required. But if I build statically then I need to specify the other libraries. When this worked previously for me I must have been building dynamically. Does this make sense?
Yes. Static libraries (.a files) don't contain the dependency information found in shared object (.so).
So when linking STATIC_BUILD=NO, only the direct dependencies need to be listed (it doesn't hurt to list all).
With STATIC_BUILD=YES, all dependencies must be listed, and in a specific order (direct first).