summaryrefslogtreecommitdiffstats
path: root/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec
diff options
context:
space:
mode:
Diffstat (limited to 't/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec')
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/control.in16
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/rules7
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/fill-values4
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/Makefile17
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.c13
-rw-r--r--t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.h8
6 files changed, 65 insertions, 0 deletions
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/control.in b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/control.in
new file mode 100644
index 0000000..b4e0958
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/control.in
@@ -0,0 +1,16 @@
+Source: [% $source %]
+Priority: optional
+Section: libs
+Maintainer: [% $author %]
+Standards-Version: [% $standards_version %]
+Build-Depends: [% $build_depends %]
+Rules-Requires-Root: no
+
+Package: libfoo-dev
+Architecture: [% $package_architecture %]
+Section: libdevel
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: [% $description %]
+ This is a test package designed to exercise some feature or tag of
+ Lintian. It is part of the Lintian test suite and may do very odd
+ things. It should not be installed like a regular package.
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/rules b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/rules
new file mode 100644
index 0000000..3a30bc0
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/debian/rules
@@ -0,0 +1,7 @@
+#!/usr/bin/make -f
+
+%:
+ dh $@
+
+override_dh_strip:
+ # Don't strip :)
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/fill-values b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/fill-values
new file mode 100644
index 0000000..ff04e62
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/fill-values
@@ -0,0 +1,4 @@
+Testname: without-fat-lto-objects
+Package-Architecture: any
+Skeleton: upload-non-native
+Description: Static library built with -flto=auto, but without -ffat-lto-objects
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/Makefile b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/Makefile
new file mode 100644
index 0000000..6b1fa78
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/Makefile
@@ -0,0 +1,17 @@
+CC=gcc
+CFLAGS+= -g -flto=auto
+LIBFILES:= libcodeless.a
+
+all: $(LIBFILES)
+
+libcodeless.a: code.o
+ ar rcs -o $@ $^
+
+clean:
+ rm -f *.a *.o
+
+install: all
+ install -m 0755 -d $(DESTDIR)/usr/lib
+ install -m 0644 *.a $(DESTDIR)/usr/lib
+
+.PHONY: install clean
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.c b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.c
new file mode 100644
index 0000000..7bba112
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.c
@@ -0,0 +1,13 @@
+#include <stdlib.h>
+#include <math.h>
+#include "code.h"
+
+double e(void (*f)(char *)){
+ char tmp[10];
+ double x;
+ f(tmp);
+ x = atof(tmp);
+ return exp(x);
+}
+
+
diff --git a/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.h b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.h
new file mode 100644
index 0000000..570beae
--- /dev/null
+++ b/t/recipes/checks/libraries/static/no-code/without-fat-lto-objects/build-spec/orig/code.h
@@ -0,0 +1,8 @@
+#ifndef CODE_H_
+#define CODE_H_
+
+double e(void (*f)(char *));
+
+double energy(double mass);
+
+#endif