Package Details: spek 0.8.5-2

Git Clone URL: https://aur.archlinux.org/spek.git (read-only, click to copy)
Package Base: spek
Description: An acoustic spectrum analyser
Upstream URL: http://spek.cc/
Licenses: GPL3
Submitter: sushidude
Maintainer: petronny (AutoUpdateBot)
Last Packager: petronny
Votes: 57
Popularity: 0.75
First Submitted: 2015-08-12 05:45 (UTC)
Last Updated: 2025-05-28 11:44 (UTC)

Latest Comments

1 2 3 4 Next › Last »

tibequadorian commented on 2025-10-25 12:21 (UTC) (edited on 2025-10-25 12:21 (UTC) by tibequadorian)

configure.ac:71: warning: macro 'AM_GNU_GETTEXT_VERSION' not found in library
configure.ac:72: warning: macro 'AM_GNU_GETTEXT' not found in library
autoreconf: configure.ac: tracing
configure.ac: warning: AM_GNU_GETTEXT_VERSION or AM_GNU_GETTEXT_REQUIRE_VERSION is used, but not AM_GNU_GETTEXT
autoreconf: running: libtoolize --copy --force
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac,
libtoolize: and rerunning libtoolize and aclocal.
libtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
libtoolize: 'AC_PROG_RANLIB' is rendered obsolete by 'LT_INIT'
autoreconf: configure.ac: not using Intltool
autoreconf: configure.ac: not using Gtkdoc
autoreconf: running: aclocal --force 
configure.ac:71: warning: macro 'AM_GNU_GETTEXT_VERSION' not found in library
configure.ac:72: warning: macro 'AM_GNU_GETTEXT' not found in library
autoreconf: running: /usr/bin/autoconf --force
configure.ac:12: warning: The macro 'AC_PROG_LIBTOOL' is obsolete.
configure.ac:12: You should run autoupdate.
aclocal.m4:122: AC_PROG_LIBTOOL is expanded from...
configure.ac:12: the top level
configure.ac:71: error: possibly undefined macro: AM_GNU_GETTEXT_VERSION
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
configure.ac:72: error: possibly undefined macro: AM_GNU_GETTEXT
autoreconf: error: /usr/bin/autoconf failed with exit status: 1
==> ERROR: A failure occurred in build().
    Aborting...

ipaqmaster commented on 2025-10-23 03:54 (UTC)

Looks like ffmpeg doesn't include libavcodec/avfft.h anymore so this isn't building again.

A fresh archlinux environment can't build this package anymore due to spek-fft.cc:5:10: fatal error: libavcodec/avfft.h: No such file or directory

But my desktop can build it because it has ffmpeg 2:7.1.1-5 installed right now not the current latest in the repo ffmpeg 2:8.0-3.

ffmpeg4.4 seems to include that file avfft.h but under path usr/include/ffmpeg4.4/libavcodec/avfft.h which I assume isn't being considered in the spek makepkg build process.

giantplaceholder commented on 2025-10-10 07:23 (UTC)

This patch file should help to fix libavcodec/avfft.h build error

It does. Thanks!

alstruit commented on 2025-10-08 18:05 (UTC) (edited on 2025-10-08 18:06 (UTC) by alstruit)

This patch file should help to fix libavcodec/avfft.h build error.

From ac42a857038f91c3b796cdbf0f7213b33d70e1b4 Mon Sep 17 00:00:00 2001
From: Mike Wang <mikewang000000@gmail.com>
Date: Thu, 6 Feb 2025 03:14:57 +0800
Subject: [PATCH] fix: Replace deprecated FFmpeg avfft.h APIs

---
 src/spek-fft.cc | 28 +++++++++++++++++++++++++++-
 src/spek-fft.h  |  2 +-
 2 files changed, 28 insertions(+), 2 deletions(-)

diff --git a/src/spek-fft.cc b/src/spek-fft.cc
index 3105213..fca30b0 100644
--- a/src/spek-fft.cc
+++ b/src/spek-fft.cc
@@ -2,7 +2,13 @@

 #define __STDC_CONSTANT_MACROS
 extern "C" {
+#include <libavutil/version.h>
+#if LIBAVUTIL_VERSION_INT >= AV_VERSION_INT(58, 18, 100)
+#define USE_LIBAVUTIL_TX_API
+#include <libavutil/tx.h>
+#else
 #include <libavcodec/avfft.h>
+#endif
 }

 #include "spek-fft.h"
@@ -16,7 +22,12 @@ public:
     void execute() override;

 private:
