JiscMail Logo
Email discussion lists for the UK Education and Research communities

Help for SYNERBI-DEVEL Archives


SYNERBI-DEVEL Archives

SYNERBI-DEVEL Archives


SYNERBI-DEVEL@JISCMAIL.AC.UK


View:

Message:

[

First

|

Previous

|

Next

|

Last

]

By Topic:

[

First

|

Previous

|

Next

|

Last

]

By Author:

[

First

|

Previous

|

Next

|

Last

]

Font:

Proportional Font

LISTSERV Archives

LISTSERV Archives

SYNERBI-DEVEL Home

SYNERBI-DEVEL Home

SYNERBI-DEVEL  July 2018

SYNERBI-DEVEL July 2018

Options

Subscribe or Unsubscribe

Subscribe or Unsubscribe

Log In

Log In

Get Password

Get Password

Subject:

Re: FindSTIR

From:

"Gillman, Ashley (H&B, Herston - RBWH)" <[log in to unmask]>

Reply-To:

Gillman, Ashley (H&B, Herston - RBWH)

Date:

Tue, 3 Jul 2018 08:56:04 +1000

Content-Type:

text/plain

Parts/Attachments:

Parts/Attachments

text/plain (268 lines)

I am hesitant to send this because of the Nix stuff - I hope not to 
confuse you. Feel free to ignore.

This is how I solved in Nix:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/sirf/default.nix

NB: Ignore the mess here:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix#L23-L40
That's pulled from the standard Nix installer to find the downloaded 
source from GitHub.

The language is a little confusing, but essentially just calls `cmake 
$cmakeFlags` then `make` then `make install`. There are some default 
flags for CMake and Make, then everything in the .nix file augments on 
top of this.
You can see which cmake flags I add here:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix#L48-L57

