143faedc1SGlen BarberPACKAGE= tests 243faedc1SGlen Barber 33c89d6b0SBryan Drewery_LIBARCHIVEDIR= ${SRCTOP}/contrib/libarchive 459e2ff55SEnji Cooper 559e2ff55SEnji CooperATF_TESTS_SH+= functional_test 659e2ff55SEnji Cooper 759e2ff55SEnji CooperBINDIR= ${TESTSDIR} 859e2ff55SEnji Cooper 959e2ff55SEnji CooperPROGS+= bsdcpio_test 1059e2ff55SEnji Cooper 1159e2ff55SEnji CooperCFLAGS+= -DPLATFORM_CONFIG_H=\"${SRCTOP}/lib/libarchive/config_freebsd.h\" 1259e2ff55SEnji CooperCFLAGS+= -I${SRCTOP}/lib/libarchive -I${.OBJDIR} 1359e2ff55SEnji Cooper 1459e2ff55SEnji CooperCFLAGS+= -I${.OBJDIR} 1564287048SMartin MatuskaCFLAGS+= -I${_LIBARCHIVEDIR}/cpio -I${_LIBARCHIVEDIR}/cpio/test 164657548dSMartin MatuskaCFLAGS+= -I${_LIBARCHIVEDIR}/libarchive 1764287048SMartin MatuskaCFLAGS+= -I${_LIBARCHIVEDIR}/libarchive_fe -I${_LIBARCHIVEDIR}/test_utils 1859e2ff55SEnji Cooper 1959e2ff55SEnji Cooper# Uncomment to link against dmalloc 2059e2ff55SEnji Cooper#LDADD+= -L/usr/local/lib -ldmalloc 2159e2ff55SEnji Cooper#CFLAGS+= -I/usr/local/include -DUSE_DMALLOC 2259e2ff55SEnji Cooper 23833a452eSMartin MatuskaCFLAGS.test_utils.c+= -Wno-cast-align 24833a452eSMartin Matuska 253c89d6b0SBryan Drewery.PATH: ${_LIBARCHIVEDIR}/cpio 2659e2ff55SEnji CooperCPIO_SRCS= cmdline.c 2759e2ff55SEnji Cooper 283c89d6b0SBryan Drewery.PATH: ${_LIBARCHIVEDIR}/libarchive_fe 2959e2ff55SEnji CooperCPIO_SRCS+= err.c 3059e2ff55SEnji Cooper 313c89d6b0SBryan Drewery.PATH: ${_LIBARCHIVEDIR}/cpio/test 3259e2ff55SEnji CooperTESTS_SRCS= \ 3359e2ff55SEnji Cooper test_0.c \ 3459e2ff55SEnji Cooper test_basic.c \ 3559e2ff55SEnji Cooper test_cmdline.c \ 36*bd66c1b4SMartin Matuska test_extract_cpio_absolute_paths.c \ 3759e2ff55SEnji Cooper test_extract_cpio_Z.c \ 3859e2ff55SEnji Cooper test_extract_cpio_bz2.c \ 3959e2ff55SEnji Cooper test_extract_cpio_grz.c \ 4059e2ff55SEnji Cooper test_extract_cpio_gz.c \ 4159e2ff55SEnji Cooper test_extract_cpio_lrz.c \ 4259e2ff55SEnji Cooper test_extract_cpio_lz.c \ 43cdf63a70SMartin Matuska test_extract_cpio_lz4.c \ 4459e2ff55SEnji Cooper test_extract_cpio_lzma.c \ 4559e2ff55SEnji Cooper test_extract_cpio_lzo.c \ 4659e2ff55SEnji Cooper test_extract_cpio_xz.c \ 475c831a5bSMartin Matuska test_extract_cpio_zstd.c \ 4859e2ff55SEnji Cooper test_format_newc.c \ 4959e2ff55SEnji Cooper test_gcpio_compat.c \ 50f061a221SMartin Matuska test_missing_file.c \ 5159e2ff55SEnji Cooper test_option_0.c \ 5259e2ff55SEnji Cooper test_option_B_upper.c \ 5359e2ff55SEnji Cooper test_option_C_upper.c \ 5459e2ff55SEnji Cooper test_option_J_upper.c \ 5559e2ff55SEnji Cooper test_option_L_upper.c \ 5659e2ff55SEnji Cooper test_option_Z_upper.c \ 5759e2ff55SEnji Cooper test_option_a.c \ 5859e2ff55SEnji Cooper test_option_b64encode.c \ 5959e2ff55SEnji Cooper test_option_c.c \ 6059e2ff55SEnji Cooper test_option_d.c \ 6159e2ff55SEnji Cooper test_option_f.c \ 6259e2ff55SEnji Cooper test_option_grzip.c \ 6359e2ff55SEnji Cooper test_option_help.c \ 6459e2ff55SEnji Cooper test_option_l.c \ 6559e2ff55SEnji Cooper test_option_lrzip.c \ 66cdf63a70SMartin Matuska test_option_lz4.c \ 6759e2ff55SEnji Cooper test_option_lzma.c \ 6859e2ff55SEnji Cooper test_option_lzop.c \ 6959e2ff55SEnji Cooper test_option_m.c \ 70cdf63a70SMartin Matuska test_option_passphrase.c \ 7159e2ff55SEnji Cooper test_option_t.c \ 7259e2ff55SEnji Cooper test_option_u.c \ 7359e2ff55SEnji Cooper test_option_uuencode.c \ 7459e2ff55SEnji Cooper test_option_version.c \ 7559e2ff55SEnji Cooper test_option_xz.c \ 7659e2ff55SEnji Cooper test_option_y.c \ 7759e2ff55SEnji Cooper test_option_z.c \ 785c831a5bSMartin Matuska test_option_zstd.c \ 7959e2ff55SEnji Cooper test_owner_parse.c \ 8059e2ff55SEnji Cooper test_passthrough_dotdot.c \ 8159e2ff55SEnji Cooper test_passthrough_reverse.c 8259e2ff55SEnji Cooper 8359e2ff55SEnji CooperSRCS.bsdcpio_test= list.h \ 8459e2ff55SEnji Cooper ${CPIO_SRCS} \ 8564287048SMartin Matuska ${TESTS_SRCS} 8659e2ff55SEnji Cooper 873c89d6b0SBryan Drewery.PATH: ${_LIBARCHIVEDIR}/test_utils 8864287048SMartin MatuskaSRCS.bsdcpio_test+= test_main.c \ 8964287048SMartin Matuska test_utils.c 9059e2ff55SEnji Cooper 9159e2ff55SEnji CooperLIBADD.bsdcpio_test= archive 9259e2ff55SEnji Cooper 9359e2ff55SEnji Cooperlist.h: ${TESTS_SRCS} Makefile 943c89d6b0SBryan Drewery @(cd ${_LIBARCHIVEDIR}/tar/test && \ 9559e2ff55SEnji Cooper grep -h DEFINE_TEST ${.ALLSRC:N*Makefile}) > ${.TARGET}.tmp 9659e2ff55SEnji Cooper @mv ${.TARGET}.tmp ${.TARGET} 9759e2ff55SEnji Cooper 9859e2ff55SEnji CooperCLEANFILES+= list.h list.h.tmp 9959e2ff55SEnji Cooper 100430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.Z.uu 101430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.bz2.uu 102430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.grz.uu 103430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.gz.uu 104430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.lrz.uu 105430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.lz.uu 106cdf63a70SMartin Matuska${PACKAGE}FILES+= test_extract.cpio.lz4.uu 107430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.lzma.uu 108430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.lzo.uu 109430f7286SEnji Cooper${PACKAGE}FILES+= test_extract.cpio.xz.uu 1105c831a5bSMartin Matuska${PACKAGE}FILES+= test_extract.cpio.zst.uu 111430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref.bin.uu 112430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref.crc.uu 113430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref.newc.uu 114430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref.ustar.uu 115430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref_nosym.bin.uu 116430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref_nosym.crc.uu 117430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref_nosym.newc.uu 118430f7286SEnji Cooper${PACKAGE}FILES+= test_gcpio_compat_ref_nosym.ustar.uu 119430f7286SEnji Cooper${PACKAGE}FILES+= test_option_f.cpio.uu 120430f7286SEnji Cooper${PACKAGE}FILES+= test_option_m.cpio.uu 121cdf63a70SMartin Matuska${PACKAGE}FILES+= test_option_passphrase.zip.uu 122430f7286SEnji Cooper${PACKAGE}FILES+= test_option_t.cpio.uu 123430f7286SEnji Cooper${PACKAGE}FILES+= test_option_t.stdout.uu 124430f7286SEnji Cooper${PACKAGE}FILES+= test_option_tv.stdout.uu 12559e2ff55SEnji Cooper 12659e2ff55SEnji Cooper.include <bsd.test.mk> 127