summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sci-libs/cqrlib/Manifest1
-rw-r--r--sci-libs/cqrlib/cqrlib-1.1.4.ebuild50
-rw-r--r--sci-libs/cqrlib/files/1.1.4-build.patch331
-rw-r--r--sci-libs/cqrlib/files/1.1.4-libtool.patch105
4 files changed, 487 insertions, 0 deletions
diff --git a/sci-libs/cqrlib/Manifest b/sci-libs/cqrlib/Manifest
index f559d9c22b4c..a7cd3700a1ae 100644
--- a/sci-libs/cqrlib/Manifest
+++ b/sci-libs/cqrlib/Manifest
@@ -1 +1,2 @@
DIST CQRlib-1.1.3.tar.gz 93987 BLAKE2B d95dc83f92c322fe6185c8a9989d4814bcae95ac870c2555c5cce0e4279a676180050b0e23bc29cc1032f3ee7a7e2ccc8bbe75be7dba4e336a27afda532aadc4 SHA512 49ee134171bc4736513556781cc978599a3017c0692cf48fba876b2cf8d846ff9b1bbce41c0beba3836701de0dc00d987142253683cd9c1da71586435a5c4010
+DIST cqrlib-1.1.4.tar.gz 41521 BLAKE2B 2b69dbf401de9908886798425ec33c28c55ef4b892d35883ffe3c715ddff03fb81b32222b6c755c3c690a016b2ded72e965d83408f14b316913e6f8c7ebb5a41 SHA512 14f49ebc5f562b31081cd53c738aa1571cbefb369ebfe4ca8c27af07a691e4eae288fcf374527453b8d6e36a114a97be26204909be478bd67fb8d94934b1bec7
diff --git a/sci-libs/cqrlib/cqrlib-1.1.4.ebuild b/sci-libs/cqrlib/cqrlib-1.1.4.ebuild
new file mode 100644
index 000000000000..525ebb014f17
--- /dev/null
+++ b/sci-libs/cqrlib/cqrlib-1.1.4.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+MY_PN=CQRlib
+MY_P="${MY_PN}-${PV}"
+
+DESCRIPTION="Utility library for quaternion arithmetic / rotation math (ANSI C implemented)"
+HOMEPAGE="http://cqrlib.sourceforge.net/"
+SRC_URI="https://github.com/yayahjb/${PN}/archive/${MY_P}/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux"
+IUSE=""
+
+RDEPEND="dev-libs/cvector"
+DEPEND="${RDEPEND}"
+
+DOCS=( README_CQRlib.txt )
+HTML_DOCS=( README_CQRlib.html )
+
+S="${WORKDIR}"/${PN}-${MY_P}
+
+PATCHES=(
+ "${FILESDIR}/${PV}-libtool.patch" # 778911
+ "${FILESDIR}/${PV}-build.patch"
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_compile() {
+ emake all
+}
+
+src_test() {
+ emake tests
+}
+
+src_install() {
+ emake install DESTDIR="${D}"
+ einstalldocs
+ find "${D}" -name '*.la' -delete || die
+}
diff --git a/sci-libs/cqrlib/files/1.1.4-build.patch b/sci-libs/cqrlib/files/1.1.4-build.patch
new file mode 100644
index 000000000000..d7b20e33338e
--- /dev/null
+++ b/sci-libs/cqrlib/files/1.1.4-build.patch
@@ -0,0 +1,331 @@
+Upstream-PR: https://github.com/yayahjb/cqrlib/pull/1
+
+From d1a82913a39168bb6d519fd7d2e14e23f4e9f291 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sat, 18 Jun 2022 23:39:18 -0700
+Subject: [PATCH 1/7] build: Fix parallel make
+
+The build will fail with slibtool when the required directories do not
+yet exist. This is because slibtool is significantly faster than GNU
+libtool...
+---
+ Makefile.in | 26 ++++++++------------------
+ 1 file changed, 8 insertions(+), 18 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index fe556ff..59a508e 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -189,12 +189,13 @@ default:
+ #
+ # Compile the library and examples
+ #
+-all: $(LIB) $(BIN) $(SOURCE) $(HEADERS) \
++all: $(LIB)/.tag $(BIN)/.tag $(SOURCE) $(HEADERS) \
+ $(LIB)/libCQRlib.$(LIB_EXT) \
+ $(BIN)/CQRlibTest $(BIN)/CPPQRTest
+
+-install: all $(INSTALLDIR) $(INSTALLDIR)/lib $(INSTALLDIR)/include \
+- $(INC) $(LIB)/libCQRlib.$(LIB_EXT) $(INC)/cqrlib.h
++install: all $(LIB)/libCQRlib.$(LIB_EXT) $(INC)/cqrlib.h
++ @mkdir -p $(INSTALLDIR)/lib
++ @mkdir -p $(INSTALLDIR)/include
+ $(INSTALL_COMMAND) $(LIB)/libCQRlib.$(LIB_EXT) $(INSTALLDIR)/lib/libCQRlib.$(LIB_EXT)
+ $(INSTALL_FINISH_COMMAND) $(INSTALLDIR)/lib/libCQRlib.$(LIB_EXT)
+ -cp $(INSTALLDIR)/include/cqrlib.h $(INSTALLDIR)/include/CQRlib_old.h
+@@ -228,24 +229,13 @@ install: all $(INSTALLDIR) $(INSTALLDIR)/lib $(INSTALLDIR)/include \
+ #
+ # Directories
+ #
+-$(INSTALLDIR):
+- mkdir -p $(INSTALLDIR)
+-
+-$(INSTALLDIR)/lib: $(INSTALLDIR)
+- mkdir -p $(INSTALLDIR)/lib
+-
+-$(INSTALLDIR)/bin: $(INSTALLDIR)
+- mkdir -p $(INSTALLDIR)/bin
+-
+-$(INSTALLDIR)/include: $(INSTALLDIR)
+- mkdir -p $(INSTALLDIR)/include
+-
+-
+-$(LIB):
++$(LIB)/.tag:
+ mkdir $(LIB)
++ @touch $@
+
+-$(BIN):
++$(BIN)/.tag:
+ mkdir $(BIN)
++ @touch $@
+
+ #
+ # CQRlib library
+
+From 3cdf6a442228d63c8f771fc0822d74d75fe8b486 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sat, 18 Jun 2022 23:40:46 -0700
+Subject: [PATCH 2/7] build: Use the .la file to link
+
+The correct way to link with internal dependencies and libtool is to use
+the .la files. When using the linker flag directly the build will fail
+with slibtool when it doesn't know where the required library is
+located.
+---
+ Makefile.in | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 59a508e..ab21e89 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -203,13 +203,13 @@ install: all $(LIB)/libCQRlib.$(LIB_EXT) $(INC)/cqrlib.h
+ chmod 644 $(INSTALLDIR)/include/cqrlib.h
+ echo "Testing final install dynamic"
+ $(BUILD_COMMAND_DYNAMIC) $(EXAMPLES)/CQRlibTest.c \
+- -lCQRlib -lm -o $(BIN)/CQRlibTest_dynamic
++ $(LIB)/libCQRlib.la -lm -o $(BIN)/CQRlibTest_dynamic
+ $(BIN)/CQRlibTest_dynamic > $(TESTDATA)/CQRlibTest_dynamic.lst
+ diff -b -c $(TESTDATA)/CQRlibTest_orig.lst \
+ $(TESTDATA)/CQRlibTest_dynamic.lst
+ echo "Testing final install static"
+ $(BUILD_COMMAND_STATIC) $(EXAMPLES)/CQRlibTest.c \
+- -lCQRlib -lm -o $(BIN)/CQRlibTest_static
++ $(LIB)/libCQRlib.la -lm -o $(BIN)/CQRlibTest_static
+ $(BIN)/CQRlibTest_static > $(TESTDATA)/CQRlibTest_static.lst
+ diff -b -c $(TESTDATA)/CQRlibTest_orig.lst \
+ $(TESTDATA)/CQRlibTest_static.lst
+
+From b81e63099004e53f1bfd984f00a4b878485b13b1 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sat, 18 Jun 2022 23:59:24 -0700
+Subject: [PATCH 3/7] build: Use standard install variables
+
+---
+ Makefile.in | 40 ++++++++++++++++++++++------------------
+ 1 file changed, 22 insertions(+), 18 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index ab21e89..22e1ffd 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -72,8 +72,12 @@ SRC = $(top_builddir)
+ INC = $(top_builddir)
+ EXAMPLES = $(top_builddir)
+ TESTDATA = $(top_builddir)
+-#INSTALLDIR = /usr/local
+-INSTALLDIR = $(HOME)
++
++prefix := @prefix@
++exec_prefix := @exec_prefix@
++
++LIBDIR := @libdir@
++INCDIR := @includedir@
+
+ #
+ # Include directories
+@@ -85,15 +89,15 @@ INCLUDES = -I$(INC)
+ endif
+
+ COMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) $(INCLUDES) $(WARNINGS) -c
+-LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(INSTALLDIR)/lib
++LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR)
+ BUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(INCLUDES)
+-BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -dynamic -I $(INSTALLDIR)/include -L$(INSTALLDIR)/lib
+-BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -static -I $(INSTALLDIR)/include -L$(INSTALLDIR)/lib
++BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -dynamic $(INCLUDES)
++BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -static $(INCLUDES)
+ CPPCOMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CXX) $(CPPFLAGS) $(INCLUDES) $(WARNINGS) -c
+-CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(INSTALLDIR)/lib
++CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(LIBDIR)
+ CPPBUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) $(INCLUDES)
+-CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -dynamic -I $(INSTALLDIR)/include -L$(INSTALLDIR)/lib
+-CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -static -I $(INSTALLDIR)/include -L$(INSTALLDIR)/lib
++CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -dynamic $(INCLUDES)
++CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -static $(INCLUDES)
+ INSTALL_COMMAND = $(LIBTOOL) --mode=install cp
+ INSTALL_FINISH_COMMAND = $(LIBTOOL) --mode=finish
+
+@@ -162,9 +166,9 @@ default:
+ @echo ' '
+ @echo ' The current values are :'
+ @echo ' '
+- @echo ' $(INSTALLDIR) '
+- @echo ' $(INSTALL_COMMAND) '
+- @echo ' $(INSTALL_FINISH) '
++ @echo ' $(DESTDIR) '
++ @echo ' $(INSTALL_COMMAND) '
++ @echo ' $(INSTALL_FINISH) '
+ @echo ' '
+ @echo ' To compile the CQRlib library and example programs type:'
+ @echo ' '
+@@ -194,13 +198,13 @@ all: $(LIB)/.tag $(BIN)/.tag $(SOURCE) $(HEADERS) \
+ $(BIN)/CQRlibTest $(BIN)/CPPQRTest
+
+ install: all $(LIB)/libCQRlib.$(LIB_EXT) $(INC)/cqrlib.h
+- @mkdir -p $(INSTALLDIR)/lib
+- @mkdir -p $(INSTALLDIR)/include
+- $(INSTALL_COMMAND) $(LIB)/libCQRlib.$(LIB_EXT) $(INSTALLDIR)/lib/libCQRlib.$(LIB_EXT)
+- $(INSTALL_FINISH_COMMAND) $(INSTALLDIR)/lib/libCQRlib.$(LIB_EXT)
+- -cp $(INSTALLDIR)/include/cqrlib.h $(INSTALLDIR)/include/CQRlib_old.h
+- cp $(INC)/cqrlib.h $(INSTALLDIR)/include/cqrlib.h
+- chmod 644 $(INSTALLDIR)/include/cqrlib.h
++ @mkdir -p $(DESTDIR)$(INCDIR)
++ @mkdir -p $(DESTDIR)$(LIBDIR)
++ $(INSTALL_COMMAND) $(LIB)/libCQRlib.$(LIB_EXT) $(DESTDIR)$(LIBDIR)/libCQRlib.$(LIB_EXT)
++ $(INSTALL_FINISH_COMMAND) $(DESTDIR)$(LIBDIR)/libCQRlib.$(LIB_EXT)
++ -cp $(DESTDIR)$(INCDIR)/cqrlib.h $(DESTDIR)$(INCDIR)/CQRlib_old.h
++ cp $(INC)/cqrlib.h $(DESTDIR)$(INCDIR)/cqrlib.h
++ chmod 644 $(DESTDIR)$(INCDIR)/cqrlib.h
+ echo "Testing final install dynamic"
+ $(BUILD_COMMAND_DYNAMIC) $(EXAMPLES)/CQRlibTest.c \
+ $(LIB)/libCQRlib.la -lm -o $(BIN)/CQRlibTest_dynamic
+
+From f3f780c5504b0f689a37062bb8820a638e0abeb6 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sun, 19 Jun 2022 00:04:58 -0700
+Subject: [PATCH 4/7] build: Support LDFLAGS
+
+---
+ Makefile.in | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 22e1ffd..192aef9 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -49,6 +49,7 @@ CC = @CC@
+ CXX = @CXX@
+ CFLAGS = -g -O2 -Wall -ansi -pedantic
+ CPPFLAGS = $(CFLAGS) -DCQR_NOCCODE=1
++LDFLAGS = @LDFLAGS@
+
+ # Build directory
+ top_builddir = @top_builddir@
+@@ -89,12 +90,12 @@ INCLUDES = -I$(INC)
+ endif
+
+ COMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) $(INCLUDES) $(WARNINGS) -c
+-LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR)
++LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+ BUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(INCLUDES)
+ BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -dynamic $(INCLUDES)
+ BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -static $(INCLUDES)
+ CPPCOMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CXX) $(CPPFLAGS) $(INCLUDES) $(WARNINGS) -c
+-CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(LIBDIR)
++CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+ CPPBUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) $(INCLUDES)
+ CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -dynamic $(INCLUDES)
+ CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -static $(INCLUDES)
+
+From dd4f0a4fb0cd30a472140cd1c3a3b35b1bb063a4 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sun, 19 Jun 2022 00:36:06 -0700
+Subject: [PATCH 5/7] build: Fix make install
+
+---
+ Makefile.in | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 192aef9..3613e37 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -203,7 +203,6 @@ install: all $(LIB)/libCQRlib.$(LIB_EXT) $(INC)/cqrlib.h
+ @mkdir -p $(DESTDIR)$(LIBDIR)
+ $(INSTALL_COMMAND) $(LIB)/libCQRlib.$(LIB_EXT) $(DESTDIR)$(LIBDIR)/libCQRlib.$(LIB_EXT)
+ $(INSTALL_FINISH_COMMAND) $(DESTDIR)$(LIBDIR)/libCQRlib.$(LIB_EXT)
+- -cp $(DESTDIR)$(INCDIR)/cqrlib.h $(DESTDIR)$(INCDIR)/CQRlib_old.h
+ cp $(INC)/cqrlib.h $(DESTDIR)$(INCDIR)/cqrlib.h
+ chmod 644 $(DESTDIR)$(INCDIR)/cqrlib.h
+ echo "Testing final install dynamic"
+
+From 59b95069aab8885919c8b91c825c14384c3d8087 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sun, 19 Jun 2022 20:09:46 -0700
+Subject: [PATCH 6/7] build: Fix compile flags
+
+This sets the compile flags using the configure process and changes
+CPPFLAGS to CXXFLAGS as is standard. CPPFLAGS is also supported now
+which are for setting defines for both C and CXX builds.
+---
+ Makefile.in | 27 ++++++++++++++++-----------
+ 1 file changed, 16 insertions(+), 11 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 3613e37..e4c6942 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -47,8 +47,10 @@ RELEASE = @PACKAGE_VERSION@
+ #
+ CC = @CC@
+ CXX = @CXX@
+-CFLAGS = -g -O2 -Wall -ansi -pedantic
+-CPPFLAGS = $(CFLAGS) -DCQR_NOCCODE=1
++CFLAGS = @CFLAGS@
++CXXFLAGS = @CXXFLAGS@
++CPPFLAGS = @CPPFLAGS@
++WARNINGS = -Wall -ansi -pedantic
+ LDFLAGS = @LDFLAGS@
+
+ # Build directory
+@@ -89,16 +91,19 @@ else
+ INCLUDES = -I$(INC)
+ endif
+
+-COMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) $(INCLUDES) $(WARNINGS) -c
+-LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+-BUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(INCLUDES)
+-BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -dynamic $(INCLUDES)
+-BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -static $(INCLUDES)
+-CPPCOMPILE_COMMAND = $(LIBTOOL) --mode=compile $(CXX) $(CPPFLAGS) $(INCLUDES) $(WARNINGS) -c
++COMPILE_C = $(CC) -std=c90 $(WARNINGS) $(CPPFLAGS) $(CFLAGS)
++COMPILE_CXX = $(CXX) -std=c++98 $(WARNINGS) $(CPPFLAGS) -DCQR_NOCCODE=1 $(CXXFLAGS)
++
++COMPILE_COMMAND = $(LIBTOOL) --mode=compile $(COMPILE_C) $(INCLUDES) -c
++LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
++BUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(COMPILE_C) $(INCLUDES)
++BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(COMPILE_C) -dynamic $(INCLUDES)
++BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(COMPILE_C) -static $(INCLUDES)
++CPPCOMPILE_COMMAND = $(LIBTOOL) --mode=compile $(COMPILE_CXX) $(INCLUDES) -c
+ CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+-CPPBUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) $(INCLUDES)
+-CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -dynamic $(INCLUDES)
+-CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(CXX) $(CPPFLAGS) -static $(INCLUDES)
++CPPBUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(COMPILE_CXX) $(INCLUDES)
++CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(COMPILE_CXX) -dynamic $(INCLUDES)
++CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(COMPILE_CXX) -static $(INCLUDES)
+ INSTALL_COMMAND = $(LIBTOOL) --mode=install cp
+ INSTALL_FINISH_COMMAND = $(LIBTOOL) --mode=finish
+
+
+From 87cd184f4df7188380251346dcda502fa21f8cdd Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sun, 19 Jun 2022 20:28:48 -0700
+Subject: [PATCH 7/7] build: Change -dynamic to -shared
+
+With libtool shared libraries can be created with -shared.
+---
+ Makefile.in | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index e4c6942..9b407c1 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -97,12 +97,12 @@ COMPILE_CXX = $(CXX) -std=c++98 $(WARNINGS) $(CPPFLAGS) -DCQR_NOCCODE=1 $(CXXFLA
+ COMPILE_COMMAND = $(LIBTOOL) --mode=compile $(COMPILE_C) $(INCLUDES) -c
+ LIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CC) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+ BUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(COMPILE_C) $(INCLUDES)
+-BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(COMPILE_C) -dynamic $(INCLUDES)
++BUILD_COMMAND_DYNAMIC = $(LIBTOOL) --mode=link $(COMPILE_C) -shared $(INCLUDES)
+ BUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(COMPILE_C) -static $(INCLUDES)
+ CPPCOMPILE_COMMAND = $(LIBTOOL) --mode=compile $(COMPILE_CXX) $(INCLUDES) -c
+ CPPLIBRARY_LINK_COMMAND = $(LIBTOOL) --mode=link $(CXX) -version-info $(VERSION) -rpath $(LIBDIR) $(LDFLAGS)
+ CPPBUILD_COMMAND_LOCAL = $(LIBTOOL) --mode=link $(COMPILE_CXX) $(INCLUDES)
+-CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(COMPILE_CXX) -dynamic $(INCLUDES)
++CPPBUILD_COMMAND_DYNAMIC= $(LIBTOOL) --mode=link $(COMPILE_CXX) -shared $(INCLUDES)
+ CPPBUILD_COMMAND_STATIC = $(LIBTOOL) --mode=link $(COMPILE_CXX) -static $(INCLUDES)
+ INSTALL_COMMAND = $(LIBTOOL) --mode=install cp
+ INSTALL_FINISH_COMMAND = $(LIBTOOL) --mode=finish
diff --git a/sci-libs/cqrlib/files/1.1.4-libtool.patch b/sci-libs/cqrlib/files/1.1.4-libtool.patch
new file mode 100644
index 000000000000..da189845f0e5
--- /dev/null
+++ b/sci-libs/cqrlib/files/1.1.4-libtool.patch
@@ -0,0 +1,105 @@
+Bug: https://bugs.gentoo.org/778911
+Upstream-PR: https://github.com/yayahjb/cqrlib/pull/1
+
+From 23f422c3049185ad0f24b9f0317b52a21ea771f3 Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Sat, 18 Jun 2022 23:02:44 -0700
+Subject: [PATCH] build: Add minimal configure.ac
+
+When building with slibtool using the rlibtool symlink the build will
+fail when it fails to find the generated libtool. This file is required
+for rlibtool because it is used to determine if building shared or
+static.
+
+This will require these commands to build:
+
+ autoreconf -fi
+ ./configure
+ make
+
+Gentoo Bug: https://bugs.gentoo.org/778911
+---
+ Makefile => Makefile.in | 29 +++++++++++++----------------
+ configure.ac | 10 ++++++++++
+ 2 files changed, 23 insertions(+), 16 deletions(-)
+ rename Makefile => Makefile.in (97%)
+ create mode 100644 configure.ac
+
+diff --git a/Makefile b/Makefile.in
+similarity index 97%
+rename from Makefile
+rename to Makefile.in
+index 555e370..fe556ff 100644
+--- a/Makefile
++++ b/Makefile.in
+@@ -40,41 +40,38 @@
+
+ # Version string
+ VERSION = 3:0:1
+-RELEASE = 1.1.0
+-
++RELEASE = @PACKAGE_VERSION@
+
+ #
+ # Compiler and compilation flags
+ #
+-CC = gcc
+-CXX = g++
++CC = @CC@
++CXX = @CXX@
+ CFLAGS = -g -O2 -Wall -ansi -pedantic
+ CPPFLAGS = $(CFLAGS) -DCQR_NOCCODE=1
+
++# Build directory
++top_builddir = @top_builddir@
++
+ #
+ # libtool path if system default is not suitable
+ #
+-#LIBTOOL = $(HOME)/bin/libtool
+-ifndef LIBTOOL
+- LIBTOOL = libtool
+-endif
++LIBTOOL = @LIBTOOL@
+
+ #
+ # If local headers must be quoted uncomment the next line
+ #
+ #USE_LOCAL_HEADERS = 1
+
+-
+ #
+ # Directories
+ #
+-ROOT = .
+-LIB = $(ROOT)/lib
+-BIN = $(ROOT)/bin
+-SRC = $(ROOT)
+-INC = $(ROOT)
+-EXAMPLES = $(ROOT)
+-TESTDATA = $(ROOT)
++LIB = $(top_builddir)/lib
++BIN = $(top_builddir)/bin
++SRC = $(top_builddir)
++INC = $(top_builddir)
++EXAMPLES = $(top_builddir)
++TESTDATA = $(top_builddir)
+ #INSTALLDIR = /usr/local
+ INSTALLDIR = $(HOME)
+
+diff --git a/configure.ac b/configure.ac
+new file mode 100644
+index 0000000..6af5b28
+--- /dev/null
++++ b/configure.ac
+@@ -0,0 +1,10 @@
++AC_INIT([cqrlib], [1.1.4])
++AC_CONFIG_FILES([Makefile])
++
++LT_INIT
++
++AC_PROG_CXX
++
++AC_SUBST([top_builddir], [$abs_builddir])
++
++AC_OUTPUT