Skip to content

Commit

Permalink
Add radium
Browse files Browse the repository at this point in the history
  • Loading branch information
noisecode3 committed Nov 11, 2023
1 parent 80f3b42 commit ad47436
Show file tree
Hide file tree
Showing 7 changed files with 194 additions and 0 deletions.
7 changes: 7 additions & 0 deletions builds/radium/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
The development of Radium started in 1999 based on ideas developed
1997-1999 while extending the Octamed tracker on the Amiga. The first
public version of Radium was released in 2000. Since then, Radium has
been ported to Linux, Windows, and Mac OS X. Today, Radium is probably
the worlds largest and most advanced tracker-like music editor.

This build is dirty and experimental, not finnished.
11 changes: 11 additions & 0 deletions builds/radium/build_linux_common.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- build_linux_common.sh.orig 2023-03-10 14:18:55.074248103 +0100
+++ build_linux_common.sh 2023-03-10 14:20:54.617578515 +0100
@@ -216,7 +216,7 @@
if [[ $RADIUM_USE_CLANG == 1 ]] && [ -f "$CLANG_PREFIX/lib/libbfd.a" ]; then
export RADIUM_BFD_LDFLAGS="$CLANG_PREFIX/lib/libbfd.a"
else
- export RADIUM_BFD_LDFLAGS="-Wl,-Bstatic -lbfd -Wl,-Bdynamic"
+ export RADIUM_BFD_LDFLAGS="-Wl,-Bstatic -lbfd -Wl,-Bdynamic -lzstd -lsframe"
fi
fi

129 changes: 129 additions & 0 deletions builds/radium/radium.SlackBuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,129 @@
#!/bin/bash

# Slackware build script for radium

# Copyright 2023 Martin Bångens Sweden
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

cd $(dirname $0) ; CWD=$(pwd)

PRGNAM=radium
VERSION=${VERSION:-git}
BUILD=${BUILD:-1}
TAG=${TAG:-_SSb}
PKGTYPE=${PKGTYPE:-tgz}

if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
fi

TMP=${TMP:-/tmp/SSb}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}

if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
mkdir -p $TMP
cd $TMP
rm -rf radium
git clone --depth 1 https://github.com/kmatheussen/radium
cd radium
#VERSION=$(git describe --tags)
#VERSION=$(echo $VERSION | tr '-' . )
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
fi

set -e

rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT $PKG
cd $TMP
rm -rf radium
git clone --depth 1 https://github.com/kmatheussen/radium
cd radium
git submodule update --init --recursive
# we could nuke sequencer_osx, but there cant be a mac symlink with the chmod we are using
rm bin/python-midi/src/sequencer_osx/CoreMIDI.framework
#VERSION=$(git describe --tags)
#VERSION=$(echo $VERSION | tr '-' . )
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
-o -perm 511 \) -exec chmod 755 {} \; -o \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
chmod 644 COPYING

patch -p0 < $CWD/build_linux_common.patch

# This tweak edits new file template and demo songs to be compatible with chorus plugin from calf-ladspa package
# !! NOTE TO LMMS USERS !!
# !! Comment next line out if you have LMMS installed as it already comes with their own version of Calf plugins !!
#for file in bin/sounds/*.rad; do sed -i -e 's/Calf MultiChorus LADSPA/Calf Multi Chorus LADSPA/g' "$file"; done
# See comment on calf-ladspa AUR page then on how to let Radium load Calf from LMMS package

# temp fix for soundfileexport
patch -p0 < $CWD/sndfilexprt.patch
sed -i "s|#sed -i 's/#define|sed -i 's/#define|" bin/packages/build.sh
export INCLUDE_FAUSTDEV_BUT_NOT_LLVM="jadda" BUILDTYPE=RELEASE \
RADIUM_USE_CLANG=0 RADIUM_BUILD_LIBXCB=1 RADIUM_QT_VERSION=5 RADIUM_VST2SDK_PATH=/usr/include/vst2sdk
export QT_QPA_PLATFORM_PLUGIN_PATH=`$(./find_moc_and_uic_paths.sh qmake) -query QT_INSTALL_PLUGINS`

