summary refs log tree commit diff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2020-02-24 19:37:03 +0100
committerMarius Bakke <mbakke@fastmail.com>2020-02-24 19:37:03 +0100
commit3941af527df6f27c88258c5d3b78720a07fe60ef (patch)
tree4747f74f32faef8a4f20bf7adf797ce57a8324fc /gnu/packages/patches
parentd85f8e46dbc5a978fe7359c89cbb3167fb9c2029 (diff)
parent7daae3c9d09a4d27586824a1d1af99e7af454d26 (diff)
downloadguix-3941af527df6f27c88258c5d3b78720a07fe60ef.tar.gz
Merge branch 'master' into staging
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/choqok-Fix-building-under-Qt-5.13.patch89
-rw-r--r--gnu/packages/patches/clang-9.0-libc-search-path.patch83
-rw-r--r--gnu/packages/patches/containerd-test-with-go1.13.patch21
-rw-r--r--gnu/packages/patches/desmume-gcc6-fixes.patch59
-rw-r--r--gnu/packages/patches/desmume-gcc7-fixes.patch18
-rw-r--r--gnu/packages/patches/elixir-path-length.patch8
-rw-r--r--gnu/packages/patches/mumps-shared-libseq.patch2
-rw-r--r--gnu/packages/patches/mumps-shared-mumps.patch8
-rw-r--r--gnu/packages/patches/mumps-shared-pord.patch4
-rw-r--r--gnu/packages/patches/qtbase-QTBUG-81715.patch40
-rw-r--r--gnu/packages/patches/racket-store-checksum-override.patch30
-rw-r--r--gnu/packages/patches/upx-fix-CVE-2017-15056.patch96
12 files changed, 247 insertions, 211 deletions
diff --git a/gnu/packages/patches/choqok-Fix-building-under-Qt-5.13.patch b/gnu/packages/patches/choqok-Fix-building-under-Qt-5.13.patch
deleted file mode 100644
index 4250106a19..0000000000
--- a/gnu/packages/patches/choqok-Fix-building-under-Qt-5.13.patch
+++ /dev/null
@@ -1,89 +0,0 @@
-Add QMap include to fix building under Qt 5.13
-
-This combines several patches which all add the same missing include:
-- e13ab06f65a4e8b6259bccda1401abb9c1c9fdca
-- 546ede9ef712bb1b156a55ce30df81c3203dde61
-- 08fb06b63a78888e6703de6ac1a4fd6a0e2791eb
-- bef6784596bf0b41287ebad81f138e1c8c2a6be2
-
-Include is no longer added transitively.
----
-
---- a/plugins/betternotify/notify.h
-+++ b/plugins/betternotify/notify.h
-@@ -23,6 +23,7 @@
- #ifndef NOTIFY_H
- #define NOTIFY_H
- 
-+#include <QMap>
- #include <QQueue>
- #include <QPoint>
- #include <QPointer>
---- a/plugins/untiny/untiny.h
-+++ b/plugins/untiny/untiny.h
-@@ -27,6 +27,7 @@
- 
- #include "plugin.h"
- 
-+#include <QMap>
- #include <QQueue>
- #include <QUrl>
- #include <QPointer>
---- a/plugins/uploaders/flickr/flickr.h
-+++ b/plugins/uploaders/flickr/flickr.h
-@@ -26,6 +26,8 @@
- 
- #include "uploader.h"
- 
-+#include <QMap>
-+
- /**
- @author Andrey Esin \<gmlastik@gmail.com\>
- */
-diff --git a/plugins/uploaders/imageshack/imageshack.h b/plugins/uploaders/imageshack/imageshack.h
-index d9ddc88..63d0e3f 100644
---- a/plugins/uploaders/imageshack/imageshack.h
-+++ b/plugins/uploaders/imageshack/imageshack.h
-@@ -26,6 +26,8 @@
- 
- #include "uploader.h"
- 
-+#include <QMap>
-+
- /**
- @author Mehrdad Momeny \<mehrdad.momeny@gmail.com\>
- */
---- a/plugins/uploaders/mobypicture/mobypicture.h
-+++ b/plugins/uploaders/mobypicture/mobypicture.h
-@@ -26,6 +26,8 @@
- 
- #include "uploader.h"
- 
-+#include <QMap>
-+
- class KJob;
- 
- class Mobypicture : public Choqok::Uploader
---- a/plugins/uploaders/posterous/posterous.h
-+++ b/plugins/uploaders/posterous/posterous.h
-@@ -26,6 +26,8 @@
- 
- #include "uploader.h"
- 
-+#include <QMap>
-+
- class KJob;
- 
- class Posterous : public Choqok::Uploader
---- a/plugins/uploaders/twitgoo/twitgoo.h
-+++ b/plugins/uploaders/twitgoo/twitgoo.h
-@@ -26,6 +26,8 @@
- 
- #include "uploader.h"
- 
-+#include <QMap>
-+
- class KJob;
- 
- class Twitgoo : public Choqok::Uploader
---
diff --git a/gnu/packages/patches/clang-9.0-libc-search-path.patch b/gnu/packages/patches/clang-9.0-libc-search-path.patch
new file mode 100644
index 0000000000..be34344842
--- /dev/null
+++ b/gnu/packages/patches/clang-9.0-libc-search-path.patch
@@ -0,0 +1,83 @@
+Clang attempts to guess file names based on the OS and distro (yes!),
+but unfortunately, that doesn't work for us.
+
+This patch makes it easy to insert libc's $libdir so that Clang passes the
+correct absolute file name of crt1.o etc. to 'ld'.  It also disables all
+the distro-specific stuff and removes the hard-coded FHS directory names
+to make sure Clang also works on non-GuixSD systems.
+
+diff --git a/lib/Driver/ToolChains/Linux.cpp b/lib/Driver/ToolChains/Linux.cpp
+--- a/lib/Driver/ToolChains/Linux.cpp
++++ b/lib/Driver/ToolChains/Linux.cpp
+@@ -240,6 +240,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+                          .str());
+   }
+ 
++// Comment out the distro-specific tweaks so that they don't bite when
++// using Guix on a foreign distro.
++#if 0
+   Distro Distro(D.getVFS());
+ 
+   if (Distro.IsAlpineLinux() || Triple.isAndroid()) {
+@@ -306,6 +309,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+ 
+   if (IsAndroid || Distro.IsOpenSUSE())
+     ExtraOpts.push_back("--enable-new-dtags");
++#endif
+ 
+   // The selection of paths to try here is designed to match the patterns which
+   // the GCC driver itself uses, as this is part of the GCC-compatible driver.
+@@ -363,7 +367,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+     // the cross. Note that GCC does include some of these directories in some
+     // configurations but this seems somewhere between questionable and simply
+     // a bug.
+-    if (StringRef(LibPath).startswith(SysRoot)) {
++    if (0) {
+       addPathIfExists(D, LibPath + "/" + MultiarchTriple, Paths);
+       addPathIfExists(D, LibPath + "/../" + OSLibDir, Paths);
+     }
+@@ -382,6 +386,8 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+   addPathIfExists(D, SysRoot + "/lib/" + MultiarchTriple, Paths);
+   addPathIfExists(D, SysRoot + "/lib/../" + OSLibDir, Paths);
+ 
++// This requires the commented distro tweaks above.
++#if 0
+   if (IsAndroid) {
+     // Android sysroots contain a library directory for each supported OS
+     // version as well as some unversioned libraries in the usual multiarch
+@@ -410,10 +416,15 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+     addPathIfExists(D, SysRoot + "/" + OSLibDir + "/" + ABIName, Paths);
+     addPathIfExists(D, SysRoot + "/usr/" + OSLibDir + "/" + ABIName, Paths);
+   }
++#endif
+ 
+   // Try walking via the GCC triple path in case of biarch or multiarch GCC
+   // installations with strange symlinks.
+   if (GCCInstallation.isValid()) {
++
++// The following code would end up adding things like
++// "/usr/lib/x86_64-unknown-linux-gnu/../../lib64" to the search path.
++#if 0
+     addPathIfExists(D,
+                     SysRoot + "/usr/lib/" + GCCInstallation.getTriple().str() +
+                         "/../../" + OSLibDir,
+@@ -426,6 +437,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+                              BiarchSibling.gccSuffix(),
+                       Paths);
+     }
++#endif
+ 
+     // See comments above on the multilib variant for details of why this is
+     // included even from outside the sysroot.
+@@ -450,8 +462,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+   if (StringRef(D.Dir).startswith(SysRoot))
+     addPathIfExists(D, D.Dir + "/../lib", Paths);
+ 
+-  addPathIfExists(D, SysRoot + "/lib", Paths);
+-  addPathIfExists(D, SysRoot + "/usr/lib", Paths);
++  // Add libc's lib/ directory to the search path, so that crt1.o, crti.o,
++  // and friends can be found.
++  addPathIfExists(D, "@GLIBC_LIBDIR@", Paths);
+ }
+ 
+ ToolChain::CXXStdlibType Linux::GetDefaultCXXStdlibType() const {
diff --git a/gnu/packages/patches/containerd-test-with-go1.13.patch b/gnu/packages/patches/containerd-test-with-go1.13.patch
new file mode 100644
index 0000000000..964adee9e6
--- /dev/null
+++ b/gnu/packages/patches/containerd-test-with-go1.13.patch
@@ -0,0 +1,21 @@
+Compatibility fix for go 1.13, flag.Parse() shouldn't be called during
+package initialization.
+https://golang.org/doc/go1.13#testing
+--- a/client_test.go	2020-02-12 14:50:28.991245371 -0500
++++ b/client_test.go	2020-02-12 15:12:37.383523980 -0500
+@@ -49,7 +49,6 @@
+ 	flag.StringVar(&address, "address", defaultAddress, "The address to the containerd socket for use in the tests")
+ 	flag.BoolVar(&noDaemon, "no-daemon", false, "Do not start a dedicated daemon for the tests")
+ 	flag.BoolVar(&noCriu, "no-criu", false, "Do not run the checkpoint tests")
+-	flag.Parse()
+ }
+ 
+ func testContext() (context.Context, context.CancelFunc) {
+@@ -59,6 +58,7 @@
+ }
+ 
+ func TestMain(m *testing.M) {
++	flag.Parse()
+ 	if testing.Short() {
+ 		os.Exit(m.Run())
+ 	}
diff --git a/gnu/packages/patches/desmume-gcc6-fixes.patch b/gnu/packages/patches/desmume-gcc6-fixes.patch
new file mode 100644
index 0000000000..6eb9576f64
--- /dev/null
+++ b/gnu/packages/patches/desmume-gcc6-fixes.patch
@@ -0,0 +1,59 @@
+From: zeromus
+Origin: upstream, https://sourceforge.net/p/desmume/code/5514, https://sourceforge.net/p/desmume/code/5517, https://sourceforge.net/p/desmume/code/5430
+Subject: fix GCC6 issues
+Bug: https://sourceforge.net/p/desmume/bugs/1570/
+Bug-Debian: http://bugs.debian.org/811691
+
+Index: desmume/src/MMU_timing.h
+===================================================================
+--- desmume/src/MMU_timing.h	(revision 5513)
++++ desmume/src/MMU_timing.h	(revision 5517)
+@@ -155,8 +155,8 @@
+ 	enum { ASSOCIATIVITY = 1 << ASSOCIATIVESHIFT };

+ 	enum { BLOCKSIZE = 1 << BLOCKSIZESHIFT };

+ 	enum { TAGSHIFT = SIZESHIFT - ASSOCIATIVESHIFT };

+-	enum { TAGMASK = (u32)(~0 << TAGSHIFT) };

+-	enum { BLOCKMASK = ((u32)~0 >> (32 - TAGSHIFT)) & (u32)(~0 << BLOCKSIZESHIFT) };

++	enum { TAGMASK = (u32)(~0U << TAGSHIFT) };

++	enum { BLOCKMASK = ((u32)~0U >> (32 - TAGSHIFT)) & (u32)(~0U << BLOCKSIZESHIFT) };

+ 	enum { WORDSIZE = sizeof(u32) };

+ 	enum { WORDSPERBLOCK = (1 << BLOCKSIZESHIFT) / WORDSIZE };

+ 	enum { DATAPERWORD = WORDSIZE * ASSOCIATIVITY };

+Index: desmume/src/ctrlssdl.cpp
+===================================================================
+--- desmume/src/ctrlssdl.cpp	(revision 5513)
++++ desmume/src/ctrlssdl.cpp	(revision 5517)
+@@ -200,7 +200,7 @@
+           break;
+         case SDL_JOYAXISMOTION:
+           /* Dead zone of 50% */
+-          if( (abs(event.jaxis.value) >> 14) != 0 )
++          if( ((u32)abs(event.jaxis.value) >> 14) != 0 )
+             {
+               key = ((event.jaxis.which & 15) << 12) | JOY_AXIS << 8 | ((event.jaxis.axis & 127) << 1);
+               if (event.jaxis.value > 0) {
+@@ -370,7 +370,7 @@
+          Note: button constants have a 1bit offset. */
+     case SDL_JOYAXISMOTION:
+       key_code = ((event->jaxis.which & 15) << 12) | JOY_AXIS << 8 | ((event->jaxis.axis & 127) << 1);
+-      if( (abs(event->jaxis.value) >> 14) != 0 )
++      if( ((u32)abs(event->jaxis.value) >> 14) != 0 )
+         {
+           if (event->jaxis.value > 0)
+             key_code |= 1;
+Index: desmume/src/wifi.cpp
+===================================================================
+--- desmume/src/wifi.cpp	(revision 5429)
++++ desmume/src/wifi.cpp	(revision 5430)
+@@ -320,9 +320,9 @@
+ 
+ #if (WIFI_LOGGING_LEVEL >= 1)
+ 	#if WIFI_LOG_USE_LOGC
+-		#define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) LOGC(8, "WIFI: "__VA_ARGS__);
++		#define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) LOGC(8, "WIFI: " __VA_ARGS__);
+ 	#else
+-		#define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) printf("WIFI: "__VA_ARGS__);
++		#define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) printf("WIFI: " __VA_ARGS__);
+ 	#endif
+ #else
+ #define WIFI_LOG(level, ...) {}
diff --git a/gnu/packages/patches/desmume-gcc7-fixes.patch b/gnu/packages/patches/desmume-gcc7-fixes.patch
new file mode 100644
index 0000000000..a4934ff6e6
--- /dev/null
+++ b/gnu/packages/patches/desmume-gcc7-fixes.patch
@@ -0,0 +1,18 @@
+From e1f7039f1b06add4fb75b2f8774000b8f05574af Mon Sep 17 00:00:00 2001
+From: rogerman <rogerman@users.sf.net>
+Date: Mon, 17 Aug 2015 21:15:04 +0000
+Subject: Fix bug with libfat string handling.
+
+diff --git a/src/utils/libfat/directory.cpp b/src/utils/libfat/directory.cpp
+index 765d7ae5..b6d7f01f 100644
+--- a/src/utils/libfat/directory.cpp
++++ b/src/utils/libfat/directory.cpp
+@@ -139,7 +139,7 @@ static size_t _FAT_directory_mbstoucs2 (ucs2_t* dst, const char* src, size_t len
+ 	int bytes;
+ 	size_t count = 0;
+ 
+-	while (count < len-1 && src != '\0') {
++	while (count < len-1 && *src != '\0') {
+ 		bytes = mbrtowc (&tempChar, src, MB_CUR_MAX, &ps);
+ 		if (bytes > 0) {
+ 			*dst = (ucs2_t)tempChar;
diff --git a/gnu/packages/patches/elixir-path-length.patch b/gnu/packages/patches/elixir-path-length.patch
index aa8bf38829..ab99595cff 100644
--- a/gnu/packages/patches/elixir-path-length.patch
+++ b/gnu/packages/patches/elixir-path-length.patch
@@ -5,11 +5,11 @@ after the substitution is made.
 
 --- a/Makefile
 +++ b/Makefile
-@@ -213,6 +213,7 @@
- TEST_ERLS = $(addprefix $(TEST_EBIN)/, $(addsuffix .beam, $(basename $(notdir $(wildcard $(TEST_ERL)/*.erl)))))
+@@ -265,6 +265,7 @@ format: compile
+	$(call FORMAT)
  
  test_formatted: compile
-+	bin/elixir bin/mix format lib/mix/lib/mix/scm/git.ex
- 	bin/elixir bin/mix format --check-formatted
++	$(call FORMAT,lib/mix/lib/mix/scm/git.ex)
+	$(call FORMAT,--check-formatted)
  
  test_erlang: compile $(TEST_ERLS)
diff --git a/gnu/packages/patches/mumps-shared-libseq.patch b/gnu/packages/patches/mumps-shared-libseq.patch
index feafcf123b..eccf528f7a 100644
--- a/gnu/packages/patches/mumps-shared-libseq.patch
+++ b/gnu/packages/patches/mumps-shared-libseq.patch
@@ -17,7 +17,7 @@ Index: mumps/libseq/Makefile
 +	$(AR) $@ mpi.o mpic.o elapse.o
  	$(RANLIB) $@
 +libmpiseq$(PLAT).so: mpi.o mpic.o elapse.o
-+	$(FC) -shared $^ -Wl,-soname,libmpiseq$(PLAT)-5.1.2.so -o libmpiseq$(PLAT)-5.1.2.so -Wl,-z,defs
++	$(FC) -shared $^ -Wl,-soname,libmpiseq$(PLAT)-5.2.1.so -o libmpiseq$(PLAT)-5.2.1.so -Wl,-z,defs
  .f.o:
 -	$(FC) $(OPTF)              -c $*.f $(OUTF)$*.o
 +	$(FC) $(OPTF)              -fPIC -c $*.f $(OUTF)$*.o
diff --git a/gnu/packages/patches/mumps-shared-mumps.patch b/gnu/packages/patches/mumps-shared-mumps.patch
index 9e2491f300..d94ccf6ce9 100644
--- a/gnu/packages/patches/mumps-shared-mumps.patch
+++ b/gnu/packages/patches/mumps-shared-mumps.patch
@@ -30,16 +30,16 @@ Index: mumps/src/Makefile
 -$(libdir)/lib$(ARITH)mumps$(PLAT)$(LIBEXT):    $(OBJS_MOD) $(OBJS_OTHER)
 -	$(AR)$@ $?
 +$(libdir)/libmumps_common$(PLAT).so:      $(OBJS_COMMON_MOD) $(OBJS_COMMON_OTHER)
-+	$(FC) -shared $^ -Wl,-soname,libmumps_common$(PLAT)-5.1.2.so -L$(libdir) $(LORDERINGS) -lpthread $(MPIFLIB) $(MPICLIB) $(LEXTRAS) -o $(libdir)/libmumps_common$(PLAT)-5.1.2.so -Wl,-z,defs
-+	ln -s libmumps_common$(PLAT)-5.1.2.so $@
++	$(FC) -shared $^ -Wl,-soname,libmumps_common$(PLAT)-5.2.1.so -L$(libdir) $(LORDERINGS) -lpthread $(MPIFLIB) $(MPICLIB) $(LEXTRAS) -o $(libdir)/libmumps_common$(PLAT)-5.2.1.so -Wl,-z,defs
++	ln -s libmumps_common$(PLAT)-5.2.1.so $@
 +
 +$(libdir)/lib$(ARITH)mumps$(PLAT).a:    $(OBJS_MOD) $(OBJS_OTHER)
 +	$(AR) $@ $?
  	$(RANLIB) $@
  
 +$(libdir)/lib$(ARITH)mumps$(PLAT).so:    $(OBJS_MOD) $(OBJS_OTHER)
-+	$(FC) -shared $^ -Wl,-soname,lib$(ARITH)mumps$(PLAT)-5.1.2.so -L$(libdir) -lmumps_common$(PLAT) $(LORDERINGS) $(MPIFLIB) $(LEXTRAS) $(LIBBLAS) $(SCALAP) $(LAPACK) -o $(libdir)/lib$(ARITH)mumps$(PLAT)-5.1.2.so -Wl,-z,defs
-+	ln -s lib$(ARITH)mumps$(PLAT)-5.1.2.so $@
++	$(FC) -shared $^ -Wl,-soname,lib$(ARITH)mumps$(PLAT)-5.2.1.so -L$(libdir) -lmumps_common$(PLAT) $(LORDERINGS) $(MPIFLIB) $(LEXTRAS) $(LIBBLAS) $(SCALAP) $(LAPACK) -o $(libdir)/lib$(ARITH)mumps$(PLAT)-5.2.1.so -Wl,-z,defs
++	ln -s lib$(ARITH)mumps$(PLAT)-5.2.1.so $@
 +
  # Dependencies between modules:
  $(ARITH)mumps_load.o:		$(ARITH)mumps_comm_buffer.o \
diff --git a/gnu/packages/patches/mumps-shared-pord.patch b/gnu/packages/patches/mumps-shared-pord.patch
index 48062d4f89..d3915b0ad9 100644
--- a/gnu/packages/patches/mumps-shared-pord.patch
+++ b/gnu/packages/patches/mumps-shared-pord.patch
@@ -24,8 +24,8 @@ Index: mumps/PORD/lib/Makefile
  	$(RANLIB) $@
  
 +libpord$(PLAT).so: $(OBJS)
-+	$(CC) -shared $(OBJS) -Wl,-soname,libpord$(PLAT)-5.1.2.so -o libpord$(PLAT)-5.1.2.so -Wl,-z,defs
-+	ln -s libpord$(PLAT)-5.1.2.so $@
++	$(CC) -shared $(OBJS) -Wl,-soname,libpord$(PLAT)-5.2.1.so -o libpord$(PLAT)-5.2.1.so -Wl,-z,defs
++	ln -s libpord$(PLAT)-5.2.1.so $@
 +
  clean:
  	rm -f *.o
diff --git a/gnu/packages/patches/qtbase-QTBUG-81715.patch b/gnu/packages/patches/qtbase-QTBUG-81715.patch
new file mode 100644
index 0000000000..70b83b97d2
--- /dev/null
+++ b/gnu/packages/patches/qtbase-QTBUG-81715.patch
@@ -0,0 +1,40 @@
+From 8a3fde00bf53d99e9e4853e8ab97b0e1bcf74915 Mon Sep 17 00:00:00 2001
+From: Joerg Bornemann <joerg.bornemann@qt.io>
+Date: Wed, 29 Jan 2020 11:06:35 +0100
+Subject: [PATCH] Fix qt5_make_output_file macro for paths containing dots
+
+Commit 89bd5a7e broke CMake projects that use dots in their build
+paths, because the used regular expression matches the directory part
+of the path as well.
+
+The regex wants to achieve the same as get_filename_component(...
+NAME_WLE) which is available since CMake 3.14. Re-implement the
+NAME_WLE functionality for older CMake versions by using multiple
+get_filename_component calls.
+
+Fixes: QTBUG-81715
+Task-number: QTBUG-80295
+Change-Id: I2ef053300948f6e1b2c0c5eafac35105f193d4e6
+Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
+---
+
+diff --git a/src/corelib/Qt5CoreMacros.cmake b/src/corelib/Qt5CoreMacros.cmake
+index 7735e51..b3da640 100644
+--- a/src/corelib/Qt5CoreMacros.cmake
++++ b/src/corelib/Qt5CoreMacros.cmake
+@@ -59,7 +59,14 @@
+     set(_outfile "${CMAKE_CURRENT_BINARY_DIR}/${rel}")
+     string(REPLACE ".." "__" _outfile ${_outfile})
+     get_filename_component(outpath ${_outfile} PATH)
+-    string(REGEX REPLACE "\\.[^.]*$" "" _outfile ${_outfile})
++    if(CMAKE_VERSION VERSION_LESS "3.14")
++        get_filename_component(_outfile_ext ${_outfile} EXT)
++        get_filename_component(_outfile_ext ${_outfile_ext} NAME_WE)
++        get_filename_component(_outfile ${_outfile} NAME_WE)
++        string(APPEND _outfile ${_outfile_ext})
++    else()
++        get_filename_component(_outfile ${_outfile} NAME_WLE)
++    endif()
+     file(MAKE_DIRECTORY ${outpath})
+     set(${outfile} ${outpath}/${prefix}${_outfile}.${ext})
+ endmacro()
diff --git a/gnu/packages/patches/racket-store-checksum-override.patch b/gnu/packages/patches/racket-store-checksum-override.patch
index 236c843de1..6c4ebcf022 100644
--- a/gnu/packages/patches/racket-store-checksum-override.patch
+++ b/gnu/packages/patches/racket-store-checksum-override.patch
@@ -11,26 +11,15 @@ See <https://debbugs.gnu.org/30680> for details.
 ---
 --- a/collects/compiler/private/cm-minimal.rkt
 +++ b/collects/compiler/private/cm-minimal.rkt
-@@ -7,6 +7,7 @@
+@@ -6,6 +6,7 @@
           racket/list
           racket/path
           racket/promise
 +         racket/string
           file/sha1
-          setup/collects
           setup/cross-system
-@@ -940,6 +941,10 @@
-       #f
-       (list src-hash recorded-hash)))
- 
-+(define (store-reference? path)
-+  (let ([store-prefix (or (getenv "NIX_STORE") "/gnu/store")])
-+    (string-prefix? (path->string path) store-prefix)))
-+
- (define (rkt->ss p)
-   (if (path-has-extension? p #".rkt")
-       (path-replace-extension p #".ss")
-@@ -1015,6 +1020,7 @@
+          compiler/compilation-path
+@@ -268,7 +269,8 @@
                 (trace-printf "newer src... ~a > ~a" path-time path-zo-time)
                 (maybe-compile-zo deps path->mode roots path orig-path read-src-syntax up-to-date collection-cache new-seen
                                   #:trying-sha1? sha1-only?)]
@@ -39,4 +28,15 @@ See <https://debbugs.gnu.org/30680> for details.
 +                    (different-source-sha1-and-dep-recorded path deps))
                 => (lambda (difference)
                      (trace-printf "different src hash ~a for ~a..." difference path)
-                     (maybe-compile-zo deps path->mode roots path orig-path read-src-syntax up-to-date collection-cache new-seen
\ No newline at end of file
+                     (maybe-compile-zo deps path->mode roots path orig-path read-src-syntax up-to-date collection-cache new-seen
+@@ -1012,5 +1014,9 @@
+       #f
+       (list src-hash recorded-hash)))
+
++(define (store-reference? path)
++  (let ([store-prefix (or (getenv "NIX_STORE") "/gnu/store")])
++    (string-prefix? (path->string path) store-prefix)))
++
+ ;; Make sure `recompile-from` is machine-independent so that
+ ;; recompilation makes sense.
+ ;; The compilation lock must is held for the source of `recompile-from`.
\ No newline at end of file
diff --git a/gnu/packages/patches/upx-fix-CVE-2017-15056.patch b/gnu/packages/patches/upx-fix-CVE-2017-15056.patch
deleted file mode 100644
index 525980e73e..0000000000
--- a/gnu/packages/patches/upx-fix-CVE-2017-15056.patch
+++ /dev/null
@@ -1,96 +0,0 @@
-From 3e0c2966dffb5dadb512a476ef4be3d0cc51c2be Mon Sep 17 00:00:00 2001
-From: Pierre Neidhardt <ambrevar@gmail.com>
-Date: Sat, 16 Jun 2018 16:35:00 +0200
-Subject: [PATCH] Protect against bad crafted input
-
-Also check for wrap-around when checking oversize involving e_shoff and e_shnum.
-
-raised by https://github.com/upx/upx/pull/190
-	modified:   p_lx_elf.cpp
----
- src/p_lx_elf.cpp | 30 ++++++++++++++++++++++++++++++
- 1 file changed, 30 insertions(+)
-
-diff --git a/src/p_lx_elf.cpp b/src/p_lx_elf.cpp
-index 822a7652..41e805ee 100644
---- a/src/p_lx_elf.cpp
-+++ b/src/p_lx_elf.cpp
-@@ -235,8 +235,17 @@ PackLinuxElf32::PackLinuxElf32help1(InputFile *f)
-         sz_phdrs = 0;
-         return;
-     }
-+    if (0==e_phnum) throwCantUnpack("0==e_phnum");
-     e_phoff = get_te32(&ehdri.e_phoff);
-+    unsigned const last_Phdr = e_phoff + e_phnum * sizeof(Elf32_Phdr);
-+    if (last_Phdr < e_phoff || (unsigned long)file_size < last_Phdr) {
-+        throwCantUnpack("bad e_phoff");
-+    }
-     e_shoff = get_te32(&ehdri.e_shoff);
-+    unsigned const last_Shdr = e_shoff + e_shnum * sizeof(Elf32_Shdr);
-+    if (last_Shdr < e_shoff || (unsigned long)file_size < last_Shdr) {
-+        throwCantUnpack("bad e_shoff");
-+    }
-     sz_phdrs = e_phnum * e_phentsize;
- 
-     if (f && Elf32_Ehdr::ET_DYN!=e_type) {
-@@ -599,8 +608,17 @@ PackLinuxElf64::PackLinuxElf64help1(InputFile *f)
-         sz_phdrs = 0;
-         return;
-     }
-+    if (0==e_phnum) throwCantUnpack("0==e_phnum");
-     e_phoff = get_te64(&ehdri.e_phoff);
-+    upx_uint64_t const last_Phdr = e_phoff + e_phnum * sizeof(Elf64_Phdr);
-+    if (last_Phdr < e_phoff || (unsigned long)file_size < last_Phdr) {
-+        throwCantUnpack("bad e_phoff");
-+    }
-     e_shoff = get_te64(&ehdri.e_shoff);
-+    upx_uint64_t const last_Shdr = e_shoff + e_shnum * sizeof(Elf64_Shdr);
-+    if (last_Shdr < e_shoff || (unsigned long)file_size < last_Shdr) {
-+        throwCantUnpack("bad e_shoff");
-+    }
-     sz_phdrs = e_phnum * e_phentsize;
- 
-     if (f && Elf64_Ehdr::ET_DYN!=e_type) {
-@@ -3763,6 +3781,9 @@ void PackLinuxElf64::pack4(OutputFile *fo, Filter &ft)
- 
- void PackLinuxElf64::unpack(OutputFile *fo)
- {
-+    if (e_phoff != sizeof(Elf64_Ehdr)) {// Phdrs not contiguous with Ehdr
-+        throwCantUnpack("bad e_phoff");
-+    }
-     unsigned const c_phnum = get_te16(&ehdri.e_phnum);
-     upx_uint64_t old_data_off = 0;
-     upx_uint64_t old_data_len = 0;
-@@ -3828,6 +3849,9 @@ void PackLinuxElf64::unpack(OutputFile *fo)
-     unsigned total_out = 0;
-     unsigned c_adler = upx_adler32(NULL, 0);
-     unsigned u_adler = upx_adler32(NULL, 0);
-+    if ((MAX_ELF_HDR - sizeof(Elf64_Ehdr))/sizeof(Elf64_Phdr) < u_phnum) {
-+        throwCantUnpack("bad compressed e_phnum");
-+    }
- 
-     // Packed ET_EXE has no PT_DYNAMIC.
-     // Packed ET_DYN has original PT_DYNAMIC for info needed by rtld.
-@@ -4383,6 +4407,9 @@ Elf64_Sym const *PackLinuxElf64::elf_lookup(char const *name) const
- 
- void PackLinuxElf32::unpack(OutputFile *fo)
- {
-+    if (e_phoff != sizeof(Elf32_Ehdr)) {// Phdrs not contiguous with Ehdr
-+        throwCantUnpack("bad e_phoff");
-+    }
-     unsigned const c_phnum = get_te16(&ehdri.e_phnum);
-     unsigned old_data_off = 0;
-     unsigned old_data_len = 0;
-@@ -4449,6 +4476,9 @@ void PackLinuxElf32::unpack(OutputFile *fo)
-     unsigned total_out = 0;
-     unsigned c_adler = upx_adler32(NULL, 0);
-     unsigned u_adler = upx_adler32(NULL, 0);
-+    if ((MAX_ELF_HDR - sizeof(Elf32_Ehdr))/sizeof(Elf32_Phdr) < u_phnum) {
-+        throwCantUnpack("bad compressed e_phnum");
-+    }
- 
-     // Packed ET_EXE has no PT_DYNAMIC.
-     // Packed ET_DYN has original PT_DYNAMIC for info needed by rtld.
--- 
-2.17.0
-