<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#954F72;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle18
{mso-style-type:personal;
font-family:"Calibri",sans-serif;
color:windowtext;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt">Ah, interesting \u2013 I got a question off list about this, but I thought I\u2019d reply here.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">\u2018ldd\u2019 on the lfs binary says \u201cnot a dynamic executable\u201d.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">So it seems I\u2019m confused (never was much for compilers and linkers). Here are the errors I get trying to run it on another node:<br>
./lfs: line 202: cd: /home/build/paf/[\u2026\u2026..]/lustre/utils: No such file or directory<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">gcc: error: lfs.o: No such file or directory<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">gcc: error: lfs_project.o: No such file or directory<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">gcc: error: ./.libs/liblustreapi.so: No such file or directory<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">gcc: error: ../../lnet/utils/lnetconfig/.libs/liblnetconfig.so<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="color:black">From: </span></b><span style="color:black">lustre-discuss <lustre-discuss-bounces@lists.lustre.org> on behalf of Patrick Farrell <paf@cray.com><br>
<b>Date: </b>Friday, March 23, 2018 at 3:03 PM<br>
<b>To: </b>"lustre-discuss@lists.lustre.org" <lustre-discuss@lists.lustre.org><br>
<b>Subject: </b>[lustre-discuss] Static lfs?<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
</div>
<p class="MsoNormal"><a name="_MailOriginalBody"><span style="font-size:11.0pt;color:black">Good afternoon,</span><o:p></o:p></a></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black"> </span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black">I\u2019ve got a developer question that perhaps someone has some insight on. After some recent (a few months ago now) changes to make the Lustre libraries
and utilities build dynamically linked rather than statically linked, I\u2019ve got a problem. If I build an lfs binary just by doing \u201cmake\u201d, the resultant binary looks for various libraries in the build directories and cannot be run on any system other than the
one it was built on (well, I guess without replicating the build directory structure). When doing make rpms and installing the RPMs, it works fine. The problem is \u201cmake rpms\u201d takes ~5 minutes, as opposed to ~1 second for \u201cmake\u201d in /utils. (I assume \u201cmake
install\u201d works too, but I explicitly need to test on nodes other than the one where I\u2019m doing the build, so that\u2019s not an option.)</span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black"> </span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black">Does anyone have any insight on a way around this for a developer? Either some tweak I can make locally to get static builds again, or some fix to
make that would let the dynamically linked binary from \u201cmake\u201d have correct library paths? (To be completely clear: The dynamically linked binary from \u201cmake\u201d looks for libraries in the locations where they are built, regardless of whether or not they\u2019re already
installed in the normal system library locations.)</span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black"> </span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black">Regards,</span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt;color:black">Patrick Farrell</span><o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-bookmark:_MailOriginalBody"><span style="font-size:11.0pt"> </span><o:p></o:p></span></p>
</div>
</body>
</html>