make packages
./build_linux.sh -j`nproc`
./install.sh "$PKG/opt"

# Create startup script according to bin/packages/README
mkdir -p "$PKG/usr/bin"
echo '#!/usr/bin/env bash' > "$PKG/usr/bin/radium"
echo QT_QPA_PLATFORM_PLUGIN_PATH="$($(RADIUM_QT_VERSION=5 ./find_moc_and_uic_paths.sh qmake) -query QT_INSTALL_PLUGINS)" \
/opt/radium/radium '"$@"' >> "$PKG/usr/bin/radium"
chmod +x "$PKG/usr/bin/radium"

ln -s /usr/lib64/ladspa $PKG/opt/radium/ladspa
chmod +x $PKG/opt/radium/packages/libpd-master/externals/freeverb~/freeverb~.pd_linux
# Icons, .desktop and mimetype files
mkdir -p "$PKG/usr/share/icons/hicolor/"{16x16,32x32,128x128,256x256}"/apps" \
"$PKG/usr/share/applications" \
"$PKG/usr/share/mime/packages"
ln -s "/opt/radium/radium_16x16x8.png" "$PKG/usr/share/icons/hicolor/16x16/apps/radium.png"
ln -s "/opt/radium/radium_32x32x24.png" "$PKG/usr/share/icons/hicolor/32x32/apps/radium.png"
ln -s "/opt/radium/radium_128x128x32.png" "$PKG/usr/share/icons/hicolor/128x128/apps/radium.png"
ln -s "/opt/radium/radium_256x256x32.png" "$PKG/usr/share/icons/hicolor/256x256/apps/radium.png"
ln -s "/opt/radium/radium.desktop" "$PKG/usr/share/applications/radium.desktop"
ln -s "/opt/radium/radium-mimetype.xml" "$PKG/usr/share/mime/packages/radium.xml"

find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a \
COPYING \
$PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc

cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
10 changes: 10 additions & 0 deletions builds/radium/radium.info
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
PRGNAM="radium"
VERSION="git"
HOMEPAGE="https://users.notam02.no/~kjetism/radium/"
DOWNLOAD="https://github.com/kmatheussen/radium"
MD5SUM=""
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="vst2sdk ladspa_sdk"
MAINTAINER="Martin Bångens"
EMAIL="marbangens@gmail.com"
10 changes: 10 additions & 0 deletions builds/radium/radium.install
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
### should create a symlink to ladspa in /opt/radium
### to get rid off the errormessage

post_install() {
}

pre_remove() {
rm /opt/radium/ladspa
}

19 changes: 19 additions & 0 deletions builds/radium/slack-desc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description.
# Line up the first '|' above the ':' following the base package name, and
# the '|' on the right side marks the last column you can put a character in.
# You must make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':' except on otherwise blank lines.

|-----handy-ruler------------------------------------------------------|
radium: radium (A graphical music editor. A next generation tracker)
radium:
radium: Radium is a music editor with a new type of interface. Compared to
radium: the normal sequencer interface editing is quicker and more musical
radium: data fits on the screen. Compared to trackers, note positions and
radium: effects are edited graphically, which should be quicker, provide more
radium: vertical space and give a better musically overview.
radium: (Everything can also be edited by text, like in a normal tracker)
radium: Radium can also be used as a normal multitracker to mix and record
radium: audio
radium:
8 changes: 8 additions & 0 deletions builds/radium/sndfilexprt.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
--- bin/run_radium_linux.sh.orig 2023-04-23 01:12:04.122074816 +0200
+++ bin/run_radium_linux.sh 2023-04-23 01:12:17.465407822 +0200
@@ -26,4 +26,4 @@
unset QT_QPA_PLATFORM
unset QT_PLUGIN_PATH

-QT_QPA_PLATFORM="xcb" LD_LIBRARY_PATH="$LD_LIBRARY_PATH" "$THIS_DIR"/radium_linux.bin "$@"
+LC_ALL=C QT_QPA_PLATFORM="xcb" LD_LIBRARY_PATH="$LD_LIBRARY_PATH" "$THIS_DIR"/radium_linux.bin "$@"

0 comments on commit ad47436

Please sign in to comment.