EPICS Home

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  2022  2023  <20242025  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  <20242025 
<== Date ==> <== Thread ==>

Subject: Re: Asyn Module Cross-Compilation: Cannot find -ltirpc
From: "Johnson, Andrew N. via Tech-talk" <tech-talk at aps.anl.gov>
To: "Ramirez-Morales, Jacob J (CONTR)" <RAMIREJJ at nv.doe.gov>, "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Mon, 15 Jul 2024 21:09:35 +0000

Hi Jacob,

 

Whether you need to use tirpc for the cRIO build would depend on the libc (presumably glibc) that your linux-x86_64-cRIO target uses, not what OS the cross-compiler runs on. I don't know the answer to that, but given the error you are seeing have you tried setting TIRPC=NO in your CONFIG_SITE.Common.linux-x86_64.linux-x86_64-cRIO file? That tells the Asyn build that the RPC routines are found in the standard C libraries, not in an external rpc library.

 

If you have been told that you need to use tirpc for the target, it might be that you also need to install a -devel package. On my RHEL-8 system here the host's libtirpc.so.3.0.0 shared library is installed from the RPM libtirpc-1.1.4-8.el8.x86_64 but there is a soft-link used for library versioning and that Asyn actually links to which comes from the RPM libtirpc-devel-1.1.4-8.el8.x86_64 (and also provides the header files):

 

voltctl% ls -l /usr/lib64/libtirpc*

lrwxrwxrwx  1 root root     17 Aug  3  2022 /usr/lib64/libtirpc.so -> libtirpc.so.3.0.0*

lrwxrwxrwx. 1 root root     17 Aug  3  2022 /usr/lib64/libtirpc.so.3 -> libtirpc.so.3.0.0*

-rwxr-xr-x. 1 root root 217696 Aug  3  2022 /usr/lib64/libtirpc.so.3.0.0*

voltctl% rpm -qf /usr/lib64/libtirpc.so.3

libtirpc-1.1.4-8.el8.x86_64

voltctl% rpm -qf /usr/lib64/libtirpc.so.3.0.0        

libtirpc-1.1.4-8.el8.x86_64

voltctl% rpm -qf /usr/lib64/libtirpc.so

libtirpc-devel-1.1.4-8.el8.x86_64

 

 

HTH,

 

- Andrew

 

-- 

Complexity comes for free, Simplicity you have to work for.

 

 

On 7/15/24, 3:09 PM, "Tech-talk" <tech-talk-bounces at aps.anl.gov> wrote:

 

Hello EPICS community,

 

I am currently working on a project where I need to cross-compile my EPICS environment for my linux-x86_64-cRIO target. I was able to compile EPICS base with the target architecture included as a STATIC_BUILD. To do this I followed the steps show below:

1.      Downloaded and ran the National instruments GNU C & C++ Compile Tools x64 (Version: 2023 Q4)

2.      In my epics-base configure directory, I added the following files:

·         CONFIG_SITE.local

o    CROSS_COMILER_TARGET_ARCHS += linux-x86_64-cRIO

·         os/CONFIG_SITE.Common.linux-x86_64.linux-x86_64-cRIO

o    STATIC_BUILD=YES

o    SHARED_LIBRARIES=NO

·         os/CONFIG.Common.linux-x86_64-cRIO

3.      After these are included, I am able to run make under epics-base successfully.

 

However, I am encountering an issue during the compilation process of Asyn, specifically with the following error message:

 

“/ni/oecore-x86_64/sysroots/x86_64-nilrtsdk-linux/usr/libexec/x86_64-nilrt-linux/gcc/x86_64-nilrt-linux/11.3.0/ld: cannot find -ltirpc: No such file or directory

Collect2: error: ld returned 1 exit status”

 

The ‘ni/oecore-x86_64’ is the directory I have downloaded my GNU C & C++ Compiler Toolchain. Additionally, I have confirmed that libtirpc should also be included with the compile toolchain for my cRIO target, along with numerous other libraries.

 

I understand the ltripc is the library for the RPC (Remote Procedure Call) interface; I have set the TIRPC=YES flag in my ‘asyn/configure/CONFIG_SITE’ file since I am running RHEL 8.10.

 

Could anyone provide guidance or share their experiences with cross-compiling the Asyn module for a cRIO target using libtirpc.

 

Best,

Jacob R.

 


Replies:
RE: [EXTERNAL]Re: Asyn Module Cross-Compilation: Cannot find -ltirpc Ramirez-Morales, Jacob J (CONTR) via Tech-talk
References:
Asyn Module Cross-Compilation: Cannot find -ltirpc Ramirez-Morales, Jacob J (CONTR) via Tech-talk

Navigate by Date:
Prev: Asyn Module Cross-Compilation: Cannot find -ltirpc Ramirez-Morales, Jacob J (CONTR) via Tech-talk
Next: Use PV value as a macro definition when opening a display William F Badgett Jr 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  2022  2023  <20242025 
Navigate by Thread:
Prev: Asyn Module Cross-Compilation: Cannot find -ltirpc Ramirez-Morales, Jacob J (CONTR) via Tech-talk
Next: RE: [EXTERNAL]Re: Asyn Module Cross-Compilation: Cannot find -ltirpc Ramirez-Morales, Jacob J (CONTR) 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  2022  2023  <20242025