Update packaging, now installs to /usr/lib/flac2pod

This commit is contained in:
2022-11-16 15:02:00 -05:00
parent 2fd4d685e0
commit e78a0bc2c2
4 changed files with 23 additions and 30 deletions
+2 -4
View File
@@ -26,8 +26,6 @@ source_dir -> artist dir -> album dir -> FLAC files
# Installation
flac2pod is available in the AUR as "flac2pod". If installing on a non-Arch-based distribution, follow the manual installation instructions:
flac2pod is available in the AUR as "flac2pod".
- copy the contents of https://github.com/rwinkhart/flac2pod/blob/master/bin/ to your /usr/bin/
- install flac, python-mutagen, ffmpeg, and screen
- start converting
If installing on a non-Arch-based distribution, a generic package is available on the releases page.
View File
+21 -26
View File
@@ -1,14 +1,12 @@
#!/bin/bash
#!/usr/bin/env bash
# This script packages flac2pod (from source) for Arch Linux.
echo -e '\n\nthe value entered in this field will only affect the version reported to the package manager - the latest source is used regardless\n'
read -r -p "version number: " version
read -r -p "revision number: " revision
echo -e '\n\nThe value entered in this field will only affect the version reported to the package manager. The latest source is used regardless.\n'
read -r -p "Version number: " version
read -r -p "Revision number: " revision
echo -e '\nOptions (please enter the number only):'
echo -e '\n1. GitHub Release Tag\n2. Local\n'
read -r -p "Source (for build scripts): " source
echo -e '\noptions (please enter the number only):'
echo -e '\n1. gitHub release tag\n2. local\n'
read -r -p "source (for build scripts): " source
if [ "$source" == "1" ]; then
source='https://github.com/rwinkhart/flac2pod/releases/download/v$pkgver/flac2pod-$pkgver.tar.xz'
@@ -16,22 +14,22 @@ else
source=local://flac2pod-"$version".tar.xz
fi
# Archive creation
echo -e '\nPackaging as generic...\n'
mkdir -p packages/archtemp/usr
cp -r bin packages/archtemp/usr/
cp -r share packages/archtemp/usr/
tar -C packages/archtemp -cvf packages/flac2pod-"$version".tar.xz usr/
rm -rf packages/archtemp
sha512="$(sha512sum packages/flac2pod-"$version".tar.xz | awk '{print $1;}')"
# generic packaging
echo -e '\npackaging as generic...\n'
mkdir -p output/generictemp/usr/lib/flac2pod
cp -r lib/. output/generictemp/usr/lib/flac2pod/
ln -s /usr/lib/flac2pod/flac2pod.py output/generictemp/usr/bin/flac2pod
ln -s /usr/lib/flac2pod/flac2pod-flacgain.py output/generictemp/usr/bin/flac2pod-flacgain
cp -r share output/generictemp/usr/
tar -C output/generictemp -cvJf output/flac2pod-"$version".tar.xz usr/
rm -rf output/generictemp
sha512="$(sha512sum output/flac2pod-"$version".tar.xz | awk '{print $1;}')"
echo -e "\nsha512 sum:\n$sha512"
echo -e "\nGeneric packaging complete.\n"
echo -e "\ngeneric packaging complete\n"
# PKGBUILD creation
echo -e '\nGenerating PKGBUILD...'
echo -e '\ngenerating PKGBUILD...'
echo "# Maintainer: Randall Winkhart <idgr at tutanota dot com>
pkgname=flac2pod
pkgver="$version"
pkgrel="$revision"
@@ -40,14 +38,11 @@ url='https://github.com/rwinkhart/flac2pod'
arch=('any')
license=('GPL2')
depends=(ffmpeg flac python python-mutagen screen)
source=(\""$source"\")
sha512sums=('"$sha512"')
package() {
tar xf flac2pod-"\"\$pkgver\"".tar.xz -C "\"\${pkgdir}\""
}
" > packages/PKGBUILD
echo -e "\nPKGBUILD generated.\n"
" > output/PKGBUILD
echo -e "\nPKGBUILD generated\n"