1
0

media-plugins/odin2: New package

Rejoice, for Odin 2 is finally available on Gentoo!

Package-Manager: Portage-3.0.8, Repoman-3.0.2
Signed-off-by: Ryan Fox <flewkey@2a03.party>
This commit is contained in:
Ryan Fox 2020-11-07 02:18:46 +00:00
parent 5b9048cda6
commit 806ef1d540
Signed by: flewkey
GPG Key ID: 94F56ADFD848851E
3 changed files with 86 additions and 0 deletions

View File

@ -0,0 +1,4 @@
DIST JUCE-c51d03f11be20cb35eb28e8016e9a81827b50339.tar.gz 13970970 BLAKE2B d2234fd239f3cbf662c5532e9ff131f65850b33fe35c7737d3a232c3ace23b59247237dfa04805d2c9ac4315463094c58c471e8636cbc23546be8d0542dccab9 SHA512 a2f9a13b86d580dd9de8c59fea84c5dfe4a9c4f22c8cf73446a1e81b26ded1038935ffd4a83acc41e17d7c5ef1a84f6854d57f4b4ca218c82780ba1e6d013a0c
DIST odin2-2.2.4.tar.gz 68244104 BLAKE2B f07e082d8e87780522bdf86530e48ff5011ae1de076d2c1acf75e03b689fb2feb0830c33029f0ab4cc783dcda521b1fd1f0542e6226af50f43883f762d2ffe36 SHA512 3588bda5bca7c264ffda2afc6a210342ff9d9634a3eabbb36519d812321927d935d1e5a43b2a1926669532d89e0f1bfd6eed73b46dc18b5c8c03569ada0b5ccc
EBUILD odin2-2.2.4.ebuild 2077 BLAKE2B ea2329263a36d7ec00fb4202dabdcb3fbfd14a40c03ca8d9aed47f52437202a58c0731c054eada0ecab8352a4ecbe6c1877a1d83e6dff7a7e75dfc5e57817192 SHA512 165b095959d668ef75ac7d24c4ba75aa0baee675da5a1d40fdc26484afa1d55555cf15a45d56479f4513bec0c5d7e3c400e2a5144b2d9dfddcb947d05c0390c4
MISC metadata.xml 303 BLAKE2B 9f1e709d9a40b50050de9a429335e65ac94ccd34b318e5b8e50704a0dbc39e5aeee6e1e7e0f0f09b2bcc565c28d69a102a2e1721a1a622581f73c85055fa9a25 SHA512 a4d6d10af92c40f32766d6952cd0a2418039136b1bbc7ffa50a295aa4435b033574abe2df93d496ed1b99cfe2859c99fe7dab8b1afa3c29efc7270619c0a06f5

View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>flewkey@2a03.party</email>
<name>Ryan Fox</name>
</maintainer>
<use>
<flag name="lv2">Enable building of LV2 plugin</flag>
</use>
</pkgmetadata>

View File

@ -0,0 +1,71 @@
# Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
JUCE_VERSION="6.0.1"
PROJUCER_VERSION="6.0.4"
inherit projucer
ODIN_REF="972de0444433ba705429ae50cae3013bd1865003" # 2.2.4
JUCE_REF="c51d03f11be20cb35eb28e8016e9a81827b50339"
SRC_URI="
https://github.com/TheWaveWarden/odin2/archive/${ODIN_REF}.tar.gz -> ${P}.tar.gz
https://github.com/lv2-porting-project/JUCE/archive/${JUCE_REF}.tar.gz -> JUCE-${JUCE_REF}.tar.gz
"
KEYWORDS="~amd64"
DESCRIPTION="A 24-voice polyphonic synthesizer"
HOMEPAGE="https://www.thewavewarden.com/odin2"
LICENSE="GPL-3"
SLOT="0"
IUSE="+lv2"
DEPEND="
media-libs/alsa-lib
media-libs/lv2
media-libs/mesa
net-libs/webkit-gtk
net-misc/curl
x11-libs/libX11
"
RDEPEND="${DEPEND}"
BDEPEND="
~dev-libs/juce-6.0.1
|| ( ~dev-libs/juce-6.0.4[projucer] ~dev-libs/juce-6.0.4[extras] )"
src_unpack() {
default
mv "${WORKDIR}/${PN}-${ODIN_REF}" "${WORKDIR}/${P}"
}
src_prepare() {
if use lv2 ; then
JUCE_MODULES_PATH="${WORKDIR}/JUCE-${JUCE_REF}/modules"
projucer_resave Odin.jucer
# LV2 configuration commands copypasta'd from the Odin 2 repo
export LINE_NUMBER="$(grep -n 'BEGIN_USER_CODE_SECTION' JuceLibraryCode/AppConfig.h | cut -d: -f1)"
head -n $LINE_NUMBER JuceLibraryCode/AppConfig.h > app_config.tmp
echo -e "#define JucePlugin_Build_LV2 1" >> app_config.tmp
echo -e "#define JucePlugin_LV2URI \"https://www.thewavewarden.com/odin2\"" >> app_config.tmp
echo -e "#define JucePlugin_MaxNumOutputChannels 2" >> app_config.tmp
tail -n +$((LINE_NUMBER+1)) JuceLibraryCode/AppConfig.h >> app_config.tmp
mv app_config.tmp JuceLibraryCode/AppConfig.h
echo -e "include ../../LV2.mak" >> "${S}/Builds/LinuxMakefile/Makefile"
fi
S="${S}/Builds/LinuxMakefile"
default
}
src_install() {
dodir /usr/$(get_libdir)/vst3
cp -r "${S}/build/Odin2.vst3" "${D}/usr/$(get_libdir)/vst3"
dodir /opt/odin2
cp -r "${WORKDIR}/${P}/Soundbanks" "${D}/opt/odin2"
if use lv2 ; then
dodir /usr/$(get_libdir)/lv2
cp -r "${S}/build/Odin2_.lv2" "${D}/usr/$(get_libdir)/lv2"
fi
}