summaryrefslogtreecommitdiffstats
path: root/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:42:30 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-14 13:42:30 +0000
commit75808db17caf8b960b351e3408e74142f4c85aac (patch)
tree7989e9c09a4240248bf4658a22208a0a52d991c4 /t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig
parentInitial commit. (diff)
downloadlintian-75808db17caf8b960b351e3408e74142f4c85aac.tar.xz
lintian-75808db17caf8b960b351e3408e74142f4c85aac.zip
Adding upstream version 2.117.0.upstream/2.117.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 't/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig')
-rw-r--r--t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/Makefile33
-rw-r--r--t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/hello.c26
2 files changed, 59 insertions, 0 deletions
diff --git a/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/Makefile b/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/Makefile
new file mode 100644
index 0000000..ddd8290
--- /dev/null
+++ b/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/Makefile
@@ -0,0 +1,33 @@
+MINGWCC = x86_64-w64-mingw32-gcc
+
+sources = hello.c
+safe = hello64.exe
+
+staticbase = $(patsubst %.exe,%-static-base.exe,$(safe))
+dataexecution = $(patsubst %.exe,%-data-execution.exe,$(safe))
+unsafeseh = $(patsubst %.exe,%-unsafe-seh.exe,$(safe))
+
+all: $(safe) $(staticbase) $(dataexecution) $(unsafeseh)
+
+$(safe): $(sources)
+ $(MINGWCC) -o $@ $^
+ genpeimg -d +d $@
+ genpeimg -d +n $@
+ genpeimg -d -s $@
+
+$(staticbase): $(safe)
+ cp $< $@
+ genpeimg -d -d $@
+
+$(dataexecution): $(safe)
+ cp $< $@
+ genpeimg -d -n $@
+
+$(unsafeseh): $(safe)
+ cp $< $@
+ # SEH is inverted
+ genpeimg -d +s $@
+
+.PHONY: clean
+clean:
+ rm -f $(safe) $(staticbase) $(dataexecution) $(unsafeseh)
diff --git a/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/hello.c b/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/hello.c
new file mode 100644
index 0000000..7085b1e
--- /dev/null
+++ b/t/recipes/checks/pe/missing-security-features-64-bit/build-spec/orig/hello.c
@@ -0,0 +1,26 @@
+/* Copyright (C) 2019 Felix Lechner
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, you can find it on the World Wide
+ Web at https://www.gnu.org/copyleft/gpl.html, or write to the Free
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+ MA 02110-1301, USA
+*/
+
+#include <stdio.h>
+
+int main(void){
+
+ printf("Hello, Lintian!\n");
+ return 0;
+}