Arch Linux Binary Installer for Salome

Mesh generators, CAD programs, and other tools
Post Reply
CrocoDuck
Posts: 79
Joined: 12 May 2016, 13:15
Antispam: Yes

Arch Linux Binary Installer for Salome

Post by CrocoDuck »

Hey there!

Salome has pretty cool packages on the AUR. However, they are very time consuming to build and there are few quirks (the AUR version crashes on my machine when trying to generate second order meshes). 64 bit universal Linux binaries are released by Salome people, however the install procedure is not as simple as they describe on Arch. I wrote a simple script based on this post (mzenker is that you?). Just download the *.run file and place it in a folder with the script. It should be able to install Salome on your home directory:

Code: Select all

#!/bin/bash

# Helper Script to install Salome on Arch Linux. Requires python2.7 (provided by the package python2).

FILE=$(ls *.run | grep Salome)

# Ensure that the file has been downloaded:
if [ -f $FILE ]; then
    echo "Unversal Binaries Installer in place"
else
    echo "ERROR: Unversal Binaries Installer not in place. Are you sure there is only a *.run file?"
    exit 1
fi

# Ensure Permissions:
chmod +x $FILE

# Extrapolate Version:
RAWVER=$(echo $FILE | grep -o -P '(?<=Salome-V).*(?=-public.run)') # X_Y_Z
COLVER=${RAWVER//_/} # XYZ
VER=${RAWVER//_/.} # X.Y.Z

# Set Environment Variables:
export SALOMEDIR="/home/${USER}/Salome-${COLVER}/Salome-V${RAWVER}-public"
export ROOT_SALOME="/home/${USER}/Salome-${COLVER}/Salome-V${RAWVER}-public"
export DEFAULTAPPLIDIR="/home/${USER}/Salome-${COLVER}/appli_V${RAWVER}"

# Run installer:
echo "Installing in /home/${USER}..."
./"${FILE}" -v -D -t /home/"${USER}"/Salome-"${COLVER}"

# Create a launcher:
echo "Puttin in place the Desktop Launcher: "

cat <<EOF >/home/"${USER}"/Salome-"${COLVER}"/Salome-"${COLVER}".desktop
[Desktop Entry]
Encoding=UTF-8
Type=Application
Name=salome-${COLVER}
Comment='an open-source software that provides a generic platform for Pre- and Post-Processing for numerical simulation'
Exec=python2.7 /home/${USER}/Salome-${COLVER}/appli_V${RAWVER}/salome
Icon=/home/${USER}/Salome-${COLVER}/Salome-V${RAWVER}-public/icon.png
Terminal=false
StartupNotify=false
Categories=Education;Science;Math;;
EOF

#TIP:
# If the launcher does not work, open /home/$USER/Salome-$COLVER/appli_V$RAWVER/runAppli, find the line export export APPLI=`${APPLI_HOME}/getAppliPath.py`, comment it and write below: export APPLI="/Salome-$COLVER/appli_V$RAWVER". Then, execute runApply

echo "ALL FINISHED!"
You will find a Launcher in the same folder. I will probably try to integrate this in a PKGBUILD. For the time being I post it here as I bet it could be useful to other Linux users as well.

Hope it helps!
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Arch Linux Binary Installer for Salome

Post by mzenker »

CrocoDuck wrote: (mzenker is that you?).
No, my name is not Matthias Schmidt... ;)
Anyway, I have to work under Windoze here in the company (Linux Mint at home), so I don't know anything on ArchLinux.

Matthias
hauptmech
Posts: 8
Joined: 06 Nov 2016, 07:17
Antispam: Yes

Re: Arch Linux Binary Installer for Salome

Post by hauptmech »

Thanks for posting this CrocoDuck!
CrocoDuck
Posts: 79
Joined: 12 May 2016, 13:15
Antispam: Yes

Re: Arch Linux Binary Installer for Salome

Post by CrocoDuck »

Hi!

The script above has been broken for a long time. I finally fixed it, and I decided I will try to maintain it. It is now on GitHub:

https://github.com/CrocoDuckoDucks/salo ... -installer

By the way, this page was essential to make it work again:

https://www.salome-platform.org/forum/forum_9/472644021
Post Reply