diff options
Diffstat (limited to 'usr.bin/make/tests/archives')
76 files changed, 364 insertions, 0 deletions
diff --git a/usr.bin/make/tests/archives/Makefile b/usr.bin/make/tests/archives/Makefile new file mode 100644 index 0000000..f8944e0 --- /dev/null +++ b/usr.bin/make/tests/archives/Makefile @@ -0,0 +1,7 @@ +# $FreeBSD$ + +TESTSDIR= ${TESTSBASE}/usr.bin/make/archives + +TESTS_SUBDIRS= fmt_44bsd fmt_44bsd_mod fmt_oldbsd + +.include <bsd.test.mk> diff --git a/usr.bin/make/tests/archives/fmt_44bsd/Makefile b/usr.bin/make/tests/archives/fmt_44bsd/Makefile new file mode 100644 index 0000000..bf6ad40 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/Makefile @@ -0,0 +1,32 @@ +# $FreeBSD$ + +TESTSDIR= ${TESTSBASE}/usr.bin/make/archives/fmt_44bsd + +TAP_TESTS_SH= legacy_test + +FILESDIR= ${TESTSDIR} +FILES= Makefile.test +FILES+= expected.status.1 +FILES+= expected.status.2 +FILES+= expected.status.3 +FILES+= expected.status.4 +FILES+= expected.status.5 +FILES+= expected.status.6 +FILES+= expected.status.7 +FILES+= expected.stderr.1 +FILES+= expected.stderr.2 +FILES+= expected.stderr.3 +FILES+= expected.stderr.4 +FILES+= expected.stderr.5 +FILES+= expected.stderr.6 +FILES+= expected.stderr.7 +FILES+= expected.stdout.1 +FILES+= expected.stdout.2 +FILES+= expected.stdout.3 +FILES+= expected.stdout.4 +FILES+= expected.stdout.5 +FILES+= expected.stdout.6 +FILES+= expected.stdout.7 +FILES+= libtest.a + +.include <bsd.test.mk> diff --git a/usr.bin/make/tests/archives/fmt_44bsd/Makefile.test b/usr.bin/make/tests/archives/fmt_44bsd/Makefile.test new file mode 100644 index 0000000..5a8b065 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/Makefile.test @@ -0,0 +1,61 @@ +# $FreeBSD$ +# This test checks the code reading archive files. The archive file +# is a BSD4.4 file with __.SYMTAB and #1/N long file names. + +############################################################################# + +# should be ok +test1: libtest.a(short.o) + @: + +libtest.a(short.o): ood + @: + +############################################################################# + +# should be ok +test2: libtest.a(exactly15char.o) + @: + +libtest.a(exactly15char.o): ood + @: + +############################################################################# + +# should be ok +test3: libtest.a(exactly16chars.o) + @: + +libtest.a(exactly16chars.o): ood + @: + +############################################################################# + +# should be ok +test4: libtest.a(verylongobjectname.o) + @: + +libtest.a(verylongobjectname.o): ood + @: + +############################################################################# + +# Truncated to 16 characters +# should fail +test5: libtest.a(verylongobjectna) + @: + +############################################################################# + +# Truncated to 15 characters +# should fail +test6: libtest.a(verylongobjectn) + @: + +############################################################################# + +# should fail +test7: libtest.a(\#1/20) + @: + +ood: diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.1 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.1 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.1 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.2 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.2 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.2 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.3 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.3 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.3 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.4 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.4 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.4 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.5 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.5 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.5 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.6 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.6 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.6 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.status.7 b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.7 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.status.7 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.1 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.1 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.2 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.3 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.3 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.4 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.4 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.5 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.5 new file mode 100644 index 0000000..7b91643 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.5 @@ -0,0 +1 @@ +make: don't know how to make verylongobjectna. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.6 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.6 new file mode 100644 index 0000000..fd15190 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.6 @@ -0,0 +1 @@ +make: don't know how to make verylongobjectn. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.7 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.7 new file mode 100644 index 0000000..cb572e1 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stderr.7 @@ -0,0 +1 @@ +make: don't know how to make #1/20. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.1 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.1 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.2 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.3 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.3 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.4 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.4 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.5 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.5 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.5 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.6 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.6 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.6 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.7 b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.7 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/expected.stdout.7 diff --git a/usr.bin/make/tests/archives/fmt_44bsd/legacy_test.sh b/usr.bin/make/tests/archives/fmt_44bsd/legacy_test.sh new file mode 100644 index 0000000..2604c96 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/legacy_test.sh @@ -0,0 +1,15 @@ +#! /bin/sh +# $FreeBSD$ + +. $(dirname $0)/../../common.sh + +# Description +DESC="Archive parsing (BSD4.4 format)." + +# Setup +TEST_COPY_FILES="libtest.a 644" + +# Run +TEST_N=7 + +eval_cmd $* diff --git a/usr.bin/make/tests/archives/fmt_44bsd/libtest.a b/usr.bin/make/tests/archives/fmt_44bsd/libtest.a Binary files differnew file mode 100644 index 0000000..891ce6e --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd/libtest.a diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile b/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile new file mode 100644 index 0000000..8d63b64 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile @@ -0,0 +1,32 @@ +# $FreeBSD$ + +TESTSDIR= ${TESTSBASE}/usr.bin/make/archives/fmt_44bsd_mod + +TAP_TESTS_SH= legacy_test + +FILESDIR= ${TESTSDIR} +FILES= Makefile.test +FILES+= expected.status.1 +FILES+= expected.status.2 +FILES+= expected.status.3 +FILES+= expected.status.4 +FILES+= expected.status.5 +FILES+= expected.status.6 +FILES+= expected.status.7 +FILES+= expected.stderr.1 +FILES+= expected.stderr.2 +FILES+= expected.stderr.3 +FILES+= expected.stderr.4 +FILES+= expected.stderr.5 +FILES+= expected.stderr.6 +FILES+= expected.stderr.7 +FILES+= expected.stdout.1 +FILES+= expected.stdout.2 +FILES+= expected.stdout.3 +FILES+= expected.stdout.4 +FILES+= expected.stdout.5 +FILES+= expected.stdout.6 +FILES+= expected.stdout.7 +FILES+= libtest.a + +.include <bsd.test.mk> diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile.test b/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile.test new file mode 100644 index 0000000..cd999da --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/Makefile.test @@ -0,0 +1,64 @@ +# $FreeBSD$ +# This test checks the code reading archive files. The archive file +# is a BSD4.4 file with __.SYMTAB and #1/N long file names. +# +# The modification of the archive consists in slashes appended to short names. +# + +############################################################################# + +# must be ok +test1: libtest.a(short.o) + @: + +libtest.a(short.o): ood + @: + +############################################################################# + +# must be ok +test2: libtest.a(exactly15char.o) + @: + +libtest.a(exactly15char.o): ood + @: + +############################################################################# + +# must be ok +test3: libtest.a(exactly16chars.o) + @: + +libtest.a(exactly16chars.o): ood + @: + +############################################################################# + +# must be ok +test4: libtest.a(verylongobjectname.o) + @: + +libtest.a(verylongobjectname.o): ood + @: + +############################################################################# + +# Truncated to 16 characters +# must fail +test5: libtest.a(verylongobjectna) + @: + +############################################################################# + +# Truncated to 15 characters +# must fail +test6: libtest.a(verylongobjectn) + @: + +############################################################################# + +# must fail +test7: libtest.a(\#1/20) + @: + +ood: diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.1 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.1 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.1 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.2 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.2 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.2 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.3 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.3 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.3 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.4 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.4 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.4 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.5 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.5 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.5 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.6 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.6 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.6 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.7 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.7 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.status.7 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.1 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.1 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.2 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.3 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.3 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.4 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.4 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.5 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.5 new file mode 100644 index 0000000..7b91643 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.5 @@ -0,0 +1 @@ +make: don't know how to make verylongobjectna. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.6 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.6 new file mode 100644 index 0000000..fd15190 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.6 @@ -0,0 +1 @@ +make: don't know how to make verylongobjectn. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.7 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.7 new file mode 100644 index 0000000..cb572e1 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stderr.7 @@ -0,0 +1 @@ +make: don't know how to make #1/20. Stop diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.1 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.1 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.2 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.2 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.3 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.3 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.4 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.4 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.5 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.5 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.5 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.6 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.6 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.6 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.7 b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.7 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/expected.stdout.7 diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/legacy_test.sh b/usr.bin/make/tests/archives/fmt_44bsd_mod/legacy_test.sh new file mode 100644 index 0000000..bf13f22 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/legacy_test.sh @@ -0,0 +1,15 @@ +#! /bin/sh +# $FreeBSD$ + +. $(dirname $0)/../../common.sh + +# Description +DESC="Archive parsing (modified BSD4.4 format)." + +# Setup +TEST_COPY_FILES="libtest.a 644" + +# Run +TEST_N=7 + +eval_cmd $* diff --git a/usr.bin/make/tests/archives/fmt_44bsd_mod/libtest.a b/usr.bin/make/tests/archives/fmt_44bsd_mod/libtest.a Binary files differnew file mode 100644 index 0000000..57bc407 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_44bsd_mod/libtest.a diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/Makefile b/usr.bin/make/tests/archives/fmt_oldbsd/Makefile new file mode 100644 index 0000000..ab1c383 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/Makefile @@ -0,0 +1,32 @@ +# $FreeBSD$ + +TESTSDIR= ${TESTSBASE}/usr.bin/make/archives/fmt_oldbsd + +TAP_TESTS_SH= legacy_test + +FILESDIR= ${TESTSDIR} +FILES= Makefile.test +FILES+= expected.status.1 +FILES+= expected.status.2 +FILES+= expected.status.3 +FILES+= expected.status.4 +FILES+= expected.status.5 +FILES+= expected.status.6 +FILES+= expected.status.7 +FILES+= expected.stderr.1 +FILES+= expected.stderr.2 +FILES+= expected.stderr.3 +FILES+= expected.stderr.4 +FILES+= expected.stderr.5 +FILES+= expected.stderr.6 +FILES+= expected.stderr.7 +FILES+= expected.stdout.1 +FILES+= expected.stdout.2 +FILES+= expected.stdout.3 +FILES+= expected.stdout.4 +FILES+= expected.stdout.5 +FILES+= expected.stdout.6 +FILES+= expected.stdout.7 +FILES+= libtest.a + +.include <bsd.test.mk> diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/Makefile.test b/usr.bin/make/tests/archives/fmt_oldbsd/Makefile.test new file mode 100644 index 0000000..b8f5116 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/Makefile.test @@ -0,0 +1,62 @@ +# $FreeBSD$ +# This test checks the code reading archive files. The archive file +# is an old BSD file with __.SYMTAB and no long file names. Filenames +# are truncated to 16 characters. + +############################################################################# + +# must be ok +test1: libtest.a(short.o) + @: + +libtest.a(short.o): ood + @: + +############################################################################# + +# must be ok +test2: libtest.a(exactly15char.o) + @: + +libtest.a(exactly15char.o): ood + @: + +############################################################################# + +# must be ok +test3: libtest.a(exactly16chars.o) + @: + +libtest.a(exactly16chars.o): ood + @: + +############################################################################# + +# must be ok +test4: libtest.a(verylongobjectname.o) + @: + +libtest.a(verylongobjectname.o): ood + @: + +############################################################################# + +# Truncated to 16 characters +# must be ok +test5: libtest.a(verylongobjectna) + @: + +############################################################################# + +# Truncated to 15 characters +# must fail +test6: libtest.a(verylongobjectn) + @: + +############################################################################# + +# must fail +test7: libtest.a(\#1/20) + @: + +ood: diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.1 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.1 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.1 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.2 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.2 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.2 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.3 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.3 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.3 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.4 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.4 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.4 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.5 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.5 new file mode 100644 index 0000000..573541a --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.5 @@ -0,0 +1 @@ +0 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.6 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.6 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.6 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.7 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.7 new file mode 100644 index 0000000..0cfbf08 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.status.7 @@ -0,0 +1 @@ +2 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.1 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.1 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.2 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.2 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.3 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.3 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.4 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.4 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.5 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.5 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.5 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.6 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.6 new file mode 100644 index 0000000..fd15190 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.6 @@ -0,0 +1 @@ +make: don't know how to make verylongobjectn. Stop diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.7 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.7 new file mode 100644 index 0000000..cb572e1 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stderr.7 @@ -0,0 +1 @@ +make: don't know how to make #1/20. Stop diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.1 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.1 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.1 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.2 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.2 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.2 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.3 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.3 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.3 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.4 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.4 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.4 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.5 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.5 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.5 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.6 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.6 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.6 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.7 b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.7 new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/expected.stdout.7 diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/legacy_test.sh b/usr.bin/make/tests/archives/fmt_oldbsd/legacy_test.sh new file mode 100644 index 0000000..c7980c5 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/legacy_test.sh @@ -0,0 +1,15 @@ +#! /bin/sh +# $FreeBSD$ + +. $(dirname $0)/../../common.sh + +# Description +DESC="Archive parsing (old BSD format)." + +# Setup +TEST_COPY_FILES="libtest.a 644" + +# Run +TEST_N=7 + +eval_cmd $* diff --git a/usr.bin/make/tests/archives/fmt_oldbsd/libtest.a b/usr.bin/make/tests/archives/fmt_oldbsd/libtest.a Binary files differnew file mode 100644 index 0000000..3434c53 --- /dev/null +++ b/usr.bin/make/tests/archives/fmt_oldbsd/libtest.a |