<div dir="ltr"><div dir="ltr">Hi Michael,<div><br></div><div>The project I'm building creates a configuration script when cmake is executed based on the path where the build happens. So when the whole build directory is moved from ${worksrcpath} to a new location it fails to configure.</div><div><br></div><div>BTW I think I set the cmake.build_dir to ${destroot}/${prefix}/share/abc/abc${abc.version}/</div><div>in the very beginning and the build happened in </div><div>so ${destroot} was available in the very beginning of the port definition I guess.</div><div>
<p class="gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:14px;line-height:normal;font-family:Menlo;color:rgb(233,253,255);background-color:rgb(45,45,45)"><span class="gmail-s1" style="font-variant-ligatures:no-common-ligatures">/opt/local/var/macports/build/_Users_frankliuao_ports_science_abc/abc4.10.5/work/destroot/opt/local/share/abc/abc4.10.5/</span></p><br>I also need some workaround for this problem. LOL. Probably manually generate a new script...</div><div><br></div><div>Best,</div><div>Ao</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, May 2, 2019 at 3:17 PM Michael Dickens <<a href="mailto:michaelld@macports.org">michaelld@macports.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><u></u><div><div style="font-family:Arial">Just remember that "${destroot}" will not exist until the "destroot" phase unless it is created in the Portfile script. If you need a different build directory than that provided by the CMake PG, then you can in the Portfile create some other directory & my advice would be to place it in the top level "${worksrcpath}" directory -- which is where the "build" directory is placed. Not sure why one would need this, but maybe there's a use-case I'm not imagining. Good luck! - MLD<br></div><div style="font-family:Arial"><br></div><div style="font-family:Arial">On Thu, May 2, 2019, at 3:20 PM, Ao Liu wrote:<br></div><blockquote type="cite" id="gmail-m_-4614648765554958601qt"><div dir="ltr"><div style="font-family:Arial">Ummmmm. Good to know that. <br></div><div><br></div><div>I think what I would like to do can be achieved by smartly using ${destroot} to deploy a new build dir and move the files to where I would like. In this case the build happens in the work dir and will eventually end up in where I want it to be.<br></div><div><br></div><div>As I suggested in a recent ticket - it would be nice for the website to explain the ${destroot} variable in more details. Helps the developer to build powerful stuff. <br></div><div><br></div><div>Thanks for the replies folks!<br></div><div>Ao<br></div></div></blockquote><div style="font-family:Arial"><br></div></div></blockquote></div>