cedadev / extra-sci-packages

A set of RPM packages to supplement Jaspy to provide an scientific analysis environment for CentOS7
1 stars 0 forks source link

Add SAGA-gis #26

Open alaniwi opened 5 years ago

alaniwi commented 5 years ago

http://www.saga-gis.org/

alaniwi commented 5 years ago

Build in test environment in progress at time of writing. After yum install wxGTK3-devel unixODBC-devel, the following seems to be working to make it pick up the correct version of wxGTK3:

Obtain source:

$ wget https://downloads.sourceforge.net/project/saga-gis/SAGA%20-%207/SAGA%20-%207.0.0/saga-7.0.0.tar.gz
$ tar xvfz saga-7.0.0.tar.gz
$ cd saga-7.0.0/

put a wx-config symbolic link early in the PATH pointing to the wx-config-3.0

$ mkdir wx-tmp
$ ln -s /usr/bin/wx-config-3.0 wx-tmp/wx-config
$ PATH=`pwd`/wx-tmp:$PATH
$ wx-config --list  # make sure that it says that 3.0 is being used by default

then do the build

$ autoreconf -fi
$ ./configure --prefix=$HOME/saga
$ make
$ make install
alaniwi commented 5 years ago

Requires #187

alaniwi commented 5 years ago

Build successful. Tested the gui as compiled above, on a machine without the above devel libs, and it seems okay (tested with some shapefile from under ESMValTool). This is a manual build and still need to build an RPM.

agstephens commented 5 years ago

This is a complex GUI. Not available on conda-forge/anaconda-default.

alaniwi commented 1 year ago

Will move ticket to extra-sci-packages repo. I looked to see whether it could be installed under /apps/jasmin/supported, but it seems likely that the above mentioned extra RPMs that need to be installed are required at run-time, not just compile time, so these would need to be added as RPM dependencies.

I'm tempted to close as WONTFIX given the age. Low priority.

alaniwi commented 1 year ago

On sci2-test, installing the RPM dependencies adds total ~50MB.

alaniwi commented 1 year ago

Build has changed. No sign of a configure or configure.in file. New instructions at https://sourceforge.net/p/saga-gis/wiki/Compiling%20SAGA%20on%20Linux/ These fail because the cmake version is too old.

This is getting too complicated, and given that I have not seen further requests for this software, now going to close as WONTFIX.

alaniwi commented 5 months ago

Reopening, as we have had another request. Helpscout 68144. Will try on Rocky 9.

alaniwi commented 5 months ago

No longer complaining about cmake version, but compilation fails at 11% with:

[ 11%] Building CXX object src/saga_core/saga_gui/CMakeFiles/saga_gui.dir/res_commands.cpp.o
/home/builder/saga/saga-9.3.2/saga-gis/src/saga_core/saga_gui/res_commands.cpp: In function ‘wxToolBarBase* CMD_ToolBar_Create(int)’:
/home/builder/saga/saga-9.3.2/saga-gis/src/saga_core/saga_gui/res_commands.cpp:554:43: error: ‘class CSAGA_Frame’ has no member named ‘FromDIP’
  554 |                 int Size = g_pSAGA_Frame->FromDIP(g_pTools->Get_Parameter("LOOK_TB_SIZE")->asInt());
      |                                           ^~~~~~~
gmake[2]: *** [src/saga_core/saga_gui/CMakeFiles/saga_gui.dir/build.make:496: src/saga_core/saga_gui/CMakeFiles/saga_gui.dir/res_commands.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:2081: src/saga_core/saga_gui/CMakeFiles/saga_gui.dir/all] Error 2
gmake: *** [Makefile:136: all] Error 2

According to https://sourceforge.net/p/saga-gis/discussion/790705/thread/8da5c505ac/, "For newer SAGA versions you require at least wxGTK 3.1". The yum install wxGTK3-devel unixODBC-devel prior to the build gave wxGTK3 3.0.5.

alaniwi commented 5 months ago

RPM wxGTK was already installed - which is 3.2.2. Undoing the previous yum install and retrying the build, it gets past where it hit the error before, which is good to know, but the undo will also have removed unixODBC-devel, and in fact gdal-devel is also a documented dependency which is missing (according to instructions) -- so although the build is on 40% and still going, I will stop it and try again with these dependencies installed.

alaniwi commented 5 months ago

Made an RPM. Note that build time is about 20 minutes.