spex-xray / spex-help

These are the help and manual pages for the SPEX X-ray spectral fitting package.
1 stars 1 forks source link

spexdist.sh ulimit setting #20

Closed jmao2014 closed 1 year ago

jmao2014 commented 2 years ago

Hi Jelle,

My student noticed an issue when installing SPEX on macOS (via admin). When sourcing spexdish.sh, the following error occurs:

./spexdist.sh: line 21: ulimit: stack size: cannot modify limit: Operation not permitted

The root of the issue is the last line in spexdist.sh: "ulimit -s 65532". A smaller value is acceptable (32767 for my student). This value can be obtained via the command "ulimit -a", which returns a stack size of 32767 kbytes.

Cheers,

Junjie

jdeplaa commented 2 years ago

Hi Junjie,

On Intel Macs the number of 65532 appeared to be OK. Is this a newer M1 mac? Or the Monterey OS? If yes, I will change the number for that case in the CMake files.

Cheers,

Jelle.

jmao2014 commented 2 years ago

Hi Jelle,

I will ask my student tomorrow to provide details then. His macOS is Big Sur (I don't recall the detailed version number). It should be the latest version of SPEX that he was trying to install.

Mine is currently Monterey (12.2.1, but old CPU chips) and it works fine with "ulimits -s 65532".

Cheers,

Junjie

TNokki commented 2 years ago

Dear Jelle,

I am a student of Dr. Mao. I am installing SPEX(ver 3.06.01). My Mac is M1 Mac, and OS is Big Sur (ver 11.5.2).

Regards,

Taishu

jdeplaa commented 2 years ago

Dear Taishu,

Thank you very much for this information! I will try to solve this issue for the next release of SPEX.

Cheers,

Jelle.

jdeplaa commented 1 year ago

This problem has been fixed in the latest SPEX releases. For Mac, the command ulimit -s hard appears to set the stacksize to the limit of the OS.