cdparanoiaIII: Cleanup
Handle CC the normal way, `unset CC` was from quite old
28b6fb61e6
during early macOS experiments
and no longer needed.
Regenerate autoconf stuff unconditionally because it is so old, and
unconditional is just simpler.
Put conditional patches after unconditional ones as is more idiomatic.
This commit is contained in:
parent
f153271f12
commit
8a00f0ca38
22
pkgs/applications/audio/cdparanoia/configure.patch
Normal file
22
pkgs/applications/audio/cdparanoia/configure.patch
Normal file
|
@ -0,0 +1,22 @@
|
|||
diff --git a/configure.in b/configure.ac
|
||||
similarity index 90%
|
||||
rename from configure.in
|
||||
rename to configure.ac
|
||||
index 3ad98ca11da..8fad378faf4 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.ac
|
||||
@@ -1,13 +1,8 @@
|
||||
AC_INIT(interface/interface.c)
|
||||
|
||||
-cp $srcdir/configure.guess $srcdir/config.guess
|
||||
-cp $srcdir/configure.sub $srcdir/config.sub
|
||||
-
|
||||
AC_CANONICAL_HOST
|
||||
|
||||
-if test -z "$CC"; then
|
||||
- AC_PROG_CC
|
||||
-fi
|
||||
+AC_PROG_CC
|
||||
AC_PROG_RANLIB
|
||||
AC_CHECK_PROG(AR,ar,ar)
|
||||
AC_CHECK_PROG(INSTALL,install,install)
|
|
@ -1,4 +1,7 @@
|
|||
{ lib, stdenv, fetchurl, gnu-config, IOKit, Carbon }:
|
||||
{ lib, stdenv, fetchurl
|
||||
, updateAutotoolsGnuConfigScriptsHook, autoreconfHook
|
||||
, IOKit, Carbon
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "cdparanoia-III";
|
||||
|
@ -9,7 +12,10 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "1pv4zrajm46za0f6lv162iqffih57a8ly4pc69f7y0gfyigb8p80";
|
||||
};
|
||||
|
||||
patches = lib.optionals stdenv.isDarwin [
|
||||
patches = [
|
||||
./fix_private_keyword.patch
|
||||
./configure.patch
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
(fetchurl {
|
||||
url = "https://trac.macports.org/export/70964/trunk/dports/audio/cdparanoia/files/osx_interface.patch";
|
||||
sha256 = "1n86kzm2ssl8fdf5wlhp6ncb2bf6b9xlb5vg0mhc85r69prqzjiy";
|
||||
|
@ -18,8 +24,12 @@ stdenv.mkDerivation rec {
|
|||
url = "https://trac.macports.org/export/70964/trunk/dports/audio/cdparanoia/files/patch-paranoia_paranoia.c.10.4.diff";
|
||||
sha256 = "17l2qhn8sh4jy6ryy5si6ll6dndcm0r537rlmk4a6a8vkn852vad";
|
||||
})
|
||||
] ++ lib.optional stdenv.hostPlatform.isMusl ./utils.patch
|
||||
++ [./fix_private_keyword.patch];
|
||||
] ++ lib.optional stdenv.hostPlatform.isMusl ./utils.patch;
|
||||
|
||||
nativeBuildInputs = [
|
||||
updateAutotoolsGnuConfigScriptsHook
|
||||
autoreconfHook
|
||||
];
|
||||
|
||||
propagatedBuildInputs = lib.optionals stdenv.isDarwin [
|
||||
Carbon
|
||||
|
@ -28,13 +38,6 @@ stdenv.mkDerivation rec {
|
|||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
preConfigure = ''
|
||||
unset CC
|
||||
'' + lib.optionalString (!stdenv.hostPlatform.isx86) ''
|
||||
cp ${gnu-config}/config.sub configure.sub
|
||||
cp ${gnu-config}/config.guess configure.guess
|
||||
'';
|
||||
|
||||
# Build system reuses the same object file names for shared and static
|
||||
# library. Occasionally fails in the middle:
|
||||
# gcc -O2 -fsigned-char -g -O2 -c scan_devices.c
|
||||
|
|
Loading…
Reference in a new issue