+#ifdef USE_LIBAVUTIL_TX_API
+    struct AVTXContext *cx;
+    av_tx_fn tx_func;
+#else
     struct RDFTContext *cx;
+#endif
 };

 std::unique_ptr<FFTPlan> FFT::create(int nbits)
@@ -24,18 +35,33 @@ std::unique_ptr<FFTPlan> FFT::create(int nbits)
     return std::unique_ptr<FFTPlan>(new FFTPlanImpl(nbits));
 }

-FFTPlanImpl::FFTPlanImpl(int nbits) : FFTPlan(nbits), cx(av_rdft_init(nbits, DFT_R2C))
+FFTPlanImpl::FFTPlanImpl(int nbits) : FFTPlan(nbits)
 {
+#ifdef USE_LIBAVUTIL_TX_API
+    const float scale = 1.f;
+    av_tx_init(&this->cx, &this->tx_func, AV_TX_FLOAT_RDFT, 0, 1 << nbits, &scale, AV_TX_INPLACE);
+#else
+    this->cx = av_rdft_init(nbits, DFT_R2C);
+#endif
 }

 FFTPlanImpl::~FFTPlanImpl()
 {
+#ifdef USE_LIBAVUTIL_TX_API
+    av_tx_uninit(&this->cx);
+#else
     av_rdft_end(this->cx);
+#endif
 }

 void FFTPlanImpl::execute()
 {
+#ifdef USE_LIBAVUTIL_TX_API
+    float *input = this->get_input();
+    this->tx_func(this->cx, input, input, sizeof(float));
+#else
     av_rdft_calc(this->cx, this->get_input());
+#endif

     // Calculate magnitudes.
     int n = this->get_input_size();
diff --git a/src/spek-fft.h b/src/spek-fft.h
index 409263e..9a16c87 100644
--- a/src/spek-fft.h
+++ b/src/spek-fft.h
@@ -26,7 +26,7 @@ public:
     {
         // FFmpeg uses various assembly optimizations which expect
         // input data to be aligned by up to 32 bytes (e.g. AVX)
-        this->input = (float*) av_malloc(sizeof(float) * input_size);
+        this->input = (float*) av_malloc(sizeof(float) * (input_size + 2));
     }

     virtual ~FFTPlan()
-- 
2.51.0

bemxio commented on 2025-10-07 11:25 (UTC)

@lodger In that case, the best approach would be to create a spek-x AUR package. Someone has already made spek-x-git, and the current version 0.9.4 seems to be up-to-date with the most recent commit.

lodger commented on 2025-10-07 11:20 (UTC)

@bemxio

spek-x, a fork of spek, seems to be alive https://aur.archlinux.org/packages/spek-x-git

bemxio commented on 2025-10-06 19:15 (UTC)

@lodger Replacing ffmpeg inside the dependencies to ffmpeg7.1 and adding LDFLAGS="-L/usr/lib/ffmpeg7.1" CPPFLAGS="-I/usr/include/ffmpeg7.1" at the beginning of line 15 makes it work. It would probably be better to just update the project to FFmpeg 8.0, however upstream seems to be dead, as the last commit was pushed in 2023.

lodger commented on 2025-10-06 11:20 (UTC) (edited on 2025-10-06 11:21 (UTC) by lodger)

Can't build

spek-fft.cc:5:10: fatal error: libavcodec/avfft.h: No such file or directory
    5 | #include <libavcodec/avfft.h>
      |          ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [Makefile:610: libspek_a-spek-fft.o] Error 1
make[2]: Leaving directory '/tmp/makepkg/spek/src/spek-0.8.5/src'
make[1]: *** [Makefile:473: all-recursive] Error 1
make[1]: Leaving directory '/tmp/makepkg/spek/src/spek-0.8.5'
make: *** [Makefile:399: all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

Kyuunex commented on 2025-05-27 15:19 (UTC)

working pkgbuild

# Maintainer: Michał Przybyś <michal@przybys.eu>
pkgname=spek
pkgver=0.8.5
pkgrel=3
pkgdesc='An acoustic spectrum analyser'
arch=(x86_64)
url='http://spek.cc/'
license=(GPL3)
depends=(ffmpeg wxwidgets-gtk3)
source=("https://github.com/alexkay/spek/releases/download/v${pkgver}/spek-${pkgver}.tar.xz")
sha256sums=('1bccf85a14a01af8f2f30476cbad004e8bf6031f500e562bbe5bbd1e5eb16c59')

build() {
    cd "spek-${pkgver}"
    ./configure --prefix=/usr --mandir=/usr/share/man
    make
}

package() {
    cd "spek-${pkgver}"
    make DESTDIR="${pkgdir}" install
}