-
Notifications
You must be signed in to change notification settings - Fork 26
Installing soundKonverter
There are two possible ways to install soundKonverter. The first one is to compile it from its sources, the second one is to install a precompiled package suitable for your distribution. Usually installing a precompiled package is easier than compiling it on your own. However, these days it seems no package maintainers are releasing packages for current distribution releases, and there are no new soundKonverter source releases as well, so the best option would be just to clone git repository using command (ensure git package is installed first):
git clone https://github.com/dfaust/soundkonverter.git
First you should make sure that all dependencies are installed. Have a look at the .spec file to see what's required.
For Ubuntu-like distributions you can install these:
sudo apt-get install libcdparanoia-dev libkf5kdelibs4support-dev libkf5kio-dev libkf5xmlgui-dev libtag1-dev build-essential cmake extra-cmake-modules gettext libphonon4qt5-dev libkf5cddb-dev
All dependencies - and whether they are fulfilled - should be shown when running cmake.
Then open a console and change to the soundKonverter root source directory (not src sub-directory) and execute the following commands:
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` ../src
make
sudo make install
In order to compile soundKonverter with debug information, the commands will look like this:
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=`kf5-config --prefix` -DCMAKE_BUILD_TYPE=debugfull ../src
make
sudo make install
Note: `kf5-config --prefix` should return the installation path of KDE. Or you can just define a path by yourself, "/usr" will be fine for most systems.
In case you are using a multi-core CPU, you should append the -j option followed by the number of threads to use to the make command. E.g.: make -j4
to use 4 threads.
For uninstalling soundKonverter, open a console and change to the soundKonverter build directory. (If you followed the instructions above it's the directory named "build" in the soundKonverter source directory.) Then execute one of the following commands:
sudo make uninstall
or
sudo xargs rm < install_manifest.txt
In order to remove the soundKonverter configuration and kde integration, run the following commands:
rm ~/.config/soundkonverterrc
rm -r ~/.local/share/soundkonverter
rm ~/.local/share/kservices5/ServiceMenus/add_replaygain_with_soundkonverter.desktop
rm ~/.local/share/kservices5/ServiceMenus/convert_with_soundkonverter.desktop
You can find soundKonverter packages for opensuse with some instructions at: http://software.opensuse.org/download.html?project=home:HessiJames&package=soundkonverter
openSUSE users should either add the following installation source to yast: http://download.opensuse.org/repositories/home:/HessiJames/<suse version>
eg.: http://download.opensuse.org/repositories/home:/HessiJames/openSUSE_12.2
for openSUSE 12.2.
Or add the KDE:Extra repository (includes a lot more KDE applications).
eg.: http://download.opensuse.org/repositories/KDE:/Extra/openSUSE_12.2
for openSUSE 12.2.
More information about openSUSE KDE repositories: http://en.opensuse.org/KDE_repositories
Quick installation guide:
Open the application launcher, start a terminal and enter the following commands (each line is one command, execute them by hitting [enter]):
Note: Replace "openSUSE_13.1" with your openSUSE version
zypper addrepo --refresh http://download.opensuse.org/repositories/home:/HessiJames/openSUSE_13.1 soundKonverter
zypper install soundkonverter
Ubuntu packages are maintained by Dominik Stadler at:
- https://launchpad.net/~dominik-stadler/+archive/ubuntu/dsta-trusty-ppa
- https://launchpad.net/~dominik-stadler/+archive/ubuntu/dsta-vivid-ppa
- https://launchpad.net/~dominik-stadler/+archive/ubuntu/dsta-wily-ppa
- https://launchpad.net/~dominik-stadler/+archive/ubuntu/dsta-xenial-ppa
soundKonverter creates two files dynamically on run time. They should be removed by a script when uninstalling soundKonverter. Just add the script below to the postun/postrm section of your package.
# Remove files really unneeded and annoying after uninstalling soundkonverter
# run only if last instance gets removed
# rpm: 0
# deb: remove
if [ "$1" = "0" ] || [ "$1" = "remove" ]; then
# get min UID limit
MIN_UID=$(grep "^UID_MIN" "/etc/login.defs")
# get max UID limit
MAX_UID=$(grep "^UID_MAX" "/etc/login.defs")
# use awk to print if UID >= $MIN_UID and UID <= $MAX_UID and shell is not /sbin/nologin
USERS=`awk -F':' -v "min=${MIN_UID##UID_MIN}" -v "max=${MAX_UID##UID_MAX}" '{ if ( $3 >= min && $3 <= max && $7 != "/sbin/nologin" ) print $1 }' "/etc/passwd"`
USERS="root $USERS"
for USER in $USERS; do
echo "cleaning up local files for user $USER"
FILE=`sudo su -l $USER -c "kde4-config --path \"services\" --locate \"ServiceMenus/convert_with_soundkonverter.desktop\""`
if [ -n "$FILE" ]; then
echo "rm $FILE"
rm "$FILE"
fi
FILE=`sudo su -l $USER -c "kde4-config --path \"services\" --locate \"ServiceMenus/add_replaygain_with_soundkonverter.desktop\""`
if [ -n "$FILE" ]; then
echo "rm $FILE"
rm "$FILE"
fi
done
fi
exit 0