aboutsummaryrefslogtreecommitdiffhomepage
path: root/debian/patches/cross.patch
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2024-02-26 11:27:32 +0800
committerSean Whitton <spwhitton@spwhitton.name>2024-02-26 11:27:32 +0800
commit38433ea622db2bd04435232251007d25c84ec54c (patch)
tree15ab06824cc4803d87420b7c018d6b6616b6d9ed /debian/patches/cross.patch
parentbad14fb1ddbcfb4fe7cb574b427f1fac80fa4ac7 (diff)
downloadzxcvbn-c-38433ea622db2bd04435232251007d25c84ec54c.tar.gz
Commit patch queue (exported by git-debrebase)
[git-debrebase make-patches: export and commit patches]
Diffstat (limited to 'debian/patches/cross.patch')
-rw-r--r--debian/patches/cross.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/debian/patches/cross.patch b/debian/patches/cross.patch
new file mode 100644
index 0000000..704b7fa
--- /dev/null
+++ b/debian/patches/cross.patch
@@ -0,0 +1,29 @@
+From: Helmut Grohne <helmut@subdivi.de>
+Date: Sun, 25 Mar 2018 13:36:47 +0200
+Subject: fix crossbuilding zxcvbn-c
+
+---
+ makefile | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/makefile b/makefile
+index 399bccc..5e8ea98 100644
+--- a/makefile
++++ b/makefile
+@@ -5,6 +5,7 @@ CXXFLAGS ?= -O2 -Wall -Wextra
+ CC ?= gcc
+ AR ?= ar
+ CXX ?= g++
++CXX_FOR_BUILD ?= $(CXX)
+
+ # need zxcvbn.h prior to package installation
+ CPPFLAGS += -I.
+@@ -61,7 +62,7 @@ dict-crc.h: dictgen $(WORDS)
+ ./dictgen -b -o zxcvbn.dict -h dict-crc.h $(WORDS)
+
+ dictgen: dict-generate.cpp makefile
+- $(CXX) $(CPPFLAGS) -std=c++11 $(CXXFLAGS) \
++ $(CXX_FOR_BUILD) $(CPPFLAGS) -std=c++11 $(CXXFLAGS) \
+ -o dictgen dict-generate.cpp $(LDFLAGS)
+
+ test-c++inline: test.c zxcvbn-c++inline.o