summaryrefslogtreecommitdiffstats
path: root/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec
diff options
context:
space:
mode:
Diffstat (limited to 't/recipes/checks/binaries/prerequisites/legacy-debug/build-spec')
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/_symbols23
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/changelog.in13
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/compat.in1
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/control85
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/copyright4
-rwxr-xr-xt/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/rules99
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/fill-values6
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/hello.c9
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.c7
-rw-r--r--t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.h1
10 files changed, 248 insertions, 0 deletions
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/_symbols b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/_symbols
new file mode 100644
index 0000000..46e6af1
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/_symbols
@@ -0,0 +1,23 @@
+ This line should flag a syntax error
+# but this one shouldn't
+| although this one should, but for a different reason
+ and so should this
+
+libhello.so.0 libhello0 #MINVER#
+| libhello0c2 (>= 1.2) , libhelloc0c2 (<< 1.3)
+| hello-dbg3| libhelloc0c3|foobar (= 1.2) |hello-dbg2
+| hello-dbg
+ hello@Base 1.0
+* Build-Dep-Foo: bar
+ hello2@Base 2.0 4
+ hello3@Base 2.0 1
+ hello3@Base 2.0 A
+ dummy
+
+libhello.so.2 libhello2 #MINVER#
+* Build-Depends-Package: libbar
+| libhello2 (>= 1:2.3)
+ hello@Base 2.0
+
+libhello.so.0 libhello0 #MINVER#
+ duplicate@Base 1.0
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/changelog.in b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/changelog.in
new file mode 100644
index 0000000..02da925
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/changelog.in
@@ -0,0 +1,13 @@
+debug ([% $version %]) [% $distribution %]; urgency=low
+
+ * NMU.
+ (uploaded by the maintainer and with repeated version number)
+
+ -- Russ Allbery <rra@debian.org> Tue, 4 Apr 2006 20:27:22 +0000
+
+debug (1.0) unstable; urgency=low
+
+ * Initial version.
+
+ -- Russ Allbery <rra@debian.org> Sat, 4 Mar 2006 21:31:06 -0800
+
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/compat.in b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/compat.in
new file mode 100644
index 0000000..640a566
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/compat.in
@@ -0,0 +1 @@
+[% $dh_compat_level %]
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/control b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/control
new file mode 100644
index 0000000..fcb2b86
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/control
@@ -0,0 +1,85 @@
+Source: debug
+Section: utils
+Priority: optional
+Maintainer: Russ Allbery <rra@debian.org>
+Build-Depends: debhelper (>= 5.0.0)
+Build-Depends-Indep: not-debhelper (>= 0.4.3)
+Standards-Version: 3.7.0
+
+Package: hello
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: Test for external debugging information
+ Lintian regression test for external debugging file handling. This test
+ contains the binary.
+ .
+ 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.
+
+Package: hello-dbg
+Priority: optional
+Section: debug
+Architecture: any
+Depends: hello (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
+Description: Test for external debugging information (symbols)
+ Lintian regression test for external debugging file handling. This test
+ contains the binary symbols.
+ .
+ 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.
+
+Package: libhello0
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: Test for external debugging information (library)
+ Lintian regression test for external debugging file handling. This test
+ contains a library.
+ .
+ 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.
+
+Package: libhello0-dbg
+Section: debug
+Priority: optional
+Architecture: any
+Depends: libhello (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
+Description: Test for external debugging information (library symbols)
+ Lintian regression test for external debugging file handling. This test
+ contains the library symbols.
+ .
+ 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.
+
+Package: hi-dbg
+Section: debug
+Priority: optional
+Architecture: any
+Depends: foo-pkg, not-libhello0
+Description: Test for external debugging symbols
+ Lintian regression test for external debugging files handling. This test
+ contains the library symbols.
+ .
+ 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. It may
+ be an empty package.
+
+Package: hello-hello-dbg
+Section: debug
+Priority: optional
+Architecture: any
+Depends: foo-pkg, not-libhello0, hello
+Description: Test for external debugging symbols - another try
+ Lintian regression test for external debugging files handling. This test
+ contains the library symbols. This package actually tests a combination of
+ the above.
+ .
+ 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. It may
+ be an empty package.
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/copyright b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/copyright
new file mode 100644
index 0000000..5d4f6c2
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/copyright
@@ -0,0 +1,4 @@
+Written Sat, 04 Mar 2006 21:30:01 -0800 by Russ Allbery <rra@debian.org>.
+
+Test for copyright in capital letters. (#464992)
+COPYRIGHT RUSS ALLBERY 2006
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/rules b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/rules
new file mode 100755
index 0000000..b659895
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/debian/rules
@@ -0,0 +1,99 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# This file is public domain software, originally written by Joey Hess.
+
+# turn off PIE in CC in case we have a PIEful toolchain:
+ifneq ($(findstring -no-pie,$(shell gcc -no-pie 2>&1)),)
+ CC := gcc
+else
+ CC := gcc -fno-pie -no-pie
+endif
+
+build-indep:
+
+build-arch: build-stamp
+
+build-stamp:
+ dh_testdir
+ $(CC) -D_REENTRANT -fPIC -c libhello.c
+ $(CC) -o libhello.so.0.0 -shared -Wl,-soname,libhello.so.0 libhello.o
+ ln -s libhello.so.0.0 libhello.so
+ $(CC) -o hello hello.c -L. -lhello
+ touch build-stamp
+
+build: build-arch build-indep
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-stamp *.o libhello.so.0.0 libhello.so
+ dh_clean
+
+install: build-stamp
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+ install -D hello $(CURDIR)/debian/hello/usr/bin/hello
+ install -D libhello.so.0.0 \
+ $(CURDIR)/debian/libhello0/usr/lib/libhello.so.0.0
+ ln -s libhello.so.0.0 \
+ $(CURDIR)/debian/libhello0/usr/lib/libhello.so.0
+
+# Build architecture-dependent files here.
+export DH_OPTIONS
+binary-arch: DH_OPTIONS=-a
+binary-arch: build-stamp install
+ dh_testdir
+ dh_testroot
+ dh_installchangelogs -N hello-dbg
+ dh_installdocs
+ DH_OPTIONS= dh_strip -phello --dbg-package=hello-dbg
+ DH_OPTIONS= dh_strip -plibhello0 --dbg-package=libhello0-dbg
+
+ # Now break a few things. Copy the debugging data into places it
+ # shouldn't be.
+ cp $(CURDIR)/debian/hello-dbg/usr/lib/debug/usr/bin/hello \
+ $(CURDIR)/debian/hello/usr/bin/hello.dbg
+ cp $(CURDIR)/debian/libhello0-dbg/usr/lib/debug/usr/lib/libhello.so.0.0 \
+ $(CURDIR)/debian/libhello0-dbg/usr/lib/libhello.so.dbg
+
+ # Put a full copy of the library in libhello0-dbg in /usr/lib/debug,
+ # which is okay.
+ install -m 644 libhello.so.0.0 \
+ $(CURDIR)/debian/libhello0-dbg/usr/lib/debug/libhello.so.0.0
+
+ # Also put it in /usr/lib/debug/lib, which isn't.
+ install -D -m 644 libhello.so.0.0 \
+ $(CURDIR)/debian/libhello0-dbg/usr/lib/debug/lib/libhello.so.0.0
+
+ # Requires a versioned dependency.
+ dh_icons
+
+ dh_link
+ dh_compress
+ dh_fixperms
+ dh_makeshlibs -X debug
+ dh_installdeb
+ dh_shlibdeps -X debug
+
+ # We do this by hand as otherwise dpkg-gensymbols
+ # will error due to the broken symbols file
+ # and abort the build; similarly the file in
+ # the source tree is _symbols so that dpkg
+ # doesn't attempt to sanity check it
+ install -d $(CURDIR)/debian/libhello0/DEBIAN
+ install -m 644 $(CURDIR)/debian/_symbols \
+ $(CURDIR)/debian/libhello0/DEBIAN/symbols
+ # hello doesn't contain any shlibs, but we
+ # make it contain a symbols file
+ install -d $(CURDIR)/debian/hello/DEBIAN
+ install -m 644 $(CURDIR)/debian/_symbols \
+ $(CURDIR)/debian/hello/DEBIAN/symbols
+
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+
+binary-indep:
+binary: binary-indep binary-arch
+.PHONY: build-arch build-indep build binary binary-indep binary-arch clean install
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/fill-values b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/fill-values
new file mode 100644
index 0000000..79eebf1
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/fill-values
@@ -0,0 +1,6 @@
+Skeleton: upload-native
+Testname: legacy-debug
+Source: debug
+Default-Build-Depends: debhelper (>= 9.20151004~)
+Dh-Compat-Level: 7
+Description: Legacy test "debug"
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/hello.c b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/hello.c
new file mode 100644
index 0000000..76f8337
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/hello.c
@@ -0,0 +1,9 @@
+#include <stdlib.h>
+#include "libhello.h"
+
+int
+main(void)
+{
+ hello();
+ exit(0);
+}
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.c b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.c
new file mode 100644
index 0000000..e2f8409
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.c
@@ -0,0 +1,7 @@
+#include <stdio.h>
+
+void
+hello(void)
+{
+ printf("Hello, World!\n");
+}
diff --git a/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.h b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.h
new file mode 100644
index 0000000..ef77476
--- /dev/null
+++ b/t/recipes/checks/binaries/prerequisites/legacy-debug/build-spec/orig/libhello.h
@@ -0,0 +1 @@
+void hello(void);