diff options
author | Chernov V. V <manbornofwoman@gmail.com> | 2014-02-01 01:16:36 +0700 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2014-02-01 00:40:34 -0600 |
commit | fdaa8fe0799d5f5b57bd8b124bb654522da3e355 (patch) | |
tree | 032bed3753b9fb4d2e473b32350225c5d8a73b7a /audio | |
parent | 15f29f5a0d7727f3b111d618294b0c1d6f0fd978 (diff) |
audio/easymp3gain: Added patches to fix compile against new FPC.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'audio')
-rw-r--r-- | audio/easymp3gain/easymp3gain.SlackBuild | 29 | ||||
-rw-r--r-- | audio/easymp3gain/environmentoptions.xml | 8 | ||||
-rw-r--r-- | audio/easymp3gain/patches/02_fix-new-fpc-compile.patch | 16 |
3 files changed, 51 insertions, 2 deletions
diff --git a/audio/easymp3gain/easymp3gain.SlackBuild b/audio/easymp3gain/easymp3gain.SlackBuild index 33e81c69146ba..4697bab5b2087 100644 --- a/audio/easymp3gain/easymp3gain.SlackBuild +++ b/audio/easymp3gain/easymp3gain.SlackBuild @@ -2,11 +2,29 @@ # Slackware build script for easymp3gain -# Written by Chernov V. V. manbornofwoman@gmail.com +# Copyright 2014 Chernov V. V. manbornofwoman@gmail.com +# 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. PRGNAM=easymp3gain VERSION=${VERSION:-0.5.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} LCL=${LCL:-gtk2} # otherwise "qt" @@ -49,6 +67,13 @@ patch -p1 < $CWD/patches/02_filechooser.patch # Don't force compiler architecture in LPI patch -p1 < $CWD/patches/03_fix_compiler_arch.patch +# Fix compilation with FPC +patch -p1 < $CWD/patches/02_fix-new-fpc-compile.patch + +# Fix compilation with Lazarus +cat $CWD/environmentoptions.xml > ./environmentoptions.xml +sed -i 's,lazbuild,lazbuild --primary-config-path=".",g' make.sh + if [ "$LCL" = "qt" ]; then OPT="-dUSE_QT_45" fi diff --git a/audio/easymp3gain/environmentoptions.xml b/audio/easymp3gain/environmentoptions.xml new file mode 100644 index 0000000000000..20e19abc14b8e --- /dev/null +++ b/audio/easymp3gain/environmentoptions.xml @@ -0,0 +1,8 @@ +<?xml version="1.0"?> +<CONFIG> + <EnvironmentOptions> + <LazarusDirectory Value="/usr/share/lazarus"/> + <CompilerFilename Value="/usr/bin/fpc"/> + </EnvironmentOptions> +</CONFIG> + diff --git a/audio/easymp3gain/patches/02_fix-new-fpc-compile.patch b/audio/easymp3gain/patches/02_fix-new-fpc-compile.patch new file mode 100644 index 0000000000000..3d2994f4dc811 --- /dev/null +++ b/audio/easymp3gain/patches/02_fix-new-fpc-compile.patch @@ -0,0 +1,16 @@ +Description: Fix compilation with more recent versions of FPC + This also improves code-quality and fixes warnings. +Forwarded: yes +Author: Matthias Klumpp <mak@debian.org> + +--- a/unitmain.pas ++++ b/unitmain.pas +@@ -169,7 +169,7 @@ + procedure AddFileAndDirectoryList(SL: TStringList; sublevels: Integer); + procedure UpdateFileCount; + procedure SortListView(Lv:TListView; Index:integer; Reverse: Boolean); +- function AddTask(ASongItem: TSongItem; AMediaGainAction: TMediaGainAction; AVolume: Double): Integer; ++ function AddTask(ASongItem: TSongItem; AMediaGainAction: TMediaGainAction; AVolume: Double): Integer; overload; + function FitsTaskType(ATask: TMediaGainTask; AMediaGainAction: TMediaGainAction; ASongItem: TSongItem): Boolean; + { private declarations } + public |