diff options
author | Ben de Groot <yngwin@gentoo.org> | 2015-08-17 23:02:33 +0800 |
---|---|---|
committer | Ben de Groot <yngwin@gentoo.org> | 2015-08-17 23:02:33 +0800 |
commit | 2c20284c752bfa2384c4dcd1e262adb51e7f3d98 (patch) | |
tree | 53fbe0e4a57ff72fe8b1ea227589db9794086780 /media-sound | |
parent | media-sound/ardour: update revision naming patch (diff) | |
download | gentoo-2c20284c752bfa2384c4dcd1e262adb51e7f3d98.tar.gz gentoo-2c20284c752bfa2384c4dcd1e262adb51e7f3d98.tar.bz2 gentoo-2c20284c752bfa2384c4dcd1e262adb51e7f3d98.zip |
media-sound/ardour: ebuild improvements
- Use git-r3.eclass instead of older git-2.
- Use more robust double bracket style for tests.
- Put dependencies in alphabetic order
- Remove unneeded src_unpack
- Break up long sed lines
- Use usex where applicable
- Language usage correction in elog message
Package-Manager: portage-2.2.20.1
Diffstat (limited to 'media-sound')
-rw-r--r-- | media-sound/ardour/ardour-4.2-r1.ebuild | 89 |
1 files changed, 39 insertions, 50 deletions
diff --git a/media-sound/ardour/ardour-4.2-r1.ebuild b/media-sound/ardour/ardour-4.2-r1.ebuild index c4f8bc41286f..c8aad5cdb632 100644 --- a/media-sound/ardour/ardour-4.2-r1.ebuild +++ b/media-sound/ardour/ardour-4.2-r1.ebuild @@ -3,19 +3,16 @@ # $Id$ EAPI=5 - PYTHON_COMPAT=( python2_7 ) PYTHON_REQ_USE='threads(+)' - inherit eutils toolchain-funcs flag-o-matic python-any-r1 waf-utils DESCRIPTION="Digital Audio Workstation" HOMEPAGE="http://ardour.org/" -if [ ${PV} = 9999 ]; then - KEYWORDS="" +if [[ ${PV} == *9999* ]]; then EGIT_REPO_URI="http://git.ardour.org/ardour/ardour.git" - inherit git-2 + inherit git-r3 else KEYWORDS="~amd64 ~x86" SRC_URI="https://github.com/Ardour/ardour/archive/${PV}.tar.gz -> ${P}.tar.gz" @@ -25,35 +22,36 @@ LICENSE="GPL-2" SLOT="4" IUSE="altivec doc jack lv2 cpu_flags_x86_sse" -RDEPEND="media-libs/aubio - media-libs/liblo - sci-libs/fftw:3.0 - media-libs/freetype:2 - >=dev-libs/glib-2.10.1:2 +RDEPEND=" >=dev-cpp/glibmm-2.32.0 - >=x11-libs/gtk+-2.8.1:2 - >=dev-libs/libxml2-2.6:2 - >=media-libs/libsndfile-1.0.18 - >=media-libs/libsamplerate-0.1 - >=media-libs/rubberband-1.6.0 - >=media-libs/libsoundtouch-1.6.0 - media-libs/flac - media-libs/raptor:2 - >=media-libs/liblrdf-0.4.0-r20 - >=gnome-base/libgnomecanvas-2 - media-libs/vamp-plugin-sdk - dev-libs/libxslt - dev-libs/libsigc++:2 >=dev-cpp/gtkmm-2.16:2.4 >=dev-cpp/libgnomecanvasmm-2.26:2.6 + dev-libs/boost:= + >=dev-libs/glib-2.10.1:2 + dev-libs/libsigc++:2 + >=dev-libs/libxml2-2.6:2 + dev-libs/libxslt + >=gnome-base/libgnomecanvas-2 media-libs/alsa-lib - x11-libs/pango - x11-libs/cairo + media-libs/aubio + media-libs/flac + media-libs/freetype:2 media-libs/libart_lgpl - virtual/libusb:0 - dev-libs/boost:= + media-libs/liblo + >=media-libs/liblrdf-0.4.0-r20 + >=media-libs/libsamplerate-0.1 + >=media-libs/libsndfile-1.0.18 + >=media-libs/libsoundtouch-1.6.0 + media-libs/raptor:2 + >=media-libs/rubberband-1.6.0 >=media-libs/taglib-1.7 + media-libs/vamp-plugin-sdk net-misc/curl + sci-libs/fftw:3.0 + virtual/libusb:0 + x11-libs/cairo + >=x11-libs/gtk+-2.8.1:2 + x11-libs/pango jack? ( >=media-sound/jack-audio-connection-kit-0.120 ) lv2? ( >=media-libs/slv2-0.6.1 @@ -63,35 +61,26 @@ RDEPEND="media-libs/aubio >=media-libs/suil-0.6.10 >=media-libs/lv2-1.4.0 )" - DEPEND="${RDEPEND} ${PYTHON_DEPS} - virtual/pkgconfig >=media-sound/jack-audio-connection-kit-0.120 sys-devel/gettext + virtual/pkgconfig doc? ( app-doc/doxygen[dot] )" - if ! [ ${PV} = 9999 ]; then - DEPEND="${DEPEND}" - fi - -src_unpack() { - if [ ${PV} = 9999 ]; then - git-2_src_unpack - else - unpack ${A} - fi -} src_prepare(){ - if ! [ ${PV} = 9999 ]; then + if ! [[ ${PV} == *9999* ]]; then epatch "${FILESDIR}"/${PN}-4.2-revision-naming.patch touch "${S}/libs/ardour/revision.cc" fi $(use lv2 || epatch "${FILESDIR}"/${PN}-4.0-lv2.patch) epatch "${FILESDIR}"/${PN}-3.5.403-sse.patch - sed -e 's/'FLAGS\'\,\ compiler_flags'/'FLAGS\'\,\ program_flags'/g' -i "${S}"/wscript - sed -e 's/'compiler_flags.append\ \(\'-DPROGRAM_'/'program_flags.append\ \(\'-DPROGRAM_'/g' -i "${S}"/wscript - sed -e '/compiler_flags\ \=\ \[\]/a \ \ \ \ program_flags\ \=\ \[\]' -i "${S}"/wscript + sed -e 's/'FLAGS\'\,\ compiler_flags'/'FLAGS\'\,\ program_flags'/g' \ + -i "${S}"/wscript + sed -e 's/'compiler_flags.append\ \(\'-DPROGRAM_'/'program_flags.append\ \(\'-DPROGRAM_'/g' \ + -i "${S}"/wscript + sed -e '/compiler_flags\ \=\ \[\]/a \ \ \ \ program_flags\ \=\ \[\]' \ + -i "${S}"/wscript append-flags "-lboost_system" } @@ -99,11 +88,11 @@ src_configure() { if use cpu_flags_x86_sse; then MARCH=$(get-flag march) for ARCHWOSSE in i686 i486; do - if [[ ${MARCH} = ${ARCHWOSSE} ]]; then + if [[ ${MARCH} == ${ARCHWOSSE} ]]; then for SSEOPT in -msse -msse2 -msse3 -mssse3 -msse4 -msse4.1 -msse4.2; do is-flag ${SSEOPT} && SSEON="yes" done - if [ -z ${SSEON} ]; then + if [[ -z ${SSEON} ]]; then append-flags -msse elog "You enabled sse but use an march that does not support sse!" elog "We add -msse to the cflags now, but please consider switching your march in make.conf!" @@ -119,10 +108,10 @@ src_configure() { --configdir=/etc \ --optimize \ --nls \ - $(use jack && echo "--with-backends=alsa,jack" || echo "--with-backends=alsa --libjack=weak") \ - $(use lv2 && echo "--lv2" || echo "--no-lv2") \ + $(usex jack "--with-backends=alsa,jack" "--with-backends=alsa --libjack=weak") \ + $(usex lv2 "--lv2" "--no-lv2") \ $({ use altivec || use cpu_flags_x86_sse; } && echo "--fpu-optimization" || echo "--no-fpu-optimization") \ - $(use doc && echo "--docs") + $(usex doc "--docs" '') } src_install() { @@ -135,5 +124,5 @@ src_install() { pkg_postinst() { elog "If you are using Ardour and want to keep its development alive" - elog "then please consider to do a donation upstream at ardour.org. Thanks!" + elog "then please consider to make a donation upstream at ${HOMEPAGE}" } |