Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile on Linux failed #2234

Open
JoannaYRS opened this issue Feb 21, 2024 · 2 comments
Open

Compile on Linux failed #2234

JoannaYRS opened this issue Feb 21, 2024 · 2 comments

Comments

@JoannaYRS
Copy link

Hi everyone,

I'm trying to compile APSIM classic on Linux because our previous experiment was conducted on the classic version. Now we want to simulate intensively, so we wish to run it on HPC. The Linux system is based on CentOS 7.9.

I believe I have successfully installed mono-4.8.1.
I run ./BuildAll.sh but encountered failures in Dcaps, General, and APSIMUI builds. The Dcaps build error I encountered seems identical to issue #2180
I have attached the output of the compilation process as "compilation_output.txt" below.

My questions are:

  1. Can I skip the Dcaps build and still achieve a functional APSIM on Linux?
  2. I noticed that pSIMS was used in several previous research projects. However, it seems to work with APSIM 7.9, which is currently inaccessible. If compiling APSIM 7.10 is not feasible, is there any way I can obtain APSIM 7.9 and run pSIMS alternatively?

Any suggestions are greatly appreciated.

compilation_output.txt

@peter-devoil
Copy link
Collaborator

  1. Yes, you can skip dcaps if you're not using it,
  2. All of apsim is in version control, so if you want 7.9 you just have to find the tag for that version. Unfortunately, 7.9 predates our current git repository and would need to be extracted from the old subversion repo. I'm not sure that that's online, but may be in an archive somewhere.

In the bad old days, I did manage to build classic once on a centos system; these days it's much easier to build a (debian) singularity image and run that on centos. Names of .deb and .rpms are similar, but not exact. Your particular error relates to not finding the mono libraries - did you install the runtime or development (mono-devel) rpm?

I used psims and apsim7.10 a long time ago; I just looked to see that it used a containerised apsim. I suspect it's just a matter of changing a few script locations.

@zur003
Copy link
Contributor

zur003 commented Feb 22, 2024

Building APSIM Classic is always a bit of a challenge...

As the first line of your log file indicates: "Cant find mono/jit.h - expect trouble". The build script is not finding the mono include and lib files. As @peter-devoil indicates, the first thing is to make sure you have installed "mono-devel", and not just "mono". If that's not the problem, you will need to find out where the mono support has been installed. On Ubuntu, everything is installed under "/usr", with include files in /usr/include/mono-2 and libraries under /usr/lib. You may find that it has actually been installed under something like "/usr/local" (which is highly likely) or "/opt". If that is the case, you can set the environment variable MONO_PREFIX to the correct path (e.g., export MONO_PREFIX=/usr/local ) and try building again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants