From d2a7114e0b46fccad1e02e301c58a5124f361c5c Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 7 Sep 2020 09:56:08 +0200 Subject: gnu: taglib: 'taglib-config --libs' shows -L flag for zlib. Fixes compilation of emacs-emms-print-metadata. * gnu/packages/mp3.scm (taglib)[arguments]: Add #:phases. --- gnu/packages/mp3.scm | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'gnu') diff --git a/gnu/packages/mp3.scm b/gnu/packages/mp3.scm index 7ee009df74..a7574f0cf9 100644 --- a/gnu/packages/mp3.scm +++ b/gnu/packages/mp3.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013 Andreas Enge -;;; Copyright © 2014, 2015, 2017 Ludovic Courtès +;;; Copyright © 2014, 2015, 2017, 2020 Ludovic Courtès ;;; Copyright © 2015 Mark H Weaver ;;; Copyright © 2016 Efraim Flashner ;;; Copyright © 2017 Thomas Danckaert @@ -174,7 +174,18 @@ a highly stable and efficient implementation.") (build-system cmake-build-system) (arguments '(#:tests? #f ; Tests are not ran with BUILD_SHARED_LIBS on. - #:configure-flags (list "-DBUILD_SHARED_LIBS=ON"))) + #:configure-flags (list "-DBUILD_SHARED_LIBS=ON") + #:phases (modify-phases %standard-phases + (add-before 'configure 'adjust-zlib-ldflags + (lambda* (#:key inputs #:allow-other-keys) + ;; Make sure users of 'taglib-config --libs' get the -L + ;; flag for zlib. + (substitute* "CMakeLists.txt" + (("set\\(ZLIB_LIBRARIES_FLAGS -lz\\)") + (string-append "set(ZLIB_LIBRARIES_FLAGS -L" + (assoc-ref inputs "zlib") + " -lz)"))) + #t))))) (inputs `(("zlib" ,zlib))) (home-page "https://taglib.org") (synopsis "Library to access audio file meta-data") -- cgit v1.2.3