Open Eloitor opened 2 months ago
Maybe https://github.com/scottypitcher/tcl-snack instead
I could probably give what @Eloitor suggested a shot... if you'd like.
It would be great, thanks!
OK, I'll try.
A little help, I did get to building, but it suddenly exits xbps-src, haven't checked why.
# Template file for 'tcl-snack
pkgname=tcl-snack
version=2.2.10
revision=1
build_style=gnu-makefile
hostmakedepends=""
makedepends="tcl-devel tk-devel vorbis-tools libvorbis-devel alsa-lib-devel"
short_desc="Snack is a powerfull multi-platform library for audio playback, recording, etc. using Tcl/Tk or Python."
maintainer="someone <someone@some.one>"
license="GPL-2.0-only"
homepage="https://www.speech.kth.se/snack/"
distfiles="https://web.archive.org/web/20230819212652/https://www.speech.kth.se/snack/dist/snack${version}.tar.gz"
checksum="4bfe764547ab92ba58f43b77366dbb7c7b3512d65a27cdbf9e585a9cb64ce81e"
post_extract () {
# Minor code corrections, missing include.
sed -i '/#include <stdlib.h>/a #include <math.h>' ${wrksrc}/generic/jkFormatMP3.c
}
do_configure () {
cd ${wrksrc}/unix
./configure \
--enable-alsa \
--with-tcl=/usr/lib/ \
--with-tk=/usr/lib \
--with-ogg-include=/usr/lib \
--with-ogg-lib=/usr/lib
}
do_build () {
cd ${wrksrc}/unix
make
}
I think you can use the cmake_builddir
variable
and configure_args
I don't think the builddir is the problem, though it is preferable to have one. The makefile runs an if statement and the if statement ends, and then it just exits (xbps, like quits entirely). I still haven't tried echoing to see at which point it does that, but could you take a look at the makefile and see if anything strikes you as odd?
I think it is fine. It just ends building. after that I get
=> tcl-snack-2.2.10_1: skipping check (XBPS_CHECK_PKGS is disabled) ... => tcl-snack-2.2.10_1: running pre-install hook: 00-libdir ... => tcl-snack-2.2.10_1: running pre-install hook: 02-script-wrapper ... => tcl-snack-2.2.10_1: running pre-install hook: 98-fixup-gir-path ... => tcl-snack-2.2.10_1: running do_install ... make: *** No rule to make target 'install'. Stop.
# Template file for 'tcl-snack
pkgname=tcl-snack
version=2.2.10
revision=1
build_style=gnu-makefile
build_wrksrc=unix
hostmakedepends=""
makedepends="tcl-devel tk-devel vorbis-tools libvorbis-devel alsa-lib-devel"
short_desc="Snack is a powerfull multi-platform library for audio playback, recording, etc. using Tcl/Tk or Python."
maintainer="someone <someone@some.one>"
license="GPL-2.0-only"
homepage="https://www.speech.kth.se/snack/"
distfiles="https://web.archive.org/web/20230819212652/https://www.speech.kth.se/snack/dist/snack${version}.tar.gz"
checksum="4bfe764547ab92ba58f43b77366dbb7c7b3512d65a27cdbf9e585a9cb64ce81e"
post_extract () {
# Minor code corrections, missing include.
sed -i '/#include <stdlib.h>/a #include <math.h>' ${wrksrc}/generic/jkFormatMP3.c
}
do_configure () {
./configure \
--enable-alsa \
--with-tcl=/usr/lib/ \
--with-tk=/usr/lib \
--with-ogg-include=/usr/lib \
--with-ogg-lib=/usr/lib
}
# Template file for 'tcl-snack
pkgname=tcl-snack
version=2.2.10
revision=1
build_style=gnu-makefile
build_wrksrc=unix
hostmakedepends=""
makedepends="tcl-devel tk-devel vorbis-tools libvorbis-devel alsa-lib-devel"
short_desc="Snack is a powerfull multi-platform library for audio playback, recording, etc. using Tcl/Tk or Python."
maintainer="someone <someone@some.one>"
license="GPL-2.0-only"
homepage="https://www.speech.kth.se/snack/"
distfiles="https://web.archive.org/web/20230819212652/https://www.speech.kth.se/snack/dist/snack${version}.tar.gz"
checksum="4bfe764547ab92ba58f43b77366dbb7c7b3512d65a27cdbf9e585a9cb64ce81e"
post_extract () {
# Minor code corrections, missing include.
sed -i '/#include <stdlib.h>/a #include <math.h>' ${wrksrc}/generic/jkFormatMP3.c
sed -i '/#include "snack.h"/a #include <stdint.h>' ${wrksrc}/generic/jkSoundFile.c
}
do_configure () {
./configure \
--enable-alsa \
--with-tcl=/usr/lib/ \
--with-tk=/usr/lib \
--with-ogg-include=/usr/lib \
--with-ogg-lib=/usr/lib
}
Now I'm getting the error:
./../unix/jkAudIO_alsa.c:23:10: fatal error: jkAudIO.h: No such file or directory
23 | #include "jkAudIO.h"
| ^~~
compilation terminated.
using build-styl=gnu-configure
solved the issue
I think it is fine. It just ends building.
Not for me... I will try on a clean git clone.
Now I'm getting the error...
That's because the makefile needs to exit the unix
dir and enter the generic
dir, but with build_wrksrc=unix
, we're limiting xbps-src to build in that dir and not exit it. I tried copying a few files "missing" from the unix
dir and it does get past the files I copied, but of course gets stuck on other missing files.
There are 2 options. We either copy everything from generic
to unix
, which might overwrite something that doesn't need to be overwritten, or two, we don't define build_wrksrc
at all and just do do_build
manually, like in my original script.
make: *** No rule to make target 'install'. Stop.
I think that is because it actually builds in the same dir as the source, there is no separate dir... don't know how xbps-src solves this regarding what files it should take from the build... my guess is, it has to have a separate build dir, so it will just copy everything to destdir
.
using
build-styl=gnu-configure
solved the issue
Just that change in your last template? OK, will try.
# Template file for 'tcl-snack
pkgname=tcl-snack
version=2.2.10
revision=1
build_style=gnu-configure
build_wrksrc=unix
configure_args="--enable-alsa --with-tcl=/usr/lib/ --with-tk=/usr/lib --with-ogg-include=/usr/lib --with-ogg-lib=/usr/lib"
hostmakedepends=""
makedepends="tcl-devel tk-devel vorbis-tools libvorbis-devel alsa-lib-devel"
short_desc="Snack is a powerfull multi-platform library for audio playback, recording, etc. using Tcl/Tk or Python."
maintainer="someone <someone@some.one>"
license="GPL-2.0-only"
homepage="https://www.speech.kth.se/snack/"
distfiles="https://web.archive.org/web/20230819212652/https://www.speech.kth.se/snack/dist/snack${version}.tar.gz"
checksum="4bfe764547ab92ba58f43b77366dbb7c7b3512d65a27cdbf9e585a9cb64ce81e"
post_extract () {
# Minor code corrections, missing include.
sed -i '/#include <stdlib.h>/a #include <math.h>' ${wrksrc}/generic/jkFormatMP3.c
}
=> tcl-snack-2.2.10_1: running post-install hook: 99-pkglint-warn-cross-cruft ... => tcl-snack-2.2.10_1: running pre-pkg hook: 03-rewrite-python-shebang ... => tcl-snack-2.2.10_1: running pre-pkg hook: 04-generate-runtime-deps ... SONAME: libc.so.6 <-> glibc>=2.39_1 SONAME: libasound.so.2 <-> alsa-lib>=1.0.20_1 SONAME: libvorbisenc.so.2 <-> libvorbis>=1.2.1rc1_1 SONAME: libvorbis.so.0 <-> libvorbis>=1.2.1rc1_1 SONAME: libogg.so.0 <-> libogg>=1.3.0_1 SONAME: libX11.so.6 <-> libX11>=1.2_1 SONAME: libtcl8.6.so <-> tcl>=8.6.0_1 SONAME: libm.so.6 <-> glibc>=2.39_1 => tcl-snack-2.2.10_1: running pre-pkg hook: 05-generate-32bit-runtime-deps ... => tcl-snack-2.2.10_1: running pre-pkg hook: 90-set-timestamps ... => tcl-snack-2.2.10_1: setting mtimes to Fri Apr 26 07:56:09 AM UTC 2024 => tcl-snack-2.2.10_1: running pre-pkg hook: 99-pkglint-subpkgs ... => tcl-snack-2.2.10_1: running pre-pkg hook: 99-pkglint ... => ERROR: tcl-snack-2.2.10_1: /lib64 must not exist. => ERROR: tcl-snack-2.2.10_1: cannot continue with installation!
The problem now it is that it install things in the wrong place...
Also, I think that snack can be used from other scripting languages. Maybe we should call it just "snack".
Yeah, there is no other package called "snack". OK, go for it.
Package name
tcl-snack
Package homepage
http://www.speech.kth.se/snack/
Description
Sound toolkit for scripting languages (tcl).
scid_vs_pc uses it for sound:
Does the requested package meet the package requirements?
System, Compiled, Required
Is the requested package released?
Yes