The main change was the three lines here:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix#L42-L46
I copy the STIR source to the install location, and install from there. 
I later delete temporary build files here:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix#L64
I had to do this because as Kris mentioned, the registries are needed at 
runtime, so I had to install these - since Nix, like Conda (presumably? 
I haven't used it) removes the temporary files including source. 
Otherwise, I ended up with STIRConfig.cmake setting the source directory 
to a no longer existing temp dir. Perhaps an appropriate location to 
install to would be /usr/share/stir/src

NB: You may also have to install the scripts to the output /bin or 
/usr/bin like here:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/stir/default.nix#L59-L61

Finally, as Kris suggests, you can just point to the location of 
STIRConfig.cmake:
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/sirf/default.nix#L32
And the rest should go as planned.

I also had to manually move the $CMAKE_INSTALL_DIR/python to 
$CMAKE_INSTALL_DIR/lib/python3.x/site-packages
https://github.com/ashgillman/SIRF-NixBuild/blob/master/pkgs/sirf/default.nix#L35-L41

Hope this is helpful, Not sure how much translates to Conda package manager
Ash


-- 

Ashley Gillman, BEng (Hons), BIT
PhD Candidate
Australian e-Health Research Centre, CSIRO
School of Medicine, University of Queensland

E [log in to unmask]    M +61 404 085 204

Level 5 UQ Health Science Building 901/16
Royal Brisbane and Women's Hospital
Herston, QLD 4029
Australia

www.csiro.au | http://www.aehrc.com/biomedical_imaging/

PLEASE NOTE
The information contained in this email may be confidential or
privileged. Any unauthorised use or disclosure is prohibited. If you
have received this email in error, please delete it immediately and
notify the sender by return email. Thank you. To the extent permitted
by law, CSIRO does not represent, warrant and/or guarantee that the
integrity of this communication has been maintained or that the
communication is free of errors, virus, interception or interference.

On 03/07/18 07:36, Edoardo Pasca - UKRI STFC wrote:
> Thanks Ash,
> 
> I can wrap STIR in conda, without problems, it seems. The problem arises 
> when I want to build SIRF, which depends on STIR and because a 
> FindSTIR.cmake doesn’t exist one cannot issue find_package(STIR). And 
> cannot compile SIRF.
> 
> I’m not sure about saving the STIRConfig.cmake that comes out of the 
> compilation, as none of the build and install directory will ever exist 
> at runtime. Conda creates an environment for the build, hence creates a 
> whole directory structure that is going to delete after it has built.
> 
> I’m a bit puzzled (and sleepy now)
> 
> Goodnight
> 
> Edo
> 
> *From:*CCP-PETMR Developers list <[log in to unmask]> *On 
> Behalf Of *Ashley Gillman
> *Sent:* 02 July 2018 20:17
> *To:* [log in to unmask]
> *Subject:* Re: FindSTIR
> 
> Hi Edo.
> 
> I have previously wrapped STIR in the Nix package manager which uses 
> quite a novel directory structure. If you can wrap in Nix I'd imagine 
> you can wrap in Conda.
> 
> The main issue I ran in to (from memory) was STIR needed access to some 
> source cxx files at run time for configuration. If Conda has an issue 
> with this also, perhaps these files could be changed to installed header 
> files?
> 
> Ash
> 
> --
> 
> Sent from my mobile. Please excuse brevity and any spelling mistakes.
> 
> Ashley Gillman, BEng (Electical and Electronic) (Hons) - BIT
> 
> PhD Candidate
> 
> School of Medicine, University of Queensland | Australian e-Health 
> Research Centre, CSIRO
> 
> E [log in to unmask] <mailto:[log in to unmask]> M +61 404 085 204
> 
> Level 5 UQ Health Science Building
> 
> 901/16 Royal Brisbane and Women's Hospital
> 
> Herston, QLD 4029 Australia
> 
> www.csiro.au <http://www.csiro.au> | 
> http://www.aehrc.com/biomedical_imaging/
> 
> PLEASE NOTE
> 
> The information contained in this email may be confidential or 
> privileged. Any unauthorised use or disclosure is prohibited. If you 
> have received this email in error, please delete it immediately and 
> notify the sender by return email. Thank you.
> 
> To the extent permitted by law, CSIRO does not represent, warrant and/or 
> guarantee that the integrity of this communication has been maintained 
> or that the communication is free of errors, virus, interception or 
> interference.
> 
> On 3 Jul. 2018, at 12:26 am, "Thielemans, Kris" <[log in to unmask] 
> <mailto:[log in to unmask]>> wrote:
> 
>     It will/should only refer to installed STIR items. If not, it’s a bug.
> 
>     *From:*Edoardo Pasca - UKRI STFC [mailto:[log in to unmask]]
>     *Sent:* 02 July 2018 15:15
>     *To:* Thielemans, Kris; [log in to unmask]
>     <mailto:[log in to unmask]>
>     *Subject:* RE: FindSTIR
> 
>     I’m just unsure  whether the STIRConfig.cmake would contain
>     references to directories which don’t exist as they refer to the
>     build environment that conda creates and destroys.
> 
>     We’ll see
> 
>     Thanks
> 
>     Edo
> 
>     *From:*CCP-PETMR Developers list <[log in to unmask]
>     <mailto:[log in to unmask]>> *On Behalf Of *Thielemans, Kris
>     *Sent:* 02 July 2018 15:05
>     *To:* [log in to unmask]
>     <mailto:[log in to unmask]>
>     *Subject:* Re: FindSTIR
> 
>     Hi
> 
>     Thanks, but please, let’s not create a FindSTIR.cmake. It isn’t
>     necessary. It’s out-dated. It’ll be very hard to maintain. The
>     STIRConfig.cmake that we write sets variables, adds dependencies and
>     compilation flags automatically (relying on what CMake knows about
>     all this). If it doesn’t, it’s a bug. Getting dependencies etc
>     sorted out will be very very hard to do with a hand-crafted
>     FindSTIR.cmake.  don’t go there.
> 
>     Kris
> 
>     *From:*CCP-PETMR Developers list
>     [mailto:[log in to unmask]] *On Behalf Of *Nikos Efthimiou
>     *Sent:* 02 July 2018 15:01
>     *To:* [log in to unmask]
>     <mailto:[log in to unmask]>
>     *Subject:* Re: FindSTIR
> 
>     Hi Edo,
> 
>     If you still need a find.cmake I have this. I used to work great,
>     but the past 6 months after some cmake updates, it works "almost"
>     great. If you have STIR in a local path, you will be able to set the
>     root path but then you will have to set and include path, again :/ .
>     Strange staff.
> 
>     Good luck,
> 
>     Nikos
> 
>     On 02/07/18 13:49, Edoardo Pasca - UKRI STFC wrote:
> 
>         Hi there,
> 
>         I’m trying to build SIRF with conda.
> 
>         It’s not clear to me how SIRF finds STIR during the SuperBuild.
>         My guess is that being a target of the SuperBuild the
>         find_package command just finds it.
> 
>         If I’m now building with USE_SYSTEM_STIR, cmake is complaing
>         that there is no FindSTIR.cmake or STIR_config.cmake Do we have
>         any? I’m presuming that with conda a STIR_config.cmake will be
>         useless as the build happens in a specific environment which is
>         created and destroyed for the build.
> 
>         So, if I’m to create a FindSTIR.cmake the question is, what is
>         needed of STIR by SIRF at compile time?
> 
>         Cheers
> 
>         Edo
> 
>         --
>         Edoardo Pasca, PhD
>         Senior Visualisation Scientist, CCPi project manager and CCPPETMR
>         Scientific Computing Department, STFC Rutherford Appleton Laboratory
>         Fermi Avenue Chilton Didcot OX11 0QX
>         0044 (0)1235 44 5660, R89 F16
>         :wq
> 
>         ------------------------------------------------------------------------
> 
>         To unsubscribe from the CCP-PETMR-DEVEL list, click the
>         following link:
>         https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1
> 
> 
>     ------------------------------------------------------------------------
> 
>     To unsubscribe from the CCP-PETMR-DEVEL list, click the following link:
>     https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1
> 
>     ------------------------------------------------------------------------
> 
>     To unsubscribe from the CCP-PETMR-DEVEL list, click the following link:
>     https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1
> 
>     ------------------------------------------------------------------------
> 
>     To unsubscribe from the CCP-PETMR-DEVEL list, click the following link:
>     https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1
> 
> ------------------------------------------------------------------------
> 
> To unsubscribe from the CCP-PETMR-DEVEL list, click the following link:
> https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1
> 

########################################################################

To unsubscribe from the CCP-PETMR-DEVEL list, click the following link:
https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP-PETMR-DEVEL&A=1

Top of Message | Previous Page | Permalink

JiscMail Tools


RSS Feeds and Sharing


Advanced Options


Archives

March 2024
February 2024
January 2024
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
November 2015


JiscMail is a Jisc service.

View our service policies at https://www.jiscmail.ac.uk/policyandsecurity/ and Jisc's privacy policy at https://www.jisc.ac.uk/website/privacy-notice

For help and support help@jisc.ac.uk

Secured by F-Secure Anti-Virus CataList Email List Search Powered by the LISTSERV Email List Manager