Index: head/ObsoleteFiles.inc =================================================================== --- head/ObsoleteFiles.inc (revision 273928) +++ head/ObsoleteFiles.inc (revision 273929) @@ -1,6629 +1,6628 @@ # # $FreeBSD$ # # This file lists old files (OLD_FILES), libraries (OLD_LIBS) and # directories (OLD_DIRS) which should get removed at an update. Recently # removed entries first (with the date as a comment). Dynamic libraries are # special cased (OLD_LIBS). Static libraries or the generic links to # the dynamic libraries (lib*.so) should (if you don't know why to make an # exception, make this a "must") be viewed as normal files (OLD_FILES). # # In case of a complete directory hierarchy the sorting is in depth first # order. # # The file is partitioned: OLD_FILES first, then OLD_LIBS and OLD_DIRS last. # # Before you commit changes to this file please check if any entries in # tools/build/mk/OptionalObsoleteFiles.inc can be removed. The following # command tells which files are listed more than once regardless of some # architecture specific conditionals, so you can not blindly trust the # output: # ( grep '+=' /usr/src/ObsoleteFiles.inc | sort -u ; \ # grep '+=' /usr/src/tools/build/mk/OptionalObsoleteFiles.inc | sort -u) | \ # sort | uniq -d # # To find regular duplicates not dependant on optional components, you can # also use something that will not give you false positives, e.g.: # for t in `make -V TARGETS universe`; do # __MAKE_CONF=/dev/null make -f Makefile.inc1 TARGET=$t \ # -V OLD_FILES -V OLD_LIBS -V OLD_DIRS check-old | \ # xargs -n1 | sort | uniq -d; # done # # For optional components, you can use the following to see if some entries # in OptionalObsoleteFiles.inc have been obsoleted by ObsoleteFiles.inc # for o in tools/build/options/WITH*; do # __MAKE_CONF=/dev/null make -f Makefile.inc1 -D${o##*/} \ # -V OLD_FILES -V OLD_LIBS -V OLD_DIRS check-old | \ # xargs -n1 | sort | uniq -d; # done # 20141031: initrandom obsoleted by new /dev/random code OLD_FILES+=etc/rc.d/initrandom # 20141028: debug files accidentally installed as directory name OLD_FILES+=usr/lib/debug/usr/lib/i18n OLD_FILES+=usr/lib/debug/usr/lib/private OLD_FILES+=usr/lib/debug/usr/lib32/i18n OLD_FILES+=usr/lib/debug/usr/lib32/private # 20141015: OpenSSL 1.0.1j import OLD_FILES+=usr/share/openssl/man/man3/CMS_sign_add1_signer.3.gz # 20140922: sleepq_calc_signal_retval.9 and sleepq_catch_signals.9 removed OLD_FILES+=usr/share/man/man9/sleepq_calc_signal_retval.9.gz OLD_FILES+=usr/share/man/man9/sleepq_catch_signals.9.gz # 20140917: hv_kvpd rc.d script removed in favor of devd configuration OLD_FILES+=etc/rc.d/hv_kvpd # 20140917: libnv was accidentally being installed to /usr/lib instead of /lib OLD_LIBS+=usr/lib/libnv.so.0 # 20140829: rc.d/kerberos removed OLD_FILES+=etc/rc.d/kerberos # 20140814: libopie version bump OLD_LIBS+=usr/lib/libopie.so.7 OLD_LIBS+=usr/lib32/libopie.so.7 # 20140811: otp-sha renamed to otp-sha1 OLD_FILES+=usr/bin/otp-sha OLD_FILES+=usr/share/man/man1/otp-sha.1.gz # 20140807: Remove private lib files that should not be installed. OLD_FILES+=usr/lib/private/libatf-c.a OLD_FILES+=usr/lib/private/libatf-c.so OLD_FILES+=usr/lib/private/libatf-c_p.a OLD_FILES+=usr/lib/private/libatf-c++.a OLD_FILES+=usr/lib/private/libatf-c++.so OLD_FILES+=usr/lib/private/libatf-c++_p.a OLD_FILES+=usr/lib/private/libbsdstat.a OLD_FILES+=usr/lib/private/libbsdstat.so OLD_FILES+=usr/lib/private/libbsdstat_p.a OLD_FILES+=usr/lib/private/libheimipcc.a OLD_FILES+=usr/lib/private/libheimipcc.so OLD_FILES+=usr/lib/private/libheimipcc_p.a OLD_FILES+=usr/lib/private/libheimipcs.a OLD_FILES+=usr/lib/private/libheimipcs.so OLD_FILES+=usr/lib/private/libheimipcs_p.a OLD_FILES+=usr/lib/private/libldns.a OLD_FILES+=usr/lib/private/libldns.so OLD_FILES+=usr/lib/private/libldns_p.a OLD_FILES+=usr/lib/private/libssh.a OLD_FILES+=usr/lib/private/libssh.so OLD_FILES+=usr/lib/private/libssh.p.a OLD_FILES+=usr/lib/private/libunbound.a OLD_FILES+=usr/lib/private/libunbound.so OLD_FILES+=usr/lib/private/libunbound_p.a OLD_FILES+=usr/lib/private/libucl.a OLD_FILES+=usr/lib/private/libucl.so OLD_FILES+=usr/lib/private/libucl_p.a # 20140803: Remove an obsolete man page OLD_FILES+=usr/share/man/man9/pmap_change_wiring.9.gz # 20140728: libsbuf restored to old version. OLD_LIBS+=lib/libsbuf.so.7 # 20140728: Remove an obsolete man page OLD_FILES+=usr/share/man/man9/VOP_GETVOBJECT.9.gz OLD_FILES+=usr/share/man/man9/VOP_CREATEVOBJECT.9.gz OLD_FILES+=usr/share/man/man9/VOP_DESTROYVOBJECT.9.gz # 20140723: renamed to PCBGROUP.9 OLD_FILES+=usr/share/man/man9/PCBGROUPS.9.gz # 20140718: Remove obsolete man pages OLD_FILES+=usr/share/man/man9/zero_copy.9.gz OLD_FILES+=usr/share/man/man9/zero_copy_sockets.9.gz # 20140718: Remove an obsolete man page OLD_FILES+=usr/share/man/man9/pmap_page_protect.9.gz # 20140717: Remove an obsolete man page OLD_FILES+=usr/share/man/man9/pmap_clear_reference.9.gz # 20140716: Remove an incorrectly named man page OLD_FILES+=usr/share/man/man9/pmap_ts_modified.9.gz # 20140712: Removal of bsd.dtrace.mk OLD_FILES+=usr/share/mk/bsd.dtrace.mk # 20140705: turn libreadline into an internal lib OLD_LIBS+=lib/libreadline.so.8 OLD_FILES+=usr/lib/libreadline.a OLD_FILES+=usr/lib/libreadline_p.a OLD_FILES+=usr/lib/libreadline.so OLD_FILES+=usr/lib/libhistory.a OLD_FILES+=usr/lib/libhistory_p.a OLD_FILES+=usr/lib/libhistory.so OLD_LIBS+=usr/lib/libhistory.so.8 OLD_FILES+=usr/include/readline/chardefs.h OLD_FILES+=usr/include/readline/history.h OLD_FILES+=usr/include/readline/keymaps.h OLD_FILES+=usr/include/readline/readline.h OLD_FILES+=usr/include/readline/rlconf.h OLD_FILES+=usr/include/readline/rlstdc.h OLD_FILES+=usr/include/readline/rltypedefs.h OLD_FILES+=usr/include/readline/rltypedefs.h OLD_FILES+=usr/share/info/readline.info.gz OLD_FILES+=usr/share/man/man3/readline.3.gz # 20140625: csup removal OLD_FILES+=usr/bin/csup OLD_FILES+=usr/bin/cpasswd OLD_FILES+=usr/share/man/man1/csup.1.gz OLD_FILES+=usr/share/man/man1/cpasswd.1.gz OLD_FILES+=usr/share/examples/cvsup/README OLD_FILES+=usr/share/examples/cvsup/cvs-supfile OLD_FILES+=usr/share/examples/cvsup/stable-supfile OLD_FILES+=usr/share/examples/cvsup/standard-supfile OLD_DIRS+=usr/share/examples/cvsup # 20140614: send-pr removal OLD_FILES+=usr/bin/sendbug OLD_FILES+=usr/share/info/send-pr.info.gz OLD_FILES+=usr/share/man/man1/send-pr.1.gz OLD_FILES+=usr/share/man/man1/sendbug.1.gz OLD_FILES+=etc/gnats/freefall OLD_DIRS+=etc/gnats # 20140512: new clang import which bumps version from 3.4 to 3.4.1. OLD_FILES+=usr/include/clang/3.4/__wmmintrin_aes.h OLD_FILES+=usr/include/clang/3.4/__wmmintrin_pclmul.h OLD_FILES+=usr/include/clang/3.4/altivec.h OLD_FILES+=usr/include/clang/3.4/ammintrin.h OLD_FILES+=usr/include/clang/3.4/avx2intrin.h OLD_FILES+=usr/include/clang/3.4/avxintrin.h OLD_FILES+=usr/include/clang/3.4/bmi2intrin.h OLD_FILES+=usr/include/clang/3.4/bmiintrin.h OLD_FILES+=usr/include/clang/3.4/cpuid.h OLD_FILES+=usr/include/clang/3.4/emmintrin.h OLD_FILES+=usr/include/clang/3.4/f16cintrin.h OLD_FILES+=usr/include/clang/3.4/fma4intrin.h OLD_FILES+=usr/include/clang/3.4/fmaintrin.h OLD_FILES+=usr/include/clang/3.4/immintrin.h OLD_FILES+=usr/include/clang/3.4/lzcntintrin.h OLD_FILES+=usr/include/clang/3.4/mm3dnow.h OLD_FILES+=usr/include/clang/3.4/mm_malloc.h OLD_FILES+=usr/include/clang/3.4/mmintrin.h OLD_FILES+=usr/include/clang/3.4/module.map OLD_FILES+=usr/include/clang/3.4/nmmintrin.h OLD_FILES+=usr/include/clang/3.4/pmmintrin.h OLD_FILES+=usr/include/clang/3.4/popcntintrin.h OLD_FILES+=usr/include/clang/3.4/prfchwintrin.h OLD_FILES+=usr/include/clang/3.4/rdseedintrin.h OLD_FILES+=usr/include/clang/3.4/rtmintrin.h OLD_FILES+=usr/include/clang/3.4/shaintrin.h OLD_FILES+=usr/include/clang/3.4/smmintrin.h OLD_FILES+=usr/include/clang/3.4/tbmintrin.h OLD_FILES+=usr/include/clang/3.4/tmmintrin.h OLD_FILES+=usr/include/clang/3.4/wmmintrin.h OLD_FILES+=usr/include/clang/3.4/x86intrin.h OLD_FILES+=usr/include/clang/3.4/xmmintrin.h OLD_FILES+=usr/include/clang/3.4/xopintrin.h OLD_FILES+=usr/include/clang/3.4/arm_neon.h OLD_FILES+=usr/include/clang/3.4/module.map OLD_DIRS+=usr/include/clang/3.4 # 20140505: Bogusly installing src.opts.mk OLD_FILES+=usr/share/mk/src.opts.mk # 20140505: Reject PR kern/187551 OLD_DIRS+=usr/tests/sbin/ifconfig OLD_FILES+=usr/tests/sbin/ifconfig/Kyuafile OLD_FILES+=usr/tests/sbin/ifconfig/fibs_test # 20140502: Removal of lindev(4) OLD_FILES+=usr/share/man/man4/lindev.4.gz # 20140314: AppleTalk OLD_DIRS+=usr/include/netatalk OLD_FILES+=usr/include/netatalk/aarp.h OLD_FILES+=usr/include/netatalk/at.h OLD_FILES+=usr/include/netatalk/at_extern.h OLD_FILES+=usr/include/netatalk/at_var.h OLD_FILES+=usr/include/netatalk/ddp.h OLD_FILES+=usr/include/netatalk/ddp_pcb.h OLD_FILES+=usr/include/netatalk/ddp_var.h OLD_FILES+=usr/include/netatalk/endian.h OLD_FILES+=usr/include/netatalk/phase2.h # 20140314: Remove IPX/SPX OLD_LIBS+=lib/libipx.so.5 OLD_FILES+=usr/include/netipx/ipx.h OLD_FILES+=usr/include/netipx/ipx_if.h OLD_FILES+=usr/include/netipx/ipx_pcb.h OLD_FILES+=usr/include/netipx/ipx_var.h OLD_FILES+=usr/include/netipx/spx.h OLD_FILES+=usr/include/netipx/spx_debug.h OLD_FILES+=usr/include/netipx/spx_timer.h OLD_FILES+=usr/include/netipx/spx_var.h OLD_DIRS+=usr/include/netipx OLD_FILES+=usr/lib/libipx.a OLD_FILES+=usr/lib/libipx.so OLD_FILES+=usr/lib/libipx_p.a OLD_FILES+=usr/lib32/libipx.a OLD_FILES+=usr/lib32/libipx.so OLD_LIBS+=usr/lib32/libipx.so.5 OLD_FILES+=usr/lib32/libipx_p.a OLD_FILES+=usr/sbin/IPXrouted OLD_FILES+=usr/share/man/man3/ipx.3.gz OLD_FILES+=usr/share/man/man3/ipx_addr.3.gz OLD_FILES+=usr/share/man/man3/ipx_ntoa.3.gz OLD_FILES+=usr/share/man/man4/ef.4.gz OLD_FILES+=usr/share/man/man4/if_ef.4.gz OLD_FILES+=usr/share/man/man8/IPXrouted.8.gz # 20140314: bsdconfig usermgmt rewrite OLD_FILES+=usr/libexec/bsdconfig/070.usermgmt/userinput # 20140307: bsdconfig groupmgmt rewrite OLD_FILES+=usr/libexec/bsdconfig/070.usermgmt/groupinput # 20140223: Remove libyaml OLD_FILES+=usr/lib/private/libyaml.a OLD_FILES+=usr/lib/private/libyaml.so OLD_FILES+=usr/lib/private/libyaml.so.1 OLD_FILES+=usr/lib/private/libyaml_p.a # 20140216: new clang import which bumps version from 3.3 to 3.4. OLD_FILES+=usr/bin/llvm-prof OLD_FILES+=usr/bin/llvm-ranlib OLD_FILES+=usr/include/clang/3.3/__wmmintrin_aes.h OLD_FILES+=usr/include/clang/3.3/__wmmintrin_pclmul.h OLD_FILES+=usr/include/clang/3.3/altivec.h OLD_FILES+=usr/include/clang/3.3/ammintrin.h OLD_FILES+=usr/include/clang/3.3/avx2intrin.h OLD_FILES+=usr/include/clang/3.3/avxintrin.h OLD_FILES+=usr/include/clang/3.3/bmi2intrin.h OLD_FILES+=usr/include/clang/3.3/bmiintrin.h OLD_FILES+=usr/include/clang/3.3/cpuid.h OLD_FILES+=usr/include/clang/3.3/emmintrin.h OLD_FILES+=usr/include/clang/3.3/f16cintrin.h OLD_FILES+=usr/include/clang/3.3/fma4intrin.h OLD_FILES+=usr/include/clang/3.3/fmaintrin.h OLD_FILES+=usr/include/clang/3.3/immintrin.h OLD_FILES+=usr/include/clang/3.3/lzcntintrin.h OLD_FILES+=usr/include/clang/3.3/mm3dnow.h OLD_FILES+=usr/include/clang/3.3/mm_malloc.h OLD_FILES+=usr/include/clang/3.3/mmintrin.h OLD_FILES+=usr/include/clang/3.3/module.map OLD_FILES+=usr/include/clang/3.3/nmmintrin.h OLD_FILES+=usr/include/clang/3.3/pmmintrin.h OLD_FILES+=usr/include/clang/3.3/popcntintrin.h OLD_FILES+=usr/include/clang/3.3/prfchwintrin.h OLD_FILES+=usr/include/clang/3.3/rdseedintrin.h OLD_FILES+=usr/include/clang/3.3/rtmintrin.h OLD_FILES+=usr/include/clang/3.3/smmintrin.h OLD_FILES+=usr/include/clang/3.3/tmmintrin.h OLD_FILES+=usr/include/clang/3.3/wmmintrin.h OLD_FILES+=usr/include/clang/3.3/x86intrin.h OLD_FILES+=usr/include/clang/3.3/xmmintrin.h OLD_FILES+=usr/include/clang/3.3/xopintrin.h OLD_FILES+=usr/share/man/man1/llvm-prof.1.gz OLD_FILES+=usr/share/man/man1/llvm-ranlib.1.gz OLD_DIRS+=usr/include/clang/3.3 # 20140216: nve(4) removed OLD_FILES+=usr/share/man/man4/if_nve.4.gz OLD_FILES+=usr/share/man/man4/nve.4.gz # 20140205: Open Firmware device moved OLD_FILES+=usr/include/dev/ofw/ofw_nexus.h # 20140128: libelf and libdwarf import OLD_LIBS+=usr/lib/libelf.so.1 OLD_LIBS+=usr/lib32/libelf.so.1 OLD_LIBS+=usr/lib/libdwarf.so.3 OLD_LIBS+=usr/lib32/libdwarf.so.3 # 20140123: apicvar header moved to x86 OLD_FILES+=usr/include/machine/apicvar.h # 20131215: libcam version bumped OLD_LIBS+=lib/libcam.so.6 usr/lib32/libcam.so.6 # 20131202: libcapsicum and libcasper moved to /lib/ OLD_LIBS+=usr/lib/libcapsicum.so.0 OLD_LIBS+=usr/lib/libcasper.so.0 # 20131109: extattr(2) mlinks fixed OLD_FILES+=usr/share/man/man2/extattr_delete_list.2.gz OLD_FILES+=usr/share/man/man2/extattr_get_list.2.gz # 20131107: example files removed OLD_FILES+=usr/share/examples/libusb20/aux.c OLD_FILES+=usr/share/examples/libusb20/aux.h # 20131105: tzdata 2013h import OLD_FILES+=usr/share/zoneinfo/America/Shiprock OLD_FILES+=usr/share/zoneinfo/Antarctica/South_Pole # 20131103: WITH_LIBICONV_COMPAT removal OLD_FILES+=usr/include/_libiconv_compat.h OLD_FILES+=usr/lib/libiconv.a OLD_FILES+=usr/lib/libiconv.so OLD_FILES+=usr/lib/libiconv.so.3 OLD_FILES+=usr/lib/libiconv_p.a OLD_FILES+=usr/lib32/libiconv.a OLD_FILES+=usr/lib32/libiconv.so OLD_FILES+=usr/lib32/libiconv.so.3 OLD_FILES+=usr/lib32/libiconv_p.a # 20131103: removal of utxrm(8), use 'utx rm' instead. OLD_FILES+=usr/sbin/utxrm OLD_FILES+=usr/share/man/man8/utxrm.8.gz # 20131031: pkg_install has been removed OLD_FILES+=etc/periodic/daily/220.backup-pkgdb OLD_FILES+=etc/periodic/daily/490.status-pkg-changes OLD_FILES+=etc/periodic/security/460.chkportsum OLD_FILES+=etc/periodic/weekly/400.status-pkg OLD_FILES+=usr/sbin/pkg_add OLD_FILES+=usr/sbin/pkg_create OLD_FILES+=usr/sbin/pkg_delete OLD_FILES+=usr/sbin/pkg_info OLD_FILES+=usr/sbin/pkg_updating OLD_FILES+=usr/sbin/pkg_version OLD_FILES+=usr/share/man/man1/pkg_add.1.gz OLD_FILES+=usr/share/man/man1/pkg_create.1.gz OLD_FILES+=usr/share/man/man1/pkg_delete.1.gz OLD_FILES+=usr/share/man/man1/pkg_info.1.gz OLD_FILES+=usr/share/man/man1/pkg_updating.1.gz OLD_FILES+=usr/share/man/man1/pkg_version.1.gz # 20131030: /etc/keys moved to /usr/share/keys OLD_DIRS+=etc/keys OLD_DIRS+=etc/keys/pkg OLD_DIRS+=etc/keys/pkg/revoked OLD_DIRS+=etc/keys/pkg/trusted OLD_FILES+=etc/keys/pkg/trusted/pkg.freebsd.org.2013102301 # 20131028: ng_fec(4) removed OLD_FILES+=usr/include/netgraph/ng_fec.h OLD_FILES+=usr/share/man/man4/ng_fec.4.gz # 20131027: header moved OLD_FILES+=usr/include/net/pf_mtag.h # 20131023: remove never used iscsi directory OLD_DIRS+=usr/share/examples/iscsi # 20131021: isf(4) removed OLD_FILES+=usr/sbin/isfctl OLD_FILES+=usr/share/man/man4/isf.4.gz OLD_FILES+=usr/share/man/man8/isfctl.8.gz # 20131014: libbsdyml becomes private OLD_FILES+=usr/lib/libbsdyml.a OLD_FILES+=usr/lib/libbsdyml.so OLD_LIBS+=usr/lib/libbsdyml.so.0 OLD_FILES+=usr/lib/libbsdyml_p.a OLD_FILES+=usr/lib32/libbsdyml.a OLD_FILES+=usr/lib32/libbsdyml.so OLD_LIBS+=usr/lib32/libbsdyml.so.0 OLD_FILES+=usr/lib32/libbsdyml_p.a OLD_FILES+=usr/share/man/man3/libbsdyml.3.gz OLD_FILES+=usr/include/bsdyml.h # 20131013: Removal of the ATF tools OLD_FILES+=etc/atf/FreeBSD.conf OLD_FILES+=etc/atf/atf-run.hooks OLD_FILES+=etc/atf/common.conf OLD_FILES+=usr/bin/atf-config OLD_FILES+=usr/bin/atf-report OLD_FILES+=usr/bin/atf-run OLD_FILES+=usr/bin/atf-version OLD_FILES+=usr/share/atf/atf-run.hooks OLD_FILES+=usr/share/examples/atf/atf-run.hooks OLD_FILES+=usr/share/examples/atf/tests-results.css OLD_FILES+=usr/share/man/man1/atf-config.1.gz OLD_FILES+=usr/share/man/man1/atf-report.1.gz OLD_FILES+=usr/share/man/man1/atf-run.1.gz OLD_FILES+=usr/share/man/man1/atf-version.1.gz OLD_FILES+=usr/share/man/man5/atf-formats.5.gz -OLD_FILES+=usr/share/man/man7/atf.7.gz OLD_FILES+=usr/share/xml/atf/tests-results.dtd OLD_FILES+=usr/share/xsl/atf/tests-results.xsl # 20131009: freebsd-version moved from /libexec to /bin OLD_FILES+=libexec/freebsd-version # 20131001: ar and ranlib from binutils not used OLD_FILES+=usr/bin/gnu-ar OLD_FILES+=usr/bin/gnu-ranlib OLD_FILES+=usr/share/man/man1/gnu-ar.1.gz OLD_FILES+=usr/share/man/man1/gnu-ranlib.1.gz # 20130930: BIND removed from base OLD_FILES+=etc/mtree/BIND.chroot.dist OLD_FILES+=etc/namedb OLD_FILES+=etc/periodic/daily/470.status-named OLD_FILES+=usr/bin/dig OLD_FILES+=usr/bin/nslookup OLD_FILES+=usr/bin/nsupdate OLD_DIRS+=usr/include/lwres OLD_FILES+=usr/include/lwres/context.h OLD_FILES+=usr/include/lwres/int.h OLD_FILES+=usr/include/lwres/ipv6.h OLD_FILES+=usr/include/lwres/lang.h OLD_FILES+=usr/include/lwres/list.h OLD_FILES+=usr/include/lwres/lwbuffer.h OLD_FILES+=usr/include/lwres/lwpacket.h OLD_FILES+=usr/include/lwres/lwres.h OLD_FILES+=usr/include/lwres/net.h OLD_FILES+=usr/include/lwres/netdb.h OLD_FILES+=usr/include/lwres/platform.h OLD_FILES+=usr/include/lwres/result.h OLD_FILES+=usr/include/lwres/version.h OLD_FILES+=usr/lib/liblwres.a OLD_FILES+=usr/lib/liblwres.so OLD_LIBS+=usr/lib/liblwres.so.90 OLD_FILES+=usr/lib/liblwres_p.a OLD_FILES+=usr/sbin/arpaname OLD_FILES+=usr/sbin/ddns-confgen OLD_FILES+=usr/sbin/dnssec-dsfromkey OLD_FILES+=usr/sbin/dnssec-keyfromlabel OLD_FILES+=usr/sbin/dnssec-keygen OLD_FILES+=usr/sbin/dnssec-revoke OLD_FILES+=usr/sbin/dnssec-settime OLD_FILES+=usr/sbin/dnssec-signzone OLD_FILES+=usr/sbin/dnssec-verify OLD_FILES+=usr/sbin/genrandom OLD_FILES+=usr/sbin/isc-hmac-fixup OLD_FILES+=usr/sbin/lwresd OLD_FILES+=usr/sbin/named OLD_FILES+=usr/sbin/named-checkconf OLD_FILES+=usr/sbin/named-checkzone OLD_FILES+=usr/sbin/named-compilezone OLD_FILES+=usr/sbin/named-journalprint OLD_FILES+=usr/sbin/named.reconfig OLD_FILES+=usr/sbin/named.reload OLD_FILES+=usr/sbin/nsec3hash OLD_FILES+=usr/sbin/rndc OLD_FILES+=usr/sbin/rndc-confgen OLD_DIRS+=usr/share/doc/bind9 OLD_FILES+=usr/share/doc/bind9/CHANGES OLD_FILES+=usr/share/doc/bind9/COPYRIGHT OLD_FILES+=usr/share/doc/bind9/FAQ OLD_FILES+=usr/share/doc/bind9/HISTORY OLD_FILES+=usr/share/doc/bind9/README OLD_DIRS+=usr/share/doc/bind9/arm OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch01.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch02.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch03.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch04.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch05.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch06.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch07.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch08.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch09.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.ch10.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.html OLD_FILES+=usr/share/doc/bind9/arm/Bv9ARM.pdf OLD_FILES+=usr/share/doc/bind9/arm/man.arpaname.html OLD_FILES+=usr/share/doc/bind9/arm/man.ddns-confgen.html OLD_FILES+=usr/share/doc/bind9/arm/man.dig.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-dsfromkey.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-keyfromlabel.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-keygen.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-revoke.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-settime.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-signzone.html OLD_FILES+=usr/share/doc/bind9/arm/man.dnssec-verify.html OLD_FILES+=usr/share/doc/bind9/arm/man.genrandom.html OLD_FILES+=usr/share/doc/bind9/arm/man.host.html OLD_FILES+=usr/share/doc/bind9/arm/man.isc-hmac-fixup.html OLD_FILES+=usr/share/doc/bind9/arm/man.named-checkconf.html OLD_FILES+=usr/share/doc/bind9/arm/man.named-checkzone.html OLD_FILES+=usr/share/doc/bind9/arm/man.named-journalprint.html OLD_FILES+=usr/share/doc/bind9/arm/man.named.html OLD_FILES+=usr/share/doc/bind9/arm/man.nsec3hash.html OLD_FILES+=usr/share/doc/bind9/arm/man.nsupdate.html OLD_FILES+=usr/share/doc/bind9/arm/man.rndc-confgen.html OLD_FILES+=usr/share/doc/bind9/arm/man.rndc.conf.html OLD_FILES+=usr/share/doc/bind9/arm/man.rndc.html OLD_DIRS+=usr/share/doc/bind9/misc OLD_FILES+=usr/share/doc/bind9/misc/dnssec OLD_FILES+=usr/share/doc/bind9/misc/format-options.pl OLD_FILES+=usr/share/doc/bind9/misc/ipv6 OLD_FILES+=usr/share/doc/bind9/misc/migration OLD_FILES+=usr/share/doc/bind9/misc/migration-4to9 OLD_FILES+=usr/share/doc/bind9/misc/options OLD_FILES+=usr/share/doc/bind9/misc/rfc-compliance OLD_FILES+=usr/share/doc/bind9/misc/roadmap OLD_FILES+=usr/share/doc/bind9/misc/sdb OLD_FILES+=usr/share/doc/bind9/misc/sort-options.pl OLD_FILES+=usr/share/man/man1/arpaname.1.gz OLD_FILES+=usr/share/man/man1/dig.1.gz OLD_FILES+=usr/share/man/man1/nslookup.1.gz OLD_FILES+=usr/share/man/man1/nsupdate.1.gz OLD_FILES+=usr/share/man/man3/lwres.3.gz OLD_FILES+=usr/share/man/man3/lwres_addr_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_add.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_back.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_clear.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_first.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_forward.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_getmem.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_getuint16.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_getuint32.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_getuint8.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_init.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_invalidate.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_putmem.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_putuint16.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_putuint32.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_putuint8.3.gz OLD_FILES+=usr/share/man/man3/lwres_buffer_subtract.3.gz OLD_FILES+=usr/share/man/man3/lwres_conf_clear.3.gz OLD_FILES+=usr/share/man/man3/lwres_conf_get.3.gz OLD_FILES+=usr/share/man/man3/lwres_conf_init.3.gz OLD_FILES+=usr/share/man/man3/lwres_conf_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_conf_print.3.gz OLD_FILES+=usr/share/man/man3/lwres_config.3.gz OLD_FILES+=usr/share/man/man3/lwres_context.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_allocmem.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_create.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_destroy.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_freemem.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_initserial.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_nextserial.3.gz OLD_FILES+=usr/share/man/man3/lwres_context_sendrecv.3.gz OLD_FILES+=usr/share/man/man3/lwres_endhostent.3.gz OLD_FILES+=usr/share/man/man3/lwres_endhostent_r.3.gz OLD_FILES+=usr/share/man/man3/lwres_freeaddrinfo.3.gz OLD_FILES+=usr/share/man/man3/lwres_freehostent.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabn.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnrequest_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnrequest_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnrequest_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnresponse_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnresponse_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_gabnresponse_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_gai_strerror.3.gz OLD_FILES+=usr/share/man/man3/lwres_getaddrinfo.3.gz OLD_FILES+=usr/share/man/man3/lwres_getaddrsbyname.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostbyaddr.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostbyaddr_r.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostbyname.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostbyname2.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostbyname_r.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostent.3.gz OLD_FILES+=usr/share/man/man3/lwres_gethostent_r.3.gz OLD_FILES+=usr/share/man/man3/lwres_getipnode.3.gz OLD_FILES+=usr/share/man/man3/lwres_getipnodebyaddr.3.gz OLD_FILES+=usr/share/man/man3/lwres_getipnodebyname.3.gz OLD_FILES+=usr/share/man/man3/lwres_getnamebyaddr.3.gz OLD_FILES+=usr/share/man/man3/lwres_getnameinfo.3.gz OLD_FILES+=usr/share/man/man3/lwres_getrrsetbyname.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnba.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbarequest_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbarequest_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbarequest_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbaresponse_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbaresponse_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_gnbaresponse_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_herror.3.gz OLD_FILES+=usr/share/man/man3/lwres_hstrerror.3.gz OLD_FILES+=usr/share/man/man3/lwres_inetntop.3.gz OLD_FILES+=usr/share/man/man3/lwres_lwpacket_parseheader.3.gz OLD_FILES+=usr/share/man/man3/lwres_lwpacket_renderheader.3.gz OLD_FILES+=usr/share/man/man3/lwres_net_ntop.3.gz OLD_FILES+=usr/share/man/man3/lwres_noop.3.gz OLD_FILES+=usr/share/man/man3/lwres_nooprequest_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_nooprequest_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_nooprequest_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_noopresponse_free.3.gz OLD_FILES+=usr/share/man/man3/lwres_noopresponse_parse.3.gz OLD_FILES+=usr/share/man/man3/lwres_noopresponse_render.3.gz OLD_FILES+=usr/share/man/man3/lwres_packet.3.gz OLD_FILES+=usr/share/man/man3/lwres_resutil.3.gz OLD_FILES+=usr/share/man/man3/lwres_sethostent.3.gz OLD_FILES+=usr/share/man/man3/lwres_sethostent_r.3.gz OLD_FILES+=usr/share/man/man3/lwres_string_parse.3.gz OLD_FILES+=usr/share/man/man5/named.conf.5.gz OLD_FILES+=usr/share/man/man5/rndc.conf.5.gz OLD_FILES+=usr/share/man/man8/ddns-confgen.8.gz OLD_FILES+=usr/share/man/man8/dnssec-dsfromkey.8.gz OLD_FILES+=usr/share/man/man8/dnssec-keyfromlabel.8.gz OLD_FILES+=usr/share/man/man8/dnssec-keygen.8.gz OLD_FILES+=usr/share/man/man8/dnssec-revoke.8.gz OLD_FILES+=usr/share/man/man8/dnssec-settime.8.gz OLD_FILES+=usr/share/man/man8/dnssec-signzone.8.gz OLD_FILES+=usr/share/man/man8/dnssec-verify.8.gz OLD_FILES+=usr/share/man/man8/genrandom.8.gz OLD_FILES+=usr/share/man/man8/isc-hmac-fixup.8.gz OLD_FILES+=usr/share/man/man8/lwresd.8.gz OLD_FILES+=usr/share/man/man8/named-checkconf.8.gz OLD_FILES+=usr/share/man/man8/named-checkzone.8.gz OLD_FILES+=usr/share/man/man8/named-compilezone.8.gz OLD_FILES+=usr/share/man/man8/named-journalprint.8.gz OLD_FILES+=usr/share/man/man8/named.8.gz OLD_FILES+=usr/share/man/man8/named.reconfig.8.gz OLD_FILES+=usr/share/man/man8/named.reload.8.gz OLD_FILES+=usr/share/man/man8/nsec3hash.8.gz OLD_FILES+=usr/share/man/man8/rndc-confgen.8.gz OLD_FILES+=usr/share/man/man8/rndc.8.gz OLD_DIRS+=var/named/dev OLD_DIRS+=var/named/etc OLD_DIRS+=var/named/etc/namedb OLD_FILES+=var/named/etc/namedb/PROTO.localhost-v6.rev OLD_FILES+=var/named/etc/namedb/PROTO.localhost.rev OLD_DIRS+=var/named/etc/namedb/dynamic OLD_FILES+=var/named/etc/namedb/make-localhost OLD_DIRS+=var/named/etc/namedb/master OLD_FILES+=var/named/etc/namedb/master/empty.db OLD_FILES+=var/named/etc/namedb/master/localhost-forward.db OLD_FILES+=var/named/etc/namedb/master/localhost-reverse.db #OLD_FILES+=var/named/etc/namedb/named.conf # intentionally left out OLD_FILES+=var/named/etc/namedb/named.root OLD_DIRS+=var/named/etc/namedb/slave OLD_DIRS+=var/named/var OLD_DIRS+=var/named/var/dump OLD_DIRS+=var/named/var/log OLD_DIRS+=var/named/var/run OLD_DIRS+=var/named/var/run/named OLD_DIRS+=var/named/var/stats OLD_DIRS+=var/run/named # 20130923: example moved OLD_FILES+=usr/share/examples/bsdconfig/browse_packages.sh # 20130908: libssh becomes private OLD_FILES+=usr/lib/libssh.a OLD_FILES+=usr/lib/libssh.so OLD_LIBS+=usr/lib/libssh.so.5 OLD_FILES+=usr/lib/libssh_p.a OLD_FILES+=usr/lib32/libssh.a OLD_FILES+=usr/lib32/libssh.so OLD_LIBS+=usr/lib32/libssh.so.5 OLD_FILES+=usr/lib32/libssh_p.a # 20130903: gnupatch is no more OLD_FILES+=usr/bin/gnupatch OLD_FILES+=usr/share/man/man1/gnupatch.1.gz # 20130829: bsdpatch is patch unconditionally OLD_FILES+=usr/bin/bsdpatch OLD_FILES+=usr/share/man/man1/bsdpatch.1.gz # 20130822: bind 9.9.3-P2 import OLD_LIBS+=usr/lib/liblwres.so.80 # 20130814: vm_page_busy(9) OLD_FILES+=usr/share/man/man9/vm_page_flash.9.gz OLD_FILES+=usr/share/man/man9/vm_page_io.9.gz OLD_FILES+=usr/share/man/man9/vm_page_io_finish.9.gz OLD_FILES+=usr/share/man/man9/vm_page_io_start.9.gz OLD_FILES+=usr/share/man/man9/vm_page_wakeup.9.gz # 20130710: libkvm version bump OLD_LIBS+=lib/libkvm.so.5 OLD_LIBS+=usr/lib32/libkvm.so.5 # 20130623: dialog update from 1.1 to 1.2 OLD_LIBS+=usr/lib/libdialog.so.7 OLD_LIBS+=usr/lib32/libdialog.so.7 # 20130616: vfs_mount.9 removed OLD_FILES+=usr/share/man/man9/vfs_mount.9.gz # 20130614: remove CVS from base OLD_FILES+=usr/bin/cvs OLD_FILES+=usr/bin/cvsbug OLD_FILES+=usr/share/doc/psd/28.cvs/paper.ascii.gz OLD_FILES+=usr/share/doc/psd/28.cvs/paper.ps.gz OLD_DIRS+=usr/share/doc/psd/28.cvs OLD_FILES+=usr/share/examples/cvs/contrib/README OLD_FILES+=usr/share/examples/cvs/contrib/clmerge OLD_FILES+=usr/share/examples/cvs/contrib/cln_hist OLD_FILES+=usr/share/examples/cvs/contrib/commit_prep OLD_FILES+=usr/share/examples/cvs/contrib/cvs2vendor OLD_FILES+=usr/share/examples/cvs/contrib/cvs_acls OLD_FILES+=usr/share/examples/cvs/contrib/cvscheck OLD_FILES+=usr/share/examples/cvs/contrib/cvscheck.man OLD_FILES+=usr/share/examples/cvs/contrib/cvshelp.man OLD_FILES+=usr/share/examples/cvs/contrib/descend.man OLD_FILES+=usr/share/examples/cvs/contrib/easy-import OLD_FILES+=usr/share/examples/cvs/contrib/intro.doc OLD_FILES+=usr/share/examples/cvs/contrib/log OLD_FILES+=usr/share/examples/cvs/contrib/log_accum OLD_FILES+=usr/share/examples/cvs/contrib/mfpipe OLD_FILES+=usr/share/examples/cvs/contrib/rcs-to-cvs OLD_FILES+=usr/share/examples/cvs/contrib/rcs2log OLD_FILES+=usr/share/examples/cvs/contrib/rcslock OLD_FILES+=usr/share/examples/cvs/contrib/sccs2rcs OLD_DIRS+=usr/share/examples/cvs/contrib OLD_DIRS+=usr/share/examples/cvs OLD_FILES+=usr/share/info/cvs.info.gz OLD_FILES+=usr/share/info/cvsclient.info.gz OLD_FILES+=usr/share/man/man1/cvs.1.gz OLD_FILES+=usr/share/man/man5/cvs.5.gz OLD_FILES+=usr/share/man/man8/cvsbug.8.gz # 20130607: WITH_DEBUG_FILES added OLD_FILES+=lib/libufs.so.6.symbols OLD_FILES+=usr/lib32/libufs.so.6.symbols # 20130417: nfs fha moved from nfsserver to nfs OLD_FILES+=usr/include/nfsserver/nfs_fha.h # 20130411: new clang import which bumps version from 3.2 to 3.3. OLD_FILES+=usr/include/clang/3.2/__wmmintrin_aes.h OLD_FILES+=usr/include/clang/3.2/__wmmintrin_pclmul.h OLD_FILES+=usr/include/clang/3.2/altivec.h OLD_FILES+=usr/include/clang/3.2/ammintrin.h OLD_FILES+=usr/include/clang/3.2/avx2intrin.h OLD_FILES+=usr/include/clang/3.2/avxintrin.h OLD_FILES+=usr/include/clang/3.2/bmi2intrin.h OLD_FILES+=usr/include/clang/3.2/bmiintrin.h OLD_FILES+=usr/include/clang/3.2/cpuid.h OLD_FILES+=usr/include/clang/3.2/emmintrin.h OLD_FILES+=usr/include/clang/3.2/f16cintrin.h OLD_FILES+=usr/include/clang/3.2/fma4intrin.h OLD_FILES+=usr/include/clang/3.2/fmaintrin.h OLD_FILES+=usr/include/clang/3.2/immintrin.h OLD_FILES+=usr/include/clang/3.2/lzcntintrin.h OLD_FILES+=usr/include/clang/3.2/mm3dnow.h OLD_FILES+=usr/include/clang/3.2/mm_malloc.h OLD_FILES+=usr/include/clang/3.2/mmintrin.h OLD_FILES+=usr/include/clang/3.2/module.map OLD_FILES+=usr/include/clang/3.2/nmmintrin.h OLD_FILES+=usr/include/clang/3.2/pmmintrin.h OLD_FILES+=usr/include/clang/3.2/popcntintrin.h OLD_FILES+=usr/include/clang/3.2/rtmintrin.h OLD_FILES+=usr/include/clang/3.2/smmintrin.h OLD_FILES+=usr/include/clang/3.2/tmmintrin.h OLD_FILES+=usr/include/clang/3.2/wmmintrin.h OLD_FILES+=usr/include/clang/3.2/x86intrin.h OLD_FILES+=usr/include/clang/3.2/xmmintrin.h OLD_FILES+=usr/include/clang/3.2/xopintrin.h OLD_DIRS+=usr/include/clang/3.2 # 20130404: legacy ATA stack removed OLD_FILES+=etc/periodic/daily/405.status-ata-raid OLD_FILES+=rescue/atacontrol OLD_FILES+=sbin/atacontrol OLD_FILES+=usr/share/man/man8/atacontrol.8.gz OLD_FILES+=usr/share/man/man4/atapicam.4.gz OLD_FILES+=usr/share/man/man4/ataraid.4.gz OLD_FILES+=usr/sbin/burncd OLD_FILES+=usr/share/man/man8/burncd.8.gz # 20130316: vinum.4 removed OLD_FILES+=usr/share/man/man4/vinum.4.gz # 20130312: fortunes-o removed OLD_FILES+=usr/share/games/fortune/fortunes-o OLD_FILES+=usr/share/games/fortune/fortunes-o.dat # 20130311: Ports are no more available via cvsup OLD_FILES+=usr/share/examples/cvsup/ports-supfile OLD_FILES+=usr/share/examples/cvsup/refuse OLD_FILES+=usr/share/examples/cvsup/refuse.README # 20130309: NWFS and NCP supports removed OLD_FILES+=usr/bin/ncplist OLD_FILES+=usr/bin/ncplogin OLD_FILES+=usr/bin/ncplogout OLD_FILES+=usr/include/fs/nwfs/nwfs.h OLD_FILES+=usr/include/fs/nwfs/nwfs_mount.h OLD_FILES+=usr/include/fs/nwfs/nwfs_node.h OLD_FILES+=usr/include/fs/nwfs/nwfs_subr.h OLD_DIRS+=usr/include/fs/nwfs OLD_FILES+=usr/include/netncp/ncp.h OLD_FILES+=usr/include/netncp/ncp_cfg.h OLD_FILES+=usr/include/netncp/ncp_conn.h OLD_FILES+=usr/include/netncp/ncp_file.h OLD_FILES+=usr/include/netncp/ncp_lib.h OLD_FILES+=usr/include/netncp/ncp_ncp.h OLD_FILES+=usr/include/netncp/ncp_nls.h OLD_FILES+=usr/include/netncp/ncp_rcfile.h OLD_FILES+=usr/include/netncp/ncp_rq.h OLD_FILES+=usr/include/netncp/ncp_sock.h OLD_FILES+=usr/include/netncp/ncp_subr.h OLD_FILES+=usr/include/netncp/ncp_user.h OLD_FILES+=usr/include/netncp/ncpio.h OLD_FILES+=usr/include/netncp/nwerror.h OLD_DIRS+=usr/include/netncp OLD_FILES+=usr/lib/libncp.a OLD_FILES+=usr/lib/libncp.so OLD_LIBS+=usr/lib/libncp.so.4 OLD_FILES+=usr/lib/libncp_p.a OLD_FILES+=usr/lib32/libncp.a OLD_FILES+=usr/lib32/libncp.so OLD_LIBS+=usr/lib32/libncp.so.4 OLD_FILES+=usr/lib32/libncp_p.a OLD_FILES+=usr/sbin/mount_nwfs OLD_FILES+=usr/share/examples/nwclient/dot.nwfsrc OLD_FILES+=usr/share/examples/nwclient/nwfs.sh.sample OLD_DIRS+=usr/share/examples/nwclient OLD_FILES+=usr/share/man/man1/ncplist.1.gz OLD_FILES+=usr/share/man/man1/ncplogin.1.gz OLD_FILES+=usr/share/man/man1/ncplogout.1.gz OLD_FILES+=usr/share/man/man8/mount_nwfs.8.gz # 20130302: NTFS support removed OLD_FILES+=rescue/mount_ntfs OLD_FILES+=sbin/mount_ntfs OLD_FILES+=usr/include/fs/ntfs/ntfs.h OLD_FILES+=usr/include/fs/ntfs/ntfs_compr.h OLD_FILES+=usr/include/fs/ntfs/ntfs_ihash.h OLD_FILES+=usr/include/fs/ntfs/ntfs_inode.h OLD_FILES+=usr/include/fs/ntfs/ntfs_subr.h OLD_FILES+=usr/include/fs/ntfs/ntfs_vfsops.h OLD_FILES+=usr/include/fs/ntfs/ntfsmount.h OLD_DIRS+=usr/include/fs/ntfs OLD_FILES+=usr/share/man/man8/mount_ntfs.8.gz # 20130302: PORTALFS support removed OLD_FILES+=usr/include/fs/portalfs/portal.h OLD_DIRS+=usr/include/fs/portalfs OLD_FILES+=usr/sbin/mount_portalfs OLD_FILES+=usr/share/examples/portal/README OLD_FILES+=usr/share/examples/portal/portal.conf OLD_DIRS+=usr/share/examples/portal OLD_FILES+=usr/share/man/man8/mount_portalfs.8.gz # 20130302: CODAFS support removed OLD_FILES+=usr/share/man/man4/coda.4.gz # 20130302: XFS support removed OLD_FILES+=usr/share/man/man5/xfs.5.gz # 20130302: Capsicum overhaul OLD_FILES+=usr/share/man/man2/cap_getrights.2.gz OLD_FILES+=usr/share/man/man2/cap_new.2.gz # 20130213: OpenSSL 1.0.1e import OLD_FILES+=usr/share/openssl/man/man3/EVP_PKEY_verifyrecover.3.gz OLD_FILES+=usr/share/openssl/man/man3/EVP_PKEY_verifyrecover_init.3.gz # 20130116: removed long unused directories for .1aout section manpages OLD_FILES+=usr/share/man/en.ISO8859-1/man1aout OLD_FILES+=usr/share/man/en.UTF-8/man1aout OLD_DIRS+=usr/share/man/man1aout OLD_DIRS+=usr/share/man/cat1aout OLD_DIRS+=usr/share/man/en.ISO8859-1/cat1aout OLD_DIRS+=usr/share/man/en.UTF-8/cat1aout # 20130110: bsd.compat.mk removed OLD_FILES+=usr/share/mk/bsd.compat.mk # 20130103: gnats-supfile removed OLD_FILES+=usr/share/examples/cvsup/gnats-supfile # 20121230: libdisk removed OLD_FILES+=usr/share/man/man3/libdisk.3.gz usr/include/libdisk.h OLD_FILES+=usr/lib/libdisk.a usr/lib32/libdisk.a # 20121230: remove wrongly created directories for auditdistd OLD_DIRS+=var/dist OLD_DIRS+=var/remote # 20121114: zpool-features manual page moved from section 5 to 7 OLD_FILES+=usr/share/man/man5/zpool-features.5.gz # 20121022: remove harp, hfa and idt man page OLD_FILES+=usr/share/man/man4/harp.4.gz OLD_FILES+=usr/share/man/man4/hfa.4.gz OLD_FILES+=usr/share/man/man4/idt.4.gz OLD_FILES+=usr/share/man/man4/if_idt.4.gz # 20121022: VFS_LOCK_GIANT elimination OLD_FILES+=usr/share/man/man9/VFS_LOCK_GIANT.9.gz OLD_FILES+=usr/share/man/man9/VFS_UNLOCK_GIANT.9.gz # 20121004: remove incomplete unwind.h OLD_FILES+=usr/include/clang/3.2/unwind.h # 20120910: NetBSD compat shims removed OLD_FILES+=usr/include/cam/scsi/scsi_low_pisa.h OLD_FILES+=usr/include/sys/device_port.h # 20120909: doc and www supfiles removed OLD_FILES+=usr/share/examples/cvsup/doc-supfile OLD_FILES+=usr/share/examples/cvsup/www-supfile # 20120908: pf cleanup OLD_FILES+=usr/include/net/if_pflow.h # 20120816: new clang import which bumps version from 3.1 to 3.2 OLD_FILES+=usr/bin/llvm-ld OLD_FILES+=usr/bin/llvm-stub OLD_FILES+=usr/include/clang/3.1/altivec.h OLD_FILES+=usr/include/clang/3.1/avx2intrin.h OLD_FILES+=usr/include/clang/3.1/avxintrin.h OLD_FILES+=usr/include/clang/3.1/bmi2intrin.h OLD_FILES+=usr/include/clang/3.1/bmiintrin.h OLD_FILES+=usr/include/clang/3.1/cpuid.h OLD_FILES+=usr/include/clang/3.1/emmintrin.h OLD_FILES+=usr/include/clang/3.1/fma4intrin.h OLD_FILES+=usr/include/clang/3.1/immintrin.h OLD_FILES+=usr/include/clang/3.1/lzcntintrin.h OLD_FILES+=usr/include/clang/3.1/mm3dnow.h OLD_FILES+=usr/include/clang/3.1/mm_malloc.h OLD_FILES+=usr/include/clang/3.1/mmintrin.h OLD_FILES+=usr/include/clang/3.1/module.map OLD_FILES+=usr/include/clang/3.1/nmmintrin.h OLD_FILES+=usr/include/clang/3.1/pmmintrin.h OLD_FILES+=usr/include/clang/3.1/popcntintrin.h OLD_FILES+=usr/include/clang/3.1/smmintrin.h OLD_FILES+=usr/include/clang/3.1/tmmintrin.h OLD_FILES+=usr/include/clang/3.1/unwind.h OLD_FILES+=usr/include/clang/3.1/wmmintrin.h OLD_FILES+=usr/include/clang/3.1/x86intrin.h OLD_FILES+=usr/include/clang/3.1/xmmintrin.h OLD_DIRS+=usr/include/clang/3.1 OLD_FILES+=usr/share/man/man1/llvm-ld.1.gz # 20120712: OpenSSL 1.0.1c import OLD_LIBS+=lib/libcrypto.so.6 OLD_LIBS+=usr/lib/libssl.so.6 OLD_LIBS+=usr/lib32/libcrypto.so.6 OLD_LIBS+=usr/lib32/libssl.so.6 OLD_FILES+=usr/include/openssl/aes_locl.h OLD_FILES+=usr/include/openssl/bio_lcl.h OLD_FILES+=usr/include/openssl/e_os.h OLD_FILES+=usr/include/openssl/fips.h OLD_FILES+=usr/include/openssl/fips_rand.h OLD_FILES+=usr/include/openssl/md2.h OLD_FILES+=usr/include/openssl/pq_compat.h OLD_FILES+=usr/include/openssl/store.h OLD_FILES+=usr/include/openssl/tmdiff.h OLD_FILES+=usr/include/openssl/ui_locl.h OLD_FILES+=usr/share/openssl/man/man3/CRYPTO_set_id_callback.3.gz # 20120621: remove old man page OLD_FILES+=usr/share/man/man8/vnconfig.8.gz # 20120619: TOE support updated OLD_FILES+=usr/include/netinet/toedev.h # 20120613: auth.conf removed OLD_FILES+=etc/auth.conf OLD_FILES+=usr/share/examples/etc/auth.conf OLD_FILES+=usr/share/man/man3/auth.3.gz OLD_FILES+=usr/share/man/man3/auth_getval.3.gz OLD_FILES+=usr/share/man/man5/auth.conf.5.gz # 20120530: kde pam lives now in ports OLD_FILES+=etc/pam.d/kde # 20120521: byacc import OLD_FILES+=usr/bin/yyfix OLD_FILES+=usr/share/man/man1/yyfix.1.gz # 20120505: new clang import installed a redundant internal header OLD_FILES+=usr/include/clang/3.1/stdalign.h # 20120428: MD2 removed from libmd OLD_LIBS+=lib/libmd.so.5 OLD_FILES+=usr/include/md2.h OLD_LIBS+=usr/lib32/libmd.so.5 OLD_FILES+=usr/share/man/man3/MD2Data.3.gz OLD_FILES+=usr/share/man/man3/MD2End.3.gz OLD_FILES+=usr/share/man/man3/MD2File.3.gz OLD_FILES+=usr/share/man/man3/MD2FileChunk.3.gz OLD_FILES+=usr/share/man/man3/MD2Final.3.gz OLD_FILES+=usr/share/man/man3/MD2Init.3.gz OLD_FILES+=usr/share/man/man3/MD2Update.3.gz OLD_FILES+=usr/share/man/man3/md2.3.gz # 20120425: libusb version bump (r234684) OLD_LIBS+=usr/lib/libusb.so.2 OLD_LIBS+=usr/lib32/libusb.so.2 OLD_FILES+=usr/share/man/man3/libsub_get_active_config_descriptor.3.gz # 20120415: new clang import which bumps version from 3.0 to 3.1 OLD_FILES+=usr/include/clang/3.0/altivec.h OLD_FILES+=usr/include/clang/3.0/avxintrin.h OLD_FILES+=usr/include/clang/3.0/emmintrin.h OLD_FILES+=usr/include/clang/3.0/immintrin.h OLD_FILES+=usr/include/clang/3.0/mm3dnow.h OLD_FILES+=usr/include/clang/3.0/mm_malloc.h OLD_FILES+=usr/include/clang/3.0/mmintrin.h OLD_FILES+=usr/include/clang/3.0/nmmintrin.h OLD_FILES+=usr/include/clang/3.0/pmmintrin.h OLD_FILES+=usr/include/clang/3.0/smmintrin.h OLD_FILES+=usr/include/clang/3.0/tmmintrin.h OLD_FILES+=usr/include/clang/3.0/wmmintrin.h OLD_FILES+=usr/include/clang/3.0/x86intrin.h OLD_FILES+=usr/include/clang/3.0/xmmintrin.h OLD_DIRS+=usr/include/clang/3.0 # 20120412: BIND 9.8.1 release notes removed OLD_FILES+=usr/share/doc/bind9/RELEASE-NOTES-BIND-9.8.1.pdf OLD_FILES+=usr/share/doc/bind9/RELEASE-NOTES-BIND-9.8.1.txt OLD_FILES+=usr/share/doc/bind9/RELEASE-NOTES-BIND-9.8.1.html OLD_FILES+=usr/share/doc/bind9/release-notes.css # 20120330: legacy(4) moved to x86 OLD_FILES+=usr/include/machine/legacyvar.h # 20120324: MPI headers updated OLD_FILES+=usr/include/dev/mpt/mpilib/mpi_inb.h # 20120322: hwpmc_mips24k.h removed OLD_FILES+=usr/include/dev/hwpmc/hwpmc_mips24k.h # 20120322: Update heimdal to 1.5.1. OLD_FILES+=usr/include/krb5-v4compat.h \ usr/include/krb_err.h \ usr/include/hdb-private.h \ usr/share/man/man3/krb5_addresses.3.gz \ usr/share/man/man3/krb5_cc_cursor.3.gz \ usr/share/man/man3/krb5_cc_ops.3.gz \ usr/share/man/man3/krb5_config.3.gz \ usr/share/man/man3/krb5_config_get_int_default.3.gz \ usr/share/man/man3/krb5_context.3.gz \ usr/share/man/man3/krb5_data.3.gz \ usr/share/man/man3/krb5_err.3.gz \ usr/share/man/man3/krb5_errx.3.gz \ usr/share/man/man3/krb5_keyblock.3.gz \ usr/share/man/man3/krb5_keytab_entry.3.gz \ usr/share/man/man3/krb5_kt_cursor.3.gz \ usr/share/man/man3/krb5_kt_ops.3.gz \ usr/share/man/man3/krb5_set_warn_dest.3.gz \ usr/share/man/man3/krb5_verr.3.gz \ usr/share/man/man3/krb5_verrx.3.gz \ usr/share/man/man3/krb5_vwarnx.3.gz \ usr/share/man/man3/krb5_warn.3.gz \ usr/share/man/man3/krb5_warnx.3.gz OLD_LIBS+=usr/lib/libasn1.so.10 \ usr/lib/libhdb.so.10 \ usr/lib/libheimntlm.so.10 \ usr/lib/libhx509.so.10 \ usr/lib/libkadm5clnt.so.10 \ usr/lib/libkadm5srv.so.10 \ usr/lib/libkafs5.so.10 \ usr/lib/libkrb5.so.10 \ usr/lib/libroken.so.10 \ usr/lib32/libasn1.so.10 \ usr/lib32/libhdb.so.10 \ usr/lib32/libheimntlm.so.10 \ usr/lib32/libhx509.so.10 \ usr/lib32/libkadm5clnt.so.10 \ usr/lib32/libkadm5srv.so.10 \ usr/lib32/libkafs5.so.10 \ usr/lib32/libkrb5.so.10 \ usr/lib32/libroken.so.10 # 20120309: Remove fifofs header files. OLD_FILES+=usr/include/fs/fifofs/fifo.h OLD_DIRS+=usr/include/fs/fifofs # 20120304: xlocale cleanup OLD_FILES+=usr/include/_xlocale_ctype.h # 20120225: libarchive 3.0.3 OLD_FILES+=usr/share/man/man3/archive_read_data_into_buffer.3.gz \ usr/share/man/man3/archive_read_support_compression_all.3.gz \ usr/share/man/man3/archive_read_support_compression_bzip2.3.gz \ usr/share/man/man3/archive_read_support_compression_compress.3.gz \ usr/share/man/man3/archive_read_support_compression_gzip.3.gz \ usr/share/man/man3/archive_read_support_compression_lzma.3.gz \ usr/share/man/man3/archive_read_support_compression_none.3.gz \ usr/share/man/man3/archive_read_support_compression_program.3.gz \ usr/share/man/man3/archive_read_support_compression_program_signature.3.gz \ usr/share/man/man3/archive_read_support_compression_xz.3.gz \ usr/share/man/man3/archive_write_set_callbacks.3.gz \ usr/share/man/man3/archive_write_set_compression_bzip2.3.gz \ usr/share/man/man3/archive_write_set_compression_compress.3.gz \ usr/share/man/man3/archive_write_set_compression_gzip.3.gz \ usr/share/man/man3/archive_write_set_compression_none.3.gz \ usr/share/man/man3/archive_write_set_compression_program.3.gz OLD_LIBS+=usr/lib/libarchive.so.5 OLD_LIBS+=usr/lib32/libarchive.so.5 # 20120113: removal of wtmpcvt(1) OLD_FILES+=usr/bin/wtmpcvt OLD_FILES+=usr/share/man/man1/wtmpcvt.1.gz # 20111214: eventtimers(7) moved to eventtimers(4) OLD_FILES+=usr/share/man/man7/eventtimers.7.gz # 20111125: amd(4) removed OLD_FILES+=usr/share/man/man4/amd.4.gz # 20111125: libodialog removed OLD_FILES+=usr/lib/libodialog.a OLD_FILES+=usr/lib/libodialog.so OLD_LIBS+=usr/lib/libodialog.so.7 OLD_FILES+=usr/lib/libodialog_p.a OLD_FILES+=usr/lib32/libodialog.a OLD_FILES+=usr/lib32/libodialog.so OLD_LIBS+=usr/lib32/libodialog.so.7 OLD_FILES+=usr/lib32/libodialog_p.a # 20110930: sysinstall removed OLD_FILES+=usr/sbin/sysinstall OLD_FILES+=usr/share/man/man8/sysinstall.8.gz OLD_FILES+=usr/lib/libftpio.a OLD_FILES+=usr/lib/libftpio.so OLD_LIBS+=usr/lib/libftpio.so.8 OLD_FILES+=usr/lib/libftpio_p.a OLD_FILES+=usr/lib32/libftpio.a OLD_FILES+=usr/lib32/libftpio.so OLD_LIBS+=usr/lib32/libftpio.so.8 OLD_FILES+=usr/lib32/libftpio_p.a OLD_FILES+=usr/include/ftpio.h OLD_FILES+=usr/share/man/man3/ftpio.3.gz # 20110915: rename congestion control manpages OLD_FILES+=usr/share/man/man4/cc.4.gz OLD_FILES+=usr/share/man/man9/cc.9.gz # 20110831: atomic page flags operations OLD_FILES+=usr/share/man/man9/vm_page_flag.9.gz OLD_FILES+=usr/share/man/man9/vm_page_flag_clear.9.gz OLD_FILES+=usr/share/man/man9/vm_page_flag_set.9.gz # 20110828: library version bump for 9.0 OLD_LIBS+=lib/libcam.so.5 OLD_LIBS+=lib/libpcap.so.7 OLD_LIBS+=lib/libufs.so.5 OLD_LIBS+=usr/lib/libbsnmp.so.5 OLD_LIBS+=usr/lib/libdwarf.so.2 OLD_LIBS+=usr/lib/libopie.so.6 OLD_LIBS+=usr/lib/librtld_db.so.1 OLD_LIBS+=usr/lib/libtacplus.so.4 OLD_LIBS+=usr/lib32/libcam.so.5 OLD_LIBS+=usr/lib32/libpcap.so.7 OLD_LIBS+=usr/lib32/libufs.so.5 OLD_LIBS+=usr/lib32/libbsnmp.so.5 OLD_LIBS+=usr/lib32/libdwarf.so.2 OLD_LIBS+=usr/lib32/libopie.so.6 OLD_LIBS+=usr/lib32/librtld_db.so.1 OLD_LIBS+=usr/lib32/libtacplus.so.4 # 20110817: no more acd.4, ad.4, afd.4 and ast.4 OLD_FILES+=usr/share/man/man4/acd.4.gz OLD_FILES+=usr/share/man/man4/ad.4.gz OLD_FILES+=usr/share/man/man4/afd.4.gz OLD_FILES+=usr/share/man/man4/ast.4.gz # 20110718: no longer useful in the age of rc.d OLD_FILES+=usr/sbin/named.reconfig OLD_FILES+=usr/sbin/named.reload OLD_FILES+=usr/share/man/man8/named.reconfig.8.gz OLD_FILES+=usr/share/man/man8/named.reload.8.gz # 20110716: bind 9.8.0 import OLD_LIBS+=usr/lib/liblwres.so.50 OLD_FILES+=usr/share/doc/bind9/KNOWN-DEFECTS OLD_FILES+=usr/share/doc/bind9/NSEC3-NOTES OLD_FILES+=usr/share/doc/bind9/README.idnkit OLD_FILES+=usr/share/doc/bind9/README.pkcs11 # 20110709: vm_map_clean.9 -> vm_map_sync.9 OLD_FILES+=usr/share/man/man9/vm_map_clean.9.gz # 20110709: Catch up with removal of these functions. OLD_FILES+=usr/share/man/man9/vm_page_copy.9.gz OLD_FILES+=usr/share/man/man9/vm_page_protect.9.gz OLD_FILES+=usr/share/man/man9/vm_page_zero_fill.9.gz # 20110707: script no longer needed by /etc/rc.d/nfsd OLD_FILES+=etc/rc.d/nfsserver # 20110705: files moved so both NFS clients can share them OLD_FILES+=usr/include/nfsclient/krpc.h OLD_FILES+=usr/include/nfsclient/nfsdiskless.h # 20110705: the switch of default NFS client to the new one OLD_FILES+=sbin/mount_newnfs OLD_FILES+=usr/share/man/man8/mount_newnfs.8.gz OLD_FILES+=usr/include/nfsclient/nfs_kdtrace.h # 20110628: calendar.msk removed OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.msk # 20110517: libpkg removed OLD_FILES+=usr/include/pkg.h OLD_FILES+=usr/lib/libpkg.a OLD_FILES+=usr/lib/libpkg.so OLD_LIBS+=usr/lib/libpkg.so.0 OLD_FILES+=usr/lib/libpkg_p.a OLD_FILES+=usr/lib32/libpkg.a OLD_FILES+=usr/lib32/libpkg.so OLD_LIBS+=usr/lib32/libpkg.so.0 OLD_FILES+=usr/lib32/libpkg_p.a # 20110517: libsbuf version bump OLD_LIBS+=lib/libsbuf.so.5 OLD_LIBS+=usr/lib32/libsbuf.so.5 # 20110502: new clang import which bumps version from 2.9 to 3.0 OLD_FILES+=usr/include/clang/2.9/emmintrin.h OLD_FILES+=usr/include/clang/2.9/mm_malloc.h OLD_FILES+=usr/include/clang/2.9/mmintrin.h OLD_FILES+=usr/include/clang/2.9/pmmintrin.h OLD_FILES+=usr/include/clang/2.9/tmmintrin.h OLD_FILES+=usr/include/clang/2.9/xmmintrin.h OLD_DIRS+=usr/include/clang/2.9 # 20110417: removal of Objective-C support OLD_FILES+=usr/include/objc/encoding.h OLD_FILES+=usr/include/objc/hash.h OLD_FILES+=usr/include/objc/NXConstStr.h OLD_FILES+=usr/include/objc/objc-api.h OLD_FILES+=usr/include/objc/objc-decls.h OLD_FILES+=usr/include/objc/objc-list.h OLD_FILES+=usr/include/objc/objc.h OLD_FILES+=usr/include/objc/Object.h OLD_FILES+=usr/include/objc/Protocol.h OLD_FILES+=usr/include/objc/runtime.h OLD_FILES+=usr/include/objc/sarray.h OLD_FILES+=usr/include/objc/thr.h OLD_FILES+=usr/include/objc/typedstream.h OLD_FILES+=usr/lib/libobjc.a OLD_FILES+=usr/lib/libobjc.so OLD_FILES+=usr/lib/libobjc_p.a OLD_FILES+=usr/libexec/cc1obj OLD_LIBS+=usr/lib/libobjc.so.4 OLD_DIRS+=usr/include/objc OLD_FILES+=usr/lib32/libobjc.a OLD_FILES+=usr/lib32/libobjc.so OLD_FILES+=usr/lib32/libobjc_p.a OLD_LIBS+=usr/lib32/libobjc.so.4 # 20110331: firmware.img created at build time OLD_FILES+=usr/share/examples/kld/firmware/fwimage/firmware.img # 20110224: sticky.8 -> sticky.7 OLD_FILES+=usr/share/man/man8/sticky.8.gz # 20110220: new clang import which bumps version from 2.8 to 2.9 OLD_FILES+=usr/include/clang/2.8/emmintrin.h OLD_FILES+=usr/include/clang/2.8/mm_malloc.h OLD_FILES+=usr/include/clang/2.8/mmintrin.h OLD_FILES+=usr/include/clang/2.8/pmmintrin.h OLD_FILES+=usr/include/clang/2.8/tmmintrin.h OLD_FILES+=usr/include/clang/2.8/xmmintrin.h OLD_DIRS+=usr/include/clang/2.8 # 20110119: netinet/sctp_cc_functions.h removed OLD_FILES+=usr/include/netinet/sctp_cc_functions.h # 20110119: Remove SYSCTL_*X* sysctl additions. OLD_FILES+=usr/share/man/man9/SYSCTL_XINT.9.gz \ usr/share/man/man9/SYSCTL_XLONG.9.gz # 20110112: Update dialog to new version, rename old libdialog to libodialog, # removing associated man pages and header files. OLD_FILES+=usr/share/man/man3/draw_shadow.3.gz \ usr/share/man/man3/draw_box.3.gz usr/share/man/man3/line_edit.3.gz \ usr/share/man/man3/strheight.3.gz usr/share/man/man3/strwidth.3.gz \ usr/share/man/man3/dialog_create_rc.3.gz \ usr/share/man/man3/dialog_yesno.3.gz usr/share/man/man3/dialog_noyes.3.gz \ usr/share/man/man3/dialog_prgbox.3.gz \ usr/share/man/man3/dialog_textbox.3.gz usr/share/man/man3/dialog_menu.3.gz \ usr/share/man/man3/dialog_checklist.3.gz \ usr/share/man/man3/dialog_radiolist.3.gz \ usr/share/man/man3/dialog_inputbox.3.gz \ usr/share/man/man3/dialog_clear_norefresh.3.gz \ usr/share/man/man3/dialog_clear.3.gz usr/share/man/man3/dialog_update.3.gz \ usr/share/man/man3/dialog_fselect.3.gz \ usr/share/man/man3/dialog_notify.3.gz \ usr/share/man/man3/dialog_mesgbox.3.gz \ usr/share/man/man3/dialog_gauge.3.gz usr/share/man/man3/init_dialog.3.gz \ usr/share/man/man3/end_dialog.3.gz usr/share/man/man3/use_helpfile.3.gz \ usr/share/man/man3/use_helpline.3.gz usr/share/man/man3/get_helpline.3.gz \ usr/share/man/man3/restore_helpline.3.gz \ usr/share/man/man3/dialog_msgbox.3.gz \ usr/share/man/man3/dialog_ftree.3.gz usr/share/man/man3/dialog_tree.3.gz \ usr/share/examples/dialog/README usr/share/examples/dialog/checklist \ usr/share/examples/dialog/ftreebox usr/share/examples/dialog/infobox \ usr/share/examples/dialog/inputbox usr/share/examples/dialog/menubox \ usr/share/examples/dialog/msgbox usr/share/examples/dialog/prgbox \ usr/share/examples/dialog/radiolist usr/share/examples/dialog/textbox \ usr/share/examples/dialog/treebox usr/share/examples/dialog/yesno \ usr/share/examples/libdialog/Makefile usr/share/examples/libdialog/check1.c\ usr/share/examples/libdialog/check2.c usr/share/examples/libdialog/check3.c\ usr/share/examples/libdialog/dselect.c \ usr/share/examples/libdialog/fselect.c \ usr/share/examples/libdialog/ftree1.c \ usr/share/examples/libdialog/ftree1.test \ usr/share/examples/libdialog/ftree2.c \ usr/share/examples/libdialog/ftree2.test \ usr/share/examples/libdialog/gauge.c usr/share/examples/libdialog/input1.c \ usr/share/examples/libdialog/input2.c usr/share/examples/libdialog/menu1.c \ usr/share/examples/libdialog/menu2.c usr/share/examples/libdialog/menu3.c \ usr/share/examples/libdialog/msg.c usr/share/examples/libdialog/prgbox.c \ usr/share/examples/libdialog/radio1.c usr/share/examples/libdialog/radio2.c\ usr/share/examples/libdialog/radio3.c usr/share/examples/libdialog/text.c \ usr/share/examples/libdialog/tree.c usr/share/examples/libdialog/yesno.c OLD_DIRS+=usr/share/examples/libdialog usr/share/examples/dialog # 20101114: Remove long-obsolete MAKEDEV.8 OLD_FILES+=usr/share/man/man8/MAKEDEV.8.gz # 20101112: vgonel(9) has gone to private API a while ago OLD_FILES+=usr/share/man/man9/vgonel.9.gz # 20101112: removed gasp.info OLD_FILES+=usr/share/info/gasp.info.gz # 20101109: machine/mutex.h removed OLD_FILES+=usr/include/machine/mutex.h # 20101109: headers moved from machine/ to x86/ .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/mptable.h .endif # 20101101: headers moved from machine/ to x86/ .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/apicreg.h OLD_FILES+=usr/include/machine/mca.h .endif # 20101020: catch up with vm_page_sleep_if_busy rename OLD_FILES+=usr/share/man/man9/vm_page_sleep_busy.9.gz # 20101018: taskqueue(9) updates OLD_FILES+=usr/share/man/man9/taskqueue_find.9.gz # 20101011: removed subblock.h from liblzma OLD_FILES+=usr/include/lzma/subblock.h # 20101002: removed manpath.config OLD_FILES+=etc/manpath.config OLD_FILES+=usr/share/examples/etc/manpath.config # 20100910: renamed sbuf_overflowed to sbuf_error OLD_FILES+=usr/share/man/man9/sbuf_overflowed.9.gz # 20100815: retired last traces of chooseproc(9) OLD_FILES+=usr/share/man/man9/chooseproc.9.gz # 20100806: removal of unused libcompat routines OLD_FILES+=usr/share/man/man3/ascftime.3.gz OLD_FILES+=usr/share/man/man3/cfree.3.gz OLD_FILES+=usr/share/man/man3/cftime.3.gz OLD_FILES+=usr/share/man/man3/getpw.3.gz # 20100801: tzdata2010k import OLD_FILES+=usr/share/zoneinfo/Pacific/Ponape OLD_FILES+=usr/share/zoneinfo/Pacific/Truk # 20100725: acpi_aiboost(4) removal. OLD_FILES+=usr/share/man/man4/acpi_aiboost.4.gz # 20100724: nfsclient/nfs_lock.h moved to nfs/nfs_lock.h OLD_FILES+=usr/include/nfsclient/nfs_lock.h # 20100720: new clang import which bumps version from 2.0 to 2.8 OLD_FILES+=usr/include/clang/2.0/emmintrin.h OLD_FILES+=usr/include/clang/2.0/mm_malloc.h OLD_FILES+=usr/include/clang/2.0/mmintrin.h OLD_FILES+=usr/include/clang/2.0/pmmintrin.h OLD_FILES+=usr/include/clang/2.0/tmmintrin.h OLD_FILES+=usr/include/clang/2.0/xmmintrin.h OLD_DIRS+=usr/include/clang/2.0 # 20100706: removed pc-sysinstall's detect-vmware.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/detect-vmware.sh # 20100701: [powerpc] removed .if ${TARGET_ARCH} == "powerpc" OLD_FILES+=usr/include/machine/intr.h .endif # 20100514: library version bump for versioned symbols for liblzma OLD_LIBS+=usr/lib/liblzma.so.0 OLD_LIBS+=usr/lib32/liblzma.so.0 # 20100511: move GCC-specific headers to /usr/include/gcc .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/emmintrin.h OLD_FILES+=usr/include/mm_malloc.h OLD_FILES+=usr/include/pmmintrin.h OLD_FILES+=usr/include/xmmintrin.h .endif .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "arm" OLD_FILES+=usr/include/mmintrin.h .endif .if ${TARGET_ARCH} == "powerpc" OLD_FILES+=usr/include/altivec.h OLD_FILES+=usr/include/ppc-asm.h OLD_FILES+=usr/include/spe.h .endif # 20100416: [mips] removed .if ${TARGET_ARCH} == "mips" OLD_FILES+=usr/include/machine/psl.h .endif # 20100415: [mips] removed unused headers .if ${TARGET_ARCH} == "mips" OLD_FILES+=usr/include/machine/archtype.h OLD_FILES+=usr/include/machine/segments.h OLD_FILES+=usr/include/machine/rm7000.h OLD_FILES+=usr/include/machine/defs.h OLD_FILES+=usr/include/machine/queue.h .endif # 20100326: gcpio removal OLD_FILES+=usr/bin/gcpio OLD_FILES+=usr/share/info/cpio.info.gz OLD_FILES+=usr/share/man/man1/gcpio.1.gz # 20100322: libz update OLD_LIBS+=lib/libz.so.5 OLD_LIBS+=usr/lib32/libz.so.5 # 20100314: removal of regexp.h OLD_FILES+=usr/include/regexp.h OLD_FILES+=usr/share/man/man3/regexp.3.gz OLD_FILES+=usr/share/man/man3/regsub.3.gz # 20100303: actual removal of utmp.h OLD_FILES+=usr/include/utmp.h # 20100208: man pages moved .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/share/man/man4/i386/alpm.4.gz OLD_FILES+=usr/share/man/man4/i386/amdpm.4.gz OLD_FILES+=usr/share/man/man4/i386/mcd.4.gz OLD_FILES+=usr/share/man/man4/i386/padlock.4.gz OLD_FILES+=usr/share/man/man4/i386/pcf.4.gz OLD_FILES+=usr/share/man/man4/i386/scd.4.gz OLD_FILES+=usr/share/man/man4/i386/viapm.4.gz .endif # 20100122: move BSDL bc/dc USD documents to /usr/share/doc/usd OLD_FILES+=usr/share/doc/papers/bc.ascii.gz OLD_FILES+=usr/share/doc/papers/dc.ascii.gz # 20100120: replacing GNU bc/dc with BSDL versions OLD_FILES+=usr/share/examples/bc/ckbook.b OLD_FILES+=usr/share/examples/bc/pi.b OLD_FILES+=usr/share/examples/bc/primes.b OLD_FILES+=usr/share/examples/bc/twins.b OLD_FILES+=usr/share/info/dc.info.gz OLD_DIRS+=usr/share/examples/bc # 20100114: removal of ttyslot(3) OLD_FILES+=usr/share/man/man3/ttyslot.3.gz # 20100113: remove utmp.h, replace it by utmpx.h OLD_FILES+=usr/share/man/man3/login.3.gz OLD_FILES+=usr/share/man/man3/logout.3.gz OLD_FILES+=usr/share/man/man3/logwtmp.3.gz OLD_FILES+=usr/share/man/man3/ulog_endutxent.3.gz OLD_FILES+=usr/share/man/man3/ulog_getutxent.3.gz OLD_FILES+=usr/share/man/man3/ulog_getutxline.3.gz OLD_FILES+=usr/share/man/man3/ulog_getutxuser.3.gz OLD_FILES+=usr/share/man/man3/ulog_pututxline.3.gz OLD_FILES+=usr/share/man/man3/ulog_setutxent.3.gz OLD_FILES+=usr/share/man/man3/ulog_setutxfile.3.gz OLD_FILES+=usr/share/man/man5/lastlog.5.gz OLD_FILES+=usr/share/man/man5/utmp.5.gz OLD_FILES+=usr/share/man/man5/wtmp.5.gz OLD_LIBS+=lib/libutil.so.8 OLD_LIBS+=usr/lib32/libutil.so.8 # 20100105: new userland semaphore implementation OLD_FILES+=usr/include/sys/semaphore.h # 20100103: ntptrace(8) removed OLD_FILES+=usr/sbin/ntptrace OLD_FILES+=usr/share/man/man8/ntptrace.8.gz # 20091229: remove no longer relevant examples OLD_FILES+=usr/share/examples/pppd/auth-down.sample OLD_FILES+=usr/share/examples/pppd/auth-up.sample OLD_FILES+=usr/share/examples/pppd/chap-secrets.sample OLD_FILES+=usr/share/examples/pppd/chat.sh.sample OLD_FILES+=usr/share/examples/pppd/ip-down.sample OLD_FILES+=usr/share/examples/pppd/ip-up.sample OLD_FILES+=usr/share/examples/pppd/options.sample OLD_FILES+=usr/share/examples/pppd/pap-secrets.sample OLD_FILES+=usr/share/examples/pppd/ppp.deny.sample OLD_FILES+=usr/share/examples/pppd/ppp.shells.sample OLD_DIRS+=usr/share/examples/pppd OLD_FILES+=usr/share/examples/slattach/unit-command.sh OLD_DIRS+=usr/share/examples/slattach OLD_FILES+=usr/share/examples/sliplogin/slip.hosts OLD_FILES+=usr/share/examples/sliplogin/slip.login OLD_FILES+=usr/share/examples/sliplogin/slip.logout OLD_FILES+=usr/share/examples/sliplogin/slip.slparms OLD_DIRS+=usr/share/examples/sliplogin OLD_FILES+=usr/share/examples/startslip/sldown.sh OLD_FILES+=usr/share/examples/startslip/slip.sh OLD_FILES+=usr/share/examples/startslip/slup.sh OLD_DIRS+=usr/share/examples/startslip # 20091202: unify rc.firewall and rc.firewall6. OLD_FILES+=etc/rc.d/ip6fw OLD_FILES+=etc/rc.firewall6 OLD_FILES+=usr/share/examples/etc/rc.firewall6 # 20091117: removal of rc.early(8) link OLD_FILES+=usr/share/man/man8/rc.early.8.gz # 20091117: usr/share/zoneinfo/GMT link removed OLD_FILES+=usr/share/zoneinfo/GMT # 20091027: pselect.3 implemented as syscall OLD_FILES+=usr/share/man/man3/pselect.3.gz # 20091005: fusword.9 and susword.9 removed OLD_FILES+=usr/share/man/man9/fusword.9.gz OLD_FILES+=usr/share/man/man9/susword.9.gz # 20090909: vesa and dpms promoted to be i386/amd64 common OLD_FILES+=usr/include/machine/pc/vesa.h OLD_FILES+=usr/share/man/man4/i386/dpms.4.gz # 20090904: remove lukemftpd OLD_FILES+=usr/libexec/lukemftpd OLD_FILES+=usr/share/man/man5/ftpd.conf.5.gz OLD_FILES+=usr/share/man/man5/ftpusers.5.gz OLD_FILES+=usr/share/man/man8/lukemftpd.8.gz # 20090902: BSD.{x11,x11-4}.dist are dead and BSD.local.dist lives in ports/ OLD_FILES+=etc/mtree/BSD.local.dist OLD_FILES+=etc/mtree/BSD.x11.dist OLD_FILES+=etc/mtree/BSD.x11-4.dist # 20090812: net80211 documentation overhaul OLD_FILES+=usr/share/man/man9/ieee80211_add_rates.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_add_xrates.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_alloc_node.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_attach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_begin_scan.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_cfgget.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_cfgset.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_chan2ieee.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_chan2mode.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_create_ibss.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_crypto_attach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_crypto_detach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_decap.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_dump_pkt.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_dup_bss.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_encap.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_end_scan.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_find_node.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_fix_rate.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_free_allnodes.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_ieee2mhz.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_ioctl.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_lookup_node.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_media2rate.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_media_change.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_media_init.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_media_status.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_mhz2ieee.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_next_scan.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_node_attach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_node_detach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_node_lateattach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_print_essid.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_proto_attach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_proto_detach.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_rate2media.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_recv_mgmt.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_send_mgmt.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_setmode.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_timeout_nodes.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_watchdog.9.gz OLD_FILES+=usr/share/man/man9/ieee80211_wep_crypt.9.gz # 20090801: vimage.h removed in favour of vnet.h OLD_FILES+=usr/include/sys/vimage.h # 20101208: libbsnmp was moved to usr/lib OLD_LIBS+=lib/libbsnmp.so.5 # 20090719: library version bump for 8.0 OLD_LIBS+=lib/libalias.so.6 OLD_LIBS+=lib/libavl.so.1 OLD_LIBS+=lib/libbegemot.so.3 OLD_LIBS+=lib/libbsdxml.so.3 OLD_LIBS+=lib/libbsnmp.so.4 OLD_LIBS+=lib/libcam.so.4 OLD_LIBS+=lib/libcrypt.so.4 OLD_LIBS+=lib/libcrypto.so.5 OLD_LIBS+=lib/libctf.so.1 OLD_LIBS+=lib/libdevstat.so.6 OLD_LIBS+=lib/libdtrace.so.1 OLD_LIBS+=lib/libedit.so.6 OLD_LIBS+=lib/libgeom.so.4 OLD_LIBS+=lib/libipsec.so.3 OLD_LIBS+=lib/libipx.so.4 OLD_LIBS+=lib/libkiconv.so.3 OLD_LIBS+=lib/libkvm.so.4 OLD_LIBS+=lib/libmd.so.4 OLD_LIBS+=lib/libncurses.so.7 OLD_LIBS+=lib/libncursesw.so.7 OLD_LIBS+=lib/libnvpair.so.1 OLD_LIBS+=lib/libpcap.so.6 OLD_LIBS+=lib/libreadline.so.7 OLD_LIBS+=lib/libsbuf.so.4 OLD_LIBS+=lib/libufs.so.4 OLD_LIBS+=lib/libumem.so.1 OLD_LIBS+=lib/libutil.so.7 OLD_LIBS+=lib/libuutil.so.1 OLD_LIBS+=lib/libz.so.4 OLD_LIBS+=lib/libzfs.so.1 OLD_LIBS+=lib/libzpool.so.1 OLD_LIBS+=usr/lib/libarchive.so.4 OLD_LIBS+=usr/lib/libauditd.so.4 OLD_LIBS+=usr/lib/libbluetooth.so.3 OLD_LIBS+=usr/lib/libbsm.so.2 OLD_LIBS+=usr/lib/libbz2.so.3 OLD_LIBS+=usr/lib/libcalendar.so.4 OLD_LIBS+=usr/lib/libcom_err.so.4 OLD_LIBS+=usr/lib/libdevinfo.so.4 OLD_LIBS+=usr/lib/libdialog.so.6 OLD_LIBS+=usr/lib/libdwarf.so.1 OLD_LIBS+=usr/lib/libfetch.so.5 OLD_LIBS+=usr/lib/libform.so.4 OLD_LIBS+=usr/lib/libformw.so.4 OLD_LIBS+=usr/lib/libftpio.so.7 OLD_LIBS+=usr/lib/libgnuregex.so.4 OLD_LIBS+=usr/lib/libgpib.so.2 OLD_LIBS+=usr/lib/libhistory.so.7 OLD_LIBS+=usr/lib/libmagic.so.3 OLD_LIBS+=usr/lib/libmemstat.so.2 OLD_LIBS+=usr/lib/libmenu.so.4 OLD_LIBS+=usr/lib/libmenuw.so.4 OLD_LIBS+=usr/lib/libmilter.so.4 OLD_LIBS+=usr/lib/libncp.so.3 OLD_LIBS+=usr/lib/libnetgraph.so.3 OLD_LIBS+=usr/lib/libngatm.so.3 OLD_LIBS+=usr/lib/libobjc.so.3 OLD_LIBS+=usr/lib/libopie.so.5 OLD_LIBS+=usr/lib/libpam.so.4 OLD_LIBS+=usr/lib/libpanel.so.4 OLD_LIBS+=usr/lib/libpanelw.so.4 OLD_LIBS+=usr/lib/libpmc.so.4 OLD_LIBS+=usr/lib/libproc.so.1 OLD_LIBS+=usr/lib/libproc.so.2 OLD_LIBS+=usr/lib/libradius.so.3 OLD_LIBS+=usr/lib/librpcsvc.so.4 OLD_LIBS+=usr/lib/libsdp.so.3 OLD_LIBS+=usr/lib/libsmb.so.3 OLD_LIBS+=usr/lib/libssh.so.4 OLD_LIBS+=usr/lib/libssl.so.5 OLD_LIBS+=usr/lib/libtacplus.so.3 OLD_LIBS+=usr/lib/libugidfw.so.3 OLD_LIBS+=usr/lib/libusb.so.1 OLD_LIBS+=usr/lib/libusbhid.so.3 OLD_LIBS+=usr/lib/libvgl.so.5 OLD_LIBS+=usr/lib/libwrap.so.5 OLD_LIBS+=usr/lib/libypclnt.so.3 OLD_LIBS+=usr/lib/pam_chroot.so.4 OLD_LIBS+=usr/lib/pam_deny.so.4 OLD_LIBS+=usr/lib/pam_echo.so.4 OLD_LIBS+=usr/lib/pam_exec.so.4 OLD_LIBS+=usr/lib/pam_ftpusers.so.4 OLD_LIBS+=usr/lib/pam_group.so.4 OLD_LIBS+=usr/lib/pam_guest.so.4 OLD_LIBS+=usr/lib/pam_krb5.so.4 OLD_LIBS+=usr/lib/pam_ksu.so.4 OLD_LIBS+=usr/lib/pam_lastlog.so.4 OLD_LIBS+=usr/lib/pam_login_access.so.4 OLD_LIBS+=usr/lib/pam_nologin.so.4 OLD_LIBS+=usr/lib/pam_opie.so.4 OLD_LIBS+=usr/lib/pam_opieaccess.so.4 OLD_LIBS+=usr/lib/pam_passwdqc.so.4 OLD_LIBS+=usr/lib/pam_permit.so.4 OLD_LIBS+=usr/lib/pam_radius.so.4 OLD_LIBS+=usr/lib/pam_rhosts.so.4 OLD_LIBS+=usr/lib/pam_rootok.so.4 OLD_LIBS+=usr/lib/pam_securetty.so.4 OLD_LIBS+=usr/lib/pam_self.so.4 OLD_LIBS+=usr/lib/pam_ssh.so.4 OLD_LIBS+=usr/lib/pam_tacplus.so.4 OLD_LIBS+=usr/lib/pam_unix.so.4 OLD_LIBS+=usr/lib/snmp_atm.so.5 OLD_LIBS+=usr/lib/snmp_bridge.so.5 OLD_LIBS+=usr/lib/snmp_hostres.so.5 OLD_LIBS+=usr/lib/snmp_mibII.so.5 OLD_LIBS+=usr/lib/snmp_netgraph.so.5 OLD_LIBS+=usr/lib/snmp_pf.so.5 OLD_LIBS+=usr/lib32/libalias.so.6 OLD_LIBS+=usr/lib32/libarchive.so.4 OLD_LIBS+=usr/lib32/libauditd.so.4 OLD_LIBS+=usr/lib32/libavl.so.1 OLD_LIBS+=usr/lib32/libbegemot.so.3 OLD_LIBS+=usr/lib32/libbluetooth.so.3 OLD_LIBS+=usr/lib32/libbsdxml.so.3 OLD_LIBS+=usr/lib32/libbsm.so.2 OLD_LIBS+=usr/lib32/libbsnmp.so.4 OLD_LIBS+=usr/lib32/libbz2.so.3 OLD_LIBS+=usr/lib32/libcalendar.so.4 OLD_LIBS+=usr/lib32/libcam.so.4 OLD_LIBS+=usr/lib32/libcom_err.so.4 OLD_LIBS+=usr/lib32/libcrypt.so.4 OLD_LIBS+=usr/lib32/libcrypto.so.5 OLD_LIBS+=usr/lib32/libctf.so.1 OLD_LIBS+=usr/lib32/libdevinfo.so.4 OLD_LIBS+=usr/lib32/libdevstat.so.6 OLD_LIBS+=usr/lib32/libdialog.so.6 OLD_LIBS+=usr/lib32/libdtrace.so.1 OLD_LIBS+=usr/lib32/libdwarf.so.1 OLD_LIBS+=usr/lib32/libedit.so.6 OLD_LIBS+=usr/lib32/libfetch.so.5 OLD_LIBS+=usr/lib32/libform.so.4 OLD_LIBS+=usr/lib32/libformw.so.4 OLD_LIBS+=usr/lib32/libftpio.so.7 OLD_LIBS+=usr/lib32/libgeom.so.4 OLD_LIBS+=usr/lib32/libgnuregex.so.4 OLD_LIBS+=usr/lib32/libgpib.so.2 OLD_LIBS+=usr/lib32/libhistory.so.7 OLD_LIBS+=usr/lib32/libipsec.so.3 OLD_LIBS+=usr/lib32/libipx.so.4 OLD_LIBS+=usr/lib32/libkiconv.so.3 OLD_LIBS+=usr/lib32/libkvm.so.4 OLD_LIBS+=usr/lib32/libmagic.so.3 OLD_LIBS+=usr/lib32/libmd.so.4 OLD_LIBS+=usr/lib32/libmemstat.so.2 OLD_LIBS+=usr/lib32/libmenu.so.4 OLD_LIBS+=usr/lib32/libmenuw.so.4 OLD_LIBS+=usr/lib32/libmilter.so.4 OLD_LIBS+=usr/lib32/libncp.so.3 OLD_LIBS+=usr/lib32/libncurses.so.7 OLD_LIBS+=usr/lib32/libncursesw.so.7 OLD_LIBS+=usr/lib32/libnetgraph.so.3 OLD_LIBS+=usr/lib32/libngatm.so.3 OLD_LIBS+=usr/lib32/libnvpair.so.1 OLD_LIBS+=usr/lib32/libobjc.so.3 OLD_LIBS+=usr/lib32/libopie.so.5 OLD_LIBS+=usr/lib32/libpam.so.4 OLD_LIBS+=usr/lib32/libpanel.so.4 OLD_LIBS+=usr/lib32/libpanelw.so.4 OLD_LIBS+=usr/lib32/libpcap.so.6 OLD_LIBS+=usr/lib32/libpmc.so.4 OLD_LIBS+=usr/lib32/libproc.so.1 OLD_LIBS+=usr/lib32/libradius.so.3 OLD_LIBS+=usr/lib32/libreadline.so.7 OLD_LIBS+=usr/lib32/librpcsvc.so.4 OLD_LIBS+=usr/lib32/libsbuf.so.4 OLD_LIBS+=usr/lib32/libsdp.so.3 OLD_LIBS+=usr/lib32/libsmb.so.3 OLD_LIBS+=usr/lib32/libssh.so.4 OLD_LIBS+=usr/lib32/libssl.so.5 OLD_LIBS+=usr/lib32/libtacplus.so.3 OLD_LIBS+=usr/lib32/libufs.so.4 OLD_LIBS+=usr/lib32/libugidfw.so.3 OLD_LIBS+=usr/lib32/libumem.so.1 OLD_LIBS+=usr/lib32/libusb.so.1 OLD_LIBS+=usr/lib32/libusbhid.so.3 OLD_LIBS+=usr/lib32/libutil.so.7 OLD_LIBS+=usr/lib32/libuutil.so.1 OLD_LIBS+=usr/lib32/libvgl.so.5 OLD_LIBS+=usr/lib32/libwrap.so.5 OLD_LIBS+=usr/lib32/libypclnt.so.3 OLD_LIBS+=usr/lib32/libz.so.4 OLD_LIBS+=usr/lib32/libzfs.so.1 OLD_LIBS+=usr/lib32/libzpool.so.1 OLD_LIBS+=usr/lib32/pam_chroot.so.4 OLD_LIBS+=usr/lib32/pam_deny.so.4 OLD_LIBS+=usr/lib32/pam_echo.so.4 OLD_LIBS+=usr/lib32/pam_exec.so.4 OLD_LIBS+=usr/lib32/pam_ftpusers.so.4 OLD_LIBS+=usr/lib32/pam_group.so.4 OLD_LIBS+=usr/lib32/pam_guest.so.4 OLD_LIBS+=usr/lib32/pam_krb5.so.4 OLD_LIBS+=usr/lib32/pam_ksu.so.4 OLD_LIBS+=usr/lib32/pam_lastlog.so.4 OLD_LIBS+=usr/lib32/pam_login_access.so.4 OLD_LIBS+=usr/lib32/pam_nologin.so.4 OLD_LIBS+=usr/lib32/pam_opie.so.4 OLD_LIBS+=usr/lib32/pam_opieaccess.so.4 OLD_LIBS+=usr/lib32/pam_passwdqc.so.4 OLD_LIBS+=usr/lib32/pam_permit.so.4 OLD_LIBS+=usr/lib32/pam_radius.so.4 OLD_LIBS+=usr/lib32/pam_rhosts.so.4 OLD_LIBS+=usr/lib32/pam_rootok.so.4 OLD_LIBS+=usr/lib32/pam_securetty.so.4 OLD_LIBS+=usr/lib32/pam_self.so.4 OLD_LIBS+=usr/lib32/pam_ssh.so.4 OLD_LIBS+=usr/lib32/pam_tacplus.so.4 OLD_LIBS+=usr/lib32/pam_unix.so.4 # 20090718: the gdm pam.d file is no longer required. OLD_FILES+=etc/pam.d/gdm # 20090714: net_add_domain(9) renamed to domain_add(9) OLD_FILES+=usr/share/man/man9/net_add_domain.9.gz # 20090713: vimage container structs removed. OLD_FILES+=usr/include/netinet/vinet.h OLD_FILES+=usr/include/netinet6/vinet6.h OLD_FILES+=usr/include/netipsec/vipsec.h # 20090712: ieee80211.4 -> net80211.4 OLD_FILES+=usr/share/man/man4/ieee80211.4.gz # 20090711: typo fixed, kproc_resume,.9 -> kproc_resume.9 OLD_FILES+=usr/share/man/man9/kproc_resume,.9.gz # 20090709: msgctl.3 msgget.3 msgrcv.3 msgsnd.3 manual pages moved OLD_FILES+=usr/share/man/man3/msgctl.3.gz OLD_FILES+=usr/share/man/man3/msgget.3.gz OLD_FILES+=usr/share/man/man3/msgrcv.3.gz OLD_FILES+=usr/share/man/man3/msgsnd.3.gz # 20090630: old kernel RPC implementation removal OLD_FILES+=usr/include/nfs/rpcv2.h # 20090624: update usbdi(9) OLD_FILES+=usr/share/man/man9/usbd_abort_default_pipe.9.gz OLD_FILES+=usr/share/man/man9/usbd_abort_pipe.9.gz OLD_FILES+=usr/share/man/man9/usbd_alloc_buffer.9.gz OLD_FILES+=usr/share/man/man9/usbd_alloc_xfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_clear_endpoint_stall.9.gz OLD_FILES+=usr/share/man/man9/usbd_clear_endpoint_stall_async.9.gz OLD_FILES+=usr/share/man/man9/usbd_clear_endpoint_toggle.9.gz OLD_FILES+=usr/share/man/man9/usbd_close_pipe.9.gz OLD_FILES+=usr/share/man/man9/usbd_device2interface_handle.9.gz OLD_FILES+=usr/share/man/man9/usbd_do_request_async.9.gz OLD_FILES+=usr/share/man/man9/usbd_do_request_flags_pipe.9.gz OLD_FILES+=usr/share/man/man9/usbd_endpoint_count.9.gz OLD_FILES+=usr/share/man/man9/usbd_find_edesc.9.gz OLD_FILES+=usr/share/man/man9/usbd_find_idesc.9.gz OLD_FILES+=usr/share/man/man9/usbd_free_buffer.9.gz OLD_FILES+=usr/share/man/man9/usbd_free_xfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_buffer.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_config.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_config_desc.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_config_desc_full.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_config_descriptor.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_device_descriptor.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_endpoint_descriptor.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_interface_altindex.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_interface_descriptor.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_no_alts.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_quirks.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_speed.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_string.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_string_desc.9.gz OLD_FILES+=usr/share/man/man9/usbd_get_xfer_status.9.gz OLD_FILES+=usr/share/man/man9/usbd_interface2device_handle.9.gz OLD_FILES+=usr/share/man/man9/usbd_interface2endpoint_descriptor.9.gz OLD_FILES+=usr/share/man/man9/usbd_interface_count.9.gz OLD_FILES+=usr/share/man/man9/usbd_open_pipe.9.gz OLD_FILES+=usr/share/man/man9/usbd_open_pipe_intr.9.gz OLD_FILES+=usr/share/man/man9/usbd_pipe2device_handle.9.gz OLD_FILES+=usr/share/man/man9/usbd_set_config_index.9.gz OLD_FILES+=usr/share/man/man9/usbd_set_config_no.9.gz OLD_FILES+=usr/share/man/man9/usbd_set_interface.9.gz OLD_FILES+=usr/share/man/man9/usbd_setup_default_xfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_setup_isoc_xfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_setup_xfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_sync_transfer.9.gz OLD_FILES+=usr/share/man/man9/usbd_transfer.9.gz OLD_FILES+=usr/share/man/man9/usb_find_desc.9.gz # 20090623: number of headers needed for a usb driver reduced OLD_FILES+=usr/include/dev/usb/usb_defs.h OLD_FILES+=usr/include/dev/usb/usb_error.h OLD_FILES+=usr/include/dev/usb/usb_handle_request.h OLD_FILES+=usr/include/dev/usb/usb_hid.h OLD_FILES+=usr/include/dev/usb/usb_lookup.h OLD_FILES+=usr/include/dev/usb/usb_mfunc.h OLD_FILES+=usr/include/dev/usb/usb_parse.h OLD_FILES+=usr/include/dev/usb/usb_revision.h # 20090609: devclass_add_driver is no longer public OLD_FILES+=usr/share/man/man9/devclass_add_driver.9.gz OLD_FILES+=usr/share/man/man9/devclass_delete_driver.9.gz OLD_FILES+=usr/share/man/man9/devclass_find_driver.9.gz # 20090605: removal of clists OLD_FILES+=usr/include/sys/clist.h # 20090602: removal of window(1) OLD_FILES+=usr/bin/window OLD_FILES+=usr/share/man/man1/window.1.gz # 20090531: bind 9.6.1rc1 import OLD_LIBS+=usr/lib/liblwres.so.30 # 20090530: removal of early.sh OLD_FILES+=etc/rc.d/early.sh # 20090527: renaming of S{LIST,TAILQ}_REMOVE_NEXT() to _REMOVE_AFTER() OLD_FILES+=usr/share/man/man3/SLIST_REMOVE_NEXT.3.gz OLD_FILES+=usr/share/man/man3/STAILQ_REMOVE_NEXT.3.gz # 20090527: removal of legacy USB stack OLD_FILES+=usr/include/legacy/dev/usb/dsbr100io.h OLD_FILES+=usr/include/legacy/dev/usb/ehcireg.h OLD_FILES+=usr/include/legacy/dev/usb/ehcivar.h OLD_FILES+=usr/include/legacy/dev/usb/hid.h OLD_FILES+=usr/include/legacy/dev/usb/if_urtwreg.h OLD_FILES+=usr/include/legacy/dev/usb/if_urtwvar.h OLD_FILES+=usr/include/legacy/dev/usb/ohcireg.h OLD_FILES+=usr/include/legacy/dev/usb/ohcivar.h OLD_FILES+=usr/include/legacy/dev/usb/rio500_usb.h OLD_FILES+=usr/include/legacy/dev/usb/rt2573_ucode.h OLD_FILES+=usr/include/legacy/dev/usb/sl811hsreg.h OLD_FILES+=usr/include/legacy/dev/usb/sl811hsvar.h OLD_FILES+=usr/include/legacy/dev/usb/ubser.h OLD_FILES+=usr/include/legacy/dev/usb/ucomvar.h OLD_FILES+=usr/include/legacy/dev/usb/udbp.h OLD_FILES+=usr/include/legacy/dev/usb/uftdireg.h OLD_FILES+=usr/include/legacy/dev/usb/ugraphire_rdesc.h OLD_FILES+=usr/include/legacy/dev/usb/uhcireg.h OLD_FILES+=usr/include/legacy/dev/usb/uhcivar.h OLD_FILES+=usr/include/legacy/dev/usb/usb.h OLD_FILES+=usr/include/legacy/dev/usb/usb_mem.h OLD_FILES+=usr/include/legacy/dev/usb/usb_port.h OLD_FILES+=usr/include/legacy/dev/usb/usb_quirks.h OLD_FILES+=usr/include/legacy/dev/usb/usbcdc.h OLD_FILES+=usr/include/legacy/dev/usb/usbdi.h OLD_FILES+=usr/include/legacy/dev/usb/usbdi_util.h OLD_FILES+=usr/include/legacy/dev/usb/usbdivar.h OLD_FILES+=usr/include/legacy/dev/usb/usbhid.h OLD_FILES+=usr/include/legacy/dev/usb/uxb360gp_rdesc.h OLD_DIRS+=usr/include/legacy/dev/usb OLD_DIRS+=usr/include/legacy/dev OLD_DIRS+=usr/include/legacy # 20090526: removal of makekey(8) OLD_FILES+=usr/libexec/makekey OLD_FILES+=usr/share/man/man8/makekey.8.gz # 20090522: removal of University of Michigan NFSv4 client OLD_FILES+=etc/rc.d/idmapd OLD_FILES+=sbin/idmapd OLD_FILES+=sbin/mount_nfs4 OLD_FILES+=usr/share/man/man8/idmapd.8.gz OLD_FILES+=usr/share/man/man8/mount_nfs4.8.gz # 20090513: removal of legacy versions of USB network interface drivers OLD_FILES+=usr/include/legacy/dev/usb/if_upgtvar.h OLD_FILES+=usr/include/legacy/dev/usb/usb_ethersubr.h # 20090417: removal of legacy versions of USB network interface drivers OLD_FILES+=usr/include/legacy/dev/usb/if_auereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_axereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_cdcereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_cuereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_kuereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_ruereg.h OLD_FILES+=usr/include/legacy/dev/usb/if_rumreg.h OLD_FILES+=usr/include/legacy/dev/usb/if_rumvar.h OLD_FILES+=usr/include/legacy/dev/usb/if_udavreg.h OLD_FILES+=usr/include/legacy/dev/usb/if_uralreg.h OLD_FILES+=usr/include/legacy/dev/usb/if_uralvar.h OLD_FILES+=usr/include/legacy/dev/usb/if_zydfw.h OLD_FILES+=usr/include/legacy/dev/usb/if_zydreg.h OLD_FILES+=usr/include/legacy/dev/usb/kue_fw.h # 20090416: removal of ar(4), ray(4), sr(4), raycontrol(8) OLD_FILES+=usr/sbin/raycontrol OLD_FILES+=usr/share/man/man4/i386/ar.4.gz OLD_FILES+=usr/share/man/man4/i386/ray.4.gz OLD_FILES+=usr/share/man/man4/i386/sr.4.gz OLD_FILES+=usr/share/man/man8/raycontrol.8.gz # 20090410: VOP_LEASE.9 removed OLD_FILES+=usr/share/man/man9/VOP_LEASE.9.gz # 20090406: usb_sw_transfer.h removed OLD_FILES+=usr/include/dev/usb/usb_sw_transfer.h # 20090405: removal of if_ppp(4) and if_sl(4) OLD_FILES+=sbin/slattach rescue/slattach OLD_FILES+=sbin/startslip rescue/startslip OLD_FILES+=usr/include/net/if_ppp.h OLD_FILES+=usr/include/net/if_pppvar.h OLD_FILES+=usr/include/net/if_slvar.h OLD_FILES+=usr/include/net/ppp_comp.h OLD_FILES+=usr/include/net/slip.h OLD_FILES+=usr/sbin/sliplogin OLD_FILES+=usr/sbin/slstat OLD_FILES+=usr/sbin/pppd OLD_FILES+=usr/sbin/pppstats OLD_FILES+=usr/share/man/man1/startslip.1.gz OLD_FILES+=usr/share/man/man4/if_ppp.4.gz OLD_FILES+=usr/share/man/man4/if_sl.4.gz OLD_FILES+=usr/share/man/man4/ppp.4.gz OLD_FILES+=usr/share/man/man4/sl.4.gz OLD_FILES+=usr/share/man/man8/pppd.8.gz OLD_FILES+=usr/share/man/man8/pppstats.8.gz OLD_FILES+=usr/share/man/man8/slattach.8.gz OLD_FILES+=usr/share/man/man8/slip.8.gz OLD_FILES+=usr/share/man/man8/sliplogin.8.gz OLD_FILES+=usr/share/man/man8/slstat.8.gz # 20090321: libpcap upgraded to 1.0.0 OLD_LIBS+=lib/libpcap.so.5 OLD_LIBS+=usr/lib32/libpcap.so.5 # 20090319: uscanner(4) has been removed OLD_FILES+=usr/share/man/man4/uscanner.4.gz # 20090313: k8temp(4) renamed to amdtemp(4) OLD_FILES+=usr/share/man/man4/k8temp.4.gz # 20090308: libusb.so.1 renamed OLD_LIBS+=usr/lib/libusb20.so.1 OLD_FILES+=usr/lib/libusb20.a OLD_FILES+=usr/lib/libusb20.so OLD_FILES+=usr/lib/libusb20_p.a OLD_FILES+=usr/include/libusb20_compat01.h OLD_FILES+=usr/include/libusb20_compat10.h OLD_LIBS+=usr/lib32/libusb20.so.1 OLD_FILES+=usr/lib32/libusb20.a OLD_FILES+=usr/lib32/libusb20.so OLD_FILES+=usr/lib32/libusb20_p.a # 20090226: libmp(3) functions renamed OLD_LIBS+=usr/lib/libmp.so.6 OLD_LIBS+=usr/lib32/libmp.so.6 # 20090223: changeover of USB stacks OLD_FILES+=usr/include/dev/usb2/include/ufm2_ioctl.h OLD_FILES+=usr/include/dev/usb2/include/urio2_ioctl.h OLD_FILES+=usr/include/dev/usb2/include/usb2_cdc.h OLD_FILES+=usr/include/dev/usb2/include/usb2_defs.h OLD_FILES+=usr/include/dev/usb2/include/usb2_devid.h OLD_FILES+=usr/include/dev/usb2/include/usb2_devtable.h OLD_FILES+=usr/include/dev/usb2/include/usb2_endian.h OLD_FILES+=usr/include/dev/usb2/include/usb2_error.h OLD_FILES+=usr/include/dev/usb2/include/usb2_hid.h OLD_FILES+=usr/include/dev/usb2/include/usb2_ioctl.h OLD_FILES+=usr/include/dev/usb2/include/usb2_mfunc.h OLD_FILES+=usr/include/dev/usb2/include/usb2_revision.h OLD_FILES+=usr/include/dev/usb2/include/usb2_standard.h OLD_DIRS+=usr/include/dev/usb2/include OLD_DIRS+=usr/include/dev/usb2 OLD_FILES+=usr/include/dev/usb/dsbr100io.h OLD_FILES+=usr/include/dev/usb/ehcireg.h OLD_FILES+=usr/include/dev/usb/ehcivar.h OLD_FILES+=usr/include/dev/usb/hid.h OLD_FILES+=usr/include/dev/usb/if_auereg.h OLD_FILES+=usr/include/dev/usb/if_axereg.h OLD_FILES+=usr/include/dev/usb/if_cdcereg.h OLD_FILES+=usr/include/dev/usb/if_cuereg.h OLD_FILES+=usr/include/dev/usb/if_kuereg.h OLD_FILES+=usr/include/dev/usb/if_ruereg.h OLD_FILES+=usr/include/dev/usb/if_rumreg.h OLD_FILES+=usr/include/dev/usb/if_rumvar.h OLD_FILES+=usr/include/dev/usb/if_udavreg.h OLD_FILES+=usr/include/dev/usb/if_upgtvar.h OLD_FILES+=usr/include/dev/usb/if_uralreg.h OLD_FILES+=usr/include/dev/usb/if_uralvar.h OLD_FILES+=usr/include/dev/usb/if_urtwreg.h OLD_FILES+=usr/include/dev/usb/if_urtwvar.h OLD_FILES+=usr/include/dev/usb/if_zydfw.h OLD_FILES+=usr/include/dev/usb/if_zydreg.h OLD_FILES+=usr/include/dev/usb/kue_fw.h OLD_FILES+=usr/include/dev/usb/ohcireg.h OLD_FILES+=usr/include/dev/usb/ohcivar.h OLD_FILES+=usr/include/dev/usb/rio500_usb.h OLD_FILES+=usr/include/dev/usb/rt2573_ucode.h OLD_FILES+=usr/include/dev/usb/sl811hsreg.h OLD_FILES+=usr/include/dev/usb/sl811hsvar.h OLD_FILES+=usr/include/dev/usb/ubser.h OLD_FILES+=usr/include/dev/usb/ucomvar.h OLD_FILES+=usr/include/dev/usb/udbp.h OLD_FILES+=usr/include/dev/usb/uftdireg.h OLD_FILES+=usr/include/dev/usb/ugraphire_rdesc.h OLD_FILES+=usr/include/dev/usb/uhcireg.h OLD_FILES+=usr/include/dev/usb/uhcivar.h OLD_FILES+=usr/include/dev/usb/usb_ethersubr.h OLD_FILES+=usr/include/dev/usb/usb_mem.h OLD_FILES+=usr/include/dev/usb/usb_port.h OLD_FILES+=usr/include/dev/usb/usb_quirks.h OLD_FILES+=usr/include/dev/usb/usbcdc.h OLD_FILES+=usr/include/dev/usb/usbdivar.h OLD_FILES+=usr/include/dev/usb/uxb360gp_rdesc.h OLD_FILES+=usr/sbin/usbdevs OLD_FILES+=usr/share/man/man8/usbdevs.8.gz # 20090203: removal of pccard header files OLD_FILES+=usr/include/pccard/cardinfo.h OLD_FILES+=usr/include/pccard/cis.h OLD_DIRS+=usr/include/pccard # 20090203: adding_user.8 moved to adding_user.7 OLD_FILES+=usr/share/man/man8/adding_user.8.gz # 20090122: tzdata2009a import OLD_FILES+=usr/share/zoneinfo/Asia/Katmandu # 20090102: file 4.26 import OLD_FILES+=usr/share/misc/magic.mime OLD_FILES+=usr/share/misc/magic.mime.mgc # 20081223: bind 9.4.3 import, nsupdate.8 moved to nsupdate.1 OLD_FILES+=usr/share/man/man8/nsupdate.8.gz # 20081223: ipprotosw.h removed OLD_FILES+=usr/include/netinet/ipprotosw.h # 20081123: vfs_mountedon.9 removed OLD_FILES+=usr/share/man/man9/vfs_mountedon.9.gz # 20081023: FREE.9 and MALLOC.9 removed OLD_FILES+=usr/share/man/man9/FREE.9.gz OLD_FILES+=usr/share/man/man9/MALLOC.9.gz # 20080928: removal of inaccurate device_ids(9) manual page OLD_FILES+=usr/share/man/man9/device_ids.9.gz OLD_FILES+=usr/share/man/man9/major.9.gz OLD_FILES+=usr/share/man/man9/minor.9.gz OLD_FILES+=usr/share/man/man9/umajor.9.gz OLD_FILES+=usr/share/man/man9/uminor.9.gz # 20080917: removal of manpage for axed kernel primitive suser(9) OLD_FILES+=usr/share/man/man9/suser.9.gz OLD_FILES+=usr/share/man/man9/suser_cred.9.gz # 20080913: pax removed from rescue OLD_FILES+=rescue/pax # 20080823: removal of unneeded pt_chown, to implement grantpt(3) OLD_FILES+=usr/libexec/pt_chown # 20080822: ntp 4.2.4p5 import OLD_FILES+=usr/share/doc/ntp/driver23.html OLD_FILES+=usr/share/doc/ntp/driver24.html # 20080821: several man pages moved from man4.i386 to man4 .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/share/man/man4/i386/acpi_aiboost.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_asus.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_fujitsu.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_ibm.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_panasonic.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_sony.4.gz OLD_FILES+=usr/share/man/man4/i386/acpi_toshiba.4.gz OLD_FILES+=usr/share/man/man4/i386/ichwd.4.gz OLD_FILES+=usr/share/man/man4/i386/if_ndis.4.gz OLD_FILES+=usr/share/man/man4/i386/io.4.gz OLD_FILES+=usr/share/man/man4/i386/linux.4.gz OLD_FILES+=usr/share/man/man4/i386/ndis.4.gz .endif # 20080820: MPSAFE TTY layer integrated OLD_FILES+=usr/include/sys/linedisc.h OLD_FILES+=usr/share/man/man3/posix_openpt.3.gz # 20080725: sgtty.h removed OLD_FILES+=usr/include/sgtty.h # 20080706: bsdlabel(8) removed on powerpc .if ${TARGET_ARCH} == "powerpc" OLD_FILES+=sbin/bsdlabel OLD_FILES+=usr/share/man/man8/bsdlabel.8.gz .endif # 20080704: sbsh(4) removed OLD_FILES+=usr/share/man/man4/if_sbsh.4.gz OLD_FILES+=usr/share/man/man4/sbsh.4.gz # 20080704: cnw(4) removed OLD_FILES+=usr/share/man/man4/if_cnw.4.gz OLD_FILES+=usr/share/man/man4/cnw.4.gz # 20080704: oltr(4) removed .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/share/man/man4/i386/if_oltr.4.gz OLD_FILES+=usr/share/man/man4/i386/oltr.4.gz .endif # 20080704: arl(4) removed .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/sbin/arlcontrol OLD_FILES+=usr/share/man/man4/i386/arl.4.gz OLD_FILES+=usr/share/man/man8/arlcontrol.8.gz .endif # 20080703: sunlabel only for sparc64 .if ${TARGET_ARCH} != "sparc64" OLD_FILES+=sbin/sunlabel OLD_FILES+=usr/share/man/man8/sunlabel.8.gz .endif # 20080701: wpa_supplicant.conf moved to share/examples/etc/ OLD_FILES+=usr/share/examples/wpa_supplicant/wpa_supplicant.conf OLD_DIRS+=usr/share/examples/wpa_supplicant # 20080614: pecoff image activator removed .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/pecoff_machdep.h .endif # 20080614: sgtty removed OLD_FILES+=usr/include/sys/ttychars.h OLD_FILES+=usr/include/sys/ttydev.h OLD_FILES+=usr/share/man/man3/gtty.3.gz OLD_FILES+=usr/share/man/man3/stty.3.gz # 20080609: gpt(8) removed OLD_FILES+=sbin/gpt OLD_FILES+=usr/share/man/man8/gpt.8.gz # 20080525: I4B removed OLD_FILES+=etc/isdn/answer OLD_FILES+=etc/isdn/isdntel OLD_FILES+=etc/isdn/record OLD_FILES+=etc/isdn/tell OLD_FILES+=etc/isdn/tell-record OLD_FILES+=etc/isdn/unknown_incoming OLD_FILES+=etc/isdn/holidays.D OLD_FILES+=etc/isdn/isdnd.rates.A OLD_FILES+=etc/isdn/isdnd.rates.D OLD_FILES+=etc/isdn/isdnd.rates.F OLD_FILES+=etc/isdn/isdnd.rates.L OLD_FILES+=etc/isdn/isdnd.rates.UK.BT OLD_FILES+=etc/isdn/isdnd.rc.sample OLD_FILES+=etc/isdn/isdntel.alias.sample OLD_DIRS+=etc/isdn OLD_FILES+=etc/rc.d/isdnd OLD_FILES+=usr/include/i4b/i4b_cause.h OLD_FILES+=usr/include/i4b/i4b_debug.h OLD_FILES+=usr/include/i4b/i4b_ioctl.h OLD_FILES+=usr/include/i4b/i4b_rbch_ioctl.h OLD_FILES+=usr/include/i4b/i4b_tel_ioctl.h OLD_FILES+=usr/include/i4b/i4b_trace.h OLD_DIRS+=usr/include/i4b OLD_FILES+=usr/sbin/dtmfdecode OLD_FILES+=usr/sbin/g711conv OLD_FILES+=usr/sbin/isdnd OLD_FILES+=usr/sbin/isdndebug OLD_FILES+=usr/sbin/isdndecode OLD_FILES+=usr/sbin/isdnmonitor OLD_FILES+=usr/sbin/isdnphone OLD_FILES+=usr/sbin/isdntel OLD_FILES+=usr/sbin/isdntelctl OLD_FILES+=usr/sbin/isdntrace OLD_FILES+=usr/share/isdn/0.al OLD_FILES+=usr/share/isdn/1.al OLD_FILES+=usr/share/isdn/2.al OLD_FILES+=usr/share/isdn/3.al OLD_FILES+=usr/share/isdn/4.al OLD_FILES+=usr/share/isdn/5.al OLD_FILES+=usr/share/isdn/6.al OLD_FILES+=usr/share/isdn/7.al OLD_FILES+=usr/share/isdn/8.al OLD_FILES+=usr/share/isdn/9.al OLD_FILES+=usr/share/isdn/beep.al OLD_FILES+=usr/share/isdn/msg.al OLD_DIRS+=usr/share/isdn OLD_FILES+=usr/share/man/man1/dtmfdecode.1.gz OLD_FILES+=usr/share/man/man1/g711conv.1.gz OLD_FILES+=usr/share/man/man4/i4b.4.gz OLD_FILES+=usr/share/man/man4/i4bcapi.4.gz OLD_FILES+=usr/share/man/man4/i4bctl.4.gz OLD_FILES+=usr/share/man/man4/i4bing.4.gz OLD_FILES+=usr/share/man/man4/i4bipr.4.gz OLD_FILES+=usr/share/man/man4/i4bisppp.4.gz OLD_FILES+=usr/share/man/man4/i4bq921.4.gz OLD_FILES+=usr/share/man/man4/i4bq931.4.gz OLD_FILES+=usr/share/man/man4/i4brbch.4.gz OLD_FILES+=usr/share/man/man4/i4btel.4.gz OLD_FILES+=usr/share/man/man4/i4btrc.4.gz OLD_FILES+=usr/share/man/man4/iavc.4.gz OLD_FILES+=usr/share/man/man4/isic.4.gz OLD_FILES+=usr/share/man/man4/ifpi.4.gz OLD_FILES+=usr/share/man/man4/ifpi2.4.gz OLD_FILES+=usr/share/man/man4/ifpnp.4.gz OLD_FILES+=usr/share/man/man4/ihfc.4.gz OLD_FILES+=usr/share/man/man4/itjc.4.gz OLD_FILES+=usr/share/man/man4/iwic.4.gz OLD_FILES+=usr/share/man/man5/isdnd.rc.5.gz OLD_FILES+=usr/share/man/man5/isdnd.rates.5.gz OLD_FILES+=usr/share/man/man5/isdnd.acct.5.gz OLD_FILES+=usr/share/man/man8/isdnd.8.gz OLD_FILES+=usr/share/man/man8/isdndebug.8.gz OLD_FILES+=usr/share/man/man8/isdndecode.8.gz OLD_FILES+=usr/share/man/man8/isdnmonitor.8.gz OLD_FILES+=usr/share/man/man8/isdnphone.8.gz OLD_FILES+=usr/share/man/man8/isdntel.8.gz OLD_FILES+=usr/share/man/man8/isdntelctl.8.gz OLD_FILES+=usr/share/man/man8/isdntrace.8.gz OLD_FILES+=usr/share/examples/isdn/contrib/README OLD_FILES+=usr/share/examples/isdn/contrib/anleitung.ppp OLD_FILES+=usr/share/examples/isdn/contrib/answer.c OLD_FILES+=usr/share/examples/isdn/contrib/answer.sh OLD_FILES+=usr/share/examples/isdn/contrib/convert.sh OLD_FILES+=usr/share/examples/isdn/contrib/hplay.c OLD_FILES+=usr/share/examples/isdn/contrib/i4b-ppp-newbie.txt OLD_FILES+=usr/share/examples/isdn/contrib/isdnctl OLD_FILES+=usr/share/examples/isdn/contrib/isdnd_acct OLD_FILES+=usr/share/examples/isdn/contrib/isdnd_acct.pl OLD_FILES+=usr/share/examples/isdn/contrib/isdntelmux.c OLD_FILES+=usr/share/examples/isdn/contrib/mrtg-isp0.sh OLD_FILES+=usr/share/examples/isdn/i4brunppp/Makefile OLD_FILES+=usr/share/examples/isdn/i4brunppp/README OLD_FILES+=usr/share/examples/isdn/i4brunppp/i4brunppp-isdnd.rc OLD_FILES+=usr/share/examples/isdn/i4brunppp/i4brunppp.8 OLD_FILES+=usr/share/examples/isdn/i4brunppp/i4brunppp.c OLD_FILES+=usr/share/examples/isdn/v21/Makefile OLD_FILES+=usr/share/examples/isdn/v21/README OLD_FILES+=usr/share/examples/isdn/v21/v21modem.c OLD_FILES+=usr/share/examples/isdn/FAQ OLD_FILES+=usr/share/examples/isdn/KERNEL OLD_FILES+=usr/share/examples/isdn/Overview OLD_FILES+=usr/share/examples/isdn/README OLD_FILES+=usr/share/examples/isdn/ROADMAP OLD_FILES+=usr/share/examples/isdn/ReleaseNotes OLD_FILES+=usr/share/examples/isdn/Resources OLD_FILES+=usr/share/examples/isdn/SupportedCards OLD_FILES+=usr/share/examples/isdn/ThankYou OLD_DIRS+=usr/share/examples/isdn/contrib OLD_DIRS+=usr/share/examples/isdn/i4brunppp OLD_DIRS+=usr/share/examples/isdn/v21 OLD_DIRS+=usr/share/examples/isdn OLD_FILES+=usr/share/examples/ppp/isdnd.rc OLD_FILES+=usr/share/examples/ppp/ppp.conf.isdn # 20080525: ng_atmpif removed OLD_FILES+=usr/include/netgraph/atm/ng_atmpif.h OLD_FILES+=usr/share/man/man4/ng_atmpif.4.gz # 20080522: pmap_addr_hint removed OLD_FILES+=usr/share/man/man9/pmap_addr_hint.9.gz # 20080517: ipsec_osdep.h removed OLD_FILES+=usr/include/netipsec/ipsec_osdep.h # 20080507: heimdal 1.1 import OLD_LIBS+=usr/lib/libasn1.so.9 OLD_LIBS+=usr/lib/libgssapi.so.9 OLD_LIBS+=usr/lib/libgssapi_krb5.so.9 OLD_LIBS+=usr/lib/libhdb.so.9 OLD_LIBS+=usr/lib/libkadm5clnt.so.9 OLD_LIBS+=usr/lib/libkadm5srv.so.9 OLD_LIBS+=usr/lib/libkafs5.so.9 OLD_LIBS+=usr/lib/libkrb5.so.9 OLD_LIBS+=usr/lib/libroken.so.9 OLD_LIBS+=usr/lib32/libgssapi.so.9 # 20080420: Symbol card support dropped OLD_FILES+=usr/include/dev/wi/spectrum24t_cf.h # 20080420: awi removal OLD_FILES+=usr/share/man/man4/awi.4.gz OLD_FILES+=usr/share/man/man4/if_awi.4.gz # 20080331: pkg_sign has been removed OLD_FILES+=usr/sbin/pkg_check OLD_FILES+=usr/sbin/pkg_sign OLD_FILES+=usr/share/man/man1/pkg_check.1.gz OLD_FILES+=usr/share/man/man1/pkg_sign.1.gz # 20080325: tzdata2008b import OLD_FILES+=usr/share/zoneinfo/Asia/Calcutta OLD_FILES+=usr/share/zoneinfo/Asia/Saigon # 20080314: stack_print(9) mlink fixed OLD_FILES+=usr/share/man/man9/stack_printf.9.gz # 20080312: libkse removal OLD_FILES+=usr/include/sys/kse.h OLD_FILES+=usr/lib/libkse.so OLD_LIBS+=usr/lib/libkse.so.3 OLD_FILES+=usr/share/man/man2/kse.2.gz OLD_FILES+=usr/share/man/man2/kse_create.2.gz OLD_FILES+=usr/share/man/man2/kse_exit.2.gz OLD_FILES+=usr/share/man/man2/kse_release.2.gz OLD_FILES+=usr/share/man/man2/kse_switchin.2.gz OLD_FILES+=usr/share/man/man2/kse_thr_interrupt.2.gz OLD_FILES+=usr/share/man/man2/kse_wakeup.2.gz OLD_FILES+=usr/lib32/libkse.so OLD_LIBS+=usr/lib32/libkse.so.3 # 20080225: bsdar/bsdranlib rename to ar/ranlib OLD_FILES+=usr/bin/bsdar OLD_FILES+=usr/bin/bsdranlib OLD_FILES+=usr/share/man/man1/bsdar.1.gz OLD_FILES+=usr/share/man/man1/bsdranlib.1.gz # 20080220: geom_lvm rename to geom_linux_lvm OLD_FILES+=usr/share/man/man4/geom_lvm.4.gz # 20080126: oldcard.4 removal OLD_FILES+=usr/share/man/man4/card.4.gz OLD_FILES+=usr/share/man/man4/oldcard.4.gz # 20080122: Removed from the tree OLD_FILES+=usr/share/man/man9/BUF_REFCNT.9.gz # 20080108: Moved to section 2 OLD_FILES+=usr/share/man/man3/shm_open.3.gz OLD_FILES+=usr/share/man/man3/shm_unlink.3.gz # 20071207: Merged with fortunes-o.real OLD_FILES+=usr/share/games/fortune/fortunes2-o OLD_FILES+=usr/share/games/fortune/fortunes2-o.dat # 20071201: Removal of XRPU driver OLD_FILES+=usr/include/sys/xrpuio.h # 20071129: Disabled static versions of libkse by default OLD_FILES+=usr/lib/libkse.a OLD_FILES+=usr/lib/libkse_p.a OLD_FILES+=usr/lib/libkse_pic.a OLD_FILES+=usr/lib32/libkse.a OLD_FILES+=usr/lib32/libkse_p.a OLD_FILES+=usr/lib32/libkse_pic.a # 20071129: Removed a Solaris compatibility header OLD_FILES+=usr/include/sys/_elf_solaris.h # 20071125: Renamed to pmc_get_msr() OLD_FILES+=usr/share/man/man3/pmc_x86_get_msr.3.gz # 20071108: Removed very crunch OLDCARD support file OLD_FILES+=etc/defaults/pccard.conf # 20071025: rc.d/nfslocking superceeded by rc.d/lockd and rc.d/statd OLD_FILES+=etc/rc.d/nfslocking # 20070930: rename of cached to nscd OLD_FILES+=etc/cached.conf OLD_FILES+=etc/rc.d/cached OLD_FILES+=usr/sbin/cached OLD_FILES+=usr/share/man/man5/cached.conf.5.gz OLD_FILES+=usr/share/man/man8/cached.8.gz # 20070807: removal of PowerPC specific header file. .if ${TARGET_ARCH} == "powerpc" OLD_FILES+=usr/include/machine/interruptvar.h .endif # 20070801: fast_ipsec.4 gone OLD_FILES+=usr/share/man/man4/fast_ipsec.4.gz # 20070715: netatm temporarily disconnected (removed 20080525) OLD_FILES+=rescue/atm OLD_FILES+=rescue/fore_dnld OLD_FILES+=rescue/ilmid OLD_FILES+=sbin/atm OLD_FILES+=sbin/fore_dnld OLD_FILES+=sbin/ilmid OLD_FILES+=usr/include/libatm.h OLD_FILES+=usr/include/netatm/atm.h OLD_FILES+=usr/include/netatm/atm_cm.h OLD_FILES+=usr/include/netatm/atm_if.h OLD_FILES+=usr/include/netatm/atm_ioctl.h OLD_FILES+=usr/include/netatm/atm_pcb.h OLD_FILES+=usr/include/netatm/atm_sap.h OLD_FILES+=usr/include/netatm/atm_sigmgr.h OLD_FILES+=usr/include/netatm/atm_stack.h OLD_FILES+=usr/include/netatm/atm_sys.h OLD_FILES+=usr/include/netatm/atm_var.h OLD_FILES+=usr/include/netatm/atm_vc.h OLD_FILES+=usr/include/netatm/ipatm/ipatm.h OLD_FILES+=usr/include/netatm/ipatm/ipatm_serv.h OLD_FILES+=usr/include/netatm/ipatm/ipatm_var.h OLD_FILES+=usr/include/netatm/port.h OLD_FILES+=usr/include/netatm/queue.h OLD_FILES+=usr/include/netatm/sigpvc/sigpvc_var.h OLD_FILES+=usr/include/netatm/spans/spans_cls.h OLD_FILES+=usr/include/netatm/spans/spans_kxdr.h OLD_FILES+=usr/include/netatm/spans/spans_var.h OLD_FILES+=usr/include/netatm/uni/sscf_uni.h OLD_FILES+=usr/include/netatm/uni/sscf_uni_var.h OLD_FILES+=usr/include/netatm/uni/sscop.h OLD_FILES+=usr/include/netatm/uni/sscop_misc.h OLD_FILES+=usr/include/netatm/uni/sscop_pdu.h OLD_FILES+=usr/include/netatm/uni/sscop_var.h OLD_FILES+=usr/include/netatm/uni/uni.h OLD_FILES+=usr/include/netatm/uni/uniip_var.h OLD_FILES+=usr/include/netatm/uni/unisig.h OLD_FILES+=usr/include/netatm/uni/unisig_decode.h OLD_FILES+=usr/include/netatm/uni/unisig_mbuf.h OLD_FILES+=usr/include/netatm/uni/unisig_msg.h OLD_FILES+=usr/include/netatm/uni/unisig_print.h OLD_FILES+=usr/include/netatm/uni/unisig_var.h OLD_FILES+=usr/lib/libatm.a OLD_FILES+=usr/lib/libatm_p.a OLD_FILES+=usr/sbin/atmarpd OLD_FILES+=usr/sbin/scspd OLD_FILES+=usr/share/man/en.ISO8859-1/man8/atm.8.gz OLD_FILES+=usr/share/man/en.ISO8859-1/man8/atmarpd.8.gz OLD_FILES+=usr/share/man/en.ISO8859-1/man8/fore_dnld.8.gz OLD_FILES+=usr/share/man/en.ISO8859-1/man8/ilmid.8.gz OLD_FILES+=usr/share/man/en.ISO8859-1/man8/scspd.8.gz OLD_FILES+=usr/share/man/man8/atm.8.gz OLD_FILES+=usr/share/man/man8/atmarpd.8.gz OLD_FILES+=usr/share/man/man8/fore_dnld.8.gz OLD_FILES+=usr/share/man/man8/ilmid.8.gz OLD_FILES+=usr/share/man/man8/scspd.8.gz OLD_FILES+=usr/share/examples/atm/NOTES OLD_FILES+=usr/share/examples/atm/README OLD_FILES+=usr/share/examples/atm/Startup OLD_FILES+=usr/share/examples/atm/atm-config.sh OLD_FILES+=usr/share/examples/atm/atm-sockets.txt OLD_FILES+=usr/share/examples/atm/cpcs-design.txt OLD_FILES+=usr/share/examples/atm/fore-microcode.txt OLD_FILES+=usr/share/examples/atm/sscf-design.txt OLD_FILES+=usr/share/examples/atm/sscop-design.txt OLD_LIBS+=lib/libatm.so.5 OLD_LIBS+=usr/lib/libatm.so OLD_DIRS+=usr/include/netatm/sigpvc OLD_DIRS+=usr/include/netatm/spans OLD_DIRS+=usr/include/netatm/ipatm OLD_DIRS+=usr/include/netatm/uni OLD_DIRS+=usr/include/netatm OLD_DIRS+=usr/share/examples/atm OLD_FILES+=usr/lib32/libatm.a OLD_FILES+=usr/lib32/libatm.so OLD_LIBS+=usr/lib32/libatm.so.5 OLD_FILES+=usr/lib32/libatm_p.a # 20070705: I4B headers repo-copied to include/i4b/ .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/machine/i4b_cause.h OLD_FILES+=usr/include/machine/i4b_debug.h OLD_FILES+=usr/include/machine/i4b_ioctl.h OLD_FILES+=usr/include/machine/i4b_rbch_ioctl.h OLD_FILES+=usr/include/machine/i4b_tel_ioctl.h OLD_FILES+=usr/include/machine/i4b_trace.h .endif # 20070703: pf 4.1 import OLD_FILES+=usr/libexec/ftp-proxy # 20070701: KAME IPSec removal OLD_FILES+=usr/include/netinet6/ah.h OLD_FILES+=usr/include/netinet6/ah6.h OLD_FILES+=usr/include/netinet6/ah_aesxcbcmac.h OLD_FILES+=usr/include/netinet6/esp.h OLD_FILES+=usr/include/netinet6/esp6.h OLD_FILES+=usr/include/netinet6/esp_aesctr.h OLD_FILES+=usr/include/netinet6/esp_camellia.h OLD_FILES+=usr/include/netinet6/esp_rijndael.h OLD_FILES+=usr/include/netinet6/ipsec.h OLD_FILES+=usr/include/netinet6/ipsec6.h OLD_FILES+=usr/include/netinet6/ipcomp.h OLD_FILES+=usr/include/netinet6/ipcomp6.h OLD_FILES+=usr/include/netkey/key.h OLD_FILES+=usr/include/netkey/key_debug.h OLD_FILES+=usr/include/netkey/key_var.h OLD_FILES+=usr/include/netkey/keydb.h OLD_FILES+=usr/include/netkey/keysock.h OLD_DIRS+=usr/include/netkey # 20070701: remove wicontrol OLD_FILES+=usr/sbin/wicontrol OLD_FILES+=usr/share/man/man8/wicontrol.8.gz # 20070625: umapfs removal OLD_FILES+=rescue/mount_umapfs OLD_FILES+=sbin/mount_umapfs OLD_FILES+=usr/include/fs/umapfs/umap.h OLD_FILES+=usr/share/man/man8/mount_umapfs.8.gz OLD_DIRS+=usr/include/fs/umapfs # 20070618: Removal of the PROTO.localhost* files OLD_FILES+=etc/namedb/PROTO.localhost-v6.rev OLD_FILES+=etc/namedb/PROTO.localhost.rev OLD_FILES+=etc/namedb/make-localhost # 20070618: shared library version bump OLD_LIBS+=lib/libalias.so.5 OLD_LIBS+=lib/libbsnmp.so.3 OLD_LIBS+=lib/libncurses.so.6 OLD_LIBS+=lib/libncursesw.so.6 OLD_LIBS+=lib/libreadline.so.6 OLD_LIBS+=usr/lib/libdialog.so.5 OLD_LIBS+=usr/lib/libgnuregex.so.3 OLD_LIBS+=usr/lib/libhistory.so.6 OLD_LIBS+=usr/lib/libpam.so.3 OLD_LIBS+=usr/lib/libssh.so.3 OLD_LIBS+=usr/lib/pam_chroot.so.3 OLD_LIBS+=usr/lib/pam_deny.so.3 OLD_LIBS+=usr/lib/pam_echo.so.3 OLD_LIBS+=usr/lib/pam_exec.so.3 OLD_LIBS+=usr/lib/pam_ftpusers.so.3 OLD_LIBS+=usr/lib/pam_group.so.3 OLD_LIBS+=usr/lib/pam_guest.so.3 OLD_LIBS+=usr/lib/pam_krb5.so.3 OLD_LIBS+=usr/lib/pam_ksu.so.3 OLD_LIBS+=usr/lib/pam_lastlog.so.3 OLD_LIBS+=usr/lib/pam_login_access.so.3 OLD_LIBS+=usr/lib/pam_nologin.so.3 OLD_LIBS+=usr/lib/pam_opie.so.3 OLD_LIBS+=usr/lib/pam_opieaccess.so.3 OLD_LIBS+=usr/lib/pam_passwdqc.so.3 OLD_LIBS+=usr/lib/pam_permit.so.3 OLD_LIBS+=usr/lib/pam_radius.so.3 OLD_LIBS+=usr/lib/pam_rhosts.so.3 OLD_LIBS+=usr/lib/pam_rootok.so.3 OLD_LIBS+=usr/lib/pam_securetty.so.3 OLD_LIBS+=usr/lib/pam_self.so.3 OLD_LIBS+=usr/lib/pam_ssh.so.3 OLD_LIBS+=usr/lib/pam_tacplus.so.3 OLD_LIBS+=usr/lib/pam_unix.so.3 OLD_LIBS+=usr/lib/snmp_atm.so.4 OLD_LIBS+=usr/lib/snmp_bridge.so.4 OLD_LIBS+=usr/lib/snmp_hostres.so.4 OLD_LIBS+=usr/lib/snmp_mibII.so.4 OLD_LIBS+=usr/lib/snmp_netgraph.so.4 OLD_LIBS+=usr/lib/snmp_pf.so.4 OLD_LIBS+=usr/lib32/libalias.so.5 OLD_LIBS+=usr/lib32/libbsnmp.so.3 OLD_LIBS+=usr/lib32/libdialog.so.5 OLD_LIBS+=usr/lib32/libgnuregex.so.3 OLD_LIBS+=usr/lib32/libhistory.so.6 OLD_LIBS+=usr/lib32/libncurses.so.6 OLD_LIBS+=usr/lib32/libncursesw.so.6 OLD_LIBS+=usr/lib32/libpam.so.3 OLD_LIBS+=usr/lib32/libreadline.so.6 OLD_LIBS+=usr/lib32/libssh.so.3 OLD_LIBS+=usr/lib32/pam_chroot.so.3 OLD_LIBS+=usr/lib32/pam_deny.so.3 OLD_LIBS+=usr/lib32/pam_echo.so.3 OLD_LIBS+=usr/lib32/pam_exec.so.3 OLD_LIBS+=usr/lib32/pam_ftpusers.so.3 OLD_LIBS+=usr/lib32/pam_group.so.3 OLD_LIBS+=usr/lib32/pam_guest.so.3 OLD_LIBS+=usr/lib32/pam_krb5.so.3 OLD_LIBS+=usr/lib32/pam_ksu.so.3 OLD_LIBS+=usr/lib32/pam_lastlog.so.3 OLD_LIBS+=usr/lib32/pam_login_access.so.3 OLD_LIBS+=usr/lib32/pam_nologin.so.3 OLD_LIBS+=usr/lib32/pam_opie.so.3 OLD_LIBS+=usr/lib32/pam_opieaccess.so.3 OLD_LIBS+=usr/lib32/pam_passwdqc.so.3 OLD_LIBS+=usr/lib32/pam_permit.so.3 OLD_LIBS+=usr/lib32/pam_radius.so.3 OLD_LIBS+=usr/lib32/pam_rhosts.so.3 OLD_LIBS+=usr/lib32/pam_rootok.so.3 OLD_LIBS+=usr/lib32/pam_securetty.so.3 OLD_LIBS+=usr/lib32/pam_self.so.3 OLD_LIBS+=usr/lib32/pam_ssh.so.3 OLD_LIBS+=usr/lib32/pam_tacplus.so.3 OLD_LIBS+=usr/lib32/pam_unix.so.3 # 20070613: IPX over IP tunnel removal OLD_FILES+=usr/include/netipx/ipx_ip.h # 20070605: sched_core removal OLD_FILES+=usr/share/man/man4/sched_core.4.gz # 20070603: BIND 9.4.1 import OLD_LIBS+=usr/lib/liblwres.so.10 # 20070521: shared library version bump OLD_LIBS+=lib/libatm.so.4 OLD_LIBS+=lib/libbegemot.so.2 OLD_LIBS+=lib/libbsdxml.so.2 OLD_LIBS+=lib/libcam.so.3 OLD_LIBS+=lib/libcrypt.so.3 OLD_LIBS+=lib/libdevstat.so.5 OLD_LIBS+=lib/libedit.so.5 OLD_LIBS+=lib/libgeom.so.3 OLD_LIBS+=lib/libipsec.so.2 OLD_LIBS+=lib/libipx.so.3 OLD_LIBS+=lib/libkiconv.so.2 OLD_LIBS+=lib/libkse.so.2 OLD_LIBS+=lib/libkvm.so.3 OLD_LIBS+=lib/libm.so.4 OLD_LIBS+=lib/libmd.so.3 OLD_LIBS+=lib/libpcap.so.4 OLD_LIBS+=lib/libpthread.so.2 OLD_LIBS+=lib/libsbuf.so.3 OLD_LIBS+=lib/libthr.so.2 OLD_LIBS+=lib/libufs.so.3 OLD_LIBS+=lib/libutil.so.6 OLD_LIBS+=lib/libz.so.3 OLD_LIBS+=usr/lib/libbluetooth.so.2 OLD_LIBS+=usr/lib/libbsm.so.1 OLD_LIBS+=usr/lib/libbz2.so.2 OLD_LIBS+=usr/lib/libcalendar.so.3 OLD_LIBS+=usr/lib/libcom_err.so.3 OLD_LIBS+=usr/lib/libdevinfo.so.3 OLD_LIBS+=usr/lib/libfetch.so.4 OLD_LIBS+=usr/lib/libform.so.3 OLD_LIBS+=usr/lib/libformw.so.3 OLD_LIBS+=usr/lib/libftpio.so.6 OLD_LIBS+=usr/lib/libgpib.so.1 OLD_LIBS+=usr/lib/libkse.so.2 OLD_LIBS+=usr/lib/libmagic.so.2 OLD_LIBS+=usr/lib/libmemstat.so.1 OLD_LIBS+=usr/lib/libmenu.so.3 OLD_LIBS+=usr/lib/libmenuw.so.3 OLD_LIBS+=usr/lib/libmilter.so.3 OLD_LIBS+=usr/lib/libmp.so.5 OLD_LIBS+=usr/lib/libncp.so.2 OLD_LIBS+=usr/lib/libnetgraph.so.2 OLD_LIBS+=usr/lib/libngatm.so.2 OLD_LIBS+=usr/lib/libopie.so.4 OLD_LIBS+=usr/lib/libpanel.so.3 OLD_LIBS+=usr/lib/libpanelw.so.3 OLD_LIBS+=usr/lib/libpmc.so.3 OLD_LIBS+=usr/lib/libradius.so.2 OLD_LIBS+=usr/lib/librpcsvc.so.3 OLD_LIBS+=usr/lib/libsdp.so.2 OLD_LIBS+=usr/lib/libsmb.so.2 OLD_LIBS+=usr/lib/libstdc++.so.5 OLD_LIBS+=usr/lib/libtacplus.so.2 OLD_LIBS+=usr/lib/libthr.so.2 OLD_LIBS+=usr/lib/libthread_db.so.2 OLD_LIBS+=usr/lib/libugidfw.so.2 OLD_LIBS+=usr/lib/libusbhid.so.2 OLD_LIBS+=usr/lib/libvgl.so.4 OLD_LIBS+=usr/lib/libwrap.so.4 OLD_LIBS+=usr/lib/libypclnt.so.2 OLD_LIBS+=usr/lib/snmp_bridge.so.3 OLD_LIBS+=usr/lib/snmp_hostres.so.3 OLD_LIBS+=usr/lib32/libatm.so.4 OLD_LIBS+=usr/lib32/libbegemot.so.2 OLD_LIBS+=usr/lib32/libbluetooth.so.2 OLD_LIBS+=usr/lib32/libbsdxml.so.2 OLD_LIBS+=usr/lib32/libbsm.so.1 OLD_LIBS+=usr/lib32/libbz2.so.2 OLD_LIBS+=usr/lib32/libcalendar.so.3 OLD_LIBS+=usr/lib32/libcam.so.3 OLD_LIBS+=usr/lib32/libcom_err.so.3 OLD_LIBS+=usr/lib32/libcrypt.so.3 OLD_LIBS+=usr/lib32/libdevinfo.so.3 OLD_LIBS+=usr/lib32/libdevstat.so.5 OLD_LIBS+=usr/lib32/libedit.so.5 OLD_LIBS+=usr/lib32/libfetch.so.4 OLD_LIBS+=usr/lib32/libform.so.3 OLD_LIBS+=usr/lib32/libformw.so.3 OLD_LIBS+=usr/lib32/libftpio.so.6 OLD_LIBS+=usr/lib32/libgeom.so.3 OLD_LIBS+=usr/lib32/libgpib.so.1 OLD_LIBS+=usr/lib32/libipsec.so.2 OLD_LIBS+=usr/lib32/libipx.so.3 OLD_LIBS+=usr/lib32/libkiconv.so.2 OLD_LIBS+=usr/lib32/libkse.so.2 OLD_LIBS+=usr/lib32/libkvm.so.3 OLD_LIBS+=usr/lib32/libm.so.4 OLD_LIBS+=usr/lib32/libmagic.so.2 OLD_LIBS+=usr/lib32/libmd.so.3 OLD_LIBS+=usr/lib32/libmemstat.so.1 OLD_LIBS+=usr/lib32/libmenu.so.3 OLD_LIBS+=usr/lib32/libmenuw.so.3 OLD_LIBS+=usr/lib32/libmilter.so.3 OLD_LIBS+=usr/lib32/libmp.so.5 OLD_LIBS+=usr/lib32/libncp.so.2 OLD_LIBS+=usr/lib32/libnetgraph.so.2 OLD_LIBS+=usr/lib32/libngatm.so.2 OLD_LIBS+=usr/lib32/libopie.so.4 OLD_LIBS+=usr/lib32/libpanel.so.3 OLD_LIBS+=usr/lib32/libpanelw.so.3 OLD_LIBS+=usr/lib32/libpcap.so.4 OLD_LIBS+=usr/lib32/libpmc.so.3 OLD_LIBS+=usr/lib32/libpthread.so.2 OLD_LIBS+=usr/lib32/libradius.so.2 OLD_LIBS+=usr/lib32/librpcsvc.so.3 OLD_LIBS+=usr/lib32/libsbuf.so.3 OLD_LIBS+=usr/lib32/libsdp.so.2 OLD_LIBS+=usr/lib32/libsmb.so.2 OLD_LIBS+=usr/lib32/libstdc++.so.5 OLD_LIBS+=usr/lib32/libtacplus.so.2 OLD_LIBS+=usr/lib32/libthr.so.2 OLD_LIBS+=usr/lib32/libthread_db.so.2 OLD_LIBS+=usr/lib32/libufs.so.3 OLD_LIBS+=usr/lib32/libugidfw.so.2 OLD_LIBS+=usr/lib32/libusbhid.so.2 OLD_LIBS+=usr/lib32/libutil.so.6 OLD_LIBS+=usr/lib32/libvgl.so.4 OLD_LIBS+=usr/lib32/libwrap.so.4 OLD_LIBS+=usr/lib32/libypclnt.so.2 OLD_LIBS+=usr/lib32/libz.so.3 # 20070519: GCC 4.2 OLD_FILES+=usr/bin/f77 OLD_FILES+=usr/bin/protoize OLD_FILES+=usr/include/g2c.h OLD_FILES+=usr/libexec/f771 OLD_FILES+=usr/share/info/g77.info.gz OLD_FILES+=usr/share/man/man1/f77.1.gz OLD_FILES+=usr/include/c++/3.4/algorithm OLD_FILES+=usr/include/c++/3.4/backward/algo.h OLD_FILES+=usr/include/c++/3.4/backward/algobase.h OLD_FILES+=usr/include/c++/3.4/backward/alloc.h OLD_FILES+=usr/include/c++/3.4/backward/backward_warning.h OLD_FILES+=usr/include/c++/3.4/backward/bvector.h OLD_FILES+=usr/include/c++/3.4/backward/complex.h OLD_FILES+=usr/include/c++/3.4/backward/defalloc.h OLD_FILES+=usr/include/c++/3.4/backward/deque.h OLD_FILES+=usr/include/c++/3.4/backward/fstream.h OLD_FILES+=usr/include/c++/3.4/backward/function.h OLD_FILES+=usr/include/c++/3.4/backward/hash_map.h OLD_FILES+=usr/include/c++/3.4/backward/hash_set.h OLD_FILES+=usr/include/c++/3.4/backward/hashtable.h OLD_FILES+=usr/include/c++/3.4/backward/heap.h OLD_FILES+=usr/include/c++/3.4/backward/iomanip.h OLD_FILES+=usr/include/c++/3.4/backward/iostream.h OLD_FILES+=usr/include/c++/3.4/backward/istream.h OLD_FILES+=usr/include/c++/3.4/backward/iterator.h OLD_FILES+=usr/include/c++/3.4/backward/list.h OLD_FILES+=usr/include/c++/3.4/backward/map.h OLD_FILES+=usr/include/c++/3.4/backward/multimap.h OLD_FILES+=usr/include/c++/3.4/backward/multiset.h OLD_FILES+=usr/include/c++/3.4/backward/new.h OLD_FILES+=usr/include/c++/3.4/backward/ostream.h OLD_FILES+=usr/include/c++/3.4/backward/pair.h OLD_FILES+=usr/include/c++/3.4/backward/queue.h OLD_FILES+=usr/include/c++/3.4/backward/rope.h OLD_FILES+=usr/include/c++/3.4/backward/set.h OLD_FILES+=usr/include/c++/3.4/backward/slist.h OLD_FILES+=usr/include/c++/3.4/backward/stack.h OLD_FILES+=usr/include/c++/3.4/backward/stream.h OLD_FILES+=usr/include/c++/3.4/backward/streambuf.h OLD_FILES+=usr/include/c++/3.4/backward/strstream OLD_FILES+=usr/include/c++/3.4/backward/tempbuf.h OLD_FILES+=usr/include/c++/3.4/backward/tree.h OLD_FILES+=usr/include/c++/3.4/backward/vector.h OLD_FILES+=usr/include/c++/3.4/bits/allocator.h OLD_FILES+=usr/include/c++/3.4/bits/atomic_word.h OLD_FILES+=usr/include/c++/3.4/bits/atomicity.h OLD_FILES+=usr/include/c++/3.4/bits/basic_file.h OLD_FILES+=usr/include/c++/3.4/bits/basic_ios.h OLD_FILES+=usr/include/c++/3.4/bits/basic_ios.tcc OLD_FILES+=usr/include/c++/3.4/bits/basic_string.h OLD_FILES+=usr/include/c++/3.4/bits/basic_string.tcc OLD_FILES+=usr/include/c++/3.4/bits/boost_concept_check.h OLD_FILES+=usr/include/c++/3.4/bits/c++allocator.h OLD_FILES+=usr/include/c++/3.4/bits/c++config.h OLD_FILES+=usr/include/c++/3.4/bits/c++io.h OLD_FILES+=usr/include/c++/3.4/bits/c++locale.h OLD_FILES+=usr/include/c++/3.4/bits/c++locale_internal.h OLD_FILES+=usr/include/c++/3.4/bits/char_traits.h OLD_FILES+=usr/include/c++/3.4/bits/cmath.tcc OLD_FILES+=usr/include/c++/3.4/bits/codecvt.h OLD_FILES+=usr/include/c++/3.4/bits/codecvt_specializations.h OLD_FILES+=usr/include/c++/3.4/bits/concept_check.h OLD_FILES+=usr/include/c++/3.4/bits/concurrence.h OLD_FILES+=usr/include/c++/3.4/bits/cpp_type_traits.h OLD_FILES+=usr/include/c++/3.4/bits/ctype_base.h OLD_FILES+=usr/include/c++/3.4/bits/ctype_inline.h OLD_FILES+=usr/include/c++/3.4/bits/ctype_noninline.h OLD_FILES+=usr/include/c++/3.4/bits/deque.tcc OLD_FILES+=usr/include/c++/3.4/bits/fstream.tcc OLD_FILES+=usr/include/c++/3.4/bits/functexcept.h OLD_FILES+=usr/include/c++/3.4/bits/gslice.h OLD_FILES+=usr/include/c++/3.4/bits/gslice_array.h OLD_FILES+=usr/include/c++/3.4/bits/gthr-default.h OLD_FILES+=usr/include/c++/3.4/bits/gthr-posix.h OLD_FILES+=usr/include/c++/3.4/bits/gthr-single.h OLD_FILES+=usr/include/c++/3.4/bits/gthr.h OLD_FILES+=usr/include/c++/3.4/bits/indirect_array.h OLD_FILES+=usr/include/c++/3.4/bits/ios_base.h OLD_FILES+=usr/include/c++/3.4/bits/istream.tcc OLD_FILES+=usr/include/c++/3.4/bits/list.tcc OLD_FILES+=usr/include/c++/3.4/bits/locale_classes.h OLD_FILES+=usr/include/c++/3.4/bits/locale_facets.h OLD_FILES+=usr/include/c++/3.4/bits/locale_facets.tcc OLD_FILES+=usr/include/c++/3.4/bits/localefwd.h OLD_FILES+=usr/include/c++/3.4/bits/mask_array.h OLD_FILES+=usr/include/c++/3.4/bits/messages_members.h OLD_FILES+=usr/include/c++/3.4/bits/os_defines.h OLD_FILES+=usr/include/c++/3.4/bits/ostream.tcc OLD_FILES+=usr/include/c++/3.4/bits/postypes.h OLD_FILES+=usr/include/c++/3.4/bits/slice_array.h OLD_FILES+=usr/include/c++/3.4/bits/sstream.tcc OLD_FILES+=usr/include/c++/3.4/bits/stl_algo.h OLD_FILES+=usr/include/c++/3.4/bits/stl_algobase.h OLD_FILES+=usr/include/c++/3.4/bits/stl_bvector.h OLD_FILES+=usr/include/c++/3.4/bits/stl_construct.h OLD_FILES+=usr/include/c++/3.4/bits/stl_deque.h OLD_FILES+=usr/include/c++/3.4/bits/stl_function.h OLD_FILES+=usr/include/c++/3.4/bits/stl_heap.h OLD_FILES+=usr/include/c++/3.4/bits/stl_iterator.h OLD_FILES+=usr/include/c++/3.4/bits/stl_iterator_base_funcs.h OLD_FILES+=usr/include/c++/3.4/bits/stl_iterator_base_types.h OLD_FILES+=usr/include/c++/3.4/bits/stl_list.h OLD_FILES+=usr/include/c++/3.4/bits/stl_map.h OLD_FILES+=usr/include/c++/3.4/bits/stl_multimap.h OLD_FILES+=usr/include/c++/3.4/bits/stl_multiset.h OLD_FILES+=usr/include/c++/3.4/bits/stl_numeric.h OLD_FILES+=usr/include/c++/3.4/bits/stl_pair.h OLD_FILES+=usr/include/c++/3.4/bits/stl_queue.h OLD_FILES+=usr/include/c++/3.4/bits/stl_raw_storage_iter.h OLD_FILES+=usr/include/c++/3.4/bits/stl_relops.h OLD_FILES+=usr/include/c++/3.4/bits/stl_set.h OLD_FILES+=usr/include/c++/3.4/bits/stl_stack.h OLD_FILES+=usr/include/c++/3.4/bits/stl_tempbuf.h OLD_FILES+=usr/include/c++/3.4/bits/stl_threads.h OLD_FILES+=usr/include/c++/3.4/bits/stl_tree.h OLD_FILES+=usr/include/c++/3.4/bits/stl_uninitialized.h OLD_FILES+=usr/include/c++/3.4/bits/stl_vector.h OLD_FILES+=usr/include/c++/3.4/bits/stream_iterator.h OLD_FILES+=usr/include/c++/3.4/bits/streambuf.tcc OLD_FILES+=usr/include/c++/3.4/bits/streambuf_iterator.h OLD_FILES+=usr/include/c++/3.4/bits/stringfwd.h OLD_FILES+=usr/include/c++/3.4/bits/time_members.h OLD_FILES+=usr/include/c++/3.4/bits/type_traits.h OLD_FILES+=usr/include/c++/3.4/bits/valarray_after.h OLD_FILES+=usr/include/c++/3.4/bits/valarray_array.h OLD_FILES+=usr/include/c++/3.4/bits/valarray_array.tcc OLD_FILES+=usr/include/c++/3.4/bits/valarray_before.h OLD_FILES+=usr/include/c++/3.4/bits/vector.tcc OLD_FILES+=usr/include/c++/3.4/bitset OLD_FILES+=usr/include/c++/3.4/cassert OLD_FILES+=usr/include/c++/3.4/cctype OLD_FILES+=usr/include/c++/3.4/cerrno OLD_FILES+=usr/include/c++/3.4/cfloat OLD_FILES+=usr/include/c++/3.4/ciso646 OLD_FILES+=usr/include/c++/3.4/climits OLD_FILES+=usr/include/c++/3.4/clocale OLD_FILES+=usr/include/c++/3.4/cmath OLD_FILES+=usr/include/c++/3.4/complex OLD_FILES+=usr/include/c++/3.4/csetjmp OLD_FILES+=usr/include/c++/3.4/csignal OLD_FILES+=usr/include/c++/3.4/cstdarg OLD_FILES+=usr/include/c++/3.4/cstddef OLD_FILES+=usr/include/c++/3.4/cstdio OLD_FILES+=usr/include/c++/3.4/cstdlib OLD_FILES+=usr/include/c++/3.4/cstring OLD_FILES+=usr/include/c++/3.4/ctime OLD_FILES+=usr/include/c++/3.4/cwchar OLD_FILES+=usr/include/c++/3.4/cwctype OLD_FILES+=usr/include/c++/3.4/cxxabi.h OLD_FILES+=usr/include/c++/3.4/debug/bitset OLD_FILES+=usr/include/c++/3.4/debug/debug.h OLD_FILES+=usr/include/c++/3.4/debug/deque OLD_FILES+=usr/include/c++/3.4/debug/formatter.h OLD_FILES+=usr/include/c++/3.4/debug/hash_map OLD_FILES+=usr/include/c++/3.4/debug/hash_map.h OLD_FILES+=usr/include/c++/3.4/debug/hash_multimap.h OLD_FILES+=usr/include/c++/3.4/debug/hash_multiset.h OLD_FILES+=usr/include/c++/3.4/debug/hash_set OLD_FILES+=usr/include/c++/3.4/debug/hash_set.h OLD_FILES+=usr/include/c++/3.4/debug/list OLD_FILES+=usr/include/c++/3.4/debug/map OLD_FILES+=usr/include/c++/3.4/debug/map.h OLD_FILES+=usr/include/c++/3.4/debug/multimap.h OLD_FILES+=usr/include/c++/3.4/debug/multiset.h OLD_FILES+=usr/include/c++/3.4/debug/safe_base.h OLD_FILES+=usr/include/c++/3.4/debug/safe_iterator.h OLD_FILES+=usr/include/c++/3.4/debug/safe_iterator.tcc OLD_FILES+=usr/include/c++/3.4/debug/safe_sequence.h OLD_FILES+=usr/include/c++/3.4/debug/set OLD_FILES+=usr/include/c++/3.4/debug/set.h OLD_FILES+=usr/include/c++/3.4/debug/string OLD_FILES+=usr/include/c++/3.4/debug/vector OLD_FILES+=usr/include/c++/3.4/deque OLD_FILES+=usr/include/c++/3.4/exception OLD_FILES+=usr/include/c++/3.4/exception_defines.h OLD_FILES+=usr/include/c++/3.4/ext/algorithm OLD_FILES+=usr/include/c++/3.4/ext/bitmap_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/debug_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/enc_filebuf.h OLD_FILES+=usr/include/c++/3.4/ext/functional OLD_FILES+=usr/include/c++/3.4/ext/hash_fun.h OLD_FILES+=usr/include/c++/3.4/ext/hash_map OLD_FILES+=usr/include/c++/3.4/ext/hash_set OLD_FILES+=usr/include/c++/3.4/ext/hashtable.h OLD_FILES+=usr/include/c++/3.4/ext/iterator OLD_FILES+=usr/include/c++/3.4/ext/malloc_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/memory OLD_FILES+=usr/include/c++/3.4/ext/mt_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/new_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/numeric OLD_FILES+=usr/include/c++/3.4/ext/pod_char_traits.h OLD_FILES+=usr/include/c++/3.4/ext/pool_allocator.h OLD_FILES+=usr/include/c++/3.4/ext/rb_tree OLD_FILES+=usr/include/c++/3.4/ext/rope OLD_FILES+=usr/include/c++/3.4/ext/ropeimpl.h OLD_FILES+=usr/include/c++/3.4/ext/slist OLD_FILES+=usr/include/c++/3.4/ext/stdio_filebuf.h OLD_FILES+=usr/include/c++/3.4/ext/stdio_sync_filebuf.h OLD_FILES+=usr/include/c++/3.4/fstream OLD_FILES+=usr/include/c++/3.4/functional OLD_FILES+=usr/include/c++/3.4/iomanip OLD_FILES+=usr/include/c++/3.4/ios OLD_FILES+=usr/include/c++/3.4/iosfwd OLD_FILES+=usr/include/c++/3.4/iostream OLD_FILES+=usr/include/c++/3.4/istream OLD_FILES+=usr/include/c++/3.4/iterator OLD_FILES+=usr/include/c++/3.4/limits OLD_FILES+=usr/include/c++/3.4/list OLD_FILES+=usr/include/c++/3.4/locale OLD_FILES+=usr/include/c++/3.4/map OLD_FILES+=usr/include/c++/3.4/memory OLD_FILES+=usr/include/c++/3.4/new OLD_FILES+=usr/include/c++/3.4/numeric OLD_FILES+=usr/include/c++/3.4/ostream OLD_FILES+=usr/include/c++/3.4/queue OLD_FILES+=usr/include/c++/3.4/set OLD_FILES+=usr/include/c++/3.4/sstream OLD_FILES+=usr/include/c++/3.4/stack OLD_FILES+=usr/include/c++/3.4/stdexcept OLD_FILES+=usr/include/c++/3.4/streambuf OLD_FILES+=usr/include/c++/3.4/string OLD_FILES+=usr/include/c++/3.4/typeinfo OLD_FILES+=usr/include/c++/3.4/utility OLD_FILES+=usr/include/c++/3.4/valarray OLD_FILES+=usr/include/c++/3.4/vector OLD_DIRS+=usr/include/c++/3.4/backward OLD_DIRS+=usr/include/c++/3.4/bits OLD_DIRS+=usr/include/c++/3.4/debug OLD_DIRS+=usr/include/c++/3.4/ext OLD_DIRS+=usr/include/c++/3.4 # 20070510: zpool/zfs moved to /sbin OLD_FILES+=usr/sbin/zfs OLD_FILES+=usr/sbin/zpool # 20070423: rc.bluetooth (examples) removed OLD_FILES+=usr/share/examples/netgraph/bluetooth/rc.bluetooth OLD_DIRS+=usr/share/examples/netgraph/bluetooth # 20070421: worm.4 removed OLD_FILES+=usr/share/man/man4/worm.4.gz # 20070417: trunk(4) renamed to lagg(4) OLD_FILES+=usr/include/net/if_trunk.h # 20070409: uuidgen moved to /bin/ OLD_FILES+=usr/bin/uuidgen # 20070328: bzip2 1.0.4 OLD_FILES+=usr/share/info/bzip2.info.gz # 20070303: libarchive 2.0 OLD_LIBS+=usr/lib/libarchive.so.3 OLD_LIBS+=usr/lib32/libarchive.so.3 # 20070301: remove addr2ascii and ascii2addr OLD_FILES+=usr/share/man/man3/addr2ascii.3.gz OLD_FILES+=usr/share/man/man3/ascii2addr.3.gz # 20070225: vm_page_unmanage() removed OLD_FILES+=usr/share/man/man9/vm_page_unmanage.9.gz # 20070216: VFS_VPTOFH(9) -> VOP_VPTOFH(9) OLD_FILES+=usr/share/man/man9/VFS_VPTOFH.9.gz # 20070212: kame.4 removed OLD_FILES+=usr/share/man/man4/kame.4.gz # 20070201: remove libmytinfo link OLD_FILES+=usr/lib/libmytinfo.a OLD_FILES+=usr/lib/libmytinfo.so OLD_FILES+=usr/lib/libmytinfo_p.a OLD_FILES+=usr/lib/libmytinfow.a OLD_FILES+=usr/lib/libmytinfow.so OLD_FILES+=usr/lib/libmytinfow_p.a OLD_FILES+=usr/lib32/libmytinfo.a OLD_FILES+=usr/lib32/libmytinfo.so OLD_FILES+=usr/lib32/libmytinfo_p.a OLD_FILES+=usr/lib32/libmytinfow.a OLD_FILES+=usr/lib32/libmytinfow.so OLD_FILES+=usr/lib32/libmytinfow_p.a # 20070128: remove vnconfig OLD_FILES+=usr/sbin/vnconfig # 20070127: remove bpf_compat.h OLD_FILES+=usr/include/net/bpf_compat.h # 20070125: objformat bites the dust OLD_FILES+=usr/bin/objformat OLD_FILES+=usr/share/man/man1/objformat.1.gz OLD_FILES+=usr/include/objformat.h OLD_FILES+=usr/share/man/man3/getobjformat.3.gz # 20061201: remove symlink to *.so.4 libalias modules OLD_FILES+=usr/lib/libalias_cuseeme.so OLD_FILES+=usr/lib/libalias_dummy.so OLD_FILES+=usr/lib/libalias_ftp.so OLD_FILES+=usr/lib/libalias_irc.so OLD_FILES+=usr/lib/libalias_nbt.so OLD_FILES+=usr/lib/libalias_pptp.so OLD_FILES+=usr/lib/libalias_skinny.so OLD_FILES+=usr/lib/libalias_smedia.so # 20061201: remove old *.so.4 libalias modules OLD_FILES+=lib/libalias_cuseeme.so.4 OLD_FILES+=lib/libalias_dummy.so.4 OLD_FILES+=lib/libalias_ftp.so.4 OLD_FILES+=lib/libalias_irc.so.4 OLD_FILES+=lib/libalias_nbt.so.4 OLD_FILES+=lib/libalias_pptp.so.4 OLD_FILES+=lib/libalias_skinny.so.4 OLD_FILES+=lib/libalias_smedia.so.4 # 20061126: remove old man page OLD_FILES+=usr/share/man/man3/archive_read_set_bytes_per_block.3.gz # 20061125: remove old man page OLD_FILES+=usr/share/man/man9/devsw.9.gz # 20061122: remove obsolete mount programs OLD_FILES+=sbin/mount_devfs OLD_FILES+=sbin/mount_ext2fs OLD_FILES+=sbin/mount_fdescfs OLD_FILES+=sbin/mount_linprocfs OLD_FILES+=sbin/mount_procfs OLD_FILES+=sbin/mount_std OLD_FILES+=rescue/mount_devfs OLD_FILES+=rescue/mount_ext2fs OLD_FILES+=rescue/mount_fdescfs OLD_FILES+=rescue/mount_linprocfs OLD_FILES+=rescue/mount_procfs OLD_FILES+=rescue/mount_std OLD_FILES+=usr/share/man/man8/mount_devfs.8.gz OLD_FILES+=usr/share/man/man8/mount_ext2fs.8.gz OLD_FILES+=usr/share/man/man8/mount_fdescfs.8.gz OLD_FILES+=usr/share/man/man8/mount_linprocfs.8.gz OLD_FILES+=usr/share/man/man8/mount_procfs.8.gz OLD_FILES+=usr/share/man/man8/mount_std.8.gz # 20061116: uhidev.4 removed OLD_FILES+=usr/share/man/man4/uhidev.4.gz # 20061106: archive_write_prepare.3 removed OLD_FILES+=usr/share/man/man3/archive_write_prepare.3.gz # 20061018: pccardc removed OLD_FILES+=usr/sbin/pccardc usr/share/man/man8/pccardc.8.gz # 20060930: demangle.h from contrib/libstdc++/include/ext/ OLD_FILES+=usr/include/c++/3.4/ext/demangle.h # 20060929: mrouted removed OLD_FILES+=usr/sbin/map-mbone OLD_FILES+=usr/sbin/mrinfo OLD_FILES+=usr/sbin/mrouted OLD_FILES+=usr/sbin/mtrace OLD_FILES+=usr/share/man/man8/map-mbone.8.gz OLD_FILES+=usr/share/man/man8/mrinfo.8.gz OLD_FILES+=usr/share/man/man8/mrouted.8.gz OLD_FILES+=usr/share/man/man8/mtrace.8.gz # 20060924: tcpslice removed OLD_FILES+=usr/sbin/tcpslice OLD_FILES+=usr/share/man/man1/tcpslice.1.gz # 20060829: kvmdb cleanup script removed OLD_FILES+=etc/periodic/weekly/120.clean-kvmdb # 20060822: ramdisk{,-own} have been replaced by mdconfig{,2} OLD_FILES+=etc/rc.d/ramdisk OLD_FILES+=etc/rc.d/ramdisk-own # 20060729: OpenSSL 0.9.7e -> 0.9.8b upgrade OLD_FILES+=usr/include/openssl/eng_int.h OLD_FILES+=usr/include/openssl/hw_4758_cca_err.h OLD_FILES+=usr/include/openssl/hw_aep_err.h OLD_FILES+=usr/include/openssl/hw_atalla_err.h OLD_FILES+=usr/include/openssl/hw_cswift_err.h OLD_FILES+=usr/include/openssl/hw_ncipher_err.h OLD_FILES+=usr/include/openssl/hw_nuron_err.h OLD_FILES+=usr/include/openssl/hw_sureware_err.h OLD_FILES+=usr/include/openssl/hw_ubsec_err.h # 20060713: mount_linsysfs(8) never existed in 7.x OLD_FILES+=sbin/mount_linsysfs OLD_FILES+=usr/share/man/man8/mount_linsysfs.8.gz # 20060704: KAME compat file net_osdep.h removed OLD_FILES+=usr/include/net/net_osdep.h # 20060605: man page links removed by OpenBSM 1.0 alpha 6 import OLD_FILES+=usr/share/man/man3/au_to_socket.3.gz OLD_FILES+=usr/share/man/man3/au_to_socket_ex_128.3.gz OLD_FILES+=usr/share/man/man3/au_to_socket_ex_32.3.gz # 20060517: pcvt removed OLD_FILES+=usr/share/pcvt/README.FIRST OLD_FILES+=usr/share/pcvt/Etc/xmodmap-german OLD_FILES+=usr/share/pcvt/Etc/pcvt.sh OLD_FILES+=usr/share/pcvt/Etc/pcvt.el OLD_FILES+=usr/share/pcvt/Etc/Terminfo OLD_FILES+=usr/share/pcvt/Etc/Termcap OLD_DIRS+=usr/share/pcvt/Etc OLD_FILES+=usr/share/pcvt/Doc/NotesAndHints OLD_FILES+=usr/share/pcvt/Doc/Keyboard.VT OLD_FILES+=usr/share/pcvt/Doc/Keyboard.HP OLD_FILES+=usr/share/pcvt/Doc/EscapeSequences OLD_FILES+=usr/share/pcvt/Doc/Charsets OLD_FILES+=usr/share/pcvt/Doc/CharGen OLD_FILES+=usr/share/pcvt/Doc/Bibliography OLD_FILES+=usr/share/pcvt/Doc/Acknowledgements OLD_DIRS+=usr/share/pcvt/Doc OLD_DIRS+=usr/share/pcvt OLD_FILES+=usr/share/misc/pcvtfonts/vt220l.816 OLD_FILES+=usr/share/misc/pcvtfonts/vt220l.814 OLD_FILES+=usr/share/misc/pcvtfonts/vt220l.810 OLD_FILES+=usr/share/misc/pcvtfonts/vt220l.808 OLD_FILES+=usr/share/misc/pcvtfonts/vt220h.816 OLD_FILES+=usr/share/misc/pcvtfonts/vt220h.814 OLD_FILES+=usr/share/misc/pcvtfonts/vt220h.810 OLD_FILES+=usr/share/misc/pcvtfonts/vt220h.808 OLD_DIRS+=usr/share/misc/pcvtfonts OLD_FILES+=usr/share/misc/keycap.pcvt OLD_FILES+=usr/share/man/man8/ispcvt.8.gz OLD_FILES+=usr/share/man/man5/keycap.5.gz OLD_FILES+=usr/share/man/man4/pcvt.4.gz OLD_FILES+=usr/share/man/man3/kgetstr.3.gz OLD_FILES+=usr/share/man/man3/kgetnum.3.gz OLD_FILES+=usr/share/man/man3/kgetflag.3.gz OLD_FILES+=usr/share/man/man3/kgetent.3.gz OLD_FILES+=usr/share/man/man3/keycap.3.gz OLD_FILES+=usr/share/man/man1/vt220keys.1.gz OLD_FILES+=usr/share/man/man1/scon.1.gz OLD_FILES+=usr/share/man/man1/loadfont.1.gz OLD_FILES+=usr/share/man/man1/kcon.1.gz OLD_FILES+=usr/share/man/man1/fontedit.1.gz OLD_FILES+=usr/share/man/man1/cursor.1.gz OLD_FILES+=usr/sbin/vt220keys OLD_FILES+=usr/sbin/scon OLD_FILES+=usr/sbin/loadfont OLD_FILES+=usr/sbin/kcon OLD_FILES+=usr/sbin/ispcvt OLD_FILES+=usr/sbin/fontedit OLD_FILES+=usr/sbin/cursor OLD_FILES+=usr/lib/libkeycap_p.a OLD_FILES+=usr/lib/libkeycap.a OLD_FILES+=usr/include/machine/pcvt_ioctl.h # 20060514: lnc(4) replaced by le(4) OLD_FILES+=usr/share/man/man4/i386/lnc.4.gz # 20060512: remove ip6fw OLD_FILES+=etc/periodic/security/600.ip6fwdenied OLD_FILES+=etc/periodic/security/650.ip6fwlimit OLD_FILES+=sbin/ip6fw OLD_FILES+=usr/include/netinet6/ip6_fw.h OLD_FILES+=usr/share/man/man8/ip6fw.8.gz # 20060424: sab(4) removed OLD_FILES+=usr/share/man/man4/sab.4.gz # 20060328: remove redundant rc.d script OLD_FILES+=etc/rc.d/ike # 20060127: revert libdisk to static-only OLD_FILES+=usr/lib/libdisk.so # 20060115: sys/pccard includes cleanup OLD_FILES+=usr/include/pccard/driver.h OLD_FILES+=usr/include/pccard/i82365.h OLD_FILES+=usr/include/pccard/meciareg.h OLD_FILES+=usr/include/pccard/pccard_nbk.h OLD_FILES+=usr/include/pccard/pcic_pci.h OLD_FILES+=usr/include/pccard/pcicvar.h OLD_FILES+=usr/include/pccard/slot.h # 20051215: rescue/nextboot.sh renamed to rescue/nextboot OLD_FILES+=rescue/nextboot.sh # 20051214: usbd(8) removed OLD_FILES+=etc/rc.d/usbd OLD_FILES+=etc/usbd.conf OLD_FILES+=usr/sbin/usbd OLD_FILES+=usr/share/man/man8/usbd.8.gz # 20051029: rc.d/ppp-user renamed to rc.d/ppp for convenience OLD_FILES+=etc/rc.d/ppp-user # 20051012: setkey(8) moved to /sbin/ OLD_FILES+=usr/sbin/setkey # 20050930: pccardd(8) removed OLD_FILES+=usr/sbin/pccardd OLD_FILES+=usr/share/man/man5/pccard.conf.5.gz OLD_FILES+=usr/share/man/man8/pccardd.8.gz # 20050927: bridge(4) replaced by if_bridge(4) OLD_FILES+=usr/include/net/bridge.h # 20050831: not implemented OLD_FILES+=usr/share/man/man3/getino.3.gz OLD_FILES+=usr/share/man/man3/putino.3.gz # 20050825: T/TCP retired several months ago OLD_FILES+=usr/share/man/man4/ttcp.4.gz # 20050805 tn3270 retired long ago OLD_FILES+=usr/share/misc/map3270 # 20050801: too old to be interesting here OLD_FILES+=usr/share/doc/papers/px.ps.gz # 20050721: moved to ports OLD_FILES+=usr/sbin/vttest OLD_FILES+=usr/share/man/man1/vttest.1.gz # 20050617: wpa man pages moved to section 8 OLD_FILES+=usr/share/man/man1/hostapd.1.gz OLD_FILES+=usr/share/man/man1/hostapd_cli.1.gz OLD_FILES+=usr/share/man/man1/wpa_cli.1.gz OLD_FILES+=usr/share/man/man1/wpa_supplicant.1.gz # 20050610: rexecd (insecure by design) OLD_FILES+=etc/pam.d/rexecd OLD_FILES+=usr/share/man/man8/rexecd.8.gz OLD_FILES+=usr/libexec/rexecd # 20050606: OpenBSD dhclient replaces ISC one OLD_FILES+=bin/omshell OLD_FILES+=sbin/omshell OLD_FILES+=usr/share/man/man1/omshell.1.gz OLD_FILES+=usr/share/man/man5/dhcp-eval.5.gz # 200504XX: ipf tools moved from /usr to / OLD_FILES+=rescue/ipfs OLD_FILES+=rescue/ipfstat OLD_FILES+=rescue/ipmon OLD_FILES+=rescue/ipnat OLD_FILES+=usr/sbin/ipftest OLD_FILES+=usr/sbin/ipresend OLD_FILES+=usr/sbin/ipsend OLD_FILES+=usr/sbin/iptest OLD_FILES+=usr/share/man/man1/ipnat.1.gz OLD_FILES+=usr/share/man/man1/ipsend.1.gz OLD_FILES+=usr/share/man/man1/iptest.1.gz OLD_FILES+=usr/share/man/man5/ipsend.5.gz # 200503XX: bsdtar takes over gtar OLD_FILES+=usr/bin/gtar OLD_FILES+=usr/share/man/man1/gtar.1.gz # 200503XX OLD_FILES+=usr/share/man/man3/exp10.3.gz OLD_FILES+=usr/share/man/man3/exp10f.3.gz OLD_FILES+=usr/share/man/man3/fpsetsticky.3.gz # 20050324: updated release infrastructure OLD_FILES+=usr/share/man/man5/drivers.conf.5.gz # 20050317: removed from BIND 9 distribution OLD_FILES+=usr/share/doc/bind9/KNOWN_DEFECTS # 2005XXXX: OLD_FILES+=sbin/mount_autofs OLD_FILES+=usr/lib/libautofs.a OLD_FILES+=usr/lib/libautofs.so OLD_FILES+=usr/share/man/man8/mount_autofs.8.gz # 20050203: Merged with fortunes OLD_FILES+=usr/share/games/fortune/fortunes2 OLD_FILES+=usr/share/games/fortune/fortunes2.dat # 200501XX: OLD_FILES+=usr/libexec/getNAME # 200411XX: gvinum replaces vinum OLD_FILES+=bin/vinum OLD_FILES+=rescue/vinum OLD_FILES+=sbin/vinum OLD_FILES+=usr/share/man/man8/vinum.8.gz # 200411XX: libxpg4 removal OLD_FILES+=usr/lib/libxpg4.a OLD_FILES+=usr/lib/libxpg4.so OLD_FILES+=usr/lib/libxpg4_p.a # 20041109: replaced by em(4) OLD_FILES+=usr/share/man/man4/gx.4.gz OLD_FILES+=usr/share/man/man4/if_gx.4.gz # 20041017: rune interface removed OLD_FILES+=usr/include/rune.h OLD_FILES+=usr/share/man/man3/fgetrune.3.gz OLD_FILES+=usr/share/man/man3/fputrune.3.gz OLD_FILES+=usr/share/man/man3/fungetrune.3.gz OLD_FILES+=usr/share/man/man3/mbrrune.3.gz OLD_FILES+=usr/share/man/man3/mbrune.3.gz OLD_FILES+=usr/share/man/man3/rune.3.gz OLD_FILES+=usr/share/man/man3/setinvalidrune.3.gz OLD_FILES+=usr/share/man/man3/sgetrune.3.gz OLD_FILES+=usr/share/man/man3/sputrune.3.gz # 20040925: bind9 import OLD_FILES+=usr/bin/dnskeygen OLD_FILES+=usr/bin/dnsquery OLD_FILES+=usr/lib/libisc.a OLD_FILES+=usr/lib/libisc.so OLD_FILES+=usr/lib/libisc_p.a OLD_FILES+=usr/libexec/named-xfer OLD_FILES+=usr/sbin/named.restart OLD_FILES+=usr/sbin/ndc OLD_FILES+=usr/sbin/nslookup OLD_FILES+=usr/sbin/nsupdate OLD_FILES+=usr/share/doc/bind/html/acl.html OLD_FILES+=usr/share/doc/bind/html/address_list.html OLD_FILES+=usr/share/doc/bind/html/comments.html OLD_FILES+=usr/share/doc/bind/html/config.html OLD_FILES+=usr/share/doc/bind/html/controls.html OLD_FILES+=usr/share/doc/bind/html/docdef.html OLD_FILES+=usr/share/doc/bind/html/example.html OLD_FILES+=usr/share/doc/bind/html/include.html OLD_FILES+=usr/share/doc/bind/html/index.html OLD_FILES+=usr/share/doc/bind/html/key.html OLD_FILES+=usr/share/doc/bind/html/logging.html OLD_FILES+=usr/share/doc/bind/html/master.html OLD_FILES+=usr/share/doc/bind/html/options.html OLD_FILES+=usr/share/doc/bind/html/server.html OLD_FILES+=usr/share/doc/bind/html/trusted-keys.html OLD_FILES+=usr/share/doc/bind/html/zone.html OLD_FILES+=usr/share/doc/bind/misc/DynamicUpdate OLD_FILES+=usr/share/doc/bind/misc/FAQ.1of2 OLD_FILES+=usr/share/doc/bind/misc/FAQ.2of2 OLD_FILES+=usr/share/doc/bind/misc/rfc2317-notes.txt OLD_FILES+=usr/share/doc/bind/misc/style.txt OLD_FILES+=usr/share/man/man1/dnskeygen.1.gz OLD_FILES+=usr/share/man/man1/dnsquery.1.gz OLD_FILES+=usr/share/man/man8/named-bootconf.8.gz OLD_FILES+=usr/share/man/man8/named-xfer.8.gz OLD_FILES+=usr/share/man/man8/named.restart.8.gz OLD_FILES+=usr/share/man/man8/ndc.8.gz OLD_FILES+=usr/share/man/man8/nslookup.8.gz # 200409XX OLD_FILES+=usr/share/man/man3/ENSURE.3.gz OLD_FILES+=usr/share/man/man3/ENSURE_ERR.3.gz OLD_FILES+=usr/share/man/man3/INSIST.3.gz OLD_FILES+=usr/share/man/man3/INSIST_ERR.3.gz OLD_FILES+=usr/share/man/man3/INVARIANT.3.gz OLD_FILES+=usr/share/man/man3/INVARIANT_ERR.3.gz OLD_FILES+=usr/share/man/man3/REQUIRE.3.gz OLD_FILES+=usr/share/man/man3/REQUIRE_ERR.3.gz OLD_FILES+=usr/share/man/man3/assertion_type_to_text.3.gz OLD_FILES+=usr/share/man/man3/assertions.3.gz OLD_FILES+=usr/share/man/man3/bitncmp.3.gz OLD_FILES+=usr/share/man/man3/evAddTime.3.gz OLD_FILES+=usr/share/man/man3/evCancelConn.3.gz OLD_FILES+=usr/share/man/man3/evCancelRW.3.gz OLD_FILES+=usr/share/man/man3/evClearIdleTimer.3.gz OLD_FILES+=usr/share/man/man3/evClearTimer.3.gz OLD_FILES+=usr/share/man/man3/evCmpTime.3.gz OLD_FILES+=usr/share/man/man3/evConnFunc.3.gz OLD_FILES+=usr/share/man/man3/evConnect.3.gz OLD_FILES+=usr/share/man/man3/evConsIovec.3.gz OLD_FILES+=usr/share/man/man3/evConsTime.3.gz OLD_FILES+=usr/share/man/man3/evCreate.3.gz OLD_FILES+=usr/share/man/man3/evDefer.3.gz OLD_FILES+=usr/share/man/man3/evDeselectFD.3.gz OLD_FILES+=usr/share/man/man3/evDestroy.3.gz OLD_FILES+=usr/share/man/man3/evDispatch.3.gz OLD_FILES+=usr/share/man/man3/evDo.3.gz OLD_FILES+=usr/share/man/man3/evDrop.3.gz OLD_FILES+=usr/share/man/man3/evFileFunc.3.gz OLD_FILES+=usr/share/man/man3/evGetNext.3.gz OLD_FILES+=usr/share/man/man3/evHold.3.gz OLD_FILES+=usr/share/man/man3/evInitID.3.gz OLD_FILES+=usr/share/man/man3/evLastEventTime.3.gz OLD_FILES+=usr/share/man/man3/evListen.3.gz OLD_FILES+=usr/share/man/man3/evMainLoop.3.gz OLD_FILES+=usr/share/man/man3/evNowTime.3.gz OLD_FILES+=usr/share/man/man3/evPrintf.3.gz OLD_FILES+=usr/share/man/man3/evRead.3.gz OLD_FILES+=usr/share/man/man3/evResetTimer.3.gz OLD_FILES+=usr/share/man/man3/evSelectFD.3.gz OLD_FILES+=usr/share/man/man3/evSetDebug.3.gz OLD_FILES+=usr/share/man/man3/evSetIdleTimer.3.gz OLD_FILES+=usr/share/man/man3/evSetTimer.3.gz OLD_FILES+=usr/share/man/man3/evStreamFunc.3.gz OLD_FILES+=usr/share/man/man3/evSubTime.3.gz OLD_FILES+=usr/share/man/man3/evTestID.3.gz OLD_FILES+=usr/share/man/man3/evTimeRW.3.gz OLD_FILES+=usr/share/man/man3/evTimeSpec.3.gz OLD_FILES+=usr/share/man/man3/evTimeVal.3.gz OLD_FILES+=usr/share/man/man3/evTimerFunc.3.gz OLD_FILES+=usr/share/man/man3/evTouchIdleTimer.3.gz OLD_FILES+=usr/share/man/man3/evTryAccept.3.gz OLD_FILES+=usr/share/man/man3/evUnhold.3.gz OLD_FILES+=usr/share/man/man3/evUntimeRW.3.gz OLD_FILES+=usr/share/man/man3/evUnwait.3.gz OLD_FILES+=usr/share/man/man3/evWaitFor.3.gz OLD_FILES+=usr/share/man/man3/evWaitFunc.3.gz OLD_FILES+=usr/share/man/man3/evWrite.3.gz OLD_FILES+=usr/share/man/man3/eventlib.3.gz OLD_FILES+=usr/share/man/man3/heap.3.gz OLD_FILES+=usr/share/man/man3/heap_decreased.3.gz OLD_FILES+=usr/share/man/man3/heap_delete.3.gz OLD_FILES+=usr/share/man/man3/heap_element.3.gz OLD_FILES+=usr/share/man/man3/heap_for_each.3.gz OLD_FILES+=usr/share/man/man3/heap_free.3.gz OLD_FILES+=usr/share/man/man3/heap_increased.3.gz OLD_FILES+=usr/share/man/man3/heap_insert.3.gz OLD_FILES+=usr/share/man/man3/heap_new.3.gz OLD_FILES+=usr/share/man/man3/log_add_channel.3.gz OLD_FILES+=usr/share/man/man3/log_category_is_active.3.gz OLD_FILES+=usr/share/man/man3/log_close_stream.3.gz OLD_FILES+=usr/share/man/man3/log_dec_references.3.gz OLD_FILES+=usr/share/man/man3/log_free_channel.3.gz OLD_FILES+=usr/share/man/man3/log_free_context.3.gz OLD_FILES+=usr/share/man/man3/log_get_filename.3.gz OLD_FILES+=usr/share/man/man3/log_get_stream.3.gz OLD_FILES+=usr/share/man/man3/log_inc_references.3.gz OLD_FILES+=usr/share/man/man3/log_new_context.3.gz OLD_FILES+=usr/share/man/man3/log_new_file_channel.3.gz OLD_FILES+=usr/share/man/man3/log_new_null_channel.3.gz OLD_FILES+=usr/share/man/man3/log_new_syslog_channel.3.gz OLD_FILES+=usr/share/man/man3/log_open_stream.3.gz OLD_FILES+=usr/share/man/man3/log_option.3.gz OLD_FILES+=usr/share/man/man3/log_remove_channel.3.gz OLD_FILES+=usr/share/man/man3/log_set_file_owner.3.gz OLD_FILES+=usr/share/man/man3/log_vwrite.3.gz OLD_FILES+=usr/share/man/man3/log_write.3.gz OLD_FILES+=usr/share/man/man3/logging.3.gz OLD_FILES+=usr/share/man/man3/memcluster.3.gz OLD_FILES+=usr/share/man/man3/memget.3.gz OLD_FILES+=usr/share/man/man3/memput.3.gz OLD_FILES+=usr/share/man/man3/memstats.3.gz OLD_FILES+=usr/share/man/man3/set_assertion_failure_callback.3. OLD_FILES+=usr/share/man/man3/sigwait.3.gz OLD_FILES+=usr/share/man/man3/tree_add.3.gz OLD_FILES+=usr/share/man/man3/tree_delete.3.gz OLD_FILES+=usr/share/man/man3/tree_init.3.gz OLD_FILES+=usr/share/man/man3/tree_mung.3.gz OLD_FILES+=usr/share/man/man3/tree_srch.3.gz OLD_FILES+=usr/share/man/man3/tree_trav.3.gz # 2004XXYY: OS internal libs, no ports use them, no need to use OLD_LIBS OLD_FILES+=lib/geom/geom_concat.so.1 OLD_FILES+=lib/geom/geom_label.so.1 OLD_FILES+=lib/geom/geom_nop.so.1 OLD_FILES+=lib/geom/geom_stripe.so.1 # 20040728: GCC 3.4.2 OLD_DIRS+=usr/include/c++/3.3 OLD_FILES+=usr/include/c++/3.3/FlexLexer.h OLD_FILES+=usr/include/c++/3.3/algorithm OLD_FILES+=usr/include/c++/3.3/backward/algo.h OLD_FILES+=usr/include/c++/3.3/backward/algobase.h OLD_FILES+=usr/include/c++/3.3/backward/alloc.h OLD_FILES+=usr/include/c++/3.3/backward/backward_warning.h OLD_FILES+=usr/include/c++/3.3/backward/bvector.h OLD_FILES+=usr/include/c++/3.3/backward/complex.h OLD_FILES+=usr/include/c++/3.3/backward/defalloc.h OLD_FILES+=usr/include/c++/3.3/backward/deque.h OLD_FILES+=usr/include/c++/3.3/backward/fstream.h OLD_FILES+=usr/include/c++/3.3/backward/function.h OLD_FILES+=usr/include/c++/3.3/backward/hash_map.h OLD_FILES+=usr/include/c++/3.3/backward/hash_set.h OLD_FILES+=usr/include/c++/3.3/backward/hashtable.h OLD_FILES+=usr/include/c++/3.3/backward/heap.h OLD_FILES+=usr/include/c++/3.3/backward/iomanip.h OLD_FILES+=usr/include/c++/3.3/backward/iostream.h OLD_FILES+=usr/include/c++/3.3/backward/istream.h OLD_FILES+=usr/include/c++/3.3/backward/iterator.h OLD_FILES+=usr/include/c++/3.3/backward/list.h OLD_FILES+=usr/include/c++/3.3/backward/map.h OLD_FILES+=usr/include/c++/3.3/backward/multimap.h OLD_FILES+=usr/include/c++/3.3/backward/multiset.h OLD_FILES+=usr/include/c++/3.3/backward/new.h OLD_FILES+=usr/include/c++/3.3/backward/ostream.h OLD_FILES+=usr/include/c++/3.3/backward/pair.h OLD_FILES+=usr/include/c++/3.3/backward/queue.h OLD_FILES+=usr/include/c++/3.3/backward/rope.h OLD_FILES+=usr/include/c++/3.3/backward/set.h OLD_FILES+=usr/include/c++/3.3/backward/slist.h OLD_FILES+=usr/include/c++/3.3/backward/stack.h OLD_FILES+=usr/include/c++/3.3/backward/stream.h OLD_FILES+=usr/include/c++/3.3/backward/streambuf.h OLD_FILES+=usr/include/c++/3.3/backward/strstream OLD_FILES+=usr/include/c++/3.3/backward/strstream.h OLD_FILES+=usr/include/c++/3.3/backward/tempbuf.h OLD_FILES+=usr/include/c++/3.3/backward/tree.h OLD_FILES+=usr/include/c++/3.3/backward/vector.h OLD_DIRS+=usr/include/c++/3.3/backward OLD_FILES+=usr/include/c++/3.3/bits/atomicity.h OLD_FILES+=usr/include/c++/3.3/bits/basic_file.h OLD_FILES+=usr/include/c++/3.3/bits/basic_ios.h OLD_FILES+=usr/include/c++/3.3/bits/basic_ios.tcc OLD_FILES+=usr/include/c++/3.3/bits/basic_string.h OLD_FILES+=usr/include/c++/3.3/bits/basic_string.tcc OLD_FILES+=usr/include/c++/3.3/bits/boost_concept_check.h OLD_FILES+=usr/include/c++/3.3/bits/c++config.h OLD_FILES+=usr/include/c++/3.3/bits/c++io.h OLD_FILES+=usr/include/c++/3.3/bits/c++locale.h OLD_FILES+=usr/include/c++/3.3/bits/c++locale_internal.h OLD_FILES+=usr/include/c++/3.3/bits/char_traits.h OLD_FILES+=usr/include/c++/3.3/bits/cmath.tcc OLD_FILES+=usr/include/c++/3.3/bits/codecvt.h OLD_FILES+=usr/include/c++/3.3/bits/codecvt_specializations.h OLD_FILES+=usr/include/c++/3.3/bits/concept_check.h OLD_FILES+=usr/include/c++/3.3/bits/cpp_type_traits.h OLD_FILES+=usr/include/c++/3.3/bits/ctype_base.h OLD_FILES+=usr/include/c++/3.3/bits/ctype_inline.h OLD_FILES+=usr/include/c++/3.3/bits/ctype_noninline.h OLD_FILES+=usr/include/c++/3.3/bits/deque.tcc OLD_FILES+=usr/include/c++/3.3/bits/fpos.h OLD_FILES+=usr/include/c++/3.3/bits/fstream.tcc OLD_FILES+=usr/include/c++/3.3/bits/functexcept.h OLD_FILES+=usr/include/c++/3.3/bits/generic_shadow.h OLD_FILES+=usr/include/c++/3.3/bits/gslice.h OLD_FILES+=usr/include/c++/3.3/bits/gslice_array.h OLD_FILES+=usr/include/c++/3.3/bits/gthr-default.h OLD_FILES+=usr/include/c++/3.3/bits/gthr-posix.h OLD_FILES+=usr/include/c++/3.3/bits/gthr-single.h OLD_FILES+=usr/include/c++/3.3/bits/gthr.h OLD_FILES+=usr/include/c++/3.3/bits/indirect_array.h OLD_FILES+=usr/include/c++/3.3/bits/ios_base.h OLD_FILES+=usr/include/c++/3.3/bits/istream.tcc OLD_FILES+=usr/include/c++/3.3/bits/list.tcc OLD_FILES+=usr/include/c++/3.3/bits/locale_classes.h OLD_FILES+=usr/include/c++/3.3/bits/locale_facets.h OLD_FILES+=usr/include/c++/3.3/bits/locale_facets.tcc OLD_FILES+=usr/include/c++/3.3/bits/localefwd.h OLD_FILES+=usr/include/c++/3.3/bits/mask_array.h OLD_FILES+=usr/include/c++/3.3/bits/messages_members.h OLD_FILES+=usr/include/c++/3.3/bits/os_defines.h OLD_FILES+=usr/include/c++/3.3/bits/ostream.tcc OLD_FILES+=usr/include/c++/3.3/bits/pthread_allocimpl.h OLD_FILES+=usr/include/c++/3.3/bits/slice.h OLD_FILES+=usr/include/c++/3.3/bits/slice_array.h OLD_FILES+=usr/include/c++/3.3/bits/sstream.tcc OLD_FILES+=usr/include/c++/3.3/bits/stl_algo.h OLD_FILES+=usr/include/c++/3.3/bits/stl_algobase.h OLD_FILES+=usr/include/c++/3.3/bits/stl_alloc.h OLD_FILES+=usr/include/c++/3.3/bits/stl_bvector.h OLD_FILES+=usr/include/c++/3.3/bits/stl_construct.h OLD_FILES+=usr/include/c++/3.3/bits/stl_deque.h OLD_FILES+=usr/include/c++/3.3/bits/stl_function.h OLD_FILES+=usr/include/c++/3.3/bits/stl_heap.h OLD_FILES+=usr/include/c++/3.3/bits/stl_iterator.h OLD_FILES+=usr/include/c++/3.3/bits/stl_iterator_base_funcs.h OLD_FILES+=usr/include/c++/3.3/bits/stl_iterator_base_types.h OLD_FILES+=usr/include/c++/3.3/bits/stl_list.h OLD_FILES+=usr/include/c++/3.3/bits/stl_map.h OLD_FILES+=usr/include/c++/3.3/bits/stl_multimap.h OLD_FILES+=usr/include/c++/3.3/bits/stl_multiset.h OLD_FILES+=usr/include/c++/3.3/bits/stl_numeric.h OLD_FILES+=usr/include/c++/3.3/bits/stl_pair.h OLD_FILES+=usr/include/c++/3.3/bits/stl_pthread_alloc.h OLD_FILES+=usr/include/c++/3.3/bits/stl_queue.h OLD_FILES+=usr/include/c++/3.3/bits/stl_raw_storage_iter.h OLD_FILES+=usr/include/c++/3.3/bits/stl_relops.h OLD_FILES+=usr/include/c++/3.3/bits/stl_set.h OLD_FILES+=usr/include/c++/3.3/bits/stl_stack.h OLD_FILES+=usr/include/c++/3.3/bits/stl_tempbuf.h OLD_FILES+=usr/include/c++/3.3/bits/stl_threads.h OLD_FILES+=usr/include/c++/3.3/bits/stl_tree.h OLD_FILES+=usr/include/c++/3.3/bits/stl_uninitialized.h OLD_FILES+=usr/include/c++/3.3/bits/stl_vector.h OLD_FILES+=usr/include/c++/3.3/bits/stream_iterator.h OLD_FILES+=usr/include/c++/3.3/bits/streambuf.tcc OLD_FILES+=usr/include/c++/3.3/bits/streambuf_iterator.h OLD_FILES+=usr/include/c++/3.3/bits/stringfwd.h OLD_FILES+=usr/include/c++/3.3/bits/time_members.h OLD_FILES+=usr/include/c++/3.3/bits/type_traits.h OLD_FILES+=usr/include/c++/3.3/bits/valarray_array.h OLD_FILES+=usr/include/c++/3.3/bits/valarray_array.tcc OLD_FILES+=usr/include/c++/3.3/bits/valarray_meta.h OLD_FILES+=usr/include/c++/3.3/bits/vector.tcc OLD_DIRS+=usr/include/c++/3.3/bits OLD_FILES+=usr/include/c++/3.3/bitset OLD_FILES+=usr/include/c++/3.3/cassert OLD_FILES+=usr/include/c++/3.3/cctype OLD_FILES+=usr/include/c++/3.3/cerrno OLD_FILES+=usr/include/c++/3.3/cfloat OLD_FILES+=usr/include/c++/3.3/ciso646 OLD_FILES+=usr/include/c++/3.3/climits OLD_FILES+=usr/include/c++/3.3/clocale OLD_FILES+=usr/include/c++/3.3/cmath OLD_FILES+=usr/include/c++/3.3/complex OLD_FILES+=usr/include/c++/3.3/csetjmp OLD_FILES+=usr/include/c++/3.3/csignal OLD_FILES+=usr/include/c++/3.3/cstdarg OLD_FILES+=usr/include/c++/3.3/cstddef OLD_FILES+=usr/include/c++/3.3/cstdio OLD_FILES+=usr/include/c++/3.3/cstdlib OLD_FILES+=usr/include/c++/3.3/cstring OLD_FILES+=usr/include/c++/3.3/ctime OLD_FILES+=usr/include/c++/3.3/cwchar OLD_FILES+=usr/include/c++/3.3/cwctype OLD_FILES+=usr/include/c++/3.3/cxxabi.h OLD_FILES+=usr/include/c++/3.3/deque OLD_FILES+=usr/include/c++/3.3/exception OLD_FILES+=usr/include/c++/3.3/exception_defines.h OLD_FILES+=usr/include/c++/3.3/ext/algorithm OLD_FILES+=usr/include/c++/3.3/ext/enc_filebuf.h OLD_FILES+=usr/include/c++/3.3/ext/functional OLD_FILES+=usr/include/c++/3.3/ext/hash_map OLD_FILES+=usr/include/c++/3.3/ext/hash_set OLD_FILES+=usr/include/c++/3.3/ext/iterator OLD_FILES+=usr/include/c++/3.3/ext/memory OLD_FILES+=usr/include/c++/3.3/ext/numeric OLD_FILES+=usr/include/c++/3.3/ext/rb_tree OLD_FILES+=usr/include/c++/3.3/ext/rope OLD_FILES+=usr/include/c++/3.3/ext/ropeimpl.h OLD_FILES+=usr/include/c++/3.3/ext/slist OLD_FILES+=usr/include/c++/3.3/ext/stdio_filebuf.h OLD_FILES+=usr/include/c++/3.3/ext/stl_hash_fun.h OLD_FILES+=usr/include/c++/3.3/ext/stl_hashtable.h OLD_FILES+=usr/include/c++/3.3/ext/stl_rope.h OLD_DIRS+=usr/include/c++/3.3/ext OLD_FILES+=usr/include/c++/3.3/fstream OLD_FILES+=usr/include/c++/3.3/functional OLD_FILES+=usr/include/c++/3.3/iomanip OLD_FILES+=usr/include/c++/3.3/ios OLD_FILES+=usr/include/c++/3.3/iosfwd OLD_FILES+=usr/include/c++/3.3/iostream OLD_FILES+=usr/include/c++/3.3/istream OLD_FILES+=usr/include/c++/3.3/iterator OLD_FILES+=usr/include/c++/3.3/limits OLD_FILES+=usr/include/c++/3.3/list OLD_FILES+=usr/include/c++/3.3/locale OLD_FILES+=usr/include/c++/3.3/map OLD_FILES+=usr/include/c++/3.3/memory OLD_FILES+=usr/include/c++/3.3/new OLD_FILES+=usr/include/c++/3.3/numeric OLD_FILES+=usr/include/c++/3.3/ostream OLD_FILES+=usr/include/c++/3.3/queue OLD_FILES+=usr/include/c++/3.3/set OLD_FILES+=usr/include/c++/3.3/sstream OLD_FILES+=usr/include/c++/3.3/stack OLD_FILES+=usr/include/c++/3.3/stdexcept OLD_FILES+=usr/include/c++/3.3/streambuf OLD_FILES+=usr/include/c++/3.3/string OLD_FILES+=usr/include/c++/3.3/typeinfo OLD_FILES+=usr/include/c++/3.3/utility OLD_FILES+=usr/include/c++/3.3/valarray OLD_FILES+=usr/include/c++/3.3/vector # 20040713: fla(4) removed. OLD_FILES+=usr/share/man/man4/fla.4.gz # 200407XX OLD_FILES+=usr/sbin/kernbb OLD_FILES+=usr/sbin/ntp-genkeys OLD_FILES+=usr/sbin/ntptimeset OLD_FILES+=usr/share/man/man8/kernbb.8.gz OLD_FILES+=usr/share/man/man8/ntp-genkeys.8.gz # 20040627: usbdevs.h and usbdevs_data.h removal OLD_FILES+=usr/include/dev/usb/usbdevs.h OLD_FILES+=usr/include/dev/usb/usbdevs_data.h # 200406XX OLD_FILES+=usr/bin/gasp OLD_FILES+=usr/bin/gdbreplay OLD_FILES+=usr/share/man/man1/gasp.1.gz OLD_FILES+=sbin/mountd OLD_FILES+=sbin/mount_fdesc OLD_FILES+=sbin/mount_umap OLD_FILES+=sbin/mount_union OLD_FILES+=sbin/mount_msdos OLD_FILES+=sbin/mount_null OLD_FILES+=sbin/mount_kernfs # 200405XX: arl OLD_FILES+=usr/sbin/arlconfig OLD_FILES+=usr/share/man/man8/arlconfig.8.gz # 200403XX OLD_FILES+=bin/raidctl OLD_FILES+=sbin/raidctl OLD_FILES+=usr/bin/sasc OLD_FILES+=usr/sbin/sgsc OLD_FILES+=usr/sbin/stlload OLD_FILES+=usr/sbin/stlstats OLD_FILES+=usr/share/man/man1/sasc.1.gz OLD_FILES+=usr/share/man/man1/sgsc.1.gz OLD_FILES+=usr/share/man/man4/i386/stl.4.gz OLD_FILES+=usr/share/man/man8/raidctl.8.gz # 20040229: clean_environment() was removed after 3 days OLD_FILES+=usr/share/man/man3/clean_environment.3.gz # 20040119: installed as `isdntel' in newer systems OLD_FILES+=etc/isdn/isdntel.sh # 200XYYZZ: /lib transition clitches OLD_FILES+=lib/libalias.so OLD_FILES+=lib/libatm.so OLD_FILES+=lib/libbsdxml.so OLD_FILES+=lib/libc.so OLD_FILES+=lib/libcam.so OLD_FILES+=lib/libcrypt.so OLD_FILES+=lib/libcrypto.so OLD_FILES+=lib/libdevstat.so OLD_FILES+=lib/libedit.so OLD_FILES+=lib/libgeom.so OLD_FILES+=lib/libipsec.so OLD_FILES+=lib/libipx.so OLD_FILES+=lib/libkvm.so OLD_FILES+=lib/libm.so OLD_FILES+=lib/libmd.so OLD_FILES+=lib/libncurses.so OLD_FILES+=lib/libreadline.so OLD_FILES+=lib/libsbuf.so OLD_FILES+=lib/libufs.so OLD_FILES+=lib/libz.so # 200312XX OLD_FILES+=bin/cxconfig OLD_FILES+=sbin/cxconfig OLD_FILES+=usr/share/man/man8/cxconfig.8.gz # 20031016: MULTI_DRIVER_MODULE macro removed OLD_FILES+=usr/share/man/man9/MULTI_DRIVER_MODULE.9.gz # 200309XX OLD_FILES+=usr/bin/symorder OLD_FILES+=usr/share/man/man1/symorder.1.gz # 200308XX OLD_FILES+=usr/sbin/amldb OLD_FILES+=usr/share/man/man8/amldb.8.gz # 200307XX OLD_FILES+=sbin/mount_nwfs OLD_FILES+=sbin/mount_portalfs OLD_FILES+=sbin/mount_smbfs # 200306XX OLD_FILES+=usr/sbin/dev_mkdb OLD_FILES+=usr/share/man/man8/dev_mkdb.8.gz # 200304XX OLD_FILES+=usr/lib/libcipher.a OLD_FILES+=usr/lib/libcipher.so OLD_FILES+=usr/lib/libcipher_p.a OLD_FILES+=usr/lib/libgmp.a OLD_FILES+=usr/lib/libgmp.so OLD_FILES+=usr/lib/libgmp_p.a OLD_FILES+=usr/lib/libperl.a OLD_FILES+=usr/lib/libperl.so OLD_FILES+=usr/lib/libperl_p.a OLD_FILES+=usr/lib/libposix1e.a OLD_FILES+=usr/lib/libposix1e.so OLD_FILES+=usr/lib/libposix1e_p.a OLD_FILES+=usr/lib/libskey.a OLD_FILES+=usr/lib/libskey.so OLD_FILES+=usr/lib/libskey_p.a OLD_FILES+=usr/libexec/tradcpp0 OLD_FILES+=usr/libexec/cpp0 # 200304XX: removal of xten OLD_FILES+=usr/libexec/xtend OLD_FILES+=usr/sbin/xten OLD_FILES+=usr/share/man/man1/xten.1.gz OLD_FILES+=usr/share/man/man8/xtend.8.gz # 200303XX OLD_FILES+=usr/lib/libacl.so OLD_FILES+=usr/lib/libdescrypt.so OLD_FILES+=usr/lib/libf2c.so OLD_FILES+=usr/lib/libg++.so OLD_FILES+=usr/lib/libkdb.so OLD_FILES+=usr/lib/librsaINTL.so OLD_FILES+=usr/lib/libscrypt.so OLD_FILES+=usr/lib/libss.so # 200302XX OLD_FILES+=usr/lib/libacl.a OLD_FILES+=usr/lib/libacl_p.a OLD_FILES+=usr/lib/libkadm.a OLD_FILES+=usr/lib/libkadm.so OLD_FILES+=usr/lib/libkadm_p.a OLD_FILES+=usr/lib/libkafs.a OLD_FILES+=usr/lib/libkafs.so OLD_FILES+=usr/lib/libkafs_p.a OLD_FILES+=usr/lib/libkdb.a OLD_FILES+=usr/lib/libkdb_p.a OLD_FILES+=usr/lib/libkrb.a OLD_FILES+=usr/lib/libkrb.so OLD_FILES+=usr/lib/libkrb_p.a OLD_FILES+=usr/share/man/man3/SSL_CIPHER_get_name.3.gz OLD_FILES+=usr/share/man/man3/SSL_COMP_add_compression_method.3 OLD_FILES+=usr/share/man/man3/SSL_CTX_add_extra_chain_cert.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_add_session.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_ctrl.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_flush_sessions.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_free.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_get_verify_mode.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_load_verify_locations.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_new.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_sess_number.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_sess_set_cache_size.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_sess_set_get_cb.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_sessions.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_cert_store.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_cert_verify_callback.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_cipher_list.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_client_CA_list.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_client_cert_cb.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_default_passwd_cb.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_generate_session_id.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_info_callback.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_max_cert_list.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_mode.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_msg_callback.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_options.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_quiet_shutdown.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_session_cache_mode.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_session_id_context.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_ssl_version.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_timeout.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_tmp_dh_callback.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_tmp_rsa_callback.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_set_verify.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_use_certificate.3.gz OLD_FILES+=usr/share/man/man3/SSL_SESSION_free.3.gz OLD_FILES+=usr/share/man/man3/SSL_SESSION_get_ex_new_index.3.gz OLD_FILES+=usr/share/man/man3/SSL_SESSION_get_time.3.gz OLD_FILES+=usr/share/man/man3/SSL_accept.3.gz OLD_FILES+=usr/share/man/man3/SSL_alert_type_string.3.gz OLD_FILES+=usr/share/man/man3/SSL_clear.3.gz OLD_FILES+=usr/share/man/man3/SSL_connect.3.gz OLD_FILES+=usr/share/man/man3/SSL_do_handshake.3.gz OLD_FILES+=usr/share/man/man3/SSL_free.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_SSL_CTX.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_ciphers.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_client_CA_list.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_current_cipher.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_default_timeout.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_error.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_ex_data_X509_STORE_CTX_idx.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_ex_new_index.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_fd.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_peer_cert_chain.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_peer_certificate.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_rbio.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_session.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_verify_result.3.gz OLD_FILES+=usr/share/man/man3/SSL_get_version.3.gz OLD_FILES+=usr/share/man/man3/SSL_library_init.3.gz OLD_FILES+=usr/share/man/man3/SSL_load_client_CA_file.3.gz OLD_FILES+=usr/share/man/man3/SSL_new.3.gz OLD_FILES+=usr/share/man/man3/SSL_pending.3.gz OLD_FILES+=usr/share/man/man3/SSL_read.3.gz OLD_FILES+=usr/share/man/man3/SSL_rstate_string.3.gz OLD_FILES+=usr/share/man/man3/SSL_session_reused.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_bio.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_connect_state.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_fd.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_session.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_shutdown.3.gz OLD_FILES+=usr/share/man/man3/SSL_set_verify_result.3.gz OLD_FILES+=usr/share/man/man3/SSL_shutdown.3.gz OLD_FILES+=usr/share/man/man3/SSL_state_string.3.gz OLD_FILES+=usr/share/man/man3/SSL_want.3.gz OLD_FILES+=usr/share/man/man3/SSL_write.3.gz OLD_FILES+=usr/share/man/man3/d2i_SSL_SESSION.3.gz # 200301XX OLD_FILES+=usr/share/man/man3/des_3cbc_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_3ecb_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_cbc_cksum.3.gz OLD_FILES+=usr/share/man/man3/des_cbc_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_cfb_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_ecb_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_enc_read.3.gz OLD_FILES+=usr/share/man/man3/des_enc_write.3.gz OLD_FILES+=usr/share/man/man3/des_is_weak_key.3.gz OLD_FILES+=usr/share/man/man3/des_key_sched.3.gz OLD_FILES+=usr/share/man/man3/des_ofb_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_pcbc_encrypt.3.gz OLD_FILES+=usr/share/man/man3/des_quad_cksum.3.gz OLD_FILES+=usr/share/man/man3/des_random_key.3.gz OLD_FILES+=usr/share/man/man3/des_read_2password.3.gz OLD_FILES+=usr/share/man/man3/des_read_password.3.gz OLD_FILES+=usr/share/man/man3/des_read_pw_string.3.gz OLD_FILES+=usr/share/man/man3/des_set_key.3.gz OLD_FILES+=usr/share/man/man3/des_set_odd_parity.3.gz OLD_FILES+=usr/share/man/man3/des_string_to_2key.3.gz OLD_FILES+=usr/share/man/man3/des_string_to_key.3.gz # 200212XX OLD_FILES+=usr/sbin/kenv OLD_FILES+=usr/bin/kenv OLD_FILES+=usr/sbin/elf2aout # 200210XX OLD_FILES+=usr/include/libusbhid.h OLD_FILES+=usr/share/man/man3/All_FreeBSD.3.gz OLD_FILES+=usr/share/man/man3/CheckRules.3.gz OLD_FILES+=usr/share/man/man3/ChunkCanBeRoot.3.gz OLD_FILES+=usr/share/man/man3/Clone_Disk.3.gz OLD_FILES+=usr/share/man/man3/Collapse_Chunk.3.gz OLD_FILES+=usr/share/man/man3/Collapse_Disk.3.gz OLD_FILES+=usr/share/man/man3/Create_Chunk.3.gz OLD_FILES+=usr/share/man/man3/Create_Chunk_DWIM.3.gz OLD_FILES+=usr/share/man/man3/Cyl_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Debug_Disk.3.gz OLD_FILES+=usr/share/man/man3/Delete_Chunk.3.gz OLD_FILES+=usr/share/man/man3/Disk_Names.3.gz OLD_FILES+=usr/share/man/man3/Free_Disk.3.gz OLD_FILES+=usr/share/man/man3/MakeDev.3.gz OLD_FILES+=usr/share/man/man3/MakeDevDisk.3.gz OLD_FILES+=usr/share/man/man3/Next_Cyl_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Next_Track_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Open_Disk.3.gz OLD_FILES+=usr/share/man/man3/Prev_Cyl_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Prev_Track_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Set_Bios_Geom.3.gz OLD_FILES+=usr/share/man/man3/Set_Boot_Blocks.3.gz OLD_FILES+=usr/share/man/man3/Set_Boot_Mgr.3.gz OLD_FILES+=usr/share/man/man3/ShowChunkFlags.3.gz OLD_FILES+=usr/share/man/man3/Track_Aligned.3.gz OLD_FILES+=usr/share/man/man3/Write_Disk.3.gz OLD_FILES+=usr/share/man/man3/slice_type_name.3.gz # 200210XX: most games moved to ports OLD_FILES+=usr/share/man/man6/adventure.6.gz OLD_FILES+=usr/share/man/man6/arithmetic.6.gz OLD_FILES+=usr/share/man/man6/atc.6.gz OLD_FILES+=usr/share/man/man6/backgammon.6.gz OLD_FILES+=usr/share/man/man6/battlestar.6.gz OLD_FILES+=usr/share/man/man6/bs.6.gz OLD_FILES+=usr/share/man/man6/canfield.6.gz OLD_FILES+=usr/share/man/man6/cfscores.6.gz OLD_FILES+=usr/share/man/man6/cribbage.6.gz OLD_FILES+=usr/share/man/man6/fish.6.gz OLD_FILES+=usr/share/man/man6/hack.6.gz OLD_FILES+=usr/share/man/man6/hangman.6.gz OLD_FILES+=usr/share/man/man6/larn.6.gz OLD_FILES+=usr/share/man/man6/mille.6.gz OLD_FILES+=usr/share/man/man6/phantasia.6.gz OLD_FILES+=usr/share/man/man6/piano.6.gz OLD_FILES+=usr/share/man/man6/pig.6.gz OLD_FILES+=usr/share/man/man6/quiz.6.gz OLD_FILES+=usr/share/man/man6/rain.6.gz OLD_FILES+=usr/share/man/man6/robots.6.gz OLD_FILES+=usr/share/man/man6/rogue.6.gz OLD_FILES+=usr/share/man/man6/sail.6.gz OLD_FILES+=usr/share/man/man6/snake.6.gz OLD_FILES+=usr/share/man/man6/snscore.6.gz OLD_FILES+=usr/share/man/man6/trek.6.gz OLD_FILES+=usr/share/man/man6/wargames.6.gz OLD_FILES+=usr/share/man/man6/worm.6.gz OLD_FILES+=usr/share/man/man6/worms.6.gz OLD_FILES+=usr/share/man/man6/wump.6.gz # 200207XX OLD_FILES+=usr/share/man/man1aout/ar.1aout.gz OLD_FILES+=usr/share/man/man1aout/as.1aout.gz OLD_FILES+=usr/share/man/man1aout/ld.1aout.gz OLD_FILES+=usr/share/man/man1aout/nm.1aout.gz OLD_FILES+=usr/share/man/man1aout/ranlib.1aout.gz OLD_FILES+=usr/share/man/man1aout/size.1aout.gz OLD_FILES+=usr/share/man/man1aout/strings.1aout.gz OLD_FILES+=usr/share/man/man1aout/strip.1aout.gz OLD_FILES+=bin/mountd OLD_FILES+=bin/nfsd # 20020707 sbin/nfsd -> usr.sbin/nfsd OLD_FILES+=sbin/nfsd # 200206XX OLD_FILES+=usr/lib/libpam_ssh.a OLD_FILES+=usr/lib/libpam_ssh_p.a OLD_FILES+=usr/bin/help OLD_FILES+=usr/bin/sccs .if ${TARGET_ARCH} != "amd64" && ${TARGET} != "arm" && ${TARGET_ARCH} != "i386" && ${TARGET} != "powerpc" OLD_FILES+=usr/bin/gdbserver .endif OLD_FILES+=usr/bin/ssh-keysign OLD_FILES+=usr/sbin/gifconfig OLD_FILES+=usr/sbin/prefix # 200205XX OLD_FILES+=usr/bin/doscmd # 200204XX OLD_FILES+=usr/bin/a2p OLD_FILES+=usr/bin/ptx OLD_FILES+=usr/bin/pod2text OLD_FILES+=usr/bin/pod2man OLD_FILES+=usr/bin/pod2latex OLD_FILES+=usr/bin/pod2html OLD_FILES+=usr/bin/h2ph OLD_FILES+=usr/bin/dprofpp OLD_FILES+=usr/bin/c2ph OLD_FILES+=usr/bin/h2xs OLD_FILES+=usr/bin/pl2pm OLD_FILES+=usr/bin/splain OLD_FILES+=usr/bin/s2p OLD_FILES+=usr/bin/find2perl OLD_FILES+=usr/sbin/pkg_update OLD_FILES+=usr/sbin/scriptdump # 20020409 GC kget(1), userconfig is long dead. OLD_FILES+=sbin/kget OLD_FILES+=usr/share/man/man8/kget.8.gz # 200203XX OLD_FILES+=usr/lib/libss.a OLD_FILES+=usr/lib/libss_p.a OLD_FILES+=usr/lib/libtelnet.a OLD_FILES+=usr/lib/libtelnet_p.a OLD_FILES+=usr/sbin/diskpart # 200202XX OLD_FILES+=usr/bin/gprof4 # 200201XX OLD_FILES+=usr/sbin/linux # 2001XXXX OLD_FILES+=usr/bin/joy OLD_FILES+=usr/sbin/ibcs2 OLD_FILES+=usr/sbin/svr4 OLD_FILES+=usr/bin/chflags OLD_FILES+=usr/sbin/uuconv OLD_FILES+=usr/sbin/uuchk OLD_FILES+=usr/sbin/portmap OLD_FILES+=usr/sbin/pmap_set OLD_FILES+=usr/sbin/pmap_dump OLD_FILES+=usr/sbin/mcon OLD_FILES+=usr/sbin/stlstty OLD_FILES+=usr/sbin/ispppcontrol OLD_FILES+=usr/sbin/rndcontrol # 20011001: UUCP migration to ports OLD_FILES+=usr/bin/uucp OLD_FILES+=usr/bin/uulog OLD_FILES+=usr/bin/uuname OLD_FILES+=usr/bin/uupick OLD_FILES+=usr/bin/uusched OLD_FILES+=usr/bin/uustat OLD_FILES+=usr/bin/uuto OLD_FILES+=usr/bin/uux OLD_FILES+=usr/libexec/uucp/uucico OLD_FILES+=usr/libexec/uucp/uuxqt OLD_FILES+=usr/libexec/uucpd OLD_FILES+=usr/share/man/man1/uuconv.1.gz OLD_FILES+=usr/share/man/man1/uucp.1.gz OLD_FILES+=usr/share/man/man1/uulog.1.gz OLD_FILES+=usr/share/man/man1/uuname.1.gz OLD_FILES+=usr/share/man/man1/uupick.1.gz OLD_FILES+=usr/share/man/man1/uustat.1.gz OLD_FILES+=usr/share/man/man1/uuto.1.gz OLD_FILES+=usr/share/man/man1/uux.1.gz OLD_FILES+=usr/share/man/man8/uuchk.8.gz OLD_FILES+=usr/share/man/man8/uucico.8.gz OLD_FILES+=usr/share/man/man8/uucpd.8.gz OLD_FILES+=usr/share/man/man8/uusched.8.gz OLD_FILES+=usr/share/man/man8/uuxqt.8.gz # 20010523 mount_portal -> mount_portalfs OLD_FILES+=sbin/mount_portal OLD_FILES+=usr/share/man/man8/mount_portal.8.gz # 200104XX OLD_FILES+=usr/lib/libdescrypt.a OLD_FILES+=usr/lib/libscrypt.a OLD_FILES+=usr/lib/libscrypt_p.a OLD_FILES+=usr/sbin/pim6stat OLD_FILES+=usr/sbin/pim6sd OLD_FILES+=usr/sbin/pim6dd # 20010217 OLD_FILES+=usr/share/doc/bind/misc/dns-setup # 20001200 OLD_FILES+=usr/lib/libgcc_r_pic.a # 200009XX OLD_FILES+=usr/lib/libRSAglue.a OLD_FILES+=usr/lib/libRSAglue.so OLD_FILES+=usr/lib/librsaINTL.a OLD_FILES+=usr/lib/librsaUSA.a OLD_FILES+=usr/lib/librsaUSA.so # 200002XX ? OLD_FILES+=usr/lib/libf2c.a OLD_FILES+=usr/lib/libf2c_p.a OLD_FILES+=usr/lib/libg++.a OLD_FILES+=usr/lib/libg++_p.a # 20001006 OLD_FILES+=usr/bin/miniperl # 20000810 OLD_FILES+=usr/bin/sperl # 200001XX OLD_FILES+=usr/sbin/apmconf # 199911XX OLD_FILES+=usr/sbin/ipfstat OLD_FILES+=usr/sbin/ipmon OLD_FILES+=usr/sbin/ipnat OLD_FILES+=usr/sbin/bad144 OLD_FILES+=usr/sbin/wormcontrol OLD_FILES+=usr/sbin/named-bootconf OLD_FILES+=usr/sbin/kvm_mkdb OLD_FILES+=usr/sbin/keyadmin # 199909XX OLD_FILES+=usr/lib/libdesrypt_p.a OLD_FILES+=sbin/ft # 199903XX OLD_FILES+=sbin/modload OLD_FILES+=sbin/modunload OLD_FILES+=usr/sbin/natd # 199812XX OLD_FILES+=sbin/dset # 199809XX OLD_FILES+=sbin/scsi OLD_FILES+=sbin/scsiformat OLD_FILES+=usr/sbin/ncrcontrol OLD_FILES+=usr/sbin/tickadj # 199806XX OLD_FILES+=usr/sbin/mkdosfs # 199801XX OLD_FILES+=sbin/mount_lfs OLD_FILES+=sbin/newlfs OLD_FILES+=sbin/dumplfs OLD_FILES+=usr/sbin/qcamcontrol OLD_FILES+=usr/sbin/supscan # 1997XXXX OLD_FILES+=usr/sbin/sysctl OLD_FILES+=usr/sbin/ctm_scan OLD_FILES+=usr/sbin/addgroup OLD_FILES+=usr/sbin/rmgroup # 1996XXXX OLD_FILES+=sbin/rdisc OLD_FILES+=usr/sbin/cdplay OLD_FILES+=usr/sbin/supfilesrv OLD_FILES+=usr/sbin/routed OLD_FILES+=usr/sbin/lsdev OLD_FILES+=usr/sbin/yppasswdd ## unsorted # do we still support aout builds? #OLD_FILES+=usr/lib/aout/c++rt0.o #OLD_FILES+=usr/lib/aout/crt0.o #OLD_FILES+=usr/lib/aout/gcrt0.o #OLD_FILES+=usr/lib/aout/scrt0.o #OLD_FILES+=usr/lib/aout/sgcrt0.o OLD_FILES+=usr/bin/sperl5 OLD_FILES+=usr/bin/perl5.6.0 OLD_FILES+=usr/bin/sperl5.6.0 OLD_FILES+=usr/bin/perlbc OLD_FILES+=usr/bin/perl5.00503 OLD_FILES+=usr/bin/sperl5.00503 OLD_FILES+=usr/bin/perlbug OLD_FILES+=usr/bin/perlcc OLD_FILES+=usr/bin/perldoc OLD_FILES+=usr/bin/suidperl OLD_FILES+=usr/lib/pam_ftp.so OLD_FILES+=usr/libdata/perl/5.00503/CGI/Apache.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI/Carp.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI/Cookie.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI/Fast.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI/Push.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI/Switch.pm OLD_FILES+=usr/libdata/perl/5.00503/CPAN/FirstTime.pm OLD_FILES+=usr/libdata/perl/5.00503/CPAN/Nox.pm OLD_FILES+=usr/libdata/perl/5.00503/Class/Struct.pm OLD_FILES+=usr/libdata/perl/5.00503/Devel/SelfStubber.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Command.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Embed.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Install.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Installed.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Liblist.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/MM_OS2.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/MM_Unix.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/MM_VMS.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/MM_Win32.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/MakeMaker.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Manifest.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Mkbootstrap.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Mksymlists.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/Packlist.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/inst OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/testlib.pm OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/typemap OLD_FILES+=usr/libdata/perl/5.00503/ExtUtils/xsubpp OLD_FILES+=usr/libdata/perl/5.00503/File/Spec/Mac.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Spec/OS2.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Spec/Unix.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Spec/VMS.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Spec/Win32.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Basename.pm OLD_FILES+=usr/libdata/perl/5.00503/File/CheckTree.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Compare.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Copy.pm OLD_FILES+=usr/libdata/perl/5.00503/File/DosGlob.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Find.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Path.pm OLD_FILES+=usr/libdata/perl/5.00503/File/Spec.pm OLD_FILES+=usr/libdata/perl/5.00503/File/stat.pm OLD_FILES+=usr/libdata/perl/5.00503/Getopt/Long.pm OLD_FILES+=usr/libdata/perl/5.00503/Getopt/Std.pm OLD_FILES+=usr/libdata/perl/5.00503/I18N/Collate.pm OLD_FILES+=usr/libdata/perl/5.00503/IPC/Open2.pm OLD_FILES+=usr/libdata/perl/5.00503/IPC/Open3.pm OLD_FILES+=usr/libdata/perl/5.00503/Math/BigFloat.pm OLD_FILES+=usr/libdata/perl/5.00503/Math/BigInt.pm OLD_FILES+=usr/libdata/perl/5.00503/Math/Complex.pm OLD_FILES+=usr/libdata/perl/5.00503/Math/Trig.pm OLD_FILES+=usr/libdata/perl/5.00503/Net/Ping.pm OLD_FILES+=usr/libdata/perl/5.00503/Net/hostent.pm OLD_FILES+=usr/libdata/perl/5.00503/Net/netent.pm OLD_FILES+=usr/libdata/perl/5.00503/Net/protoent.pm OLD_FILES+=usr/libdata/perl/5.00503/Net/servent.pm OLD_FILES+=usr/libdata/perl/5.00503/Pod/Functions.pm OLD_FILES+=usr/libdata/perl/5.00503/Pod/Html.pm OLD_FILES+=usr/libdata/perl/5.00503/Pod/Text.pm OLD_FILES+=usr/libdata/perl/5.00503/Search/Dict.pm OLD_FILES+=usr/libdata/perl/5.00503/Sys/Hostname.pm OLD_FILES+=usr/libdata/perl/5.00503/Sys/Syslog.pm OLD_FILES+=usr/libdata/perl/5.00503/Term/Cap.pm OLD_FILES+=usr/libdata/perl/5.00503/Term/Complete.pm OLD_FILES+=usr/libdata/perl/5.00503/Term/ReadLine.pm OLD_FILES+=usr/libdata/perl/5.00503/Test/Harness.pm OLD_FILES+=usr/libdata/perl/5.00503/Text/Abbrev.pm OLD_FILES+=usr/libdata/perl/5.00503/Text/ParseWords.pm OLD_FILES+=usr/libdata/perl/5.00503/Text/Soundex.pm OLD_FILES+=usr/libdata/perl/5.00503/Text/Tabs.pm OLD_FILES+=usr/libdata/perl/5.00503/Text/Wrap.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/Array.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/Handle.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/Hash.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/RefHash.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/Scalar.pm OLD_FILES+=usr/libdata/perl/5.00503/Tie/SubstrHash.pm OLD_FILES+=usr/libdata/perl/5.00503/Time/Local.pm OLD_FILES+=usr/libdata/perl/5.00503/Time/gmtime.pm OLD_FILES+=usr/libdata/perl/5.00503/Time/localtime.pm OLD_FILES+=usr/libdata/perl/5.00503/Time/tm.pm OLD_FILES+=usr/libdata/perl/5.00503/User/grent.pm OLD_FILES+=usr/libdata/perl/5.00503/User/pwent.pm OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/GetOptions.al OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/FindOption.al OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/Configure.al OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/config.al OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/Croak.al OLD_FILES+=usr/libdata/perl/5.00503/auto/Getopt/Long/autosplit.ix OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Deparse.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/CC.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Debug.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Showlex.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/makeliblinks OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Bblock.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/cc_harness OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Bytecode.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Stackobj.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Xref.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Lint.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Asmdata.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Assembler.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Disassembler.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/disassemble OLD_FILES+=usr/libdata/perl/5.00503/mach/B/assemble OLD_FILES+=usr/libdata/perl/5.00503/mach/B/Terse.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B/C.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/EXTERN.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/INTERN.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/XSUB.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/XSlock.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/av.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/bytecode.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/byterun.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/cc_runtime.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/config.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/cop.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/cv.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/dosish.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/embed.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/embedvar.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/fakethr.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/form.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/gv.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/handy.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/hv.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/intrpvar.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/iperlsys.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/keywords.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/mg.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/nostdio.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/objXSUB.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/objpp.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/op.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/opcode.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/patchlevel.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perl.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perlio.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perlsdio.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perlsfio.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perlvars.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/perly.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/pp.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/pp_proto.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/proto.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/regcomp.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/regexp.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/regnodes.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/scope.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/sv.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/thrdvar.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/thread.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/unixish.h OLD_FILES+=usr/libdata/perl/5.00503/mach/CORE/util.h OLD_FILES+=usr/libdata/perl/5.00503/mach/Data/Dumper.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/File.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/Select.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/Socket.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/Handle.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/Seekable.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO/Pipe.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IPC/SysV.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IPC/Msg.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IPC/Semaphore.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/B/B.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/B/B.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/B/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DB_File/autosplit.ix OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DB_File/DB_File.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DB_File/DB_File.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DB_File/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Data/Dumper/Dumper.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Data/Dumper/Dumper.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Data/Dumper/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/.exists OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/dl_findfile.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/dl_expandspec.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/dl_find_symbol_anywhere.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/autosplit.ix OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/DynaLoader.a OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/DynaLoader/extralibs.ld OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Fcntl/Fcntl.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Fcntl/Fcntl.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Fcntl/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IO/IO.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IO/IO.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IO/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IPC/SysV/SysV.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IPC/SysV/SysV.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/IPC/SysV/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/NDBM_File/NDBM_File.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/NDBM_File/NDBM_File.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/NDBM_File/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Opcode/Opcode.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Opcode/Opcode.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Opcode/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/assert.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/tolower.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/toupper.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/closedir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/opendir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/readdir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/rewinddir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/errno.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/creat.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fcntl.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getgrgid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getgrnam.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/atan2.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/cos.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/exp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fabs.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/log.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/pow.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sin.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sqrt.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getpwnam.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getpwuid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/longjmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/setjmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/kill.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/feof.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/siglongjmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sigsetjmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/raise.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/offsetof.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/clearerr.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fclose.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fdopen.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fgetc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fgets.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fileno.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fopen.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fprintf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fputc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fputs.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fread.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/freopen.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fscanf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fseek.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/ferror.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fflush.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fgetpos.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fsetpos.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/ftell.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fwrite.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getchar.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/gets.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/perror.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/printf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/putc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/putchar.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/puts.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/remove.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/rename.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/rewind.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/scanf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sprintf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sscanf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/tmpfile.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/ungetc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/vfprintf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/vprintf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/vsprintf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/abs.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/atexit.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/atof.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/atoi.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/atol.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/bsearch.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/calloc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/div.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/exit.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/free.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getenv.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/labs.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/ldiv.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/malloc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/qsort.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/rand.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/realloc.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/srand.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/system.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/memchr.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/memcmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/memcpy.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/memmove.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/memset.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strcat.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strchr.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strcmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strcpy.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strcspn.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strerror.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strlen.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strncat.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strncmp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strncpy.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strpbrk.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strrchr.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strspn.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strstr.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/strtok.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/chmod.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fstat.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/mkdir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/stat.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/umask.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/wait.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/waitpid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/gmtime.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/localtime.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/time.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/alarm.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/chdir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/chown.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execl.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execle.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execlp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execv.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execve.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/execvp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/fork.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getcwd.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getegid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/geteuid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getgid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getgroups.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getlogin.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getpgrp.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getpid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getppid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/getuid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/isatty.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/link.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/rmdir.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/setbuf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/setgid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/setuid.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/setvbuf.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/sleep.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/unlink.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/utime.al OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/autosplit.ix OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/POSIX.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/POSIX.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/POSIX/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/SDBM_File/SDBM_File.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/SDBM_File/SDBM_File.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/SDBM_File/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Socket/Socket.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Socket/Socket.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Socket/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/attrs/attrs.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/attrs/attrs.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/attrs/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/re/re.so OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/re/re.bs OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/re/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/sdbm/extralibs.ld OLD_FILES+=usr/libdata/perl/5.00503/mach/auto/Errno/.packlist OLD_FILES+=usr/libdata/perl/5.00503/mach/Config.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/B.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/O.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/perllocal.pod OLD_FILES+=usr/libdata/perl/5.00503/mach/DB_File.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/Errno.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/Fcntl.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/IO.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/NDBM_File.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/Safe.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/Opcode.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/ops.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/POSIX.pod OLD_FILES+=usr/libdata/perl/5.00503/mach/POSIX.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/SDBM_File.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/Socket.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/attrs.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/re.pm OLD_FILES+=usr/libdata/perl/5.00503/mach/_h2ph_pre.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/a.out.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_ccb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_extend.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_periph.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_queue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_sim.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_xpt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_xpt_periph.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/cam/cam_xpt_sim.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/aio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/alias.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/assert.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/bitstring.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/calendar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/camlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/com_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/com_right.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ctype.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/curses.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/db.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/des.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/devstat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/dialog.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/dirent.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/disktab.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/dlfcn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/elf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/errno.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/eti.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/fcntl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/fetch.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/float.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/floatingpoint.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/fnmatch.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/form.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/fstab.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ftpio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/fts.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/glob.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/gmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/gnuregex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/grp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/histedit.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ieeefp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ifaddrs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/inttypes.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/iso646.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/kvm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libatm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libdisk.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libgen.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libusb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libutil.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/limits.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/link.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/linker_set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/locale.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/login_cap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/malloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/FlexLexer.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/PlotFile.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/SFile.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/_G_config.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/algo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/algobase.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/alloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/builtinbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/bvector.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/complex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/defalloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/deque.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/editbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/floatio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/fstream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/function.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/hash_map.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/hash_set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/hashtable.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/heap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/indstream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iolibio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iomanip.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/list.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iostdio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iostream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iostreamP.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/istream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/iterator.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/libio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/libioP.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/map.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/multimap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/multiset.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/new.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/ostream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/pair.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/parsestream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/pfstream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/procbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/pthread_alloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/rope.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/ropeimpl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/slist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stdiostream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_algo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/tree.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_algobase.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_alloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_bvector.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_config.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_construct.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_deque.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_function.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_hash_fun.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_hash_map.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_hash_set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_hashtable.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_heap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_iterator.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_list.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_map.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_multimap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_multiset.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_numeric.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_pair.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_queue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_raw_storage_iter.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_relops.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_rope.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_slist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_stack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_tempbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_tree.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_uninitialized.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stl_vector.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/stream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/streambuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/strfile.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/strstream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/tempbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/type_traits.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g++/vector.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/math.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/md2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/md4.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/md5.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/memory.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/menu.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/mp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/mpool.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/mqueue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ncurses.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ndbm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netdb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nl_types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nlist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objformat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/opie.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/osreldate.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/panel.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/paths.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pcap-int.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pcap-namedb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pcap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/poll.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pthread.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pthread_np.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pwd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/radlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ranlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/regex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/regexp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/resolv.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ripemd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rune.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/runetype.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sched.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/search.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/semaphore.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/setjmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sgtty.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sha.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/signal.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/skey.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stab.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stand.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stdarg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stddef.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stdio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stdlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/strhash.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/string.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stringlist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/strings.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/struct.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sysexits.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/syslog.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/taclib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/tar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/tcpd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/term.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/termcap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/termios.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/time.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/timers.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ttyent.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ucontext.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/unctrl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/unistd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/utime.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/utmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/values.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/varargs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vgl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vis.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/zconf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/zlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/ftp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/inet.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/nameser.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/nameser_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/telnet.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/arpa/tftp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/assertions.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/ctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/dst.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/eventlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/heap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/irpmarshall.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/logging.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/memcluster.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/misc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/tree.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/isc/list.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ansi.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/apic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/apm_bios.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/apm_segments.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/asc_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/asm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/asmacros.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/asnames.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/atomic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bootinfo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_at386.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_memio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_pc98.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_pio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_pio_ind.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/cdk.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/clock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/comstats.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/console.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/cpu.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/cpufunc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/cputypes.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/cronyx.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/db_machdep.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/dvcfg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/elf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/endian.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/exec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/float.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/floatingpoint.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/frame.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/globaldata.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/globals.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/gsc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_cause.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_rbch_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_tel_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_trace.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ieeefp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/if_wavelan_ieee.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/if_wl_wavelan.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/iic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/in_cksum.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ioctl_bt848.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ioctl_ctx.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ioctl_fd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ioctl_meteor.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ipl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/joystick.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/limits.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/lock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/md_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/mouse.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/mpapic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/mtpr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/bus_dma.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/npx.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/param.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pcaudioio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pcb_ext.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pcvt_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/perfmon.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/physio_proc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pmap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/proc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/profile.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/psl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ptrace.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/reg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/reloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/resource.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/segments.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/setjmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/sigframe.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/signal.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/smb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/smp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/smptests.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/soundcard.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/speaker.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/specialreg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/spigot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/stdarg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/sysarch.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/trap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/tss.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/uc_device.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ucontext.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/ultrasound.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/varargs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/vm86.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/vmparam.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/wtio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/i4b_isppp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/machine/pci_cfgreg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/bootsect.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/bpb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/denode.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/direntry.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/fat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/msdosfs/msdosfsmount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/bpf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/bpf_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/bpfdesc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/bridge.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/ethernet.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/hostcache.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_arp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_atm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_dl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_gif.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_ieee80211.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_llc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_media.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_mib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_ppp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_pppvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_slvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_sppp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_stf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_tap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_tapvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_tun.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/slip.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_tunvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_vlan_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/intrq.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/iso88025.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/net_osdep.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/netisr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/pfkeyv2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/ppp_comp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/ppp_defs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/radix.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/raw_cb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/route.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/slcompress.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/zlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_faith.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_arc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/net/if_gre.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/krpc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsdiskless.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsm_subs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsmount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsnode.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsproto.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsrtt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsrvcache.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nfsv2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/nqnfs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/rpcv2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nfs/xdr_subs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/aarp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/at.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/at_extern.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/at_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/ddp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/ddp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/endian.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatalk/phase2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_cm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_if.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_sap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_sigmgr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_stack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_sys.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/atm_vc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/kern_include.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/port.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netatm/queue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/netgraph.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_UI.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_async.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_bpf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_bridge.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_cisco.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_echo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_ether.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_frame_relay.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_hole.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_iface.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_ksocket.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_lmi.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_message.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_mppc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_one2many.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_parse.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_ppp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_pppoe.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_pptpgre.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_rfc1490.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_sample.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_socket.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_socketvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_tee.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_tty.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_vjc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_eiface.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_etf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_device.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_l2tp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netgraph/ng_fec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/icmp6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/icmp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/if_atm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/if_ether.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/if_fddi.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/igmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/igmp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in_gif.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in_hostcache.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in_pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in_systm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/in_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_auth.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_dummynet.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_ecn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_encap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_fil.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_flow.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_frag.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_fw.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_icmp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_mroute.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_nat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_proxy.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_state.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ipl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ipprotosw.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp_fsm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp_seq.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp_timer.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/tcpip.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/udp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/udp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_fw2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet/ip_gre.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ah.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ah6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/esp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/esp6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/icmp6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6_gif.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6_ifattach.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6_pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6_prefix.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/in6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6_ecn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6_fw.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6_mroute.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ip6protosw.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ipcomp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ipcomp6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ipsec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/ipsec6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/mld6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/nd6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/pim6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/pim6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/scope6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/tcp6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/udp6_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/esp_rijndael.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netinet6/raw_ip6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/ipx.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/ipx_if.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/ipx_ip.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/ipx_pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/ipx_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/spx.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/spx_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/spx_timer.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipx/spx_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netkey/key.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netkey/key_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netkey/key_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netkey/keydb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netkey/keysock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netnatm/natm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_cfg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_conn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_file.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_lib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_ncp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_nls.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_rcfile.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_rq.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_sock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_subr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/ncp_user.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netncp/nwerror.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/idp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/idp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/ns.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/ns_error.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/ns_if.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/ns_pcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/sp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/spidp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/spp_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/spp_timer.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netns/spp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs_compr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs_ihash.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs_inode.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs_subr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfs_vfsops.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ntfs/ntfsmount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nwfs/nwfs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nwfs/nwfs_mount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nwfs/nwfs_node.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/nwfs/nwfs_subr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/NXConstStr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/Object.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/Protocol.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/encoding.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/hash.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/objc-api.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/objc-list.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/objc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/runtime.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/sarray.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/thr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/objc/typedstream.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/asn1.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/asn1_mac.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/bio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/blowfish.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/bn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/buffer.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/cast.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/comp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/conf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/conf_api.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/crypto.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/des.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/dh.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/dsa.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/dso.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/e_os.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/e_os2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ebcdic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/evp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hmac.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/lhash.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/md2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/md4.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/md5.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/mdc2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/obj_mac.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/objects.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/opensslconf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/opensslv.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/pem.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/pem2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/pkcs12.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/pkcs7.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/rand.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/rc2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/rc4.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/rc5.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ripemd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/rsa.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/safestack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/sha.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ssl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ssl2.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ssl23.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ssl3.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ssl_locl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/stack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/symhacks.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/tls1.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/tmdiff.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/txt_db.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/x509.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/x509_vfy.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/x509v3.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/idea.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/aes.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/asn1t.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/cryptlib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/des_old.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/engine.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/krb5_asn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/kssl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ocsp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ossl_typ.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ui.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ui_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/aes_locl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/eng_int.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_4758_cca_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_aep_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_atalla_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_cswift_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_ncipher_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_nuron_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_sureware_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/hw_ubsec_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/openssl/ui_locl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/cardinfo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/cis.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/driver.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/i82365.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/pccard_nbk.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/slot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/meciareg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/pcic_pci.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/pccard/pcicvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/posix4/aio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/posix4/mqueue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/posix4/posix4.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/posix4/sched.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/posix4/semaphore.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/protocols/dumprestore.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/protocols/routed.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/protocols/rwhod.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/protocols/talkd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/protocols/timed.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/chardefs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/history.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/keymaps.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/readline.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/rlconf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/rlstdc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readline/tilde.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/auth.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/auth_des.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/auth_unix.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/clnt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/des.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/des_crypt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/key_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/pmap_clnt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/pmap_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/pmap_rmt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/rpc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/rpc_com.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/rpc_msg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/svc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/svc_auth.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpc/xdr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/bootparam_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/crypt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/key_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/klm_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/mount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nfs_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nis.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nis_cache.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nis_callback.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nis_db.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nis_tags.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nislib.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/nlm_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/rex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/rnusers.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/rquota.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/rstat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/rwall.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/sm_inter.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/spray.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/yp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/yp_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/ypclnt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/yppasswd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/ypupdate_prot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/rpcsvc/ypxfrd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/_pam_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/_pam_macros.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/_pam_types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/pam_appl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/pam_malloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/pam_misc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/pam_mod_misc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/security/pam_modules.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ss/mit-sipb-copyright.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ss/ss.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/ss/ss_err.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/_posix.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ata.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/acct.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/acl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/agpio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/aio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/assym.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/blist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/buf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/bus.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/bus_private.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/callout.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ccdvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/cdefs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/cdio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/cdrio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/chio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/clist.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/endian.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/conf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/cons.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/consio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/copyright.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ctype.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dir.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dataacq.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/link_elf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/device_port.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/devicestat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dirent.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/disk.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/disklabel.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/diskslice.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dkstat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dmap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/domain.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/dvdio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/elf32.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/elf64.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/elf_common.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/elf_generic.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/errno.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/event.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/eventhandler.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/eventvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/exec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/extattr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/fbio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/fcntl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/file.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/filedesc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/filio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/gmon.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/imgact.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/imgact_aout.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/imgact_elf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/inflate.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/interrupt.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/inttypes.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ioccom.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ioctl_compat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ipc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/jail.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/joystick.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/kbio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/kernel.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/kthread.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ktrace.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/libkern.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/linker.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/linker_set.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/lock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/lockf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/malloc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/mbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/md5.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/memrange.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/mman.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/module.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/mount.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/msg.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/msgbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/mtio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/namei.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/param.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/pciio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/pioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/pipe.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/poll.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/proc.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/procfs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/protosw.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ptio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ptrace.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/queue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/random.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/reboot.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/resource.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/resourcevar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/rman.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/rtprio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sbuf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/select.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sem.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/shm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/signal.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/signalvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/snoop.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/socket.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/socketvar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sockio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/soundcard.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/stat.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/syscall-hide.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/syscall.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sysctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sysent.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/syslimits.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/syslog.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/sysproto.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/systm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/taskqueue.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/termios.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/time.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/timeb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/timepps.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/timers.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/times.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/timex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/tprintf.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/tty.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ttychars.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ttycom.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ttydefaults.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ttydev.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/types.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ucontext.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/ucred.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/uio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/un.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/unistd.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/unpcb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/user.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/utsname.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/vmmeter.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/vnioctl.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/vnode.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/wait.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/wormio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/xrpuio.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/kobj.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/link_aout.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/nlist_aout.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/mchain.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/fnv_hash.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/iconv.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/sys/md4.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/pmap.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/swap_pager.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_extern.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_kern.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_map.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_object.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_page.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_pageout.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_pager.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_param.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vm_zone.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/vm/vnode_pager.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/complex.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/stdbool.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/langinfo.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/netbios.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_conn.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_dev.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_rq.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_subr.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_tran.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netsmb/smb_trantcp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/g2c.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/telnet.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/elf-hints.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/libusbhid.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/radlib_vs.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/readpassphrase.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/wchar.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/wctype.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/cast.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/castsb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/cryptodev.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/cryptosoft.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/deflate.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/rijndael.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/rmd160.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/skipjack.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/crypto/xform.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ah.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ah_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/esp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/esp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ipcomp.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ipcomp_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ipip_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ipsec.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/ipsec6.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/key.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/key_debug.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/key_var.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/keydb.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/keysock.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/netipsec/xform.ph OLD_FILES+=usr/libdata/perl/5.00503/mach/bzlib.ph OLD_FILES+=usr/libdata/perl/5.00503/pod/perl.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perl5004delta.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlapio.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlbook.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlbot.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlcall.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perldata.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perldebug.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perldelta.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perldiag.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perldsc.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlembed.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq1.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq2.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq3.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq4.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq5.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq6.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq7.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlipc.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq8.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfaq9.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlform.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlfunc.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlguts.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlhist.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perllocale.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perllol.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlmod.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlmodinstall.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlmodlib.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlobj.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlop.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlopentut.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlpod.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlport.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlre.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlref.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlreftut.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlrun.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlsec.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlstyle.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlsub.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlsyn.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlthrtut.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perltie.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perltoc.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perltoot.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perltrap.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlvar.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlxs.pod OLD_FILES+=usr/libdata/perl/5.00503/pod/perlxstut.pod OLD_FILES+=usr/libdata/perl/5.00503/AnyDBM_File.pm OLD_FILES+=usr/libdata/perl/5.00503/AutoLoader.pm OLD_FILES+=usr/libdata/perl/5.00503/AutoSplit.pm OLD_FILES+=usr/libdata/perl/5.00503/Benchmark.pm OLD_FILES+=usr/libdata/perl/5.00503/CGI.pm OLD_FILES+=usr/libdata/perl/5.00503/CPAN.pm OLD_FILES+=usr/libdata/perl/5.00503/Carp.pm OLD_FILES+=usr/libdata/perl/5.00503/Cwd.pm OLD_FILES+=usr/libdata/perl/5.00503/DirHandle.pm OLD_FILES+=usr/libdata/perl/5.00503/Dumpvalue.pm OLD_FILES+=usr/libdata/perl/5.00503/English.pm OLD_FILES+=usr/libdata/perl/5.00503/Env.pm OLD_FILES+=usr/libdata/perl/5.00503/Exporter.pm OLD_FILES+=usr/libdata/perl/5.00503/Fatal.pm OLD_FILES+=usr/libdata/perl/5.00503/FileCache.pm OLD_FILES+=usr/libdata/perl/5.00503/FileHandle.pm OLD_FILES+=usr/libdata/perl/5.00503/FindBin.pm OLD_FILES+=usr/libdata/perl/5.00503/SelectSaver.pm OLD_FILES+=usr/libdata/perl/5.00503/SelfLoader.pm OLD_FILES+=usr/libdata/perl/5.00503/Shell.pm OLD_FILES+=usr/libdata/perl/5.00503/Symbol.pm OLD_FILES+=usr/libdata/perl/5.00503/Test.pm OLD_FILES+=usr/libdata/perl/5.00503/abbrev.pl OLD_FILES+=usr/libdata/perl/5.00503/UNIVERSAL.pm OLD_FILES+=usr/libdata/perl/5.00503/assert.pl OLD_FILES+=usr/libdata/perl/5.00503/autouse.pm OLD_FILES+=usr/libdata/perl/5.00503/base.pm OLD_FILES+=usr/libdata/perl/5.00503/bigfloat.pl OLD_FILES+=usr/libdata/perl/5.00503/bigint.pl OLD_FILES+=usr/libdata/perl/5.00503/bigrat.pl OLD_FILES+=usr/libdata/perl/5.00503/blib.pm OLD_FILES+=usr/libdata/perl/5.00503/cacheout.pl OLD_FILES+=usr/libdata/perl/5.00503/chat2.pl OLD_FILES+=usr/libdata/perl/5.00503/complete.pl OLD_FILES+=usr/libdata/perl/5.00503/constant.pm OLD_FILES+=usr/libdata/perl/5.00503/ctime.pl OLD_FILES+=usr/libdata/perl/5.00503/diagnostics.pm OLD_FILES+=usr/libdata/perl/5.00503/dotsh.pl OLD_FILES+=usr/libdata/perl/5.00503/dumpvar.pl OLD_FILES+=usr/libdata/perl/5.00503/exceptions.pl OLD_FILES+=usr/libdata/perl/5.00503/fastcwd.pl OLD_FILES+=usr/libdata/perl/5.00503/fields.pm OLD_FILES+=usr/libdata/perl/5.00503/find.pl OLD_FILES+=usr/libdata/perl/5.00503/finddepth.pl OLD_FILES+=usr/libdata/perl/5.00503/flush.pl OLD_FILES+=usr/libdata/perl/5.00503/ftp.pl OLD_FILES+=usr/libdata/perl/5.00503/getcwd.pl OLD_FILES+=usr/libdata/perl/5.00503/getopt.pl OLD_FILES+=usr/libdata/perl/5.00503/getopts.pl OLD_FILES+=usr/libdata/perl/5.00503/hostname.pl OLD_FILES+=usr/libdata/perl/5.00503/importenv.pl OLD_FILES+=usr/libdata/perl/5.00503/integer.pm OLD_FILES+=usr/libdata/perl/5.00503/less.pm OLD_FILES+=usr/libdata/perl/5.00503/lib.pm OLD_FILES+=usr/libdata/perl/5.00503/locale.pm OLD_FILES+=usr/libdata/perl/5.00503/look.pl OLD_FILES+=usr/libdata/perl/5.00503/newgetopt.pl OLD_FILES+=usr/libdata/perl/5.00503/open2.pl OLD_FILES+=usr/libdata/perl/5.00503/open3.pl OLD_FILES+=usr/libdata/perl/5.00503/overload.pm OLD_FILES+=usr/libdata/perl/5.00503/perl5db.pl OLD_FILES+=usr/libdata/perl/5.00503/pwd.pl OLD_FILES+=usr/libdata/perl/5.00503/shellwords.pl OLD_FILES+=usr/libdata/perl/5.00503/sigtrap.pm OLD_FILES+=usr/libdata/perl/5.00503/stat.pl OLD_FILES+=usr/libdata/perl/5.00503/strict.pm OLD_FILES+=usr/libdata/perl/5.00503/subs.pm OLD_FILES+=usr/libdata/perl/5.00503/syslog.pl OLD_FILES+=usr/libdata/perl/5.00503/tainted.pl OLD_FILES+=usr/libdata/perl/5.00503/termcap.pl OLD_FILES+=usr/libdata/perl/5.00503/timelocal.pl OLD_FILES+=usr/libdata/perl/5.00503/validate.pl OLD_FILES+=usr/libdata/perl/5.00503/vars.pm OLD_FILES+=usr/libdata/perl/5.00503/re.pm OLD_FILES+=usr/libdata/perl/5.00503/Config.pm OLD_FILES+=usr/libdata/perl/5.00503/.exists OLD_FILES+=usr/libdata/perl/5.00503/DynaLoader.pm OLD_FILES+=usr/share/perl/man/man3/AnyDBM_File.3.gz OLD_FILES+=usr/share/perl/man/man3/AutoLoader.3.gz OLD_FILES+=usr/share/perl/man/man3/AutoSplit.3.gz OLD_FILES+=usr/share/perl/man/man3/B.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Asmdata.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Assembler.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Bblock.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Bytecode.3.gz OLD_FILES+=usr/share/perl/man/man3/B::C.3.gz OLD_FILES+=usr/share/perl/man/man3/B::CC.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Debug.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Deparse.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Disassembler.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Lint.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Showlex.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Stackobj.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Terse.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Xref.3.gz OLD_FILES+=usr/share/perl/man/man3/Benchmark.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Apache.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Carp.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Cookie.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Fast.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Push.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Switch.3.gz OLD_FILES+=usr/share/perl/man/man3/CPAN.3.gz OLD_FILES+=usr/share/perl/man/man3/CPAN::FirstTime.3.gz OLD_FILES+=usr/share/perl/man/man3/CPAN::Nox.3.gz OLD_FILES+=usr/share/perl/man/man3/Carp.3.gz OLD_FILES+=usr/share/perl/man/man3/Class::Struct.3.gz OLD_FILES+=usr/share/perl/man/man3/Config.3.gz OLD_FILES+=usr/share/perl/man/man3/Cwd.3.gz OLD_FILES+=usr/share/perl/man/man3/DB_File.3.gz OLD_FILES+=usr/share/perl/man/man3/Data::Dumper.3.gz OLD_FILES+=usr/share/perl/man/man3/Devel::SelfStubber.3.gz OLD_FILES+=usr/share/perl/man/man3/DirHandle.3.gz OLD_FILES+=usr/share/perl/man/man3/Dumpvalue.3.gz OLD_FILES+=usr/share/perl/man/man3/DynaLoader.3.gz OLD_FILES+=usr/share/perl/man/man3/English.3.gz OLD_FILES+=usr/share/perl/man/man3/Env.3.gz OLD_FILES+=usr/share/perl/man/man3/Exporter.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Command.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Embed.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Install.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Installed.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Liblist.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MM_OS2.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MM_Unix.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MM_VMS.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MM_Win32.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MakeMaker.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Manifest.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Mkbootstrap.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Mksymlists.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::Packlist.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::testlib.3.gz OLD_FILES+=usr/share/perl/man/man3/Fatal.3.gz OLD_FILES+=usr/share/perl/man/man3/Fcntl.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Basename.3.gz OLD_FILES+=usr/share/perl/man/man3/File::CheckTree.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Compare.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Copy.3.gz OLD_FILES+=usr/share/perl/man/man3/File::DosGlob.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Find.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Path.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec::Mac.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec::OS2.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec::Unix.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec::VMS.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Spec::Win32.3.gz OLD_FILES+=usr/share/perl/man/man3/File::stat.3.gz OLD_FILES+=usr/share/perl/man/man3/FileCache.3.gz OLD_FILES+=usr/share/perl/man/man3/IO.3.gz OLD_FILES+=usr/share/perl/man/man3/FileHandle.3.gz OLD_FILES+=usr/share/perl/man/man3/FindBin.3.gz OLD_FILES+=usr/share/perl/man/man3/GDBM_File.3.gz OLD_FILES+=usr/share/perl/man/man3/Getopt::Long.3.gz OLD_FILES+=usr/share/perl/man/man3/Getopt::Std.3.gz OLD_FILES+=usr/share/perl/man/man3/I18N::Collate.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::File.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Handle.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Pipe.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Seekable.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Select.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Socket.3.gz OLD_FILES+=usr/share/perl/man/man3/IPC::Msg.3.gz OLD_FILES+=usr/share/perl/man/man3/IPC::Open2.3.gz OLD_FILES+=usr/share/perl/man/man3/IPC::Open3.3.gz OLD_FILES+=usr/share/perl/man/man3/IPC::Semaphore.3.gz OLD_FILES+=usr/share/perl/man/man3/IPC::SysV.3.gz OLD_FILES+=usr/share/perl/man/man3/Math::BigFloat.3.gz OLD_FILES+=usr/share/perl/man/man3/Math::BigInt.3.gz OLD_FILES+=usr/share/perl/man/man3/Math::Complex.3.gz OLD_FILES+=usr/share/perl/man/man3/Math::Trig.3.gz OLD_FILES+=usr/share/perl/man/man3/NDBM_File.3.gz OLD_FILES+=usr/share/perl/man/man3/Net::Ping.3.gz OLD_FILES+=usr/share/perl/man/man3/Net::hostent.3.gz OLD_FILES+=usr/share/perl/man/man3/Net::netent.3.gz OLD_FILES+=usr/share/perl/man/man3/Net::protoent.3.gz OLD_FILES+=usr/share/perl/man/man3/Net::servent.3.gz OLD_FILES+=usr/share/perl/man/man3/O.3.gz OLD_FILES+=usr/share/perl/man/man3/ODBM_File.3.gz OLD_FILES+=usr/share/perl/man/man3/Opcode.3.gz OLD_FILES+=usr/share/perl/man/man3/POSIX.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Html.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Text.3.gz OLD_FILES+=usr/share/perl/man/man3/SDBM_File.3.gz OLD_FILES+=usr/share/perl/man/man3/Safe.3.gz OLD_FILES+=usr/share/perl/man/man3/Search::Dict.3.gz OLD_FILES+=usr/share/perl/man/man3/SelectSaver.3.gz OLD_FILES+=usr/share/perl/man/man3/SelfLoader.3.gz OLD_FILES+=usr/share/perl/man/man3/Shell.3.gz OLD_FILES+=usr/share/perl/man/man3/Socket.3.gz OLD_FILES+=usr/share/perl/man/man3/Symbol.3.gz OLD_FILES+=usr/share/perl/man/man3/re.3.gz OLD_FILES+=usr/share/perl/man/man3/Sys::Hostname.3.gz OLD_FILES+=usr/share/perl/man/man3/Sys::Syslog.3.gz OLD_FILES+=usr/share/perl/man/man3/Term::Cap.3.gz OLD_FILES+=usr/share/perl/man/man3/Term::Complete.3.gz OLD_FILES+=usr/share/perl/man/man3/Term::ReadLine.3.gz OLD_FILES+=usr/share/perl/man/man3/Test.3.gz OLD_FILES+=usr/share/perl/man/man3/Test::Harness.3.gz OLD_FILES+=usr/share/perl/man/man3/Text::Abbrev.3.gz OLD_FILES+=usr/share/perl/man/man3/Text::ParseWords.3.gz OLD_FILES+=usr/share/perl/man/man3/Text::Soundex.3.gz OLD_FILES+=usr/share/perl/man/man3/Text::Tabs.3.gz OLD_FILES+=usr/share/perl/man/man3/Text::Wrap.3.gz OLD_FILES+=usr/share/perl/man/man3/Thread.3.gz OLD_FILES+=usr/share/perl/man/man3/Thread::Queue.3.gz OLD_FILES+=usr/share/perl/man/man3/Thread::Semaphore.3.gz OLD_FILES+=usr/share/perl/man/man3/Thread::Signal.3.gz OLD_FILES+=usr/share/perl/man/man3/Thread::Specific.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::Array.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::Handle.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::Hash.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::RefHash.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::Scalar.3.gz OLD_FILES+=usr/share/perl/man/man3/Tie::SubstrHash.3.gz OLD_FILES+=usr/share/perl/man/man3/Time::Local.3.gz OLD_FILES+=usr/share/perl/man/man3/Time::gmtime.3.gz OLD_FILES+=usr/share/perl/man/man3/Time::localtime.3.gz OLD_FILES+=usr/share/perl/man/man3/Time::tm.3.gz OLD_FILES+=usr/share/perl/man/man3/UNIVERSAL.3.gz OLD_FILES+=usr/share/perl/man/man3/User::grent.3.gz OLD_FILES+=usr/share/perl/man/man3/User::pwent.3.gz OLD_FILES+=usr/share/perl/man/man3/attrs.3.gz OLD_FILES+=usr/share/perl/man/man3/autouse.3.gz OLD_FILES+=usr/share/perl/man/man3/base.3.gz OLD_FILES+=usr/share/perl/man/man3/blib.3.gz OLD_FILES+=usr/share/perl/man/man3/constant.3.gz OLD_FILES+=usr/share/perl/man/man3/diagnostics.3.gz OLD_FILES+=usr/share/perl/man/man3/fields.3.gz OLD_FILES+=usr/share/perl/man/man3/integer.3.gz OLD_FILES+=usr/share/perl/man/man3/less.3.gz OLD_FILES+=usr/share/perl/man/man3/lib.3.gz OLD_FILES+=usr/share/perl/man/man3/locale.3.gz OLD_FILES+=usr/share/perl/man/man3/ops.3.gz OLD_FILES+=usr/share/perl/man/man3/overload.3.gz OLD_FILES+=usr/share/perl/man/man3/sigtrap.3.gz OLD_FILES+=usr/share/perl/man/man3/strict.3.gz OLD_FILES+=usr/share/perl/man/man3/subs.3.gz OLD_FILES+=usr/share/perl/man/man3/vars.3.gz OLD_FILES+=usr/share/perl/man/man3/B::Stash.3.gz OLD_FILES+=usr/share/perl/man/man3/ByteLoader.3.gz OLD_FILES+=usr/share/perl/man/man3/CGI::Pretty.3.gz OLD_FILES+=usr/share/perl/man/man3/Carp::Heavy.3.gz OLD_FILES+=usr/share/perl/man/man3/DB.3.gz OLD_FILES+=usr/share/perl/man/man3/DProf::DProf.3.gz OLD_FILES+=usr/share/perl/man/man3/Exporter::Heavy.3.gz OLD_FILES+=usr/share/perl/man/man3/ExtUtils::MM_Cygwin.3.gz OLD_FILES+=usr/share/perl/man/man3/File::Glob.3.gz OLD_FILES+=usr/share/perl/man/man3/Glob::Glob.3.gz OLD_FILES+=usr/share/perl/man/man3/Hostname::Hostname.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Dir.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Poll.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Socket::INET.3.gz OLD_FILES+=usr/share/perl/man/man3/IO::Socket::UNIX.3.gz OLD_FILES+=usr/share/perl/man/man3/Peek::Peek.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Checker.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Find.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::InputObjects.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Man.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::ParseUtils.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Parser.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Plainer.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Select.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Text::Color.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Text::Termcap.3.gz OLD_FILES+=usr/share/perl/man/man3/Pod::Usage.3.gz OLD_FILES+=usr/share/perl/man/man3/Syslog::Syslog.3.gz OLD_FILES+=usr/share/perl/man/man3/Term::ANSIColor.3.gz OLD_FILES+=usr/share/perl/man/man3/XSLoader.3.gz OLD_FILES+=usr/share/perl/man/man3/attributes.3.gz OLD_FILES+=usr/share/perl/man/man3/bytes.3.gz OLD_FILES+=usr/share/perl/man/man3/charnames.3.gz OLD_FILES+=usr/share/perl/man/man3/filetest.3.gz OLD_FILES+=usr/share/perl/man/man3/open.3.gz OLD_FILES+=usr/share/perl/man/man3/utf8.3.gz OLD_FILES+=usr/share/perl/man/man3/warnings.3.gz OLD_FILES+=usr/share/perl/man/man3/warnings::register.3.gz OLD_FILES+=usr/share/perl/man/whatis OLD_FILES+=usr/share/man/man1/CA.pl.1.gz OLD_FILES+=usr/share/man/man1/asn1parse.1.gz OLD_FILES+=usr/share/man/man1/ca.1.gz OLD_FILES+=usr/share/man/man1/ciphers.1.gz OLD_FILES+=usr/share/man/man1/config.1.gz OLD_FILES+=usr/share/man/man1/crl.1.gz OLD_FILES+=usr/share/man/man1/crl2pkcs7.1.gz OLD_FILES+=usr/share/man/man1/dgst.1.gz OLD_FILES+=usr/share/man/man1/dhparam.1.gz OLD_FILES+=usr/share/man/man1/doscmd.1.gz OLD_FILES+=usr/share/man/man1/dsa.1.gz OLD_FILES+=usr/share/man/man1/dsaparam.1.gz OLD_FILES+=usr/share/man/man1/enc.1.gz OLD_FILES+=usr/share/man/man1/gendsa.1.gz OLD_FILES+=usr/share/man/man1/genrsa.1.gz OLD_FILES+=usr/share/man/man1/getNAME.1.gz OLD_FILES+=usr/share/man/man1/nseq.1.gz OLD_FILES+=usr/share/man/man1/ocsp.1.gz OLD_FILES+=usr/share/man/man1/openssl.1.gz OLD_FILES+=usr/share/man/man1/perl.1.gz OLD_FILES+=usr/share/man/man1/perl5004delta.1.gz OLD_FILES+=usr/share/man/man1/perlapio.1.gz OLD_FILES+=usr/share/man/man1/perlbook.1.gz OLD_FILES+=usr/share/man/man1/perlbot.1.gz OLD_FILES+=usr/share/man/man1/perlcall.1.gz OLD_FILES+=usr/share/man/man1/perldata.1.gz OLD_FILES+=usr/share/man/man1/perldebug.1.gz OLD_FILES+=usr/share/man/man1/perldelta.1.gz OLD_FILES+=usr/share/man/man1/perldiag.1.gz OLD_FILES+=usr/share/man/man1/perldsc.1.gz OLD_FILES+=usr/share/man/man1/perlembed.1.gz OLD_FILES+=usr/share/man/man1/perlfaq.1.gz OLD_FILES+=usr/share/man/man1/perlfaq1.1.gz OLD_FILES+=usr/share/man/man1/perlfaq2.1.gz OLD_FILES+=usr/share/man/man1/perlfaq3.1.gz OLD_FILES+=usr/share/man/man1/perlfaq4.1.gz OLD_FILES+=usr/share/man/man1/perlfaq5.1.gz OLD_FILES+=usr/share/man/man1/perlfaq6.1.gz OLD_FILES+=usr/share/man/man1/perlfaq7.1.gz OLD_FILES+=usr/share/man/man1/perlfaq8.1.gz OLD_FILES+=usr/share/man/man1/perlfaq9.1.gz OLD_FILES+=usr/share/man/man1/perlform.1.gz OLD_FILES+=usr/share/man/man1/perlfunc.1.gz OLD_FILES+=usr/share/man/man1/perlguts.1.gz OLD_FILES+=usr/share/man/man1/perlhist.1.gz OLD_FILES+=usr/share/man/man1/perlipc.1.gz OLD_FILES+=usr/share/man/man1/perllocale.1.gz OLD_FILES+=usr/share/man/man1/perllol.1.gz OLD_FILES+=usr/share/man/man1/perlmod.1.gz OLD_FILES+=usr/share/man/man1/perlmodinstall.1.gz OLD_FILES+=usr/share/man/man1/perlmodlib.1.gz OLD_FILES+=usr/share/man/man1/perlobj.1.gz OLD_FILES+=usr/share/man/man1/perlop.1.gz OLD_FILES+=usr/share/man/man1/perlopentut.1.gz OLD_FILES+=usr/share/man/man1/perlpod.1.gz OLD_FILES+=usr/share/man/man1/perlport.1.gz OLD_FILES+=usr/share/man/man1/perlre.1.gz OLD_FILES+=usr/share/man/man1/perlref.1.gz OLD_FILES+=usr/share/man/man1/perlreftut.1.gz OLD_FILES+=usr/share/man/man1/perlrun.1.gz OLD_FILES+=usr/share/man/man1/perlsec.1.gz OLD_FILES+=usr/share/man/man1/perlstyle.1.gz OLD_FILES+=usr/share/man/man1/perlsub.1.gz OLD_FILES+=usr/share/man/man1/perlsyn.1.gz OLD_FILES+=usr/share/man/man1/perlthrtut.1.gz OLD_FILES+=usr/share/man/man1/perltie.1.gz OLD_FILES+=usr/share/man/man1/perltoc.1.gz OLD_FILES+=usr/share/man/man1/perltoot.1.gz OLD_FILES+=usr/share/man/man1/perltrap.1.gz OLD_FILES+=usr/share/man/man1/perlvar.1.gz OLD_FILES+=usr/share/man/man1/perlxs.1.gz OLD_FILES+=usr/share/man/man1/perlxstut.1.gz OLD_FILES+=usr/share/man/man1/perlbug.1.gz OLD_FILES+=usr/share/man/man1/perlcc.1.gz OLD_FILES+=usr/share/man/man1/perldoc.1.gz OLD_FILES+=usr/share/man/man1/perl5005delta.1.gz OLD_FILES+=usr/share/man/man1/perlfork.1.gz OLD_FILES+=usr/share/man/man1/perlboot.1.gz OLD_FILES+=usr/share/man/man1/perltootc.1.gz OLD_FILES+=usr/share/man/man1/perldbmfilter.1.gz OLD_FILES+=usr/share/man/man1/perldebguts.1.gz OLD_FILES+=usr/share/man/man1/perlnumber.1.gz OLD_FILES+=usr/share/man/man1/perlcompile.1.gz OLD_FILES+=usr/share/man/man1/perltodo.1.gz OLD_FILES+=usr/share/man/man1/perlapi.1.gz OLD_FILES+=usr/share/man/man1/perlintern.1.gz OLD_FILES+=usr/share/man/man1/perlhack.1.gz OLD_FILES+=usr/share/man/man1/perlbc.1.gz OLD_FILES+=usr/share/man/man1/pkcs12.1.gz OLD_FILES+=usr/share/man/man1/pkcs7.1.gz OLD_FILES+=usr/share/man/man1/pkcs8.1.gz OLD_FILES+=usr/share/man/man1/rand.1.gz OLD_FILES+=usr/share/man/man1/req.1.gz OLD_FILES+=usr/share/man/man1/rsa.1.gz OLD_FILES+=usr/share/man/man1/rsautl.1.gz OLD_FILES+=usr/share/man/man1/s_client.1.gz OLD_FILES+=usr/share/man/man1/s_server.1.gz OLD_FILES+=usr/share/man/man1/sess_id.1.gz OLD_FILES+=usr/share/man/man1/smime.1.gz OLD_FILES+=usr/share/man/man1/speed.1.gz OLD_FILES+=usr/share/man/man1/spkac.1.gz OLD_FILES+=usr/share/man/man1/verify.1.gz OLD_FILES+=usr/share/man/man1/version.1.gz OLD_FILES+=usr/share/man/man1/x509.1.gz OLD_FILES+=usr/share/man/man3/SSL_COMP_add_compression_method.3.gz OLD_FILES+=usr/share/man/man3/SSL_CTX_get_ex_new_index.3.gz OLD_FILES+=usr/share/man/man3/archive_entry_dup.3.gz OLD_FILES+=usr/share/man/man3/archive_entry_set_tartype.3.gz OLD_FILES+=usr/share/man/man3/archive_entry_tartype.3.gz OLD_FILES+=usr/share/man/man3/archive_read_data_into_file.3.gz OLD_FILES+=usr/share/man/man3/archive_read_open_tar.3.gz OLD_FILES+=usr/share/man/man3/archive_read_support_format_gnutar.3.gz OLD_FILES+=usr/share/man/man3/cipher.3.gz OLD_FILES+=usr/share/man/man3/des_cipher.3.gz OLD_FILES+=usr/share/man/man3/des_setkey.3.gz OLD_FILES+=usr/share/man/man3/encrypt.3.gz OLD_FILES+=usr/share/man/man3/endvfsent.3.gz OLD_FILES+=usr/share/man/man3/getvfsbytype.3.gz OLD_FILES+=usr/share/man/man3/getvfsent.3.gz OLD_FILES+=usr/share/man/man3/isnanf.3.gz OLD_FILES+=usr/share/man/man3/libautofs.3.gz OLD_FILES+=usr/share/man/man3/pthread_attr_setsstack.3.gz OLD_FILES+=usr/share/man/man3/pthread_getcancelstate.3.gz OLD_FILES+=usr/share/man/man3/pthread_mutexattr_getpshared.3.gz OLD_FILES+=usr/share/man/man3/pthread_mutexattr_setpshared.3.gz OLD_FILES+=usr/share/man/man3/set_assertion_failure_callback.3.gz OLD_FILES+=usr/share/man/man3/setkey.3.gz OLD_FILES+=usr/share/man/man3/setvfsent.3.gz OLD_FILES+=usr/share/man/man3/ssl.3.gz OLD_FILES+=usr/share/man/man3/vfsisloadable.3.gz OLD_FILES+=usr/share/man/man3/vfsload.3.gz OLD_FILES+=usr/share/man/man4/als4000.4.gz OLD_FILES+=usr/share/man/man4/csa.4.gz OLD_FILES+=usr/share/man/man4/emu10k1.4.gz OLD_FILES+=usr/share/man/man4/euc.4.gz OLD_FILES+=usr/share/man/man4/gusc.4.gz OLD_FILES+=usr/share/man/man4/if_fwp.4.gz OLD_FILES+=usr/share/man/man4/lomac.4.gz OLD_FILES+=usr/share/man/man4/maestro3.4.gz OLD_FILES+=usr/share/man/man4/raid.4.gz OLD_FILES+=usr/share/man/man4/sbc.4.gz OLD_FILES+=usr/share/man/man4/sd.4.gz OLD_FILES+=usr/share/man/man4/snc.4.gz OLD_FILES+=usr/share/man/man4/st.4.gz OLD_FILES+=usr/share/man/man4/uaudio.4.gz OLD_FILES+=usr/share/man/man4/utf2.4.gz OLD_FILES+=usr/share/man/man4/vinumdebug.4.gz OLD_FILES+=usr/share/man/man5/disklabel.5.gz OLD_FILES+=usr/share/man/man5/dm.conf.5.gz OLD_FILES+=usr/share/man/man5/ranlib.5.gz OLD_FILES+=usr/share/man/man5/utf2.5.gz OLD_FILES+=usr/share/man/man7/groff_mwww.7.gz OLD_FILES+=usr/share/man/man7/mmroff.7.gz OLD_FILES+=usr/share/man/man7/mwww.7.gz OLD_FILES+=usr/share/man/man7/style.perl.7.gz OLD_FILES+=usr/share/man/man8/apm.8.gz OLD_FILES+=usr/share/man/man8/apmconf.8.gz OLD_FILES+=usr/share/man/man8/apmd.8.gz OLD_FILES+=usr/share/man/man8/dm.8.gz OLD_FILES+=usr/share/man/man8/pam_ftp.8.gz OLD_FILES+=usr/share/man/man8/pam_wheel.8.gz OLD_FILES+=usr/share/man/man8/sconfig.8.gz OLD_FILES+=usr/share/man/man8/ssl.8.gz OLD_FILES+=usr/share/man/man8/wlconfig.8.gz OLD_FILES+=usr/share/man/man9/CURSIG.9.gz OLD_FILES+=usr/share/man/man9/VFS_INIT.9.gz OLD_FILES+=usr/share/man/man9/at_exit.9.gz OLD_FILES+=usr/share/man/man9/at_fork.9.gz OLD_FILES+=usr/share/man/man9/cdevsw_add.9.gz OLD_FILES+=usr/share/man/man9/cdevsw_remove.9.gz OLD_FILES+=usr/share/man/man9/cv_waitq_empty.9.gz OLD_FILES+=usr/share/man/man9/cv_waitq_remove.9.gz OLD_FILES+=usr/share/man/man9/endtsleep.9.gz OLD_FILES+=usr/share/man/man9/jumbo.9.gz OLD_FILES+=usr/share/man/man9/jumbo_freem.9.gz OLD_FILES+=usr/share/man/man9/jumbo_pg_alloc.9.gz OLD_FILES+=usr/share/man/man9/jumbo_pg_free.9.gz OLD_FILES+=usr/share/man/man9/jumbo_pg_steal.9.gz OLD_FILES+=usr/share/man/man9/jumbo_phys_to_kva.9.gz OLD_FILES+=usr/share/man/man9/jumbo_vm_init.9.gz OLD_FILES+=usr/share/man/man9/mac_biba.9.gz OLD_FILES+=usr/share/man/man9/mac_bsdextended.9.gz OLD_FILES+=usr/share/man/man9/mono_time.9.gz OLD_FILES+=usr/share/man/man9/p1003_1b.9.gz OLD_FILES+=usr/share/man/man9/pmap_prefault.9.gz OLD_FILES+=usr/share/man/man9/posix4.9.gz OLD_FILES+=usr/share/man/man9/resource_query_name.9.gz OLD_FILES+=usr/share/man/man9/resource_query_string.9.gz OLD_FILES+=usr/share/man/man9/resource_query_unit.9.gz OLD_FILES+=usr/share/man/man9/rm_at_exit.9.gz OLD_FILES+=usr/share/man/man9/rm_at_fork.9.gz OLD_FILES+=usr/share/man/man9/runtime.9.gz OLD_FILES+=usr/share/man/man9/sleepinit.9.gz OLD_FILES+=usr/share/man/man9/unsleep.9.gz OLD_FILES+=usr/share/man/ja/man1/perl.1.gz OLD_FILES+=usr/share/games/atc/Game_List OLD_FILES+=usr/share/games/atc/Killer OLD_FILES+=usr/share/games/atc/crossover OLD_FILES+=usr/share/games/atc/default OLD_FILES+=usr/share/games/atc/easy OLD_FILES+=usr/share/games/atc/game_2 OLD_FILES+=usr/share/games/larn/larnmaze OLD_FILES+=usr/share/games/larn/larnopts OLD_FILES+=usr/share/games/larn/larn.help OLD_FILES+=usr/share/games/quiz.db/africa OLD_FILES+=usr/share/games/quiz.db/america OLD_FILES+=usr/share/games/quiz.db/areas OLD_FILES+=usr/share/games/quiz.db/arith OLD_FILES+=usr/share/games/quiz.db/asia OLD_FILES+=usr/share/games/quiz.db/babies OLD_FILES+=usr/share/games/quiz.db/bard OLD_FILES+=usr/share/games/quiz.db/chinese OLD_FILES+=usr/share/games/quiz.db/collectives OLD_FILES+=usr/share/games/quiz.db/ed OLD_FILES+=usr/share/games/quiz.db/elements OLD_FILES+=usr/share/games/quiz.db/europe OLD_FILES+=usr/share/games/quiz.db/flowers OLD_FILES+=usr/share/games/quiz.db/greek OLD_FILES+=usr/share/games/quiz.db/inca OLD_FILES+=usr/share/games/quiz.db/index OLD_FILES+=usr/share/games/quiz.db/latin OLD_FILES+=usr/share/games/quiz.db/locomotive OLD_FILES+=usr/share/games/quiz.db/midearth OLD_FILES+=usr/share/games/quiz.db/morse OLD_FILES+=usr/share/games/quiz.db/murders OLD_FILES+=usr/share/games/quiz.db/poetry OLD_FILES+=usr/share/games/quiz.db/posneg OLD_FILES+=usr/share/games/quiz.db/pres OLD_FILES+=usr/share/games/quiz.db/province OLD_FILES+=usr/share/games/quiz.db/seq-easy OLD_FILES+=usr/share/games/quiz.db/seq-hard OLD_FILES+=usr/share/games/quiz.db/sexes OLD_FILES+=usr/share/games/quiz.db/sov OLD_FILES+=usr/share/games/quiz.db/spell OLD_FILES+=usr/share/games/quiz.db/state OLD_FILES+=usr/share/games/quiz.db/trek OLD_FILES+=usr/share/games/quiz.db/ucc OLD_FILES+=usr/share/games/cribbage.instr OLD_FILES+=usr/share/games/fish.instr OLD_FILES+=usr/share/games/wump.info OLD_FILES+=usr/games/hide/adventure OLD_FILES+=usr/games/hide/arithmetic OLD_FILES+=usr/games/hide/atc OLD_FILES+=usr/games/hide/backgammon OLD_FILES+=usr/games/hide/teachgammon OLD_FILES+=usr/games/hide/battlestar OLD_FILES+=usr/games/hide/bs OLD_FILES+=usr/games/hide/canfield OLD_FILES+=usr/games/hide/cribbage OLD_FILES+=usr/games/hide/fish OLD_FILES+=usr/games/hide/hack OLD_FILES+=usr/games/hide/hangman OLD_FILES+=usr/games/hide/larn OLD_FILES+=usr/games/hide/mille OLD_FILES+=usr/games/hide/phantasia OLD_FILES+=usr/games/hide/quiz OLD_FILES+=usr/games/hide/robots OLD_FILES+=usr/games/hide/rogue OLD_FILES+=usr/games/hide/sail OLD_FILES+=usr/games/hide/snake OLD_FILES+=usr/games/hide/trek OLD_FILES+=usr/games/hide/worm OLD_FILES+=usr/games/hide/wump OLD_FILES+=usr/games/adventure OLD_FILES+=usr/games/arithmetic OLD_FILES+=usr/games/atc OLD_FILES+=usr/games/backgammon OLD_FILES+=usr/games/teachgammon OLD_FILES+=usr/games/battlestar OLD_FILES+=usr/games/bs OLD_FILES+=usr/games/canfield OLD_FILES+=usr/games/cfscores OLD_FILES+=usr/games/cribbage OLD_FILES+=usr/games/dm OLD_FILES+=usr/games/fish OLD_FILES+=usr/games/hack OLD_FILES+=usr/games/hangman OLD_FILES+=usr/games/larn OLD_FILES+=usr/games/mille OLD_FILES+=usr/games/phantasia OLD_FILES+=usr/games/piano OLD_FILES+=usr/games/pig OLD_FILES+=usr/games/quiz OLD_FILES+=usr/games/rain OLD_FILES+=usr/games/robots OLD_FILES+=usr/games/rogue OLD_FILES+=usr/games/sail OLD_FILES+=usr/games/snake OLD_FILES+=usr/games/snscore OLD_FILES+=usr/games/trek OLD_FILES+=usr/games/wargames OLD_FILES+=usr/games/worm OLD_FILES+=usr/games/worms OLD_FILES+=usr/games/wump OLD_FILES+=sbin/mount_reiserfs OLD_FILES+=usr/include/cam/cam_extend.h OLD_FILES+=usr/include/dev/wi/wi_hostap.h OLD_FILES+=usr/include/disktab.h OLD_FILES+=usr/include/g++/FlexLexer.h OLD_FILES+=usr/include/g++/PlotFile.h OLD_FILES+=usr/include/g++/SFile.h OLD_FILES+=usr/include/g++/_G_config.h OLD_FILES+=usr/include/g++/algo.h OLD_FILES+=usr/include/g++/algobase.h OLD_FILES+=usr/include/g++/algorithm OLD_FILES+=usr/include/g++/alloc.h OLD_FILES+=usr/include/g++/bitset OLD_FILES+=usr/include/g++/builtinbuf.h OLD_FILES+=usr/include/g++/bvector.h OLD_FILES+=usr/include/g++/cassert OLD_FILES+=usr/include/g++/cctype OLD_FILES+=usr/include/g++/cerrno OLD_FILES+=usr/include/g++/cfloat OLD_FILES+=usr/include/g++/ciso646 OLD_FILES+=usr/include/g++/climits OLD_FILES+=usr/include/g++/clocale OLD_FILES+=usr/include/g++/cmath OLD_FILES+=usr/include/g++/complex OLD_FILES+=usr/include/g++/complex.h OLD_FILES+=usr/include/g++/csetjmp OLD_FILES+=usr/include/g++/csignal OLD_FILES+=usr/include/g++/cstdarg OLD_FILES+=usr/include/g++/cstddef OLD_FILES+=usr/include/g++/cstdio OLD_FILES+=usr/include/g++/cstdlib OLD_FILES+=usr/include/g++/cstring OLD_FILES+=usr/include/g++/ctime OLD_FILES+=usr/include/g++/cwchar OLD_FILES+=usr/include/g++/cwctype OLD_FILES+=usr/include/g++/defalloc.h OLD_FILES+=usr/include/g++/deque OLD_FILES+=usr/include/g++/deque.h OLD_FILES+=usr/include/g++/editbuf.h OLD_FILES+=usr/include/g++/exception OLD_FILES+=usr/include/g++/floatio.h OLD_FILES+=usr/include/g++/fstream OLD_FILES+=usr/include/g++/fstream.h OLD_FILES+=usr/include/g++/function.h OLD_FILES+=usr/include/g++/functional OLD_FILES+=usr/include/g++/hash_map OLD_FILES+=usr/include/g++/hash_map.h OLD_FILES+=usr/include/g++/hash_set OLD_FILES+=usr/include/g++/hash_set.h OLD_FILES+=usr/include/g++/hashtable.h OLD_FILES+=usr/include/g++/heap.h OLD_FILES+=usr/include/g++/indstream.h OLD_FILES+=usr/include/g++/iolibio.h OLD_FILES+=usr/include/g++/iomanip OLD_FILES+=usr/include/g++/iomanip.h OLD_FILES+=usr/include/g++/iosfwd OLD_FILES+=usr/include/g++/iostdio.h OLD_FILES+=usr/include/g++/iostream OLD_FILES+=usr/include/g++/iostream.h OLD_FILES+=usr/include/g++/iostreamP.h OLD_FILES+=usr/include/g++/istream.h OLD_FILES+=usr/include/g++/iterator OLD_FILES+=usr/include/g++/iterator.h OLD_FILES+=usr/include/g++/libio.h OLD_FILES+=usr/include/g++/libioP.h OLD_FILES+=usr/include/g++/list OLD_FILES+=usr/include/g++/list.h OLD_FILES+=usr/include/g++/map OLD_FILES+=usr/include/g++/map.h OLD_FILES+=usr/include/g++/memory OLD_FILES+=usr/include/g++/multimap.h OLD_FILES+=usr/include/g++/multiset.h OLD_FILES+=usr/include/g++/new OLD_FILES+=usr/include/g++/new.h OLD_FILES+=usr/include/g++/numeric OLD_FILES+=usr/include/g++/ostream.h OLD_FILES+=usr/include/g++/pair.h OLD_FILES+=usr/include/g++/parsestream.h OLD_FILES+=usr/include/g++/pfstream.h OLD_FILES+=usr/include/g++/procbuf.h OLD_FILES+=usr/include/g++/pthread_alloc OLD_FILES+=usr/include/g++/pthread_alloc.h OLD_FILES+=usr/include/g++/queue OLD_FILES+=usr/include/g++/rope OLD_FILES+=usr/include/g++/rope.h OLD_FILES+=usr/include/g++/ropeimpl.h OLD_FILES+=usr/include/g++/set OLD_FILES+=usr/include/g++/set.h OLD_FILES+=usr/include/g++/slist OLD_FILES+=usr/include/g++/slist.h OLD_FILES+=usr/include/g++/sstream OLD_FILES+=usr/include/g++/stack OLD_FILES+=usr/include/g++/stack.h OLD_FILES+=usr/include/g++/std/bastring.cc OLD_FILES+=usr/include/g++/std/bastring.h OLD_FILES+=usr/include/g++/std/complext.cc OLD_FILES+=usr/include/g++/std/complext.h OLD_FILES+=usr/include/g++/std/dcomplex.h OLD_FILES+=usr/include/g++/std/fcomplex.h OLD_FILES+=usr/include/g++/std/gslice.h OLD_FILES+=usr/include/g++/std/gslice_array.h OLD_FILES+=usr/include/g++/std/indirect_array.h OLD_FILES+=usr/include/g++/std/ldcomplex.h OLD_FILES+=usr/include/g++/std/mask_array.h OLD_FILES+=usr/include/g++/std/slice.h OLD_FILES+=usr/include/g++/std/slice_array.h OLD_FILES+=usr/include/g++/std/std_valarray.h OLD_FILES+=usr/include/g++/std/straits.h OLD_FILES+=usr/include/g++/std/valarray_array.h OLD_FILES+=usr/include/g++/std/valarray_array.tcc OLD_FILES+=usr/include/g++/std/valarray_meta.h OLD_FILES+=usr/include/g++/stdexcept OLD_FILES+=usr/include/g++/stdiostream.h OLD_FILES+=usr/include/g++/stl.h OLD_FILES+=usr/include/g++/stl_algo.h OLD_FILES+=usr/include/g++/stl_algobase.h OLD_FILES+=usr/include/g++/stl_alloc.h OLD_FILES+=usr/include/g++/stl_bvector.h OLD_FILES+=usr/include/g++/stl_config.h OLD_FILES+=usr/include/g++/stl_construct.h OLD_FILES+=usr/include/g++/stl_deque.h OLD_FILES+=usr/include/g++/stl_function.h OLD_FILES+=usr/include/g++/stl_hash_fun.h OLD_FILES+=usr/include/g++/stl_hash_map.h OLD_FILES+=usr/include/g++/stl_hash_set.h OLD_FILES+=usr/include/g++/stl_hashtable.h OLD_FILES+=usr/include/g++/stl_heap.h OLD_FILES+=usr/include/g++/stl_iterator.h OLD_FILES+=usr/include/g++/stl_list.h OLD_FILES+=usr/include/g++/stl_map.h OLD_FILES+=usr/include/g++/stl_multimap.h OLD_FILES+=usr/include/g++/stl_multiset.h OLD_FILES+=usr/include/g++/stl_numeric.h OLD_FILES+=usr/include/g++/stl_pair.h OLD_FILES+=usr/include/g++/stl_queue.h OLD_FILES+=usr/include/g++/stl_raw_storage_iter.h OLD_FILES+=usr/include/g++/stl_relops.h OLD_FILES+=usr/include/g++/stl_rope.h OLD_FILES+=usr/include/g++/stl_set.h OLD_FILES+=usr/include/g++/stl_slist.h OLD_FILES+=usr/include/g++/stl_stack.h OLD_FILES+=usr/include/g++/stl_tempbuf.h OLD_FILES+=usr/include/g++/stl_tree.h OLD_FILES+=usr/include/g++/stl_uninitialized.h OLD_FILES+=usr/include/g++/stl_vector.h OLD_FILES+=usr/include/g++/stream.h OLD_FILES+=usr/include/g++/streambuf.h OLD_FILES+=usr/include/g++/strfile.h OLD_FILES+=usr/include/g++/string OLD_FILES+=usr/include/g++/strstream OLD_FILES+=usr/include/g++/strstream.h OLD_FILES+=usr/include/g++/tempbuf.h OLD_FILES+=usr/include/g++/tree.h OLD_FILES+=usr/include/g++/type_traits.h OLD_FILES+=usr/include/g++/typeinfo OLD_FILES+=usr/include/g++/utility OLD_FILES+=usr/include/g++/valarray OLD_FILES+=usr/include/g++/vector OLD_FILES+=usr/include/g++/vector.h OLD_FILES+=usr/include/gmp.h OLD_FILES+=usr/include/isc/assertions.h OLD_FILES+=usr/include/isc/ctl.h OLD_FILES+=usr/include/isc/dst.h OLD_FILES+=usr/include/isc/eventlib.h OLD_FILES+=usr/include/isc/heap.h OLD_FILES+=usr/include/isc/irpmarshall.h OLD_FILES+=usr/include/isc/list.h OLD_FILES+=usr/include/isc/logging.h OLD_FILES+=usr/include/isc/memcluster.h OLD_FILES+=usr/include/isc/misc.h OLD_FILES+=usr/include/isc/tree.h OLD_FILES+=usr/include/machine/ansi.h OLD_FILES+=usr/include/machine/apic.h OLD_FILES+=usr/include/machine/asc_ioctl.h OLD_FILES+=usr/include/machine/asnames.h OLD_FILES+=usr/include/machine/bus_at386.h OLD_FILES+=usr/include/machine/bus_memio.h OLD_FILES+=usr/include/machine/bus_pc98.h OLD_FILES+=usr/include/machine/bus_pio.h OLD_FILES+=usr/include/machine/cdk.h OLD_FILES+=usr/include/machine/comstats.h OLD_FILES+=usr/include/machine/console.h OLD_FILES+=usr/include/machine/critical.h OLD_FILES+=usr/include/machine/cronyx.h OLD_FILES+=usr/include/machine/dvcfg.h OLD_FILES+=usr/include/machine/globaldata.h OLD_FILES+=usr/include/machine/globals.h OLD_FILES+=usr/include/machine/gsc.h OLD_FILES+=usr/include/machine/i4b_isppp.h OLD_FILES+=usr/include/machine/if_wavelan_ieee.h OLD_FILES+=usr/include/machine/iic.h OLD_FILES+=usr/include/machine/ioctl_ctx.h OLD_FILES+=usr/include/machine/ioctl_fd.h OLD_FILES+=usr/include/machine/ipl.h OLD_FILES+=usr/include/machine/lock.h OLD_FILES+=usr/include/machine/mouse.h OLD_FILES+=usr/include/machine/mpapic.h OLD_FILES+=usr/include/machine/mtpr.h OLD_FILES+=usr/include/machine/pc/msdos.h OLD_FILES+=usr/include/machine/physio_proc.h OLD_FILES+=usr/include/machine/smb.h OLD_FILES+=usr/include/machine/spigot.h OLD_FILES+=usr/include/machine/types.h OLD_FILES+=usr/include/machine/uc_device.h OLD_FILES+=usr/include/machine/ultrasound.h OLD_FILES+=usr/include/machine/wtio.h OLD_FILES+=usr/include/msdosfs/bootsect.h OLD_FILES+=usr/include/msdosfs/bpb.h OLD_FILES+=usr/include/msdosfs/denode.h OLD_FILES+=usr/include/msdosfs/direntry.h OLD_FILES+=usr/include/msdosfs/fat.h OLD_FILES+=usr/include/msdosfs/msdosfsmount.h OLD_FILES+=usr/include/net/hostcache.h OLD_FILES+=usr/include/net/if_faith.h OLD_FILES+=usr/include/net/if_ieee80211.h OLD_FILES+=usr/include/net/if_tunvar.h OLD_FILES+=usr/include/net/intrq.h OLD_FILES+=usr/include/netatm/kern_include.h OLD_FILES+=usr/include/netinet/if_fddi.h OLD_FILES+=usr/include/netinet/in_hostcache.h OLD_FILES+=usr/include/netinet/ip_flow.h OLD_FILES+=usr/include/netinet/ip_fw2.h OLD_FILES+=usr/include/netinet6/in6_prefix.h OLD_FILES+=usr/include/netns/idp.h OLD_FILES+=usr/include/netns/idp_var.h OLD_FILES+=usr/include/netns/ns.h OLD_FILES+=usr/include/netns/ns_error.h OLD_FILES+=usr/include/netns/ns_if.h OLD_FILES+=usr/include/netns/ns_pcb.h OLD_FILES+=usr/include/netns/sp.h OLD_FILES+=usr/include/netns/spidp.h OLD_FILES+=usr/include/netns/spp_debug.h OLD_FILES+=usr/include/netns/spp_timer.h OLD_FILES+=usr/include/netns/spp_var.h OLD_FILES+=usr/include/nfs/nfs.h OLD_FILES+=usr/include/nfs/nfsm_subs.h OLD_FILES+=usr/include/nfs/nfsmount.h OLD_FILES+=usr/include/nfs/nfsnode.h OLD_FILES+=usr/include/nfs/nfsrtt.h OLD_FILES+=usr/include/nfs/nfsrvcache.h OLD_FILES+=usr/include/nfs/nfsv2.h OLD_FILES+=usr/include/nfs/nqnfs.h OLD_FILES+=usr/include/ntfs/ntfs.h OLD_FILES+=usr/include/ntfs/ntfs_compr.h OLD_FILES+=usr/include/ntfs/ntfs_ihash.h OLD_FILES+=usr/include/ntfs/ntfs_inode.h OLD_FILES+=usr/include/ntfs/ntfs_subr.h OLD_FILES+=usr/include/ntfs/ntfs_vfsops.h OLD_FILES+=usr/include/ntfs/ntfsmount.h OLD_FILES+=usr/include/nwfs/nwfs.h OLD_FILES+=usr/include/nwfs/nwfs_mount.h OLD_FILES+=usr/include/nwfs/nwfs_node.h OLD_FILES+=usr/include/nwfs/nwfs_subr.h OLD_FILES+=usr/include/posix4/_semaphore.h OLD_FILES+=usr/include/posix4/aio.h OLD_FILES+=usr/include/posix4/ksem.h OLD_FILES+=usr/include/posix4/mqueue.h OLD_FILES+=usr/include/posix4/posix4.h OLD_FILES+=usr/include/posix4/sched.h OLD_FILES+=usr/include/posix4/semaphore.h OLD_DIRS+=usr/include/posix4 OLD_FILES+=usr/include/security/_pam_compat.h OLD_FILES+=usr/include/security/_pam_macros.h OLD_FILES+=usr/include/security/_pam_types.h OLD_FILES+=usr/include/security/pam_malloc.h OLD_FILES+=usr/include/security/pam_misc.h OLD_FILES+=usr/include/skey.h OLD_FILES+=usr/include/strhash.h OLD_FILES+=usr/include/struct.h OLD_FILES+=usr/include/sys/_label.h OLD_FILES+=usr/include/sys/_posix.h OLD_FILES+=usr/include/sys/bus_private.h OLD_FILES+=usr/include/sys/ccdvar.h OLD_FILES+=usr/include/sys/diskslice.h OLD_FILES+=usr/include/sys/dmap.h OLD_FILES+=usr/include/sys/inttypes.h OLD_FILES+=usr/include/sys/jumbo.h OLD_FILES+=usr/include/sys/mac_policy.h OLD_FILES+=usr/include/sys/pbioio.h OLD_FILES+=usr/include/sys/syscall-hide.h OLD_FILES+=usr/include/sys/tprintf.h OLD_FILES+=usr/include/sys/vnioctl.h OLD_FILES+=usr/include/sys/wormio.h OLD_FILES+=usr/include/telnet.h OLD_FILES+=usr/include/ufs/mfs/mfs_extern.h OLD_FILES+=usr/include/ufs/mfs/mfsnode.h OLD_FILES+=usr/include/values.h OLD_FILES+=usr/include/vm/vm_zone.h OLD_FILES+=usr/share/examples/etc/usbd.conf OLD_FILES+=usr/share/examples/meteor/README OLD_FILES+=usr/share/examples/meteor/rgb16.c OLD_FILES+=usr/share/examples/meteor/rgb24.c OLD_FILES+=usr/share/examples/meteor/test-n.c OLD_FILES+=usr/share/examples/meteor/yuvpk.c OLD_FILES+=usr/share/examples/meteor/yuvpl.c OLD_FILES+=usr/share/examples/worm/README OLD_FILES+=usr/share/examples/worm/makecdfs.sh OLD_FILES+=usr/share/groff_font/devlj4/Makefile OLD_FILES+=usr/share/groff_font/devlj4/text.map OLD_FILES+=usr/share/groff_font/devlj4/special.map OLD_FILES+=usr/share/misc/nslookup.help OLD_FILES+=usr/share/sendmail/cf/feature/nodns.m4 OLD_FILES+=usr/share/syscons/keymaps/lat-amer.kbd OLD_FILES+=usr/share/vi/catalog/ru_SU.KOI8-R OLD_FILES+=usr/share/zoneinfo/Africa/Timbuktu OLD_FILES+=usr/share/zoneinfo/Africa/Asmera OLD_FILES+=usr/share/zoneinfo/America/Buenos_Aires OLD_FILES+=usr/share/zoneinfo/America/Cordoba OLD_FILES+=usr/share/zoneinfo/America/Jujuy OLD_FILES+=usr/share/zoneinfo/America/Catamarca OLD_FILES+=usr/share/zoneinfo/America/Mendoza OLD_FILES+=usr/share/zoneinfo/America/Indianapolis OLD_FILES+=usr/share/zoneinfo/America/Louisville OLD_FILES+=usr/share/zoneinfo/America/Argentina/ComodRivadavia OLD_FILES+=usr/share/zoneinfo/Atlantic/Faeroe OLD_FILES+=usr/share/zoneinfo/Europe/Belfast OLD_FILES+=usr/share/zoneinfo/Pacific/Yap OLD_FILES+=usr/share/zoneinfo/SystemV/YST9 OLD_FILES+=usr/share/zoneinfo/SystemV/PST8 OLD_FILES+=usr/share/zoneinfo/SystemV/EST5EDT OLD_FILES+=usr/share/zoneinfo/SystemV/CST6CDT OLD_FILES+=usr/share/zoneinfo/SystemV/MST7MDT OLD_FILES+=usr/share/zoneinfo/SystemV/PST8PDT OLD_FILES+=usr/share/zoneinfo/SystemV/YST9YDT OLD_FILES+=usr/share/zoneinfo/SystemV/HST10 OLD_FILES+=usr/share/zoneinfo/SystemV/MST7 OLD_FILES+=usr/share/zoneinfo/SystemV/EST5 OLD_FILES+=usr/share/zoneinfo/SystemV/AST4ADT OLD_FILES+=usr/share/zoneinfo/SystemV/CST6 OLD_FILES+=usr/share/zoneinfo/SystemV/AST4 OLD_FILES+=usr/share/doc/ntp/accopt.htm OLD_FILES+=usr/share/doc/ntp/assoc.htm OLD_FILES+=usr/share/doc/ntp/audio.htm OLD_FILES+=usr/share/doc/ntp/authopt.htm OLD_FILES+=usr/share/doc/ntp/biblio.htm OLD_FILES+=usr/share/doc/ntp/build.htm OLD_FILES+=usr/share/doc/ntp/clockopt.htm OLD_FILES+=usr/share/doc/ntp/config.htm OLD_FILES+=usr/share/doc/ntp/confopt.htm OLD_FILES+=usr/share/doc/ntp/copyright.htm OLD_FILES+=usr/share/doc/ntp/debug.htm OLD_FILES+=usr/share/doc/ntp/driver1.htm OLD_FILES+=usr/share/doc/ntp/driver10.htm OLD_FILES+=usr/share/doc/ntp/driver11.htm OLD_FILES+=usr/share/doc/ntp/driver12.htm OLD_FILES+=usr/share/doc/ntp/driver16.htm OLD_FILES+=usr/share/doc/ntp/driver18.htm OLD_FILES+=usr/share/doc/ntp/driver19.htm OLD_FILES+=usr/share/doc/ntp/driver2.htm OLD_FILES+=usr/share/doc/ntp/driver20.htm OLD_FILES+=usr/share/doc/ntp/driver22.htm OLD_FILES+=usr/share/doc/ntp/driver23.htm OLD_FILES+=usr/share/doc/ntp/driver24.htm OLD_FILES+=usr/share/doc/ntp/driver26.htm OLD_FILES+=usr/share/doc/ntp/driver27.htm OLD_FILES+=usr/share/doc/ntp/driver28.htm OLD_FILES+=usr/share/doc/ntp/driver29.htm OLD_FILES+=usr/share/doc/ntp/driver3.htm OLD_FILES+=usr/share/doc/ntp/driver30.htm OLD_FILES+=usr/share/doc/ntp/driver32.htm OLD_FILES+=usr/share/doc/ntp/driver33.htm OLD_FILES+=usr/share/doc/ntp/driver34.htm OLD_FILES+=usr/share/doc/ntp/driver35.htm OLD_FILES+=usr/share/doc/ntp/driver36.htm OLD_FILES+=usr/share/doc/ntp/driver37.htm OLD_FILES+=usr/share/doc/ntp/driver4.htm OLD_FILES+=usr/share/doc/ntp/driver5.htm OLD_FILES+=usr/share/doc/ntp/driver6.htm OLD_FILES+=usr/share/doc/ntp/driver7.htm OLD_FILES+=usr/share/doc/ntp/driver8.htm OLD_FILES+=usr/share/doc/ntp/driver9.htm OLD_FILES+=usr/share/doc/ntp/exec.htm OLD_FILES+=usr/share/doc/ntp/extern.htm OLD_FILES+=usr/share/doc/ntp/gadget.htm OLD_FILES+=usr/share/doc/ntp/hints.htm OLD_FILES+=usr/share/doc/ntp/howto.htm OLD_FILES+=usr/share/doc/ntp/htmlprimer.htm OLD_FILES+=usr/share/doc/ntp/index.htm OLD_FILES+=usr/share/doc/ntp/kern.htm OLD_FILES+=usr/share/doc/ntp/kernpps.htm OLD_FILES+=usr/share/doc/ntp/ldisc.htm OLD_FILES+=usr/share/doc/ntp/measure.htm OLD_FILES+=usr/share/doc/ntp/miscopt.htm OLD_FILES+=usr/share/doc/ntp/monopt.htm OLD_FILES+=usr/share/doc/ntp/mx4200data.htm OLD_FILES+=usr/share/doc/ntp/notes.htm OLD_FILES+=usr/share/doc/ntp/ntpd.htm OLD_FILES+=usr/share/doc/ntp/ntpdate.htm OLD_FILES+=usr/share/doc/ntp/ntpdc.htm OLD_FILES+=usr/share/doc/ntp/ntpq.htm OLD_FILES+=usr/share/doc/ntp/ntptime.htm OLD_FILES+=usr/share/doc/ntp/ntptrace.htm OLD_FILES+=usr/share/doc/ntp/parsedata.htm OLD_FILES+=usr/share/doc/ntp/parsenew.htm OLD_FILES+=usr/share/doc/ntp/patches.htm OLD_FILES+=usr/share/doc/ntp/porting.htm OLD_FILES+=usr/share/doc/ntp/pps.htm OLD_FILES+=usr/share/doc/ntp/prefer.htm OLD_FILES+=usr/share/doc/ntp/qth.htm OLD_FILES+=usr/share/doc/ntp/quick.htm OLD_FILES+=usr/share/doc/ntp/rdebug.htm OLD_FILES+=usr/share/doc/ntp/refclock.htm OLD_FILES+=usr/share/doc/ntp/release.htm OLD_FILES+=usr/share/doc/ntp/tickadj.htm OLD_FILES+=usr/share/doc/papers/nqnfs.ascii.gz OLD_FILES+=usr/share/doc/papers/px.ascii.gz OLD_FILES+=usr/share/man/man3/exp10.3.gz OLD_FILES+=usr/share/man/man3/exp10f.3.gz OLD_FILES+=usr/share/man/man3/fpsetsticky.3.gz OLD_FILES+=usr/share/man/man3/gss_krb5_compat_des3_mic.3.gz OLD_FILES+=usr/share/man/man3/gss_krb5_copy_ccache.3.gz OLD_FILES+=usr/share/man/man3/mac_is_present_np.3.gz OLD_FILES+=usr/share/man/man3/mbmb.3.gz OLD_FILES+=usr/share/man/man3/setrunelocale.3.gz OLD_FILES+=usr/share/man/man5/usbd.conf.5.gz .if ${TARGET_ARCH} != "i386" && ${TARGET_ARCH} != "amd64" OLD_FILES+=usr/share/man/man8/boot_i386.8.gz .endif .if ${TARGET_ARCH} != "powerpc" && ${TARGET_ARCH} != "powerpc64" && ${TARGET_ARCH} != "sparc64" OLD_FILES+=usr/share/man/man8/ofwdump.8.gz .endif OLD_FILES+=usr/share/man/man8/mount_reiserfs.8.gz OLD_FILES+=usr/share/man/man9/VFS_START.9.gz OLD_FILES+=usr/share/man/man9/cpu_critical_exit.9.gz OLD_FILES+=usr/share/man/man9/cpu_critical_enter.9.gz OLD_FILES+=usr/share/info/annotate.info.gz OLD_FILES+=usr/share/info/tar.info.gz OLD_FILES+=usr/share/bsnmp/defs/tree.def OLD_FILES+=usr/share/bsnmp/defs/mibII_tree.def OLD_FILES+=usr/share/bsnmp/defs/netgraph_tree.def OLD_FILES+=usr/share/bsnmp/mibs/FOKUS-MIB.txt OLD_FILES+=usr/share/bsnmp/mibs/BEGEMOT-MIB.txt OLD_FILES+=usr/share/bsnmp/mibs/BEGEMOT-SNMPD.txt OLD_FILES+=usr/share/bsnmp/mibs/BEGEMOT-NETGRAPH.txt OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.x OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xbn OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xn OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xr OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xs OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xu OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xc OLD_FILES+=usr/libdata/ldscripts/elf64_sparc.xsc OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.x OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xbn OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xn OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xr OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xs OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xu OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xc OLD_FILES+=usr/libdata/ldscripts/elf32_sparc.xsc OLD_FILES+=usr/libdata/msdosfs/iso22dos OLD_FILES+=usr/libdata/msdosfs/iso72dos OLD_FILES+=usr/libdata/msdosfs/koi2dos OLD_FILES+=usr/libdata/msdosfs/koi8u2dos # The following files are *not* obsolete, they just don't get touched at # install, so don't add them: # - boot/loader.rc # - usr/share/tmac/man.local # - usr/share/tmac/mm/locale # - usr/share/tmac/mm/se_locale # - var/yp/Makefile # 20071120: shared library version bump OLD_LIBS+=usr/lib/libasn1.so.8 OLD_LIBS+=usr/lib/libgssapi.so.8 OLD_LIBS+=usr/lib/libgssapi_krb5.so.8 OLD_LIBS+=usr/lib/libhdb.so.8 OLD_LIBS+=usr/lib/libkadm5clnt.so.8 OLD_LIBS+=usr/lib/libkadm5srv.so.8 OLD_LIBS+=usr/lib/libkafs5.so.8 OLD_LIBS+=usr/lib/libkrb5.so.8 OLD_LIBS+=usr/lib/libobjc.so.2 OLD_LIBS+=usr/lib32/libgssapi.so.8 OLD_LIBS+=usr/lib32/libobjc.so.2 # 20070519: GCC 4.2 OLD_LIBS+=usr/lib/libg2c.a OLD_LIBS+=usr/lib/libg2c.so OLD_LIBS+=usr/lib/libg2c.so.2 OLD_LIBS+=usr/lib/libg2c_p.a OLD_LIBS+=usr/lib/libgcc_pic.a OLD_LIBS+=usr/lib32/libg2c.a OLD_LIBS+=usr/lib32/libg2c.so OLD_LIBS+=usr/lib32/libg2c.so.2 OLD_LIBS+=usr/lib32/libg2c_p.a OLD_LIBS+=usr/lib32/libgcc_pic.a # 20060729: OpenSSL 0.9.7e -> 0.9.8b upgrade OLD_LIBS+=lib/libcrypto.so.4 OLD_LIBS+=usr/lib/libssl.so.4 OLD_LIBS+=usr/lib32/libcrypto.so.4 OLD_LIBS+=usr/lib32/libssl.so.4 # 20060521: gethostbyaddr(3) ABI change OLD_LIBS+=usr/lib/libroken.so.8 OLD_LIBS+=lib/libatm.so.3 OLD_LIBS+=lib/libc.so.6 OLD_LIBS+=lib/libutil.so.5 OLD_LIBS+=usr/lib32/libatm.so.3 OLD_LIBS+=usr/lib32/libc.so.6 OLD_LIBS+=usr/lib32/libutil.so.5 # 20060413: shared library moved to /usr/lib OLD_LIBS+=lib/libgpib.so.1 # 20060413: libpcap.so.4 moved to /lib/ OLD_LIBS+=usr/lib/libpcap.so.4 # 20060412: libpthread.so.2 moved to /lib/ OLD_LIBS+=usr/lib/libpthread.so.2 # 20060127: revert libdisk to static-only OLD_LIBS+=usr/lib/libdisk.so.3 # 20051027: libc_r discontinued (removed 20101113) OLD_LIBS+=usr/lib/libc_r.a OLD_LIBS+=usr/lib/libc_r.so OLD_LIBS+=usr/lib/libc_r.so.7 OLD_LIBS+=usr/lib/libc_r_p.a OLD_LIBS+=usr/lib32/libc_r.a OLD_LIBS+=usr/lib32/libc_r.so OLD_LIBS+=usr/lib32/libc_r.so.7 OLD_LIBS+=usr/lib32/libc_r_p.a # 20050722: bump for 6.0-RELEASE OLD_LIBS+=lib/libalias.so.4 OLD_LIBS+=lib/libatm.so.2 OLD_LIBS+=lib/libbegemot.so.1 OLD_LIBS+=lib/libbsdxml.so.1 OLD_LIBS+=lib/libbsnmp.so.2 OLD_LIBS+=lib/libc.so.5 OLD_LIBS+=lib/libcam.so.2 OLD_LIBS+=lib/libcrypt.so.2 OLD_LIBS+=lib/libcrypto.so.3 OLD_LIBS+=lib/libdevstat.so.4 OLD_LIBS+=lib/libedit.so.4 OLD_LIBS+=lib/libgeom.so.2 OLD_LIBS+=lib/libgpib.so.0 OLD_LIBS+=lib/libipsec.so.1 OLD_LIBS+=lib/libipx.so.2 OLD_LIBS+=lib/libkiconv.so.1 OLD_LIBS+=lib/libkvm.so.2 OLD_LIBS+=lib/libm.so.3 OLD_LIBS+=lib/libmd.so.2 OLD_LIBS+=lib/libncurses.so.5 OLD_LIBS+=lib/libreadline.so.5 OLD_LIBS+=lib/libsbuf.so.2 OLD_LIBS+=lib/libufs.so.2 OLD_LIBS+=lib/libutil.so.4 OLD_LIBS+=lib/libz.so.2 OLD_LIBS+=usr/lib/libarchive.so.1 OLD_LIBS+=usr/lib/libasn1.so.7 OLD_LIBS+=usr/lib/libbluetooth.so.1 OLD_LIBS+=usr/lib/libbz2.so.1 OLD_LIBS+=usr/lib/libc_r.so.5 OLD_LIBS+=usr/lib/libcalendar.so.2 OLD_LIBS+=usr/lib/libcom_err.so.2 OLD_LIBS+=usr/lib/libdevinfo.so.2 OLD_LIBS+=usr/lib/libdialog.so.4 OLD_LIBS+=usr/lib/libfetch.so.3 OLD_LIBS+=usr/lib/libform.so.2 OLD_LIBS+=usr/lib/libftpio.so.5 OLD_LIBS+=usr/lib/libg2c.so.1 OLD_LIBS+=usr/lib/libgnuregex.so.2 OLD_LIBS+=usr/lib/libgssapi.so.7 OLD_LIBS+=usr/lib/libhdb.so.7 OLD_LIBS+=usr/lib/libhistory.so.5 OLD_LIBS+=usr/lib/libkadm5clnt.so.7 OLD_LIBS+=usr/lib/libkadm5srv.so.7 OLD_LIBS+=usr/lib/libkafs5.so.7 OLD_LIBS+=usr/lib/libkrb5.so.7 OLD_LIBS+=usr/lib/libmagic.so.1 OLD_LIBS+=usr/lib/libmenu.so.2 OLD_LIBS+=usr/lib/libmilter.so.2 OLD_LIBS+=usr/lib/libmp.so.4 OLD_LIBS+=usr/lib/libncp.so.1 OLD_LIBS+=usr/lib/libnetgraph.so.1 OLD_LIBS+=usr/lib/libngatm.so.1 OLD_LIBS+=usr/lib/libobjc.so.1 OLD_LIBS+=usr/lib/libopie.so.3 OLD_LIBS+=usr/lib/libpam.so.2 OLD_LIBS+=usr/lib/libpanel.so.2 OLD_LIBS+=usr/lib/libpcap.so.3 OLD_LIBS+=usr/lib/libpmc.so.2 OLD_LIBS+=usr/lib/libpthread.so.1 OLD_LIBS+=usr/lib/libradius.so.1 OLD_LIBS+=usr/lib/libroken.so.7 OLD_LIBS+=usr/lib/librpcsvc.so.2 OLD_LIBS+=usr/lib/libsdp.so.1 OLD_LIBS+=usr/lib/libsmb.so.1 OLD_LIBS+=usr/lib/libssh.so.2 OLD_LIBS+=usr/lib/libssl.so.3 OLD_LIBS+=usr/lib/libstdc++.so.4 OLD_LIBS+=usr/lib/libtacplus.so.1 OLD_LIBS+=usr/lib/libthr.so.1 OLD_LIBS+=usr/lib/libthread_db.so.1 OLD_LIBS+=usr/lib/libugidfw.so.1 OLD_LIBS+=usr/lib/libusbhid.so.1 OLD_LIBS+=usr/lib/libvgl.so.3 OLD_LIBS+=usr/lib/libwrap.so.3 OLD_LIBS+=usr/lib/libypclnt.so.1 OLD_LIBS+=usr/lib/pam_chroot.so.2 OLD_LIBS+=usr/lib/pam_deny.so.2 OLD_LIBS+=usr/lib/pam_echo.so.2 OLD_LIBS+=usr/lib/pam_exec.so.2 OLD_LIBS+=usr/lib/pam_ftpusers.so.2 OLD_LIBS+=usr/lib/pam_group.so.2 OLD_LIBS+=usr/lib/pam_guest.so.2 OLD_LIBS+=usr/lib/pam_krb5.so.2 OLD_LIBS+=usr/lib/pam_ksu.so.2 OLD_LIBS+=usr/lib/pam_lastlog.so.2 OLD_LIBS+=usr/lib/pam_login_access.so.2 OLD_LIBS+=usr/lib/pam_nologin.so.2 OLD_LIBS+=usr/lib/pam_opie.so.2 OLD_LIBS+=usr/lib/pam_opieaccess.so.2 OLD_LIBS+=usr/lib/pam_passwdqc.so.2 OLD_LIBS+=usr/lib/pam_permit.so.2 OLD_LIBS+=usr/lib/pam_radius.so.2 OLD_LIBS+=usr/lib/pam_rhosts.so.2 OLD_LIBS+=usr/lib/pam_rootok.so.2 OLD_LIBS+=usr/lib/pam_securetty.so.2 OLD_LIBS+=usr/lib/pam_self.so.2 OLD_LIBS+=usr/lib/pam_ssh.so.2 OLD_LIBS+=usr/lib/pam_tacplus.so.2 OLD_LIBS+=usr/lib/pam_unix.so.2 OLD_LIBS+=usr/lib/snmp_atm.so.3 OLD_LIBS+=usr/lib/snmp_mibII.so.3 OLD_LIBS+=usr/lib/snmp_netgraph.so.3 OLD_LIBS+=usr/lib/snmp_pf.so.3 # 200505XX: ? OLD_LIBS+=usr/lib/snmp_atm.so.2 OLD_LIBS+=usr/lib/snmp_mibII.so.2 OLD_LIBS+=usr/lib/snmp_netgraph.so.2 OLD_LIBS+=usr/lib/snmp_pf.so.2 # 2005XXXX: not ready for primetime yet OLD_LIBS+=usr/lib/libautofs.so.1 # 200411XX: libxpg4 removal OLD_LIBS+=usr/lib/libxpg4.so.3 # 200410XX: libm compatibility fix OLD_LIBS+=lib/libm.so.2 # 20041001: version bump OLD_LIBS+=lib/libreadline.so.4 OLD_LIBS+=usr/lib/libhistory.so.4 OLD_LIBS+=usr/lib/libopie.so.2 OLD_LIBS+=usr/lib/libpcap.so.2 # 20040925: bind9 import OLD_LIBS+=usr/lib/libisc.so.1 # 200408XX OLD_LIBS+=usr/lib/snmp_netgraph.so.1 # 200404XX OLD_LIBS+=usr/lib/libsnmp.so.1 OLD_LIBS+=usr/lib/snmp_mibII.so.1 # 200309XX OLD_LIBS+=usr/lib/libasn1.so.6 OLD_LIBS+=usr/lib/libhdb.so.6 OLD_LIBS+=usr/lib/libkadm5clnt.so.6 OLD_LIBS+=usr/lib/libkadm5srv.so.6 OLD_LIBS+=usr/lib/libkrb5.so.6 OLD_LIBS+=usr/lib/libroken.so.6 # 200304XX OLD_LIBS+=usr/lib/libc.so.4 OLD_LIBS+=usr/lib/libc_r.so.4 OLD_LIBS+=usr/lib/libdevstat.so.2 OLD_LIBS+=usr/lib/libedit.so.3 OLD_LIBS+=usr/lib/libgmp.so.3 OLD_LIBS+=usr/lib/libmp.so.3 OLD_LIBS+=usr/lib/libpam.so.1 OLD_LIBS+=usr/lib/libposix1e.so.2 OLD_LIBS+=usr/lib/libskey.so.2 OLD_LIBS+=usr/lib/libusbhid.so.0 OLD_LIBS+=usr/lib/libvgl.so.2 # 200302XX OLD_LIBS+=usr/lib/libacl.so.3 OLD_LIBS+=usr/lib/libasn1.so.5 OLD_LIBS+=usr/lib/libcrypto.so.2 OLD_LIBS+=usr/lib/libgssapi.so.5 OLD_LIBS+=usr/lib/libhdb.so.5 OLD_LIBS+=usr/lib/libkadm.so.3 OLD_LIBS+=usr/lib/libkadm5clnt.so.5 OLD_LIBS+=usr/lib/libkadm5srv.so.5 OLD_LIBS+=usr/lib/libkafs.so.3 OLD_LIBS+=usr/lib/libkafs5.so.5 OLD_LIBS+=usr/lib/libkdb.so.3 OLD_LIBS+=usr/lib/libkrb.so.3 OLD_LIBS+=usr/lib/libroken.so. OLD_LIBS+=usr/lib/libssl.so.2 OLD_LIBS+=usr/lib/pam_kerberosIV.so # 200208XX OLD_LIBS+=usr/lib/libgssapi.so.4 # 200203XX OLD_LIBS+=usr/lib/libss.so.3 OLD_LIBS+=usr/lib/libusb.so.0 # 200112XX OLD_LIBS+=usr/lib/libfetch.so.2 # 200110XX OLD_LIBS+=usr/lib/libgssapi.so.3 # 200104XX OLD_LIBS+=usr/lib/libdescrypt.so.2 OLD_LIBS+=usr/lib/libscrypt.so.2 # 200102XX OLD_LIBS+=usr/lib/libcrypto.so.1 OLD_LIBS+=usr/lib/libssl.so.1 # 200009XX OLD_LIBS+=usr/lib/libRSAglue.so.1 OLD_LIBS+=usr/lib/librsaINTL.so.1 OLD_LIBS+=usr/lib/librsaUSA.so.1 # 200006XX OLD_LIBS+=usr/lib/libalias.so.3 OLD_LIBS+=usr/lib/libfetch.so.1 OLD_LIBS+=usr/lib/libipsec.so.0 # 200005XX OLD_LIBS+=usr/lib/libxpg4.so.2 # 200002XX OLD_LIBS+=usr/lib/libc.so.3 OLD_LIBS+=usr/lib/libcurses.so.2 OLD_LIBS+=usr/lib/libdialog.so.3 OLD_LIBS+=usr/lib/libedit.so.2 OLD_LIBS+=usr/lib/libf2c.so.2 OLD_LIBS+=usr/lib/libftpio.so.4 OLD_LIBS+=usr/lib/libg++.so.4 OLD_LIBS+=usr/lib/libhistory.so.3 OLD_LIBS+=usr/lib/libmytinfo.so.2 OLD_LIBS+=usr/lib/libncurses.so.3 OLD_LIBS+=usr/lib/libreadline.so.3 OLD_LIBS+=usr/lib/libss.so.2 OLD_LIBS+=usr/lib/libtermcap.so.2 OLD_LIBS+=usr/lib/libutil.so.2 OLD_LIBS+=usr/lib/libvgl.so.1 OLD_LIBS+=usr/lib/libwrap.so.2 # 199909XX OLD_LIBS+=usr/lib/libc_r.so.3 # ??? OLD_LIBS+=usr/lib/libarchive.so.2 OLD_LIBS+=usr/lib/libbsnmp.so.1 OLD_LIBS+=usr/lib/libc_r.so.6 OLD_LIBS+=usr/lib32/libarchive.so.2 OLD_LIBS+=usr/lib32/libc_r.so.6 OLD_LIBS+=usr/lib/libcipher.so.2 OLD_LIBS+=usr/lib/libgssapi.so.6 OLD_LIBS+=usr/lib/libkse.so.1 OLD_LIBS+=usr/lib/liblwres.so.3 OLD_LIBS+=usr/lib/pam_ftp.so.2 # 20131013: Removal of the ATF tools OLD_DIRS+=etc/atf OLD_DIRS+=usr/share/examples/atf OLD_DIRS+=usr/share/xml/atf OLD_DIRS+=usr/share/xml OLD_DIRS+=usr/share/xsl/atf OLD_DIRS+=usr/share/xsl # 20040925: bind9 import OLD_DIRS+=usr/share/doc/bind/html OLD_DIRS+=usr/share/doc/bind/misc OLD_DIRS+=usr/share/doc/bind/ # ??? OLD_DIRS+=usr/include/g++/std OLD_DIRS+=usr/include/msdosfs OLD_DIRS+=usr/include/ntfs OLD_DIRS+=usr/include/nwfs OLD_DIRS+=usr/include/ufs/mfs # 20011001: UUCP migration to ports OLD_DIRS+=usr/libexec/uucp .include "tools/build/mk/OptionalObsoleteFiles.inc" Index: head/contrib/atf/bconfig.h =================================================================== --- head/contrib/atf/bconfig.h (revision 273928) +++ head/contrib/atf/bconfig.h (nonexistent) @@ -1,93 +0,0 @@ -/* bconfig.h. Generated from bconfig.h.in by configure. */ -/* bconfig.h.in. Generated from configure.ac by autoheader. */ - -/* Define to 1 if basename takes a constant pointer */ -#define HAVE_CONST_BASENAME 1 - -/* Define to 1 if dirname takes a constant pointer */ -#define HAVE_CONST_DIRNAME 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_DLFCN_H 1 - -/* Define to 1 if getcwd(NULL, 0) works */ -#define HAVE_GETCWD_DYN 1 - -/* Define to 1 if getopt allows a + sign for POSIX behavior */ -/* #undef HAVE_GNU_GETOPT */ - -/* Define to 1 if you have the header file. */ -#define HAVE_INTTYPES_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_MEMORY_H 1 - -/* Define to 1 if getopt has optreset */ -#define HAVE_OPTRESET 1 - -/* Define to 1 if you have the `putenv' function. */ -#define HAVE_PUTENV 1 - -/* Define to 1 if you have the `setenv' function. */ -#define HAVE_SETENV 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDLIB_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRING_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - -/* Define to 1 if you have the `unsetenv' function. */ -#define HAVE_UNSETENV 1 - -/* Define to 1 if vsnprintf is in std */ -/* #undef HAVE_VSNPRINTF_IN_STD */ - -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#define LT_OBJDIR ".libs/" - -/* Name of package */ -#define PACKAGE "atf" - -/* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "atf-devel@NetBSD.org" - -/* Define to the copyright string applicable to this package. */ -#define PACKAGE_COPYRIGHT "Copyright (c) 2007-2012 The NetBSD Foundation, Inc." - -/* Define to the full name of this package. */ -#define PACKAGE_NAME "Automated Testing Framework" - -/* Define to the full name and version of this package. */ -#define PACKAGE_STRING "Automated Testing Framework 0.20" - -/* Define to the one symbol short name of this package. */ -#define PACKAGE_TARNAME "atf" - -/* Define to the home page for this package. */ -#define PACKAGE_URL "https://github.com/jmmv/atf/" - -/* Define to the version of this package. */ -#define PACKAGE_VERSION "0.20" - -/* Define to 1 if you have the ANSI C header files. */ -#define STDC_HEADERS 1 - -/* Version number of package */ -#define VERSION "0.20" Index: head/contrib/atf/FREEBSD-Xlist =================================================================== --- head/contrib/atf/FREEBSD-Xlist (revision 273928) +++ head/contrib/atf/FREEBSD-Xlist (revision 273929) @@ -1,22 +1,12 @@ -*/*/Atffile */*/Makefile* -*/Atffile */Makefile* */*.m4 */*.pc.in -Atffile INSTALL Makefile* aclocal.m4 admin/ -atf-config/ -atf-report/ -atf-run/ -atf-version/ -bconfig.h.in +config.h.in bootstrap/ configure* -doc/atf-formats.5 -doc/atf.7.in m4/ -tools/ Index: head/contrib/atf/NEWS =================================================================== --- head/contrib/atf/NEWS (revision 273928) +++ head/contrib/atf/NEWS (revision 273929) @@ -1,670 +1,726 @@ Major changes between releases Automated Testing Framework =========================================================================== +Changes in version 0.21 +*********************** + +Released on October 23rd, 2014. + +* Restored the atf(7) manual page to serve as a reference to all the other + manual pages shipped by ATF. + +* Added the -s flag to atf-sh to support specifying the shell interpreter + to be used. + +* Removed ATF_WORKDIR. The only remaining consumers have been converted to + use the standard TMPDIR environment variable. As a benefit, and because + Kyua forces the TMPDIR to live within the test case's work directory, + any stale files left behind by ATF will be automatically cleaned up. + +* Documented the environment variables recognized by each component in the + relevant manual pages. This information was lost with the atf-config(1) + removal. + +* Added a new "require.diskspace" metadata property to test cases so that + they can specify the minimum amount of disk space required for the test + to run. + +* Renamed the atf-{c,c++,sh}-api(3) manual pages to atf-{c,c++,sh}(3) for + discoverability purposes. Symbolic links are provided for the time + being to still make the old names visible. + +* Issue #5: Recommend the (expected, actual) idiom for calls to the test + macros in the manual pages. + +* Issue #7: Stopped catching unhandled exceptions in atf-c++ tests. This + propagates the crash to the caller, which in turn allows it to obtain + proper debugging information. In particular, Kyua should now be able to + extract a stacktrace pinpointing the problem. + +* Issue #8: Fixed atf-c/macros_test:use test failures spotted by the clang + that ships with FreeBSD 11.0-CURRENT. + +* Issue #12: Improved documentation of atf-sh(3) and atf-check(1) by better + explaining how they relate to each other. + +* Issue #14: Stopped setting 'set -e' in atf-sh. This setting was + initially added as a way to enable a "strict" mode in the library and to + make test cases fail fast when they run unprotected commands. However, + doing so in the library is surprising as the responsibility of enabling + 'set -e' should be on the user's code. Also, 'set -e' introduces + inconsistent behavior on subshells and users do not expect that. + +* Issue #15: Fixed atf_utils_{fork,wait} to support nested calls. + +* Issue #16: Fixed test failures (by removing a long-standing hack) on + systems that lack \e support in printf(1). + +* Issue #19: Removed stale references to atf-config and atf-run. + Changes in version 0.20 *********************** Experimental version released on February 7th, 2014. This is the first release without the code for the deprecated tools. If you require such code, please fetch a copy of the 0.19 release and extract the 'tools' directory for your own consumption. * Removed the deprecated tools. This includes atf-config, atf-report, atf-run and atf-version. * Issue #8: Fixed atf-c/macros_test:use test failures spotted by the clang that ships with FreeBSD 11.0-CURRENT. Changes in version 0.19 *********************** Experimental version released on February 7th, 2014. This is the last release to bundle the code for the deprecated tools. The next release will drop their code and will stop worrying about backwards compatibility between the ATF libraries and what the old tools may or may not support. If you still require the old tools for some reason, grab a copy of the 'tools' directory now. The code in this directory is standalone and does not depend on any internal details of atf-c++ any longer. * Various fixes and improvements to support running as part of the FreeBSD test suite. * Project hosting moved from Google Code (as a subproject of Kyua) to GitHub (as a first-class project). The main reason for the change is the suppression of binary downloads in Google Code on Jan 15th, 2014. See https://github.com/jmmv/atf/ * Removed builtin help from atf-sh(1) and atf-check(1) for simplicity reasons. In other words, their -h option is gone. * Moved the code of the deprecated tools into a 'tools' directory and completely decoupled their code from the internals of atf-c++. The reason for this is to painlessly allow a third-party to maintain a copy of these tools after we delete them because upcoming changes to atf-c++ would break the stale tools. Changes in version 0.18 *********************** Experimental version released on November 16th, 2013. * Issue 45: Added require.memory support in atf-run for FreeBSD. * Fixed an issue with the handling of cin with libc++. * Issue 64: Fixed various mandoc formatting warnings. * NetBSD PR bin/48284: Made atf-check flush its progress message to stdout so that an interrupted test case always shows the last message being executed. * NetBSD PR bin/48285: Fixed atf_check examples in atf-sh-api(3). Changes in version 0.17 *********************** Experimental version released on February 14th, 2013. * Added the atf_utils_cat_file, atf_utils_compare_file, atf_utils_copy_file, atf_utils_create_file, atf_utils_file_exists, atf_utils_fork, atf_utils_grep_file, atf_utils_grep_string, atf_utils_readline, atf_utils_redirect and atf_utils_wait utility functions to atf-c-api. Documented the already-public atf_utils_free_charpp function. * Added the cat_file, compare_file, copy_file, create_file, file_exists, fork, grep_collection, grep_file, grep_string, redirect and wait functions to the atf::utils namespace of atf-c++-api. These are wrappers around the same functions added to the atf-c-api library. * Added the ATF_CHECK_MATCH, ATF_CHECK_MATCH_MSG, ATF_REQUIRE_MATCH and ATF_REQUIRE_MATCH_MSG macros to atf-c to simplify the validation of a string against a regular expression. * Miscellaneous fixes for manpage typos and compilation problems with clang. * Added caching of the results of those configure tests that rely on executing a test program. This should help crossbuild systems by providing a mechanism to pre-specify what the results should be. * PR bin/45690: Make atf-report convert any non-printable characters to a plain-text representation (matching their corresponding hexadecimal entities) in XML output files. This is to prevent the output of test cases from breaking xsltproc later. Changes in version 0.16 *********************** Experimental version released on July 10th, 2012. * Added a --enable-tools flag to configure to request the build of the deprecated ATF tools, whose build is now disabled by default. In order to continue running tests, you should migrate to Kyua instead of enabling the build of the deprecated tools. The kyua-atf-compat package provides transitional compatibility versions of atf-run and atf-report built on top of Kyua. * Tweaked the ATF_TEST_CASE macro of atf-c++ so that the compiler can detect defined but unused test cases. * PR bin/45859: Fixed some XSLT bugs that resulted in the tc-time and tp-time XML tags leaking into the generated HTML file. Also improved the CSS file slightly to correct alignment and color issues with the timestamps column. * Optimized atf-c++/macros.hpp so that GNU G++ consumes less memory during compilation with GNU G++. * Flipped the default to building shared libraries for atf-c and atf-c++, and started versioning them. As a side-effect, this removes the --enable-unstable-shared flag from configure that appears to not work any more (under NetBSD). Additionally, some distributions require the use of shared libraries for proper dependency tracking (e.g. Fedora), so it is better if we do the right versioning upstream. * Project hosting moved from an adhoc solution (custom web site and Monotone repository) to Google Code (standard wiki and Git). ATF now lives in a subcomponent of the Kyua project. Changes in version 0.15 *********************** Experimental version released on January 16th, 2012. * Respect stdin in atf-check. The previous release silenced stdin for any processes spawned by atf, not only test programs, which caused breakage in tests that pipe data through atf-check. * Performance improvements to atf-sh. * Enabled detection of unused parameters and variables in the code and fixed all warnings. * Changed the behavior of "developer mode". Compiler warnings are now enabled unconditionally regardless of whether we are in developer mode or not; developer mode is now only used to perform strict warning checks and to enable assertions. Additionally, developer mode is now only automatically enabled when building from the repository, not for formal releases. * Added new Autoconf M4 macros (ATF_ARG_WITH, ATF_CHECK_C and ATF_CHECK_CXX) to provide a consistent way of defining a --with-arg flag in configure scripts and detecting the presence of any of the ATF bindings. Note that ATF_CHECK_SH was already introduced in 0.14, but it has now been modified to also honor --with-atf if instantiated. * Added timing support to atf-run / atf-report. * Added support for a 'require.memory' property, to specify the minimum amount of physical memory needed by the test case to yield valid results. * PR bin/45690: Force an ISO-8859-1 encoding in the XML files generated by atf-report so that invalid data in the output of test cases does not mangle our report. Changes in version 0.14 *********************** Experimental version released on June 14th, 2011. * Added a pkg-config file for atf-sh and an aclocal file to ease the detection of atf-sh from autoconf scripts. * Made the default test case body defined by atf_sh fail. This is to ensure that test cases are properly defined in test programs and helps in catching typos in the names of the body functions. * PR bin/44882: Made atf-run connect the stdin of test cases to /dev/zero. This provides more consistent results with "normal" execution (in particular, when tests are executed detached from a terminal). * Made atf-run hardcode TZ=UTC for test cases. It used to undefine TZ, but that does not take into account that libc determines the current timezone from a configuration file. * All test programs will now print a warning when they are not run through atf-run(1) stating that this is unsupported and may deliver incorrect results. * Added support for the 'require.files' test-case property. This allows test cases to specify installed files that must be present for the test case to run. Changes in version 0.13 *********************** Experimental version released on March 31st, 2011. This is the first release after the creation of the Kyua project, a more modular and reliable replacement for ATF. From now on, ATF will change to accomodate the transition to this new codebase, but ATF will still continue to see development in the short/medium term. Check out the project page at http://code.google.com/p/kyua/ for more details. The changes in this release are: * Added support to run the tests with the Kyua runtime engine (kyua-cli), a new package that aims to replace atf-run and atf-report. The ATF tests can be run with the new system by issuing a 'make installcheck-kyua' from the top-level directory of the project (assuming the 'kyua' binary is available during the configuration stage of ATF). * atf-run and atf-report are now in maintenance mode (but *not* deprecated yet!). Kyua already implements a new, much more reliable runtime engine that provides similar features to these tools. That said, it is not complete yet so all development efforts should go towards it. * If GDB is installed, atf-run dumps the stack trace of crashing test programs in an attempt to aid debugging. Contributed by Antti Kantee. * Reverted default timeout change in previous release and reset its value to 5 minutes. This was causing several issues, specially when running the existing NetBSD test suite in qemu. * Fixed the 'match' output checker in atf-check to properly validate the last line of a file even if it does not have a newline. * Added the ATF_REQUIRE_IN and ATF_REQUIRE_NOT_IN macros to atf-c++ to check for the presence (or lack thereof) of an element in a collection. * PR bin/44176: Fixed a race condition in atf-run that would crash atf-run when the cleanup of a test case triggered asynchronous modifications to its work directory (e.g. killing a daemon process that cleans up a pid file in the work directory). * PR bin/44301: Fixed the sample XSLT file to report bogus test programs instead of just listing them as having 0 test cases. Changes in version 0.12 *********************** Experimental version released on November 7th, 2010. * Added the ATF_REQUIRE_THROW_RE to atf-c++, which is the same as ATF_REQUIRE_THROW but allows checking for the validity of the exception's error message by means of a regular expression. * Added the ATF_REQUIRE_MATCH to atf-c++, which allows checking for a regular expression match in a string. * Changed the default timeout for test cases from 5 minutes to 30 seconds. 30 seconds is long enough for virtually all tests to complete, and 5 minutes is a way too long pause in a test suite where a single test case stalls. * Deprecated the use.fs property. While this seemed like a good idea in the first place to impose more control on what test cases can do, it turns out to be bad. First, use.fs=false prevents bogus test cases from dumping core so after-the-fact debugging is harder. Second, supporting use.fs adds a lot of unnecessary complexity. atf-run will now ignore any value provided to use.fs and will allow test cases to freely access the file system if they wish to. * Added the atf_tc_get_config_var_as_{bool,long}{,_wd} functions to the atf-c library. The 'text' module became private in 0.11 but was being used externally to simplify the parsing of configuration variables. * Made atf-run recognize the 'unprivileged-user' configuration variable and automatically drop root privileges when a test case sets require.user=unprivileged. Note that this is, by no means, done for security purposes; this is just for user convenience; tests should, in general, not be blindly run as root in the first place. Changes in version 0.11 *********************** Experimental version released on October 20th, 2010. * The ATF_CHECK* macros in atf-c++ were renamed to ATF_REQUIRE* to match their counterparts in atf-c. * Clearly separated the modules in atf-c that are supposed to be public from those that are implementation details. The header files for the internal modules are not installed any more. * Made the atf-check tool private. It is only required by atf-sh and being public has the danger of causing confusion. Also, making it private simplifies the public API of atf. * Changed atf-sh to enable per-command error checking (set -e) by default. This catches many cases in which a test case is broken but it is not reported as such because execution continues. * Fixed the XSTL and CSS stylesheets to support expected failures. Changes in version 0.10 *********************** Experimental version released on July 2nd, 2010. Miscellaneous features * Added expected failures support to test cases and atf-run. These include, for example, expected clean exits, expected reception of fatal signals, expected timeouts and expected errors in condition checks. These statuses can be used to denote test cases that are known to fail due to a bug in the code they are testing. atf-report reports these tests separately but they do not count towards the failed test cases amount. * Added the ATF_CHECK_ERRNO and ATF_REQUIRE_ERRNO to the C library to allow easy checking of call failures that update errno. * Added the has.cleanup meta-data property to test caes that specifies whether the test case has a cleanup routine or not; its value is automatically set. This property is read by atf-run to know if it has to run the cleanup routine; skipping this run for every test case significantly speeds up the run time of test suites. * Reversed the order of the ATF_CHECK_THROW macro in the C++ binding to take the expected exception as the first argument and the statement to execute as the second argument. Changes in atf-check * Changed atf-check to support negating the status and output checks by prefixing them with not- and added support to specify multiple checkers for stdout and stderr, not only one. * Added the match output checker to atf-check to look for regular expressions in the stdout and stderr of commands. * Modified the exit checks in atf-check to support checking for the reception of signals. Code simplifications and cleanups * Removed usage messages from test programs to simplify the implementation of every binding by a significant amount. They just now refer the user to the appropriate manual page and do not attempt to wrap lines on terminal boundaries. Test programs are not supposed to be run by users directly so this minor interface regression is not important. * Removed the atf-format internal utility, which is unused after the change documented above. * Removed the atf-cleanup internal utility. It has been unused since the test case isolation was moved to atf-run in 0.8 * Splitted the Makefile.am into smaller files for easier maintenance and dropped the use of M4. Only affects users building from the repository sources. * Intermixed tests with the source files in the source tree to provide them more visibility and easier access. The tests directory is gone from the source tree and tests are now suffixed by _test, not prefixed by t_. * Simplifications to the atf-c library: removed the io, tcr and ui modules as they had become unnecessary after all simplifications introduced since the 0.8 release. * Removed the application/X-atf-tcr format introduced in 0.8 release. Tests now print a much simplified format that is easy to parse and nicer to read by end users. As a side effect, the default for test cases is now to print their results to stdout unless otherwise stated by providing the -r flag. * Removed XML distribution documents and replaced them with plain-text documents. They provided little value and introduced a lot of complexity to the build system. * Simplified the output of atf-version by not attempting to print a revision number when building form a distfile. Makes the build system easier to maintain. Changes in version 0.9 ********************** Experimental version released on June 3rd, 2010. * Added atf-sh, an interpreter to process test programs written using the shell API. This is not really a shell interpreter by itself though: it is just a wrapper around the system shell that eases the loading of the necessary ATF libraries. * Removed atf-compile in favour of atf-sh. * Added the use.fs metadata property to test case, which is used to specify which test cases require file system access. This is to highlight dependencies on external resources more clearly and to speed up the execution of test suites by skipping the creation of many unnecessary work directories. * Fixed test programs to get a sane default value for their source directory. This means that it should not be necessary any more to pass -s when running test programs that do not live in the current directory. * Defining test case headers became optional. This is trivial to achieve in shell-based tests but a bit ugly in C and C++. In C, use the new ATF_TC_WITHOUT_HEAD macro to define the test case, and in C++ use ATF_TEST_CASE_WITHOUT_HEAD. Changes in version 0.8 ********************** Experimental version released on May 7th, 2010. * Test programs no longer run several test cases in a row. The execution of a test program now requires a test case name, and that single test case is executed. To execute several test cases, use the atf-run utility as usual. * Test programs no longer fork a subprocess to isolate the execution of test cases. They run the test case code in-process, and a crash of the test case will result in a crash of the test program. This is to ease debugging of faulty test cases. * Test programs no longer isolate their test cases. This means that they will not create temporary directories nor sanitize the environment any more. Yes: running a test case that depends on system state by hand will most likely yield different results depending on where (machine, directory, user environment, etc.) it is run. Isolation has been moved to atf-run. * Test programs no longer print a cryptic format (application/X-atf-tcs) on a special file channel. They can now print whatever they want on the screen. Because test programs can now only run one test case every time, providing controlled output is not necessary any more. * Test programs no longer write their status into a special file descriptor. Instead, they create a file with the results, which is later parsed by atf-run. This changes the semantics of the -r flag. * atf-run has been adjusted to perform the test case isolation. As a result, there is now a single canonical place that implements the isolation of test caes. In previous releases, the three language bindings (C, C++ and shell) had to be kept in sync with each other (read: not a nice thing to do at all). As a side effect of this change, writing bindings for other languages will be much, much easier from now on. * atf-run forks test programs on a test case basis, instead of on a test program basis as it did before. This is to provide the test case isolation that was before implemented by the test programs themselves. * Removed the atf-exec tool. This was used to implement test case isolation in atf-sh, but it is now unnecessary. * It is now optional to define the descr meta-data property. It has been proven to be mostly useless, because test cases often carry a descriptive name of their own. Changes in version 0.7 ********************** Experimental version released on December 22nd, 2009. * Added build-time checks to atf-c and atf-c++. A binding for atf-sh will come later. * Migrated all build-time checks for header files to proper ATF tests. This demonstrates the use of the new feature described above. * Added an internal API for child process management. * Converted all plain-text distribution documents to a Docbook canonical version, and include pre-generated plain text and HTML copies in the distribution file. * Simplified the contents of the Makefile.am by regenerating it from a canonical Makefile.am.m4 source. As a side-effect, some dependency specifications were fixed. * Migrated all checks from the check target to installcheck, as these require ATF to be installed. * Fixed sign comparison mismatches triggered by the now-enabled -Wsign-compare. * Fixed many memory and object leaks. Changes in version 0.6 ********************** Experimental version released on January 18th, 2009. * Make atf-exec be able to kill its child process after a certain period of time; this is controlled through the new -t option. * Change atf-sh to use atf-exec's -t option to control the test case's timeouts, instead of doing it internally. Same behavior as before, but noticeably faster. * atf-exec's -g option and atf-killpg are gone due to the previous change. * Added the atf-check(1) tool, a program that executes a given command and checks its exit code against a known value and allows the management of stdout and stderr in multiple ways. This replaces the previous atf_check function in the atf-sh library and exposes this functionality to both atf-c and atf-c++. * Added the ATF_REQUIRE family of macros to the C interface. These help in checking for fatal test conditions. The old ATF_CHECK macros now perform non-fatal checks only. I.e. by using ATF_CHECK, the test case can now continue its execution and the failures will not be reported until the end of the whole run. * Extended the amount of ATF_CHECK_* C macros with new ones to provide more features to the developer. These also have their corresponding counterparts in the ATF_REQUIRE_* family. The new macros (listing the suffixes only) are: _EQ (replaces _EQUAL), _EQ_MSG, _STREQ and _STREQ_MSG. Changes in version 0.5 ********************** Experimental version released on May 1st, 2008. * Clauses 3 and 4 of the BSD license used by the project were dropped. All the code is now under a 2-clause BSD license compatible with the GNU General Public License (GPL). * Added a C-only binding so that binary test programs do not need to be tied to C++ at all. This binding is now known as the atf-c library. * Renamed the C++ binding to atf-c++ for consistency with the new atf-c. * Renamed the POSIX shell binding to atf-sh for consistency with the new atf-c and atf-c++. * Added a -w flag to test programs through which it is possible to specify the work directory to be used. This was possible in prior releases by defining the workdir configuration variable (-v workdir=...), but was a conceptually incorrect mechanism. * Test programs now preserve the execution order of test cases when they are given in the command line. Even those mentioned more than once are executed multiple times to comply with the user's requests. Changes in version 0.4 ********************** Experimental version released on February 4th, 2008. * Added two new manual pages, atf-c++-api and atf-sh-api, describing the C++ and POSIX shell interfaces used to write test programs. * Added a pkg-config file, useful to get the flags to build against the C++ library or to easily detect the presence of ATF. * Added a way for test cases to require a specific architecture and/or machine type through the new 'require.arch' and 'require.machine' meta-data properties, respectively. * Added the 'timeout' property to test cases, useful to set an upper-bound limit for the test's run time and thus prevent global test program stalls due to the test case's misbehavior. * Added the atf-exec(1) internal utility, used to execute a command after changing the process group it belongs to. * Added the atf-killpg(1) internal utility, used to kill process groups. * Multiple portability fixes. Of special interest, full support for SunOS (Solaris Express Developer Edition 2007/09) using the Sun Studio 12 C++ compiler. * Fixed a serious bug that prevented atf-run(1) from working at all under Fedora 8 x86_64. Due to the nature of the bug, other platforms were likely affected too. Changes in version 0.3 ********************** Experimental version released on November 11th, 2007. * Added XML output support to atf-report. This is accompanied by a DTD for the format's structure and sample XSLT/CSS files to post-process this output and convert it to a plain HTML report. * Changed atf-run to add system information to the report it generates. This is currently used by atf-report's XML output only, and is later printed in the HTML reports in a nice and useful summary table. The user and system administrator are allowed to tune this feature by means of hooks. * Removed the test cases' 'isolated' property. This was intended to avoid touching the file system at all when running the related test case, but this has not been true for a long while: some control files are unconditionally required for several purposes, and we cannot easily get rid of them. This way we remove several critical and delicate pieces of code. * Improved atf-report's CSV output format to include information about test programs too. * Fixed the tests that used atf-compile to not require this tool as a helper. Avoids systems without build-time utilities to skip many tests that could otherwise be run. (E.g. NetBSD without the comp.tgz set installed.) * Many general cleanups: Fixed many pieces of code marked as ugly and/or incomplete. Changes in version 0.2 ********************** Experimental version released on September 20th, 2007. * Test cases now get a known umask on entry. * atf-run now detects many unexpected failures caused by test programs and reports them as bogus tests. atf-report is able to handle these new errors and nicely reports them to the user. * All the data formats read and written by the tools have been documented and cleaned up. These include those grammars that define how the different components communicate with each other as well as the format of files written by the developers and users: the Atffiles and the configuration files. * Added the atf-version tool, a utility that displays information about the currently installed version of ATF. * Test cases can now define an optional cleanup routine to undo their actions regardless of their exit status. * atf-report now summarizes the list of failed (bogus) test programs when using the ticker output format. * Test programs now capture some termination signals and clean up any temporary files before exiting the program. * Multiple bug fixes and improvements all around. Changes in version 0.1 ********************** Experimental version released on August 20th, 2007. * First public version. This was released coinciding with the end of the Google Summer of Code 2007 program. =========================================================================== vim: filetype=text:textwidth=75:expandtab:shiftwidth=2:softtabstop=2 Index: head/contrib/atf/atf-c/config_test.c =================================================================== --- head/contrib/atf/atf-c/config_test.c (revision 273928) +++ head/contrib/atf/atf-c/config_test.c (nonexistent) @@ -1,152 +0,0 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND - * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, - * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE - * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER - * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -#include -#include - -#include - -#include "atf-c/config.h" - -#include "detail/env.h" -#include "detail/test_helpers.h" - -static const char *test_value = "env-value"; - -static struct varnames { - const char *lc; - const char *uc; - bool can_be_empty; -} all_vars[] = { - { "atf_build_cc", "ATF_BUILD_CC", false }, - { "atf_build_cflags", "ATF_BUILD_CFLAGS", true }, - { "atf_build_cpp", "ATF_BUILD_CPP", false }, - { "atf_build_cppflags", "ATF_BUILD_CPPFLAGS", true }, - { "atf_build_cxx", "ATF_BUILD_CXX", false }, - { "atf_build_cxxflags", "ATF_BUILD_CXXFLAGS", true }, - { "atf_includedir", "ATF_INCLUDEDIR", false }, - { "atf_libexecdir", "ATF_LIBEXECDIR", false }, - { "atf_pkgdatadir", "ATF_PKGDATADIR", false }, - { "atf_shell", "ATF_SHELL", false }, - { "atf_workdir", "ATF_WORKDIR", false }, - { NULL, NULL, false } -}; - -/* --------------------------------------------------------------------- - * Auxiliary functions. - * --------------------------------------------------------------------- */ - -void __atf_config_reinit(void); - -static -void -unset_all(void) -{ - const struct varnames *v; - for (v = all_vars; v->lc != NULL; v++) - RE(atf_env_unset(v->uc)); -} - -static -void -compare_one(const char *var, const char *expvalue) -{ - const struct varnames *v; - - printf("Checking that %s is set to %s\n", var, expvalue); - - for (v = all_vars; v->lc != NULL; v++) { - if (strcmp(v->lc, var) == 0) - ATF_CHECK_STREQ(atf_config_get(v->lc), test_value); - else - ATF_CHECK(strcmp(atf_config_get(v->lc), test_value) != 0); - } -} - -/* --------------------------------------------------------------------- - * Test cases for the free functions. - * --------------------------------------------------------------------- */ - -ATF_TC(get); -ATF_TC_HEAD(get, tc) -{ - atf_tc_set_md_var(tc, "descr", "Tests the atf_config_get function"); -} -ATF_TC_BODY(get, tc) -{ - const struct varnames *v; - - /* Unset all known environment variables and make sure the built-in - * values do not match the bogus value we will use for testing. */ - unset_all(); - __atf_config_reinit(); - for (v = all_vars; v->lc != NULL; v++) - ATF_CHECK(strcmp(atf_config_get(v->lc), test_value) != 0); - - /* Test the behavior of empty values. */ - for (v = all_vars; v->lc != NULL; v++) { - unset_all(); - if (strcmp(atf_config_get(v->lc), "") != 0) { - RE(atf_env_set(v->uc, "")); - __atf_config_reinit(); - if (v->can_be_empty) - ATF_CHECK(strlen(atf_config_get(v->lc)) == 0); - else - ATF_CHECK(strlen(atf_config_get(v->lc)) > 0); - } - } - - /* Check if every variable is recognized individually. */ - for (v = all_vars; v->lc != NULL; v++) { - unset_all(); - RE(atf_env_set(v->uc, test_value)); - __atf_config_reinit(); - compare_one(v->lc, test_value); - } -} - -/* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/config.h"); - -/* --------------------------------------------------------------------- - * Main. - * --------------------------------------------------------------------- */ - -ATF_TP_ADD_TCS(tp) -{ - ATF_TP_ADD_TC(tp, get); - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); - - return atf_no_error(); -} Index: head/contrib/atf/atf-c/config.c =================================================================== --- head/contrib/atf/atf-c/config.c (revision 273928) +++ head/contrib/atf/atf-c/config.c (nonexistent) @@ -1,160 +0,0 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND - * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, - * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE - * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER - * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -#include -#include -#include -#include - -#include "atf-c/config.h" - -#include "detail/env.h" -#include "detail/sanity.h" - -static bool initialized = false; - -static struct var { - const char *name; - const char *default_value; - const char *value; - bool can_be_empty; -} vars[] = { - { "atf_build_cc", ATF_BUILD_CC, NULL, false, }, - { "atf_build_cflags", ATF_BUILD_CFLAGS, NULL, true, }, - { "atf_build_cpp", ATF_BUILD_CPP, NULL, false, }, - { "atf_build_cppflags", ATF_BUILD_CPPFLAGS, NULL, true, }, - { "atf_build_cxx", ATF_BUILD_CXX, NULL, false, }, - { "atf_build_cxxflags", ATF_BUILD_CXXFLAGS, NULL, true, }, - { "atf_includedir", ATF_INCLUDEDIR, NULL, false, }, - { "atf_libexecdir", ATF_LIBEXECDIR, NULL, false, }, - { "atf_pkgdatadir", ATF_PKGDATADIR, NULL, false, }, - { "atf_shell", ATF_SHELL, NULL, false, }, - { "atf_workdir", ATF_WORKDIR, NULL, false, }, - { NULL, NULL, NULL, false, }, -}; - -/* Only used for unit testing, so this prototype is private. */ -void __atf_config_reinit(void); - -/* --------------------------------------------------------------------- - * Auxiliary functions. - * --------------------------------------------------------------------- */ - -static -char * -string_to_upper(const char *str) -{ - char *uc; - - uc = (char *)malloc(strlen(str) + 1); - if (uc != NULL) { - char *ucptr = uc; - while (*str != '\0') { - *ucptr = toupper((int)*str); - - str++; - ucptr++; - } - *ucptr = '\0'; - } - - return uc; -} - -static -void -initialize_var(struct var *var, const char *envname) -{ - PRE(var->value == NULL); - - if (atf_env_has(envname)) { - const char *val = atf_env_get(envname); - if (strlen(val) > 0 || var->can_be_empty) - var->value = val; - else - var->value = var->default_value; - } else - var->value = var->default_value; - - POST(var->value != NULL); -} - -static -void -initialize(void) -{ - struct var *var; - - PRE(!initialized); - - for (var = vars; var->name != NULL; var++) { - char *envname; - - envname = string_to_upper(var->name); - initialize_var(var, envname); - free(envname); - } - - initialized = true; -} - -/* --------------------------------------------------------------------- - * Free functions. - * --------------------------------------------------------------------- */ - -const char * -atf_config_get(const char *name) -{ - const struct var *var; - const char *value; - - if (!initialized) { - initialize(); - INV(initialized); - } - - value = NULL; - for (var = vars; value == NULL && var->name != NULL; var++) - if (strcmp(var->name, name) == 0) - value = var->value; - INV(value != NULL); - - return value; -} - -void -__atf_config_reinit(void) -{ - struct var *var; - - initialized = false; - - for (var = vars; var->name != NULL; var++) - var->value = NULL; -} Index: head/contrib/atf/atf-c/config.h =================================================================== --- head/contrib/atf/atf-c/config.h (revision 273928) +++ head/contrib/atf/atf-c/config.h (nonexistent) @@ -1,37 +0,0 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND - * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, - * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE - * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER - * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR - * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -#if !defined(ATF_C_CONFIG_H) -#define ATF_C_CONFIG_H - -#include - -const char *atf_config_get(const char *); - -#endif /* !defined(ATF_C_CONFIG_H) */ Index: head/contrib/atf/atf-c/Kyuafile =================================================================== --- head/contrib/atf/atf-c/Kyuafile (revision 273928) +++ head/contrib/atf/atf-c/Kyuafile (revision 273929) @@ -1,16 +1,15 @@ syntax("kyuafile", 1) test_suite("atf") atf_test_program{name="atf_c_test"} atf_test_program{name="build_test"} atf_test_program{name="check_test"} -atf_test_program{name="config_test"} atf_test_program{name="error_test"} atf_test_program{name="macros_test"} atf_test_program{name="pkg_config_test"} atf_test_program{name="tc_test"} atf_test_program{name="tp_test"} atf_test_program{name="utils_test"} include("detail/Kyuafile") Index: head/contrib/atf/atf-c/atf-c.3 =================================================================== --- head/contrib/atf/atf-c/atf-c.3 (nonexistent) +++ head/contrib/atf/atf-c/atf-c.3 (revision 273929) @@ -0,0 +1,793 @@ +.\" Copyright (c) 2008 The NetBSD Foundation, Inc. +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND +.\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +.\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.Dd October 13, 2014 +.Dt ATF-C 3 +.Os +.Sh NAME +.Nm atf-c , +.Nm ATF_CHECK , +.Nm ATF_CHECK_MSG , +.Nm ATF_CHECK_EQ , +.Nm ATF_CHECK_EQ_MSG , +.Nm ATF_CHECK_MATCH , +.Nm ATF_CHECK_MATCH_MSG , +.Nm ATF_CHECK_STREQ , +.Nm ATF_CHECK_STREQ_MSG , +.Nm ATF_CHECK_ERRNO , +.Nm ATF_REQUIRE , +.Nm ATF_REQUIRE_MSG , +.Nm ATF_REQUIRE_EQ , +.Nm ATF_REQUIRE_EQ_MSG , +.Nm ATF_REQUIRE_MATCH , +.Nm ATF_REQUIRE_MATCH_MSG , +.Nm ATF_REQUIRE_STREQ , +.Nm ATF_REQUIRE_STREQ_MSG , +.Nm ATF_REQUIRE_ERRNO , +.Nm ATF_TC , +.Nm ATF_TC_BODY , +.Nm ATF_TC_BODY_NAME , +.Nm ATF_TC_CLEANUP , +.Nm ATF_TC_CLEANUP_NAME , +.Nm ATF_TC_HEAD , +.Nm ATF_TC_HEAD_NAME , +.Nm ATF_TC_NAME , +.Nm ATF_TC_WITH_CLEANUP , +.Nm ATF_TC_WITHOUT_HEAD , +.Nm ATF_TP_ADD_TC , +.Nm ATF_TP_ADD_TCS , +.Nm atf_tc_get_config_var , +.Nm atf_tc_get_config_var_wd , +.Nm atf_tc_get_config_var_as_bool , +.Nm atf_tc_get_config_var_as_bool_wd , +.Nm atf_tc_get_config_var_as_long , +.Nm atf_tc_get_config_var_as_long_wd , +.Nm atf_no_error , +.Nm atf_tc_expect_death , +.Nm atf_tc_expect_exit , +.Nm atf_tc_expect_fail , +.Nm atf_tc_expect_pass , +.Nm atf_tc_expect_signal , +.Nm atf_tc_expect_timeout , +.Nm atf_tc_fail , +.Nm atf_tc_fail_nonfatal , +.Nm atf_tc_pass , +.Nm atf_tc_skip , +.Nm atf_utils_cat_file , +.Nm atf_utils_compare_file , +.Nm atf_utils_copy_file , +.Nm atf_utils_create_file , +.Nm atf_utils_file_exists , +.Nm atf_utils_fork , +.Nm atf_utils_free_charpp , +.Nm atf_utils_grep_file , +.Nm atf_utils_grep_string , +.Nm atf_utils_readline , +.Nm atf_utils_redirect , +.Nm atf_utils_wait +.Nd C API to write ATF-based test programs +.Sh SYNOPSIS +.In atf-c.h +.\" NO_CHECK_STYLE_BEGIN +.Fn ATF_CHECK "expression" +.Fn ATF_CHECK_MSG "expression" "fail_msg_fmt" ... +.Fn ATF_CHECK_EQ "expected_expression" "actual_expression" +.Fn ATF_CHECK_EQ_MSG "expected_expression" "actual_expression" "fail_msg_fmt" ... +.Fn ATF_CHECK_MATCH "regexp" "string" +.Fn ATF_CHECK_MATCH_MSG "regexp" "string" "fail_msg_fmt" ... +.Fn ATF_CHECK_STREQ "string_1" "string_2" +.Fn ATF_CHECK_STREQ_MSG "string_1" "string_2" "fail_msg_fmt" ... +.Fn ATF_CHECK_ERRNO "expected_errno" "bool_expression" +.Fn ATF_REQUIRE "expression" +.Fn ATF_REQUIRE_MSG "expression" "fail_msg_fmt" ... +.Fn ATF_REQUIRE_EQ "expected_expression" "actual_expression" +.Fn ATF_REQUIRE_EQ_MSG "expected_expression" "actual_expression" "fail_msg_fmt" ... +.Fn ATF_REQUIRE_MATCH "regexp" "string" +.Fn ATF_REQUIRE_MATCH_MSG "regexp" "string" "fail_msg_fmt" ... +.Fn ATF_REQUIRE_STREQ "expected_string" "actual_string" +.Fn ATF_REQUIRE_STREQ_MSG "expected_string" "actual_string" "fail_msg_fmt" ... +.Fn ATF_REQUIRE_ERRNO "expected_errno" "bool_expression" +.\" NO_CHECK_STYLE_END +.Fn ATF_TC "name" +.Fn ATF_TC_BODY "name" "tc" +.Fn ATF_TC_BODY_NAME "name" +.Fn ATF_TC_CLEANUP "name" "tc" +.Fn ATF_TC_CLEANUP_NAME "name" +.Fn ATF_TC_HEAD "name" "tc" +.Fn ATF_TC_HEAD_NAME "name" +.Fn ATF_TC_NAME "name" +.Fn ATF_TC_WITH_CLEANUP "name" +.Fn ATF_TC_WITHOUT_HEAD "name" +.Fn ATF_TP_ADD_TC "tp_name" "tc_name" +.Fn ATF_TP_ADD_TCS "tp_name" +.Fn atf_tc_get_config_var "tc" "varname" +.Fn atf_tc_get_config_var_wd "tc" "variable_name" "default_value" +.Fn atf_tc_get_config_var_as_bool "tc" "variable_name" +.Fn atf_tc_get_config_var_as_bool_wd "tc" "variable_name" "default_value" +.Fn atf_tc_get_config_var_as_long "tc" "variable_name" +.Fn atf_tc_get_config_var_as_long_wd "tc" "variable_name" "default_value" +.Fn atf_no_error +.Fn atf_tc_expect_death "reason" "..." +.Fn atf_tc_expect_exit "exitcode" "reason" "..." +.Fn atf_tc_expect_fail "reason" "..." +.Fn atf_tc_expect_pass +.Fn atf_tc_expect_signal "signo" "reason" "..." +.Fn atf_tc_expect_timeout "reason" "..." +.Fn atf_tc_fail "reason" +.Fn atf_tc_fail_nonfatal "reason" +.Fn atf_tc_pass +.Fn atf_tc_skip "reason" +.Ft void +.Fo atf_utils_cat_file +.Fa "const char *file" +.Fa "const char *prefix" +.Fc +.Ft bool +.Fo atf_utils_compare_file +.Fa "const char *file" +.Fa "const char *contents" +.Fc +.Ft void +.Fo atf_utils_copy_file +.Fa "const char *source" +.Fa "const char *destination" +.Fc +.Ft void +.Fo atf_utils_create_file +.Fa "const char *file" +.Fa "const char *contents" +.Fa "..." +.Fc +.Ft void +.Fo atf_utils_file_exists +.Fa "const char *file" +.Fc +.Ft pid_t +.Fo atf_utils_fork +.Fa "void" +.Fc +.Ft void +.Fo atf_utils_free_charpp +.Fa "char **argv" +.Fc +.Ft bool +.Fo atf_utils_grep_file +.Fa "const char *regexp" +.Fa "const char *file" +.Fa "..." +.Fc +.Ft bool +.Fo atf_utils_grep_string +.Fa "const char *regexp" +.Fa "const char *str" +.Fa "..." +.Fc +.Ft char * +.Fo atf_utils_readline +.Fa "int fd" +.Fc +.Ft void +.Fo atf_utils_redirect +.Fa "const int fd" +.Fa "const char *file" +.Fc +.Ft void +.Fo atf_utils_wait +.Fa "const pid_t pid" +.Fa "const int expected_exit_status" +.Fa "const char *expected_stdout" +.Fa "const char *expected_stderr" +.Fc +.Sh DESCRIPTION +ATF provides a C programming interface to implement test programs. +C-based test programs follow this template: +.Bd -literal -offset indent +.Ns ... C-specific includes go here ... + +#include + +ATF_TC(tc1); +ATF_TC_HEAD(tc1, tc) +{ + ... first test case's header ... +} +ATF_TC_BODY(tc1, tc) +{ + ... first test case's body ... +} + +ATF_TC_WITH_CLEANUP(tc2); +ATF_TC_HEAD(tc2, tc) +{ + ... second test case's header ... +} +ATF_TC_BODY(tc2, tc) +{ + ... second test case's body ... +} +ATF_TC_CLEANUP(tc2, tc) +{ + ... second test case's cleanup ... +} + +ATF_TC_WITHOUT_HEAD(tc3); +ATF_TC_BODY(tc3, tc) +{ + ... third test case's body ... +} + +.Ns ... additional test cases ... + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tcs, tc1); + ATF_TP_ADD_TC(tcs, tc2); + ATF_TP_ADD_TC(tcs, tc3); + ... add additional test cases ... + + return atf_no_error(); +} +.Ed +.Ss Definition of test cases +Test cases have an identifier and are composed of three different parts: +the header, the body and an optional cleanup routine, all of which are +described in +.Xr atf-test-case 4 . +To define test cases, one can use the +.Fn ATF_TC , +.Fn ATF_TC_WITH_CLEANUP +or the +.Fn ATF_TC_WITHOUT_HEAD +macros, which take a single parameter specifiying the test case's name. +.Fn ATF_TC , +requires to define a head and a body for the test case, +.Fn ATF_TC_WITH_CLEANUP +requires to define a head, a body and a cleanup for the test case and +.Fn ATF_TC_WITHOUT_HEAD +requires only a body for the test case. +It is important to note that these +.Em do not +set the test case up for execution when the program is run. +In order to do so, a later registration is needed with the +.Fn ATF_TP_ADD_TC +macro detailed in +.Sx Program initialization . +.Pp +Later on, one must define the three parts of the body by means of three +functions. +Their headers are given by the +.Fn ATF_TC_HEAD , +.Fn ATF_TC_BODY +and +.Fn ATF_TC_CLEANUP +macros, all of which take the test case name provided to the +.Fn ATF_TC +.Fn ATF_TC_WITH_CLEANUP , +or +.Fn ATF_TC_WITHOUT_HEAD +macros and the name of the variable that will hold a pointer to the +test case data. +Following each of these, a block of code is expected, surrounded by the +opening and closing brackets. +.Ss Program initialization +The library provides a way to easily define the test program's +.Fn main +function. +You should never define one on your own, but rely on the +library to do it for you. +This is done by using the +.Fn ATF_TP_ADD_TCS +macro, which is passed the name of the object that will hold the test +cases; i.e. the test program instance. +This name can be whatever you want as long as it is a valid variable +identifier. +.Pp +After the macro, you are supposed to provide the body of a function, which +should only use the +.Fn ATF_TP_ADD_TC +macro to register the test cases the test program will execute and return +a success error code. +The first parameter of this macro matches the name you provided in the +former call. +The success status can be returned using the +.Fn atf_no_error +function. +.Ss Header definitions +The test case's header can define the meta-data by using the +.Fn atf_tc_set_md_var +method, which takes three parameters: the first one points to the test +case data, the second one specifies the meta-data variable to be set +and the third one specifies its value. +Both of them are strings. +.Ss Configuration variables +The test case has read-only access to the current configuration variables +by means of the +.Ft bool +.Fn atf_tc_has_config_var , +.Ft const char * +.Fn atf_tc_get_config_var , +.Ft const char * +.Fn atf_tc_get_config_var_wd , +.Ft bool +.Fn atf_tc_get_config_var_as_bool , +.Ft bool +.Fn atf_tc_get_config_var_as_bool_wd , +.Ft long +.Fn atf_tc_get_config_var_as_long , +and the +.Ft long +.Fn atf_tc_get_config_var_as_long_wd +functions, which can be called in any of the three parts of a test case. +.Pp +The +.Sq _wd +variants take a default value for the variable which is returned if the +variable is not defined. +The other functions without the +.Sq _wd +suffix +.Em require +the variable to be defined. +.Ss Access to the source directory +It is possible to get the path to the test case's source directory from any +of its three components by querying the +.Sq srcdir +configuration variable. +.Ss Requiring programs +Aside from the +.Va require.progs +meta-data variable available in the header only, one can also check for +additional programs in the test case's body by using the +.Fn atf_tc_require_prog +function, which takes the base name or full path of a single binary. +Relative paths are forbidden. +If it is not found, the test case will be automatically skipped. +.Ss Test case finalization +The test case finalizes either when the body reaches its end, at which +point the test is assumed to have +.Em passed , +unless any non-fatal errors were raised using +.Fn atf_tc_fail_nonfatal , +or at any explicit call to +.Fn atf_tc_pass , +.Fn atf_tc_fail +or +.Fn atf_tc_skip . +These three functions terminate the execution of the test case immediately. +The cleanup routine will be processed afterwards in a completely automated +way, regardless of the test case's termination reason. +.Pp +.Fn atf_tc_pass +does not take any parameters. +.Fn atf_tc_fail , +.Fn atf_tc_fail_nonfatal +and +.Fn atf_tc_skip +take a format string and a variable list of parameters, which describe, in +a user-friendly manner, why the test case failed or was skipped, +respectively. +It is very important to provide a clear error message in both cases so that +the user can quickly know why the test did not pass. +.Ss Expectations +Everything explained in the previous section changes when the test case +expectations are redefined by the programmer. +.Pp +Each test case has an internal state called +.Sq expect +that describes what the test case expectations are at any point in time. +The value of this property can change during execution by any of: +.Bl -tag -width indent +.It Fn atf_tc_expect_death "reason" "..." +Expects the test case to exit prematurely regardless of the nature of the +exit. +.It Fn atf_tc_expect_exit "exitcode" "reason" "..." +Expects the test case to exit cleanly. +If +.Va exitcode +is not +.Sq -1 , +the runtime engine will validate that the exit code of the test case +matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Fn atf_tc_expect_fail "reason" "..." +Any failure (be it fatal or non-fatal) raised in this mode is recorded. +However, such failures do not report the test case as failed; instead, the +test case finalizes cleanly and is reported as +.Sq expected failure ; +this report includes the provided +.Fa reason +as part of it. +If no error is raised while running in this mode, then the test case is +reported as +.Sq failed . +.Pp +This mode is useful to reproduce actual known bugs in tests. +Whenever the developer fixes the bug later on, the test case will start +reporting a failure, signaling the developer that the test case must be +adjusted to the new conditions. +In this situation, it is useful, for example, to set +.Fa reason +as the bug number for tracking purposes. +.It Fn atf_tc_expect_pass +This is the normal mode of execution. +In this mode, any failure is reported as such to the user and the test case +is marked as +.Sq failed . +.It Fn atf_tc_expect_signal "signo" "reason" "..." +Expects the test case to terminate due to the reception of a signal. +If +.Va signo +is not +.Sq -1 , +the runtime engine will validate that the signal that terminated the test +case matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Fn atf_tc_expect_timeout "reason" "..." +Expects the test case to execute for longer than its timeout. +.El +.Ss Helper macros for common checks +The library provides several macros that are very handy in multiple +situations. +These basically check some condition after executing a given statement or +processing a given expression and, if the condition is not met, they +report the test case as failed. +.Pp +The +.Sq REQUIRE +variant of the macros immediately abort the test case as soon as an error +condition is detected by calling the +.Fn atf_tc_fail +function. +Use this variant whenever it makes no sense to continue the execution of a +test case when the checked condition is not met. +The +.Sq CHECK +variant, on the other hand, reports a failure as soon as it is encountered +using the +.Fn atf_tc_fail_nonfatal +function, but the execution of the test case continues as if nothing had +happened. +Use this variant whenever the checked condition is important as a result of +the test case, but there are other conditions that can be subsequently +checked on the same run without aborting. +.Pp +Additionally, the +.Sq MSG +variants take an extra set of parameters to explicitly specify the failure +message. +This failure message is formatted according to the +.Xr printf 3 +formatters. +.Pp +.Fn ATF_CHECK , +.Fn ATF_CHECK_MSG , +.Fn ATF_REQUIRE +and +.Fn ATF_REQUIRE_MSG +take an expression and fail if the expression evaluates to false. +.Pp +.Fn ATF_CHECK_EQ , +.Fn ATF_CHECK_EQ_MSG , +.Fn ATF_REQUIRE_EQ +and +.Fn ATF_REQUIRE_EQ_MSG +take two expressions and fail if the two evaluated values are not equal. +The common style is to put the expected value in the first parameter and the +actual value in the second parameter. +.Pp +.Fn ATF_CHECK_MATCH , +.Fn ATF_CHECK_MATCH_MSG , +.Fn ATF_REQUIRE_MATCH +and +.Fn ATF_REQUIRE_MATCH_MSG +take a regular expression and a string and fail if the regular expression does +not match the given string. +Note that the regular expression is not anchored, so it will match anywhere in +the string. +.Pp +.Fn ATF_CHECK_STREQ , +.Fn ATF_CHECK_STREQ_MSG , +.Fn ATF_REQUIRE_STREQ +and +.Fn ATF_REQUIRE_STREQ_MSG +take two strings and fail if the two are not equal character by character. +The common style is to put the expected string in the first parameter and the +actual string in the second parameter. +.Pp +.Fn ATF_CHECK_ERRNO +and +.Fn ATF_REQUIRE_ERRNO +take, first, the error code that the check is expecting to find in the +.Va errno +variable and, second, a boolean expression that, if evaluates to true, +means that a call failed and +.Va errno +has to be checked against the first value. +.Ss Utility functions +The following functions are provided as part of the +.Nm +API to simplify the creation of a variety of tests. +In particular, these are useful to write tests for command-line interfaces. +.Pp +.Ft void +.Fo atf_utils_cat_file +.Fa "const char *file" +.Fa "const char *prefix" +.Fc +.Bd -ragged -offset indent +Prints the contents of +.Fa file +to the standard output, prefixing every line with the string in +.Fa prefix . +.Ed +.Pp +.Ft bool +.Fo atf_utils_compare_file +.Fa "const char *file" +.Fa "const char *contents" +.Fc +.Bd -ragged -offset indent +Returns true if the given +.Fa file +matches exactly the expected inlined +.Fa contents . +.Ed +.Pp +.Ft void +.Fo atf_utils_copy_file +.Fa "const char *source" +.Fa "const char *destination" +.Fc +.Bd -ragged -offset indent +Copies the file +.Fa source +to +.Fa destination . +The permissions of the file are preserved during the code. +.Ed +.Pp +.Ft void +.Fo atf_utils_create_file +.Fa "const char *file" +.Fa "const char *contents" +.Fa "..." +.Fc +.Bd -ragged -offset indent +Creates +.Fa file +with the text given in +.Fa contents , +which is a formatting string that uses the rest of the variable arguments. +.Ed +.Pp +.Ft void +.Fo atf_utils_file_exists +.Fa "const char *file" +.Fc +.Bd -ragged -offset indent +Checks if +.Fa file +exists. +.Ed +.Pp +.Ft pid_t +.Fo atf_utils_fork +.Fa "void" +.Fc +.Bd -ragged -offset indent +Forks a process and redirects the standard output and standard error of the +child to files for later validation with +.Fn atf_utils_wait . +Fails the test case if the fork fails, so this does not return an error. +.Ed +.Pp +.Ft void +.Fo atf_utils_free_charpp +.Fa "char **argv" +.Fc +.Bd -ragged -offset indent +Frees a dynamically-allocated array of dynamically-allocated strings. +.Ed +.Pp +.Ft bool +.Fo atf_utils_grep_file +.Fa "const char *regexp" +.Fa "const char *file" +.Fa "..." +.Fc +.Bd -ragged -offset indent +Searches for the +.Fa regexp , +which is a formatting string representing the regular expression, +in the +.Fa file . +The variable arguments are used to construct the regular expression. +.Ed +.Pp +.Ft bool +.Fo atf_utils_grep_string +.Fa "const char *regexp" +.Fa "const char *str" +.Fa "..." +.Fc +.Bd -ragged -offset indent +Searches for the +.Fa regexp , +which is a formatting string representing the regular expression, +in the literal string +.Fa str . +The variable arguments are used to construct the regular expression. +.Ed +.Pp +.Ft char * +.Fo atf_utils_readline +.Fa "int fd" +.Fc +.Bd -ragged -offset indent +Reads a line from the file descriptor +.Fa fd . +The line, if any, is returned as a dynamically-allocated buffer that must be +released with +.Xr free 3 . +If there was nothing to read, returns +.Sq NULL . +.Ed +.Pp +.Ft void +.Fo atf_utils_redirect +.Fa "const int fd" +.Fa "const char *file" +.Fc +.Bd -ragged -offset indent +Redirects the given file descriptor +.Fa fd +to +.Fa file . +This function exits the process in case of an error and does not properly mark +the test case as failed. +As a result, it should only be used in subprocesses of the test case; specially +those spawned by +.Fn atf_utils_fork . +.Ed +.Pp +.Ft void +.Fo atf_utils_wait +.Fa "const pid_t pid" +.Fa "const int expected_exit_status" +.Fa "const char *expected_stdout" +.Fa "const char *expected_stderr" +.Fc +.Bd -ragged -offset indent +Waits and validates the result of a subprocess spawned with +.Fn atf_utils_wait . +The validation involves checking that the subprocess exited cleanly and returned +the code specified in +.Fa expected_exit_status +and that its standard output and standard error match the strings given in +.Fa expected_stdout +and +.Fa expected_stderr . +.Pp +If any of the +.Fa expected_stdout +or +.Fa expected_stderr +strings are prefixed with +.Sq save: , +then they specify the name of the file into which to store the stdout or stderr +of the subprocess, and no comparison is performed. +.Ed +.Sh ENVIRONMENT +The following variables are recognized by +.Nm +but should not be overridden other than for testing purposes: +.Pp +.Bl -tag -width ATFXBUILDXCXXFLAGSXX -compact +.It Va ATF_BUILD_CC +Path to the C compiler. +.It Va ATF_BUILD_CFLAGS +C compiler flags. +.It Va ATF_BUILD_CPP +Path to the C/C++ preprocessor. +.It Va ATF_BUILD_CPPFLAGS +C/C++ preprocessor flags. +.It Va ATF_BUILD_CXX +Path to the C++ compiler. +.It Va ATF_BUILD_CXXFLAGS +C++ compiler flags. +.El +.Sh EXAMPLES +The following shows a complete test program with a single test case that +validates the addition operator: +.Bd -literal -offset indent +#include + +ATF_TC(addition); +ATF_TC_HEAD(addition, tc) +{ + atf_tc_set_md_var(tc, "descr", + "Sample tests for the addition operator"); +} +ATF_TC_BODY(addition, tc) +{ + ATF_CHECK_EQ(0, 0 + 0); + ATF_CHECK_EQ(1, 0 + 1); + ATF_CHECK_EQ(1, 1 + 0); + + ATF_CHECK_EQ(2, 1 + 1); + + ATF_CHECK_EQ(300, 100 + 200); +} + +ATF_TC(string_formatting); +ATF_TC_HEAD(string_formatting, tc) +{ + atf_tc_set_md_var(tc, "descr", + "Sample tests for the snprintf"); +} +ATF_TC_BODY(string_formatting, tc) +{ + char buf[1024]; + snprintf(buf, sizeof(buf), "a %s", "string"); + ATF_CHECK_STREQ_MSG("a string", buf, "%s is not working"); +} + +ATF_TC(open_failure); +ATF_TC_HEAD(open_failure, tc) +{ + atf_tc_set_md_var(tc, "descr", + "Sample tests for the open function"); +} +ATF_TC_BODY(open_failure, tc) +{ + ATF_CHECK_ERRNO(ENOENT, open("non-existent", O_RDONLY) == -1); +} + +ATF_TC(known_bug); +ATF_TC_HEAD(known_bug, tc) +{ + atf_tc_set_md_var(tc, "descr", + "Reproduces a known bug"); +} +ATF_TC_BODY(known_bug, tc) +{ + atf_tc_expect_fail("See bug number foo/bar"); + ATF_CHECK_EQ(3, 1 + 1); + atf_tc_expect_pass(); + ATF_CHECK_EQ(3, 1 + 2); +} + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tp, addition); + ATF_TP_ADD_TC(tp, string_formatting); + ATF_TP_ADD_TC(tp, open_failure); + ATF_TP_ADD_TC(tp, known_bug); + + return atf_no_error(); +} +.Ed +.Sh SEE ALSO +.Xr atf-test-program 1 , +.Xr atf-test-case 4 Property changes on: head/contrib/atf/atf-c/atf-c.3 ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/contrib/atf/atf-c/atf_c_test.c =================================================================== --- head/contrib/atf/atf-c/atf_c_test.c (revision 273928) +++ head/contrib/atf/atf-c/atf_c_test.c (revision 273929) @@ -1,50 +1,46 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include -#include "detail/test_helpers.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Tests cases for the header file. * --------------------------------------------------------------------- */ HEADER_TC(include, "atf-c.h"); /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the test cases for the header file. */ ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c/build.c =================================================================== --- head/contrib/atf/atf-c/build.c (revision 273928) +++ head/contrib/atf/atf-c/build.c (revision 273929) @@ -1,281 +1,282 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2009 The NetBSD Foundation, Inc. +/* Copyright (c) 2009 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/build.h" + #include #include -#include "atf-c/build.h" -#include "atf-c/config.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/text.h" #include "atf-c/error.h" -#include "detail/sanity.h" -#include "detail/text.h" - /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static atf_error_t -append_config_var(const char *var, atf_list_t *argv) +append_config_var(const char *var, const char *default_value, atf_list_t *argv) { atf_error_t err; atf_list_t words; - err = atf_text_split(atf_config_get(var), " ", &words); + err = atf_text_split(atf_env_get_with_default(var, default_value), + " ", &words); if (atf_is_error(err)) goto out; atf_list_append_list(argv, &words); out: return err; } static atf_error_t append_arg1(const char *arg, atf_list_t *argv) { return atf_list_append(argv, strdup(arg), true); } static atf_error_t append_arg2(const char *flag, const char *arg, atf_list_t *argv) { atf_error_t err; err = append_arg1(flag, argv); if (!atf_is_error(err)) err = append_arg1(arg, argv); return err; } static atf_error_t append_optargs(const char *const optargs[], atf_list_t *argv) { atf_error_t err; err = atf_no_error(); while (*optargs != NULL && !atf_is_error(err)) { err = append_arg1(strdup(*optargs), argv); optargs++; } return err; } static atf_error_t append_src_out(const char *src, const char *obj, atf_list_t *argv) { atf_error_t err; err = append_arg2("-o", obj, argv); if (atf_is_error(err)) goto out; err = append_arg1("-c", argv); if (atf_is_error(err)) goto out; err = append_arg1(src, argv); out: return err; } static atf_error_t list_to_array(const atf_list_t *l, char ***ap) { atf_error_t err; char **a; a = (char **)malloc((atf_list_size(l) + 1) * sizeof(char *)); if (a == NULL) err = atf_no_memory_error(); else { char **aiter; atf_list_citer_t liter; aiter = a; atf_list_for_each_c(liter, l) { *aiter = strdup((const char *)atf_list_citer_data(liter)); aiter++; } *aiter = NULL; err = atf_no_error(); } *ap = a; /* Shut up warnings in the caller about uninitialized *ap. */ return err; } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_build_c_o(const char *sfile, const char *ofile, const char *const optargs[], char ***argv) { atf_error_t err; atf_list_t argv_list; err = atf_list_init(&argv_list); if (atf_is_error(err)) goto out; - err = append_config_var("atf_build_cc", &argv_list); + err = append_config_var("ATF_BUILD_CC", ATF_BUILD_CC, &argv_list); if (atf_is_error(err)) goto out_list; - err = append_config_var("atf_build_cppflags", &argv_list); + err = append_config_var("ATF_BUILD_CPPFLAGS", ATF_BUILD_CPPFLAGS, + &argv_list); if (atf_is_error(err)) goto out_list; - err = append_config_var("atf_build_cflags", &argv_list); + err = append_config_var("ATF_BUILD_CFLAGS", ATF_BUILD_CFLAGS, &argv_list); if (atf_is_error(err)) goto out_list; if (optargs != NULL) { err = append_optargs(optargs, &argv_list); if (atf_is_error(err)) goto out_list; } err = append_src_out(sfile, ofile, &argv_list); if (atf_is_error(err)) goto out_list; err = list_to_array(&argv_list, argv); if (atf_is_error(err)) goto out_list; out_list: atf_list_fini(&argv_list); out: return err; } atf_error_t atf_build_cpp(const char *sfile, const char *ofile, const char *const optargs[], char ***argv) { atf_error_t err; atf_list_t argv_list; err = atf_list_init(&argv_list); if (atf_is_error(err)) goto out; - err = append_config_var("atf_build_cpp", &argv_list); + err = append_config_var("ATF_BUILD_CPP", ATF_BUILD_CPP, &argv_list); if (atf_is_error(err)) goto out_list; - err = append_config_var("atf_build_cppflags", &argv_list); + err = append_config_var("ATF_BUILD_CPPFLAGS", ATF_BUILD_CPPFLAGS, + &argv_list); if (atf_is_error(err)) goto out_list; if (optargs != NULL) { err = append_optargs(optargs, &argv_list); if (atf_is_error(err)) goto out_list; } err = append_arg2("-o", ofile, &argv_list); if (atf_is_error(err)) goto out_list; err = append_arg1(sfile, &argv_list); if (atf_is_error(err)) goto out_list; err = list_to_array(&argv_list, argv); if (atf_is_error(err)) goto out_list; out_list: atf_list_fini(&argv_list); out: return err; } atf_error_t atf_build_cxx_o(const char *sfile, const char *ofile, const char *const optargs[], char ***argv) { atf_error_t err; atf_list_t argv_list; err = atf_list_init(&argv_list); if (atf_is_error(err)) goto out; - err = append_config_var("atf_build_cxx", &argv_list); + err = append_config_var("ATF_BUILD_CXX", ATF_BUILD_CXX, &argv_list); if (atf_is_error(err)) goto out_list; - err = append_config_var("atf_build_cppflags", &argv_list); + err = append_config_var("ATF_BUILD_CPPFLAGS", ATF_BUILD_CPPFLAGS, + &argv_list); if (atf_is_error(err)) goto out_list; - err = append_config_var("atf_build_cxxflags", &argv_list); + err = append_config_var("ATF_BUILD_CXXFLAGS", ATF_BUILD_CXXFLAGS, + &argv_list); if (atf_is_error(err)) goto out_list; if (optargs != NULL) { err = append_optargs(optargs, &argv_list); if (atf_is_error(err)) goto out_list; } err = append_src_out(sfile, ofile, &argv_list); if (atf_is_error(err)) goto out_list; err = list_to_array(&argv_list, argv); if (atf_is_error(err)) goto out_list; out_list: atf_list_fini(&argv_list); out: return err; } Index: head/contrib/atf/atf-c/build.h =================================================================== --- head/contrib/atf/atf-c/build.h (revision 273928) +++ head/contrib/atf/atf-c/build.h (revision 273929) @@ -1,42 +1,38 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2009 The NetBSD Foundation, Inc. +/* Copyright (c) 2009 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_BUILD_H) #define ATF_C_BUILD_H #include atf_error_t atf_build_c_o(const char *, const char *, const char *const [], char ***); atf_error_t atf_build_cpp(const char *, const char *, const char *const [], char ***); atf_error_t atf_build_cxx_o(const char *, const char *, const char *const [], char ***); -#endif /* ATF_C_BUILD_H */ +#endif /* !defined(ATF_C_BUILD_H) */ Index: head/contrib/atf/atf-c/build_test.c =================================================================== --- head/contrib/atf/atf-c/build_test.c (revision 273928) +++ head/contrib/atf/atf-c/build_test.c (revision 273929) @@ -1,268 +1,249 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2009 The NetBSD Foundation, Inc. +/* Copyright (c) 2009 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/build.h" + #include #include #include #include -#include "atf-c/build.h" -#include "atf-c/config.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/test_helpers.h" +#include "atf-c/h_build.h" #include "atf-c/utils.h" -#include "detail/env.h" -#include "detail/test_helpers.h" -#include "h_build.h" - /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ -void __atf_config_reinit(void); - static bool equal_arrays(const char *const *exp_array, char **actual_array) { bool equal; if (*exp_array == NULL && *actual_array == NULL) equal = true; else if (*exp_array == NULL || *actual_array == NULL) equal = false; else { equal = true; while (*actual_array != NULL) { if (*exp_array == NULL || strcmp(*exp_array, *actual_array) != 0) { equal = false; break; } exp_array++; actual_array++; } } return equal; } static void check_equal_array(const char *const *exp_array, char **actual_array) { { const char *const *exp_ptr; printf("Expected arguments:"); for (exp_ptr = exp_array; *exp_ptr != NULL; exp_ptr++) printf(" '%s'", *exp_ptr); printf("\n"); } { char **actual_ptr; printf("Returned arguments:"); for (actual_ptr = actual_array; *actual_ptr != NULL; actual_ptr++) printf(" '%s'", *actual_ptr); printf("\n"); } if (!equal_arrays(exp_array, actual_array)) atf_tc_fail_nonfatal("The constructed argv differs from the " "expected values"); } static void verbose_set_env(const char *var, const char *val) { printf("Setting %s to '%s'\n", var, val); RE(atf_env_set(var, val)); } /* --------------------------------------------------------------------- * Internal test cases. * --------------------------------------------------------------------- */ ATF_TC(equal_arrays); ATF_TC_HEAD(equal_arrays, tc) { atf_tc_set_md_var(tc, "descr", "Tests the test case internal " "equal_arrays function"); } ATF_TC_BODY(equal_arrays, tc) { { const char *const exp[] = { NULL }; char *actual[] = { NULL }; ATF_CHECK(equal_arrays(exp, actual)); } { const char *const exp[] = { NULL }; char *actual[2] = { strdup("foo"), NULL }; ATF_CHECK(!equal_arrays(exp, actual)); free(actual[0]); } { const char *const exp[] = { "foo", NULL }; char *actual[] = { NULL }; ATF_CHECK(!equal_arrays(exp, actual)); } { const char *const exp[] = { "foo", NULL }; char *actual[2] = { strdup("foo"), NULL }; ATF_CHECK(equal_arrays(exp, actual)); free(actual[0]); } } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(c_o); ATF_TC_HEAD(c_o, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_build_c_o function"); } ATF_TC_BODY(c_o, tc) { struct c_o_test *test; for (test = c_o_tests; test->expargv[0] != NULL; test++) { printf("> Test: %s\n", test->msg); verbose_set_env("ATF_BUILD_CC", test->cc); verbose_set_env("ATF_BUILD_CFLAGS", test->cflags); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - __atf_config_reinit(); { char **argv; if (test->hasoptargs) RE(atf_build_c_o(test->sfile, test->ofile, test->optargs, &argv)); else RE(atf_build_c_o(test->sfile, test->ofile, NULL, &argv)); check_equal_array(test->expargv, argv); atf_utils_free_charpp(argv); } } } ATF_TC(cpp); ATF_TC_HEAD(cpp, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_build_cpp function"); } ATF_TC_BODY(cpp, tc) { struct cpp_test *test; for (test = cpp_tests; test->expargv[0] != NULL; test++) { printf("> Test: %s\n", test->msg); verbose_set_env("ATF_BUILD_CPP", test->cpp); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - __atf_config_reinit(); { char **argv; if (test->hasoptargs) RE(atf_build_cpp(test->sfile, test->ofile, test->optargs, &argv)); else RE(atf_build_cpp(test->sfile, test->ofile, NULL, &argv)); check_equal_array(test->expargv, argv); atf_utils_free_charpp(argv); } } } ATF_TC(cxx_o); ATF_TC_HEAD(cxx_o, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_build_cxx_o function"); } ATF_TC_BODY(cxx_o, tc) { struct cxx_o_test *test; for (test = cxx_o_tests; test->expargv[0] != NULL; test++) { printf("> Test: %s\n", test->msg); verbose_set_env("ATF_BUILD_CXX", test->cxx); verbose_set_env("ATF_BUILD_CXXFLAGS", test->cxxflags); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - __atf_config_reinit(); { char **argv; if (test->hasoptargs) RE(atf_build_cxx_o(test->sfile, test->ofile, test->optargs, &argv)); else RE(atf_build_cxx_o(test->sfile, test->ofile, NULL, &argv)); check_equal_array(test->expargv, argv); atf_utils_free_charpp(argv); } } } /* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/build.h"); - -/* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the internal test cases. */ ATF_TP_ADD_TC(tp, equal_arrays); /* Add the test cases for the free functions. */ ATF_TP_ADD_TC(tp, c_o); ATF_TP_ADD_TC(tp, cpp); ATF_TP_ADD_TC(tp, cxx_o); - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c/check.c =================================================================== --- head/contrib/atf/atf-c/check.c (revision 273928) +++ head/contrib/atf/atf-c/check.c (revision 273929) @@ -1,488 +1,484 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/check.h" + #include #include #include #include #include #include #include #include "atf-c/build.h" -#include "atf-c/check.h" -#include "atf-c/config.h" #include "atf-c/defs.h" +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/list.h" +#include "atf-c/detail/process.h" +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" #include "atf-c/utils.h" -#include "detail/dynstr.h" -#include "detail/fs.h" -#include "detail/list.h" -#include "detail/process.h" -#include "detail/sanity.h" - /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static atf_error_t create_tmpdir(atf_fs_path_t *dir) { atf_error_t err; err = atf_fs_path_init_fmt(dir, "%s/check.XXXXXX", - atf_config_get("atf_workdir")); + atf_env_get_with_default("TMPDIR", "/tmp")); if (atf_is_error(err)) goto out; err = atf_fs_mkdtemp(dir); if (atf_is_error(err)) { atf_fs_path_fini(dir); goto out; } INV(!atf_is_error(err)); out: return err; } static void cleanup_tmpdir(const atf_fs_path_t *dir, const atf_fs_path_t *outfile, const atf_fs_path_t *errfile) { { atf_error_t err = atf_fs_unlink(outfile); if (atf_is_error(err)) { INV(atf_error_is(err, "libc") && atf_libc_error_code(err) == ENOENT); atf_error_free(err); } else INV(!atf_is_error(err)); } { atf_error_t err = atf_fs_unlink(errfile); if (atf_is_error(err)) { INV(atf_error_is(err, "libc") && atf_libc_error_code(err) == ENOENT); atf_error_free(err); } else INV(!atf_is_error(err)); } { atf_error_t err = atf_fs_rmdir(dir); INV(!atf_is_error(err)); } } static int const_execvp(const char *file, const char *const *argv) { #define UNCONST(a) ((void *)(unsigned long)(const void *)(a)) return execvp(file, UNCONST(argv)); #undef UNCONST } static atf_error_t init_sb(const atf_fs_path_t *path, atf_process_stream_t *sb) { atf_error_t err; if (path == NULL) err = atf_process_stream_init_inherit(sb); else err = atf_process_stream_init_redirect_path(sb, path); return err; } static atf_error_t init_sbs(const atf_fs_path_t *outfile, atf_process_stream_t *outsb, const atf_fs_path_t *errfile, atf_process_stream_t *errsb) { atf_error_t err; err = init_sb(outfile, outsb); if (atf_is_error(err)) goto out; err = init_sb(errfile, errsb); if (atf_is_error(err)) { atf_process_stream_fini(outsb); goto out; } out: return err; } struct exec_data { const char *const *m_argv; }; static void exec_child(void *) ATF_DEFS_ATTRIBUTE_NORETURN; static void exec_child(void *v) { struct exec_data *ea = v; const_execvp(ea->m_argv[0], ea->m_argv); fprintf(stderr, "execvp(%s) failed: %s\n", ea->m_argv[0], strerror(errno)); exit(127); } static atf_error_t fork_and_wait(const char *const *argv, const atf_fs_path_t *outfile, const atf_fs_path_t *errfile, atf_process_status_t *status) { atf_error_t err; atf_process_child_t child; atf_process_stream_t outsb, errsb; struct exec_data ea = { argv }; err = init_sbs(outfile, &outsb, errfile, &errsb); if (atf_is_error(err)) goto out; err = atf_process_fork(&child, exec_child, &outsb, &errsb, &ea); if (atf_is_error(err)) goto out_sbs; err = atf_process_child_wait(&child, status); out_sbs: atf_process_stream_fini(&errsb); atf_process_stream_fini(&outsb); out: return err; } static void update_success_from_status(const char *progname, const atf_process_status_t *status, bool *success) { bool s = atf_process_status_exited(status) && atf_process_status_exitstatus(status) == EXIT_SUCCESS; if (atf_process_status_exited(status)) { if (atf_process_status_exitstatus(status) == EXIT_SUCCESS) INV(s); else { INV(!s); fprintf(stderr, "%s failed with exit code %d\n", progname, atf_process_status_exitstatus(status)); } } else if (atf_process_status_signaled(status)) { INV(!s); fprintf(stderr, "%s failed due to signal %d%s\n", progname, atf_process_status_termsig(status), atf_process_status_coredump(status) ? " (core dumped)" : ""); } else { INV(!s); fprintf(stderr, "%s failed due to unknown reason\n", progname); } *success = s; } static atf_error_t array_to_list(const char *const *a, atf_list_t *l) { atf_error_t err; err = atf_list_init(l); if (atf_is_error(err)) goto out; while (*a != NULL) { char *item = strdup(*a); if (item == NULL) { err = atf_no_memory_error(); goto out; } err = atf_list_append(l, item, true); if (atf_is_error(err)) goto out; a++; } out: return err; } static void print_array(const char *const *array, const char *pfx) { const char *const *ptr; printf("%s", pfx); for (ptr = array; *ptr != NULL; ptr++) printf(" %s", *ptr); printf("\n"); } static atf_error_t check_build_run(const char *const *argv, bool *success) { atf_error_t err; atf_process_status_t status; print_array(argv, ">"); err = fork_and_wait(argv, NULL, NULL, &status); if (atf_is_error(err)) goto out; update_success_from_status(argv[0], &status, success); atf_process_status_fini(&status); INV(!atf_is_error(err)); out: return err; } /* --------------------------------------------------------------------- * The "atf_check_result" type. * --------------------------------------------------------------------- */ struct atf_check_result_impl { atf_list_t m_argv; atf_fs_path_t m_dir; atf_fs_path_t m_stdout; atf_fs_path_t m_stderr; atf_process_status_t m_status; }; static atf_error_t atf_check_result_init(atf_check_result_t *r, const char *const *argv, const atf_fs_path_t *dir) { atf_error_t err; r->pimpl = malloc(sizeof(struct atf_check_result_impl)); if (r->pimpl == NULL) return atf_no_memory_error(); err = array_to_list(argv, &r->pimpl->m_argv); if (atf_is_error(err)) goto out; err = atf_fs_path_copy(&r->pimpl->m_dir, dir); if (atf_is_error(err)) goto err_argv; err = atf_fs_path_init_fmt(&r->pimpl->m_stdout, "%s/stdout", atf_fs_path_cstring(dir)); if (atf_is_error(err)) goto err_dir; err = atf_fs_path_init_fmt(&r->pimpl->m_stderr, "%s/stderr", atf_fs_path_cstring(dir)); if (atf_is_error(err)) goto err_stdout; INV(!atf_is_error(err)); goto out; err_stdout: atf_fs_path_fini(&r->pimpl->m_stdout); err_dir: atf_fs_path_fini(&r->pimpl->m_dir); err_argv: atf_list_fini(&r->pimpl->m_argv); out: return err; } void atf_check_result_fini(atf_check_result_t *r) { atf_process_status_fini(&r->pimpl->m_status); cleanup_tmpdir(&r->pimpl->m_dir, &r->pimpl->m_stdout, &r->pimpl->m_stderr); atf_fs_path_fini(&r->pimpl->m_stdout); atf_fs_path_fini(&r->pimpl->m_stderr); atf_fs_path_fini(&r->pimpl->m_dir); atf_list_fini(&r->pimpl->m_argv); free(r->pimpl); } const char * atf_check_result_stdout(const atf_check_result_t *r) { return atf_fs_path_cstring(&r->pimpl->m_stdout); } const char * atf_check_result_stderr(const atf_check_result_t *r) { return atf_fs_path_cstring(&r->pimpl->m_stderr); } bool atf_check_result_exited(const atf_check_result_t *r) { return atf_process_status_exited(&r->pimpl->m_status); } int atf_check_result_exitcode(const atf_check_result_t *r) { return atf_process_status_exitstatus(&r->pimpl->m_status); } bool atf_check_result_signaled(const atf_check_result_t *r) { return atf_process_status_signaled(&r->pimpl->m_status); } int atf_check_result_termsig(const atf_check_result_t *r) { return atf_process_status_termsig(&r->pimpl->m_status); } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ /* XXX: This function shouldn't be in this module. It messes with stdout * and stderr, and it provides a very high-end interface. This belongs, * probably, somewhere related to test cases (such as in the tc module). */ atf_error_t atf_check_build_c_o(const char *sfile, const char *ofile, const char *const optargs[], bool *success) { atf_error_t err; char **argv; err = atf_build_c_o(sfile, ofile, optargs, &argv); if (atf_is_error(err)) goto out; err = check_build_run((const char *const *)argv, success); atf_utils_free_charpp(argv); out: return err; } atf_error_t atf_check_build_cpp(const char *sfile, const char *ofile, const char *const optargs[], bool *success) { atf_error_t err; char **argv; err = atf_build_cpp(sfile, ofile, optargs, &argv); if (atf_is_error(err)) goto out; err = check_build_run((const char *const *)argv, success); atf_utils_free_charpp(argv); out: return err; } atf_error_t atf_check_build_cxx_o(const char *sfile, const char *ofile, const char *const optargs[], bool *success) { atf_error_t err; char **argv; err = atf_build_cxx_o(sfile, ofile, optargs, &argv); if (atf_is_error(err)) goto out; err = check_build_run((const char *const *)argv, success); atf_utils_free_charpp(argv); out: return err; } atf_error_t atf_check_exec_array(const char *const *argv, atf_check_result_t *r) { atf_error_t err; atf_fs_path_t dir; err = create_tmpdir(&dir); if (atf_is_error(err)) goto out; err = atf_check_result_init(r, argv, &dir); if (atf_is_error(err)) { atf_error_t err2 = atf_fs_rmdir(&dir); INV(!atf_is_error(err2)); goto out; } err = fork_and_wait(argv, &r->pimpl->m_stdout, &r->pimpl->m_stderr, &r->pimpl->m_status); if (atf_is_error(err)) { atf_check_result_fini(r); goto out; } INV(!atf_is_error(err)); atf_fs_path_fini(&dir); out: return err; } Index: head/contrib/atf/atf-c/check.h =================================================================== --- head/contrib/atf/atf-c/check.h (revision 273928) +++ head/contrib/atf/atf-c/check.h (revision 273929) @@ -1,73 +1,69 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_CHECK_H) #define ATF_C_CHECK_H #include #include /* --------------------------------------------------------------------- * The "atf_check_result" type. * --------------------------------------------------------------------- */ struct atf_check_result_impl; struct atf_check_result { struct atf_check_result_impl *pimpl; }; typedef struct atf_check_result atf_check_result_t; /* Construtors and destructors */ void atf_check_result_fini(atf_check_result_t *); /* Getters */ const char *atf_check_result_stdout(const atf_check_result_t *); const char *atf_check_result_stderr(const atf_check_result_t *); bool atf_check_result_exited(const atf_check_result_t *); int atf_check_result_exitcode(const atf_check_result_t *); bool atf_check_result_signaled(const atf_check_result_t *); int atf_check_result_termsig(const atf_check_result_t *); /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_check_build_c_o(const char *, const char *, const char *const [], bool *); atf_error_t atf_check_build_cpp(const char *, const char *, const char *const [], bool *); atf_error_t atf_check_build_cxx_o(const char *, const char *, const char *const [], bool *); atf_error_t atf_check_exec_array(const char *const *, atf_check_result_t *); -#endif /* ATF_C_CHECK_H */ +#endif /* !defined(ATF_C_CHECK_H) */ Index: head/contrib/atf/atf-c/check_test.c =================================================================== --- head/contrib/atf/atf-c/check_test.c (revision 273928) +++ head/contrib/atf/atf-c/check_test.c (revision 273929) @@ -1,539 +1,521 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/check.h" + #include #include #include #include #include #include #include -#include "atf-c/check.h" -#include "atf-c/config.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/map.h" +#include "atf-c/detail/process.h" +#include "atf-c/detail/test_helpers.h" -#include "detail/fs.h" -#include "detail/map.h" -#include "detail/process.h" -#include "detail/test_helpers.h" - /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void do_exec(const atf_tc_t *tc, const char *helper_name, atf_check_result_t *r) { atf_fs_path_t process_helpers; const char *argv[3]; get_process_helpers_path(tc, false, &process_helpers); argv[0] = atf_fs_path_cstring(&process_helpers); argv[1] = helper_name; argv[2] = NULL; printf("Executing %s %s\n", argv[0], argv[1]); RE(atf_check_exec_array(argv, r)); atf_fs_path_fini(&process_helpers); } static void do_exec_with_arg(const atf_tc_t *tc, const char *helper_name, const char *arg, atf_check_result_t *r) { atf_fs_path_t process_helpers; const char *argv[4]; get_process_helpers_path(tc, false, &process_helpers); argv[0] = atf_fs_path_cstring(&process_helpers); argv[1] = helper_name; argv[2] = arg; argv[3] = NULL; printf("Executing %s %s %s\n", argv[0], argv[1], argv[2]); RE(atf_check_exec_array(argv, r)); atf_fs_path_fini(&process_helpers); } static void check_line(int fd, const char *exp) { char *line = atf_utils_readline(fd); ATF_CHECK(line != NULL); ATF_CHECK_STREQ_MSG(exp, line, "read: '%s', expected: '%s'", line, exp); free(line); } /* --------------------------------------------------------------------- * Helper test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(h_build_c_o_ok); ATF_TC_HEAD(h_build_c_o_ok, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_c_o"); } ATF_TC_BODY(h_build_c_o_ok, tc) { FILE *sfile; bool success; ATF_REQUIRE((sfile = fopen("test.c", "w")) != NULL); fprintf(sfile, "#include \n"); fclose(sfile); RE(atf_check_build_c_o("test.c", "test.o", NULL, &success)); ATF_REQUIRE(success); } ATF_TC(h_build_c_o_fail); ATF_TC_HEAD(h_build_c_o_fail, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_c_o"); } ATF_TC_BODY(h_build_c_o_fail, tc) { FILE *sfile; bool success; ATF_REQUIRE((sfile = fopen("test.c", "w")) != NULL); fprintf(sfile, "void foo(void) { int a = UNDEFINED_SYMBOL; }\n"); fclose(sfile); RE(atf_check_build_c_o("test.c", "test.o", NULL, &success)); ATF_REQUIRE(!success); } ATF_TC(h_build_cpp_ok); ATF_TC_HEAD(h_build_cpp_ok, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_cpp"); } ATF_TC_BODY(h_build_cpp_ok, tc) { FILE *sfile; bool success; atf_fs_path_t test_p; RE(atf_fs_path_init_fmt(&test_p, "test.p")); ATF_REQUIRE((sfile = fopen("test.c", "w")) != NULL); fprintf(sfile, "#define A foo\n"); fprintf(sfile, "#define B bar\n"); fprintf(sfile, "A B\n"); fclose(sfile); RE(atf_check_build_cpp("test.c", atf_fs_path_cstring(&test_p), NULL, &success)); ATF_REQUIRE(success); atf_fs_path_fini(&test_p); } ATF_TC(h_build_cpp_fail); ATF_TC_HEAD(h_build_cpp_fail, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_cpp"); } ATF_TC_BODY(h_build_cpp_fail, tc) { FILE *sfile; bool success; ATF_REQUIRE((sfile = fopen("test.c", "w")) != NULL); fprintf(sfile, "#include \"./non-existent.h\"\n"); fclose(sfile); RE(atf_check_build_cpp("test.c", "test.p", NULL, &success)); ATF_REQUIRE(!success); } ATF_TC(h_build_cxx_o_ok); ATF_TC_HEAD(h_build_cxx_o_ok, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_cxx_o"); } ATF_TC_BODY(h_build_cxx_o_ok, tc) { FILE *sfile; bool success; ATF_REQUIRE((sfile = fopen("test.cpp", "w")) != NULL); fprintf(sfile, "#include \n"); fclose(sfile); RE(atf_check_build_cxx_o("test.cpp", "test.o", NULL, &success)); ATF_REQUIRE(success); } ATF_TC(h_build_cxx_o_fail); ATF_TC_HEAD(h_build_cxx_o_fail, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for build_cxx_o"); } ATF_TC_BODY(h_build_cxx_o_fail, tc) { FILE *sfile; bool success; ATF_REQUIRE((sfile = fopen("test.cpp", "w")) != NULL); fprintf(sfile, "void foo(void) { int a = UNDEFINED_SYMBOL; }\n"); fclose(sfile); RE(atf_check_build_cxx_o("test.cpp", "test.o", NULL, &success)); ATF_REQUIRE(!success); } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ static void init_and_run_h_tc(atf_tc_t *tc, const atf_tc_pack_t *tcpack, const char *outname, const char *errname) { const char *const config[] = { NULL }; RE(atf_tc_init_pack(tc, tcpack, config)); run_h_tc(tc, outname, errname, "result"); atf_tc_fini(tc); } ATF_TC(build_c_o); ATF_TC_HEAD(build_c_o, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_check_build_c_o " "function"); } ATF_TC_BODY(build_c_o, tc) { init_and_run_h_tc(&ATF_TC_NAME(h_build_c_o_ok), &ATF_TC_PACK_NAME(h_build_c_o_ok), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o test.o", "stdout")); ATF_CHECK(atf_utils_grep_file("-c test.c", "stdout")); init_and_run_h_tc(&ATF_TC_NAME(h_build_c_o_fail), &ATF_TC_PACK_NAME(h_build_c_o_fail), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o test.o", "stdout")); ATF_CHECK(atf_utils_grep_file("-c test.c", "stdout")); ATF_CHECK(atf_utils_grep_file("test.c", "stderr")); ATF_CHECK(atf_utils_grep_file("UNDEFINED_SYMBOL", "stderr")); } ATF_TC(build_cpp); ATF_TC_HEAD(build_cpp, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_check_build_cpp " "function"); } ATF_TC_BODY(build_cpp, tc) { init_and_run_h_tc(&ATF_TC_NAME(h_build_cpp_ok), &ATF_TC_PACK_NAME(h_build_cpp_ok), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o.*test.p", "stdout")); ATF_CHECK(atf_utils_grep_file("test.c", "stdout")); ATF_CHECK(atf_utils_grep_file("foo bar", "test.p")); init_and_run_h_tc(&ATF_TC_NAME(h_build_cpp_fail), &ATF_TC_PACK_NAME(h_build_cpp_fail), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o test.p", "stdout")); ATF_CHECK(atf_utils_grep_file("test.c", "stdout")); ATF_CHECK(atf_utils_grep_file("test.c", "stderr")); ATF_CHECK(atf_utils_grep_file("non-existent.h", "stderr")); } ATF_TC(build_cxx_o); ATF_TC_HEAD(build_cxx_o, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_check_build_cxx_o " "function"); } ATF_TC_BODY(build_cxx_o, tc) { init_and_run_h_tc(&ATF_TC_NAME(h_build_cxx_o_ok), &ATF_TC_PACK_NAME(h_build_cxx_o_ok), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o test.o", "stdout")); ATF_CHECK(atf_utils_grep_file("-c test.cpp", "stdout")); init_and_run_h_tc(&ATF_TC_NAME(h_build_cxx_o_fail), &ATF_TC_PACK_NAME(h_build_cxx_o_fail), "stdout", "stderr"); ATF_CHECK(atf_utils_grep_file("-o test.o", "stdout")); ATF_CHECK(atf_utils_grep_file("-c test.cpp", "stdout")); ATF_CHECK(atf_utils_grep_file("test.cpp", "stderr")); ATF_CHECK(atf_utils_grep_file("UNDEFINED_SYMBOL", "stderr")); } ATF_TC(exec_array); ATF_TC_HEAD(exec_array, tc) { atf_tc_set_md_var(tc, "descr", "Checks that atf_check_exec_array " "works properly"); } ATF_TC_BODY(exec_array, tc) { atf_fs_path_t process_helpers; atf_check_result_t result; get_process_helpers_path(tc, false, &process_helpers); const char *argv[4]; argv[0] = atf_fs_path_cstring(&process_helpers); argv[1] = "echo"; argv[2] = "test-message"; argv[3] = NULL; RE(atf_check_exec_array(argv, &result)); ATF_CHECK(atf_check_result_exited(&result)); ATF_CHECK(atf_check_result_exitcode(&result) == EXIT_SUCCESS); { const char *path = atf_check_result_stdout(&result); int fd = open(path, O_RDONLY); ATF_CHECK(fd != -1); check_line(fd, "test-message"); close(fd); } atf_check_result_fini(&result); atf_fs_path_fini(&process_helpers); } ATF_TC(exec_cleanup); ATF_TC_HEAD(exec_cleanup, tc) { atf_tc_set_md_var(tc, "descr", "Checks that atf_check_exec_array " "properly cleans up the temporary files it creates"); } ATF_TC_BODY(exec_cleanup, tc) { atf_fs_path_t out, err; atf_check_result_t result; bool exists; do_exec(tc, "exit-success", &result); RE(atf_fs_path_init_fmt(&out, "%s", atf_check_result_stdout(&result))); RE(atf_fs_path_init_fmt(&err, "%s", atf_check_result_stderr(&result))); RE(atf_fs_exists(&out, &exists)); ATF_CHECK(exists); RE(atf_fs_exists(&err, &exists)); ATF_CHECK(exists); atf_check_result_fini(&result); RE(atf_fs_exists(&out, &exists)); ATF_CHECK(!exists); RE(atf_fs_exists(&err, &exists)); ATF_CHECK(!exists); atf_fs_path_fini(&err); atf_fs_path_fini(&out); } ATF_TC(exec_exitstatus); ATF_TC_HEAD(exec_exitstatus, tc) { atf_tc_set_md_var(tc, "descr", "Checks that atf_check_exec_array " "properly captures the exit status of the executed " "command"); } ATF_TC_BODY(exec_exitstatus, tc) { { atf_check_result_t result; do_exec(tc, "exit-success", &result); ATF_CHECK(atf_check_result_exited(&result)); ATF_CHECK(!atf_check_result_signaled(&result)); ATF_CHECK(atf_check_result_exitcode(&result) == EXIT_SUCCESS); atf_check_result_fini(&result); } { atf_check_result_t result; do_exec(tc, "exit-failure", &result); ATF_CHECK(atf_check_result_exited(&result)); ATF_CHECK(!atf_check_result_signaled(&result)); ATF_CHECK(atf_check_result_exitcode(&result) == EXIT_FAILURE); atf_check_result_fini(&result); } { atf_check_result_t result; do_exec(tc, "exit-signal", &result); ATF_CHECK(!atf_check_result_exited(&result)); ATF_CHECK(atf_check_result_signaled(&result)); ATF_CHECK(atf_check_result_termsig(&result) == SIGKILL); atf_check_result_fini(&result); } } ATF_TC(exec_stdout_stderr); ATF_TC_HEAD(exec_stdout_stderr, tc) { atf_tc_set_md_var(tc, "descr", "Checks that atf_check_exec_array " "properly captures the stdout and stderr streams " "of the child process"); } ATF_TC_BODY(exec_stdout_stderr, tc) { atf_check_result_t result1, result2; const char *out1, *out2; const char *err1, *err2; do_exec_with_arg(tc, "stdout-stderr", "result1", &result1); ATF_CHECK(atf_check_result_exited(&result1)); ATF_CHECK(atf_check_result_exitcode(&result1) == EXIT_SUCCESS); do_exec_with_arg(tc, "stdout-stderr", "result2", &result2); ATF_CHECK(atf_check_result_exited(&result2)); ATF_CHECK(atf_check_result_exitcode(&result2) == EXIT_SUCCESS); out1 = atf_check_result_stdout(&result1); out2 = atf_check_result_stdout(&result2); err1 = atf_check_result_stderr(&result1); err2 = atf_check_result_stderr(&result2); ATF_CHECK(strstr(out1, "check.XXXXXX") == NULL); ATF_CHECK(strstr(out2, "check.XXXXXX") == NULL); ATF_CHECK(strstr(err1, "check.XXXXXX") == NULL); ATF_CHECK(strstr(err2, "check.XXXXXX") == NULL); ATF_CHECK(strstr(out1, "/check") != NULL); ATF_CHECK(strstr(out2, "/check") != NULL); ATF_CHECK(strstr(err1, "/check") != NULL); ATF_CHECK(strstr(err2, "/check") != NULL); ATF_CHECK(strstr(out1, "/stdout") != NULL); ATF_CHECK(strstr(out2, "/stdout") != NULL); ATF_CHECK(strstr(err1, "/stderr") != NULL); ATF_CHECK(strstr(err2, "/stderr") != NULL); ATF_CHECK(strcmp(out1, out2) != 0); ATF_CHECK(strcmp(err1, err2) != 0); #define CHECK_LINES(path, outname, resname) \ do { \ int fd = open(path, O_RDONLY); \ ATF_CHECK(fd != -1); \ check_line(fd, "Line 1 to " outname " for " resname); \ check_line(fd, "Line 2 to " outname " for " resname); \ close(fd); \ } while (false) CHECK_LINES(out1, "stdout", "result1"); CHECK_LINES(out2, "stdout", "result2"); CHECK_LINES(err1, "stderr", "result1"); CHECK_LINES(err2, "stderr", "result2"); #undef CHECK_LINES atf_check_result_fini(&result2); atf_check_result_fini(&result1); } ATF_TC(exec_umask); ATF_TC_HEAD(exec_umask, tc) { atf_tc_set_md_var(tc, "descr", "Checks that atf_check_exec_array " "correctly reports an error if the umask is too " "restrictive to create temporary files"); } ATF_TC_BODY(exec_umask, tc) { atf_check_result_t result; atf_fs_path_t process_helpers; const char *argv[3]; get_process_helpers_path(tc, false, &process_helpers); argv[0] = atf_fs_path_cstring(&process_helpers); argv[1] = "exit-success"; argv[2] = NULL; umask(0222); atf_error_t err = atf_check_exec_array(argv, &result); ATF_CHECK(atf_is_error(err)); ATF_CHECK(atf_error_is(err, "invalid_umask")); atf_error_free(err); atf_fs_path_fini(&process_helpers); } ATF_TC(exec_unknown); ATF_TC_HEAD(exec_unknown, tc) { atf_tc_set_md_var(tc, "descr", "Checks that running a non-existing " "binary is handled correctly"); } ATF_TC_BODY(exec_unknown, tc) { - char buf[1024]; - snprintf(buf, sizeof(buf), "%s/non-existent", - atf_config_get("atf_workdir")); - const char *argv[2]; - argv[0] = buf; + argv[0] = "/foo/bar/non-existent"; argv[1] = NULL; atf_check_result_t result; RE(atf_check_exec_array(argv, &result)); ATF_CHECK(atf_check_result_exited(&result)); ATF_CHECK(atf_check_result_exitcode(&result) == 127); atf_check_result_fini(&result); } /* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/check.h"); - -/* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the test cases for the free functions. */ ATF_TP_ADD_TC(tp, build_c_o); ATF_TP_ADD_TC(tp, build_cpp); ATF_TP_ADD_TC(tp, build_cxx_o); ATF_TP_ADD_TC(tp, exec_array); ATF_TP_ADD_TC(tp, exec_cleanup); ATF_TP_ADD_TC(tp, exec_exitstatus); ATF_TP_ADD_TC(tp, exec_stdout_stderr); ATF_TP_ADD_TC(tp, exec_umask); ATF_TP_ADD_TC(tp, exec_unknown); - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c/defs.h.in =================================================================== --- head/contrib/atf/atf-c/defs.h.in (revision 273928) +++ head/contrib/atf/atf-c/defs.h.in (revision 273929) @@ -1,37 +1,33 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_DEFS_H) #define ATF_C_DEFS_H #define ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(a, b) @ATTRIBUTE_FORMAT_PRINTF@ #define ATF_DEFS_ATTRIBUTE_NORETURN @ATTRIBUTE_NORETURN@ #define ATF_DEFS_ATTRIBUTE_UNUSED @ATTRIBUTE_UNUSED@ #endif /* !defined(ATF_C_DEFS_H) */ Index: head/contrib/atf/atf-c/detail/dynstr.c =================================================================== --- head/contrib/atf/atf-c/detail/dynstr.c (revision 273928) +++ head/contrib/atf/atf-c/detail/dynstr.c (revision 273929) @@ -1,398 +1,394 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/dynstr.h" + #include #include #include #include #include #include +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/text.h" #include "atf-c/error.h" - -#include "dynstr.h" -#include "sanity.h" -#include "text.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static atf_error_t resize(atf_dynstr_t *ad, size_t newsize) { char *newdata; atf_error_t err; PRE(newsize > ad->m_datasize); newdata = (char *)malloc(newsize); if (newdata == NULL) { err = atf_no_memory_error(); } else { strcpy(newdata, ad->m_data); free(ad->m_data); ad->m_data = newdata; ad->m_datasize = newsize; err = atf_no_error(); } return err; } static atf_error_t prepend_or_append(atf_dynstr_t *ad, const char *fmt, va_list ap, bool prepend) { char *aux; atf_error_t err; size_t newlen; va_list ap2; va_copy(ap2, ap); err = atf_text_format_ap(&aux, fmt, ap2); va_end(ap2); if (atf_is_error(err)) goto out; newlen = ad->m_length + strlen(aux); if (newlen + sizeof(char) > ad->m_datasize) { err = resize(ad, newlen + sizeof(char)); if (atf_is_error(err)) goto out_free; } if (prepend) { memmove(ad->m_data + strlen(aux), ad->m_data, ad->m_length + 1); memcpy(ad->m_data, aux, strlen(aux)); } else strcpy(ad->m_data + ad->m_length, aux); ad->m_length = newlen; err = atf_no_error(); out_free: free(aux); out: return err; } /* --------------------------------------------------------------------- * The "atf_dynstr" type. * --------------------------------------------------------------------- */ /* * Constants. */ const size_t atf_dynstr_npos = SIZE_MAX; /* * Constructors and destructors. */ atf_error_t atf_dynstr_init(atf_dynstr_t *ad) { atf_error_t err; ad->m_data = (char *)malloc(sizeof(char)); if (ad->m_data == NULL) { err = atf_no_memory_error(); goto out; } ad->m_data[0] = '\0'; ad->m_datasize = 1; ad->m_length = 0; err = atf_no_error(); out: return err; } atf_error_t atf_dynstr_init_ap(atf_dynstr_t *ad, const char *fmt, va_list ap) { atf_error_t err; ad->m_datasize = strlen(fmt) + 1; ad->m_length = 0; do { va_list ap2; int ret; ad->m_datasize *= 2; ad->m_data = (char *)malloc(ad->m_datasize); if (ad->m_data == NULL) { err = atf_no_memory_error(); goto out; } va_copy(ap2, ap); ret = vsnprintf(ad->m_data, ad->m_datasize, fmt, ap2); va_end(ap2); if (ret < 0) { free(ad->m_data); err = atf_libc_error(errno, "Cannot format string"); goto out; } INV(ret >= 0); if ((size_t)ret >= ad->m_datasize) { free(ad->m_data); ad->m_data = NULL; } ad->m_length = ret; } while (ad->m_length >= ad->m_datasize); err = atf_no_error(); out: POST(atf_is_error(err) || ad->m_data != NULL); return err; } atf_error_t atf_dynstr_init_fmt(atf_dynstr_t *ad, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_dynstr_init_ap(ad, fmt, ap); va_end(ap); return err; } atf_error_t atf_dynstr_init_raw(atf_dynstr_t *ad, const void *mem, size_t memlen) { atf_error_t err; if (memlen >= SIZE_MAX - 1) { err = atf_no_memory_error(); goto out; } ad->m_data = (char *)malloc(memlen + 1); if (ad->m_data == NULL) { err = atf_no_memory_error(); goto out; } ad->m_datasize = memlen + 1; memcpy(ad->m_data, mem, memlen); ad->m_data[memlen] = '\0'; ad->m_length = strlen(ad->m_data); INV(ad->m_length <= memlen); err = atf_no_error(); out: return err; } atf_error_t atf_dynstr_init_rep(atf_dynstr_t *ad, size_t len, char ch) { atf_error_t err; if (len == SIZE_MAX) { err = atf_no_memory_error(); goto out; } ad->m_datasize = (len + 1) * sizeof(char); ad->m_data = (char *)malloc(ad->m_datasize); if (ad->m_data == NULL) { err = atf_no_memory_error(); goto out; } memset(ad->m_data, ch, len); ad->m_data[len] = '\0'; ad->m_length = len; err = atf_no_error(); out: return err; } atf_error_t atf_dynstr_init_substr(atf_dynstr_t *ad, const atf_dynstr_t *src, size_t beg, size_t end) { if (beg > src->m_length) beg = src->m_length; if (end == atf_dynstr_npos || end > src->m_length) end = src->m_length; return atf_dynstr_init_raw(ad, src->m_data + beg, end - beg); } atf_error_t atf_dynstr_copy(atf_dynstr_t *dest, const atf_dynstr_t *src) { atf_error_t err; dest->m_data = (char *)malloc(src->m_datasize); if (dest->m_data == NULL) err = atf_no_memory_error(); else { memcpy(dest->m_data, src->m_data, src->m_datasize); dest->m_datasize = src->m_datasize; dest->m_length = src->m_length; err = atf_no_error(); } return err; } void atf_dynstr_fini(atf_dynstr_t *ad) { INV(ad->m_data != NULL); free(ad->m_data); } char * atf_dynstr_fini_disown(atf_dynstr_t *ad) { INV(ad->m_data != NULL); return ad->m_data; } /* * Getters. */ const char * atf_dynstr_cstring(const atf_dynstr_t *ad) { return ad->m_data; } size_t atf_dynstr_length(const atf_dynstr_t *ad) { return ad->m_length; } size_t atf_dynstr_rfind_ch(const atf_dynstr_t *ad, char ch) { size_t pos; for (pos = ad->m_length; pos > 0 && ad->m_data[pos - 1] != ch; pos--) ; return pos == 0 ? atf_dynstr_npos : pos - 1; } /* * Modifiers. */ atf_error_t atf_dynstr_append_ap(atf_dynstr_t *ad, const char *fmt, va_list ap) { atf_error_t err; va_list ap2; va_copy(ap2, ap); err = prepend_or_append(ad, fmt, ap2, false); va_end(ap2); return err; } atf_error_t atf_dynstr_append_fmt(atf_dynstr_t *ad, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = prepend_or_append(ad, fmt, ap, false); va_end(ap); return err; } void atf_dynstr_clear(atf_dynstr_t *ad) { ad->m_data[0] = '\0'; ad->m_length = 0; } atf_error_t atf_dynstr_prepend_ap(atf_dynstr_t *ad, const char *fmt, va_list ap) { atf_error_t err; va_list ap2; va_copy(ap2, ap); err = prepend_or_append(ad, fmt, ap2, true); va_end(ap2); return err; } atf_error_t atf_dynstr_prepend_fmt(atf_dynstr_t *ad, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = prepend_or_append(ad, fmt, ap, true); va_end(ap); return err; } /* * Operators. */ bool atf_equal_dynstr_cstring(const atf_dynstr_t *ad, const char *str) { return strcmp(ad->m_data, str) == 0; } bool atf_equal_dynstr_dynstr(const atf_dynstr_t *s1, const atf_dynstr_t *s2) { return strcmp(s1->m_data, s2->m_data) == 0; } Index: head/contrib/atf/atf-c/detail/dynstr.h =================================================================== --- head/contrib/atf/atf-c/detail/dynstr.h (revision 273928) +++ head/contrib/atf/atf-c/detail/dynstr.h (revision 273929) @@ -1,81 +1,77 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_DYNSTR_H) -#define ATF_C_DYNSTR_H +#if !defined(ATF_C_DETAIL_DYNSTR_H) +#define ATF_C_DETAIL_DYNSTR_H #include #include #include #include /* --------------------------------------------------------------------- * The "atf_dynstr" type. * --------------------------------------------------------------------- */ struct atf_dynstr { char *m_data; size_t m_datasize; size_t m_length; }; typedef struct atf_dynstr atf_dynstr_t; /* Constants */ extern const size_t atf_dynstr_npos; /* Constructors and destructors */ atf_error_t atf_dynstr_init(atf_dynstr_t *); atf_error_t atf_dynstr_init_ap(atf_dynstr_t *, const char *, va_list); atf_error_t atf_dynstr_init_fmt(atf_dynstr_t *, const char *, ...); atf_error_t atf_dynstr_init_raw(atf_dynstr_t *, const void *, size_t); atf_error_t atf_dynstr_init_rep(atf_dynstr_t *, size_t, char); atf_error_t atf_dynstr_init_substr(atf_dynstr_t *, const atf_dynstr_t *, size_t, size_t); atf_error_t atf_dynstr_copy(atf_dynstr_t *, const atf_dynstr_t *); void atf_dynstr_fini(atf_dynstr_t *); char *atf_dynstr_fini_disown(atf_dynstr_t *); /* Getters */ const char *atf_dynstr_cstring(const atf_dynstr_t *); size_t atf_dynstr_length(const atf_dynstr_t *); size_t atf_dynstr_rfind_ch(const atf_dynstr_t *, char); /* Modifiers */ atf_error_t atf_dynstr_append_ap(atf_dynstr_t *, const char *, va_list); atf_error_t atf_dynstr_append_fmt(atf_dynstr_t *, const char *, ...); void atf_dynstr_clear(atf_dynstr_t *); atf_error_t atf_dynstr_prepend_ap(atf_dynstr_t *, const char *, va_list); atf_error_t atf_dynstr_prepend_fmt(atf_dynstr_t *, const char *, ...); /* Operators */ bool atf_equal_dynstr_cstring(const atf_dynstr_t *, const char *); bool atf_equal_dynstr_dynstr(const atf_dynstr_t *, const atf_dynstr_t *); -#endif /* ATF_C_DYNSTR_H */ +#endif /* !defined(ATF_C_DETAIL_DYNSTR_H) */ Index: head/contrib/atf/atf-c/detail/dynstr_test.c =================================================================== --- head/contrib/atf/atf-c/detail/dynstr_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/dynstr_test.c (revision 273929) @@ -1,637 +1,634 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/dynstr.h" + #include #include #include #include #include #include -#include "dynstr.h" -#include "test_helpers.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Tests for the "atf_dynstr" type. * --------------------------------------------------------------------- */ /* * Constructors and destructors. */ ATF_TC(init); ATF_TC_HEAD(init, tc) { atf_tc_set_md_var(tc, "descr", "Checks the empty constructor"); } ATF_TC_BODY(init, tc) { atf_dynstr_t str; RE(atf_dynstr_init(&str)); ATF_REQUIRE_EQ(atf_dynstr_length(&str), 0); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); } static void init_fmt(atf_dynstr_t *str, const char *fmt, ...) { va_list ap; va_start(ap, fmt); RE(atf_dynstr_init_ap(str, fmt, ap)); va_end(ap); } ATF_TC(init_ap); ATF_TC_HEAD(init_ap, tc) { atf_tc_set_md_var(tc, "descr", "Checks the formatted constructor using " "a va_list argument"); } ATF_TC_BODY(init_ap, tc) { atf_dynstr_t str; init_fmt(&str, "String 1"); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 1") == 0); atf_dynstr_fini(&str); init_fmt(&str, "String %d", 2); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 2") == 0); atf_dynstr_fini(&str); init_fmt(&str, "%s %d", "String", 3); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 3") == 0); atf_dynstr_fini(&str); init_fmt(&str, "%s%s%s%s%s%s%s", "This ", "should ", "be ", "a ", "large ", "string ", "aaaabbbbccccdddd"); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "This should be a large string " "aaaabbbbccccdddd") == 0); atf_dynstr_fini(&str); } ATF_TC(init_fmt); ATF_TC_HEAD(init_fmt, tc) { atf_tc_set_md_var(tc, "descr", "Checks the formatted constructor using " "a variable list of parameters"); } ATF_TC_BODY(init_fmt, tc) { atf_dynstr_t str; RE(atf_dynstr_init_fmt(&str, "String 1")); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 1") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_fmt(&str, "String %d", 2)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 2") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_fmt(&str, "%s %d", "String", 3)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 3") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_fmt(&str, "%s%s%s%s%s%s%s", "This ", "should ", "be ", "a ", "large ", "string ", "aaaabbbbccccdddd")); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "This should be a large string " "aaaabbbbccccdddd") == 0); atf_dynstr_fini(&str); } ATF_TC(init_raw); ATF_TC_HEAD(init_raw, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of a string " "using a raw memory pointer"); } ATF_TC_BODY(init_raw, tc) { const char *src = "String 1, String 2"; atf_dynstr_t str; RE(atf_dynstr_init_raw(&str, src, 0)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_raw(&str, src, 8)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 1") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_raw(&str, src + 10, 8)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String 2") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_raw(&str, "String\0Lost", 11)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "String") == 0); atf_dynstr_fini(&str); { atf_error_t err = atf_dynstr_init_raw(&str, "NULL", SIZE_MAX - 1); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "no_memory")); atf_error_free(err); } } ATF_TC(init_rep); ATF_TC_HEAD(init_rep, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of a string by " "repeating characters"); } ATF_TC_BODY(init_rep, tc) { const size_t maxlen = 8192; char buf[maxlen + 1]; size_t i; buf[0] = '\0'; for (i = 0; i < maxlen; i++) { atf_dynstr_t str; RE(atf_dynstr_init_rep(&str, i, 'a')); if (strcmp(atf_dynstr_cstring(&str), buf) != 0) { fprintf(stderr, "Failed at iteration %zd\n", i); atf_tc_fail("Failed to construct dynstr by repeating %zd " "times the '%c' character", i, 'a'); } atf_dynstr_fini(&str); strcat(buf, "a"); } { atf_dynstr_t str; atf_error_t err; err = atf_dynstr_init_rep(&str, SIZE_MAX, 'a'); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "no_memory")); atf_error_free(err); err = atf_dynstr_init_rep(&str, SIZE_MAX - 1, 'a'); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "no_memory")); atf_error_free(err); } } ATF_TC(init_substr); ATF_TC_HEAD(init_substr, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of a string " "using a substring of another one"); } ATF_TC_BODY(init_substr, tc) { atf_dynstr_t src; atf_dynstr_t str; RE(atf_dynstr_init_fmt(&src, "Str 1, Str 2")); RE(atf_dynstr_init_substr(&str, &src, 0, 0)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_substr(&str, &src, 0, atf_dynstr_npos)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "Str 1, Str 2") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_substr(&str, &src, 0, 100)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "Str 1, Str 2") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_substr(&str, &src, 0, 5)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "Str 1") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_substr(&str, &src, 100, atf_dynstr_npos)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_substr(&str, &src, 7, atf_dynstr_npos)); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "Str 2") == 0); atf_dynstr_fini(&str); atf_dynstr_fini(&src); } ATF_TC(copy); ATF_TC_HEAD(copy, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_dynstr_copy constructor"); } ATF_TC_BODY(copy, tc) { atf_dynstr_t str, str2; RE(atf_dynstr_init_fmt(&str, "Test string")); RE(atf_dynstr_copy(&str2, &str)); ATF_REQUIRE(atf_equal_dynstr_dynstr(&str, &str2)); RE(atf_dynstr_append_fmt(&str2, " non-shared text")); ATF_REQUIRE(!atf_equal_dynstr_dynstr(&str, &str2)); atf_dynstr_fini(&str2); atf_dynstr_fini(&str); } ATF_TC(fini_disown); ATF_TC_HEAD(fini_disown, tc) { atf_tc_set_md_var(tc, "descr", "Checks grabbing ownership of the " "internal plain C string"); } ATF_TC_BODY(fini_disown, tc) { const char *cstr; char *cstr2; atf_dynstr_t str; RE(atf_dynstr_init_fmt(&str, "Test string 1")); cstr = atf_dynstr_cstring(&str); cstr2 = atf_dynstr_fini_disown(&str); ATF_REQUIRE_EQ(cstr, cstr2); free(cstr2); } /* * Getters. */ ATF_TC(cstring); ATF_TC_HEAD(cstring, tc) { atf_tc_set_md_var(tc, "descr", "Checks the method to obtain a plain C " "string"); } ATF_TC_BODY(cstring, tc) { const char *cstr; atf_dynstr_t str; RE(atf_dynstr_init_fmt(&str, "Test string 1")); cstr = atf_dynstr_cstring(&str); ATF_REQUIRE(cstr != NULL); ATF_REQUIRE(strcmp(cstr, "Test string 1") == 0); atf_dynstr_fini(&str); RE(atf_dynstr_init_fmt(&str, "Test string 2")); cstr = atf_dynstr_cstring(&str); ATF_REQUIRE(cstr != NULL); ATF_REQUIRE(strcmp(cstr, "Test string 2") == 0); atf_dynstr_fini(&str); } ATF_TC(length); ATF_TC_HEAD(length, tc) { atf_tc_set_md_var(tc, "descr", "Checks the method to obtain the length"); } ATF_TC_BODY(length, tc) { size_t i; for (i = 0; i < 8192; i++) { atf_dynstr_t str; RE(atf_dynstr_init_rep(&str, i, 'a')); ATF_REQUIRE_EQ(atf_dynstr_length(&str), i); atf_dynstr_fini(&str); } } ATF_TC(rfind_ch); ATF_TC_HEAD(rfind_ch, tc) { atf_tc_set_md_var(tc, "descr", "Checks the method to locate the first " "occurrence of a character starting from the end"); } ATF_TC_BODY(rfind_ch, tc) { atf_dynstr_t str; RE(atf_dynstr_init_fmt(&str, "Foo1/Bar2/,.Baz")); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, '\0'), atf_dynstr_npos); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, '0'), atf_dynstr_npos); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, 'b'), atf_dynstr_npos); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, 'F'), 0); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, '/'), 9); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, 'a'), 13); ATF_REQUIRE_EQ(atf_dynstr_rfind_ch(&str, 'z'), 14); atf_dynstr_fini(&str); } /* * Modifiers. */ static void check_append(atf_error_t (*append)(atf_dynstr_t *, const char *, ...)) { const size_t maxlen = 8192; char buf[maxlen + 1]; size_t i; atf_dynstr_t str; printf("Appending with plain string\n"); buf[0] = '\0'; RE(atf_dynstr_init(&str)); for (i = 0; i < maxlen; i++) { if (strcmp(atf_dynstr_cstring(&str), buf) != 0) { fprintf(stderr, "Failed at iteration %zd\n", i); atf_tc_fail("Failed to append character at iteration %zd", i); } RE(append(&str, "a")); strcat(buf, "a"); } atf_dynstr_fini(&str); printf("Appending with formatted string\n"); buf[0] = '\0'; RE(atf_dynstr_init(&str)); for (i = 0; i < maxlen; i++) { if (strcmp(atf_dynstr_cstring(&str), buf) != 0) { fprintf(stderr, "Failed at iteration %zd\n", i); atf_tc_fail("Failed to append character at iteration %zd", i); } RE(append(&str, "%s", "a")); strcat(buf, "a"); } atf_dynstr_fini(&str); } static atf_error_t append_ap_aux(atf_dynstr_t *str, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_dynstr_append_ap(str, fmt, ap); va_end(ap); return err; } ATF_TC(append_ap); ATF_TC_HEAD(append_ap, tc) { atf_tc_set_md_var(tc, "descr", "Checks that appending a string to " "another one works"); } ATF_TC_BODY(append_ap, tc) { check_append(append_ap_aux); } ATF_TC(append_fmt); ATF_TC_HEAD(append_fmt, tc) { atf_tc_set_md_var(tc, "descr", "Checks that appending a string to " "another one works"); } ATF_TC_BODY(append_fmt, tc) { check_append(atf_dynstr_append_fmt); } ATF_TC(clear); ATF_TC_HEAD(clear, tc) { atf_tc_set_md_var(tc, "descr", "Checks clearing a string"); } ATF_TC_BODY(clear, tc) { atf_dynstr_t str; printf("Clear an empty string\n"); RE(atf_dynstr_init(&str)); atf_dynstr_clear(&str); ATF_REQUIRE_EQ(atf_dynstr_length(&str), 0); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); printf("Clear a non-empty string\n"); RE(atf_dynstr_init_fmt(&str, "Not empty")); ATF_REQUIRE_EQ(atf_dynstr_length(&str), strlen("Not empty")); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "Not empty") == 0); atf_dynstr_clear(&str); ATF_REQUIRE_EQ(atf_dynstr_length(&str), 0); ATF_REQUIRE(strcmp(atf_dynstr_cstring(&str), "") == 0); atf_dynstr_fini(&str); } static void check_prepend(atf_error_t (*prepend)(atf_dynstr_t *, const char *, ...)) { const size_t maxlen = 8192; char buf[maxlen + 1]; size_t i; atf_dynstr_t str; printf("Prepending with plain string\n"); buf[0] = '\0'; RE(atf_dynstr_init(&str)); for (i = 0; i < maxlen; i++) { if (strcmp(atf_dynstr_cstring(&str), buf) != 0) { fprintf(stderr, "Failed at iteration %zd\n", i); atf_tc_fail("Failed to prepend character at iteration %zd", i); } memmove(buf + 1, buf, i + 1); if (i % 2 == 0) { RE(prepend(&str, "%s", "a")); buf[0] = 'a'; } else { RE(prepend(&str, "%s", "b")); buf[0] = 'b'; } } atf_dynstr_fini(&str); printf("Prepending with formatted string\n"); buf[0] = '\0'; RE(atf_dynstr_init(&str)); for (i = 0; i < maxlen; i++) { if (strcmp(atf_dynstr_cstring(&str), buf) != 0) { fprintf(stderr, "Failed at iteration %zd\n", i); atf_tc_fail("Failed to prepend character at iteration %zd", i); } memmove(buf + 1, buf, i + 1); if (i % 2 == 0) { RE(prepend(&str, "%s", "a")); buf[0] = 'a'; } else { RE(prepend(&str, "%s", "b")); buf[0] = 'b'; } } atf_dynstr_fini(&str); } static atf_error_t prepend_ap_aux(atf_dynstr_t *str, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_dynstr_prepend_ap(str, fmt, ap); va_end(ap); return err; } ATF_TC(prepend_ap); ATF_TC_HEAD(prepend_ap, tc) { atf_tc_set_md_var(tc, "descr", "Checks that prepending a string to " "another one works"); } ATF_TC_BODY(prepend_ap, tc) { check_prepend(prepend_ap_aux); } ATF_TC(prepend_fmt); ATF_TC_HEAD(prepend_fmt, tc) { atf_tc_set_md_var(tc, "descr", "Checks that prepending a string to " "another one works"); } ATF_TC_BODY(prepend_fmt, tc) { check_prepend(atf_dynstr_prepend_fmt); } /* * Operators. */ ATF_TC(equal_cstring); ATF_TC_HEAD(equal_cstring, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_equal_dynstr_cstring " "function"); } ATF_TC_BODY(equal_cstring, tc) { atf_dynstr_t str; RE(atf_dynstr_init(&str)); ATF_REQUIRE( atf_equal_dynstr_cstring(&str, "")); ATF_REQUIRE(!atf_equal_dynstr_cstring(&str, "Test")); atf_dynstr_fini(&str); RE(atf_dynstr_init_fmt(&str, "Test")); ATF_REQUIRE( atf_equal_dynstr_cstring(&str, "Test")); ATF_REQUIRE(!atf_equal_dynstr_cstring(&str, "")); ATF_REQUIRE(!atf_equal_dynstr_cstring(&str, "Tes")); ATF_REQUIRE(!atf_equal_dynstr_cstring(&str, "Test ")); atf_dynstr_fini(&str); } ATF_TC(equal_dynstr); ATF_TC_HEAD(equal_dynstr, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_equal_dynstr_dynstr " "function"); } ATF_TC_BODY(equal_dynstr, tc) { atf_dynstr_t str, str2; RE(atf_dynstr_init(&str)); RE(atf_dynstr_init_fmt(&str2, "Test")); ATF_REQUIRE( atf_equal_dynstr_dynstr(&str, &str)); ATF_REQUIRE(!atf_equal_dynstr_dynstr(&str, &str2)); atf_dynstr_fini(&str2); atf_dynstr_fini(&str); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Constructors and destructors. */ ATF_TP_ADD_TC(tp, init); ATF_TP_ADD_TC(tp, init_ap); ATF_TP_ADD_TC(tp, init_fmt); ATF_TP_ADD_TC(tp, init_raw); ATF_TP_ADD_TC(tp, init_rep); ATF_TP_ADD_TC(tp, init_substr); ATF_TP_ADD_TC(tp, copy); ATF_TP_ADD_TC(tp, fini_disown); /* Getters. */ ATF_TP_ADD_TC(tp, cstring); ATF_TP_ADD_TC(tp, length); ATF_TP_ADD_TC(tp, rfind_ch); /* Modifiers. */ ATF_TP_ADD_TC(tp, append_ap); ATF_TP_ADD_TC(tp, append_fmt); ATF_TP_ADD_TC(tp, clear); ATF_TP_ADD_TC(tp, prepend_ap); ATF_TP_ADD_TC(tp, prepend_fmt); /* Operators. */ ATF_TP_ADD_TC(tp, equal_cstring); ATF_TP_ADD_TC(tp, equal_dynstr); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/env.c =================================================================== --- head/contrib/atf/atf-c/detail/env.c (revision 273928) +++ head/contrib/atf/atf-c/detail/env.c (revision 273929) @@ -1,108 +1,114 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/env.h" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/text.h" #include "atf-c/error.h" -#include "env.h" -#include "sanity.h" -#include "text.h" - const char * atf_env_get(const char *name) { const char* val = getenv(name); PRE(val != NULL); return val; +} + +const char * +atf_env_get_with_default(const char *name, const char *default_value) +{ + const char* val = getenv(name); + if (val == NULL) + return default_value; + else + return val; } bool atf_env_has(const char *name) { return getenv(name) != NULL; } atf_error_t atf_env_set(const char *name, const char *val) { atf_error_t err; #if defined(HAVE_SETENV) if (setenv(name, val, 1) == -1) err = atf_libc_error(errno, "Cannot set environment variable " "'%s' to '%s'", name, val); else err = atf_no_error(); #elif defined(HAVE_PUTENV) char *buf; err = atf_text_format(&buf, "%s=%s", name, val); if (!atf_is_error(err)) { if (putenv(buf) == -1) err = atf_libc_error(errno, "Cannot set environment variable " "'%s' to '%s'", name, val); free(buf); } #else # error "Don't know how to set an environment variable." #endif return err; } atf_error_t atf_env_unset(const char *name) { atf_error_t err; #if defined(HAVE_UNSETENV) unsetenv(name); err = atf_no_error(); #elif defined(HAVE_PUTENV) char *buf; err = atf_text_format(&buf, "%s=", name); if (!atf_is_error(err)) { if (putenv(buf) == -1) err = atf_libc_error(errno, "Cannot unset environment variable" " '%s'", name); free(buf); } #else # error "Don't know how to unset an environment variable." #endif return err; } Index: head/contrib/atf/atf-c/detail/env.h =================================================================== --- head/contrib/atf/atf-c/detail/env.h (revision 273928) +++ head/contrib/atf/atf-c/detail/env.h (revision 273929) @@ -1,42 +1,39 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_ENV_H) -#define ATF_C_ENV_H +#if !defined(ATF_C_DETAIL_ENV_H) +#define ATF_C_DETAIL_ENV_H #include #include const char *atf_env_get(const char *); +const char *atf_env_get_with_default(const char *, const char *); bool atf_env_has(const char *); atf_error_t atf_env_set(const char *, const char *); atf_error_t atf_env_unset(const char *); -#endif /* !defined(ATF_C_ENV_H) */ +#endif /* !defined(ATF_C_DETAIL_ENV_H) */ Index: head/contrib/atf/atf-c/detail/env_test.c =================================================================== --- head/contrib/atf/atf-c/detail/env_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/env_test.c (revision 273929) @@ -1,116 +1,133 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/env.h" + #include #include #include -#include "env.h" -#include "test_helpers.h" -#include "text.h" +#include "atf-c/detail/test_helpers.h" +#include "atf-c/detail/text.h" /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(has); ATF_TC_HEAD(has, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_env_has function"); } ATF_TC_BODY(has, tc) { ATF_REQUIRE(atf_env_has("PATH")); ATF_REQUIRE(!atf_env_has("_UNDEFINED_VARIABLE_")); } ATF_TC(get); ATF_TC_HEAD(get, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_env_get function"); } ATF_TC_BODY(get, tc) { const char *val; ATF_REQUIRE(atf_env_has("PATH")); val = atf_env_get("PATH"); ATF_REQUIRE(strlen(val) > 0); ATF_REQUIRE(strchr(val, ':') != NULL); } +ATF_TC(get_with_default); +ATF_TC_HEAD(get_with_default, tc) +{ + atf_tc_set_md_var(tc, "descr", "Tests the atf_env_get_with_default " + "function"); +} +ATF_TC_BODY(get_with_default, tc) +{ + const char *val; + + ATF_REQUIRE(atf_env_has("PATH")); + + val = atf_env_get_with_default("PATH", "unknown"); + ATF_REQUIRE(strcmp(val, "unknown") != 0); + + val = atf_env_get_with_default("_UNKNOWN_VARIABLE_", "foo bar"); + ATF_REQUIRE(strcmp(val, "foo bar") == 0); +} + ATF_TC(set); ATF_TC_HEAD(set, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_env_set function"); } ATF_TC_BODY(set, tc) { char *oldval; ATF_REQUIRE(atf_env_has("PATH")); RE(atf_text_format(&oldval, "%s", atf_env_get("PATH"))); RE(atf_env_set("PATH", "foo-bar")); ATF_REQUIRE(strcmp(atf_env_get("PATH"), oldval) != 0); ATF_REQUIRE(strcmp(atf_env_get("PATH"), "foo-bar") == 0); free(oldval); ATF_REQUIRE(!atf_env_has("_UNDEFINED_VARIABLE_")); RE(atf_env_set("_UNDEFINED_VARIABLE_", "foo2-bar2")); ATF_REQUIRE(strcmp(atf_env_get("_UNDEFINED_VARIABLE_"), "foo2-bar2") == 0); } ATF_TC(unset); ATF_TC_HEAD(unset, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_env_unset function"); } ATF_TC_BODY(unset, tc) { ATF_REQUIRE(atf_env_has("PATH")); RE(atf_env_unset("PATH")); ATF_REQUIRE(!atf_env_has("PATH")); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, has); ATF_TP_ADD_TC(tp, get); + ATF_TP_ADD_TC(tp, get_with_default); ATF_TP_ADD_TC(tp, set); ATF_TP_ADD_TC(tp, unset); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/fs.c =================================================================== --- head/contrib/atf/atf-c/detail/fs.c (revision 273928) +++ head/contrib/atf/atf-c/detail/fs.c (revision 273929) @@ -1,888 +1,884 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/fs.h" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include #include #include #include #include #include #include #include #include #include #include #include #include "atf-c/defs.h" +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/text.h" +#include "atf-c/detail/user.h" #include "atf-c/error.h" - -#include "fs.h" -#include "sanity.h" -#include "text.h" -#include "user.h" /* --------------------------------------------------------------------- * Prototypes for auxiliary functions. * --------------------------------------------------------------------- */ static bool check_umask(const mode_t, const mode_t); static atf_error_t copy_contents(const atf_fs_path_t *, char **); static mode_t current_umask(void); static atf_error_t do_mkdtemp(char *); static atf_error_t normalize(atf_dynstr_t *, char *); static atf_error_t normalize_ap(atf_dynstr_t *, const char *, va_list); static void replace_contents(atf_fs_path_t *, const char *); static const char *stat_type_to_string(const int); /* --------------------------------------------------------------------- * The "invalid_umask" error type. * --------------------------------------------------------------------- */ struct invalid_umask_error_data { /* One of atf_fs_stat_*_type. */ int m_type; /* The original path causing the error. */ /* XXX: Ideally this would be an atf_fs_path_t, but if we create it * from the error constructor, we cannot delete the path later on. * Can't remember why atf_error_new does not take a hook for * deletion. */ char m_path[1024]; /* The umask that caused the error. */ mode_t m_umask; }; typedef struct invalid_umask_error_data invalid_umask_error_data_t; static void invalid_umask_format(const atf_error_t err, char *buf, size_t buflen) { const invalid_umask_error_data_t *data; PRE(atf_error_is(err, "invalid_umask")); data = atf_error_data(err); snprintf(buf, buflen, "Could not create the temporary %s %s because " "it will not have enough access rights due to the current " "umask %05o", stat_type_to_string(data->m_type), data->m_path, (unsigned int)data->m_umask); } static atf_error_t invalid_umask_error(const atf_fs_path_t *path, const int type, const mode_t failing_mask) { atf_error_t err; invalid_umask_error_data_t data; data.m_type = type; strncpy(data.m_path, atf_fs_path_cstring(path), sizeof(data.m_path)); data.m_path[sizeof(data.m_path) - 1] = '\0'; data.m_umask = failing_mask; err = atf_error_new("invalid_umask", &data, sizeof(data), invalid_umask_format); return err; } /* --------------------------------------------------------------------- * The "unknown_file_type" error type. * --------------------------------------------------------------------- */ struct unknown_type_error_data { const char *m_path; int m_type; }; typedef struct unknown_type_error_data unknown_type_error_data_t; static void unknown_type_format(const atf_error_t err, char *buf, size_t buflen) { const unknown_type_error_data_t *data; PRE(atf_error_is(err, "unknown_type")); data = atf_error_data(err); snprintf(buf, buflen, "Unknown file type %d of %s", data->m_type, data->m_path); } static atf_error_t unknown_type_error(const char *path, int type) { atf_error_t err; unknown_type_error_data_t data; data.m_path = path; data.m_type = type; err = atf_error_new("unknown_type", &data, sizeof(data), unknown_type_format); return err; } /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static bool check_umask(const mode_t exp_mode, const mode_t min_mode) { const mode_t actual_mode = (~current_umask() & exp_mode); return (actual_mode & min_mode) == min_mode; } static atf_error_t copy_contents(const atf_fs_path_t *p, char **buf) { atf_error_t err; char *str; str = (char *)malloc(atf_dynstr_length(&p->m_data) + 1); if (str == NULL) err = atf_no_memory_error(); else { strcpy(str, atf_dynstr_cstring(&p->m_data)); *buf = str; err = atf_no_error(); } return err; } static mode_t current_umask(void) { const mode_t current = umask(0); (void)umask(current); return current; } static atf_error_t do_mkdtemp(char *tmpl) { atf_error_t err; PRE(strstr(tmpl, "XXXXXX") != NULL); if (mkdtemp(tmpl) == NULL) err = atf_libc_error(errno, "Cannot create temporary directory " "with template '%s'", tmpl); else err = atf_no_error(); return err; } static atf_error_t do_mkstemp(char *tmpl, int *fdout) { atf_error_t err; PRE(strstr(tmpl, "XXXXXX") != NULL); *fdout = mkstemp(tmpl); if (*fdout == -1) err = atf_libc_error(errno, "Cannot create temporary file " "with template '%s'", tmpl); else err = atf_no_error(); return err; } static atf_error_t normalize(atf_dynstr_t *d, char *p) { const char *ptr; char *last; atf_error_t err; bool first; PRE(strlen(p) > 0); PRE(atf_dynstr_length(d) == 0); if (p[0] == '/') err = atf_dynstr_append_fmt(d, "/"); else err = atf_no_error(); first = true; last = NULL; /* Silence GCC warning. */ ptr = strtok_r(p, "/", &last); while (!atf_is_error(err) && ptr != NULL) { if (strlen(ptr) > 0) { err = atf_dynstr_append_fmt(d, "%s%s", first ? "" : "/", ptr); first = false; } ptr = strtok_r(NULL, "/", &last); } return err; } static atf_error_t normalize_ap(atf_dynstr_t *d, const char *p, va_list ap) { char *str; atf_error_t err; va_list ap2; err = atf_dynstr_init(d); if (atf_is_error(err)) goto out; va_copy(ap2, ap); err = atf_text_format_ap(&str, p, ap2); va_end(ap2); if (atf_is_error(err)) atf_dynstr_fini(d); else { err = normalize(d, str); free(str); } out: return err; } static void replace_contents(atf_fs_path_t *p, const char *buf) { atf_error_t err; PRE(atf_dynstr_length(&p->m_data) == strlen(buf)); atf_dynstr_clear(&p->m_data); err = atf_dynstr_append_fmt(&p->m_data, "%s", buf); INV(!atf_is_error(err)); } static const char * stat_type_to_string(const int type) { const char *str; if (type == atf_fs_stat_blk_type) str = "block device"; else if (type == atf_fs_stat_chr_type) str = "character device"; else if (type == atf_fs_stat_dir_type) str = "directory"; else if (type == atf_fs_stat_fifo_type) str = "named pipe"; else if (type == atf_fs_stat_lnk_type) str = "symbolic link"; else if (type == atf_fs_stat_reg_type) str = "regular file"; else if (type == atf_fs_stat_sock_type) str = "socket"; else if (type == atf_fs_stat_wht_type) str = "whiteout"; else { UNREACHABLE; str = NULL; } return str; } /* --------------------------------------------------------------------- * The "atf_fs_path" type. * --------------------------------------------------------------------- */ /* * Constructors/destructors. */ atf_error_t atf_fs_path_init_ap(atf_fs_path_t *p, const char *fmt, va_list ap) { atf_error_t err; va_list ap2; va_copy(ap2, ap); err = normalize_ap(&p->m_data, fmt, ap2); va_end(ap2); return err; } atf_error_t atf_fs_path_init_fmt(atf_fs_path_t *p, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_fs_path_init_ap(p, fmt, ap); va_end(ap); return err; } atf_error_t atf_fs_path_copy(atf_fs_path_t *dest, const atf_fs_path_t *src) { return atf_dynstr_copy(&dest->m_data, &src->m_data); } void atf_fs_path_fini(atf_fs_path_t *p) { atf_dynstr_fini(&p->m_data); } /* * Getters. */ atf_error_t atf_fs_path_branch_path(const atf_fs_path_t *p, atf_fs_path_t *bp) { const size_t endpos = atf_dynstr_rfind_ch(&p->m_data, '/'); atf_error_t err; if (endpos == atf_dynstr_npos) err = atf_fs_path_init_fmt(bp, "."); else if (endpos == 0) err = atf_fs_path_init_fmt(bp, "/"); else err = atf_dynstr_init_substr(&bp->m_data, &p->m_data, 0, endpos); #if defined(HAVE_CONST_DIRNAME) INV(atf_equal_dynstr_cstring(&bp->m_data, dirname(atf_dynstr_cstring(&p->m_data)))); #endif /* defined(HAVE_CONST_DIRNAME) */ return err; } const char * atf_fs_path_cstring(const atf_fs_path_t *p) { return atf_dynstr_cstring(&p->m_data); } atf_error_t atf_fs_path_leaf_name(const atf_fs_path_t *p, atf_dynstr_t *ln) { size_t begpos = atf_dynstr_rfind_ch(&p->m_data, '/'); atf_error_t err; if (begpos == atf_dynstr_npos) begpos = 0; else begpos++; err = atf_dynstr_init_substr(ln, &p->m_data, begpos, atf_dynstr_npos); #if defined(HAVE_CONST_BASENAME) INV(atf_equal_dynstr_cstring(ln, basename(atf_dynstr_cstring(&p->m_data)))); #endif /* defined(HAVE_CONST_BASENAME) */ return err; } bool atf_fs_path_is_absolute(const atf_fs_path_t *p) { return atf_dynstr_cstring(&p->m_data)[0] == '/'; } bool atf_fs_path_is_root(const atf_fs_path_t *p) { return atf_equal_dynstr_cstring(&p->m_data, "/"); } /* * Modifiers. */ atf_error_t atf_fs_path_append_ap(atf_fs_path_t *p, const char *fmt, va_list ap) { atf_dynstr_t aux; atf_error_t err; va_list ap2; va_copy(ap2, ap); err = normalize_ap(&aux, fmt, ap2); va_end(ap2); if (!atf_is_error(err)) { const char *auxstr = atf_dynstr_cstring(&aux); const bool needslash = auxstr[0] != '/'; err = atf_dynstr_append_fmt(&p->m_data, "%s%s", needslash ? "/" : "", auxstr); atf_dynstr_fini(&aux); } return err; } atf_error_t atf_fs_path_append_fmt(atf_fs_path_t *p, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_fs_path_append_ap(p, fmt, ap); va_end(ap); return err; } atf_error_t atf_fs_path_append_path(atf_fs_path_t *p, const atf_fs_path_t *p2) { return atf_fs_path_append_fmt(p, "%s", atf_dynstr_cstring(&p2->m_data)); } atf_error_t atf_fs_path_to_absolute(const atf_fs_path_t *p, atf_fs_path_t *pa) { atf_error_t err; PRE(!atf_fs_path_is_absolute(p)); err = atf_fs_getcwd(pa); if (atf_is_error(err)) goto out; err = atf_fs_path_append_path(pa, p); if (atf_is_error(err)) atf_fs_path_fini(pa); out: return err; } /* * Operators. */ bool atf_equal_fs_path_fs_path(const atf_fs_path_t *p1, const atf_fs_path_t *p2) { return atf_equal_dynstr_dynstr(&p1->m_data, &p2->m_data); } /* --------------------------------------------------------------------- * The "atf_fs_path" type. * --------------------------------------------------------------------- */ /* * Constants. */ const int atf_fs_stat_blk_type = 1; const int atf_fs_stat_chr_type = 2; const int atf_fs_stat_dir_type = 3; const int atf_fs_stat_fifo_type = 4; const int atf_fs_stat_lnk_type = 5; const int atf_fs_stat_reg_type = 6; const int atf_fs_stat_sock_type = 7; const int atf_fs_stat_wht_type = 8; /* * Constructors/destructors. */ atf_error_t atf_fs_stat_init(atf_fs_stat_t *st, const atf_fs_path_t *p) { atf_error_t err; const char *pstr = atf_fs_path_cstring(p); if (lstat(pstr, &st->m_sb) == -1) { err = atf_libc_error(errno, "Cannot get information of %s; " "lstat(2) failed", pstr); } else { int type = st->m_sb.st_mode & S_IFMT; err = atf_no_error(); switch (type) { case S_IFBLK: st->m_type = atf_fs_stat_blk_type; break; case S_IFCHR: st->m_type = atf_fs_stat_chr_type; break; case S_IFDIR: st->m_type = atf_fs_stat_dir_type; break; case S_IFIFO: st->m_type = atf_fs_stat_fifo_type; break; case S_IFLNK: st->m_type = atf_fs_stat_lnk_type; break; case S_IFREG: st->m_type = atf_fs_stat_reg_type; break; case S_IFSOCK: st->m_type = atf_fs_stat_sock_type; break; #if defined(S_IFWHT) case S_IFWHT: st->m_type = atf_fs_stat_wht_type; break; #endif default: err = unknown_type_error(pstr, type); } } return err; } void atf_fs_stat_copy(atf_fs_stat_t *dest, const atf_fs_stat_t *src) { dest->m_type = src->m_type; dest->m_sb = src->m_sb; } void atf_fs_stat_fini(atf_fs_stat_t *st ATF_DEFS_ATTRIBUTE_UNUSED) { } /* * Getters. */ dev_t atf_fs_stat_get_device(const atf_fs_stat_t *st) { return st->m_sb.st_dev; } ino_t atf_fs_stat_get_inode(const atf_fs_stat_t *st) { return st->m_sb.st_ino; } mode_t atf_fs_stat_get_mode(const atf_fs_stat_t *st) { return st->m_sb.st_mode & ~S_IFMT; } off_t atf_fs_stat_get_size(const atf_fs_stat_t *st) { return st->m_sb.st_size; } int atf_fs_stat_get_type(const atf_fs_stat_t *st) { return st->m_type; } bool atf_fs_stat_is_owner_readable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IRUSR; } bool atf_fs_stat_is_owner_writable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IWUSR; } bool atf_fs_stat_is_owner_executable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IXUSR; } bool atf_fs_stat_is_group_readable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IRGRP; } bool atf_fs_stat_is_group_writable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IWGRP; } bool atf_fs_stat_is_group_executable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IXGRP; } bool atf_fs_stat_is_other_readable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IROTH; } bool atf_fs_stat_is_other_writable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IWOTH; } bool atf_fs_stat_is_other_executable(const atf_fs_stat_t *st) { return st->m_sb.st_mode & S_IXOTH; } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ const int atf_fs_access_f = 1 << 0; const int atf_fs_access_r = 1 << 1; const int atf_fs_access_w = 1 << 2; const int atf_fs_access_x = 1 << 3; /* * An implementation of access(2) but using the effective user value * instead of the real one. Also avoids false positives for root when * asking for execute permissions, which appear in SunOS. */ atf_error_t atf_fs_eaccess(const atf_fs_path_t *p, int mode) { atf_error_t err; struct stat st; bool ok; PRE(mode & atf_fs_access_f || mode & atf_fs_access_r || mode & atf_fs_access_w || mode & atf_fs_access_x); if (lstat(atf_fs_path_cstring(p), &st) == -1) { err = atf_libc_error(errno, "Cannot get information from file %s", atf_fs_path_cstring(p)); goto out; } err = atf_no_error(); /* Early return if we are only checking for existence and the file * exists (stat call returned). */ if (mode & atf_fs_access_f) goto out; ok = false; if (atf_user_is_root()) { if (!ok && !(mode & atf_fs_access_x)) { /* Allow root to read/write any file. */ ok = true; } if (!ok && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) { /* Allow root to execute the file if any of its execution bits * are set. */ ok = true; } } else { if (!ok && (atf_user_euid() == st.st_uid)) { ok = ((mode & atf_fs_access_r) && (st.st_mode & S_IRUSR)) || ((mode & atf_fs_access_w) && (st.st_mode & S_IWUSR)) || ((mode & atf_fs_access_x) && (st.st_mode & S_IXUSR)); } if (!ok && atf_user_is_member_of_group(st.st_gid)) { ok = ((mode & atf_fs_access_r) && (st.st_mode & S_IRGRP)) || ((mode & atf_fs_access_w) && (st.st_mode & S_IWGRP)) || ((mode & atf_fs_access_x) && (st.st_mode & S_IXGRP)); } if (!ok && ((atf_user_euid() != st.st_uid) && !atf_user_is_member_of_group(st.st_gid))) { ok = ((mode & atf_fs_access_r) && (st.st_mode & S_IROTH)) || ((mode & atf_fs_access_w) && (st.st_mode & S_IWOTH)) || ((mode & atf_fs_access_x) && (st.st_mode & S_IXOTH)); } } if (!ok) err = atf_libc_error(EACCES, "Access check failed"); out: return err; } atf_error_t atf_fs_exists(const atf_fs_path_t *p, bool *b) { atf_error_t err; err = atf_fs_eaccess(p, atf_fs_access_f); if (atf_is_error(err)) { if (atf_error_is(err, "libc") && atf_libc_error_code(err) == ENOENT) { atf_error_free(err); err = atf_no_error(); *b = false; } } else *b = true; return err; } atf_error_t atf_fs_getcwd(atf_fs_path_t *p) { atf_error_t err; char *cwd; #if defined(HAVE_GETCWD_DYN) cwd = getcwd(NULL, 0); #else cwd = getcwd(NULL, MAXPATHLEN); #endif if (cwd == NULL) { err = atf_libc_error(errno, "Cannot determine current directory"); goto out; } err = atf_fs_path_init_fmt(p, "%s", cwd); free(cwd); out: return err; } atf_error_t atf_fs_mkdtemp(atf_fs_path_t *p) { atf_error_t err; char *buf; if (!check_umask(S_IRWXU, S_IRWXU)) { err = invalid_umask_error(p, atf_fs_stat_dir_type, current_umask()); goto out; } err = copy_contents(p, &buf); if (atf_is_error(err)) goto out; err = do_mkdtemp(buf); if (atf_is_error(err)) goto out_buf; replace_contents(p, buf); INV(!atf_is_error(err)); out_buf: free(buf); out: return err; } atf_error_t atf_fs_mkstemp(atf_fs_path_t *p, int *fdout) { atf_error_t err; char *buf; int fd; if (!check_umask(S_IRWXU, S_IRWXU)) { err = invalid_umask_error(p, atf_fs_stat_reg_type, current_umask()); goto out; } err = copy_contents(p, &buf); if (atf_is_error(err)) goto out; err = do_mkstemp(buf, &fd); if (atf_is_error(err)) goto out_buf; replace_contents(p, buf); *fdout = fd; INV(!atf_is_error(err)); out_buf: free(buf); out: return err; } atf_error_t atf_fs_rmdir(const atf_fs_path_t *p) { atf_error_t err; if (rmdir(atf_fs_path_cstring(p))) { if (errno == EEXIST) { /* Some operating systems (e.g. OpenSolaris 200906) return * EEXIST instead of ENOTEMPTY for non-empty directories. * Homogenize the return value so that callers don't need * to bother about differences in operating systems. */ errno = ENOTEMPTY; } err = atf_libc_error(errno, "Cannot remove directory"); } else err = atf_no_error(); return err; } atf_error_t atf_fs_unlink(const atf_fs_path_t *p) { atf_error_t err; const char *path; path = atf_fs_path_cstring(p); if (unlink(path) != 0) err = atf_libc_error(errno, "Cannot unlink file: '%s'", path); else err = atf_no_error(); return err; } Index: head/contrib/atf/atf-c/detail/fs.h =================================================================== --- head/contrib/atf/atf-c/detail/fs.h (revision 273928) +++ head/contrib/atf/atf-c/detail/fs.h (revision 273929) @@ -1,133 +1,128 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_FS_H) -#define ATF_C_FS_H +#if !defined(ATF_C_DETAIL_FS_H) +#define ATF_C_DETAIL_FS_H #include #include #include #include +#include #include -#include "dynstr.h" - /* --------------------------------------------------------------------- * The "atf_fs_path" type. * --------------------------------------------------------------------- */ struct atf_fs_path { atf_dynstr_t m_data; }; typedef struct atf_fs_path atf_fs_path_t; /* Constructors/destructors. */ atf_error_t atf_fs_path_init_ap(atf_fs_path_t *, const char *, va_list); atf_error_t atf_fs_path_init_fmt(atf_fs_path_t *, const char *, ...); atf_error_t atf_fs_path_copy(atf_fs_path_t *, const atf_fs_path_t *); void atf_fs_path_fini(atf_fs_path_t *); /* Getters. */ atf_error_t atf_fs_path_branch_path(const atf_fs_path_t *, atf_fs_path_t *); const char *atf_fs_path_cstring(const atf_fs_path_t *); atf_error_t atf_fs_path_leaf_name(const atf_fs_path_t *, atf_dynstr_t *); bool atf_fs_path_is_absolute(const atf_fs_path_t *); bool atf_fs_path_is_root(const atf_fs_path_t *); /* Modifiers. */ atf_error_t atf_fs_path_append_ap(atf_fs_path_t *, const char *, va_list); atf_error_t atf_fs_path_append_fmt(atf_fs_path_t *, const char *, ...); atf_error_t atf_fs_path_append_path(atf_fs_path_t *, const atf_fs_path_t *); atf_error_t atf_fs_path_to_absolute(const atf_fs_path_t *, atf_fs_path_t *); /* Operators. */ bool atf_equal_fs_path_fs_path(const atf_fs_path_t *, const atf_fs_path_t *); /* --------------------------------------------------------------------- * The "atf_fs_stat" type. * --------------------------------------------------------------------- */ struct atf_fs_stat { int m_type; struct stat m_sb; }; typedef struct atf_fs_stat atf_fs_stat_t; /* Constants. */ extern const int atf_fs_stat_blk_type; extern const int atf_fs_stat_chr_type; extern const int atf_fs_stat_dir_type; extern const int atf_fs_stat_fifo_type; extern const int atf_fs_stat_lnk_type; extern const int atf_fs_stat_reg_type; extern const int atf_fs_stat_sock_type; extern const int atf_fs_stat_wht_type; /* Constructors/destructors. */ atf_error_t atf_fs_stat_init(atf_fs_stat_t *, const atf_fs_path_t *); void atf_fs_stat_copy(atf_fs_stat_t *, const atf_fs_stat_t *); void atf_fs_stat_fini(atf_fs_stat_t *); /* Getters. */ dev_t atf_fs_stat_get_device(const atf_fs_stat_t *); ino_t atf_fs_stat_get_inode(const atf_fs_stat_t *); mode_t atf_fs_stat_get_mode(const atf_fs_stat_t *); off_t atf_fs_stat_get_size(const atf_fs_stat_t *); int atf_fs_stat_get_type(const atf_fs_stat_t *); bool atf_fs_stat_is_owner_readable(const atf_fs_stat_t *); bool atf_fs_stat_is_owner_writable(const atf_fs_stat_t *); bool atf_fs_stat_is_owner_executable(const atf_fs_stat_t *); bool atf_fs_stat_is_group_readable(const atf_fs_stat_t *); bool atf_fs_stat_is_group_writable(const atf_fs_stat_t *); bool atf_fs_stat_is_group_executable(const atf_fs_stat_t *); bool atf_fs_stat_is_other_readable(const atf_fs_stat_t *); bool atf_fs_stat_is_other_writable(const atf_fs_stat_t *); bool atf_fs_stat_is_other_executable(const atf_fs_stat_t *); /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ extern const int atf_fs_access_f; extern const int atf_fs_access_r; extern const int atf_fs_access_w; extern const int atf_fs_access_x; atf_error_t atf_fs_eaccess(const atf_fs_path_t *, int); atf_error_t atf_fs_exists(const atf_fs_path_t *, bool *); atf_error_t atf_fs_getcwd(atf_fs_path_t *); atf_error_t atf_fs_mkdtemp(atf_fs_path_t *); atf_error_t atf_fs_mkstemp(atf_fs_path_t *, int *); atf_error_t atf_fs_rmdir(const atf_fs_path_t *); atf_error_t atf_fs_unlink(const atf_fs_path_t *); -#endif /* !defined(ATF_C_FS_H) */ +#endif /* !defined(ATF_C_DETAIL_FS_H) */ Index: head/contrib/atf/atf-c/detail/fs_test.c =================================================================== --- head/contrib/atf/atf-c/detail/fs_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/fs_test.c (revision 273929) @@ -1,1082 +1,1079 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/fs.h" + #include #include #include #include #include #include #include #include #include -#include "fs.h" -#include "test_helpers.h" -#include "user.h" +#include "atf-c/detail/test_helpers.h" +#include "atf-c/detail/user.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void create_dir(const char *p, int mode) { int ret; ret = mkdir(p, mode); if (ret == -1) atf_tc_fail("Could not create helper directory %s", p); } static void create_file(const char *p, int mode) { int fd; fd = open(p, O_CREAT | O_WRONLY | O_TRUNC, mode); if (fd == -1) atf_tc_fail("Could not create helper file %s", p); close(fd); } static bool exists(const atf_fs_path_t *p) { return access(atf_fs_path_cstring(p), F_OK) == 0; } static atf_error_t mkstemp_discard_fd(atf_fs_path_t *p) { int fd; atf_error_t err = atf_fs_mkstemp(p, &fd); if (!atf_is_error(err)) close(fd); return err; } /* --------------------------------------------------------------------- * Test cases for the "atf_fs_path" type. * --------------------------------------------------------------------- */ ATF_TC(path_normalize); ATF_TC_HEAD(path_normalize, tc) { atf_tc_set_md_var(tc, "descr", "Tests the path's normalization"); } ATF_TC_BODY(path_normalize, tc) { struct test { const char *in; const char *out; } tests[] = { { ".", ".", }, { "..", "..", }, { "/", "/", }, { "//", "/", }, /* NO_CHECK_STYLE */ { "///", "/", }, /* NO_CHECK_STYLE */ { "foo", "foo", }, { "foo/", "foo", }, { "foo/bar", "foo/bar", }, { "foo/bar/", "foo/bar", }, { "/foo", "/foo", }, { "/foo/bar", "/foo/bar", }, { "/foo/bar/", "/foo/bar", }, { "///foo", "/foo", }, /* NO_CHECK_STYLE */ { "///foo///bar", "/foo/bar", }, /* NO_CHECK_STYLE */ { "///foo///bar///", "/foo/bar", }, /* NO_CHECK_STYLE */ { NULL, NULL } }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p; printf("Input : >%s<\n", t->in); printf("Expected output: >%s<\n", t->out); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); printf("Output : >%s<\n", atf_fs_path_cstring(&p)); ATF_REQUIRE(strcmp(atf_fs_path_cstring(&p), t->out) == 0); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_copy); ATF_TC_HEAD(path_copy, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_path_copy constructor"); } ATF_TC_BODY(path_copy, tc) { atf_fs_path_t str, str2; RE(atf_fs_path_init_fmt(&str, "foo")); RE(atf_fs_path_copy(&str2, &str)); ATF_REQUIRE(atf_equal_fs_path_fs_path(&str, &str2)); RE(atf_fs_path_append_fmt(&str2, "bar")); ATF_REQUIRE(!atf_equal_fs_path_fs_path(&str, &str2)); atf_fs_path_fini(&str2); atf_fs_path_fini(&str); } ATF_TC(path_is_absolute); ATF_TC_HEAD(path_is_absolute, tc) { atf_tc_set_md_var(tc, "descr", "Tests the path::is_absolute function"); } ATF_TC_BODY(path_is_absolute, tc) { struct test { const char *in; bool abs; } tests[] = { { "/", true }, { "////", true }, /* NO_CHECK_STYLE */ { "////a", true }, /* NO_CHECK_STYLE */ { "//a//", true }, /* NO_CHECK_STYLE */ { "a////", false }, /* NO_CHECK_STYLE */ { "../foo", false }, { NULL, false }, }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p; printf("Input : %s\n", t->in); printf("Expected result: %s\n", t->abs ? "true" : "false"); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); printf("Result : %s\n", atf_fs_path_is_absolute(&p) ? "true" : "false"); if (t->abs) ATF_REQUIRE(atf_fs_path_is_absolute(&p)); else ATF_REQUIRE(!atf_fs_path_is_absolute(&p)); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_is_root); ATF_TC_HEAD(path_is_root, tc) { atf_tc_set_md_var(tc, "descr", "Tests the path::is_root function"); } ATF_TC_BODY(path_is_root, tc) { struct test { const char *in; bool root; } tests[] = { { "/", true }, { "////", true }, /* NO_CHECK_STYLE */ { "////a", false }, /* NO_CHECK_STYLE */ { "//a//", false }, /* NO_CHECK_STYLE */ { "a////", false }, /* NO_CHECK_STYLE */ { "../foo", false }, { NULL, false }, }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p; printf("Input : %s\n", t->in); printf("Expected result: %s\n", t->root ? "true" : "false"); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); printf("Result : %s\n", atf_fs_path_is_root(&p) ? "true" : "false"); if (t->root) ATF_REQUIRE(atf_fs_path_is_root(&p)); else ATF_REQUIRE(!atf_fs_path_is_root(&p)); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_branch_path); ATF_TC_HEAD(path_branch_path, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_path_branch_path " "function"); } ATF_TC_BODY(path_branch_path, tc) { struct test { const char *in; const char *branch; } tests[] = { { ".", "." }, { "foo", "." }, { "foo/bar", "foo" }, { "/foo", "/" }, { "/foo/bar", "/foo" }, { NULL, NULL }, }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p, bp; printf("Input : %s\n", t->in); printf("Expected output: %s\n", t->branch); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); RE(atf_fs_path_branch_path(&p, &bp)); printf("Output : %s\n", atf_fs_path_cstring(&bp)); ATF_REQUIRE(strcmp(atf_fs_path_cstring(&bp), t->branch) == 0); atf_fs_path_fini(&bp); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_leaf_name); ATF_TC_HEAD(path_leaf_name, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_path_leaf_name " "function"); } ATF_TC_BODY(path_leaf_name, tc) { struct test { const char *in; const char *leaf; } tests[] = { { ".", "." }, { "foo", "foo" }, { "foo/bar", "bar" }, { "/foo", "foo" }, { "/foo/bar", "bar" }, { NULL, NULL }, }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p; atf_dynstr_t ln; printf("Input : %s\n", t->in); printf("Expected output: %s\n", t->leaf); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); RE(atf_fs_path_leaf_name(&p, &ln)); printf("Output : %s\n", atf_dynstr_cstring(&ln)); ATF_REQUIRE(atf_equal_dynstr_cstring(&ln, t->leaf)); atf_dynstr_fini(&ln); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_append); ATF_TC_HEAD(path_append, tc) { atf_tc_set_md_var(tc, "descr", "Tests the concatenation of multiple " "paths"); } ATF_TC_BODY(path_append, tc) { struct test { const char *in; const char *ap; const char *out; } tests[] = { { "foo", "bar", "foo/bar" }, { "foo/", "/bar", "foo/bar" }, { "foo/", "/bar/baz", "foo/bar/baz" }, { "foo/", "///bar///baz", "foo/bar/baz" }, /* NO_CHECK_STYLE */ { NULL, NULL, NULL } }; struct test *t; for (t = &tests[0]; t->in != NULL; t++) { atf_fs_path_t p; printf("Input : >%s<\n", t->in); printf("Append : >%s<\n", t->ap); printf("Expected output: >%s<\n", t->out); RE(atf_fs_path_init_fmt(&p, "%s", t->in)); RE(atf_fs_path_append_fmt(&p, "%s", t->ap)); printf("Output : >%s<\n", atf_fs_path_cstring(&p)); ATF_REQUIRE(strcmp(atf_fs_path_cstring(&p), t->out) == 0); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_to_absolute); ATF_TC_HEAD(path_to_absolute, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_path_to_absolute " "function"); } ATF_TC_BODY(path_to_absolute, tc) { const char *names[] = { ".", "dir", NULL }; const char **n; ATF_REQUIRE(mkdir("dir", 0755) != -1); for (n = names; *n != NULL; n++) { atf_fs_path_t p, p2; atf_fs_stat_t st1, st2; RE(atf_fs_path_init_fmt(&p, "%s", *n)); RE(atf_fs_stat_init(&st1, &p)); printf("Relative path: %s\n", atf_fs_path_cstring(&p)); RE(atf_fs_path_to_absolute(&p, &p2)); printf("Absolute path: %s\n", atf_fs_path_cstring(&p2)); ATF_REQUIRE(atf_fs_path_is_absolute(&p2)); RE(atf_fs_stat_init(&st2, &p2)); ATF_REQUIRE_EQ(atf_fs_stat_get_device(&st1), atf_fs_stat_get_device(&st2)); ATF_REQUIRE_EQ(atf_fs_stat_get_inode(&st1), atf_fs_stat_get_inode(&st2)); atf_fs_stat_fini(&st2); atf_fs_stat_fini(&st1); atf_fs_path_fini(&p2); atf_fs_path_fini(&p); printf("\n"); } } ATF_TC(path_equal); ATF_TC_HEAD(path_equal, tc) { atf_tc_set_md_var(tc, "descr", "Tests the equality operators for paths"); } ATF_TC_BODY(path_equal, tc) { atf_fs_path_t p1, p2; RE(atf_fs_path_init_fmt(&p1, "foo")); RE(atf_fs_path_init_fmt(&p2, "foo")); ATF_REQUIRE(atf_equal_fs_path_fs_path(&p1, &p2)); atf_fs_path_fini(&p2); RE(atf_fs_path_init_fmt(&p2, "bar")); ATF_REQUIRE(!atf_equal_fs_path_fs_path(&p1, &p2)); atf_fs_path_fini(&p2); atf_fs_path_fini(&p1); } /* --------------------------------------------------------------------- * Test cases for the "atf_fs_stat" type. * --------------------------------------------------------------------- */ ATF_TC(stat_mode); ATF_TC_HEAD(stat_mode, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_stat_get_mode function " "and, indirectly, the constructor"); } ATF_TC_BODY(stat_mode, tc) { atf_fs_path_t p; atf_fs_stat_t st; create_file("f1", 0400); create_file("f2", 0644); RE(atf_fs_path_init_fmt(&p, "f1")); RE(atf_fs_stat_init(&st, &p)); ATF_CHECK_EQ(0400, atf_fs_stat_get_mode(&st)); atf_fs_stat_fini(&st); atf_fs_path_fini(&p); RE(atf_fs_path_init_fmt(&p, "f2")); RE(atf_fs_stat_init(&st, &p)); ATF_CHECK_EQ(0644, atf_fs_stat_get_mode(&st)); atf_fs_stat_fini(&st); atf_fs_path_fini(&p); } ATF_TC(stat_type); ATF_TC_HEAD(stat_type, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_stat_get_type function " "and, indirectly, the constructor"); } ATF_TC_BODY(stat_type, tc) { atf_fs_path_t p; atf_fs_stat_t st; create_dir("dir", 0755); create_file("reg", 0644); RE(atf_fs_path_init_fmt(&p, "dir")); RE(atf_fs_stat_init(&st, &p)); ATF_REQUIRE_EQ(atf_fs_stat_get_type(&st), atf_fs_stat_dir_type); atf_fs_stat_fini(&st); atf_fs_path_fini(&p); RE(atf_fs_path_init_fmt(&p, "reg")); RE(atf_fs_stat_init(&st, &p)); ATF_REQUIRE_EQ(atf_fs_stat_get_type(&st), atf_fs_stat_reg_type); atf_fs_stat_fini(&st); atf_fs_path_fini(&p); } ATF_TC(stat_perms); ATF_TC_HEAD(stat_perms, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_stat_is_* functions"); } ATF_TC_BODY(stat_perms, tc) { atf_fs_path_t p; atf_fs_stat_t st; create_file("reg", 0); RE(atf_fs_path_init_fmt(&p, "reg")); #define perms(ur, uw, ux, gr, gw, gx, othr, othw, othx) \ { \ RE(atf_fs_stat_init(&st, &p)); \ ATF_REQUIRE(atf_fs_stat_is_owner_readable(&st) == ur); \ ATF_REQUIRE(atf_fs_stat_is_owner_writable(&st) == uw); \ ATF_REQUIRE(atf_fs_stat_is_owner_executable(&st) == ux); \ ATF_REQUIRE(atf_fs_stat_is_group_readable(&st) == gr); \ ATF_REQUIRE(atf_fs_stat_is_group_writable(&st) == gw); \ ATF_REQUIRE(atf_fs_stat_is_group_executable(&st) == gx); \ ATF_REQUIRE(atf_fs_stat_is_other_readable(&st) == othr); \ ATF_REQUIRE(atf_fs_stat_is_other_writable(&st) == othw); \ ATF_REQUIRE(atf_fs_stat_is_other_executable(&st) == othx); \ atf_fs_stat_fini(&st); \ } chmod("reg", 0000); perms(false, false, false, false, false, false, false, false, false); chmod("reg", 0001); perms(false, false, false, false, false, false, false, false, true); chmod("reg", 0010); perms(false, false, false, false, false, true, false, false, false); chmod("reg", 0100); perms(false, false, true, false, false, false, false, false, false); chmod("reg", 0002); perms(false, false, false, false, false, false, false, true, false); chmod("reg", 0020); perms(false, false, false, false, true, false, false, false, false); chmod("reg", 0200); perms(false, true, false, false, false, false, false, false, false); chmod("reg", 0004); perms(false, false, false, false, false, false, true, false, false); chmod("reg", 0040); perms(false, false, false, true, false, false, false, false, false); chmod("reg", 0400); perms(true, false, false, false, false, false, false, false, false); chmod("reg", 0644); perms(true, true, false, true, false, false, true, false, false); chmod("reg", 0755); perms(true, true, true, true, false, true, true, false, true); chmod("reg", 0777); perms(true, true, true, true, true, true, true, true, true); #undef perms atf_fs_path_fini(&p); } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(exists); ATF_TC_HEAD(exists, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_exists function"); } ATF_TC_BODY(exists, tc) { atf_error_t err; atf_fs_path_t pdir, pfile; bool b; RE(atf_fs_path_init_fmt(&pdir, "dir")); RE(atf_fs_path_init_fmt(&pfile, "dir/file")); create_dir(atf_fs_path_cstring(&pdir), 0755); create_file(atf_fs_path_cstring(&pfile), 0644); printf("Checking existence of a directory\n"); RE(atf_fs_exists(&pdir, &b)); ATF_REQUIRE(b); printf("Checking existence of a file\n"); RE(atf_fs_exists(&pfile, &b)); ATF_REQUIRE(b); /* XXX: This should probably be a separate test case to let the user * be aware that some tests were skipped because privileges were not * correct. */ if (!atf_user_is_root()) { printf("Checking existence of a file inside a directory without " "permissions\n"); ATF_REQUIRE(chmod(atf_fs_path_cstring(&pdir), 0000) != -1); err = atf_fs_exists(&pfile, &b); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE(chmod(atf_fs_path_cstring(&pdir), 0755) != -1); atf_error_free(err); } printf("Checking existence of a non-existent file\n"); ATF_REQUIRE(unlink(atf_fs_path_cstring(&pfile)) != -1); RE(atf_fs_exists(&pfile, &b)); ATF_REQUIRE(!b); atf_fs_path_fini(&pfile); atf_fs_path_fini(&pdir); } ATF_TC(eaccess); ATF_TC_HEAD(eaccess, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_eaccess function"); } ATF_TC_BODY(eaccess, tc) { const int modes[] = { atf_fs_access_f, atf_fs_access_r, atf_fs_access_w, atf_fs_access_x, 0 }; const int *m; struct tests { mode_t fmode; int amode; int uerror; int rerror; } tests[] = { { 0000, atf_fs_access_r, EACCES, 0 }, { 0000, atf_fs_access_w, EACCES, 0 }, { 0000, atf_fs_access_x, EACCES, EACCES }, { 0001, atf_fs_access_r, EACCES, 0 }, { 0001, atf_fs_access_w, EACCES, 0 }, { 0001, atf_fs_access_x, EACCES, 0 }, { 0002, atf_fs_access_r, EACCES, 0 }, { 0002, atf_fs_access_w, EACCES, 0 }, { 0002, atf_fs_access_x, EACCES, EACCES }, { 0004, atf_fs_access_r, EACCES, 0 }, { 0004, atf_fs_access_w, EACCES, 0 }, { 0004, atf_fs_access_x, EACCES, EACCES }, { 0010, atf_fs_access_r, EACCES, 0 }, { 0010, atf_fs_access_w, EACCES, 0 }, { 0010, atf_fs_access_x, 0, 0 }, { 0020, atf_fs_access_r, EACCES, 0 }, { 0020, atf_fs_access_w, 0, 0 }, { 0020, atf_fs_access_x, EACCES, EACCES }, { 0040, atf_fs_access_r, 0, 0 }, { 0040, atf_fs_access_w, EACCES, 0 }, { 0040, atf_fs_access_x, EACCES, EACCES }, { 0100, atf_fs_access_r, EACCES, 0 }, { 0100, atf_fs_access_w, EACCES, 0 }, { 0100, atf_fs_access_x, 0, 0 }, { 0200, atf_fs_access_r, EACCES, 0 }, { 0200, atf_fs_access_w, 0, 0 }, { 0200, atf_fs_access_x, EACCES, EACCES }, { 0400, atf_fs_access_r, 0, 0 }, { 0400, atf_fs_access_w, EACCES, 0 }, { 0400, atf_fs_access_x, EACCES, EACCES }, { 0, 0, 0, 0 } }; struct tests *t; atf_fs_path_t p; atf_error_t err; RE(atf_fs_path_init_fmt(&p, "the-file")); printf("Non-existent file checks\n"); for (m = &modes[0]; *m != 0; m++) { err = atf_fs_eaccess(&p, *m); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), ENOENT); atf_error_free(err); } create_file(atf_fs_path_cstring(&p), 0000); ATF_REQUIRE(chown(atf_fs_path_cstring(&p), geteuid(), getegid()) != -1); for (t = &tests[0]; t->amode != 0; t++) { const int experr = atf_user_is_root() ? t->rerror : t->uerror; printf("\n"); printf("File mode : %04o\n", (unsigned int)t->fmode); printf("Access mode : 0x%02x\n", t->amode); ATF_REQUIRE(chmod(atf_fs_path_cstring(&p), t->fmode) != -1); /* First, existence check. */ err = atf_fs_eaccess(&p, atf_fs_access_f); ATF_REQUIRE(!atf_is_error(err)); /* Now do the specific test case. */ printf("Expected error: %d\n", experr); err = atf_fs_eaccess(&p, t->amode); if (atf_is_error(err)) { if (atf_error_is(err, "libc")) printf("Error : %d\n", atf_libc_error_code(err)); else printf("Error : Non-libc error\n"); } else printf("Error : None\n"); if (experr == 0) { ATF_REQUIRE(!atf_is_error(err)); } else { ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), experr); atf_error_free(err); } } atf_fs_path_fini(&p); } ATF_TC(getcwd); ATF_TC_HEAD(getcwd, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_getcwd function"); } ATF_TC_BODY(getcwd, tc) { atf_fs_path_t cwd1, cwd2; create_dir ("root", 0755); RE(atf_fs_getcwd(&cwd1)); ATF_REQUIRE(chdir("root") != -1); RE(atf_fs_getcwd(&cwd2)); RE(atf_fs_path_append_fmt(&cwd1, "root")); ATF_REQUIRE(atf_equal_fs_path_fs_path(&cwd1, &cwd2)); atf_fs_path_fini(&cwd2); atf_fs_path_fini(&cwd1); } ATF_TC(rmdir_empty); ATF_TC_HEAD(rmdir_empty, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_rmdir function"); } ATF_TC_BODY(rmdir_empty, tc) { atf_fs_path_t p; RE(atf_fs_path_init_fmt(&p, "test-dir")); ATF_REQUIRE(mkdir("test-dir", 0755) != -1); ATF_REQUIRE(exists(&p)); RE(atf_fs_rmdir(&p)); ATF_REQUIRE(!exists(&p)); atf_fs_path_fini(&p); } ATF_TC(rmdir_enotempty); ATF_TC_HEAD(rmdir_enotempty, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_rmdir function"); } ATF_TC_BODY(rmdir_enotempty, tc) { atf_fs_path_t p; atf_error_t err; RE(atf_fs_path_init_fmt(&p, "test-dir")); ATF_REQUIRE(mkdir("test-dir", 0755) != -1); ATF_REQUIRE(exists(&p)); create_file("test-dir/foo", 0644); err = atf_fs_rmdir(&p); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), ENOTEMPTY); atf_error_free(err); atf_fs_path_fini(&p); } ATF_TC(rmdir_eperm); ATF_TC_HEAD(rmdir_eperm, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_rmdir function"); } ATF_TC_BODY(rmdir_eperm, tc) { atf_fs_path_t p; atf_error_t err; RE(atf_fs_path_init_fmt(&p, "test-dir/foo")); ATF_REQUIRE(mkdir("test-dir", 0755) != -1); ATF_REQUIRE(mkdir("test-dir/foo", 0755) != -1); ATF_REQUIRE(chmod("test-dir", 0555) != -1); ATF_REQUIRE(exists(&p)); err = atf_fs_rmdir(&p); if (atf_user_is_root()) { ATF_REQUIRE(!atf_is_error(err)); } else { ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), EACCES); atf_error_free(err); } atf_fs_path_fini(&p); } ATF_TC(mkdtemp_ok); ATF_TC_HEAD(mkdtemp_ok, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkdtemp function, " "successful execution"); } ATF_TC_BODY(mkdtemp_ok, tc) { atf_fs_path_t p1, p2; atf_fs_stat_t s1, s2; RE(atf_fs_path_init_fmt(&p1, "testdir.XXXXXX")); RE(atf_fs_path_init_fmt(&p2, "testdir.XXXXXX")); RE(atf_fs_mkdtemp(&p1)); RE(atf_fs_mkdtemp(&p2)); ATF_REQUIRE(!atf_equal_fs_path_fs_path(&p1, &p2)); ATF_REQUIRE(exists(&p1)); ATF_REQUIRE(exists(&p2)); RE(atf_fs_stat_init(&s1, &p1)); ATF_REQUIRE_EQ(atf_fs_stat_get_type(&s1), atf_fs_stat_dir_type); ATF_REQUIRE( atf_fs_stat_is_owner_readable(&s1)); ATF_REQUIRE( atf_fs_stat_is_owner_writable(&s1)); ATF_REQUIRE( atf_fs_stat_is_owner_executable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_group_readable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_group_writable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_group_executable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_other_readable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_other_writable(&s1)); ATF_REQUIRE(!atf_fs_stat_is_other_executable(&s1)); RE(atf_fs_stat_init(&s2, &p2)); ATF_REQUIRE_EQ(atf_fs_stat_get_type(&s2), atf_fs_stat_dir_type); ATF_REQUIRE( atf_fs_stat_is_owner_readable(&s2)); ATF_REQUIRE( atf_fs_stat_is_owner_writable(&s2)); ATF_REQUIRE( atf_fs_stat_is_owner_executable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_group_readable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_group_writable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_group_executable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_other_readable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_other_writable(&s2)); ATF_REQUIRE(!atf_fs_stat_is_other_executable(&s2)); atf_fs_stat_fini(&s2); atf_fs_stat_fini(&s1); atf_fs_path_fini(&p2); atf_fs_path_fini(&p1); } ATF_TC(mkdtemp_err); ATF_TC_HEAD(mkdtemp_err, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkdtemp function, " "error conditions"); atf_tc_set_md_var(tc, "require.user", "unprivileged"); } ATF_TC_BODY(mkdtemp_err, tc) { atf_error_t err; atf_fs_path_t p; ATF_REQUIRE(mkdir("dir", 0555) != -1); RE(atf_fs_path_init_fmt(&p, "dir/testdir.XXXXXX")); err = atf_fs_mkdtemp(&p); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_CHECK_EQ(atf_libc_error_code(err), EACCES); atf_error_free(err); ATF_CHECK(!exists(&p)); ATF_CHECK(strcmp(atf_fs_path_cstring(&p), "dir/testdir.XXXXXX") == 0); atf_fs_path_fini(&p); } static void do_umask_check(atf_error_t (*const mk_func)(atf_fs_path_t *), atf_fs_path_t *path, const mode_t test_mask, const char *str_mask, const char *exp_name) { char buf[1024]; int old_umask; atf_error_t err; printf("Creating temporary %s with umask %s\n", exp_name, str_mask); old_umask = umask(test_mask); err = mk_func(path); (void)umask(old_umask); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "invalid_umask")); atf_error_format(err, buf, sizeof(buf)); ATF_CHECK(strstr(buf, exp_name) != NULL); ATF_CHECK(strstr(buf, str_mask) != NULL); atf_error_free(err); } ATF_TC(mkdtemp_umask); ATF_TC_HEAD(mkdtemp_umask, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkdtemp function " "causing an error due to a too strict umask"); } ATF_TC_BODY(mkdtemp_umask, tc) { atf_fs_path_t p; RE(atf_fs_path_init_fmt(&p, "testdir.XXXXXX")); do_umask_check(atf_fs_mkdtemp, &p, 00100, "00100", "directory"); do_umask_check(atf_fs_mkdtemp, &p, 00200, "00200", "directory"); do_umask_check(atf_fs_mkdtemp, &p, 00400, "00400", "directory"); do_umask_check(atf_fs_mkdtemp, &p, 00500, "00500", "directory"); do_umask_check(atf_fs_mkdtemp, &p, 00600, "00600", "directory"); atf_fs_path_fini(&p); } ATF_TC(mkstemp_ok); ATF_TC_HEAD(mkstemp_ok, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkstemp function, " "successful execution"); } ATF_TC_BODY(mkstemp_ok, tc) { int fd1, fd2; atf_fs_path_t p1, p2; atf_fs_stat_t s1, s2; RE(atf_fs_path_init_fmt(&p1, "testfile.XXXXXX")); RE(atf_fs_path_init_fmt(&p2, "testfile.XXXXXX")); fd1 = fd2 = -1; RE(atf_fs_mkstemp(&p1, &fd1)); RE(atf_fs_mkstemp(&p2, &fd2)); ATF_REQUIRE(!atf_equal_fs_path_fs_path(&p1, &p2)); ATF_REQUIRE(exists(&p1)); ATF_REQUIRE(exists(&p2)); ATF_CHECK(fd1 != -1); ATF_CHECK(fd2 != -1); ATF_CHECK(write(fd1, "foo", 3) == 3); ATF_CHECK(write(fd2, "bar", 3) == 3); close(fd1); close(fd2); RE(atf_fs_stat_init(&s1, &p1)); ATF_CHECK_EQ(atf_fs_stat_get_type(&s1), atf_fs_stat_reg_type); ATF_CHECK( atf_fs_stat_is_owner_readable(&s1)); ATF_CHECK( atf_fs_stat_is_owner_writable(&s1)); ATF_CHECK(!atf_fs_stat_is_owner_executable(&s1)); ATF_CHECK(!atf_fs_stat_is_group_readable(&s1)); ATF_CHECK(!atf_fs_stat_is_group_writable(&s1)); ATF_CHECK(!atf_fs_stat_is_group_executable(&s1)); ATF_CHECK(!atf_fs_stat_is_other_readable(&s1)); ATF_CHECK(!atf_fs_stat_is_other_writable(&s1)); ATF_CHECK(!atf_fs_stat_is_other_executable(&s1)); RE(atf_fs_stat_init(&s2, &p2)); ATF_CHECK_EQ(atf_fs_stat_get_type(&s2), atf_fs_stat_reg_type); ATF_CHECK( atf_fs_stat_is_owner_readable(&s2)); ATF_CHECK( atf_fs_stat_is_owner_writable(&s2)); ATF_CHECK(!atf_fs_stat_is_owner_executable(&s2)); ATF_CHECK(!atf_fs_stat_is_group_readable(&s2)); ATF_CHECK(!atf_fs_stat_is_group_writable(&s2)); ATF_CHECK(!atf_fs_stat_is_group_executable(&s2)); ATF_CHECK(!atf_fs_stat_is_other_readable(&s2)); ATF_CHECK(!atf_fs_stat_is_other_writable(&s2)); ATF_CHECK(!atf_fs_stat_is_other_executable(&s2)); atf_fs_stat_fini(&s2); atf_fs_stat_fini(&s1); atf_fs_path_fini(&p2); atf_fs_path_fini(&p1); } ATF_TC(mkstemp_err); ATF_TC_HEAD(mkstemp_err, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkstemp function, " "error conditions"); atf_tc_set_md_var(tc, "require.user", "unprivileged"); } ATF_TC_BODY(mkstemp_err, tc) { int fd; atf_error_t err; atf_fs_path_t p; ATF_REQUIRE(mkdir("dir", 0555) != -1); RE(atf_fs_path_init_fmt(&p, "dir/testfile.XXXXXX")); fd = 1234; err = atf_fs_mkstemp(&p, &fd); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_CHECK_EQ(atf_libc_error_code(err), EACCES); atf_error_free(err); ATF_CHECK(!exists(&p)); ATF_CHECK(strcmp(atf_fs_path_cstring(&p), "dir/testfile.XXXXXX") == 0); ATF_CHECK_EQ(fd, 1234); atf_fs_path_fini(&p); } ATF_TC(mkstemp_umask); ATF_TC_HEAD(mkstemp_umask, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_fs_mkstemp function " "causing an error due to a too strict umask"); } ATF_TC_BODY(mkstemp_umask, tc) { atf_fs_path_t p; RE(atf_fs_path_init_fmt(&p, "testfile.XXXXXX")); do_umask_check(mkstemp_discard_fd, &p, 00100, "00100", "regular file"); do_umask_check(mkstemp_discard_fd, &p, 00200, "00200", "regular file"); do_umask_check(mkstemp_discard_fd, &p, 00400, "00400", "regular file"); atf_fs_path_fini(&p); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the tests for the "atf_fs_path" type. */ ATF_TP_ADD_TC(tp, path_normalize); ATF_TP_ADD_TC(tp, path_copy); ATF_TP_ADD_TC(tp, path_is_absolute); ATF_TP_ADD_TC(tp, path_is_root); ATF_TP_ADD_TC(tp, path_branch_path); ATF_TP_ADD_TC(tp, path_leaf_name); ATF_TP_ADD_TC(tp, path_append); ATF_TP_ADD_TC(tp, path_to_absolute); ATF_TP_ADD_TC(tp, path_equal); /* Add the tests for the "atf_fs_stat" type. */ ATF_TP_ADD_TC(tp, stat_mode); ATF_TP_ADD_TC(tp, stat_type); ATF_TP_ADD_TC(tp, stat_perms); /* Add the tests for the free functions. */ ATF_TP_ADD_TC(tp, eaccess); ATF_TP_ADD_TC(tp, exists); ATF_TP_ADD_TC(tp, getcwd); ATF_TP_ADD_TC(tp, rmdir_empty); ATF_TP_ADD_TC(tp, rmdir_enotempty); ATF_TP_ADD_TC(tp, rmdir_eperm); ATF_TP_ADD_TC(tp, mkdtemp_ok); ATF_TP_ADD_TC(tp, mkdtemp_err); ATF_TP_ADD_TC(tp, mkdtemp_umask); ATF_TP_ADD_TC(tp, mkstemp_ok); ATF_TP_ADD_TC(tp, mkstemp_err); ATF_TP_ADD_TC(tp, mkstemp_umask); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/list.c =================================================================== --- head/contrib/atf/atf-c/detail/list.c (revision 273928) +++ head/contrib/atf/atf-c/detail/list.c (revision 273929) @@ -1,392 +1,388 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/list.h" + #include #include +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" #include "atf-c/utils.h" - -#include "list.h" -#include "sanity.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ struct list_entry { struct list_entry *m_prev; struct list_entry *m_next; void *m_object; bool m_managed; }; static atf_list_citer_t entry_to_citer(const atf_list_t *l, const struct list_entry *le) { atf_list_citer_t iter; iter.m_list = l; iter.m_entry = le; return iter; } static atf_list_iter_t entry_to_iter(atf_list_t *l, struct list_entry *le) { atf_list_iter_t iter; iter.m_list = l; iter.m_entry = le; return iter; } static struct list_entry * new_entry(void *object, bool managed) { struct list_entry *le; le = (struct list_entry *)malloc(sizeof(*le)); if (le != NULL) { le->m_prev = le->m_next = NULL; le->m_object = object; le->m_managed = managed; } else free(object); return le; } static void delete_entry(struct list_entry *le) { if (le->m_managed) free(le->m_object); free(le); } static struct list_entry * new_entry_and_link(void *object, bool managed, struct list_entry *prev, struct list_entry *next) { struct list_entry *le; le = new_entry(object, managed); if (le != NULL) { le->m_prev = prev; le->m_next = next; prev->m_next = le; next->m_prev = le; } return le; } /* --------------------------------------------------------------------- * The "atf_list_citer" type. * --------------------------------------------------------------------- */ /* * Getters. */ const void * atf_list_citer_data(const atf_list_citer_t citer) { const struct list_entry *le = citer.m_entry; PRE(le != NULL); return le->m_object; } atf_list_citer_t atf_list_citer_next(const atf_list_citer_t citer) { const struct list_entry *le = citer.m_entry; atf_list_citer_t newciter; PRE(le != NULL); newciter = citer; newciter.m_entry = le->m_next; return newciter; } bool atf_equal_list_citer_list_citer(const atf_list_citer_t i1, const atf_list_citer_t i2) { return i1.m_list == i2.m_list && i1.m_entry == i2.m_entry; } /* --------------------------------------------------------------------- * The "atf_list_iter" type. * --------------------------------------------------------------------- */ /* * Getters. */ void * atf_list_iter_data(const atf_list_iter_t iter) { const struct list_entry *le = iter.m_entry; PRE(le != NULL); return le->m_object; } atf_list_iter_t atf_list_iter_next(const atf_list_iter_t iter) { const struct list_entry *le = iter.m_entry; atf_list_iter_t newiter; PRE(le != NULL); newiter = iter; newiter.m_entry = le->m_next; return newiter; } bool atf_equal_list_iter_list_iter(const atf_list_iter_t i1, const atf_list_iter_t i2) { return i1.m_list == i2.m_list && i1.m_entry == i2.m_entry; } /* --------------------------------------------------------------------- * The "atf_list" type. * --------------------------------------------------------------------- */ /* * Constructors and destructors. */ atf_error_t atf_list_init(atf_list_t *l) { struct list_entry *lebeg, *leend; lebeg = new_entry(NULL, false); if (lebeg == NULL) { return atf_no_memory_error(); } leend = new_entry(NULL, false); if (leend == NULL) { free(lebeg); return atf_no_memory_error(); } lebeg->m_next = leend; lebeg->m_prev = NULL; leend->m_next = NULL; leend->m_prev = lebeg; l->m_size = 0; l->m_begin = lebeg; l->m_end = leend; return atf_no_error(); } void atf_list_fini(atf_list_t *l) { struct list_entry *le; size_t freed; le = (struct list_entry *)l->m_begin; freed = 0; while (le != NULL) { struct list_entry *lenext; lenext = le->m_next; delete_entry(le); le = lenext; freed++; } INV(freed == l->m_size + 2); } /* * Getters. */ atf_list_iter_t atf_list_begin(atf_list_t *l) { struct list_entry *le = l->m_begin; return entry_to_iter(l, le->m_next); } atf_list_citer_t atf_list_begin_c(const atf_list_t *l) { const struct list_entry *le = l->m_begin; return entry_to_citer(l, le->m_next); } atf_list_iter_t atf_list_end(atf_list_t *l) { return entry_to_iter(l, l->m_end); } atf_list_citer_t atf_list_end_c(const atf_list_t *l) { return entry_to_citer(l, l->m_end); } void * atf_list_index(atf_list_t *list, const size_t idx) { atf_list_iter_t iter; PRE(idx < atf_list_size(list)); iter = atf_list_begin(list); { size_t pos = 0; while (pos < idx && !atf_equal_list_iter_list_iter((iter), atf_list_end(list))) { iter = atf_list_iter_next(iter); pos++; } } return atf_list_iter_data(iter); } const void * atf_list_index_c(const atf_list_t *list, const size_t idx) { atf_list_citer_t iter; PRE(idx < atf_list_size(list)); iter = atf_list_begin_c(list); { size_t pos = 0; while (pos < idx && !atf_equal_list_citer_list_citer((iter), atf_list_end_c(list))) { iter = atf_list_citer_next(iter); pos++; } } return atf_list_citer_data(iter); } size_t atf_list_size(const atf_list_t *l) { return l->m_size; } char ** atf_list_to_charpp(const atf_list_t *l) { char **array; atf_list_citer_t iter; size_t i; array = malloc(sizeof(char *) * (atf_list_size(l) + 1)); if (array == NULL) goto out; i = 0; atf_list_for_each_c(iter, l) { array[i] = strdup((const char *)atf_list_citer_data(iter)); if (array[i] == NULL) { atf_utils_free_charpp(array); array = NULL; goto out; } i++; } array[i] = NULL; out: return array; } /* * Modifiers. */ atf_error_t atf_list_append(atf_list_t *l, void *data, bool managed) { struct list_entry *le, *next, *prev; atf_error_t err; next = (struct list_entry *)l->m_end; prev = next->m_prev; le = new_entry_and_link(data, managed, prev, next); if (le == NULL) err = atf_no_memory_error(); else { l->m_size++; err = atf_no_error(); } return err; } void atf_list_append_list(atf_list_t *l, atf_list_t *src) { struct list_entry *e1, *e2, *ghost1, *ghost2; ghost1 = (struct list_entry *)l->m_end; ghost2 = (struct list_entry *)src->m_begin; e1 = ghost1->m_prev; e2 = ghost2->m_next; delete_entry(ghost1); delete_entry(ghost2); e1->m_next = e2; e2->m_prev = e1; l->m_end = src->m_end; l->m_size += src->m_size; } Index: head/contrib/atf/atf-c/detail/list.h =================================================================== --- head/contrib/atf/atf-c/detail/list.h (revision 273928) +++ head/contrib/atf/atf-c/detail/list.h (revision 273929) @@ -1,115 +1,111 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_LIST_H) -#define ATF_C_LIST_H +#if !defined(ATF_C_DETAIL_LIST_H) +#define ATF_C_DETAIL_LIST_H #include #include #include #include /* --------------------------------------------------------------------- * The "atf_list_citer" type. * --------------------------------------------------------------------- */ struct atf_list_citer { const struct atf_list *m_list; const void *m_entry; }; typedef struct atf_list_citer atf_list_citer_t; /* Getters. */ const void *atf_list_citer_data(const atf_list_citer_t); atf_list_citer_t atf_list_citer_next(const atf_list_citer_t); /* Operators. */ bool atf_equal_list_citer_list_citer(const atf_list_citer_t, const atf_list_citer_t); /* --------------------------------------------------------------------- * The "atf_list_iter" type. * --------------------------------------------------------------------- */ struct atf_list_iter { struct atf_list *m_list; void *m_entry; }; typedef struct atf_list_iter atf_list_iter_t; /* Getters. */ void *atf_list_iter_data(const atf_list_iter_t); atf_list_iter_t atf_list_iter_next(const atf_list_iter_t); /* Operators. */ bool atf_equal_list_iter_list_iter(const atf_list_iter_t, const atf_list_iter_t); /* --------------------------------------------------------------------- * The "atf_list" type. * --------------------------------------------------------------------- */ struct atf_list { void *m_begin; void *m_end; size_t m_size; }; typedef struct atf_list atf_list_t; /* Constructors and destructors */ atf_error_t atf_list_init(atf_list_t *); void atf_list_fini(atf_list_t *); /* Getters. */ atf_list_iter_t atf_list_begin(atf_list_t *); atf_list_citer_t atf_list_begin_c(const atf_list_t *); atf_list_iter_t atf_list_end(atf_list_t *); atf_list_citer_t atf_list_end_c(const atf_list_t *); void *atf_list_index(atf_list_t *, const size_t); const void *atf_list_index_c(const atf_list_t *, const size_t); size_t atf_list_size(const atf_list_t *); char **atf_list_to_charpp(const atf_list_t *); /* Modifiers. */ atf_error_t atf_list_append(atf_list_t *, void *, bool); void atf_list_append_list(atf_list_t *, atf_list_t *); /* Macros. */ #define atf_list_for_each(iter, list) \ for (iter = atf_list_begin(list); \ !atf_equal_list_iter_list_iter((iter), atf_list_end(list)); \ iter = atf_list_iter_next(iter)) #define atf_list_for_each_c(iter, list) \ for (iter = atf_list_begin_c(list); \ !atf_equal_list_citer_list_citer((iter), atf_list_end_c(list)); \ iter = atf_list_citer_next(iter)) -#endif /* ATF_C_LIST_H */ +#endif /* !defined(ATF_C_DETAIL_LIST_H) */ Index: head/contrib/atf/atf-c/detail/list_test.c =================================================================== --- head/contrib/atf/atf-c/detail/list_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/list_test.c (revision 273929) @@ -1,369 +1,365 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/list.h" + #include #include #include +#include "atf-c/detail/test_helpers.h" #include "atf-c/utils.h" - -#include "list.h" -#include "test_helpers.h" /* --------------------------------------------------------------------- * Tests for the "atf_list" type. * --------------------------------------------------------------------- */ /* * Constructors and destructors. */ ATF_TC(list_init); ATF_TC_HEAD(list_init, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_init function"); } ATF_TC_BODY(list_init, tc) { atf_list_t list; RE(atf_list_init(&list)); ATF_REQUIRE_EQ(atf_list_size(&list), 0); atf_list_fini(&list); } /* * Getters. */ ATF_TC(list_index); ATF_TC_HEAD(list_index, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_index function"); } ATF_TC_BODY(list_index, tc) { atf_list_t list; int i1 = 1; int i2 = 5; int i3 = 9; RE(atf_list_init(&list)); RE(atf_list_append(&list, &i1, false)); RE(atf_list_append(&list, &i2, false)); RE(atf_list_append(&list, &i3, false)); ATF_CHECK_EQ(*(int *)atf_list_index(&list, 0), 1); ATF_CHECK_EQ(*(int *)atf_list_index(&list, 1), 5); ATF_CHECK_EQ(*(int *)atf_list_index(&list, 2), 9); atf_list_fini(&list); } ATF_TC(list_index_c); ATF_TC_HEAD(list_index_c, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_index_c function"); } ATF_TC_BODY(list_index_c, tc) { atf_list_t list; int i1 = 1; int i2 = 5; int i3 = 9; RE(atf_list_init(&list)); RE(atf_list_append(&list, &i1, false)); RE(atf_list_append(&list, &i2, false)); RE(atf_list_append(&list, &i3, false)); ATF_CHECK_EQ(*(const int *)atf_list_index_c(&list, 0), 1); ATF_CHECK_EQ(*(const int *)atf_list_index_c(&list, 1), 5); ATF_CHECK_EQ(*(const int *)atf_list_index_c(&list, 2), 9); atf_list_fini(&list); } ATF_TC_WITHOUT_HEAD(list_to_charpp_empty); ATF_TC_BODY(list_to_charpp_empty, tc) { atf_list_t list; char **array; RE(atf_list_init(&list)); ATF_REQUIRE((array = atf_list_to_charpp(&list)) != NULL); atf_list_fini(&list); ATF_CHECK_EQ(NULL, array[0]); atf_utils_free_charpp(array); } ATF_TC_WITHOUT_HEAD(list_to_charpp_some); ATF_TC_BODY(list_to_charpp_some, tc) { atf_list_t list; char **array; char s1[] = "one"; char s2[] = "two"; char s3[] = "three"; RE(atf_list_init(&list)); RE(atf_list_append(&list, s1, false)); RE(atf_list_append(&list, s2, false)); RE(atf_list_append(&list, s3, false)); ATF_REQUIRE((array = atf_list_to_charpp(&list)) != NULL); atf_list_fini(&list); ATF_CHECK_STREQ("one", array[0]); ATF_CHECK_STREQ("two", array[1]); ATF_CHECK_STREQ("three", array[2]); ATF_CHECK_EQ(NULL, array[3]); atf_utils_free_charpp(array); } /* * Modifiers. */ ATF_TC(list_append); ATF_TC_HEAD(list_append, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_append function"); } ATF_TC_BODY(list_append, tc) { atf_list_t list; size_t i; char buf[] = "Test string"; RE(atf_list_init(&list)); for (i = 0; i < 1024; i++) { ATF_REQUIRE_EQ(atf_list_size(&list), i); RE(atf_list_append(&list, buf, false)); } atf_list_fini(&list); } ATF_TC(list_append_list); ATF_TC_HEAD(list_append_list, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_append_list " "function"); } ATF_TC_BODY(list_append_list, tc) { { atf_list_t l1, l2; RE(atf_list_init(&l1)); RE(atf_list_init(&l2)); atf_list_append_list(&l1, &l2); ATF_CHECK_EQ(atf_list_size(&l1), 0); atf_list_fini(&l1); } { atf_list_t l1, l2; int item = 5; RE(atf_list_init(&l1)); RE(atf_list_append(&l1, &item, false)); RE(atf_list_init(&l2)); atf_list_append_list(&l1, &l2); ATF_CHECK_EQ(atf_list_size(&l1), 1); ATF_CHECK_EQ(*(int *)atf_list_index(&l1, 0), item); atf_list_fini(&l1); } { atf_list_t l1, l2; int item = 5; RE(atf_list_init(&l1)); RE(atf_list_init(&l2)); RE(atf_list_append(&l2, &item, false)); atf_list_append_list(&l1, &l2); ATF_CHECK_EQ(atf_list_size(&l1), 1); ATF_CHECK_EQ(*(int *)atf_list_index(&l1, 0), item); atf_list_fini(&l1); } { atf_list_t l1, l2; int item1 = 5; int item2 = 9; RE(atf_list_init(&l1)); RE(atf_list_append(&l1, &item1, false)); RE(atf_list_init(&l2)); RE(atf_list_append(&l2, &item2, false)); atf_list_append_list(&l1, &l2); ATF_CHECK_EQ(atf_list_size(&l1), 2); ATF_CHECK_EQ(*(int *)atf_list_index(&l1, 0), item1); ATF_CHECK_EQ(*(int *)atf_list_index(&l1, 1), item2); atf_list_fini(&l1); } { atf_list_t l1, l2; atf_list_citer_t end1, end2; RE(atf_list_init(&l1)); RE(atf_list_init(&l2)); end1 = atf_list_end_c(&l1); end2 = atf_list_end_c(&l2); /* XXX Shouldn't query m_entry here. */ ATF_CHECK(end1.m_entry != end2.m_entry); atf_list_append_list(&l1, &l2); ATF_CHECK(atf_list_end_c(&l1).m_entry == end2.m_entry); atf_list_fini(&l1); } } /* * Macros. */ ATF_TC(list_for_each); ATF_TC_HEAD(list_for_each, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_for_each macro"); } ATF_TC_BODY(list_for_each, tc) { atf_list_t list; atf_list_iter_t iter; size_t count, i, size; int nums[10]; printf("Iterating over empty list\n"); RE(atf_list_init(&list)); count = 0; atf_list_for_each(iter, &list) { count++; printf("Item count is now %zd\n", count); } ATF_REQUIRE_EQ(count, 0); atf_list_fini(&list); for (size = 0; size <= 10; size++) { printf("Iterating over list of %zd elements\n", size); RE(atf_list_init(&list)); for (i = 0; i < size; i++) { nums[i] = i + 1; RE(atf_list_append(&list, &nums[i], false)); } count = 0; atf_list_for_each(iter, &list) { printf("Retrieved item: %d\n", *(int *)atf_list_iter_data(iter)); count++; } ATF_REQUIRE_EQ(count, size); atf_list_fini(&list); } } ATF_TC(list_for_each_c); ATF_TC_HEAD(list_for_each_c, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_list_for_each_c macro"); } ATF_TC_BODY(list_for_each_c, tc) { atf_list_t list; atf_list_citer_t iter; size_t count, i, size; int nums[10]; printf("Iterating over empty list\n"); RE(atf_list_init(&list)); count = 0; atf_list_for_each_c(iter, &list) { count++; printf("Item count is now %zd\n", count); } ATF_REQUIRE_EQ(count, 0); atf_list_fini(&list); for (size = 0; size <= 10; size++) { printf("Iterating over list of %zd elements\n", size); RE(atf_list_init(&list)); for (i = 0; i < size; i++) { nums[i] = i + 1; RE(atf_list_append(&list, &nums[i], false)); } count = 0; atf_list_for_each_c(iter, &list) { printf("Retrieved item: %d\n", *(const int *)atf_list_citer_data(iter)); count++; } ATF_REQUIRE_EQ(count, size); atf_list_fini(&list); } } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Constructors and destructors. */ ATF_TP_ADD_TC(tp, list_init); /* Getters. */ ATF_TP_ADD_TC(tp, list_index); ATF_TP_ADD_TC(tp, list_index_c); ATF_TP_ADD_TC(tp, list_to_charpp_empty); ATF_TP_ADD_TC(tp, list_to_charpp_some); /* Modifiers. */ ATF_TP_ADD_TC(tp, list_append); ATF_TP_ADD_TC(tp, list_append_list); /* Macros. */ ATF_TP_ADD_TC(tp, list_for_each); ATF_TP_ADD_TC(tp, list_for_each_c); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/map.c =================================================================== --- head/contrib/atf/atf-c/detail/map.c (revision 273928) +++ head/contrib/atf/atf-c/detail/map.c (revision 273929) @@ -1,383 +1,379 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/map.h" + #include #include #include +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" #include "atf-c/utils.h" - -#include "map.h" -#include "sanity.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ struct map_entry { char *m_key; void *m_value; bool m_managed; }; static struct map_entry * new_entry(const char *key, void *value, bool managed) { struct map_entry *me; me = (struct map_entry *)malloc(sizeof(*me)); if (me != NULL) { me->m_key = strdup(key); if (me->m_key == NULL) { free(me); me = NULL; } else { me->m_value = value; me->m_managed = managed; } } return me; } /* --------------------------------------------------------------------- * The "atf_map_citer" type. * --------------------------------------------------------------------- */ /* * Getters. */ const char * atf_map_citer_key(const atf_map_citer_t citer) { const struct map_entry *me = citer.m_entry; PRE(me != NULL); return me->m_key; } const void * atf_map_citer_data(const atf_map_citer_t citer) { const struct map_entry *me = citer.m_entry; PRE(me != NULL); return me->m_value; } atf_map_citer_t atf_map_citer_next(const atf_map_citer_t citer) { atf_map_citer_t newciter; newciter = citer; newciter.m_listiter = atf_list_citer_next(citer.m_listiter); newciter.m_entry = ((const struct map_entry *) atf_list_citer_data(newciter.m_listiter)); return newciter; } bool atf_equal_map_citer_map_citer(const atf_map_citer_t i1, const atf_map_citer_t i2) { return i1.m_map == i2.m_map && i1.m_entry == i2.m_entry; } /* --------------------------------------------------------------------- * The "atf_map_iter" type. * --------------------------------------------------------------------- */ /* * Getters. */ const char * atf_map_iter_key(const atf_map_iter_t iter) { const struct map_entry *me = iter.m_entry; PRE(me != NULL); return me->m_key; } void * atf_map_iter_data(const atf_map_iter_t iter) { const struct map_entry *me = iter.m_entry; PRE(me != NULL); return me->m_value; } atf_map_iter_t atf_map_iter_next(const atf_map_iter_t iter) { atf_map_iter_t newiter; newiter = iter; newiter.m_listiter = atf_list_iter_next(iter.m_listiter); newiter.m_entry = ((struct map_entry *) atf_list_iter_data(newiter.m_listiter)); return newiter; } bool atf_equal_map_iter_map_iter(const atf_map_iter_t i1, const atf_map_iter_t i2) { return i1.m_map == i2.m_map && i1.m_entry == i2.m_entry; } /* --------------------------------------------------------------------- * The "atf_map" type. * --------------------------------------------------------------------- */ /* * Constructors and destructors. */ atf_error_t atf_map_init(atf_map_t *m) { return atf_list_init(&m->m_list); } atf_error_t atf_map_init_charpp(atf_map_t *m, const char *const *array) { atf_error_t err; const char *const *ptr = array; err = atf_map_init(m); if (array != NULL) { while (!atf_is_error(err) && *ptr != NULL) { const char *key, *value; key = *ptr; INV(key != NULL); ptr++; if ((value = *ptr) == NULL) { err = atf_libc_error(EINVAL, "List too short; no value for " "key '%s' provided", key); /* XXX: Not really libc_error */ break; } ptr++; err = atf_map_insert(m, key, strdup(value), true); } } if (atf_is_error(err)) atf_map_fini(m); return err; } void atf_map_fini(atf_map_t *m) { atf_list_iter_t iter; atf_list_for_each(iter, &m->m_list) { struct map_entry *me = atf_list_iter_data(iter); if (me->m_managed) free(me->m_value); free(me->m_key); free(me); } atf_list_fini(&m->m_list); } /* * Getters. */ atf_map_iter_t atf_map_begin(atf_map_t *m) { atf_map_iter_t iter; iter.m_map = m; iter.m_listiter = atf_list_begin(&m->m_list); iter.m_entry = atf_list_iter_data(iter.m_listiter); return iter; } atf_map_citer_t atf_map_begin_c(const atf_map_t *m) { atf_map_citer_t citer; citer.m_map = m; citer.m_listiter = atf_list_begin_c(&m->m_list); citer.m_entry = atf_list_citer_data(citer.m_listiter); return citer; } atf_map_iter_t atf_map_end(atf_map_t *m) { atf_map_iter_t iter; iter.m_map = m; iter.m_entry = NULL; iter.m_listiter = atf_list_end(&m->m_list); return iter; } atf_map_citer_t atf_map_end_c(const atf_map_t *m) { atf_map_citer_t iter; iter.m_map = m; iter.m_entry = NULL; iter.m_listiter = atf_list_end_c(&m->m_list); return iter; } atf_map_iter_t atf_map_find(atf_map_t *m, const char *key) { atf_list_iter_t iter; atf_list_for_each(iter, &m->m_list) { struct map_entry *me = atf_list_iter_data(iter); if (strcmp(me->m_key, key) == 0) { atf_map_iter_t i; i.m_map = m; i.m_entry = me; i.m_listiter = iter; return i; } } return atf_map_end(m); } atf_map_citer_t atf_map_find_c(const atf_map_t *m, const char *key) { atf_list_citer_t iter; atf_list_for_each_c(iter, &m->m_list) { const struct map_entry *me = atf_list_citer_data(iter); if (strcmp(me->m_key, key) == 0) { atf_map_citer_t i; i.m_map = m; i.m_entry = me; i.m_listiter = iter; return i; } } return atf_map_end_c(m); } size_t atf_map_size(const atf_map_t *m) { return atf_list_size(&m->m_list); } char ** atf_map_to_charpp(const atf_map_t *l) { char **array; atf_map_citer_t iter; size_t i; array = malloc(sizeof(char *) * (atf_map_size(l) * 2 + 1)); if (array == NULL) goto out; i = 0; atf_map_for_each_c(iter, l) { array[i] = strdup(atf_map_citer_key(iter)); if (array[i] == NULL) { atf_utils_free_charpp(array); array = NULL; goto out; } array[i + 1] = strdup((const char *)atf_map_citer_data(iter)); if (array[i + 1] == NULL) { atf_utils_free_charpp(array); array = NULL; goto out; } i += 2; } array[i] = NULL; out: return array; } /* * Modifiers. */ atf_error_t atf_map_insert(atf_map_t *m, const char *key, void *value, bool managed) { struct map_entry *me; atf_error_t err; atf_map_iter_t iter; iter = atf_map_find(m, key); if (atf_equal_map_iter_map_iter(iter, atf_map_end(m))) { me = new_entry(key, value, managed); if (me == NULL) err = atf_no_memory_error(); else { err = atf_list_append(&m->m_list, me, false); if (atf_is_error(err)) { if (managed) free(value); free(me); } } } else { me = iter.m_entry; if (me->m_managed) free(me->m_value); INV(strcmp(me->m_key, key) == 0); me->m_value = value; me->m_managed = managed; err = atf_no_error(); } return err; } Index: head/contrib/atf/atf-c/detail/map.h =================================================================== --- head/contrib/atf/atf-c/detail/map.h (revision 273928) +++ head/contrib/atf/atf-c/detail/map.h (revision 273929) @@ -1,119 +1,114 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_MAP_H) -#define ATF_C_MAP_H +#if !defined(ATF_C_DETAIL_MAP_H) +#define ATF_C_DETAIL_MAP_H #include #include +#include #include -#include "list.h" - /* --------------------------------------------------------------------- * The "atf_map_citer" type. * --------------------------------------------------------------------- */ struct atf_map_citer { const struct atf_map *m_map; const void *m_entry; atf_list_citer_t m_listiter; }; typedef struct atf_map_citer atf_map_citer_t; /* Getters. */ const char *atf_map_citer_key(const atf_map_citer_t); const void *atf_map_citer_data(const atf_map_citer_t); atf_map_citer_t atf_map_citer_next(const atf_map_citer_t); /* Operators. */ bool atf_equal_map_citer_map_citer(const atf_map_citer_t, const atf_map_citer_t); /* --------------------------------------------------------------------- * The "atf_map_iter" type. * --------------------------------------------------------------------- */ struct atf_map_iter { struct atf_map *m_map; void *m_entry; atf_list_iter_t m_listiter; }; typedef struct atf_map_iter atf_map_iter_t; /* Getters. */ const char *atf_map_iter_key(const atf_map_iter_t); void *atf_map_iter_data(const atf_map_iter_t); atf_map_iter_t atf_map_iter_next(const atf_map_iter_t); /* Operators. */ bool atf_equal_map_iter_map_iter(const atf_map_iter_t, const atf_map_iter_t); /* --------------------------------------------------------------------- * The "atf_map" type. * --------------------------------------------------------------------- */ /* A list-based map. Typically very inefficient, but our maps are small * enough. */ struct atf_map { atf_list_t m_list; }; typedef struct atf_map atf_map_t; /* Constructors and destructors */ atf_error_t atf_map_init(atf_map_t *); atf_error_t atf_map_init_charpp(atf_map_t *, const char *const *); void atf_map_fini(atf_map_t *); /* Getters. */ atf_map_iter_t atf_map_begin(atf_map_t *); atf_map_citer_t atf_map_begin_c(const atf_map_t *); atf_map_iter_t atf_map_end(atf_map_t *); atf_map_citer_t atf_map_end_c(const atf_map_t *); atf_map_iter_t atf_map_find(atf_map_t *, const char *); atf_map_citer_t atf_map_find_c(const atf_map_t *, const char *); size_t atf_map_size(const atf_map_t *); char **atf_map_to_charpp(const atf_map_t *); /* Modifiers. */ atf_error_t atf_map_insert(atf_map_t *, const char *, void *, bool); /* Macros. */ #define atf_map_for_each(iter, map) \ for (iter = atf_map_begin(map); \ !atf_equal_map_iter_map_iter((iter), atf_map_end(map)); \ iter = atf_map_iter_next(iter)) #define atf_map_for_each_c(iter, map) \ for (iter = atf_map_begin_c(map); \ !atf_equal_map_citer_map_citer((iter), atf_map_end_c(map)); \ iter = atf_map_citer_next(iter)) -#endif /* ATF_C_MAP_H */ +#endif /* !defined(ATF_C_DETAIL_MAP_H) */ Index: head/contrib/atf/atf-c/detail/map_test.c =================================================================== --- head/contrib/atf/atf-c/detail/map_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/map_test.c (revision 273929) @@ -1,425 +1,421 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/map.h" + #include #include #include +#include "atf-c/detail/test_helpers.h" #include "atf-c/utils.h" - -#include "map.h" -#include "test_helpers.h" /* --------------------------------------------------------------------- * Tests for the "atf_map" type. * --------------------------------------------------------------------- */ /* * Constructors and destructors. */ ATF_TC(map_init); ATF_TC_HEAD(map_init, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_init function"); } ATF_TC_BODY(map_init, tc) { atf_map_t map; RE(atf_map_init(&map)); ATF_REQUIRE_EQ(atf_map_size(&map), 0); atf_map_fini(&map); } ATF_TC_WITHOUT_HEAD(map_init_charpp_null); ATF_TC_BODY(map_init_charpp_null, tc) { atf_map_t map; RE(atf_map_init_charpp(&map, NULL)); ATF_REQUIRE_EQ(atf_map_size(&map), 0); atf_map_fini(&map); } ATF_TC_WITHOUT_HEAD(map_init_charpp_empty); ATF_TC_BODY(map_init_charpp_empty, tc) { const char *const array[] = { NULL }; atf_map_t map; RE(atf_map_init_charpp(&map, array)); ATF_REQUIRE_EQ(atf_map_size(&map), 0); atf_map_fini(&map); } ATF_TC_WITHOUT_HEAD(map_init_charpp_some); ATF_TC_BODY(map_init_charpp_some, tc) { const char *const array[] = { "K1", "V1", "K2", "V2", NULL }; atf_map_t map; atf_map_citer_t iter; RE(atf_map_init_charpp(&map, array)); ATF_REQUIRE_EQ(atf_map_size(&map), 2); iter = atf_map_find_c(&map, "K1"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ATF_REQUIRE(strcmp(atf_map_citer_key(iter), "K1") == 0); ATF_REQUIRE(strcmp(atf_map_citer_data(iter), "V1") == 0); iter = atf_map_find_c(&map, "K2"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ATF_REQUIRE(strcmp(atf_map_citer_key(iter), "K2") == 0); ATF_REQUIRE(strcmp(atf_map_citer_data(iter), "V2") == 0); atf_map_fini(&map); } ATF_TC_WITHOUT_HEAD(map_init_charpp_short); ATF_TC_BODY(map_init_charpp_short, tc) { const char *const array[] = { "K1", "V1", "K2", NULL }; atf_map_t map; atf_error_t err = atf_map_init_charpp(&map, array); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "libc")); } /* * Getters. */ ATF_TC(find); ATF_TC_HEAD(find, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_find function"); } ATF_TC_BODY(find, tc) { atf_map_t map; char val1[] = "V1"; char val2[] = "V2"; atf_map_iter_t iter; RE(atf_map_init(&map)); RE(atf_map_insert(&map, "K1", val1, false)); RE(atf_map_insert(&map, "K2", val2, false)); iter = atf_map_find(&map, "K0"); ATF_REQUIRE(atf_equal_map_iter_map_iter(iter, atf_map_end(&map))); iter = atf_map_find(&map, "K1"); ATF_REQUIRE(!atf_equal_map_iter_map_iter(iter, atf_map_end(&map))); ATF_REQUIRE(strcmp(atf_map_iter_key(iter), "K1") == 0); ATF_REQUIRE(strcmp(atf_map_iter_data(iter), "V1") == 0); strcpy(atf_map_iter_data(iter), "Z1"); iter = atf_map_find(&map, "K1"); ATF_REQUIRE(!atf_equal_map_iter_map_iter(iter, atf_map_end(&map))); ATF_REQUIRE(strcmp(atf_map_iter_key(iter), "K1") == 0); ATF_REQUIRE(strcmp(atf_map_iter_data(iter), "Z1") == 0); iter = atf_map_find(&map, "K2"); ATF_REQUIRE(!atf_equal_map_iter_map_iter(iter, atf_map_end(&map))); ATF_REQUIRE(strcmp(atf_map_iter_key(iter), "K2") == 0); ATF_REQUIRE(strcmp(atf_map_iter_data(iter), "V2") == 0); atf_map_fini(&map); } ATF_TC(find_c); ATF_TC_HEAD(find_c, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_find_c function"); } ATF_TC_BODY(find_c, tc) { atf_map_t map; char val1[] = "V1"; char val2[] = "V2"; atf_map_citer_t iter; RE(atf_map_init(&map)); RE(atf_map_insert(&map, "K1", val1, false)); RE(atf_map_insert(&map, "K2", val2, false)); iter = atf_map_find_c(&map, "K0"); ATF_REQUIRE(atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); iter = atf_map_find_c(&map, "K1"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ATF_REQUIRE(strcmp(atf_map_citer_key(iter), "K1") == 0); ATF_REQUIRE(strcmp(atf_map_citer_data(iter), "V1") == 0); iter = atf_map_find_c(&map, "K2"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ATF_REQUIRE(strcmp(atf_map_citer_key(iter), "K2") == 0); ATF_REQUIRE(strcmp(atf_map_citer_data(iter), "V2") == 0); atf_map_fini(&map); } ATF_TC_WITHOUT_HEAD(to_charpp_empty); ATF_TC_BODY(to_charpp_empty, tc) { atf_map_t map; char **array; RE(atf_map_init(&map)); ATF_REQUIRE((array = atf_map_to_charpp(&map)) != NULL); atf_map_fini(&map); ATF_CHECK_EQ(NULL, array[0]); atf_utils_free_charpp(array); } ATF_TC_WITHOUT_HEAD(to_charpp_some); ATF_TC_BODY(to_charpp_some, tc) { atf_map_t map; char **array; char s1[] = "one"; char s2[] = "two"; char s3[] = "three"; RE(atf_map_init(&map)); RE(atf_map_insert(&map, "K1", s1, false)); RE(atf_map_insert(&map, "K2", s2, false)); RE(atf_map_insert(&map, "K3", s3, false)); ATF_REQUIRE((array = atf_map_to_charpp(&map)) != NULL); atf_map_fini(&map); ATF_CHECK_STREQ("K1", array[0]); ATF_CHECK_STREQ("one", array[1]); ATF_CHECK_STREQ("K2", array[2]); ATF_CHECK_STREQ("two", array[3]); ATF_CHECK_STREQ("K3", array[4]); ATF_CHECK_STREQ("three", array[5]); ATF_CHECK_EQ(NULL, array[6]); atf_utils_free_charpp(array); } /* * Modifiers. */ ATF_TC(map_insert); ATF_TC_HEAD(map_insert, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_insert function"); } ATF_TC_BODY(map_insert, tc) { atf_map_t map; char buf[] = "1st test string"; char buf2[] = "2nd test string"; const char *ptr; atf_map_citer_t iter; RE(atf_map_init(&map)); printf("Inserting some values\n"); ATF_REQUIRE_EQ(atf_map_size(&map), 0); RE(atf_map_insert(&map, "K1", buf, false)); ATF_REQUIRE_EQ(atf_map_size(&map), 1); RE(atf_map_insert(&map, "K2", buf, false)); ATF_REQUIRE_EQ(atf_map_size(&map), 2); RE(atf_map_insert(&map, "K3", buf, false)); ATF_REQUIRE_EQ(atf_map_size(&map), 3); printf("Replacing a value\n"); iter = atf_map_find_c(&map, "K3"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ptr = atf_map_citer_data(iter); ATF_REQUIRE_EQ(ptr, buf); RE(atf_map_insert(&map, "K3", buf2, false)); ATF_REQUIRE_EQ(atf_map_size(&map), 3); iter = atf_map_find_c(&map, "K3"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); ptr = atf_map_citer_data(iter); ATF_REQUIRE_EQ(ptr, buf2); atf_map_fini(&map); } /* * Macros. */ ATF_TC(map_for_each); ATF_TC_HEAD(map_for_each, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_for_each macro"); } ATF_TC_BODY(map_for_each, tc) { atf_map_t map; atf_map_iter_t iter; size_t count, i, size; char keys[10][5]; int nums[10]; printf("Iterating over empty map\n"); RE(atf_map_init(&map)); count = 0; atf_map_for_each(iter, &map) { count++; printf("Item count is now %zd\n", count); } ATF_REQUIRE_EQ(count, 0); atf_map_fini(&map); for (size = 0; size <= 10; size++) { printf("Iterating over map of %zd elements\n", size); RE(atf_map_init(&map)); for (i = 0; i < size; i++) { nums[i] = i + 1; snprintf(keys[i], sizeof(keys[i]), "%d", nums[i]); RE(atf_map_insert(&map, keys[i], &nums[i], false)); } count = 0; atf_map_for_each(iter, &map) { printf("Retrieved item: %d\n", *(int *)atf_map_iter_data(iter)); count++; } ATF_REQUIRE_EQ(count, size); atf_map_fini(&map); } } ATF_TC(map_for_each_c); ATF_TC_HEAD(map_for_each_c, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_map_for_each_c macro"); } ATF_TC_BODY(map_for_each_c, tc) { atf_map_t map; atf_map_citer_t iter; size_t count, i, size; char keys[10][5]; int nums[10]; printf("Iterating over empty map\n"); RE(atf_map_init(&map)); count = 0; atf_map_for_each_c(iter, &map) { count++; printf("Item count is now %zd\n", count); } ATF_REQUIRE_EQ(count, 0); atf_map_fini(&map); for (size = 0; size <= 10; size++) { printf("Iterating over map of %zd elements\n", size); RE(atf_map_init(&map)); for (i = 0; i < size; i++) { nums[i] = i + 1; snprintf(keys[i], sizeof(keys[i]), "%d", nums[i]); RE(atf_map_insert(&map, keys[i], &nums[i], false)); } count = 0; atf_map_for_each_c(iter, &map) { printf("Retrieved item: %d\n", *(const int *)atf_map_citer_data(iter)); count++; } ATF_REQUIRE_EQ(count, size); atf_map_fini(&map); } } /* * Other. */ ATF_TC(stable_keys); ATF_TC_HEAD(stable_keys, tc) { atf_tc_set_md_var(tc, "descr", "Checks that the keys do not change " "even if their original values do"); } ATF_TC_BODY(stable_keys, tc) { atf_map_t map; atf_map_citer_t iter; char key[] = "K1"; RE(atf_map_init(&map)); RE(atf_map_insert(&map, key, strdup("test-value"), true)); iter = atf_map_find_c(&map, "K1"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); iter = atf_map_find_c(&map, "K2"); ATF_REQUIRE(atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); strcpy(key, "K2"); iter = atf_map_find_c(&map, "K1"); ATF_REQUIRE(!atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); iter = atf_map_find_c(&map, "K2"); ATF_REQUIRE(atf_equal_map_citer_map_citer(iter, atf_map_end_c(&map))); atf_map_fini(&map); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Constructors and destructors. */ ATF_TP_ADD_TC(tp, map_init); ATF_TP_ADD_TC(tp, map_init_charpp_null); ATF_TP_ADD_TC(tp, map_init_charpp_empty); ATF_TP_ADD_TC(tp, map_init_charpp_some); ATF_TP_ADD_TC(tp, map_init_charpp_short); /* Getters. */ ATF_TP_ADD_TC(tp, find); ATF_TP_ADD_TC(tp, find_c); ATF_TP_ADD_TC(tp, to_charpp_empty); ATF_TP_ADD_TC(tp, to_charpp_some); /* Modifiers. */ ATF_TP_ADD_TC(tp, map_insert); /* Macros. */ ATF_TP_ADD_TC(tp, map_for_each); ATF_TP_ADD_TC(tp, map_for_each_c); /* Other. */ ATF_TP_ADD_TC(tp, stable_keys); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/process.c =================================================================== --- head/contrib/atf/atf-c/detail/process.c (revision 273928) +++ head/contrib/atf/atf-c/detail/process.c (revision 273929) @@ -1,674 +1,670 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/process.h" + #include #include #include #include #include #include #include #include #include "atf-c/defs.h" +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" - -#include "process.h" -#include "sanity.h" /* This prototype is not in the header file because this is a private * function; however, we need to access it during testing. */ atf_error_t atf_process_status_init(atf_process_status_t *, int); /* --------------------------------------------------------------------- * The "stream_prepare" auxiliary type. * --------------------------------------------------------------------- */ struct stream_prepare { const atf_process_stream_t *m_sb; bool m_pipefds_ok; int m_pipefds[2]; }; typedef struct stream_prepare stream_prepare_t; static atf_error_t stream_prepare_init(stream_prepare_t *sp, const atf_process_stream_t *sb) { atf_error_t err; const int type = atf_process_stream_type(sb); sp->m_sb = sb; sp->m_pipefds_ok = false; if (type == atf_process_stream_type_capture) { if (pipe(sp->m_pipefds) == -1) err = atf_libc_error(errno, "Failed to create pipe"); else { err = atf_no_error(); sp->m_pipefds_ok = true; } } else err = atf_no_error(); return err; } static void stream_prepare_fini(stream_prepare_t *sp) { if (sp->m_pipefds_ok) { close(sp->m_pipefds[0]); close(sp->m_pipefds[1]); } } /* --------------------------------------------------------------------- * The "atf_process_stream" type. * --------------------------------------------------------------------- */ const int atf_process_stream_type_capture = 1; const int atf_process_stream_type_connect = 2; const int atf_process_stream_type_inherit = 3; const int atf_process_stream_type_redirect_fd = 4; const int atf_process_stream_type_redirect_path = 5; static bool stream_is_valid(const atf_process_stream_t *sb) { return (sb->m_type == atf_process_stream_type_capture) || (sb->m_type == atf_process_stream_type_connect) || (sb->m_type == atf_process_stream_type_inherit) || (sb->m_type == atf_process_stream_type_redirect_fd) || (sb->m_type == atf_process_stream_type_redirect_path); } atf_error_t atf_process_stream_init_capture(atf_process_stream_t *sb) { sb->m_type = atf_process_stream_type_capture; POST(stream_is_valid(sb)); return atf_no_error(); } atf_error_t atf_process_stream_init_connect(atf_process_stream_t *sb, const int src_fd, const int tgt_fd) { PRE(src_fd >= 0); PRE(tgt_fd >= 0); PRE(src_fd != tgt_fd); sb->m_type = atf_process_stream_type_connect; sb->m_src_fd = src_fd; sb->m_tgt_fd = tgt_fd; POST(stream_is_valid(sb)); return atf_no_error(); } atf_error_t atf_process_stream_init_inherit(atf_process_stream_t *sb) { sb->m_type = atf_process_stream_type_inherit; POST(stream_is_valid(sb)); return atf_no_error(); } atf_error_t atf_process_stream_init_redirect_fd(atf_process_stream_t *sb, const int fd) { sb->m_type = atf_process_stream_type_redirect_fd; sb->m_fd = fd; POST(stream_is_valid(sb)); return atf_no_error(); } atf_error_t atf_process_stream_init_redirect_path(atf_process_stream_t *sb, const atf_fs_path_t *path) { sb->m_type = atf_process_stream_type_redirect_path; sb->m_path = path; POST(stream_is_valid(sb)); return atf_no_error(); } void atf_process_stream_fini(atf_process_stream_t *sb) { PRE(stream_is_valid(sb)); } int atf_process_stream_type(const atf_process_stream_t *sb) { PRE(stream_is_valid(sb)); return sb->m_type; } /* --------------------------------------------------------------------- * The "atf_process_status" type. * --------------------------------------------------------------------- */ atf_error_t atf_process_status_init(atf_process_status_t *s, int status) { s->m_status = status; return atf_no_error(); } void atf_process_status_fini(atf_process_status_t *s ATF_DEFS_ATTRIBUTE_UNUSED) { } bool atf_process_status_exited(const atf_process_status_t *s) { int mutable_status = s->m_status; return WIFEXITED(mutable_status); } int atf_process_status_exitstatus(const atf_process_status_t *s) { PRE(atf_process_status_exited(s)); int mutable_status = s->m_status; return WEXITSTATUS(mutable_status); } bool atf_process_status_signaled(const atf_process_status_t *s) { int mutable_status = s->m_status; return WIFSIGNALED(mutable_status); } int atf_process_status_termsig(const atf_process_status_t *s) { PRE(atf_process_status_signaled(s)); int mutable_status = s->m_status; return WTERMSIG(mutable_status); } bool atf_process_status_coredump(const atf_process_status_t *s) { PRE(atf_process_status_signaled(s)); #if defined(WCOREDUMP) int mutable_status = s->m_status; return WCOREDUMP(mutable_status); #else return false; #endif } /* --------------------------------------------------------------------- * The "atf_process_child" type. * --------------------------------------------------------------------- */ static atf_error_t atf_process_child_init(atf_process_child_t *c) { c->m_pid = 0; c->m_stdout = -1; c->m_stderr = -1; return atf_no_error(); } static void atf_process_child_fini(atf_process_child_t *c) { if (c->m_stdout != -1) close(c->m_stdout); if (c->m_stderr != -1) close(c->m_stderr); } atf_error_t atf_process_child_wait(atf_process_child_t *c, atf_process_status_t *s) { atf_error_t err; int status; if (waitpid(c->m_pid, &status, 0) == -1) err = atf_libc_error(errno, "Failed waiting for process %d", c->m_pid); else { atf_process_child_fini(c); err = atf_process_status_init(s, status); } return err; } pid_t atf_process_child_pid(const atf_process_child_t *c) { return c->m_pid; } int atf_process_child_stdout(atf_process_child_t *c) { PRE(c->m_stdout != -1); return c->m_stdout; } int atf_process_child_stderr(atf_process_child_t *c) { PRE(c->m_stderr != -1); return c->m_stderr; } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ static atf_error_t safe_dup(const int oldfd, const int newfd) { atf_error_t err; if (oldfd != newfd) { if (dup2(oldfd, newfd) == -1) { err = atf_libc_error(errno, "Could not allocate file descriptor"); } else { close(oldfd); err = atf_no_error(); } } else err = atf_no_error(); return err; } static atf_error_t child_connect(const stream_prepare_t *sp, int procfd) { atf_error_t err; const int type = atf_process_stream_type(sp->m_sb); if (type == atf_process_stream_type_capture) { close(sp->m_pipefds[0]); err = safe_dup(sp->m_pipefds[1], procfd); } else if (type == atf_process_stream_type_connect) { if (dup2(sp->m_sb->m_tgt_fd, sp->m_sb->m_src_fd) == -1) err = atf_libc_error(errno, "Cannot connect descriptor %d to %d", sp->m_sb->m_tgt_fd, sp->m_sb->m_src_fd); else err = atf_no_error(); } else if (type == atf_process_stream_type_inherit) { err = atf_no_error(); } else if (type == atf_process_stream_type_redirect_fd) { err = safe_dup(sp->m_sb->m_fd, procfd); } else if (type == atf_process_stream_type_redirect_path) { int aux = open(atf_fs_path_cstring(sp->m_sb->m_path), O_WRONLY | O_CREAT | O_TRUNC, 0644); if (aux == -1) err = atf_libc_error(errno, "Could not create %s", atf_fs_path_cstring(sp->m_sb->m_path)); else { err = safe_dup(aux, procfd); if (atf_is_error(err)) close(aux); } } else { UNREACHABLE; err = atf_no_error(); } return err; } static void parent_connect(const stream_prepare_t *sp, int *fd) { const int type = atf_process_stream_type(sp->m_sb); if (type == atf_process_stream_type_capture) { close(sp->m_pipefds[1]); *fd = sp->m_pipefds[0]; } else if (type == atf_process_stream_type_connect) { /* Do nothing. */ } else if (type == atf_process_stream_type_inherit) { /* Do nothing. */ } else if (type == atf_process_stream_type_redirect_fd) { /* Do nothing. */ } else if (type == atf_process_stream_type_redirect_path) { /* Do nothing. */ } else { UNREACHABLE; } } static atf_error_t do_parent(atf_process_child_t *c, const pid_t pid, const stream_prepare_t *outsp, const stream_prepare_t *errsp) { atf_error_t err; err = atf_process_child_init(c); if (atf_is_error(err)) goto out; c->m_pid = pid; parent_connect(outsp, &c->m_stdout); parent_connect(errsp, &c->m_stderr); out: return err; } static void do_child(void (*)(void *), void *, const stream_prepare_t *, const stream_prepare_t *) ATF_DEFS_ATTRIBUTE_NORETURN; static void do_child(void (*start)(void *), void *v, const stream_prepare_t *outsp, const stream_prepare_t *errsp) { atf_error_t err; err = child_connect(outsp, STDOUT_FILENO); if (atf_is_error(err)) goto out; err = child_connect(errsp, STDERR_FILENO); if (atf_is_error(err)) goto out; start(v); UNREACHABLE; out: if (atf_is_error(err)) { char buf[1024]; atf_error_format(err, buf, sizeof(buf)); fprintf(stderr, "Unhandled error: %s\n", buf); atf_error_free(err); exit(EXIT_FAILURE); } else exit(EXIT_SUCCESS); } static atf_error_t fork_with_streams(atf_process_child_t *c, void (*start)(void *), const atf_process_stream_t *outsb, const atf_process_stream_t *errsb, void *v) { atf_error_t err; stream_prepare_t outsp; stream_prepare_t errsp; pid_t pid; err = stream_prepare_init(&outsp, outsb); if (atf_is_error(err)) goto out; err = stream_prepare_init(&errsp, errsb); if (atf_is_error(err)) goto err_outpipe; pid = fork(); if (pid == -1) { err = atf_libc_error(errno, "Failed to fork"); goto err_errpipe; } if (pid == 0) { do_child(start, v, &outsp, &errsp); UNREACHABLE; abort(); err = atf_no_error(); } else { err = do_parent(c, pid, &outsp, &errsp); if (atf_is_error(err)) goto err_errpipe; } goto out; err_errpipe: stream_prepare_fini(&errsp); err_outpipe: stream_prepare_fini(&outsp); out: return err; } static atf_error_t init_stream_w_default(const atf_process_stream_t *usersb, atf_process_stream_t *inheritsb, const atf_process_stream_t **realsb) { atf_error_t err; if (usersb == NULL) { err = atf_process_stream_init_inherit(inheritsb); if (!atf_is_error(err)) *realsb = inheritsb; } else { err = atf_no_error(); *realsb = usersb; } return err; } atf_error_t atf_process_fork(atf_process_child_t *c, void (*start)(void *), const atf_process_stream_t *outsb, const atf_process_stream_t *errsb, void *v) { atf_error_t err; atf_process_stream_t inherit_outsb, inherit_errsb; const atf_process_stream_t *real_outsb, *real_errsb; real_outsb = NULL; /* Shut up GCC warning. */ err = init_stream_w_default(outsb, &inherit_outsb, &real_outsb); if (atf_is_error(err)) goto out; real_errsb = NULL; /* Shut up GCC warning. */ err = init_stream_w_default(errsb, &inherit_errsb, &real_errsb); if (atf_is_error(err)) goto out_out; err = fork_with_streams(c, start, real_outsb, real_errsb, v); if (errsb == NULL) atf_process_stream_fini(&inherit_errsb); out_out: if (outsb == NULL) atf_process_stream_fini(&inherit_outsb); out: return err; } static int const_execvp(const char *file, const char *const *argv) { #define UNCONST(a) ((void *)(unsigned long)(const void *)(a)) return execvp(file, UNCONST(argv)); #undef UNCONST } static atf_error_t list_to_array(const atf_list_t *l, const char ***ap) { atf_error_t err; const char **a; a = (const char **)malloc((atf_list_size(l) + 1) * sizeof(const char *)); if (a == NULL) err = atf_no_memory_error(); else { const char **aiter; atf_list_citer_t liter; aiter = a; atf_list_for_each_c(liter, l) { *aiter = (const char *)atf_list_citer_data(liter); aiter++; } *aiter = NULL; err = atf_no_error(); *ap = a; } return err; } struct exec_args { const atf_fs_path_t *m_prog; const char *const *m_argv; void (*m_prehook)(void); }; static void do_exec(void *v) { struct exec_args *ea = v; if (ea->m_prehook != NULL) ea->m_prehook(); const int ret = const_execvp(atf_fs_path_cstring(ea->m_prog), ea->m_argv); const int errnocopy = errno; INV(ret == -1); fprintf(stderr, "exec(%s) failed: %s\n", atf_fs_path_cstring(ea->m_prog), strerror(errnocopy)); exit(EXIT_FAILURE); } atf_error_t atf_process_exec_array(atf_process_status_t *s, const atf_fs_path_t *prog, const char *const *argv, const atf_process_stream_t *outsb, const atf_process_stream_t *errsb, void (*prehook)(void)) { atf_error_t err; atf_process_child_t c; struct exec_args ea = { prog, argv, prehook }; PRE(outsb == NULL || atf_process_stream_type(outsb) != atf_process_stream_type_capture); PRE(errsb == NULL || atf_process_stream_type(errsb) != atf_process_stream_type_capture); err = atf_process_fork(&c, do_exec, outsb, errsb, &ea); if (atf_is_error(err)) goto out; again: err = atf_process_child_wait(&c, s); if (atf_is_error(err)) { INV(atf_error_is(err, "libc") && atf_libc_error_code(err) == EINTR); atf_error_free(err); goto again; } out: return err; } atf_error_t atf_process_exec_list(atf_process_status_t *s, const atf_fs_path_t *prog, const atf_list_t *argv, const atf_process_stream_t *outsb, const atf_process_stream_t *errsb, void (*prehook)(void)) { atf_error_t err; const char **argv2; PRE(outsb == NULL || atf_process_stream_type(outsb) != atf_process_stream_type_capture); PRE(errsb == NULL || atf_process_stream_type(errsb) != atf_process_stream_type_capture); argv2 = NULL; /* Silence GCC warning. */ err = list_to_array(argv, &argv2); if (atf_is_error(err)) goto out; err = atf_process_exec_array(s, prog, argv2, outsb, errsb, prehook); free(argv2); out: return err; } Index: head/contrib/atf/atf-c/detail/process.h =================================================================== --- head/contrib/atf/atf-c/detail/process.h (revision 273928) +++ head/contrib/atf/atf-c/detail/process.h (revision 273929) @@ -1,136 +1,131 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_PROCESS_H) -#define ATF_C_PROCESS_H +#if !defined(ATF_C_DETAIL_PROCESS_H) +#define ATF_C_DETAIL_PROCESS_H #include #include +#include +#include #include -#include "fs.h" -#include "list.h" - /* --------------------------------------------------------------------- * The "atf_process_stream" type. * --------------------------------------------------------------------- */ struct atf_process_stream { int m_type; /* Valid if m_type == connect. */ int m_src_fd; int m_tgt_fd; /* Valid if m_type == redirect_fd. */ int m_fd; /* Valid if m_type == redirect_path. */ const atf_fs_path_t *m_path; }; typedef struct atf_process_stream atf_process_stream_t; extern const int atf_process_stream_type_capture; extern const int atf_process_stream_type_connect; extern const int atf_process_stream_type_inherit; extern const int atf_process_stream_type_redirect_fd; extern const int atf_process_stream_type_redirect_path; atf_error_t atf_process_stream_init_capture(atf_process_stream_t *); atf_error_t atf_process_stream_init_connect(atf_process_stream_t *, const int, const int); atf_error_t atf_process_stream_init_inherit(atf_process_stream_t *); atf_error_t atf_process_stream_init_redirect_fd(atf_process_stream_t *, const int fd); atf_error_t atf_process_stream_init_redirect_path(atf_process_stream_t *, const atf_fs_path_t *); void atf_process_stream_fini(atf_process_stream_t *); int atf_process_stream_type(const atf_process_stream_t *); /* --------------------------------------------------------------------- * The "atf_process_status" type. * --------------------------------------------------------------------- */ struct atf_process_status { int m_status; }; typedef struct atf_process_status atf_process_status_t; void atf_process_status_fini(atf_process_status_t *); bool atf_process_status_exited(const atf_process_status_t *); int atf_process_status_exitstatus(const atf_process_status_t *); bool atf_process_status_signaled(const atf_process_status_t *); int atf_process_status_termsig(const atf_process_status_t *); bool atf_process_status_coredump(const atf_process_status_t *); /* --------------------------------------------------------------------- * The "atf_process_child" type. * --------------------------------------------------------------------- */ struct atf_process_child { pid_t m_pid; int m_stdout; int m_stderr; }; typedef struct atf_process_child atf_process_child_t; atf_error_t atf_process_child_wait(atf_process_child_t *, atf_process_status_t *); pid_t atf_process_child_pid(const atf_process_child_t *); int atf_process_child_stdout(atf_process_child_t *); int atf_process_child_stderr(atf_process_child_t *); /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_process_fork(atf_process_child_t *, void (*)(void *), const atf_process_stream_t *, const atf_process_stream_t *, void *); atf_error_t atf_process_exec_array(atf_process_status_t *, const atf_fs_path_t *, const char *const *, const atf_process_stream_t *, const atf_process_stream_t *, void (*)(void)); atf_error_t atf_process_exec_list(atf_process_status_t *, const atf_fs_path_t *, const atf_list_t *, const atf_process_stream_t *, const atf_process_stream_t *, void (*)(void)); -#endif /* !defined(ATF_C_PROCESS_H) */ +#endif /* !defined(ATF_C_DETAIL_PROCESS_H) */ Index: head/contrib/atf/atf-c/detail/process_helpers.c =================================================================== --- head/contrib/atf/atf-c/detail/process_helpers.c (revision 273928) +++ head/contrib/atf/atf-c/detail/process_helpers.c (revision 273929) @@ -1,117 +1,113 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include #include /* NO_CHECK_STYLE */ #include #include #include #include #include static int h_echo(const char *msg) { printf("%s\n", msg); return EXIT_SUCCESS; } static int h_exit_failure(void) { return EXIT_FAILURE; } static int h_exit_signal(void) { kill(getpid(), SIGKILL); assert(0); /* NO_CHECK_STYLE */ return EXIT_FAILURE; } static int h_exit_success(void) { return EXIT_SUCCESS; } static int h_stdout_stderr(const char *id) { fprintf(stdout, "Line 1 to stdout for %s\n", id); fprintf(stdout, "Line 2 to stdout for %s\n", id); fprintf(stderr, "Line 1 to stderr for %s\n", id); fprintf(stderr, "Line 2 to stderr for %s\n", id); return EXIT_SUCCESS; } static void check_args(const int argc, const char *const argv[], const int required) { if (argc < required) { fprintf(stderr, "Usage: %s helper-name [args]\n", argv[0]); exit(EXIT_FAILURE); } } int main(int argc, const char *const argv[]) { int exitcode; check_args(argc, argv, 2); if (strcmp(argv[1], "echo") == 0) { check_args(argc, argv, 3); exitcode = h_echo(argv[2]); } else if (strcmp(argv[1], "exit-failure") == 0) exitcode = h_exit_failure(); else if (strcmp(argv[1], "exit-signal") == 0) exitcode = h_exit_signal(); else if (strcmp(argv[1], "exit-success") == 0) exitcode = h_exit_success(); else if (strcmp(argv[1], "stdout-stderr") == 0) { check_args(argc, argv, 3); exitcode = h_stdout_stderr(argv[2]); } else { fprintf(stderr, "%s: Unknown helper %s\n", argv[0], argv[1]); exitcode = EXIT_FAILURE; } return exitcode; } Index: head/contrib/atf/atf-c/detail/process_test.c =================================================================== --- head/contrib/atf/atf-c/detail/process_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/process_test.c (revision 273929) @@ -1,1163 +1,1159 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/process.h" + #include #include #include #include #include #include #include #include #include #include #include #include #include "atf-c/defs.h" - -#include "process.h" -#include "sanity.h" -#include "test_helpers.h" +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/test_helpers.h" atf_error_t atf_process_status_init(atf_process_status_t *, int); /* --------------------------------------------------------------------- * Auxiliary functions for testing of 'atf_process_fork'. * --------------------------------------------------------------------- */ /* * Testing of atf_process_fork is quite messy. We want to be able to test * all the possible combinations of stdout and stderr behavior to ensure * that the streams are manipulated correctly. * * To do this, the do_fork function is a wrapper for atf_process_fork that * issues stream-specific hooks before fork, while the child is running and * after the child terminates. We then provide test cases that just call * do_fork with different hooks. * * The hooks are described by base_stream, and we then have one *_stream * type for ever possible stream behavior. */ enum out_type { stdout_type, stderr_type }; struct base_stream { void (*init)(void *); void (*process)(void *, atf_process_child_t *); void (*fini)(void *); /* m_sb is initialized by subclasses that need it, but all consumers * must use m_sb_ptr, which may or may not point to m_sb. This allows * us to test the interface with a NULL value, which triggers a * default behavior. */ atf_process_stream_t m_sb; atf_process_stream_t *m_sb_ptr; enum out_type m_type; }; #define BASE_STREAM(ihook, phook, fhook, type) \ { .init = ihook, \ .process = phook, \ .fini = fhook, \ .m_type = type } static void check_file(const enum out_type type) { switch (type) { case stdout_type: ATF_CHECK(atf_utils_grep_file("stdout: msg", "stdout")); ATF_CHECK(!atf_utils_grep_file("stderr: msg", "stdout")); break; case stderr_type: ATF_CHECK(atf_utils_grep_file("stderr: msg", "stderr")); ATF_CHECK(!atf_utils_grep_file("stdout: msg", "stderr")); break; default: UNREACHABLE; } } struct capture_stream { struct base_stream m_base; char *m_msg; }; #define CAPTURE_STREAM(type) \ { .m_base = BASE_STREAM(capture_stream_init, \ capture_stream_process, \ capture_stream_fini, \ type) } static void capture_stream_init(void *v) { struct capture_stream *s = v; s->m_base.m_sb_ptr = &s->m_base.m_sb; RE(atf_process_stream_init_capture(&s->m_base.m_sb)); s->m_msg = NULL; } static void capture_stream_process(void *v, atf_process_child_t *c) { struct capture_stream *s = v; switch (s->m_base.m_type) { case stdout_type: s->m_msg = atf_utils_readline(atf_process_child_stdout(c)); break; case stderr_type: s->m_msg = atf_utils_readline(atf_process_child_stderr(c)); break; default: UNREACHABLE; } } static void capture_stream_fini(void *v) { struct capture_stream *s = v; switch (s->m_base.m_type) { case stdout_type: ATF_CHECK(atf_utils_grep_string("stdout: msg", s->m_msg)); ATF_CHECK(!atf_utils_grep_string("stderr: msg", s->m_msg)); break; case stderr_type: ATF_CHECK(!atf_utils_grep_string("stdout: msg", s->m_msg)); ATF_CHECK(atf_utils_grep_string("stderr: msg", s->m_msg)); break; default: UNREACHABLE; } free(s->m_msg); atf_process_stream_fini(&s->m_base.m_sb); } struct connect_stream { struct base_stream m_base; int m_fd; }; #define CONNECT_STREAM(type) \ { .m_base = BASE_STREAM(connect_stream_init, \ NULL, \ connect_stream_fini, \ type) } static void connect_stream_init(void *v) { struct connect_stream *s = v; int src_fd; switch (s->m_base.m_type) { case stdout_type: src_fd = STDOUT_FILENO; s->m_fd = open("stdout", O_WRONLY | O_CREAT | O_TRUNC, 0644); break; case stderr_type: src_fd = STDERR_FILENO; s->m_fd = open("stderr", O_WRONLY | O_CREAT | O_TRUNC, 0644); break; default: UNREACHABLE; src_fd = -1; } ATF_REQUIRE(s->m_fd != -1); s->m_base.m_sb_ptr = &s->m_base.m_sb; RE(atf_process_stream_init_connect(&s->m_base.m_sb, src_fd, s->m_fd)); } static void connect_stream_fini(void *v) { struct connect_stream *s = v; ATF_REQUIRE(close(s->m_fd) != -1); atf_process_stream_fini(&s->m_base.m_sb); check_file(s->m_base.m_type); } struct inherit_stream { struct base_stream m_base; int m_fd; int m_old_fd; }; #define INHERIT_STREAM(type) \ { .m_base = BASE_STREAM(inherit_stream_init, \ NULL, \ inherit_stream_fini, \ type) } static void inherit_stream_init(void *v) { struct inherit_stream *s = v; const char *name; s->m_base.m_sb_ptr = &s->m_base.m_sb; RE(atf_process_stream_init_inherit(&s->m_base.m_sb)); switch (s->m_base.m_type) { case stdout_type: s->m_fd = STDOUT_FILENO; name = "stdout"; break; case stderr_type: s->m_fd = STDERR_FILENO; name = "stderr"; break; default: UNREACHABLE; name = NULL; } s->m_old_fd = dup(s->m_fd); ATF_REQUIRE(s->m_old_fd != -1); ATF_REQUIRE(close(s->m_fd) != -1); ATF_REQUIRE_EQ(open(name, O_WRONLY | O_CREAT | O_TRUNC, 0644), s->m_fd); } static void inherit_stream_fini(void *v) { struct inherit_stream *s = v; ATF_REQUIRE(dup2(s->m_old_fd, s->m_fd) != -1); ATF_REQUIRE(close(s->m_old_fd) != -1); atf_process_stream_fini(&s->m_base.m_sb); check_file(s->m_base.m_type); } #define default_stream inherit_stream #define DEFAULT_STREAM(type) \ { .m_base = BASE_STREAM(default_stream_init, \ NULL, \ default_stream_fini, \ type) } static void default_stream_init(void *v) { struct inherit_stream *s = v; inherit_stream_init(v); s->m_base.m_sb_ptr = NULL; } static void default_stream_fini(void *v) { inherit_stream_fini(v); } struct redirect_fd_stream { struct base_stream m_base; int m_fd; }; #define REDIRECT_FD_STREAM(type) \ { .m_base = BASE_STREAM(redirect_fd_stream_init, \ NULL, \ redirect_fd_stream_fini, \ type) } static void redirect_fd_stream_init(void *v) { struct redirect_fd_stream *s = v; switch (s->m_base.m_type) { case stdout_type: s->m_fd = open("stdout", O_WRONLY | O_CREAT | O_TRUNC, 0644); break; case stderr_type: s->m_fd = open("stderr", O_WRONLY | O_CREAT | O_TRUNC, 0644); break; default: UNREACHABLE; } ATF_REQUIRE(s->m_fd != -1); s->m_base.m_sb_ptr = &s->m_base.m_sb; RE(atf_process_stream_init_redirect_fd(&s->m_base.m_sb, s->m_fd)); } static void redirect_fd_stream_fini(void *v) { struct redirect_fd_stream *s = v; ATF_REQUIRE(close(s->m_fd) != -1); atf_process_stream_fini(&s->m_base.m_sb); check_file(s->m_base.m_type); } struct redirect_path_stream { struct base_stream m_base; atf_fs_path_t m_path; }; #define REDIRECT_PATH_STREAM(type) \ { .m_base = BASE_STREAM(redirect_path_stream_init, \ NULL, \ redirect_path_stream_fini, \ type) } static void redirect_path_stream_init(void *v) { struct redirect_path_stream *s = v; switch (s->m_base.m_type) { case stdout_type: RE(atf_fs_path_init_fmt(&s->m_path, "stdout")); break; case stderr_type: RE(atf_fs_path_init_fmt(&s->m_path, "stderr")); break; default: UNREACHABLE; } s->m_base.m_sb_ptr = &s->m_base.m_sb; RE(atf_process_stream_init_redirect_path(&s->m_base.m_sb, &s->m_path)); } static void redirect_path_stream_fini(void *v) { struct redirect_path_stream *s = v; atf_process_stream_fini(&s->m_base.m_sb); atf_fs_path_fini(&s->m_path); check_file(s->m_base.m_type); } static void child_print(void *) ATF_DEFS_ATTRIBUTE_NORETURN; struct child_print_data { const char *m_msg; }; static void child_print(void *v) { struct child_print_data *cpd = v; fprintf(stdout, "stdout: %s\n", cpd->m_msg); fprintf(stderr, "stderr: %s\n", cpd->m_msg); exit(EXIT_SUCCESS); } static void do_fork(const struct base_stream *outfs, void *out, const struct base_stream *errfs, void *err) { atf_process_child_t child; atf_process_status_t status; struct child_print_data cpd = { "msg" }; outfs->init(out); errfs->init(err); RE(atf_process_fork(&child, child_print, outfs->m_sb_ptr, errfs->m_sb_ptr, &cpd)); if (outfs->process != NULL) outfs->process(out, &child); if (errfs->process != NULL) errfs->process(err, &child); RE(atf_process_child_wait(&child, &status)); outfs->fini(out); errfs->fini(err); atf_process_status_fini(&status); } /* --------------------------------------------------------------------- * Test cases for the "stream" type. * --------------------------------------------------------------------- */ ATF_TC(stream_init_capture); ATF_TC_HEAD(stream_init_capture, tc) { atf_tc_set_md_var(tc, "descr", "Tests the " "atf_process_stream_init_capture function"); } ATF_TC_BODY(stream_init_capture, tc) { atf_process_stream_t sb; RE(atf_process_stream_init_capture(&sb)); ATF_CHECK_EQ(atf_process_stream_type(&sb), atf_process_stream_type_capture); atf_process_stream_fini(&sb); } ATF_TC(stream_init_connect); ATF_TC_HEAD(stream_init_connect, tc) { atf_tc_set_md_var(tc, "descr", "Tests the " "atf_process_stream_init_connect function"); } ATF_TC_BODY(stream_init_connect, tc) { atf_process_stream_t sb; RE(atf_process_stream_init_connect(&sb, 1, 2)); ATF_CHECK_EQ(atf_process_stream_type(&sb), atf_process_stream_type_connect); atf_process_stream_fini(&sb); } ATF_TC(stream_init_inherit); ATF_TC_HEAD(stream_init_inherit, tc) { atf_tc_set_md_var(tc, "descr", "Tests the " "atf_process_stream_init_inherit function"); } ATF_TC_BODY(stream_init_inherit, tc) { atf_process_stream_t sb; RE(atf_process_stream_init_inherit(&sb)); ATF_CHECK_EQ(atf_process_stream_type(&sb), atf_process_stream_type_inherit); atf_process_stream_fini(&sb); } ATF_TC(stream_init_redirect_fd); ATF_TC_HEAD(stream_init_redirect_fd, tc) { atf_tc_set_md_var(tc, "descr", "Tests the " "atf_process_stream_init_redirect_fd function"); } ATF_TC_BODY(stream_init_redirect_fd, tc) { atf_process_stream_t sb; RE(atf_process_stream_init_redirect_fd(&sb, 1)); ATF_CHECK_EQ(atf_process_stream_type(&sb), atf_process_stream_type_redirect_fd); atf_process_stream_fini(&sb); } ATF_TC(stream_init_redirect_path); ATF_TC_HEAD(stream_init_redirect_path, tc) { atf_tc_set_md_var(tc, "descr", "Tests the " "atf_process_stream_init_redirect_path function"); } ATF_TC_BODY(stream_init_redirect_path, tc) { atf_process_stream_t sb; atf_fs_path_t path; RE(atf_fs_path_init_fmt(&path, "foo")); RE(atf_process_stream_init_redirect_path(&sb, &path)); ATF_CHECK_EQ(atf_process_stream_type(&sb), atf_process_stream_type_redirect_path); atf_process_stream_fini(&sb); atf_fs_path_fini(&path); } /* --------------------------------------------------------------------- * Test cases for the "status" type. * --------------------------------------------------------------------- */ static void child_exit_success(void) ATF_DEFS_ATTRIBUTE_NORETURN; static void child_exit_failure(void) ATF_DEFS_ATTRIBUTE_NORETURN; static void child_sigkill(void) ATF_DEFS_ATTRIBUTE_NORETURN; static void child_sigquit(void) ATF_DEFS_ATTRIBUTE_NORETURN; static void child_sigterm(void) ATF_DEFS_ATTRIBUTE_NORETURN; void child_exit_success(void) { exit(EXIT_SUCCESS); } void child_exit_failure(void) { exit(EXIT_FAILURE); } void child_sigkill(void) { kill(getpid(), SIGKILL); abort(); } void child_sigquit(void) { kill(getpid(), SIGQUIT); abort(); } void child_sigterm(void) { kill(getpid(), SIGTERM); abort(); } static int fork_and_wait_child(void (*child_func)(void)) { pid_t pid; int status; pid = fork(); ATF_REQUIRE(pid != -1); if (pid == 0) { status = 0; /* Silence compiler warnings */ child_func(); UNREACHABLE; } else { ATF_REQUIRE(waitpid(pid, &status, 0) != 0); } return status; } ATF_TC(status_exited); ATF_TC_HEAD(status_exited, tc) { atf_tc_set_md_var(tc, "descr", "Tests the status type for processes " "that exit cleanly"); } ATF_TC_BODY(status_exited, tc) { { const int rawstatus = fork_and_wait_child(child_exit_success); atf_process_status_t s; RE(atf_process_status_init(&s, rawstatus)); ATF_CHECK(atf_process_status_exited(&s)); ATF_CHECK_EQ(atf_process_status_exitstatus(&s), EXIT_SUCCESS); ATF_CHECK(!atf_process_status_signaled(&s)); atf_process_status_fini(&s); } { const int rawstatus = fork_and_wait_child(child_exit_failure); atf_process_status_t s; RE(atf_process_status_init(&s, rawstatus)); ATF_CHECK(atf_process_status_exited(&s)); ATF_CHECK_EQ(atf_process_status_exitstatus(&s), EXIT_FAILURE); ATF_CHECK(!atf_process_status_signaled(&s)); atf_process_status_fini(&s); } } ATF_TC(status_signaled); ATF_TC_HEAD(status_signaled, tc) { atf_tc_set_md_var(tc, "descr", "Tests the status type for processes " "that end due to a signal"); } ATF_TC_BODY(status_signaled, tc) { { const int rawstatus = fork_and_wait_child(child_sigkill); atf_process_status_t s; RE(atf_process_status_init(&s, rawstatus)); ATF_CHECK(!atf_process_status_exited(&s)); ATF_CHECK(atf_process_status_signaled(&s)); ATF_CHECK_EQ(atf_process_status_termsig(&s), SIGKILL); ATF_CHECK(!atf_process_status_coredump(&s)); atf_process_status_fini(&s); } { const int rawstatus = fork_and_wait_child(child_sigterm); atf_process_status_t s; RE(atf_process_status_init(&s, rawstatus)); ATF_CHECK(!atf_process_status_exited(&s)); ATF_CHECK(atf_process_status_signaled(&s)); ATF_CHECK_EQ(atf_process_status_termsig(&s), SIGTERM); ATF_CHECK(!atf_process_status_coredump(&s)); atf_process_status_fini(&s); } } ATF_TC(status_coredump); ATF_TC_HEAD(status_coredump, tc) { atf_tc_set_md_var(tc, "descr", "Tests the status type for processes " "that crash"); } ATF_TC_BODY(status_coredump, tc) { struct rlimit rl; rl.rlim_cur = RLIM_INFINITY; rl.rlim_max = RLIM_INFINITY; if (setrlimit(RLIMIT_CORE, &rl) == -1) atf_tc_skip("Cannot unlimit the core file size; check limits " "manually"); const int rawstatus = fork_and_wait_child(child_sigquit); atf_process_status_t s; RE(atf_process_status_init(&s, rawstatus)); ATF_CHECK(!atf_process_status_exited(&s)); ATF_CHECK(atf_process_status_signaled(&s)); ATF_CHECK_EQ(atf_process_status_termsig(&s), SIGQUIT); ATF_CHECK(atf_process_status_coredump(&s)); atf_process_status_fini(&s); } /* --------------------------------------------------------------------- * Test cases for the "child" type. * --------------------------------------------------------------------- */ static void child_report_pid(void *) ATF_DEFS_ATTRIBUTE_NORETURN; static void child_report_pid(void *v ATF_DEFS_ATTRIBUTE_UNUSED) { const pid_t pid = getpid(); if (write(STDOUT_FILENO, &pid, sizeof(pid)) != sizeof(pid)) abort(); fprintf(stderr, "Reporting %d to parent\n", (int)getpid()); exit(EXIT_SUCCESS); } ATF_TC(child_pid); ATF_TC_HEAD(child_pid, tc) { atf_tc_set_md_var(tc, "descr", "Tests the correctness of the pid " "stored in the child type"); } ATF_TC_BODY(child_pid, tc) { atf_process_stream_t outsb, errsb; atf_process_child_t child; atf_process_status_t status; pid_t pid; RE(atf_process_stream_init_capture(&outsb)); RE(atf_process_stream_init_inherit(&errsb)); RE(atf_process_fork(&child, child_report_pid, &outsb, &errsb, NULL)); ATF_CHECK_EQ(read(atf_process_child_stdout(&child), &pid, sizeof(pid)), sizeof(pid)); printf("Expected PID: %d\n", (int)atf_process_child_pid(&child)); printf("Actual PID: %d\n", (int)pid); ATF_CHECK_EQ(atf_process_child_pid(&child), pid); RE(atf_process_child_wait(&child, &status)); atf_process_status_fini(&status); atf_process_stream_fini(&outsb); atf_process_stream_fini(&errsb); } static void child_loop(void *v ATF_DEFS_ATTRIBUTE_UNUSED) { for (;;) sleep(1); } static void nop_signal(int sig ATF_DEFS_ATTRIBUTE_UNUSED) { } static void child_spawn_loop_and_wait_eintr(void *v ATF_DEFS_ATTRIBUTE_UNUSED) { atf_process_child_t child; atf_process_status_t status; struct sigaction sighup, old_sighup; #define RE_ABORT(expr) \ do { \ atf_error_t _aux_err = expr; \ if (atf_is_error(_aux_err)) { \ atf_error_free(_aux_err); \ abort(); \ } \ } while (0) { atf_process_stream_t outsb, errsb; RE_ABORT(atf_process_stream_init_capture(&outsb)); RE_ABORT(atf_process_stream_init_inherit(&errsb)); RE_ABORT(atf_process_fork(&child, child_loop, &outsb, &errsb, NULL)); atf_process_stream_fini(&outsb); atf_process_stream_fini(&errsb); } sighup.sa_handler = nop_signal; sigemptyset(&sighup.sa_mask); sighup.sa_flags = 0; if (sigaction(SIGHUP, &sighup, &old_sighup) == -1) abort(); printf("waiting\n"); fflush(stdout); fprintf(stderr, "Child entering wait(2)\n"); atf_error_t err = atf_process_child_wait(&child, &status); fprintf(stderr, "Child's wait(2) terminated\n"); if (!atf_is_error(err)) { fprintf(stderr, "wait completed successfully (not interrupted)\n"); abort(); } if (!atf_error_is(err, "libc")) { fprintf(stderr, "wait did not raise libc_error\n"); abort(); } if (atf_libc_error_code(err) != EINTR) { fprintf(stderr, "libc_error is not EINTR\n"); abort(); } atf_error_free(err); sigaction(SIGHUP, &old_sighup, NULL); fprintf(stderr, "Child is killing subchild\n"); kill(atf_process_child_pid(&child), SIGTERM); RE_ABORT(atf_process_child_wait(&child, &status)); atf_process_status_fini(&status); #undef RE_ABORT exit(EXIT_SUCCESS); } ATF_TC(child_wait_eintr); ATF_TC_HEAD(child_wait_eintr, tc) { atf_tc_set_md_var(tc, "descr", "Tests the interruption of the wait " "method by an external signal, and the return of " "an EINTR error"); atf_tc_set_md_var(tc, "timeout", "30"); } ATF_TC_BODY(child_wait_eintr, tc) { atf_process_child_t child; atf_process_status_t status; { atf_process_stream_t outsb, errsb; RE(atf_process_stream_init_capture(&outsb)); RE(atf_process_stream_init_inherit(&errsb)); RE(atf_process_fork(&child, child_spawn_loop_and_wait_eintr, &outsb, &errsb, NULL)); atf_process_stream_fini(&outsb); atf_process_stream_fini(&errsb); } { /* Wait until the child process performs the wait call. This is * racy, because the message we get from it is sent *before* * doing the real system call... but I can't figure any other way * to do this. */ char buf[16]; printf("Waiting for child to issue wait(2)\n"); ATF_REQUIRE(read(atf_process_child_stdout(&child), buf, sizeof(buf)) > 0); sleep(1); } printf("Interrupting child's wait(2) call\n"); kill(atf_process_child_pid(&child), SIGHUP); printf("Waiting for child's completion\n"); RE(atf_process_child_wait(&child, &status)); ATF_REQUIRE(atf_process_status_exited(&status)); ATF_REQUIRE_EQ(atf_process_status_exitstatus(&status), EXIT_SUCCESS); atf_process_status_fini(&status); } /* --------------------------------------------------------------------- * Tests cases for the free functions. * --------------------------------------------------------------------- */ static void do_exec(const atf_tc_t *tc, const char *helper_name, atf_process_status_t *s, void (*prehook)(void)) { atf_fs_path_t process_helpers; const char *argv[3]; get_process_helpers_path(tc, true, &process_helpers); argv[0] = atf_fs_path_cstring(&process_helpers); argv[1] = helper_name; argv[2] = NULL; printf("Executing %s %s\n", argv[0], argv[1]); RE(atf_process_exec_array(s, &process_helpers, argv, NULL, NULL, prehook)); atf_fs_path_fini(&process_helpers); } static void check_line(int fd, const char *exp) { char *line = atf_utils_readline(fd); ATF_CHECK(line != NULL); ATF_CHECK_STREQ_MSG(exp, line, "read: '%s', expected: '%s'", line, exp); free(line); } ATF_TC(exec_failure); ATF_TC_HEAD(exec_failure, tc) { atf_tc_set_md_var(tc, "descr", "Tests execing a command"); } ATF_TC_BODY(exec_failure, tc) { atf_process_status_t status; do_exec(tc, "exit-failure", &status, NULL); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), EXIT_FAILURE); atf_process_status_fini(&status); } ATF_TC(exec_list); ATF_TC_HEAD(exec_list, tc) { atf_tc_set_md_var(tc, "descr", "Tests execing a command"); } ATF_TC_BODY(exec_list, tc) { atf_fs_path_t process_helpers; atf_list_t argv; atf_process_status_t status; RE(atf_list_init(&argv)); get_process_helpers_path(tc, true, &process_helpers); atf_list_append(&argv, strdup(atf_fs_path_cstring(&process_helpers)), true); atf_list_append(&argv, strdup("echo"), true); atf_list_append(&argv, strdup("test-message"), true); { atf_fs_path_t outpath; atf_process_stream_t outsb; RE(atf_fs_path_init_fmt(&outpath, "stdout")); RE(atf_process_stream_init_redirect_path(&outsb, &outpath)); RE(atf_process_exec_list(&status, &process_helpers, &argv, &outsb, NULL, NULL)); atf_process_stream_fini(&outsb); atf_fs_path_fini(&outpath); } atf_list_fini(&argv); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), EXIT_SUCCESS); { int fd = open("stdout", O_RDONLY); ATF_CHECK(fd != -1); check_line(fd, "test-message"); close(fd); } atf_process_status_fini(&status); atf_fs_path_fini(&process_helpers); } static void exit_early(void) { exit(80); } ATF_TC(exec_prehook); ATF_TC_HEAD(exec_prehook, tc) { atf_tc_set_md_var(tc, "descr", "Tests execing a command with a prehook"); } ATF_TC_BODY(exec_prehook, tc) { atf_process_status_t status; do_exec(tc, "exit-success", &status, exit_early); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), 80); atf_process_status_fini(&status); } ATF_TC(exec_success); ATF_TC_HEAD(exec_success, tc) { atf_tc_set_md_var(tc, "descr", "Tests execing a command"); } ATF_TC_BODY(exec_success, tc) { atf_process_status_t status; do_exec(tc, "exit-success", &status, NULL); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), EXIT_SUCCESS); atf_process_status_fini(&status); } static const int exit_v_null = 1; static const int exit_v_notnull = 2; static void child_cookie(void *v) { if (v == NULL) exit(exit_v_null); else exit(exit_v_notnull); UNREACHABLE; } ATF_TC(fork_cookie); ATF_TC_HEAD(fork_cookie, tc) { atf_tc_set_md_var(tc, "descr", "Tests forking a child, with " "a null and non-null data cookie"); } ATF_TC_BODY(fork_cookie, tc) { atf_process_stream_t outsb, errsb; RE(atf_process_stream_init_inherit(&outsb)); RE(atf_process_stream_init_inherit(&errsb)); { atf_process_child_t child; atf_process_status_t status; RE(atf_process_fork(&child, child_cookie, &outsb, &errsb, NULL)); RE(atf_process_child_wait(&child, &status)); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), exit_v_null); atf_process_status_fini(&status); } { atf_process_child_t child; atf_process_status_t status; int dummy_int; RE(atf_process_fork(&child, child_cookie, &outsb, &errsb, &dummy_int)); RE(atf_process_child_wait(&child, &status)); ATF_CHECK(atf_process_status_exited(&status)); ATF_CHECK_EQ(atf_process_status_exitstatus(&status), exit_v_notnull); atf_process_status_fini(&status); } atf_process_stream_fini(&errsb); atf_process_stream_fini(&outsb); } #define TC_FORK_STREAMS(outlc, outuc, errlc, erruc) \ ATF_TC(fork_out_ ## outlc ## _err_ ## errlc); \ ATF_TC_HEAD(fork_out_ ## outlc ## _err_ ## errlc, tc) \ { \ atf_tc_set_md_var(tc, "descr", "Tests forking a child, with " \ "stdout " #outlc " and stderr " #errlc); \ } \ ATF_TC_BODY(fork_out_ ## outlc ## _err_ ## errlc, tc) \ { \ struct outlc ## _stream out = outuc ## _STREAM(stdout_type); \ struct errlc ## _stream err = erruc ## _STREAM(stderr_type); \ do_fork(&out.m_base, &out, &err.m_base, &err); \ } TC_FORK_STREAMS(capture, CAPTURE, capture, CAPTURE); TC_FORK_STREAMS(capture, CAPTURE, connect, CONNECT); TC_FORK_STREAMS(capture, CAPTURE, default, DEFAULT); TC_FORK_STREAMS(capture, CAPTURE, inherit, INHERIT); TC_FORK_STREAMS(capture, CAPTURE, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(capture, CAPTURE, redirect_path, REDIRECT_PATH); TC_FORK_STREAMS(connect, CONNECT, capture, CAPTURE); TC_FORK_STREAMS(connect, CONNECT, connect, CONNECT); TC_FORK_STREAMS(connect, CONNECT, default, DEFAULT); TC_FORK_STREAMS(connect, CONNECT, inherit, INHERIT); TC_FORK_STREAMS(connect, CONNECT, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(connect, CONNECT, redirect_path, REDIRECT_PATH); TC_FORK_STREAMS(default, DEFAULT, capture, CAPTURE); TC_FORK_STREAMS(default, DEFAULT, connect, CONNECT); TC_FORK_STREAMS(default, DEFAULT, default, DEFAULT); TC_FORK_STREAMS(default, DEFAULT, inherit, INHERIT); TC_FORK_STREAMS(default, DEFAULT, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(default, DEFAULT, redirect_path, REDIRECT_PATH); TC_FORK_STREAMS(inherit, INHERIT, capture, CAPTURE); TC_FORK_STREAMS(inherit, INHERIT, connect, CONNECT); TC_FORK_STREAMS(inherit, INHERIT, default, DEFAULT); TC_FORK_STREAMS(inherit, INHERIT, inherit, INHERIT); TC_FORK_STREAMS(inherit, INHERIT, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(inherit, INHERIT, redirect_path, REDIRECT_PATH); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, capture, CAPTURE); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, connect, CONNECT); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, default, DEFAULT); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, inherit, INHERIT); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(redirect_fd, REDIRECT_FD, redirect_path, REDIRECT_PATH); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, capture, CAPTURE); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, connect, CONNECT); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, default, DEFAULT); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, inherit, INHERIT); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, redirect_fd, REDIRECT_FD); TC_FORK_STREAMS(redirect_path, REDIRECT_PATH, redirect_path, REDIRECT_PATH); #undef TC_FORK_STREAMS /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the tests for the "stream" type. */ ATF_TP_ADD_TC(tp, stream_init_capture); ATF_TP_ADD_TC(tp, stream_init_connect); ATF_TP_ADD_TC(tp, stream_init_inherit); ATF_TP_ADD_TC(tp, stream_init_redirect_fd); ATF_TP_ADD_TC(tp, stream_init_redirect_path); /* Add the tests for the "status" type. */ ATF_TP_ADD_TC(tp, status_exited); ATF_TP_ADD_TC(tp, status_signaled); ATF_TP_ADD_TC(tp, status_coredump); /* Add the tests for the "child" type. */ ATF_TP_ADD_TC(tp, child_pid); ATF_TP_ADD_TC(tp, child_wait_eintr); /* Add the tests for the free functions. */ ATF_TP_ADD_TC(tp, exec_failure); ATF_TP_ADD_TC(tp, exec_list); ATF_TP_ADD_TC(tp, exec_prehook); ATF_TP_ADD_TC(tp, exec_success); ATF_TP_ADD_TC(tp, fork_cookie); ATF_TP_ADD_TC(tp, fork_out_capture_err_capture); ATF_TP_ADD_TC(tp, fork_out_capture_err_connect); ATF_TP_ADD_TC(tp, fork_out_capture_err_default); ATF_TP_ADD_TC(tp, fork_out_capture_err_inherit); ATF_TP_ADD_TC(tp, fork_out_capture_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_capture_err_redirect_path); ATF_TP_ADD_TC(tp, fork_out_connect_err_capture); ATF_TP_ADD_TC(tp, fork_out_connect_err_connect); ATF_TP_ADD_TC(tp, fork_out_connect_err_default); ATF_TP_ADD_TC(tp, fork_out_connect_err_inherit); ATF_TP_ADD_TC(tp, fork_out_connect_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_connect_err_redirect_path); ATF_TP_ADD_TC(tp, fork_out_default_err_capture); ATF_TP_ADD_TC(tp, fork_out_default_err_connect); ATF_TP_ADD_TC(tp, fork_out_default_err_default); ATF_TP_ADD_TC(tp, fork_out_default_err_inherit); ATF_TP_ADD_TC(tp, fork_out_default_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_default_err_redirect_path); ATF_TP_ADD_TC(tp, fork_out_inherit_err_capture); ATF_TP_ADD_TC(tp, fork_out_inherit_err_connect); ATF_TP_ADD_TC(tp, fork_out_inherit_err_default); ATF_TP_ADD_TC(tp, fork_out_inherit_err_inherit); ATF_TP_ADD_TC(tp, fork_out_inherit_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_inherit_err_redirect_path); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_capture); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_connect); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_default); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_inherit); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_redirect_fd_err_redirect_path); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_capture); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_connect); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_default); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_inherit); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_redirect_fd); ATF_TP_ADD_TC(tp, fork_out_redirect_path_err_redirect_path); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/sanity.c =================================================================== --- head/contrib/atf/atf-c/detail/sanity.c (revision 273928) +++ head/contrib/atf/atf-c/detail/sanity.c (revision 273929) @@ -1,78 +1,74 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/sanity.h" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include #include #include -#include "sanity.h" - static void fail(const char *fmt, ...) { va_list ap; char buf[4096]; va_start(ap, fmt); vsnprintf(buf, sizeof(buf), fmt, ap); va_end(ap); warnx("%s", buf); warnx("%s", ""); warnx("This is probably a bug in this application or one of the " "libraries it uses. If you believe this problem is caused " "by, or is related to " PACKAGE_STRING ", please report it " - "to " PACKAGE_BUGREPORT " and provide as many detatils as " + "to " PACKAGE_BUGREPORT " and provide as many details as " "possible describing how you got to this condition."); abort(); } void atf_sanity_inv(const char *file, int line, const char *cond) { fail("Invariant check failed at %s:%d: %s", file, line, cond); } void atf_sanity_pre(const char *file, int line, const char *cond) { fail("Precondition check failed at %s:%d: %s", file, line, cond); } void atf_sanity_post(const char *file, int line, const char *cond) { fail("Postcondition check failed at %s:%d: %s", file, line, cond); } Index: head/contrib/atf/atf-c/detail/sanity.h =================================================================== --- head/contrib/atf/atf-c/detail/sanity.h (revision 273928) +++ head/contrib/atf/atf-c/detail/sanity.h (revision 273929) @@ -1,73 +1,69 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_SANITY_H) -#define ATF_C_SANITY_H +#if !defined(ATF_C_DETAIL_SANITY_H) +#define ATF_C_DETAIL_SANITY_H void atf_sanity_inv(const char *, int, const char *); void atf_sanity_pre(const char *, int, const char *); void atf_sanity_post(const char *, int, const char *); #if !defined(NDEBUG) #define INV(x) \ do { \ if (!(x)) \ atf_sanity_inv(__FILE__, __LINE__, #x); \ } while (0) #define PRE(x) \ do { \ if (!(x)) \ atf_sanity_pre(__FILE__, __LINE__, #x); \ } while (0) #define POST(x) \ do { \ if (!(x)) \ atf_sanity_post(__FILE__, __LINE__, #x); \ } while (0) #else /* defined(NDEBUG) */ #define INV(x) \ do { \ } while (0) #define PRE(x) \ do { \ } while (0) #define POST(x) \ do { \ } while (0) #endif /* !defined(NDEBUG) */ #define UNREACHABLE INV(0) -#endif /* ATF_C_SANITY_H */ +#endif /* !defined(ATF_C_DETAIL_SANITY_H) */ Index: head/contrib/atf/atf-c/detail/sanity_test.c =================================================================== --- head/contrib/atf/atf-c/detail/sanity_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/sanity_test.c (revision 273929) @@ -1,233 +1,230 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/sanity.h" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include #include #include #include #include #include #include -#include "dynstr.h" -#include "process.h" -#include "sanity.h" -#include "test_helpers.h" +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/process.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ enum type { inv, pre, post, unreachable }; struct test_data { enum type m_type; bool m_cond; }; static void do_test_child(void *) ATF_DEFS_ATTRIBUTE_NORETURN; static void do_test_child(void *v) { struct test_data *td = v; switch (td->m_type) { case inv: INV(td->m_cond); break; case pre: PRE(td->m_cond); break; case post: POST(td->m_cond); break; case unreachable: if (!td->m_cond) UNREACHABLE; break; } exit(EXIT_SUCCESS); } static void do_test(enum type t, bool cond) { atf_process_child_t child; atf_process_status_t status; int nlines; char *lines[3]; { atf_process_stream_t outsb, errsb; struct test_data td = { t, cond }; RE(atf_process_stream_init_inherit(&outsb)); RE(atf_process_stream_init_capture(&errsb)); RE(atf_process_fork(&child, do_test_child, &outsb, &errsb, &td)); atf_process_stream_fini(&errsb); atf_process_stream_fini(&outsb); } nlines = 0; while (nlines < 3 && (lines[nlines] = atf_utils_readline(atf_process_child_stderr(&child))) != NULL) nlines++; ATF_REQUIRE(nlines == 0 || nlines == 3); RE(atf_process_child_wait(&child, &status)); if (!cond) { ATF_REQUIRE(atf_process_status_signaled(&status)); ATF_REQUIRE(atf_process_status_termsig(&status) == SIGABRT); } else { ATF_REQUIRE(atf_process_status_exited(&status)); ATF_REQUIRE(atf_process_status_exitstatus(&status) == EXIT_SUCCESS); } atf_process_status_fini(&status); if (!cond) { switch (t) { case inv: ATF_REQUIRE(atf_utils_grep_string("Invariant", lines[0])); break; case pre: ATF_REQUIRE(atf_utils_grep_string("Precondition", lines[0])); break; case post: ATF_REQUIRE(atf_utils_grep_string("Postcondition", lines[0])); break; case unreachable: ATF_REQUIRE(atf_utils_grep_string("Invariant", lines[0])); break; } ATF_REQUIRE(atf_utils_grep_string(__FILE__, lines[0])); ATF_REQUIRE(atf_utils_grep_string(PACKAGE_BUGREPORT, lines[2])); } while (nlines > 0) { nlines--; free(lines[nlines]); } } static void require_ndebug(void) { #if defined(NDEBUG) atf_tc_skip("Sanity checks not available; code built with -DNDEBUG"); #endif } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(inv); ATF_TC_HEAD(inv, tc) { atf_tc_set_md_var(tc, "descr", "Tests the INV macro"); } ATF_TC_BODY(inv, tc) { require_ndebug(); do_test(inv, false); do_test(inv, true); } ATF_TC(pre); ATF_TC_HEAD(pre, tc) { atf_tc_set_md_var(tc, "descr", "Tests the PRE macro"); } ATF_TC_BODY(pre, tc) { require_ndebug(); do_test(pre, false); do_test(pre, true); } ATF_TC(post); ATF_TC_HEAD(post, tc) { atf_tc_set_md_var(tc, "descr", "Tests the POST macro"); } ATF_TC_BODY(post, tc) { require_ndebug(); do_test(post, false); do_test(post, true); } ATF_TC(unreachable); ATF_TC_HEAD(unreachable, tc) { atf_tc_set_md_var(tc, "descr", "Tests the UNREACHABLE macro"); } ATF_TC_BODY(unreachable, tc) { require_ndebug(); do_test(unreachable, false); do_test(unreachable, true); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, inv); ATF_TP_ADD_TC(tp, pre); ATF_TP_ADD_TC(tp, post); ATF_TP_ADD_TC(tp, unreachable); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/test_helpers.c =================================================================== --- head/contrib/atf/atf-c/detail/test_helpers.c (revision 273928) +++ head/contrib/atf/atf-c/detail/test_helpers.c (revision 273929) @@ -1,149 +1,147 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/test_helpers.h" + #include #include #include #include +#include + #include "atf-c/build.h" #include "atf-c/check.h" -#include "atf-c/config.h" +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/process.h" #include "atf-c/error.h" -#include "atf-c/macros.h" -#include "dynstr.h" -#include "fs.h" -#include "process.h" -#include "test_helpers.h" - bool build_check_c_o(const char *path) { bool success; atf_dynstr_t iflag; const char *optargs[4]; - RE(atf_dynstr_init_fmt(&iflag, "-I%s", atf_config_get("atf_includedir"))); + RE(atf_dynstr_init_fmt(&iflag, "-I%s", atf_env_get_with_default( + "ATF_INCLUDEDIR", ATF_INCLUDEDIR))); optargs[0] = atf_dynstr_cstring(&iflag); optargs[1] = "-Wall"; optargs[2] = "-Werror"; optargs[3] = NULL; RE(atf_check_build_c_o(path, "test.o", optargs, &success)); atf_dynstr_fini(&iflag); return success; } bool build_check_c_o_srcdir(const atf_tc_t *tc, const char *sfile) { atf_fs_path_t path; RE(atf_fs_path_init_fmt(&path, "%s/%s", atf_tc_get_config_var(tc, "srcdir"), sfile)); const bool result = build_check_c_o(atf_fs_path_cstring(&path)); atf_fs_path_fini(&path); return result; } void header_check(const char *hdrname) { FILE *srcfile; char failmsg[128]; srcfile = fopen("test.c", "w"); ATF_REQUIRE(srcfile != NULL); fprintf(srcfile, "#include <%s>\n", hdrname); fclose(srcfile); snprintf(failmsg, sizeof(failmsg), "Header check failed; %s is not self-contained", hdrname); if (!build_check_c_o("test.c")) atf_tc_fail("%s", failmsg); } void get_process_helpers_path(const atf_tc_t *tc, const bool is_detail, atf_fs_path_t *path) { RE(atf_fs_path_init_fmt(path, "%s/%sprocess_helpers", atf_tc_get_config_var(tc, "srcdir"), is_detail ? "" : "detail/")); } struct run_h_tc_data { atf_tc_t *m_tc; const char *m_resname; }; static void run_h_tc_child(void *v) { struct run_h_tc_data *data = (struct run_h_tc_data *)v; RE(atf_tc_run(data->m_tc, data->m_resname)); } /* TODO: Investigate if it's worth to add this functionality as part of * the public API. I.e. a function to easily run a test case body in a * subprocess. */ void run_h_tc(atf_tc_t *tc, const char *outname, const char *errname, const char *resname) { atf_fs_path_t outpath, errpath; atf_process_stream_t outb, errb; atf_process_child_t child; atf_process_status_t status; RE(atf_fs_path_init_fmt(&outpath, outname)); RE(atf_fs_path_init_fmt(&errpath, errname)); struct run_h_tc_data data = { tc, resname }; RE(atf_process_stream_init_redirect_path(&outb, &outpath)); RE(atf_process_stream_init_redirect_path(&errb, &errpath)); RE(atf_process_fork(&child, run_h_tc_child, &outb, &errb, &data)); atf_process_stream_fini(&errb); atf_process_stream_fini(&outb); RE(atf_process_child_wait(&child, &status)); ATF_CHECK(atf_process_status_exited(&status)); atf_process_status_fini(&status); atf_fs_path_fini(&errpath); atf_fs_path_fini(&outpath); } Index: head/contrib/atf/atf-c/detail/test_helpers.h =================================================================== --- head/contrib/atf/atf-c/detail/test_helpers.h (revision 273928) +++ head/contrib/atf/atf-c/detail/test_helpers.h (revision 273929) @@ -1,76 +1,75 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if defined(TESTS_ATF_ATF_C_TEST_HELPERS_H) +#if defined(ATF_C_DETAIL_TEST_HELPERS_H) # error "Cannot include test_helpers.h more than once." #else -# define TESTS_ATF_ATF_C_TEST_HELPERS_H +# define ATF_C_DETAIL_TEST_HELPERS_H #endif #include -#include "atf-c/error_fwd.h" +#include + +#include +#include struct atf_dynstr; struct atf_fs_path; #define CE(stm) ATF_CHECK(!atf_is_error(stm)) #define RE(stm) ATF_REQUIRE(!atf_is_error(stm)) #define HEADER_TC(name, hdrname) \ ATF_TC(name); \ ATF_TC_HEAD(name, tc) \ { \ atf_tc_set_md_var(tc, "descr", "Tests that the " hdrname " file can " \ "be included on its own, without any prerequisites"); \ } \ ATF_TC_BODY(name, tc) \ { \ header_check(hdrname); \ } #define BUILD_TC(name, sfile, descr, failmsg) \ ATF_TC(name); \ ATF_TC_HEAD(name, tc) \ { \ atf_tc_set_md_var(tc, "descr", descr); \ } \ ATF_TC_BODY(name, tc) \ { \ if (!build_check_c_o_srcdir(tc, sfile)) \ atf_tc_fail("%s", failmsg); \ } bool build_check_c_o(const char *); bool build_check_c_o_srcdir(const atf_tc_t *, const char *); void header_check(const char *); void get_process_helpers_path(const atf_tc_t *, const bool, struct atf_fs_path *); bool read_line(int, struct atf_dynstr *); void run_h_tc(atf_tc_t *, const char *, const char *, const char *); Index: head/contrib/atf/atf-c/detail/text.c =================================================================== --- head/contrib/atf/atf-c/detail/text.c (revision 273928) +++ head/contrib/atf/atf-c/detail/text.c (revision 273929) @@ -1,184 +1,180 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/text.h" + #include #include #include #include +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" - -#include "dynstr.h" -#include "sanity.h" -#include "text.h" atf_error_t atf_text_for_each_word(const char *instr, const char *sep, atf_error_t (*func)(const char *, void *), void *data) { atf_error_t err; char *str, *str2, *last; str = strdup(instr); if (str == NULL) { err = atf_no_memory_error(); goto out; } err = atf_no_error(); str2 = strtok_r(str, sep, &last); while (str2 != NULL && !atf_is_error(err)) { err = func(str2, data); str2 = strtok_r(NULL, sep, &last); } free(str); out: return err; } atf_error_t atf_text_format(char **dest, const char *fmt, ...) { atf_error_t err; va_list ap; va_start(ap, fmt); err = atf_text_format_ap(dest, fmt, ap); va_end(ap); return err; } atf_error_t atf_text_format_ap(char **dest, const char *fmt, va_list ap) { atf_error_t err; atf_dynstr_t tmp; va_list ap2; va_copy(ap2, ap); err = atf_dynstr_init_ap(&tmp, fmt, ap2); va_end(ap2); if (!atf_is_error(err)) *dest = atf_dynstr_fini_disown(&tmp); return err; } atf_error_t atf_text_split(const char *str, const char *delim, atf_list_t *words) { atf_error_t err; const char *end; const char *iter; err = atf_list_init(words); if (atf_is_error(err)) goto err; end = str + strlen(str); INV(*end == '\0'); iter = str; while (iter < end) { const char *ptr; INV(iter != NULL); ptr = strstr(iter, delim); if (ptr == NULL) ptr = end; INV(ptr >= iter); if (ptr > iter) { atf_dynstr_t word; err = atf_dynstr_init_raw(&word, iter, ptr - iter); if (atf_is_error(err)) goto err_list; err = atf_list_append(words, atf_dynstr_fini_disown(&word), true); if (atf_is_error(err)) goto err_list; } iter = ptr + strlen(delim); } INV(!atf_is_error(err)); return err; err_list: atf_list_fini(words); err: return err; } atf_error_t atf_text_to_bool(const char *str, bool *b) { atf_error_t err; if (strcasecmp(str, "yes") == 0 || strcasecmp(str, "true") == 0) { *b = true; err = atf_no_error(); } else if (strcasecmp(str, "no") == 0 || strcasecmp(str, "false") == 0) { *b = false; err = atf_no_error(); } else { /* XXX Not really a libc error. */ err = atf_libc_error(EINVAL, "Cannot convert string '%s' " "to boolean", str); } return err; } atf_error_t atf_text_to_long(const char *str, long *l) { atf_error_t err; char *endptr; long tmp; errno = 0; tmp = strtol(str, &endptr, 10); if (str[0] == '\0' || *endptr != '\0') err = atf_libc_error(EINVAL, "'%s' is not a number", str); else if (errno == ERANGE || (tmp == LONG_MAX || tmp == LONG_MIN)) err = atf_libc_error(ERANGE, "'%s' is out of range", str); else { *l = tmp; err = atf_no_error(); } return err; } Index: head/contrib/atf/atf-c/detail/text.h =================================================================== --- head/contrib/atf/atf-c/detail/text.h (revision 273928) +++ head/contrib/atf/atf-c/detail/text.h (revision 273929) @@ -1,49 +1,44 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_TEXT_H) -#define ATF_C_TEXT_H +#if !defined(ATF_C_DETAIL_TEXT_H) +#define ATF_C_DETAIL_TEXT_H #include #include +#include #include -#include "list.h" - atf_error_t atf_text_for_each_word(const char *, const char *, atf_error_t (*)(const char *, void *), void *); atf_error_t atf_text_format(char **, const char *, ...); atf_error_t atf_text_format_ap(char **, const char *, va_list); atf_error_t atf_text_split(const char *, const char *, atf_list_t *); atf_error_t atf_text_to_bool(const char *, bool *); atf_error_t atf_text_to_long(const char *, long *); -#endif /* ATF_C_TEXT_H */ +#endif /* !defined(ATF_C_DETAIL_TEXT_H) */ Index: head/contrib/atf/atf-c/detail/text_test.c =================================================================== --- head/contrib/atf/atf-c/detail/text_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/text_test.c (revision 273929) @@ -1,424 +1,421 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/text.h" + #include #include #include #include -#include "sanity.h" -#include "test_helpers.h" -#include "text.h" +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ #define REQUIRE_ERROR(exp) \ do { \ atf_error_t err = exp; \ ATF_REQUIRE(atf_is_error(err)); \ atf_error_free(err); \ } while (0) static size_t array_size(const char *words[]) { size_t count; const char **word; count = 0; for (word = words; *word != NULL; word++) count++; return count; } static void check_split(const char *str, const char *delim, const char *words[]) { atf_list_t list; const char **word; size_t i; printf("Splitting '%s' with delimiter '%s'\n", str, delim); CE(atf_text_split(str, delim, &list)); printf("Expecting %zd words\n", array_size(words)); ATF_CHECK_EQ(atf_list_size(&list), array_size(words)); for (word = words, i = 0; *word != NULL; word++, i++) { printf("Word at position %zd should be '%s'\n", i, words[i]); ATF_CHECK_STREQ((const char *)atf_list_index_c(&list, i), words[i]); } atf_list_fini(&list); } static atf_error_t word_acum(const char *word, void *data) { char *acum = data; strcat(acum, word); return atf_no_error(); } static atf_error_t word_count(const char *word ATF_DEFS_ATTRIBUTE_UNUSED, void *data) { size_t *counter = data; (*counter)++; return atf_no_error(); } struct fail_at { int failpos; int curpos; }; static atf_error_t word_fail_at(const char *word ATF_DEFS_ATTRIBUTE_UNUSED, void *data) { struct fail_at *fa = data; atf_error_t err; if (fa->failpos == fa->curpos) err = atf_no_memory_error(); /* Just a random error. */ else { fa->curpos++; err = atf_no_error(); } return err; } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(for_each_word); ATF_TC_HEAD(for_each_word, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_text_for_each_word" "function"); } ATF_TC_BODY(for_each_word, tc) { size_t cnt; char acum[1024]; cnt = 0; strcpy(acum, ""); RE(atf_text_for_each_word("1 2 3", " ", word_count, &cnt)); RE(atf_text_for_each_word("1 2 3", " ", word_acum, acum)); ATF_REQUIRE(cnt == 3); ATF_REQUIRE(strcmp(acum, "123") == 0); cnt = 0; strcpy(acum, ""); RE(atf_text_for_each_word("1 2 3", ".", word_count, &cnt)); RE(atf_text_for_each_word("1 2 3", ".", word_acum, acum)); ATF_REQUIRE(cnt == 1); ATF_REQUIRE(strcmp(acum, "1 2 3") == 0); cnt = 0; strcpy(acum, ""); RE(atf_text_for_each_word("1 2 3 4 5", " ", word_count, &cnt)); RE(atf_text_for_each_word("1 2 3 4 5", " ", word_acum, acum)); ATF_REQUIRE(cnt == 5); ATF_REQUIRE(strcmp(acum, "12345") == 0); cnt = 0; strcpy(acum, ""); RE(atf_text_for_each_word("1 2.3.4 5", " .", word_count, &cnt)); RE(atf_text_for_each_word("1 2.3.4 5", " .", word_acum, acum)); ATF_REQUIRE(cnt == 5); ATF_REQUIRE(strcmp(acum, "12345") == 0); { struct fail_at fa; fa.failpos = 3; fa.curpos = 0; atf_error_t err = atf_text_for_each_word("a b c d e", " ", word_fail_at, &fa); ATF_REQUIRE(atf_is_error(err)); ATF_REQUIRE(atf_error_is(err, "no_memory")); ATF_REQUIRE(fa.curpos == 3); atf_error_free(err); } } ATF_TC(format); ATF_TC_HEAD(format, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of free-form " "strings using a variable parameters list"); } ATF_TC_BODY(format, tc) { char *str; atf_error_t err; err = atf_text_format(&str, "%s %s %d", "Test", "string", 1); ATF_REQUIRE(!atf_is_error(err)); ATF_REQUIRE(strcmp(str, "Test string 1") == 0); free(str); } static void format_ap(char **dest, const char *fmt, ...) { va_list ap; atf_error_t err; va_start(ap, fmt); err = atf_text_format_ap(dest, fmt, ap); va_end(ap); ATF_REQUIRE(!atf_is_error(err)); } ATF_TC(format_ap); ATF_TC_HEAD(format_ap, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of free-form " "strings using a va_list argument"); } ATF_TC_BODY(format_ap, tc) { char *str; format_ap(&str, "%s %s %d", "Test", "string", 1); ATF_REQUIRE(strcmp(str, "Test string 1") == 0); free(str); } ATF_TC(split); ATF_TC_HEAD(split, tc) { atf_tc_set_md_var(tc, "descr", "Checks the split function"); } ATF_TC_BODY(split, tc) { { const char *words[] = { NULL }; check_split("", " ", words); } { const char *words[] = { NULL }; check_split(" ", " ", words); } { const char *words[] = { NULL }; check_split(" ", " ", words); } { const char *words[] = { "a", "b", NULL }; check_split("a b", " ", words); } { const char *words[] = { "a", "b", "c", "d", NULL }; check_split("a b c d", " ", words); } { const char *words[] = { "foo", "bar", NULL }; check_split("foo bar", " ", words); } { const char *words[] = { "foo", "bar", "baz", "foobar", NULL }; check_split("foo bar baz foobar", " ", words); } { const char *words[] = { "foo", "bar", NULL }; check_split(" foo bar", " ", words); } { const char *words[] = { "foo", "bar", NULL }; check_split("foo bar", " ", words); } { const char *words[] = { "foo", "bar", NULL }; check_split("foo bar ", " ", words); } { const char *words[] = { "foo", "bar", NULL }; check_split(" foo bar ", " ", words); } } ATF_TC(split_delims); ATF_TC_HEAD(split_delims, tc) { atf_tc_set_md_var(tc, "descr", "Checks the split function using " "different delimiters"); } ATF_TC_BODY(split_delims, tc) { { const char *words[] = { NULL }; check_split("", "/", words); } { const char *words[] = { " ", NULL }; check_split(" ", "/", words); } { const char *words[] = { " ", NULL }; check_split(" ", "/", words); } { const char *words[] = { "a", "b", NULL }; check_split("a/b", "/", words); } { const char *words[] = { "a", "bcd", "ef", NULL }; check_split("aLONGDELIMbcdLONGDELIMef", "LONGDELIM", words); } } ATF_TC(to_bool); ATF_TC_HEAD(to_bool, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_text_to_bool function"); } ATF_TC_BODY(to_bool, tc) { bool b; RE(atf_text_to_bool("true", &b)); ATF_REQUIRE(b); RE(atf_text_to_bool("TRUE", &b)); ATF_REQUIRE(b); RE(atf_text_to_bool("yes", &b)); ATF_REQUIRE(b); RE(atf_text_to_bool("YES", &b)); ATF_REQUIRE(b); RE(atf_text_to_bool("false", &b)); ATF_REQUIRE(!b); RE(atf_text_to_bool("FALSE", &b)); ATF_REQUIRE(!b); RE(atf_text_to_bool("no", &b)); ATF_REQUIRE(!b); RE(atf_text_to_bool("NO", &b)); ATF_REQUIRE(!b); b = false; REQUIRE_ERROR(atf_text_to_bool("", &b)); ATF_REQUIRE(!b); b = true; REQUIRE_ERROR(atf_text_to_bool("", &b)); ATF_REQUIRE(b); b = false; REQUIRE_ERROR(atf_text_to_bool("tru", &b)); ATF_REQUIRE(!b); b = true; REQUIRE_ERROR(atf_text_to_bool("tru", &b)); ATF_REQUIRE(b); b = false; REQUIRE_ERROR(atf_text_to_bool("true2", &b)); ATF_REQUIRE(!b); b = true; REQUIRE_ERROR(atf_text_to_bool("true2", &b)); ATF_REQUIRE(b); b = false; REQUIRE_ERROR(atf_text_to_bool("fals", &b)); ATF_REQUIRE(!b); b = true; REQUIRE_ERROR(atf_text_to_bool("fals", &b)); ATF_REQUIRE(b); b = false; REQUIRE_ERROR(atf_text_to_bool("false2", &b)); ATF_REQUIRE(!b); b = true; REQUIRE_ERROR(atf_text_to_bool("false2", &b)); ATF_REQUIRE(b); } ATF_TC(to_long); ATF_TC_HEAD(to_long, tc) { atf_tc_set_md_var(tc, "descr", "Checks the atf_text_to_long function"); } ATF_TC_BODY(to_long, tc) { long l; RE(atf_text_to_long("0", &l)); ATF_REQUIRE_EQ(l, 0); RE(atf_text_to_long("-5", &l)); ATF_REQUIRE_EQ(l, -5); RE(atf_text_to_long("5", &l)); ATF_REQUIRE_EQ(l, 5); RE(atf_text_to_long("123456789", &l)); ATF_REQUIRE_EQ(l, 123456789); l = 1212; REQUIRE_ERROR(atf_text_to_long("", &l)); ATF_REQUIRE_EQ(l, 1212); REQUIRE_ERROR(atf_text_to_long("foo", &l)); ATF_REQUIRE_EQ(l, 1212); REQUIRE_ERROR(atf_text_to_long("1234x", &l)); ATF_REQUIRE_EQ(l, 1212); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, for_each_word); ATF_TP_ADD_TC(tp, format); ATF_TP_ADD_TC(tp, format_ap); ATF_TP_ADD_TC(tp, split); ATF_TP_ADD_TC(tp, split_delims); ATF_TP_ADD_TC(tp, to_bool); ATF_TP_ADD_TC(tp, to_long); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/tp_main.c =================================================================== --- head/contrib/atf/atf-c/detail/tp_main.c (revision 273928) +++ head/contrib/atf/atf-c/detail/tp_main.c (revision 273929) @@ -1,617 +1,612 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include #include #include #include #include +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/map.h" +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" #include "atf-c/tc.h" #include "atf-c/tp.h" #include "atf-c/utils.h" -#include "dynstr.h" -#include "env.h" -#include "fs.h" -#include "map.h" -#include "sanity.h" - #if defined(HAVE_GNU_GETOPT) # define GETOPT_POSIX "+" #else # define GETOPT_POSIX "" #endif static const char *progname = NULL; /* This prototype is provided by macros.h during instantiation of the test * program, so it can be kept private. Don't know if that's the best idea * though. */ int atf_tp_main(int, char **, atf_error_t (*)(atf_tp_t *)); enum tc_part { BODY, CLEANUP, }; /* --------------------------------------------------------------------- * The "usage" and "user" error types. * --------------------------------------------------------------------- */ #define FREE_FORM_ERROR(name) \ struct name ## _error_data { \ char m_what[2048]; \ }; \ \ static \ void \ name ## _format(const atf_error_t err, char *buf, size_t buflen) \ { \ const struct name ## _error_data *data; \ \ PRE(atf_error_is(err, #name)); \ \ data = atf_error_data(err); \ snprintf(buf, buflen, "%s", data->m_what); \ } \ \ static \ atf_error_t \ name ## _error(const char *fmt, ...) \ { \ atf_error_t err; \ struct name ## _error_data data; \ va_list ap; \ \ va_start(ap, fmt); \ vsnprintf(data.m_what, sizeof(data.m_what), fmt, ap); \ va_end(ap); \ \ err = atf_error_new(#name, &data, sizeof(data), name ## _format); \ \ return err; \ } FREE_FORM_ERROR(usage); FREE_FORM_ERROR(user); /* --------------------------------------------------------------------- * Printing functions. * --------------------------------------------------------------------- */ static void print_error(const atf_error_t err) { char buf[4096]; PRE(atf_is_error(err)); atf_error_format(err, buf, sizeof(buf)); fprintf(stderr, "%s: ERROR: %s\n", progname, buf); if (atf_error_is(err, "usage")) fprintf(stderr, "%s: See atf-test-program(1) for usage details.\n", progname); } static void print_warning(const char *message) { fprintf(stderr, "%s: WARNING: %s\n", progname, message); } /* --------------------------------------------------------------------- * Options handling. * --------------------------------------------------------------------- */ struct params { bool m_do_list; atf_fs_path_t m_srcdir; char *m_tcname; enum tc_part m_tcpart; atf_fs_path_t m_resfile; atf_map_t m_config; }; static atf_error_t argv0_to_dir(const char *argv0, atf_fs_path_t *dir) { atf_error_t err; atf_fs_path_t temp; err = atf_fs_path_init_fmt(&temp, "%s", argv0); if (atf_is_error(err)) goto out; err = atf_fs_path_branch_path(&temp, dir); atf_fs_path_fini(&temp); out: return err; } static atf_error_t params_init(struct params *p, const char *argv0) { atf_error_t err; p->m_do_list = false; p->m_tcname = NULL; p->m_tcpart = BODY; err = argv0_to_dir(argv0, &p->m_srcdir); if (atf_is_error(err)) return err; err = atf_fs_path_init_fmt(&p->m_resfile, "/dev/stdout"); if (atf_is_error(err)) { atf_fs_path_fini(&p->m_srcdir); return err; } err = atf_map_init(&p->m_config); if (atf_is_error(err)) { atf_fs_path_fini(&p->m_resfile); atf_fs_path_fini(&p->m_srcdir); return err; } return err; } static void params_fini(struct params *p) { atf_map_fini(&p->m_config); atf_fs_path_fini(&p->m_resfile); atf_fs_path_fini(&p->m_srcdir); if (p->m_tcname != NULL) free(p->m_tcname); } static atf_error_t parse_vflag(char *arg, atf_map_t *config) { atf_error_t err; char *split; split = strchr(arg, '='); if (split == NULL) { err = usage_error("-v requires an argument of the form var=value"); goto out; } *split = '\0'; split++; err = atf_map_insert(config, arg, split, false); out: return err; } static atf_error_t replace_path_param(atf_fs_path_t *param, const char *value) { atf_error_t err; atf_fs_path_t temp; err = atf_fs_path_init_fmt(&temp, "%s", value); if (!atf_is_error(err)) { atf_fs_path_fini(param); *param = temp; } return err; } /* --------------------------------------------------------------------- * Test case listing. * --------------------------------------------------------------------- */ static void list_tcs(const atf_tp_t *tp) { const atf_tc_t *const *tcs; const atf_tc_t *const *tcsptr; printf("Content-Type: application/X-atf-tp; version=\"1\"\n\n"); tcs = atf_tp_get_tcs(tp); INV(tcs != NULL); /* Should be checked. */ for (tcsptr = tcs; *tcsptr != NULL; tcsptr++) { const atf_tc_t *tc = *tcsptr; char **vars = atf_tc_get_md_vars(tc); char **ptr; INV(vars != NULL); /* Should be checked. */ if (tcsptr != tcs) /* Not first. */ printf("\n"); for (ptr = vars; *ptr != NULL; ptr += 2) { if (strcmp(*ptr, "ident") == 0) { printf("ident: %s\n", *(ptr + 1)); break; } } for (ptr = vars; *ptr != NULL; ptr += 2) { if (strcmp(*ptr, "ident") != 0) { printf("%s: %s\n", *ptr, *(ptr + 1)); } } atf_utils_free_charpp(vars); } } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ static atf_error_t handle_tcarg(const char *tcarg, char **tcname, enum tc_part *tcpart) { atf_error_t err; err = atf_no_error(); *tcname = strdup(tcarg); if (*tcname == NULL) { err = atf_no_memory_error(); goto out; } char *delim = strchr(*tcname, ':'); if (delim != NULL) { *delim = '\0'; delim++; if (strcmp(delim, "body") == 0) { *tcpart = BODY; } else if (strcmp(delim, "cleanup") == 0) { *tcpart = CLEANUP; } else { err = usage_error("Invalid test case part `%s'", delim); goto out; } } out: return err; } static atf_error_t process_params(int argc, char **argv, struct params *p) { atf_error_t err; int ch; int old_opterr; err = params_init(p, argv[0]); if (atf_is_error(err)) goto out; old_opterr = opterr; opterr = 0; while (!atf_is_error(err) && (ch = getopt(argc, argv, GETOPT_POSIX ":lr:s:v:")) != -1) { switch (ch) { case 'l': p->m_do_list = true; break; case 'r': err = replace_path_param(&p->m_resfile, optarg); break; case 's': err = replace_path_param(&p->m_srcdir, optarg); break; case 'v': err = parse_vflag(optarg, &p->m_config); break; case ':': err = usage_error("Option -%c requires an argument.", optopt); break; case '?': default: err = usage_error("Unknown option -%c.", optopt); } } argc -= optind; argv += optind; /* Clear getopt state just in case the test wants to use it. */ opterr = old_opterr; optind = 1; #if defined(HAVE_OPTRESET) optreset = 1; #endif if (!atf_is_error(err)) { if (p->m_do_list) { if (argc > 0) err = usage_error("Cannot provide test case names with -l"); } else { if (argc == 0) err = usage_error("Must provide a test case name"); else if (argc == 1) err = handle_tcarg(argv[0], &p->m_tcname, &p->m_tcpart); else if (argc > 1) { err = usage_error("Cannot provide more than one test case " "name"); } } } if (atf_is_error(err)) params_fini(p); out: return err; } static atf_error_t srcdir_strip_libtool(atf_fs_path_t *srcdir) { atf_error_t err; atf_fs_path_t parent; err = atf_fs_path_branch_path(srcdir, &parent); if (atf_is_error(err)) goto out; atf_fs_path_fini(srcdir); *srcdir = parent; INV(!atf_is_error(err)); out: return err; } static atf_error_t handle_srcdir(struct params *p) { atf_error_t err; atf_dynstr_t leafname; atf_fs_path_t exe, srcdir; bool b; err = atf_fs_path_copy(&srcdir, &p->m_srcdir); if (atf_is_error(err)) goto out; if (!atf_fs_path_is_absolute(&srcdir)) { atf_fs_path_t srcdirabs; err = atf_fs_path_to_absolute(&srcdir, &srcdirabs); if (atf_is_error(err)) goto out_srcdir; atf_fs_path_fini(&srcdir); srcdir = srcdirabs; } err = atf_fs_path_leaf_name(&srcdir, &leafname); if (atf_is_error(err)) goto out_srcdir; else { const bool libs = atf_equal_dynstr_cstring(&leafname, ".libs"); atf_dynstr_fini(&leafname); if (libs) { err = srcdir_strip_libtool(&srcdir); if (atf_is_error(err)) goto out; } } err = atf_fs_path_copy(&exe, &srcdir); if (atf_is_error(err)) goto out_srcdir; err = atf_fs_path_append_fmt(&exe, "%s", progname); if (atf_is_error(err)) goto out_exe; err = atf_fs_exists(&exe, &b); if (!atf_is_error(err)) { if (b) { err = atf_map_insert(&p->m_config, "srcdir", strdup(atf_fs_path_cstring(&srcdir)), true); } else { err = user_error("Cannot find the test program in the source " "directory `%s'", atf_fs_path_cstring(&srcdir)); } } out_exe: atf_fs_path_fini(&exe); out_srcdir: atf_fs_path_fini(&srcdir); out: return err; } static atf_error_t run_tc(const atf_tp_t *tp, struct params *p, int *exitcode) { atf_error_t err; err = atf_no_error(); if (!atf_tp_has_tc(tp, p->m_tcname)) { err = usage_error("Unknown test case `%s'", p->m_tcname); goto out; } if (!atf_env_has("__RUNNING_INSIDE_ATF_RUN") || strcmp(atf_env_get( "__RUNNING_INSIDE_ATF_RUN"), "internal-yes-value") != 0) { - print_warning("Running test cases without atf-run(1) is unsupported"); + print_warning("Running test cases outside of kyua(1) is unsupported"); print_warning("No isolation nor timeout control is being applied; you " "may get unexpected failures; see atf-test-case(4)"); } switch (p->m_tcpart) { case BODY: err = atf_tp_run(tp, p->m_tcname, atf_fs_path_cstring(&p->m_resfile)); if (atf_is_error(err)) { /* TODO: Handle error */ *exitcode = EXIT_FAILURE; atf_error_free(err); } else { *exitcode = EXIT_SUCCESS; } break; case CLEANUP: err = atf_tp_cleanup(tp, p->m_tcname); if (atf_is_error(err)) { /* TODO: Handle error */ *exitcode = EXIT_FAILURE; atf_error_free(err); } else { *exitcode = EXIT_SUCCESS; } break; default: UNREACHABLE; } INV(!atf_is_error(err)); out: return err; } static atf_error_t controlled_main(int argc, char **argv, atf_error_t (*add_tcs_hook)(atf_tp_t *), int *exitcode) { atf_error_t err; struct params p; atf_tp_t tp; char **raw_config; err = process_params(argc, argv, &p); if (atf_is_error(err)) goto out; err = handle_srcdir(&p); if (atf_is_error(err)) goto out_p; raw_config = atf_map_to_charpp(&p.m_config); if (raw_config == NULL) { err = atf_no_memory_error(); goto out_p; } err = atf_tp_init(&tp, (const char* const*)raw_config); atf_utils_free_charpp(raw_config); if (atf_is_error(err)) goto out_p; err = add_tcs_hook(&tp); if (atf_is_error(err)) goto out_tp; if (p.m_do_list) { list_tcs(&tp); INV(!atf_is_error(err)); *exitcode = EXIT_SUCCESS; } else { err = run_tc(&tp, &p, exitcode); } out_tp: atf_tp_fini(&tp); out_p: params_fini(&p); out: return err; } int atf_tp_main(int argc, char **argv, atf_error_t (*add_tcs_hook)(atf_tp_t *)) { atf_error_t err; int exitcode; progname = strrchr(argv[0], '/'); if (progname == NULL) progname = argv[0]; else progname++; /* Libtool workaround: if running from within the source tree (binaries * that are not installed yet), skip the "lt-" prefix added to files in * the ".libs" directory to show the real (not temporary) name. */ if (strncmp(progname, "lt-", 3) == 0) progname += 3; exitcode = EXIT_FAILURE; /* Silence GCC warning. */ err = controlled_main(argc, argv, add_tcs_hook, &exitcode); if (atf_is_error(err)) { print_error(err); atf_error_free(err); exitcode = EXIT_FAILURE; } return exitcode; } Index: head/contrib/atf/atf-c/detail/user.c =================================================================== --- head/contrib/atf/atf-c/detail/user.c (revision 273928) +++ head/contrib/atf/atf-c/detail/user.c (revision 273929) @@ -1,78 +1,75 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/user.h" + #include #include #include #include -#include "sanity.h" -#include "user.h" +#include "atf-c/detail/sanity.h" /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ uid_t atf_user_euid(void) { return geteuid(); } bool atf_user_is_member_of_group(gid_t gid) { static gid_t groups[NGROUPS_MAX]; static int ngroups = -1; bool found; int i; if (ngroups == -1) { ngroups = getgroups(NGROUPS_MAX, groups); INV(ngroups >= 0); } found = false; for (i = 0; !found && i < ngroups; i++) if (groups[i] == gid) found = true; return found; } bool atf_user_is_root(void) { return geteuid() == 0; } bool atf_user_is_unprivileged(void) { return geteuid() != 0; } Index: head/contrib/atf/atf-c/detail/user.h =================================================================== --- head/contrib/atf/atf-c/detail/user.h (revision 273928) +++ head/contrib/atf/atf-c/detail/user.h (revision 273929) @@ -1,49 +1,45 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if !defined(ATF_C_USER_H) -#define ATF_C_USER_H +#if !defined(ATF_C_DETAIL_USER_H) +#define ATF_C_DETAIL_USER_H #include #include /* TODO: Would be nice to have an atf_user_t type and transform all of * the functions below to methods. */ /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ uid_t atf_user_euid(void); bool atf_user_is_member_of_group(gid_t); bool atf_user_is_root(void); bool atf_user_is_unprivileged(void); -#endif /* !defined(ATF_C_USER_H) */ +#endif /* !defined(ATF_C_DETAIL_USER_H) */ Index: head/contrib/atf/atf-c/detail/user_test.c =================================================================== --- head/contrib/atf/atf-c/detail/user_test.c (revision 273928) +++ head/contrib/atf/atf-c/detail/user_test.c (revision 273929) @@ -1,149 +1,146 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/detail/user.h" + #include #include #include #include #include #include -#include "test_helpers.h" -#include "user.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ ATF_TC(euid); ATF_TC_HEAD(euid, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_user_euid function"); } ATF_TC_BODY(euid, tc) { ATF_REQUIRE_EQ(atf_user_euid(), geteuid()); } ATF_TC(is_member_of_group); ATF_TC_HEAD(is_member_of_group, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_user_is_member_of_group " "function"); } ATF_TC_BODY(is_member_of_group, tc) { gid_t gids[NGROUPS_MAX]; gid_t g, maxgid; int ngids; const gid_t maxgid_limit = 1 << 16; { int i; ngids = getgroups(NGROUPS_MAX, gids); if (ngids == -1) atf_tc_fail("Call to getgroups failed"); maxgid = 0; for (i = 0; i < ngids; i++) { printf("User group %d is %u\n", i, gids[i]); if (maxgid < gids[i]) maxgid = gids[i]; } printf("User belongs to %d groups\n", ngids); printf("Last GID is %u\n", maxgid); } if (maxgid > maxgid_limit) { printf("Test truncated from %u groups to %u to keep the run time " "reasonable enough\n", maxgid, maxgid_limit); maxgid = maxgid_limit; } for (g = 0; g < maxgid; g++) { bool found = false; int i; for (i = 0; !found && i < ngids; i++) { if (gids[i] == g) found = true; } if (found) { printf("Checking if user belongs to group %d\n", g); ATF_REQUIRE(atf_user_is_member_of_group(g)); } else { printf("Checking if user does not belong to group %d\n", g); ATF_REQUIRE(!atf_user_is_member_of_group(g)); } } } ATF_TC(is_root); ATF_TC_HEAD(is_root, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_user_is_root function"); } ATF_TC_BODY(is_root, tc) { if (geteuid() == 0) ATF_REQUIRE(atf_user_is_root()); else ATF_REQUIRE(!atf_user_is_root()); } ATF_TC(is_unprivileged); ATF_TC_HEAD(is_unprivileged, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_user_is_unprivileged " "function"); } ATF_TC_BODY(is_unprivileged, tc) { if (geteuid() != 0) ATF_REQUIRE(atf_user_is_unprivileged()); else ATF_REQUIRE(!atf_user_is_unprivileged()); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, euid); ATF_TP_ADD_TC(tp, is_member_of_group); ATF_TP_ADD_TC(tp, is_root); ATF_TP_ADD_TC(tp, is_unprivileged); return atf_no_error(); } Index: head/contrib/atf/atf-c/detail/version_helper.c =================================================================== --- head/contrib/atf/atf-c/detail/version_helper.c (revision 273928) +++ head/contrib/atf/atf-c/detail/version_helper.c (revision 273929) @@ -1,43 +1,43 @@ /* * Copyright 2014 Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * Neither the name of Google Inc. nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include int main(void) { printf("%s\n", PACKAGE_VERSION); return EXIT_SUCCESS; } Index: head/contrib/atf/atf-c/error.c =================================================================== --- head/contrib/atf/atf-c/error.c (revision 273928) +++ head/contrib/atf/atf-c/error.c (revision 273929) @@ -1,267 +1,263 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/error.h" + #include #include #include #include -#include "atf-c/error.h" - -#include "detail/sanity.h" +#include "atf-c/detail/sanity.h" /* Theoretically, there can only be a single error intance at any given * point in time, because errors are raised at one point and must be * handled immediately. If another error has to be raised during the * handling process, something else has to be done with the previous * error. * * This is per-thread information and will break threaded tests, but we * currently do not have any threading support; therefore, this is fine. */ static bool error_on_flight = false; /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void error_format(const atf_error_t err, char *buf, size_t buflen) { PRE(err != NULL); snprintf(buf, buflen, "Error '%s'", err->m_type); } static bool error_init(atf_error_t err, const char *type, void *data, size_t datalen, void (*format)(const atf_error_t, char *, size_t)) { bool ok; PRE(data != NULL || datalen == 0); PRE(datalen != 0 || data == NULL); err->m_free = false; err->m_type = type; err->m_format = (format == NULL) ? error_format : format; ok = true; if (data == NULL) { err->m_data = NULL; } else { err->m_data = malloc(datalen); if (err->m_data == NULL) { ok = false; } else memcpy(err->m_data, data, datalen); } return ok; } /* --------------------------------------------------------------------- * The "atf_error" type. * --------------------------------------------------------------------- */ atf_error_t atf_error_new(const char *type, void *data, size_t datalen, void (*format)(const atf_error_t, char *, size_t)) { atf_error_t err; PRE(!error_on_flight); PRE(data != NULL || datalen == 0); PRE(datalen != 0 || data == NULL); err = malloc(sizeof(*err)); if (err == NULL) err = atf_no_memory_error(); else { if (!error_init(err, type, data, datalen, format)) { free(err); err = atf_no_memory_error(); } else { err->m_free = true; error_on_flight = true; } } INV(err != NULL); POST(error_on_flight); return err; } void atf_error_free(atf_error_t err) { bool freeit; PRE(error_on_flight); PRE(err != NULL); freeit = err->m_free; if (err->m_data != NULL) free(err->m_data); if (freeit) free(err); error_on_flight = false; } atf_error_t atf_no_error(void) { return NULL; } bool atf_is_error(const atf_error_t err) { return err != NULL; } bool atf_error_is(const atf_error_t err, const char *type) { PRE(err != NULL); return strcmp(err->m_type, type) == 0; } const void * atf_error_data(const atf_error_t err) { PRE(err != NULL); return err->m_data; } void atf_error_format(const atf_error_t err, char *buf, size_t buflen) { PRE(err != NULL); err->m_format(err, buf, buflen); } /* --------------------------------------------------------------------- * Common error types. * --------------------------------------------------------------------- */ /* * The "libc" error. */ struct atf_libc_error_data { int m_errno; char m_what[4096]; }; typedef struct atf_libc_error_data atf_libc_error_data_t; static void libc_format(const atf_error_t err, char *buf, size_t buflen) { const atf_libc_error_data_t *data; PRE(atf_error_is(err, "libc")); data = atf_error_data(err); snprintf(buf, buflen, "%s: %s", data->m_what, strerror(data->m_errno)); } atf_error_t atf_libc_error(int syserrno, const char *fmt, ...) { atf_error_t err; atf_libc_error_data_t data; va_list ap; data.m_errno = syserrno; va_start(ap, fmt); vsnprintf(data.m_what, sizeof(data.m_what), fmt, ap); va_end(ap); err = atf_error_new("libc", &data, sizeof(data), libc_format); return err; } int atf_libc_error_code(const atf_error_t err) { const struct atf_libc_error_data *data; PRE(atf_error_is(err, "libc")); data = atf_error_data(err); return data->m_errno; } const char * atf_libc_error_msg(const atf_error_t err) { const struct atf_libc_error_data *data; PRE(atf_error_is(err, "libc")); data = atf_error_data(err); return data->m_what; } /* * The "no_memory" error. */ static struct atf_error no_memory_error; static void no_memory_format(const atf_error_t err, char *buf, size_t buflen) { PRE(atf_error_is(err, "no_memory")); snprintf(buf, buflen, "Not enough memory"); } atf_error_t atf_no_memory_error(void) { PRE(!error_on_flight); error_init(&no_memory_error, "no_memory", NULL, 0, no_memory_format); error_on_flight = true; return &no_memory_error; } Index: head/contrib/atf/atf-c/error.h =================================================================== --- head/contrib/atf/atf-c/error.h (revision 273928) +++ head/contrib/atf/atf-c/error.h (revision 273929) @@ -1,71 +1,67 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_ERROR_H) #define ATF_C_ERROR_H +#include + #include #include -#include - /* --------------------------------------------------------------------- * The "atf_error" type. * --------------------------------------------------------------------- */ struct atf_error { bool m_free; const char *m_type; void *m_data; void (*m_format)(struct atf_error *, char *, size_t); }; atf_error_t atf_error_new(const char *, void *, size_t, void (*)(const atf_error_t, char *, size_t)); void atf_error_free(atf_error_t); atf_error_t atf_no_error(void); bool atf_is_error(const atf_error_t); bool atf_error_is(const atf_error_t, const char *); const void *atf_error_data(const atf_error_t); void atf_error_format(const atf_error_t, char *, size_t); /* --------------------------------------------------------------------- * Common error types. * --------------------------------------------------------------------- */ atf_error_t atf_libc_error(int, const char *, ...); int atf_libc_error_code(const atf_error_t); const char *atf_libc_error_msg(const atf_error_t); atf_error_t atf_no_memory_error(void); -#endif /* ATF_C_ERROR_H */ +#endif /* !defined(ATF_C_ERROR_H) */ Index: head/contrib/atf/atf-c/error_fwd.h =================================================================== --- head/contrib/atf/atf-c/error_fwd.h (revision 273928) +++ head/contrib/atf/atf-c/error_fwd.h (revision 273929) @@ -1,40 +1,36 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_ERROR_FWD_H) #define ATF_C_ERROR_FWD_H /* --------------------------------------------------------------------- * The "atf_error" type. * --------------------------------------------------------------------- */ struct atf_error; typedef struct atf_error *atf_error_t; -#endif /* ATF_C_ERROR_FWD_H */ +#endif /* !defined(ATF_C_ERROR_FWD_H) */ Index: head/contrib/atf/atf-c/error_test.c =================================================================== --- head/contrib/atf/atf-c/error_test.c (revision 273928) +++ head/contrib/atf/atf-c/error_test.c (revision 273929) @@ -1,313 +1,297 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/error.h" + #include #include #include #include #include #include "atf-c/defs.h" -#include "atf-c/error.h" -#include "detail/test_helpers.h" - /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void test_format(const atf_error_t err ATF_DEFS_ATTRIBUTE_UNUSED, char *buf, size_t buflen) { snprintf(buf, buflen, "Test formatting function"); } /* --------------------------------------------------------------------- * Tests for the "atf_error" type. * --------------------------------------------------------------------- */ ATF_TC(error_new); ATF_TC_HEAD(error_new, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of an error " "object"); } ATF_TC_BODY(error_new, tc) { atf_error_t err; int data; err = atf_error_new("test_error", NULL, 0, NULL); ATF_REQUIRE(atf_error_is(err, "test_error")); ATF_REQUIRE(!atf_error_is(err, "unknown_error")); ATF_REQUIRE(atf_error_data(err) == NULL); atf_error_free(err); data = 5; err = atf_error_new("test_data_error", &data, sizeof(data), NULL); ATF_REQUIRE(atf_error_is(err, "test_data_error")); ATF_REQUIRE(!atf_error_is(err, "unknown_error")); ATF_REQUIRE(atf_error_data(err) != NULL); ATF_REQUIRE_EQ(*((const int *)atf_error_data(err)), 5); atf_error_free(err); } ATF_TC(error_new_wo_memory); ATF_TC_HEAD(error_new_wo_memory, tc) { atf_tc_set_md_var(tc, "descr", "Checks that an unavailable memory error " "raised when constructing an error object " "is properly converted to the no_memory " "static error type"); } ATF_TC_BODY(error_new_wo_memory, tc) { atf_error_t err; void *invalid; invalid = (void *)1; err = atf_error_new("test_error", invalid, SIZE_MAX, NULL); ATF_REQUIRE(atf_error_is(err, "no_memory")); ATF_REQUIRE(atf_error_data(err) == NULL); atf_error_free(err); } ATF_TC(no_error); ATF_TC_HEAD(no_error, tc) { atf_tc_set_md_var(tc, "descr", "Checks that constructing a non-error " "object works"); } ATF_TC_BODY(no_error, tc) { atf_error_t err; err = atf_no_error(); ATF_REQUIRE(!atf_is_error(err)); } ATF_TC(is_error); ATF_TC_HEAD(is_error, tc) { atf_tc_set_md_var(tc, "descr", "Checks the is_error method to determine " "if an error object holds success or an error"); } ATF_TC_BODY(is_error, tc) { atf_error_t err; err = atf_no_error(); ATF_REQUIRE(!atf_is_error(err)); err = atf_error_new("test_error", NULL, 0, NULL); ATF_REQUIRE(atf_is_error(err)); atf_error_free(err); } ATF_TC(format); ATF_TC_HEAD(format, tc) { atf_tc_set_md_var(tc, "descr", "Checks the default formatting function " "and the ability to change it"); } ATF_TC_BODY(format, tc) { atf_error_t err; char buf[1024]; printf("Testing default formatting function\n"); err = atf_error_new("test_error", NULL, 0, NULL); atf_error_format(err, buf, sizeof(buf)); printf("Error string is: %s\n", buf); ATF_REQUIRE(strcmp(buf, "Error 'test_error'") == 0); atf_error_free(err); printf("Testing custom formatting function\n"); err = atf_error_new("test_error", NULL, 0, test_format); atf_error_format(err, buf, sizeof(buf)); printf("Error string is: %s\n", buf); ATF_REQUIRE(strcmp(buf, "Test formatting function") == 0); atf_error_free(err); } /* --------------------------------------------------------------------- * Tests for the "libc" error. * --------------------------------------------------------------------- */ ATF_TC(libc_new); ATF_TC_HEAD(libc_new, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of libc errors"); } ATF_TC_BODY(libc_new, tc) { atf_error_t err; err = atf_libc_error(ENOMEM, "Test message 1"); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), ENOMEM); ATF_REQUIRE(strcmp(atf_libc_error_msg(err), "Test message 1") == 0); atf_error_free(err); err = atf_libc_error(EPERM, "%s message %d", "Test", 2); ATF_REQUIRE(atf_error_is(err, "libc")); ATF_REQUIRE_EQ(atf_libc_error_code(err), EPERM); ATF_REQUIRE(strcmp(atf_libc_error_msg(err), "Test message 2") == 0); atf_error_free(err); } ATF_TC(libc_format); ATF_TC_HEAD(libc_format, tc) { atf_tc_set_md_var(tc, "descr", "Checks the formatting of libc errors"); } ATF_TC_BODY(libc_format, tc) { atf_error_t err; char buf[1024]; err = atf_libc_error(ENOMEM, "Test message 1"); atf_error_format(err, buf, sizeof(buf)); ATF_REQUIRE(strstr(buf, strerror(ENOMEM)) != NULL); ATF_REQUIRE(strstr(buf, "Test message 1") != NULL); atf_error_free(err); err = atf_libc_error(EPERM, "Test message 2"); atf_error_format(err, buf, sizeof(buf)); ATF_REQUIRE(strstr(buf, strerror(EPERM)) != NULL); ATF_REQUIRE(strstr(buf, "Test message 2") != NULL); atf_error_free(err); err = atf_libc_error(EPERM, "%s message %d", "Test", 3); atf_error_format(err, buf, sizeof(buf)); ATF_REQUIRE(strstr(buf, strerror(EPERM)) != NULL); ATF_REQUIRE(strstr(buf, "Test message 3") != NULL); atf_error_free(err); } /* --------------------------------------------------------------------- * Tests for the "no_memory" error. * --------------------------------------------------------------------- */ ATF_TC(no_memory_new); ATF_TC_HEAD(no_memory_new, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of no_memory " "errors"); } ATF_TC_BODY(no_memory_new, tc) { atf_error_t err; err = atf_no_memory_error(); ATF_REQUIRE(atf_error_is(err, "no_memory")); ATF_REQUIRE(atf_error_data(err) == NULL); atf_error_free(err); } ATF_TC(no_memory_format); ATF_TC_HEAD(no_memory_format, tc) { atf_tc_set_md_var(tc, "descr", "Checks the formatting of no_memory " "errors"); } ATF_TC_BODY(no_memory_format, tc) { atf_error_t err; char buf[1024]; err = atf_no_memory_error(); atf_error_format(err, buf, sizeof(buf)); ATF_REQUIRE(strcmp(buf, "Not enough memory") == 0); atf_error_free(err); } ATF_TC(no_memory_twice); ATF_TC_HEAD(no_memory_twice, tc) { atf_tc_set_md_var(tc, "descr", "Checks the construction of no_memory " "errors multiple times, as this error is initialized " "statically"); } ATF_TC_BODY(no_memory_twice, tc) { { atf_error_t err = atf_no_memory_error(); ATF_REQUIRE(atf_error_is(err, "no_memory")); ATF_REQUIRE(atf_error_data(err) == NULL); atf_error_free(err); } { atf_error_t err = atf_no_memory_error(); ATF_REQUIRE(atf_error_is(err, "no_memory")); ATF_REQUIRE(atf_error_data(err) == NULL); atf_error_free(err); } } /* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/error.h"); -HEADER_TC(include_fwd, "atf-c/error_fwd.h"); - -/* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the tests for the "atf_error" type. */ ATF_TP_ADD_TC(tp, error_new); ATF_TP_ADD_TC(tp, error_new_wo_memory); ATF_TP_ADD_TC(tp, no_error); ATF_TP_ADD_TC(tp, is_error); ATF_TP_ADD_TC(tp, format); /* Add the tests for the "libc" error. */ ATF_TP_ADD_TC(tp, libc_new); ATF_TP_ADD_TC(tp, libc_format); /* Add the tests for the "no_memory" error. */ ATF_TP_ADD_TC(tp, no_memory_new); ATF_TP_ADD_TC(tp, no_memory_format); ATF_TP_ADD_TC(tp, no_memory_twice); - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); - ATF_TP_ADD_TC(tp, include_fwd); return atf_no_error(); } Index: head/contrib/atf/atf-c/h_build.h =================================================================== --- head/contrib/atf/atf-c/h_build.h (revision 273928) +++ head/contrib/atf/atf-c/h_build.h (revision 273929) @@ -1,414 +1,410 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2009 The NetBSD Foundation, Inc. +/* Copyright (c) 2009 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#if defined(TESTS_ATF_ATF_C_H_BUILD_H) +#if defined(ATF_C_H_BUILD_H) # error "Cannot include h_build.h more than once." #else -# define TESTS_ATF_ATF_C_H_BUILD_H +# define ATF_C_H_BUILD_H #endif /* --------------------------------------------------------------------- * Test case data. * --------------------------------------------------------------------- */ static struct c_o_test { const char *msg; const char *cc; const char *cflags; const char *cppflags; const char *sfile; const char *ofile; bool hasoptargs; const char *const optargs[16]; const char *const expargv[16]; } c_o_tests[] = { { "No flags", "cc", "", "", "test.c", "test.o", false, { NULL }, { "cc", "-o", "test.o", "-c", "test.c", NULL }, }, { "Multi-word program name", "cc -foo", "", "", "test.c", "test.o", false, { NULL }, { "cc", "-foo", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cflags", "cc", "-f1 -f2 -f3 -f4-f5", "", "test.c", "test.o", false, { NULL }, { "cc", "-f1", "-f2", "-f3", "-f4-f5", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cppflags", "cc", "", "-f1 -f2 -f3 -f4-f5", "test.c", "test.o", false, { NULL }, { "cc", "-f1", "-f2", "-f3", "-f4-f5", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cflags and cppflags", "cc", "-f2", "-f1", "test.c", "test.o", false, { NULL }, { "cc", "-f1", "-f2", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some optional arguments", "cc", "", "", "test.c", "test.o", true, { "-o1", "-o2", NULL }, { "cc", "-o1", "-o2", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cflags, cppflags and optional arguments", "cc", "-f2", "-f1", "test.c", "test.o", true, { "-o1", "-o2", NULL }, { "cc", "-f1", "-f2", "-o1", "-o2", "-o", "test.o", "-c", "test.c", NULL }, }, { NULL, NULL, NULL, NULL, NULL, NULL, false, { NULL }, { NULL }, }, }; static struct cpp_test { const char *msg; const char *cpp; const char *cppflags; const char *sfile; const char *ofile; bool hasoptargs; const char *const optargs[16]; const char *const expargv[16]; } cpp_tests[] = { { "No flags", "cpp", "", "test.c", "test.out", false, { NULL }, { "cpp", "-o", "test.out", "test.c", NULL }, }, { "Multi-word program name", "cpp -foo", "", "test.c", "test.out", false, { NULL }, { "cpp", "-foo", "-o", "test.out", "test.c", NULL }, }, { "Some cppflags", "cpp", "-f1 -f2 -f3 -f4-f5", "test.c", "test.out", false, { NULL }, { "cpp", "-f1", "-f2", "-f3", "-f4-f5", "-o", "test.out", "test.c", NULL }, }, { "Some optional arguments", "cpp", "", "test.c", "test.out", true, { "-o1", "-o2", NULL }, { "cpp", "-o1", "-o2", "-o", "test.out", "test.c", NULL }, }, { "Some cppflags and optional arguments", "cpp", "-f1", "test.c", "test.out", true, { "-o1", "-o2", NULL }, { "cpp", "-f1", "-o1", "-o2", "-o", "test.out", "test.c", NULL }, }, { NULL, NULL, NULL, NULL, NULL, false, { NULL }, { NULL }, }, }; static struct cxx_o_test { const char *msg; const char *cxx; const char *cxxflags; const char *cppflags; const char *sfile; const char *ofile; bool hasoptargs; const char *const optargs[16]; const char *const expargv[16]; } cxx_o_tests[] = { { "No flags", "c++", "", "", "test.c", "test.o", false, { NULL }, { "c++", "-o", "test.o", "-c", "test.c", NULL }, }, { "Multi-word program name", "c++ -foo", "", "", "test.c", "test.o", false, { NULL }, { "c++", "-foo", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cxxflags", "c++", "-f1 -f2 -f3 -f4-f5", "", "test.c", "test.o", false, { NULL }, { "c++", "-f1", "-f2", "-f3", "-f4-f5", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cppflags", "c++", "", "-f1 -f2 -f3 -f4-f5", "test.c", "test.o", false, { NULL }, { "c++", "-f1", "-f2", "-f3", "-f4-f5", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cxxflags and cppflags", "c++", "-f2", "-f1", "test.c", "test.o", false, { NULL }, { "c++", "-f1", "-f2", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some optional arguments", "c++", "", "", "test.c", "test.o", true, { "-o1", "-o2", NULL }, { "c++", "-o1", "-o2", "-o", "test.o", "-c", "test.c", NULL }, }, { "Some cxxflags, cppflags and optional arguments", "c++", "-f2", "-f1", "test.c", "test.o", true, { "-o1", "-o2", NULL }, { "c++", "-f1", "-f2", "-o1", "-o2", "-o", "test.o", "-c", "test.c", NULL }, }, { NULL, NULL, NULL, NULL, NULL, NULL, false, { NULL }, { NULL }, }, }; Index: head/contrib/atf/atf-c/macros.h =================================================================== --- head/contrib/atf/atf-c/macros.h (revision 273928) +++ head/contrib/atf/atf-c/macros.h (revision 273929) @@ -1,208 +1,212 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_MACROS_H) #define ATF_C_MACROS_H #include #include #include #include #include #include #define ATF_TC_NAME(tc) \ (atfu_ ## tc ## _tc) #define ATF_TC_PACK_NAME(tc) \ (atfu_ ## tc ## _tc_pack) #define ATF_TC_WITHOUT_HEAD(tc) \ static void atfu_ ## tc ## _body(const atf_tc_t *); \ static atf_tc_t atfu_ ## tc ## _tc; \ static atf_tc_pack_t atfu_ ## tc ## _tc_pack = { \ .m_ident = #tc, \ .m_head = NULL, \ .m_body = atfu_ ## tc ## _body, \ .m_cleanup = NULL, \ } #define ATF_TC(tc) \ static void atfu_ ## tc ## _head(atf_tc_t *); \ static void atfu_ ## tc ## _body(const atf_tc_t *); \ static atf_tc_t atfu_ ## tc ## _tc; \ static atf_tc_pack_t atfu_ ## tc ## _tc_pack = { \ .m_ident = #tc, \ .m_head = atfu_ ## tc ## _head, \ .m_body = atfu_ ## tc ## _body, \ .m_cleanup = NULL, \ } #define ATF_TC_WITH_CLEANUP(tc) \ static void atfu_ ## tc ## _head(atf_tc_t *); \ static void atfu_ ## tc ## _body(const atf_tc_t *); \ static void atfu_ ## tc ## _cleanup(const atf_tc_t *); \ static atf_tc_t atfu_ ## tc ## _tc; \ static atf_tc_pack_t atfu_ ## tc ## _tc_pack = { \ .m_ident = #tc, \ .m_head = atfu_ ## tc ## _head, \ .m_body = atfu_ ## tc ## _body, \ .m_cleanup = atfu_ ## tc ## _cleanup, \ } #define ATF_TC_HEAD(tc, tcptr) \ static \ void \ atfu_ ## tc ## _head(atf_tc_t *tcptr ATF_DEFS_ATTRIBUTE_UNUSED) #define ATF_TC_HEAD_NAME(tc) \ (atfu_ ## tc ## _head) #define ATF_TC_BODY(tc, tcptr) \ static \ void \ atfu_ ## tc ## _body(const atf_tc_t *tcptr ATF_DEFS_ATTRIBUTE_UNUSED) #define ATF_TC_BODY_NAME(tc) \ (atfu_ ## tc ## _body) #define ATF_TC_CLEANUP(tc, tcptr) \ static \ void \ atfu_ ## tc ## _cleanup(const atf_tc_t *tcptr ATF_DEFS_ATTRIBUTE_UNUSED) #define ATF_TC_CLEANUP_NAME(tc) \ (atfu_ ## tc ## _cleanup) #define ATF_TP_ADD_TCS(tps) \ static atf_error_t atfu_tp_add_tcs(atf_tp_t *); \ int atf_tp_main(int, char **, atf_error_t (*)(atf_tp_t *)); \ \ int \ main(int argc, char **argv) \ { \ return atf_tp_main(argc, argv, atfu_tp_add_tcs); \ } \ static \ atf_error_t \ atfu_tp_add_tcs(atf_tp_t *tps) #define ATF_TP_ADD_TC(tp, tc) \ do { \ atf_error_t atfu_err; \ char **atfu_config = atf_tp_get_config(tp); \ if (atfu_config == NULL) \ return atf_no_memory_error(); \ atfu_err = atf_tc_init_pack(&atfu_ ## tc ## _tc, \ &atfu_ ## tc ## _tc_pack, \ (const char *const *)atfu_config); \ atf_utils_free_charpp(atfu_config); \ if (atf_is_error(atfu_err)) \ return atfu_err; \ atfu_err = atf_tp_add_tc(tp, &atfu_ ## tc ## _tc); \ if (atf_is_error(atfu_err)) \ return atfu_err; \ } while (0) -#define ATF_REQUIRE_MSG(x, fmt, ...) \ +#define ATF_REQUIRE_MSG(expression, fmt, ...) \ do { \ - if (!(x)) \ + if (!(expression)) \ atf_tc_fail_requirement(__FILE__, __LINE__, fmt, ##__VA_ARGS__); \ } while(0) -#define ATF_CHECK_MSG(x, fmt, ...) \ +#define ATF_CHECK_MSG(expression, fmt, ...) \ do { \ - if (!(x)) \ + if (!(expression)) \ atf_tc_fail_check(__FILE__, __LINE__, fmt, ##__VA_ARGS__); \ } while(0) -#define ATF_REQUIRE(x) \ +#define ATF_REQUIRE(expression) \ do { \ - if (!(x)) \ - atf_tc_fail_requirement(__FILE__, __LINE__, "%s", #x " not met"); \ + if (!(expression)) \ + atf_tc_fail_requirement(__FILE__, __LINE__, "%s", \ + #expression " not met"); \ } while(0) -#define ATF_CHECK(x) \ +#define ATF_CHECK(expression) \ do { \ - if (!(x)) \ - atf_tc_fail_check(__FILE__, __LINE__, "%s", #x " not met"); \ + if (!(expression)) \ + atf_tc_fail_check(__FILE__, __LINE__, "%s", \ + #expression " not met"); \ } while(0) -#define ATF_REQUIRE_EQ(x, y) \ - ATF_REQUIRE_MSG((x) == (y), "%s != %s", #x, #y) +#define ATF_REQUIRE_EQ(expected, actual) \ + ATF_REQUIRE_MSG((expected) == (actual), "%s != %s", #expected, #actual) -#define ATF_CHECK_EQ(x, y) \ - ATF_CHECK_MSG((x) == (y), "%s != %s", #x, #y) +#define ATF_CHECK_EQ(expected, actual) \ + ATF_CHECK_MSG((expected) == (actual), "%s != %s", #expected, #actual) -#define ATF_REQUIRE_EQ_MSG(x, y, fmt, ...) \ - ATF_REQUIRE_MSG((x) == (y), "%s != %s: " fmt, #x, #y, ##__VA_ARGS__) +#define ATF_REQUIRE_EQ_MSG(expected, actual, fmt, ...) \ + ATF_REQUIRE_MSG((expected) == (actual), "%s != %s: " fmt, \ + #expected, #actual, ##__VA_ARGS__) -#define ATF_CHECK_EQ_MSG(x, y, fmt, ...) \ - ATF_CHECK_MSG((x) == (y), "%s != %s: " fmt, #x, #y, ##__VA_ARGS__) +#define ATF_CHECK_EQ_MSG(expected, actual, fmt, ...) \ + ATF_CHECK_MSG((expected) == (actual), "%s != %s: " fmt, \ + #expected, #actual, ##__VA_ARGS__) -#define ATF_REQUIRE_STREQ(x, y) \ - ATF_REQUIRE_MSG(strcmp(x, y) == 0, "%s != %s (%s != %s)", #x, #y, x, y) +#define ATF_REQUIRE_STREQ(expected, actual) \ + ATF_REQUIRE_MSG(strcmp(expected, actual) == 0, "%s != %s (%s != %s)", \ + #expected, #actual, expected, actual) -#define ATF_CHECK_STREQ(x, y) \ - ATF_CHECK_MSG(strcmp(x, y) == 0, "%s != %s (%s != %s)", #x, #y, x, y) +#define ATF_CHECK_STREQ(expected, actual) \ + ATF_CHECK_MSG(strcmp(expected, actual) == 0, "%s != %s (%s != %s)", \ + #expected, #actual, expected, actual) -#define ATF_REQUIRE_STREQ_MSG(x, y, fmt, ...) \ - ATF_REQUIRE_MSG(strcmp(x, y) == 0, "%s != %s (%s != %s): " fmt, \ - #x, #y, x, y, ##__VA_ARGS__) +#define ATF_REQUIRE_STREQ_MSG(expected, actual, fmt, ...) \ + ATF_REQUIRE_MSG(strcmp(expected, actual) == 0, \ + "%s != %s (%s != %s): " fmt, \ + #expected, #actual, expected, actual, ##__VA_ARGS__) -#define ATF_CHECK_STREQ_MSG(x, y, fmt, ...) \ - ATF_CHECK_MSG(strcmp(x, y) == 0, "%s != %s (%s != %s): " fmt, \ - #x, #y, x, y, ##__VA_ARGS__) +#define ATF_CHECK_STREQ_MSG(expected, actual, fmt, ...) \ + ATF_CHECK_MSG(strcmp(expected, actual) == 0, \ + "%s != %s (%s != %s): " fmt, \ + #expected, #actual, expected, actual, ##__VA_ARGS__) #define ATF_REQUIRE_MATCH(regexp, string) \ ATF_REQUIRE_MSG(atf_utils_grep_string("%s", string, regexp), \ "'%s' not matched in '%s'", regexp, string); #define ATF_CHECK_MATCH(regexp, string) \ ATF_CHECK_MSG(atf_utils_grep_string("%s", string, regexp), \ "'%s' not matched in '%s'", regexp, string); #define ATF_REQUIRE_MATCH_MSG(regexp, string, fmt, ...) \ ATF_REQUIRE_MSG(atf_utils_grep_string("%s", string, regexp), \ "'%s' not matched in '%s': " fmt, regexp, string, \ ##__VA_ARGS__); #define ATF_CHECK_MATCH_MSG(regexp, string, fmt, ...) \ ATF_CHECK_MSG(atf_utils_grep_string("%s", string, regexp), \ "'%s' not matched in '%s': " fmt, regexp, string, \ ##__VA_ARGS__); #define ATF_CHECK_ERRNO(exp_errno, bool_expr) \ atf_tc_check_errno(__FILE__, __LINE__, exp_errno, #bool_expr, bool_expr) #define ATF_REQUIRE_ERRNO(exp_errno, bool_expr) \ atf_tc_require_errno(__FILE__, __LINE__, exp_errno, #bool_expr, bool_expr) #endif /* !defined(ATF_C_MACROS_H) */ Index: head/contrib/atf/atf-c/macros_h_test.c =================================================================== --- head/contrib/atf/atf-c/macros_h_test.c (revision 273928) +++ head/contrib/atf/atf-c/macros_h_test.c (revision 273929) @@ -1,106 +1,102 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include void atf_require_inside_if(void); void atf_require_equal_inside_if(void); void atf_check_errno_semicolons(void); void atf_require_errno_semicolons(void); void atf_require_inside_if(void) { /* Make sure that ATF_REQUIRE can be used inside an if statement that * does not have braces. Earlier versions of it generated an error * if there was an else clause because they confused the compiler * by defining an unprotected nested if. */ if (true) ATF_REQUIRE(true); else ATF_REQUIRE(true); } void atf_require_equal_inside_if(void) { /* Make sure that ATF_REQUIRE_EQUAL can be used inside an if statement * that does not have braces. Earlier versions of it generated an * error if there was an else clause because they confused the * compiler by defining an unprotected nested if. */ if (true) ATF_REQUIRE_EQ(true, true); else ATF_REQUIRE_EQ(true, true); } void atf_check_errno_semicolons(void) { /* Check that ATF_CHECK_ERRNO does not contain a semicolon that would * cause an empty-statement that confuses some compilers. */ ATF_CHECK_ERRNO(1, 1 == 1); ATF_CHECK_ERRNO(2, 2 == 2); } void atf_require_errno_semicolons(void) { /* Check that ATF_REQUIRE_ERRNO does not contain a semicolon that would * cause an empty-statement that confuses some compilers. */ ATF_REQUIRE_ERRNO(1, 1 == 1); ATF_REQUIRE_ERRNO(2, 2 == 2); } /* Test case names should not be expanded during instatiation so that they * can have the exact same name as macros. */ #define TEST_MACRO_1 invalid + name #define TEST_MACRO_2 invalid + name #define TEST_MACRO_3 invalid + name ATF_TC(TEST_MACRO_1); ATF_TC_HEAD(TEST_MACRO_1, tc) { if (tc != NULL) {} } ATF_TC_BODY(TEST_MACRO_1, tc) { if (tc != NULL) {} } atf_tc_t *test_name_1 = &ATF_TC_NAME(TEST_MACRO_1); atf_tc_pack_t *test_pack_1 = &ATF_TC_PACK_NAME(TEST_MACRO_1); void (*head_1)(atf_tc_t *) = ATF_TC_HEAD_NAME(TEST_MACRO_1); void (*body_1)(const atf_tc_t *) = ATF_TC_BODY_NAME(TEST_MACRO_1); ATF_TC_WITH_CLEANUP(TEST_MACRO_2); ATF_TC_HEAD(TEST_MACRO_2, tc) { if (tc != NULL) {} } ATF_TC_BODY(TEST_MACRO_2, tc) { if (tc != NULL) {} } ATF_TC_CLEANUP(TEST_MACRO_2, tc) { if (tc != NULL) {} } atf_tc_t *test_name_2 = &ATF_TC_NAME(TEST_MACRO_2); atf_tc_pack_t *test_pack_2 = &ATF_TC_PACK_NAME(TEST_MACRO_2); void (*head_2)(atf_tc_t *) = ATF_TC_HEAD_NAME(TEST_MACRO_2); void (*body_2)(const atf_tc_t *) = ATF_TC_BODY_NAME(TEST_MACRO_2); void (*cleanup_2)(const atf_tc_t *) = ATF_TC_CLEANUP_NAME(TEST_MACRO_2); ATF_TC_WITHOUT_HEAD(TEST_MACRO_3); ATF_TC_BODY(TEST_MACRO_3, tc) { if (tc != NULL) {} } atf_tc_t *test_name_3 = &ATF_TC_NAME(TEST_MACRO_3); atf_tc_pack_t *test_pack_3 = &ATF_TC_PACK_NAME(TEST_MACRO_3); void (*body_3)(const atf_tc_t *) = ATF_TC_BODY_NAME(TEST_MACRO_3); Index: head/contrib/atf/atf-c/macros_test.c =================================================================== --- head/contrib/atf/atf-c/macros_test.c (revision 273928) +++ head/contrib/atf/atf-c/macros_test.c (revision 273929) @@ -1,897 +1,893 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/macros.h" + #include #include #include #include #include #include #include #include #include #include #include -#include "detail/fs.h" -#include "detail/process.h" -#include "detail/test_helpers.h" -#include "detail/text.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/process.h" +#include "atf-c/detail/test_helpers.h" +#include "atf-c/detail/text.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void create_ctl_file(const char *name) { atf_fs_path_t p; RE(atf_fs_path_init_fmt(&p, "%s", name)); ATF_REQUIRE(open(atf_fs_path_cstring(&p), O_CREAT | O_WRONLY | O_TRUNC, 0644) != -1); atf_fs_path_fini(&p); } static bool exists(const char *p) { bool b; atf_fs_path_t pp; RE(atf_fs_path_init_fmt(&pp, "%s", p)); RE(atf_fs_exists(&pp, &b)); atf_fs_path_fini(&pp); return b; } static void init_and_run_h_tc(const char *name, void (*head)(atf_tc_t *), void (*body)(const atf_tc_t *)) { atf_tc_t tc; const char *const config[] = { NULL }; RE(atf_tc_init(&tc, name, head, body, NULL, config)); run_h_tc(&tc, "output", "error", "result"); atf_tc_fini(&tc); } /* --------------------------------------------------------------------- * Helper test cases. * --------------------------------------------------------------------- */ #define H_DEF(id, macro) \ ATF_TC_HEAD(h_ ## id, tc) \ { \ atf_tc_set_md_var(tc, "descr", "Helper test case"); \ } \ ATF_TC_BODY(h_ ## id, tc) \ { \ create_ctl_file("before"); \ macro; \ create_ctl_file("after"); \ } #define H_CHECK_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_ ## id) #define H_CHECK_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_ ## id) #define H_CHECK(id, condition) \ H_DEF(check_ ## id, ATF_CHECK(condition)) #define H_CHECK_MSG_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_msg_ ## id) #define H_CHECK_MSG_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_msg_ ## id) #define H_CHECK_MSG(id, condition, msg) \ H_DEF(check_msg_ ## id, ATF_CHECK_MSG(condition, msg)) #define H_CHECK_EQ_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_eq_ ## id) #define H_CHECK_EQ_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_eq_ ## id) #define H_CHECK_EQ(id, v1, v2) \ H_DEF(check_eq_ ## id, ATF_CHECK_EQ(v1, v2)) #define H_CHECK_STREQ_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_streq_ ## id) #define H_CHECK_STREQ_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_streq_ ## id) #define H_CHECK_STREQ(id, v1, v2) \ H_DEF(check_streq_ ## id, ATF_CHECK_STREQ(v1, v2)) #define H_CHECK_MATCH_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_match_ ## id) #define H_CHECK_MATCH_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_match_ ## id) #define H_CHECK_MATCH(id, v1, v2) \ H_DEF(check_match_ ## id, ATF_CHECK_MATCH(v1, v2)) #define H_CHECK_EQ_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_check_eq_msg_ ## id) #define H_CHECK_EQ_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_check_eq_msg_ ## id) #define H_CHECK_EQ_MSG(id, v1, v2, msg) \ H_DEF(check_eq_msg_ ## id, ATF_CHECK_EQ_MSG(v1, v2, msg)) #define H_CHECK_STREQ_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_check_streq_msg_ ## id) #define H_CHECK_STREQ_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_check_streq_msg_ ## id) #define H_CHECK_STREQ_MSG(id, v1, v2, msg) \ H_DEF(check_streq_msg_ ## id, ATF_CHECK_STREQ_MSG(v1, v2, msg)) #define H_CHECK_MATCH_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_check_match_msg_ ## id) #define H_CHECK_MATCH_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_check_match_msg_ ## id) #define H_CHECK_MATCH_MSG(id, v1, v2, msg) \ H_DEF(check_match_msg_ ## id, ATF_CHECK_MATCH_MSG(v1, v2, msg)) #define H_CHECK_ERRNO_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_check_errno_ ## id) #define H_CHECK_ERRNO_BODY_NAME(id) ATF_TC_BODY_NAME(h_check_errno_ ## id) #define H_CHECK_ERRNO(id, exp_errno, bool_expr) \ H_DEF(check_errno_ ## id, ATF_CHECK_ERRNO(exp_errno, bool_expr)) #define H_REQUIRE_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_ ## id) #define H_REQUIRE_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_ ## id) #define H_REQUIRE(id, condition) \ H_DEF(require_ ## id, ATF_REQUIRE(condition)) #define H_REQUIRE_MSG_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_msg_ ## id) #define H_REQUIRE_MSG_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_msg_ ## id) #define H_REQUIRE_MSG(id, condition, msg) \ H_DEF(require_msg_ ## id, ATF_REQUIRE_MSG(condition, msg)) #define H_REQUIRE_EQ_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_eq_ ## id) #define H_REQUIRE_EQ_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_eq_ ## id) #define H_REQUIRE_EQ(id, v1, v2) \ H_DEF(require_eq_ ## id, ATF_REQUIRE_EQ(v1, v2)) #define H_REQUIRE_STREQ_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_streq_ ## id) #define H_REQUIRE_STREQ_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_streq_ ## id) #define H_REQUIRE_STREQ(id, v1, v2) \ H_DEF(require_streq_ ## id, ATF_REQUIRE_STREQ(v1, v2)) #define H_REQUIRE_MATCH_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_match_ ## id) #define H_REQUIRE_MATCH_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_match_ ## id) #define H_REQUIRE_MATCH(id, v1, v2) \ H_DEF(require_match_ ## id, ATF_REQUIRE_MATCH(v1, v2)) #define H_REQUIRE_EQ_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_require_eq_msg_ ## id) #define H_REQUIRE_EQ_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_require_eq_msg_ ## id) #define H_REQUIRE_EQ_MSG(id, v1, v2, msg) \ H_DEF(require_eq_msg_ ## id, ATF_REQUIRE_EQ_MSG(v1, v2, msg)) #define H_REQUIRE_STREQ_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_require_streq_msg_ ## id) #define H_REQUIRE_STREQ_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_require_streq_msg_ ## id) #define H_REQUIRE_STREQ_MSG(id, v1, v2, msg) \ H_DEF(require_streq_msg_ ## id, ATF_REQUIRE_STREQ_MSG(v1, v2, msg)) #define H_REQUIRE_MATCH_MSG_HEAD_NAME(id) \ ATF_TC_HEAD_NAME(h_require_match_msg_ ## id) #define H_REQUIRE_MATCH_MSG_BODY_NAME(id) \ ATF_TC_BODY_NAME(h_require_match_msg_ ## id) #define H_REQUIRE_MATCH_MSG(id, v1, v2, msg) \ H_DEF(require_match_msg_ ## id, ATF_REQUIRE_MATCH_MSG(v1, v2, msg)) #define H_REQUIRE_ERRNO_HEAD_NAME(id) ATF_TC_HEAD_NAME(h_require_errno_ ## id) #define H_REQUIRE_ERRNO_BODY_NAME(id) ATF_TC_BODY_NAME(h_require_errno_ ## id) #define H_REQUIRE_ERRNO(id, exp_errno, bool_expr) \ H_DEF(require_errno_ ## id, ATF_REQUIRE_ERRNO(exp_errno, bool_expr)) /* --------------------------------------------------------------------- * Test cases for the ATF_{CHECK,REQUIRE}_ERRNO macros. * --------------------------------------------------------------------- */ static int errno_fail_stub(const int raised_errno) { errno = raised_errno; return -1; } static int errno_ok_stub(void) { return 0; } H_CHECK_ERRNO(no_error, -1, errno_ok_stub() == -1); H_CHECK_ERRNO(errno_ok, 2, errno_fail_stub(2) == -1); H_CHECK_ERRNO(errno_fail, 3, errno_fail_stub(4) == -1); H_REQUIRE_ERRNO(no_error, -1, errno_ok_stub() == -1); H_REQUIRE_ERRNO(errno_ok, 2, errno_fail_stub(2) == -1); H_REQUIRE_ERRNO(errno_fail, 3, errno_fail_stub(4) == -1); ATF_TC(check_errno); ATF_TC_HEAD(check_errno, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_CHECK_ERRNO macro"); } ATF_TC_BODY(check_errno, tc) { struct test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); bool ok; const char *exp_regex; } *t, tests[] = { { H_CHECK_ERRNO_HEAD_NAME(no_error), H_CHECK_ERRNO_BODY_NAME(no_error), false, "Expected true value in errno_ok_stub\\(\\) == -1" }, { H_CHECK_ERRNO_HEAD_NAME(errno_ok), H_CHECK_ERRNO_BODY_NAME(errno_ok), true, NULL }, { H_CHECK_ERRNO_HEAD_NAME(errno_fail), H_CHECK_ERRNO_BODY_NAME(errno_fail), false, "Expected errno 3, got 4, in errno_fail_stub\\(4\\) == -1" }, { NULL, NULL, false, NULL } }; for (t = &tests[0]; t->head != NULL; t++) { init_and_run_h_tc("h_check_errno", t->head, t->body); ATF_REQUIRE(exists("before")); ATF_REQUIRE(exists("after")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); } else { ATF_REQUIRE(atf_utils_grep_file("^failed", "result")); ATF_REQUIRE(atf_utils_grep_file( "macros_test.c:[0-9]+: %s$", "error", t->exp_regex)); } ATF_REQUIRE(unlink("before") != -1); ATF_REQUIRE(unlink("after") != -1); } } ATF_TC(require_errno); ATF_TC_HEAD(require_errno, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_REQUIRE_ERRNO macro"); } ATF_TC_BODY(require_errno, tc) { struct test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); bool ok; const char *exp_regex; } *t, tests[] = { { H_REQUIRE_ERRNO_HEAD_NAME(no_error), H_REQUIRE_ERRNO_BODY_NAME(no_error), false, "Expected true value in errno_ok_stub\\(\\) == -1" }, { H_REQUIRE_ERRNO_HEAD_NAME(errno_ok), H_REQUIRE_ERRNO_BODY_NAME(errno_ok), true, NULL }, { H_REQUIRE_ERRNO_HEAD_NAME(errno_fail), H_REQUIRE_ERRNO_BODY_NAME(errno_fail), false, "Expected errno 3, got 4, in errno_fail_stub\\(4\\) == -1" }, { NULL, NULL, false, NULL } }; for (t = &tests[0]; t->head != NULL; t++) { init_and_run_h_tc("h_require_errno", t->head, t->body); ATF_REQUIRE(exists("before")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); ATF_REQUIRE(exists("after")); } else { ATF_REQUIRE(atf_utils_grep_file( "^failed: .*macros_test.c:[0-9]+: %s$", "result", t->exp_regex)); ATF_REQUIRE(!exists("after")); } ATF_REQUIRE(unlink("before") != -1); if (t->ok) ATF_REQUIRE(unlink("after") != -1); } } /* --------------------------------------------------------------------- * Test cases for the ATF_CHECK and ATF_CHECK_MSG macros. * --------------------------------------------------------------------- */ H_CHECK(0, 0); H_CHECK(1, 1); H_CHECK_MSG(0, 0, "expected a false value"); H_CHECK_MSG(1, 1, "expected a true value"); ATF_TC(check); ATF_TC_HEAD(check, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_CHECK and " "ATF_CHECK_MSG macros"); } ATF_TC_BODY(check, tc) { struct test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); bool value; const char *msg; bool ok; } *t, tests[] = { { H_CHECK_HEAD_NAME(0), H_CHECK_BODY_NAME(0), 0, "0 not met", false }, { H_CHECK_HEAD_NAME(1), H_CHECK_BODY_NAME(1), 1, "1 not met", true }, { H_CHECK_MSG_HEAD_NAME(0), H_CHECK_MSG_BODY_NAME(0), 0, "expected a false value", false }, { H_CHECK_MSG_HEAD_NAME(1), H_CHECK_MSG_BODY_NAME(1), 1, "expected a true value", true }, { NULL, NULL, false, NULL, false } }; for (t = &tests[0]; t->head != NULL; t++) { printf("Checking with a %d value\n", t->value); init_and_run_h_tc("h_check", t->head, t->body); ATF_REQUIRE(exists("before")); ATF_REQUIRE(exists("after")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); } else { ATF_REQUIRE(atf_utils_grep_file("^failed", "result")); ATF_REQUIRE(atf_utils_grep_file("Check failed: .*" "macros_test.c:[0-9]+: %s$", "error", t->msg)); } ATF_REQUIRE(unlink("before") != -1); ATF_REQUIRE(unlink("after") != -1); } } /* --------------------------------------------------------------------- * Test cases for the ATF_CHECK_*EQ_ macros. * --------------------------------------------------------------------- */ struct check_eq_test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); const char *v1; const char *v2; const char *msg; bool ok; }; static void do_check_eq_tests(const struct check_eq_test *tests) { const struct check_eq_test *t; for (t = &tests[0]; t->head != NULL; t++) { printf("Checking with %s, %s and expecting %s\n", t->v1, t->v2, t->ok ? "true" : "false"); init_and_run_h_tc("h_check", t->head, t->body); ATF_CHECK(exists("before")); ATF_CHECK(exists("after")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); } else { ATF_REQUIRE(atf_utils_grep_file("^failed", "result")); ATF_CHECK(atf_utils_grep_file("Check failed: .*" "macros_test.c:[0-9]+: %s$", "error", t->msg)); } ATF_CHECK(unlink("before") != -1); ATF_CHECK(unlink("after") != -1); } } H_CHECK_EQ(1_1, 1, 1); H_CHECK_EQ(1_2, 1, 2); H_CHECK_EQ(2_1, 2, 1); H_CHECK_EQ(2_2, 2, 2); H_CHECK_EQ_MSG(1_1, 1, 1, "1 does not match 1"); H_CHECK_EQ_MSG(1_2, 1, 2, "1 does not match 2"); H_CHECK_EQ_MSG(2_1, 2, 1, "2 does not match 1"); H_CHECK_EQ_MSG(2_2, 2, 2, "2 does not match 2"); ATF_TC(check_eq); ATF_TC_HEAD(check_eq, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_CHECK_EQ and " "ATF_CHECK_EQ_MSG macros"); } ATF_TC_BODY(check_eq, tc) { struct check_eq_test tests[] = { { H_CHECK_EQ_HEAD_NAME(1_1), H_CHECK_EQ_BODY_NAME(1_1), "1", "1", "1 != 1", true }, { H_CHECK_EQ_HEAD_NAME(1_2), H_CHECK_EQ_BODY_NAME(1_2), "1", "2", "1 != 2", false }, { H_CHECK_EQ_HEAD_NAME(2_1), H_CHECK_EQ_BODY_NAME(2_1), "2", "1", "2 != 1", false }, { H_CHECK_EQ_HEAD_NAME(2_2), H_CHECK_EQ_BODY_NAME(2_2), "2", "2", "2 != 2", true }, { H_CHECK_EQ_MSG_HEAD_NAME(1_1), H_CHECK_EQ_MSG_BODY_NAME(1_1), "1", "1", "1 != 1: 1 does not match 1", true }, { H_CHECK_EQ_MSG_HEAD_NAME(1_2), H_CHECK_EQ_MSG_BODY_NAME(1_2), "1", "2", "1 != 2: 1 does not match 2", false }, { H_CHECK_EQ_MSG_HEAD_NAME(2_1), H_CHECK_EQ_MSG_BODY_NAME(2_1), "2", "1", "2 != 1: 2 does not match 1", false }, { H_CHECK_EQ_MSG_HEAD_NAME(2_2), H_CHECK_EQ_MSG_BODY_NAME(2_2), "2", "2", "2 != 2: 2 does not match 2", true }, { NULL, NULL, 0, 0, "", false } }; do_check_eq_tests(tests); } H_CHECK_STREQ(1_1, "1", "1"); H_CHECK_STREQ(1_2, "1", "2"); H_CHECK_STREQ(2_1, "2", "1"); H_CHECK_STREQ(2_2, "2", "2"); H_CHECK_STREQ_MSG(1_1, "1", "1", "1 does not match 1"); H_CHECK_STREQ_MSG(1_2, "1", "2", "1 does not match 2"); H_CHECK_STREQ_MSG(2_1, "2", "1", "2 does not match 1"); H_CHECK_STREQ_MSG(2_2, "2", "2", "2 does not match 2"); #define CHECK_STREQ_VAR1 "5" #define CHECK_STREQ_VAR2 "9" const char *check_streq_var1 = CHECK_STREQ_VAR1; const char *check_streq_var2 = CHECK_STREQ_VAR2; H_CHECK_STREQ(vars, check_streq_var1, check_streq_var2); ATF_TC(check_streq); ATF_TC_HEAD(check_streq, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_CHECK_STREQ and " "ATF_CHECK_STREQ_MSG macros"); } ATF_TC_BODY(check_streq, tc) { struct check_eq_test tests[] = { { H_CHECK_STREQ_HEAD_NAME(1_1), H_CHECK_STREQ_BODY_NAME(1_1), "1", "1", "\"1\" != \"1\" \\(1 != 1\\)", true }, { H_CHECK_STREQ_HEAD_NAME(1_2), H_CHECK_STREQ_BODY_NAME(1_2), "1", "2", "\"1\" != \"2\" \\(1 != 2\\)", false }, { H_CHECK_STREQ_HEAD_NAME(2_1), H_CHECK_STREQ_BODY_NAME(2_1), "2", "1", "\"2\" != \"1\" \\(2 != 1\\)", false }, { H_CHECK_STREQ_HEAD_NAME(2_2), H_CHECK_STREQ_BODY_NAME(2_2), "2", "2", "\"2\" != \"2\" \\(2 != 2\\)", true }, { H_CHECK_STREQ_MSG_HEAD_NAME(1_1), H_CHECK_STREQ_MSG_BODY_NAME(1_1), "1", "1", "\"1\" != \"1\" \\(1 != 1\\): 1 does not match 1", true }, { H_CHECK_STREQ_MSG_HEAD_NAME(1_2), H_CHECK_STREQ_MSG_BODY_NAME(1_2), "1", "2", "\"1\" != \"2\" \\(1 != 2\\): 1 does not match 2", false }, { H_CHECK_STREQ_MSG_HEAD_NAME(2_1), H_CHECK_STREQ_MSG_BODY_NAME(2_1), "2", "1", "\"2\" != \"1\" \\(2 != 1\\): 2 does not match 1", false }, { H_CHECK_STREQ_MSG_HEAD_NAME(2_2), H_CHECK_STREQ_MSG_BODY_NAME(2_2), "2", "2", "\"2\" != \"2\" \\(2 != 2\\): 2 does not match 2", true }, { H_CHECK_STREQ_HEAD_NAME(vars), H_CHECK_STREQ_BODY_NAME(vars), check_streq_var1, check_streq_var2, "check_streq_var1 != check_streq_var2 \\(" CHECK_STREQ_VAR1 " != " CHECK_STREQ_VAR2 "\\)", false }, { NULL, NULL, 0, 0, "", false } }; do_check_eq_tests(tests); } /* --------------------------------------------------------------------- * Test cases for the ATF_CHECK_MATCH and ATF_CHECK_MATCH_MSG macros. * --------------------------------------------------------------------- */ H_CHECK_MATCH(yes, "hello [a-z]+", "abc hello world"); H_CHECK_MATCH(no, "hello [a-z]+", "abc hello WORLD"); H_CHECK_MATCH_MSG(yes, "hello [a-z]+", "abc hello world", "lowercase"); H_CHECK_MATCH_MSG(no, "hello [a-z]+", "abc hello WORLD", "uppercase"); ATF_TC(check_match); ATF_TC_HEAD(check_match, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_CHECK_MATCH and " "ATF_CHECK_MATCH_MSG macros"); } ATF_TC_BODY(check_match, tc) { struct check_eq_test tests[] = { { H_CHECK_MATCH_HEAD_NAME(yes), H_CHECK_MATCH_BODY_NAME(yes), "hello [a-z]+", "abc hello world", "", true }, { H_CHECK_MATCH_HEAD_NAME(no), H_CHECK_MATCH_BODY_NAME(no), "hello [a-z]+", "abc hello WORLD", "'hello \\[a-z\\]\\+' not matched in 'abc hello WORLD'", false }, { H_CHECK_MATCH_MSG_HEAD_NAME(yes), H_CHECK_MATCH_MSG_BODY_NAME(yes), "hello [a-z]+", "abc hello world", "", true }, { H_CHECK_MATCH_MSG_HEAD_NAME(no), H_CHECK_MATCH_MSG_BODY_NAME(no), "hello [a-z]+", "abc hello WORLD", "'hello \\[a-z\\]\\+' not matched in 'abc hello WORLD': uppercase", false }, { NULL, NULL, 0, 0, "", false } }; do_check_eq_tests(tests); } /* --------------------------------------------------------------------- * Test cases for the ATF_REQUIRE and ATF_REQUIRE_MSG macros. * --------------------------------------------------------------------- */ H_REQUIRE(0, 0); H_REQUIRE(1, 1); H_REQUIRE_MSG(0, 0, "expected a false value"); H_REQUIRE_MSG(1, 1, "expected a true value"); ATF_TC(require); ATF_TC_HEAD(require, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_REQUIRE and " "ATF_REQUIRE_MSG macros"); } ATF_TC_BODY(require, tc) { struct test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); bool value; const char *msg; bool ok; } *t, tests[] = { { H_REQUIRE_HEAD_NAME(0), H_REQUIRE_BODY_NAME(0), 0, "0 not met", false }, { H_REQUIRE_HEAD_NAME(1), H_REQUIRE_BODY_NAME(1), 1, "1 not met", true }, { H_REQUIRE_MSG_HEAD_NAME(0), H_REQUIRE_MSG_BODY_NAME(0), 0, "expected a false value", false }, { H_REQUIRE_MSG_HEAD_NAME(1), H_REQUIRE_MSG_BODY_NAME(1), 1, "expected a true value", true }, { NULL, NULL, false, NULL, false } }; for (t = &tests[0]; t->head != NULL; t++) { printf("Checking with a %d value\n", t->value); init_and_run_h_tc("h_require", t->head, t->body); ATF_REQUIRE(exists("before")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); ATF_REQUIRE(exists("after")); } else { ATF_REQUIRE(atf_utils_grep_file( "^failed: .*macros_test.c:[0-9]+: %s$", "result", t->msg)); ATF_REQUIRE(!exists("after")); } ATF_REQUIRE(unlink("before") != -1); if (t->ok) ATF_REQUIRE(unlink("after") != -1); } } /* --------------------------------------------------------------------- * Test cases for the ATF_REQUIRE_*EQ_ macros. * --------------------------------------------------------------------- */ struct require_eq_test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); const char *v1; const char *v2; const char *msg; bool ok; }; static void do_require_eq_tests(const struct require_eq_test *tests) { const struct require_eq_test *t; for (t = &tests[0]; t->head != NULL; t++) { printf("Checking with %s, %s and expecting %s\n", t->v1, t->v2, t->ok ? "true" : "false"); init_and_run_h_tc("h_require", t->head, t->body); ATF_REQUIRE(exists("before")); if (t->ok) { ATF_REQUIRE(atf_utils_grep_file("^passed", "result")); ATF_REQUIRE(exists("after")); } else { ATF_REQUIRE(atf_utils_grep_file("^failed: .*macros_test.c" ":[0-9]+: %s$", "result", t->msg)); ATF_REQUIRE(!exists("after")); } ATF_REQUIRE(unlink("before") != -1); if (t->ok) ATF_REQUIRE(unlink("after") != -1); } } H_REQUIRE_EQ(1_1, 1, 1); H_REQUIRE_EQ(1_2, 1, 2); H_REQUIRE_EQ(2_1, 2, 1); H_REQUIRE_EQ(2_2, 2, 2); H_REQUIRE_EQ_MSG(1_1, 1, 1, "1 does not match 1"); H_REQUIRE_EQ_MSG(1_2, 1, 2, "1 does not match 2"); H_REQUIRE_EQ_MSG(2_1, 2, 1, "2 does not match 1"); H_REQUIRE_EQ_MSG(2_2, 2, 2, "2 does not match 2"); ATF_TC(require_eq); ATF_TC_HEAD(require_eq, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_REQUIRE_EQ and " "ATF_REQUIRE_EQ_MSG macros"); } ATF_TC_BODY(require_eq, tc) { struct require_eq_test tests[] = { { H_REQUIRE_EQ_HEAD_NAME(1_1), H_REQUIRE_EQ_BODY_NAME(1_1), "1", "1", "1 != 1", true }, { H_REQUIRE_EQ_HEAD_NAME(1_2), H_REQUIRE_EQ_BODY_NAME(1_2), "1", "2", "1 != 2", false }, { H_REQUIRE_EQ_HEAD_NAME(2_1), H_REQUIRE_EQ_BODY_NAME(2_1), "2", "1", "2 != 1", false }, { H_REQUIRE_EQ_HEAD_NAME(2_2), H_REQUIRE_EQ_BODY_NAME(2_2), "2", "2", "2 != 2", true }, { H_REQUIRE_EQ_MSG_HEAD_NAME(1_1), H_REQUIRE_EQ_MSG_BODY_NAME(1_1), "1", "1", "1 != 1: 1 does not match 1", true }, { H_REQUIRE_EQ_MSG_HEAD_NAME(1_2), H_REQUIRE_EQ_MSG_BODY_NAME(1_2), "1", "2", "1 != 2: 1 does not match 2", false }, { H_REQUIRE_EQ_MSG_HEAD_NAME(2_1), H_REQUIRE_EQ_MSG_BODY_NAME(2_1), "2", "1", "2 != 1: 2 does not match 1", false }, { H_REQUIRE_EQ_MSG_HEAD_NAME(2_2), H_REQUIRE_EQ_MSG_BODY_NAME(2_2), "2", "2", "2 != 2: 2 does not match 2", true }, { NULL, NULL, 0, 0, "", false } }; do_require_eq_tests(tests); } H_REQUIRE_STREQ(1_1, "1", "1"); H_REQUIRE_STREQ(1_2, "1", "2"); H_REQUIRE_STREQ(2_1, "2", "1"); H_REQUIRE_STREQ(2_2, "2", "2"); H_REQUIRE_STREQ_MSG(1_1, "1", "1", "1 does not match 1"); H_REQUIRE_STREQ_MSG(1_2, "1", "2", "1 does not match 2"); H_REQUIRE_STREQ_MSG(2_1, "2", "1", "2 does not match 1"); H_REQUIRE_STREQ_MSG(2_2, "2", "2", "2 does not match 2"); #define REQUIRE_STREQ_VAR1 "5" #define REQUIRE_STREQ_VAR2 "9" const char *require_streq_var1 = REQUIRE_STREQ_VAR1; const char *require_streq_var2 = REQUIRE_STREQ_VAR2; H_REQUIRE_STREQ(vars, require_streq_var1, require_streq_var2); ATF_TC(require_streq); ATF_TC_HEAD(require_streq, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_REQUIRE_STREQ and " "ATF_REQUIRE_STREQ_MSG macros"); } ATF_TC_BODY(require_streq, tc) { struct require_eq_test tests[] = { { H_REQUIRE_STREQ_HEAD_NAME(1_1), H_REQUIRE_STREQ_BODY_NAME(1_1), "1", "1", "\"1\" != \"1\" \\(1 != 1\\)", true }, { H_REQUIRE_STREQ_HEAD_NAME(1_2), H_REQUIRE_STREQ_BODY_NAME(1_2), "1", "2", "\"1\" != \"2\" \\(1 != 2\\)", false }, { H_REQUIRE_STREQ_HEAD_NAME(2_1), H_REQUIRE_STREQ_BODY_NAME(2_1), "2", "1", "\"2\" != \"1\" \\(2 != 1\\)", false }, { H_REQUIRE_STREQ_HEAD_NAME(2_2), H_REQUIRE_STREQ_BODY_NAME(2_2), "2", "2", "\"2\" != \"2\" \\(2 != 2\\)", true }, { H_REQUIRE_STREQ_MSG_HEAD_NAME(1_1), H_REQUIRE_STREQ_MSG_BODY_NAME(1_1), "1", "1", "\"1\" != \"1\" \\(1 != 1\\): 1 does not match 1", true }, { H_REQUIRE_STREQ_MSG_HEAD_NAME(1_2), H_REQUIRE_STREQ_MSG_BODY_NAME(1_2), "1", "2", "\"1\" != \"2\" \\(1 != 2\\): 1 does not match 2", false }, { H_REQUIRE_STREQ_MSG_HEAD_NAME(2_1), H_REQUIRE_STREQ_MSG_BODY_NAME(2_1), "2", "1", "\"2\" != \"1\" \\(2 != 1\\): 2 does not match 1", false }, { H_REQUIRE_STREQ_MSG_HEAD_NAME(2_2), H_REQUIRE_STREQ_MSG_BODY_NAME(2_2), "2", "2", "\"2\" != \"2\" \\(2 != 2\\): 2 does not match 2", true }, { H_REQUIRE_STREQ_HEAD_NAME(vars), H_REQUIRE_STREQ_BODY_NAME(vars), require_streq_var1, require_streq_var2, "require_streq_var1 != require_streq_var2 \\(" REQUIRE_STREQ_VAR1 " != " REQUIRE_STREQ_VAR2 "\\)", false }, { NULL, NULL, 0, 0, "", false } }; do_require_eq_tests(tests); } /* --------------------------------------------------------------------- * Test cases for the ATF_REQUIRE_MATCH and ATF_REQUIRE_MATCH_MSG macros. * --------------------------------------------------------------------- */ H_REQUIRE_MATCH(yes, "hello [a-z]+", "abc hello world"); H_REQUIRE_MATCH(no, "hello [a-z]+", "abc hello WORLD"); H_REQUIRE_MATCH_MSG(yes, "hello [a-z]+", "abc hello world", "lowercase"); H_REQUIRE_MATCH_MSG(no, "hello [a-z]+", "abc hello WORLD", "uppercase"); ATF_TC(require_match); ATF_TC_HEAD(require_match, tc) { atf_tc_set_md_var(tc, "descr", "Tests the ATF_REQUIRE_MATCH and " "ATF_REQUIRE_MATCH_MSG macros"); } ATF_TC_BODY(require_match, tc) { struct require_eq_test tests[] = { { H_REQUIRE_MATCH_HEAD_NAME(yes), H_REQUIRE_MATCH_BODY_NAME(yes), "hello [a-z]+", "abc hello world", "", true }, { H_REQUIRE_MATCH_HEAD_NAME(no), H_REQUIRE_MATCH_BODY_NAME(no), "hello [a-z]+", "abc hello WORLD", "'hello \\[a-z\\]\\+' not matched in 'abc hello WORLD'", false }, { H_REQUIRE_MATCH_MSG_HEAD_NAME(yes), H_REQUIRE_MATCH_MSG_BODY_NAME(yes), "hello [a-z]+", "abc hello world", "", true }, { H_REQUIRE_MATCH_MSG_HEAD_NAME(no), H_REQUIRE_MATCH_MSG_BODY_NAME(no), "hello [a-z]+", "abc hello WORLD", "'hello \\[a-z\\]\\+' not matched in 'abc hello WORLD': uppercase", false }, { NULL, NULL, 0, 0, "", false } }; do_require_eq_tests(tests); } /* --------------------------------------------------------------------- * Miscellaneous test cases covering several macros. * --------------------------------------------------------------------- */ static bool aux_bool(const char *fmt ATF_DEFS_ATTRIBUTE_UNUSED) { return false; } static const char * aux_str(const char *fmt ATF_DEFS_ATTRIBUTE_UNUSED) { return "foo"; } H_CHECK(msg, aux_bool("%d")); H_REQUIRE(msg, aux_bool("%d")); H_CHECK_STREQ(msg, aux_str("%d"), ""); H_REQUIRE_STREQ(msg, aux_str("%d"), ""); ATF_TC(msg_embedded_fmt); ATF_TC_HEAD(msg_embedded_fmt, tc) { atf_tc_set_md_var(tc, "descr", "Tests that format strings passed " "as part of the automatically-generated messages " "do not get expanded"); } ATF_TC_BODY(msg_embedded_fmt, tc) { struct test { void (*head)(atf_tc_t *); void (*body)(const atf_tc_t *); bool fatal; const char *msg; } *t, tests[] = { { H_CHECK_HEAD_NAME(msg), H_CHECK_BODY_NAME(msg), false, "aux_bool\\(\"%d\"\\) not met" }, { H_REQUIRE_HEAD_NAME(msg), H_REQUIRE_BODY_NAME(msg), true, "aux_bool\\(\"%d\"\\) not met" }, { H_CHECK_STREQ_HEAD_NAME(msg), H_CHECK_STREQ_BODY_NAME(msg), false, "aux_str\\(\"%d\"\\) != \"\" \\(foo != \\)" }, { H_REQUIRE_STREQ_HEAD_NAME(msg), H_REQUIRE_STREQ_BODY_NAME(msg), true, "aux_str\\(\"%d\"\\) != \"\" \\(foo != \\)" }, { NULL, NULL, false, NULL } }; for (t = &tests[0]; t->head != NULL; t++) { printf("Checking with an expected '%s' message\n", t->msg); init_and_run_h_tc("h_check", t->head, t->body); if (t->fatal) { bool matched = atf_utils_grep_file( "^failed: .*macros_test.c:[0-9]+: %s$", "result", t->msg); ATF_CHECK_MSG(matched, "couldn't find error string in result"); } else { bool matched = atf_utils_grep_file("Check failed: .*" "macros_test.c:[0-9]+: %s$", "error", t->msg); ATF_CHECK_MSG(matched, "couldn't find error string in output"); } } } /* --------------------------------------------------------------------- * Tests cases for the header file. * --------------------------------------------------------------------- */ -HEADER_TC(include, "atf-c/macros.h"); BUILD_TC(use, "macros_h_test.c", "Tests that the macros provided by the atf-c/macros.h file " "do not cause syntax errors when used", "Build of macros_h_test.c failed; some macros in atf-c/macros.h " "are broken"); ATF_TC(detect_unused_tests); ATF_TC_HEAD(detect_unused_tests, tc) { atf_tc_set_md_var(tc, "descr", "Tests that defining an unused test case raises a " "warning (and thus an error)"); } ATF_TC_BODY(detect_unused_tests, tc) { const char* validate_compiler = "struct test_struct { int dummy; };\n" "#define define_unused static struct test_struct unused\n" "define_unused;\n"; atf_utils_create_file("compiler_test.c", "%s", validate_compiler); if (build_check_c_o("compiler_test.c")) atf_tc_expect_fail("Compiler does not raise a warning on an unused " "static global variable declared by a macro"); if (build_check_c_o_srcdir(tc, "unused_test.c")) atf_tc_fail("Build of unused_test.c passed; unused test cases are " "not properly detected"); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, check); ATF_TP_ADD_TC(tp, check_eq); ATF_TP_ADD_TC(tp, check_streq); ATF_TP_ADD_TC(tp, check_errno); ATF_TP_ADD_TC(tp, check_match); ATF_TP_ADD_TC(tp, require); ATF_TP_ADD_TC(tp, require_eq); ATF_TP_ADD_TC(tp, require_streq); ATF_TP_ADD_TC(tp, require_errno); ATF_TP_ADD_TC(tp, require_match); ATF_TP_ADD_TC(tp, msg_embedded_fmt); /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); ATF_TP_ADD_TC(tp, use); ATF_TP_ADD_TC(tp, detect_unused_tests); return atf_no_error(); } Index: head/contrib/atf/atf-c/pkg_config_test.sh =================================================================== --- head/contrib/atf/atf-c/pkg_config_test.sh (revision 273928) +++ head/contrib/atf/atf-c/pkg_config_test.sh (revision 273929) @@ -1,147 +1,143 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # The following tests assume that the atf-c.pc file is installed in a # directory that is known by pkg-config. Otherwise they will fail, # and you will be required to adjust PKG_CONFIG_PATH accordingly. # # It would be possible to bypass this requirement by setting the path # explicitly during the tests, but then this would not do a real check # to ensure that the installation is working. require_pc() { pkg-config ${1} || atf_fail "pkg-config could not locate ${1}.pc;" \ "maybe need to set PKG_CONFIG_PATH?" } check_version() { ver1=$($(atf_get_srcdir)/detail/version_helper) echo "Version reported by builtin PACKAGE_VERSION: ${ver1}" atf_check -s eq:0 -o save:stdout -e empty pkg-config --modversion "${1}" ver2=$(cat stdout) echo "Version reported by pkg-config: ${ver2}" atf_check_equal ${ver1} ${ver2} } atf_test_case version version_head() { atf_set "descr" "Checks that the version in atf-c is correct" atf_set "require.progs" "pkg-config" } version_body() { require_pc "atf-c" check_version "atf-c" } atf_test_case build build_head() { atf_set "descr" "Checks that a test program can be built against" \ "the C library based on the pkg-config information" atf_set "require.progs" "pkg-config" } build_body() { require_pc "atf-c" atf_check -s eq:0 -o save:stdout -e empty pkg-config --variable=cc atf-c cc=$(cat stdout) echo "Compiler is: ${cxx}" atf_require_prog ${cxx} cat >tp.c < #include ATF_TC(tc); ATF_TC_HEAD(tc, tc) { atf_tc_set_md_var(tc, "descr", "A test case"); } ATF_TC_BODY(tc, tc) { printf("Running\n"); } ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, tc); return atf_no_error(); } EOF atf_check -s eq:0 -o save:stdout -e empty pkg-config --cflags atf-c cflags=$(cat stdout) echo "CFLAGS are: ${cflags}" atf_check -s eq:0 -o save:stdout -e empty \ pkg-config --libs-only-L --libs-only-other atf-c ldflags=$(cat stdout) atf_check -s eq:0 -o save:stdout -e empty pkg-config --libs-only-l atf-c libs=$(cat stdout) echo "LDFLAGS are: ${ldflags}" echo "LIBS are: ${libs}" atf_check -s eq:0 -o empty -e empty ${cc} ${cflags} -o tp.o -c tp.c atf_check -s eq:0 -o empty -e empty ${cc} ${ldflags} -o tp tp.o ${libs} libpath= for f in ${ldflags}; do case ${f} in -L*) dir=$(echo ${f} | sed -e 's,^-L,,') if [ -z "${libpath}" ]; then libpath="${dir}" else libpath="${libpath}:${dir}" fi ;; *) ;; esac done atf_check -s eq:0 -o empty -e empty test -x tp atf_check -s eq:0 -o match:'Running' -e empty -x \ "LD_LIBRARY_PATH=${libpath} ./tp tc" } atf_init_test_cases() { atf_add_test_case version atf_add_test_case build } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-c/tc.c =================================================================== --- head/contrib/atf/atf-c/tc.c (revision 273928) +++ head/contrib/atf/atf-c/tc.c (revision 273929) @@ -1,1221 +1,1217 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/tc.h" + #include #include #include #include #include #include #include #include #include #include #include #include "atf-c/defs.h" +#include "atf-c/detail/env.h" +#include "atf-c/detail/fs.h" +#include "atf-c/detail/map.h" +#include "atf-c/detail/sanity.h" +#include "atf-c/detail/text.h" #include "atf-c/error.h" -#include "atf-c/tc.h" - -#include "detail/env.h" -#include "detail/fs.h" -#include "detail/map.h" -#include "detail/sanity.h" -#include "detail/text.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ enum expect_type { EXPECT_PASS, EXPECT_FAIL, EXPECT_EXIT, EXPECT_SIGNAL, EXPECT_DEATH, EXPECT_TIMEOUT, }; struct context { const atf_tc_t *tc; const char *resfile; size_t fail_count; enum expect_type expect; atf_dynstr_t expect_reason; size_t expect_previous_fail_count; size_t expect_fail_count; int expect_exitcode; int expect_signo; }; static void context_init(struct context *, const atf_tc_t *, const char *); static void check_fatal_error(atf_error_t); static void report_fatal_error(const char *, ...) ATF_DEFS_ATTRIBUTE_NORETURN; static atf_error_t write_resfile(const int, const char *, const int, const atf_dynstr_t *); static void create_resfile(const char *, const char *, const int, atf_dynstr_t *); static void error_in_expect(struct context *, const char *, ...) ATF_DEFS_ATTRIBUTE_NORETURN; static void validate_expect(struct context *); static void expected_failure(struct context *, atf_dynstr_t *) ATF_DEFS_ATTRIBUTE_NORETURN; static void fail_requirement(struct context *, atf_dynstr_t *) ATF_DEFS_ATTRIBUTE_NORETURN; static void fail_check(struct context *, atf_dynstr_t *); static void pass(struct context *) ATF_DEFS_ATTRIBUTE_NORETURN; static void skip(struct context *, atf_dynstr_t *) ATF_DEFS_ATTRIBUTE_NORETURN; static void format_reason_ap(atf_dynstr_t *, const char *, const size_t, const char *, va_list); static void format_reason_fmt(atf_dynstr_t *, const char *, const size_t, const char *, ...); static void errno_test(struct context *, const char *, const size_t, const int, const char *, const bool, void (*)(struct context *, atf_dynstr_t *)); static atf_error_t check_prog_in_dir(const char *, void *); static atf_error_t check_prog(struct context *, const char *); static void context_init(struct context *ctx, const atf_tc_t *tc, const char *resfile) { ctx->tc = tc; ctx->resfile = resfile; ctx->fail_count = 0; ctx->expect = EXPECT_PASS; check_fatal_error(atf_dynstr_init(&ctx->expect_reason)); ctx->expect_previous_fail_count = 0; ctx->expect_fail_count = 0; ctx->expect_exitcode = 0; ctx->expect_signo = 0; } static void check_fatal_error(atf_error_t err) { if (atf_is_error(err)) { char buf[1024]; atf_error_format(err, buf, sizeof(buf)); fprintf(stderr, "FATAL ERROR: %s\n", buf); atf_error_free(err); abort(); } } static void report_fatal_error(const char *msg, ...) { va_list ap; fprintf(stderr, "FATAL ERROR: "); va_start(ap, msg); vfprintf(stderr, msg, ap); va_end(ap); fprintf(stderr, "\n"); abort(); } /** Writes to a results file. * * The results file is supposed to be already open. * * This function returns an error code instead of exiting in case of error * because the caller needs to clean up the reason object before terminating. */ static atf_error_t write_resfile(const int fd, const char *result, const int arg, const atf_dynstr_t *reason) { static char NL[] = "\n", CS[] = ": "; char buf[64]; const char *r; struct iovec iov[5]; ssize_t ret; int count = 0; INV(arg == -1 || reason != NULL); #define UNCONST(a) ((void *)(unsigned long)(const void *)(a)) iov[count].iov_base = UNCONST(result); iov[count++].iov_len = strlen(result); if (reason != NULL) { if (arg != -1) { iov[count].iov_base = buf; iov[count++].iov_len = snprintf(buf, sizeof(buf), "(%d)", arg); } iov[count].iov_base = CS; iov[count++].iov_len = sizeof(CS) - 1; r = atf_dynstr_cstring(reason); iov[count].iov_base = UNCONST(r); iov[count++].iov_len = strlen(r); } #undef UNCONST iov[count].iov_base = NL; iov[count++].iov_len = sizeof(NL) - 1; while ((ret = writev(fd, iov, count)) == -1 && errno == EINTR) continue; /* Retry. */ if (ret != -1) return atf_no_error(); return atf_libc_error( errno, "Failed to write results file; result %s, reason %s", result, reason == NULL ? "null" : atf_dynstr_cstring(reason)); } /** Creates a results file. * * The input reason is released in all cases. * * An error in this function is considered to be fatal, hence why it does * not return any error code. */ static void create_resfile(const char *resfile, const char *result, const int arg, atf_dynstr_t *reason) { atf_error_t err; if (strcmp("/dev/stdout", resfile) == 0) { err = write_resfile(STDOUT_FILENO, result, arg, reason); } else if (strcmp("/dev/stderr", resfile) == 0) { err = write_resfile(STDERR_FILENO, result, arg, reason); } else { const int fd = open(resfile, O_WRONLY | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH); if (fd == -1) { err = atf_libc_error(errno, "Cannot create results file '%s'", resfile); } else { err = write_resfile(fd, result, arg, reason); close(fd); } } if (reason != NULL) atf_dynstr_fini(reason); check_fatal_error(err); } /** Fails a test case if validate_expect fails. */ static void error_in_expect(struct context *ctx, const char *fmt, ...) { atf_dynstr_t reason; va_list ap; va_start(ap, fmt); format_reason_ap(&reason, NULL, 0, fmt, ap); va_end(ap); ctx->expect = EXPECT_PASS; /* Ensure fail_requirement really fails. */ fail_requirement(ctx, &reason); } /** Ensures that the "expect" state is correct. * * Call this function before modifying the current value of expect. */ static void validate_expect(struct context *ctx) { if (ctx->expect == EXPECT_DEATH) { error_in_expect(ctx, "Test case was expected to terminate abruptly " "but it continued execution"); } else if (ctx->expect == EXPECT_EXIT) { error_in_expect(ctx, "Test case was expected to exit cleanly but it " "continued execution"); } else if (ctx->expect == EXPECT_FAIL) { if (ctx->expect_fail_count == ctx->expect_previous_fail_count) error_in_expect(ctx, "Test case was expecting a failure but none " "were raised"); else INV(ctx->expect_fail_count > ctx->expect_previous_fail_count); } else if (ctx->expect == EXPECT_PASS) { /* Nothing to validate. */ } else if (ctx->expect == EXPECT_SIGNAL) { error_in_expect(ctx, "Test case was expected to receive a termination " "signal but it continued execution"); } else if (ctx->expect == EXPECT_TIMEOUT) { error_in_expect(ctx, "Test case was expected to hang but it continued " "execution"); } else UNREACHABLE; } static void expected_failure(struct context *ctx, atf_dynstr_t *reason) { check_fatal_error(atf_dynstr_prepend_fmt(reason, "%s: ", atf_dynstr_cstring(&ctx->expect_reason))); create_resfile(ctx->resfile, "expected_failure", -1, reason); exit(EXIT_SUCCESS); } static void fail_requirement(struct context *ctx, atf_dynstr_t *reason) { if (ctx->expect == EXPECT_FAIL) { expected_failure(ctx, reason); } else if (ctx->expect == EXPECT_PASS) { create_resfile(ctx->resfile, "failed", -1, reason); exit(EXIT_FAILURE); } else { error_in_expect(ctx, "Test case raised a failure but was not " "expecting one; reason was %s", atf_dynstr_cstring(reason)); } UNREACHABLE; } static void fail_check(struct context *ctx, atf_dynstr_t *reason) { if (ctx->expect == EXPECT_FAIL) { fprintf(stderr, "*** Expected check failure: %s: %s\n", atf_dynstr_cstring(&ctx->expect_reason), atf_dynstr_cstring(reason)); ctx->expect_fail_count++; } else if (ctx->expect == EXPECT_PASS) { fprintf(stderr, "*** Check failed: %s\n", atf_dynstr_cstring(reason)); ctx->fail_count++; } else { error_in_expect(ctx, "Test case raised a failure but was not " "expecting one; reason was %s", atf_dynstr_cstring(reason)); } atf_dynstr_fini(reason); } static void pass(struct context *ctx) { if (ctx->expect == EXPECT_FAIL) { error_in_expect(ctx, "Test case was expecting a failure but got " "a pass instead"); } else if (ctx->expect == EXPECT_PASS) { create_resfile(ctx->resfile, "passed", -1, NULL); exit(EXIT_SUCCESS); } else { error_in_expect(ctx, "Test case asked to explicitly pass but was " "not expecting such condition"); } UNREACHABLE; } static void skip(struct context *ctx, atf_dynstr_t *reason) { if (ctx->expect == EXPECT_PASS) { create_resfile(ctx->resfile, "skipped", -1, reason); exit(EXIT_SUCCESS); } else { error_in_expect(ctx, "Can only skip a test case when running in " "expect pass mode"); } UNREACHABLE; } /** Formats a failure/skip reason message. * * The formatted reason is stored in out_reason. out_reason is initialized * in this function and is supposed to be released by the caller. In general, * the reason will eventually be fed to create_resfile, which will release * it. * * Errors in this function are fatal. Rationale being: reasons are used to * create results files; if we can't format the reason correctly, the result * of the test program will be bogus. So it's better to just exit with a * fatal error. */ static void format_reason_ap(atf_dynstr_t *out_reason, const char *source_file, const size_t source_line, const char *reason, va_list ap) { atf_error_t err; if (source_file != NULL) { err = atf_dynstr_init_fmt(out_reason, "%s:%zd: ", source_file, source_line); } else { PRE(source_line == 0); err = atf_dynstr_init(out_reason); } if (!atf_is_error(err)) { va_list ap2; va_copy(ap2, ap); err = atf_dynstr_append_ap(out_reason, reason, ap2); va_end(ap2); } check_fatal_error(err); } static void format_reason_fmt(atf_dynstr_t *out_reason, const char *source_file, const size_t source_line, const char *reason, ...) { va_list ap; va_start(ap, reason); format_reason_ap(out_reason, source_file, source_line, reason, ap); va_end(ap); } static void errno_test(struct context *ctx, const char *file, const size_t line, const int exp_errno, const char *expr_str, const bool expr_result, void (*fail_func)(struct context *, atf_dynstr_t *)) { const int actual_errno = errno; if (expr_result) { if (exp_errno != actual_errno) { atf_dynstr_t reason; format_reason_fmt(&reason, file, line, "Expected errno %d, got %d, " "in %s", exp_errno, actual_errno, expr_str); fail_func(ctx, &reason); } } else { atf_dynstr_t reason; format_reason_fmt(&reason, file, line, "Expected true value in %s", expr_str); fail_func(ctx, &reason); } } struct prog_found_pair { const char *prog; bool found; }; static atf_error_t check_prog_in_dir(const char *dir, void *data) { struct prog_found_pair *pf = data; atf_error_t err; if (pf->found) err = atf_no_error(); else { atf_fs_path_t p; err = atf_fs_path_init_fmt(&p, "%s/%s", dir, pf->prog); if (atf_is_error(err)) goto out_p; err = atf_fs_eaccess(&p, atf_fs_access_x); if (!atf_is_error(err)) pf->found = true; else { atf_error_free(err); INV(!pf->found); err = atf_no_error(); } out_p: atf_fs_path_fini(&p); } return err; } static atf_error_t check_prog(struct context *ctx, const char *prog) { atf_error_t err; atf_fs_path_t p; err = atf_fs_path_init_fmt(&p, "%s", prog); if (atf_is_error(err)) goto out; if (atf_fs_path_is_absolute(&p)) { err = atf_fs_eaccess(&p, atf_fs_access_x); if (atf_is_error(err)) { atf_dynstr_t reason; atf_error_free(err); atf_fs_path_fini(&p); format_reason_fmt(&reason, NULL, 0, "The required program %s could " "not be found", prog); skip(ctx, &reason); } } else { const char *path = atf_env_get("PATH"); struct prog_found_pair pf; atf_fs_path_t bp; err = atf_fs_path_branch_path(&p, &bp); if (atf_is_error(err)) goto out_p; if (strcmp(atf_fs_path_cstring(&bp), ".") != 0) { atf_fs_path_fini(&bp); atf_fs_path_fini(&p); report_fatal_error("Relative paths are not allowed when searching " "for a program (%s)", prog); UNREACHABLE; } pf.prog = prog; pf.found = false; err = atf_text_for_each_word(path, ":", check_prog_in_dir, &pf); if (atf_is_error(err)) goto out_bp; if (!pf.found) { atf_dynstr_t reason; atf_fs_path_fini(&bp); atf_fs_path_fini(&p); format_reason_fmt(&reason, NULL, 0, "The required program %s could " "not be found in the PATH", prog); fail_requirement(ctx, &reason); } out_bp: atf_fs_path_fini(&bp); } out_p: atf_fs_path_fini(&p); out: return err; } /* --------------------------------------------------------------------- * The "atf_tc" type. * --------------------------------------------------------------------- */ struct atf_tc_impl { const char *m_ident; atf_map_t m_vars; atf_map_t m_config; atf_tc_head_t m_head; atf_tc_body_t m_body; atf_tc_cleanup_t m_cleanup; }; /* * Constructors/destructors. */ atf_error_t atf_tc_init(atf_tc_t *tc, const char *ident, atf_tc_head_t head, atf_tc_body_t body, atf_tc_cleanup_t cleanup, const char *const *config) { atf_error_t err; tc->pimpl = malloc(sizeof(struct atf_tc_impl)); if (tc->pimpl == NULL) { err = atf_no_memory_error(); goto err; } tc->pimpl->m_ident = ident; tc->pimpl->m_head = head; tc->pimpl->m_body = body; tc->pimpl->m_cleanup = cleanup; err = atf_map_init_charpp(&tc->pimpl->m_config, config); if (atf_is_error(err)) goto err; err = atf_map_init(&tc->pimpl->m_vars); if (atf_is_error(err)) goto err_vars; err = atf_tc_set_md_var(tc, "ident", ident); if (atf_is_error(err)) goto err_map; if (cleanup != NULL) { err = atf_tc_set_md_var(tc, "has.cleanup", "true"); if (atf_is_error(err)) goto err_map; } /* XXX Should the head be able to return error codes? */ if (tc->pimpl->m_head != NULL) tc->pimpl->m_head(tc); if (strcmp(atf_tc_get_md_var(tc, "ident"), ident) != 0) { report_fatal_error("Test case head modified the read-only 'ident' " "property"); UNREACHABLE; } INV(!atf_is_error(err)); return err; err_map: atf_map_fini(&tc->pimpl->m_vars); err_vars: atf_map_fini(&tc->pimpl->m_config); err: return err; } atf_error_t atf_tc_init_pack(atf_tc_t *tc, const atf_tc_pack_t *pack, const char *const *config) { return atf_tc_init(tc, pack->m_ident, pack->m_head, pack->m_body, pack->m_cleanup, config); } void atf_tc_fini(atf_tc_t *tc) { atf_map_fini(&tc->pimpl->m_vars); free(tc->pimpl); } /* * Getters. */ const char * atf_tc_get_ident(const atf_tc_t *tc) { return tc->pimpl->m_ident; } const char * atf_tc_get_config_var(const atf_tc_t *tc, const char *name) { const char *val; atf_map_citer_t iter; PRE(atf_tc_has_config_var(tc, name)); iter = atf_map_find_c(&tc->pimpl->m_config, name); val = atf_map_citer_data(iter); INV(val != NULL); return val; } const char * atf_tc_get_config_var_wd(const atf_tc_t *tc, const char *name, const char *defval) { const char *val; if (!atf_tc_has_config_var(tc, name)) val = defval; else val = atf_tc_get_config_var(tc, name); return val; } bool atf_tc_get_config_var_as_bool(const atf_tc_t *tc, const char *name) { bool val; const char *strval; atf_error_t err; strval = atf_tc_get_config_var(tc, name); err = atf_text_to_bool(strval, &val); if (atf_is_error(err)) { atf_error_free(err); atf_tc_fail("Configuration variable %s does not have a valid " "boolean value; found %s", name, strval); } return val; } bool atf_tc_get_config_var_as_bool_wd(const atf_tc_t *tc, const char *name, const bool defval) { bool val; if (!atf_tc_has_config_var(tc, name)) val = defval; else val = atf_tc_get_config_var_as_bool(tc, name); return val; } long atf_tc_get_config_var_as_long(const atf_tc_t *tc, const char *name) { long val; const char *strval; atf_error_t err; strval = atf_tc_get_config_var(tc, name); err = atf_text_to_long(strval, &val); if (atf_is_error(err)) { atf_error_free(err); atf_tc_fail("Configuration variable %s does not have a valid " "long value; found %s", name, strval); } return val; } long atf_tc_get_config_var_as_long_wd(const atf_tc_t *tc, const char *name, const long defval) { long val; if (!atf_tc_has_config_var(tc, name)) val = defval; else val = atf_tc_get_config_var_as_long(tc, name); return val; } const char * atf_tc_get_md_var(const atf_tc_t *tc, const char *name) { const char *val; atf_map_citer_t iter; PRE(atf_tc_has_md_var(tc, name)); iter = atf_map_find_c(&tc->pimpl->m_vars, name); val = atf_map_citer_data(iter); INV(val != NULL); return val; } char ** atf_tc_get_md_vars(const atf_tc_t *tc) { return atf_map_to_charpp(&tc->pimpl->m_vars); } bool atf_tc_has_config_var(const atf_tc_t *tc, const char *name) { atf_map_citer_t end, iter; iter = atf_map_find_c(&tc->pimpl->m_config, name); end = atf_map_end_c(&tc->pimpl->m_config); return !atf_equal_map_citer_map_citer(iter, end); } bool atf_tc_has_md_var(const atf_tc_t *tc, const char *name) { atf_map_citer_t end, iter; iter = atf_map_find_c(&tc->pimpl->m_vars, name); end = atf_map_end_c(&tc->pimpl->m_vars); return !atf_equal_map_citer_map_citer(iter, end); } /* * Modifiers. */ atf_error_t atf_tc_set_md_var(atf_tc_t *tc, const char *name, const char *fmt, ...) { atf_error_t err; char *value; va_list ap; va_start(ap, fmt); err = atf_text_format_ap(&value, fmt, ap); va_end(ap); if (!atf_is_error(err)) err = atf_map_insert(&tc->pimpl->m_vars, name, value, true); else free(value); return err; } /* --------------------------------------------------------------------- * Free functions, as they should be publicly but they can't. * --------------------------------------------------------------------- */ static void _atf_tc_fail(struct context *, const char *, va_list) ATF_DEFS_ATTRIBUTE_NORETURN; static void _atf_tc_fail_nonfatal(struct context *, const char *, va_list); static void _atf_tc_fail_check(struct context *, const char *, const size_t, const char *, va_list); static void _atf_tc_fail_requirement(struct context *, const char *, const size_t, const char *, va_list) ATF_DEFS_ATTRIBUTE_NORETURN; static void _atf_tc_pass(struct context *) ATF_DEFS_ATTRIBUTE_NORETURN; static void _atf_tc_require_prog(struct context *, const char *); static void _atf_tc_skip(struct context *, const char *, va_list) ATF_DEFS_ATTRIBUTE_NORETURN; static void _atf_tc_check_errno(struct context *, const char *, const size_t, const int, const char *, const bool); static void _atf_tc_require_errno(struct context *, const char *, const size_t, const int, const char *, const bool); static void _atf_tc_expect_pass(struct context *); static void _atf_tc_expect_fail(struct context *, const char *, va_list); static void _atf_tc_expect_exit(struct context *, const int, const char *, va_list); static void _atf_tc_expect_signal(struct context *, const int, const char *, va_list); static void _atf_tc_expect_death(struct context *, const char *, va_list); static void _atf_tc_fail(struct context *ctx, const char *fmt, va_list ap) { va_list ap2; atf_dynstr_t reason; va_copy(ap2, ap); format_reason_ap(&reason, NULL, 0, fmt, ap2); va_end(ap2); fail_requirement(ctx, &reason); UNREACHABLE; } static void _atf_tc_fail_nonfatal(struct context *ctx, const char *fmt, va_list ap) { va_list ap2; atf_dynstr_t reason; va_copy(ap2, ap); format_reason_ap(&reason, NULL, 0, fmt, ap2); va_end(ap2); fail_check(ctx, &reason); } static void _atf_tc_fail_check(struct context *ctx, const char *file, const size_t line, const char *fmt, va_list ap) { va_list ap2; atf_dynstr_t reason; va_copy(ap2, ap); format_reason_ap(&reason, file, line, fmt, ap2); va_end(ap2); fail_check(ctx, &reason); } static void _atf_tc_fail_requirement(struct context *ctx, const char *file, const size_t line, const char *fmt, va_list ap) { va_list ap2; atf_dynstr_t reason; va_copy(ap2, ap); format_reason_ap(&reason, file, line, fmt, ap2); va_end(ap2); fail_requirement(ctx, &reason); UNREACHABLE; } static void _atf_tc_pass(struct context *ctx) { pass(ctx); UNREACHABLE; } static void _atf_tc_require_prog(struct context *ctx, const char *prog) { check_fatal_error(check_prog(ctx, prog)); } static void _atf_tc_skip(struct context *ctx, const char *fmt, va_list ap) { atf_dynstr_t reason; va_list ap2; va_copy(ap2, ap); format_reason_ap(&reason, NULL, 0, fmt, ap2); va_end(ap2); skip(ctx, &reason); } static void _atf_tc_check_errno(struct context *ctx, const char *file, const size_t line, const int exp_errno, const char *expr_str, const bool expr_result) { errno_test(ctx, file, line, exp_errno, expr_str, expr_result, fail_check); } static void _atf_tc_require_errno(struct context *ctx, const char *file, const size_t line, const int exp_errno, const char *expr_str, const bool expr_result) { errno_test(ctx, file, line, exp_errno, expr_str, expr_result, fail_requirement); } static void _atf_tc_expect_pass(struct context *ctx) { validate_expect(ctx); ctx->expect = EXPECT_PASS; } static void _atf_tc_expect_fail(struct context *ctx, const char *reason, va_list ap) { va_list ap2; validate_expect(ctx); ctx->expect = EXPECT_FAIL; atf_dynstr_fini(&ctx->expect_reason); va_copy(ap2, ap); check_fatal_error(atf_dynstr_init_ap(&ctx->expect_reason, reason, ap2)); va_end(ap2); ctx->expect_previous_fail_count = ctx->expect_fail_count; } static void _atf_tc_expect_exit(struct context *ctx, const int exitcode, const char *reason, va_list ap) { va_list ap2; atf_dynstr_t formatted; validate_expect(ctx); ctx->expect = EXPECT_EXIT; va_copy(ap2, ap); check_fatal_error(atf_dynstr_init_ap(&formatted, reason, ap2)); va_end(ap2); create_resfile(ctx->resfile, "expected_exit", exitcode, &formatted); } static void _atf_tc_expect_signal(struct context *ctx, const int signo, const char *reason, va_list ap) { va_list ap2; atf_dynstr_t formatted; validate_expect(ctx); ctx->expect = EXPECT_SIGNAL; va_copy(ap2, ap); check_fatal_error(atf_dynstr_init_ap(&formatted, reason, ap2)); va_end(ap2); create_resfile(ctx->resfile, "expected_signal", signo, &formatted); } static void _atf_tc_expect_death(struct context *ctx, const char *reason, va_list ap) { va_list ap2; atf_dynstr_t formatted; validate_expect(ctx); ctx->expect = EXPECT_DEATH; va_copy(ap2, ap); check_fatal_error(atf_dynstr_init_ap(&formatted, reason, ap2)); va_end(ap2); create_resfile(ctx->resfile, "expected_death", -1, &formatted); } static void _atf_tc_expect_timeout(struct context *ctx, const char *reason, va_list ap) { va_list ap2; atf_dynstr_t formatted; validate_expect(ctx); ctx->expect = EXPECT_TIMEOUT; va_copy(ap2, ap); check_fatal_error(atf_dynstr_init_ap(&formatted, reason, ap2)); va_end(ap2); create_resfile(ctx->resfile, "expected_timeout", -1, &formatted); } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ static struct context Current; atf_error_t atf_tc_run(const atf_tc_t *tc, const char *resfile) { context_init(&Current, tc, resfile); tc->pimpl->m_body(tc); validate_expect(&Current); if (Current.fail_count > 0) { atf_dynstr_t reason; format_reason_fmt(&reason, NULL, 0, "%d checks failed; see output for " "more details", Current.fail_count); fail_requirement(&Current, &reason); } else if (Current.expect_fail_count > 0) { atf_dynstr_t reason; format_reason_fmt(&reason, NULL, 0, "%d checks failed as expected; " "see output for more details", Current.expect_fail_count); expected_failure(&Current, &reason); } else { pass(&Current); } UNREACHABLE; return atf_no_error(); } atf_error_t atf_tc_cleanup(const atf_tc_t *tc) { if (tc->pimpl->m_cleanup != NULL) tc->pimpl->m_cleanup(tc); return atf_no_error(); /* XXX */ } /* --------------------------------------------------------------------- * Free functions that depend on Current. * --------------------------------------------------------------------- */ /* * All the functions below provide delegates to other internal functions * (prefixed by _) that take the current test case as an argument to * prevent them from accessing global state. This is to keep the side- * effects of the internal functions clearer and easier to understand. * * The public API should never have hid the fact that it needs access to * the current test case (other than maybe in the macros), but changing it * is hard. TODO: Revisit in the future. */ void atf_tc_fail(const char *fmt, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, fmt); _atf_tc_fail(&Current, fmt, ap); va_end(ap); } void atf_tc_fail_nonfatal(const char *fmt, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, fmt); _atf_tc_fail_nonfatal(&Current, fmt, ap); va_end(ap); } void atf_tc_fail_check(const char *file, const size_t line, const char *fmt, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, fmt); _atf_tc_fail_check(&Current, file, line, fmt, ap); va_end(ap); } void atf_tc_fail_requirement(const char *file, const size_t line, const char *fmt, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, fmt); _atf_tc_fail_requirement(&Current, file, line, fmt, ap); va_end(ap); } void atf_tc_pass(void) { PRE(Current.tc != NULL); _atf_tc_pass(&Current); } void atf_tc_require_prog(const char *prog) { PRE(Current.tc != NULL); _atf_tc_require_prog(&Current, prog); } void atf_tc_skip(const char *fmt, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, fmt); _atf_tc_skip(&Current, fmt, ap); va_end(ap); } void atf_tc_check_errno(const char *file, const size_t line, const int exp_errno, const char *expr_str, const bool expr_result) { PRE(Current.tc != NULL); _atf_tc_check_errno(&Current, file, line, exp_errno, expr_str, expr_result); } void atf_tc_require_errno(const char *file, const size_t line, const int exp_errno, const char *expr_str, const bool expr_result) { PRE(Current.tc != NULL); _atf_tc_require_errno(&Current, file, line, exp_errno, expr_str, expr_result); } void atf_tc_expect_pass(void) { PRE(Current.tc != NULL); _atf_tc_expect_pass(&Current); } void atf_tc_expect_fail(const char *reason, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, reason); _atf_tc_expect_fail(&Current, reason, ap); va_end(ap); } void atf_tc_expect_exit(const int exitcode, const char *reason, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, reason); _atf_tc_expect_exit(&Current, exitcode, reason, ap); va_end(ap); } void atf_tc_expect_signal(const int signo, const char *reason, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, reason); _atf_tc_expect_signal(&Current, signo, reason, ap); va_end(ap); } void atf_tc_expect_death(const char *reason, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, reason); _atf_tc_expect_death(&Current, reason, ap); va_end(ap); } void atf_tc_expect_timeout(const char *reason, ...) { va_list ap; PRE(Current.tc != NULL); va_start(ap, reason); _atf_tc_expect_timeout(&Current, reason, ap); va_end(ap); } Index: head/contrib/atf/atf-c/tc.h =================================================================== --- head/contrib/atf/atf-c/tc.h (revision 273928) +++ head/contrib/atf/atf-c/tc.h (revision 273929) @@ -1,140 +1,136 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_TC_H) #define ATF_C_TC_H #include #include #include #include struct atf_tc; typedef void (*atf_tc_head_t)(struct atf_tc *); typedef void (*atf_tc_body_t)(const struct atf_tc *); typedef void (*atf_tc_cleanup_t)(const struct atf_tc *); /* --------------------------------------------------------------------- * The "atf_tc_pack" type. * --------------------------------------------------------------------- */ /* For static initialization only. */ struct atf_tc_pack { const char *m_ident; const char *const *m_config; atf_tc_head_t m_head; atf_tc_body_t m_body; atf_tc_cleanup_t m_cleanup; }; typedef const struct atf_tc_pack atf_tc_pack_t; /* --------------------------------------------------------------------- * The "atf_tc" type. * --------------------------------------------------------------------- */ struct atf_tc_impl; struct atf_tc { struct atf_tc_impl *pimpl; }; typedef struct atf_tc atf_tc_t; /* Constructors/destructors. */ atf_error_t atf_tc_init(atf_tc_t *, const char *, atf_tc_head_t, atf_tc_body_t, atf_tc_cleanup_t, const char *const *); atf_error_t atf_tc_init_pack(atf_tc_t *, atf_tc_pack_t *, const char *const *); void atf_tc_fini(atf_tc_t *); /* Getters. */ const char *atf_tc_get_ident(const atf_tc_t *); const char *atf_tc_get_config_var(const atf_tc_t *, const char *); const char *atf_tc_get_config_var_wd(const atf_tc_t *, const char *, const char *); bool atf_tc_get_config_var_as_bool(const atf_tc_t *, const char *); bool atf_tc_get_config_var_as_bool_wd(const atf_tc_t *, const char *, const bool); long atf_tc_get_config_var_as_long(const atf_tc_t *, const char *); long atf_tc_get_config_var_as_long_wd(const atf_tc_t *, const char *, const long); const char *atf_tc_get_md_var(const atf_tc_t *, const char *); char **atf_tc_get_md_vars(const atf_tc_t *); bool atf_tc_has_config_var(const atf_tc_t *, const char *); bool atf_tc_has_md_var(const atf_tc_t *, const char *); /* Modifiers. */ atf_error_t atf_tc_set_md_var(atf_tc_t *, const char *, const char *, ...); /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_tc_run(const atf_tc_t *, const char *); atf_error_t atf_tc_cleanup(const atf_tc_t *); /* To be run from test case bodies only. */ void atf_tc_fail(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2) ATF_DEFS_ATTRIBUTE_NORETURN; void atf_tc_fail_nonfatal(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2); void atf_tc_pass(void) ATF_DEFS_ATTRIBUTE_NORETURN; void atf_tc_require_prog(const char *); void atf_tc_skip(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2) ATF_DEFS_ATTRIBUTE_NORETURN; void atf_tc_expect_pass(void); void atf_tc_expect_fail(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2); void atf_tc_expect_exit(const int, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(2, 3); void atf_tc_expect_signal(const int, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(2, 3); void atf_tc_expect_death(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2); void atf_tc_expect_timeout(const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 2); /* To be run from test case bodies only; internal to macros.h. */ void atf_tc_fail_check(const char *, const size_t, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(3, 4); void atf_tc_fail_requirement(const char *, const size_t, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(3, 4) ATF_DEFS_ATTRIBUTE_NORETURN; void atf_tc_check_errno(const char *, const size_t, const int, const char *, const bool); void atf_tc_require_errno(const char *, const size_t, const int, const char *, const bool); -#endif /* ATF_C_TC_H */ +#endif /* !defined(ATF_C_TC_H) */ Index: head/contrib/atf/atf-c/tc_test.c =================================================================== --- head/contrib/atf/atf-c/tc_test.c (revision 273928) +++ head/contrib/atf/atf-c/tc_test.c (revision 273929) @@ -1,194 +1,183 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/tc.h" + #include #include #include -#include "detail/test_helpers.h" +#include "atf-c/detail/test_helpers.h" /* --------------------------------------------------------------------- * Auxiliary test cases. * --------------------------------------------------------------------- */ ATF_TC_HEAD(empty, tc) { if (tc != NULL) {} } ATF_TC_BODY(empty, tc) { } ATF_TC_HEAD(test_var, tc) { atf_tc_set_md_var(tc, "test-var", "Test text"); } /* --------------------------------------------------------------------- * Test cases for the "atf_tc_t" type. * --------------------------------------------------------------------- */ ATF_TC(init); ATF_TC_HEAD(init, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_tc_init function"); } ATF_TC_BODY(init, tcin) { atf_tc_t tc; RE(atf_tc_init(&tc, "test1", ATF_TC_HEAD_NAME(empty), ATF_TC_BODY_NAME(empty), NULL, NULL)); ATF_REQUIRE(strcmp(atf_tc_get_ident(&tc), "test1") == 0); ATF_REQUIRE(!atf_tc_has_md_var(&tc, "test-var")); atf_tc_fini(&tc); RE(atf_tc_init(&tc, "test2", ATF_TC_HEAD_NAME(test_var), ATF_TC_BODY_NAME(empty), NULL, NULL)); ATF_REQUIRE(strcmp(atf_tc_get_ident(&tc), "test2") == 0); ATF_REQUIRE(atf_tc_has_md_var(&tc, "test-var")); atf_tc_fini(&tc); } ATF_TC(init_pack); ATF_TC_HEAD(init_pack, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_tc_init_pack function"); } ATF_TC_BODY(init_pack, tcin) { atf_tc_t tc; atf_tc_pack_t tcp1 = { .m_ident = "test1", .m_head = ATF_TC_HEAD_NAME(empty), .m_body = ATF_TC_BODY_NAME(empty), .m_cleanup = NULL, }; atf_tc_pack_t tcp2 = { .m_ident = "test2", .m_head = ATF_TC_HEAD_NAME(test_var), .m_body = ATF_TC_BODY_NAME(empty), .m_cleanup = NULL, }; RE(atf_tc_init_pack(&tc, &tcp1, NULL)); ATF_REQUIRE(strcmp(atf_tc_get_ident(&tc), "test1") == 0); ATF_REQUIRE(!atf_tc_has_md_var(&tc, "test-var")); atf_tc_fini(&tc); RE(atf_tc_init_pack(&tc, &tcp2, NULL)); ATF_REQUIRE(strcmp(atf_tc_get_ident(&tc), "test2") == 0); ATF_REQUIRE(atf_tc_has_md_var(&tc, "test-var")); atf_tc_fini(&tc); } ATF_TC(vars); ATF_TC_HEAD(vars, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_tc_get_md_var, " "atf_tc_has_md_var and atf_tc_set_md_var functions"); } ATF_TC_BODY(vars, tcin) { atf_tc_t tc; RE(atf_tc_init(&tc, "test1", ATF_TC_HEAD_NAME(empty), ATF_TC_BODY_NAME(empty), NULL, NULL)); ATF_REQUIRE(!atf_tc_has_md_var(&tc, "test-var")); RE(atf_tc_set_md_var(&tc, "test-var", "Test value")); ATF_REQUIRE(atf_tc_has_md_var(&tc, "test-var")); ATF_REQUIRE(strcmp(atf_tc_get_md_var(&tc, "test-var"), "Test value") == 0); atf_tc_fini(&tc); } ATF_TC(config); ATF_TC_HEAD(config, tc) { atf_tc_set_md_var(tc, "descr", "Tests the atf_tc_get_config_var, " "atf_tc_get_config_var_wd and atf_tc_has_config_var " "functions"); } ATF_TC_BODY(config, tcin) { atf_tc_t tc; const char *const config[] = { "test-var", "test-value", NULL }; RE(atf_tc_init(&tc, "test1", ATF_TC_HEAD_NAME(empty), ATF_TC_BODY_NAME(empty), NULL, NULL)); ATF_REQUIRE(!atf_tc_has_config_var(&tc, "test-var")); ATF_REQUIRE(!atf_tc_has_md_var(&tc, "test-var")); atf_tc_fini(&tc); RE(atf_tc_init(&tc, "test1", ATF_TC_HEAD_NAME(empty), ATF_TC_BODY_NAME(empty), NULL, config)); ATF_REQUIRE(atf_tc_has_config_var(&tc, "test-var")); ATF_REQUIRE(strcmp(atf_tc_get_config_var(&tc, "test-var"), "test-value") == 0); ATF_REQUIRE(!atf_tc_has_md_var(&tc, "test-var")); ATF_REQUIRE(!atf_tc_has_config_var(&tc, "test-var2")); ATF_REQUIRE(strcmp(atf_tc_get_config_var_wd(&tc, "test-var2", "def-value"), "def-value") == 0); atf_tc_fini(&tc); } /* --------------------------------------------------------------------- * Test cases for the free functions. * --------------------------------------------------------------------- */ /* TODO: Add test cases for atf_tc_run. This is going to be very tough, * but good tests here could allow us to avoid much of the indirect * testing done later on. */ /* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/tc.h"); - -/* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add the test cases for the "atf_tcr_t" type. */ ATF_TP_ADD_TC(tp, init); ATF_TP_ADD_TC(tp, init_pack); ATF_TP_ADD_TC(tp, vars); ATF_TP_ADD_TC(tp, config); /* Add the test cases for the free functions. */ /* TODO */ - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c/tp.c =================================================================== --- head/contrib/atf/atf-c/tp.c (revision 273928) +++ head/contrib/atf/atf-c/tp.c (revision 273929) @@ -1,217 +1,213 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/tp.h" + #include #include #include #include +#include "atf-c/detail/fs.h" +#include "atf-c/detail/map.h" +#include "atf-c/detail/sanity.h" #include "atf-c/error.h" #include "atf-c/tc.h" -#include "atf-c/tp.h" - -#include "detail/fs.h" -#include "detail/map.h" -#include "detail/sanity.h" struct atf_tp_impl { atf_list_t m_tcs; atf_map_t m_config; }; /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static const atf_tc_t * find_tc(const atf_tp_t *tp, const char *ident) { const atf_tc_t *tc; atf_list_citer_t iter; tc = NULL; atf_list_for_each_c(iter, &tp->pimpl->m_tcs) { const atf_tc_t *tc2; tc2 = atf_list_citer_data(iter); if (strcmp(atf_tc_get_ident(tc2), ident) == 0) { tc = tc2; break; } } return tc; } /* --------------------------------------------------------------------- * The "atf_tp" type. * --------------------------------------------------------------------- */ /* * Constructors/destructors. */ atf_error_t atf_tp_init(atf_tp_t *tp, const char *const *config) { atf_error_t err; PRE(config != NULL); tp->pimpl = malloc(sizeof(struct atf_tp_impl)); if (tp->pimpl == NULL) return atf_no_memory_error(); err = atf_list_init(&tp->pimpl->m_tcs); if (atf_is_error(err)) goto out; err = atf_map_init_charpp(&tp->pimpl->m_config, config); if (atf_is_error(err)) { atf_list_fini(&tp->pimpl->m_tcs); goto out; } INV(!atf_is_error(err)); out: return err; } void atf_tp_fini(atf_tp_t *tp) { atf_list_iter_t iter; atf_map_fini(&tp->pimpl->m_config); atf_list_for_each(iter, &tp->pimpl->m_tcs) { atf_tc_t *tc = atf_list_iter_data(iter); atf_tc_fini(tc); } atf_list_fini(&tp->pimpl->m_tcs); free(tp->pimpl); } /* * Getters. */ char ** atf_tp_get_config(const atf_tp_t *tp) { return atf_map_to_charpp(&tp->pimpl->m_config); } bool atf_tp_has_tc(const atf_tp_t *tp, const char *id) { const atf_tc_t *tc = find_tc(tp, id); return tc != NULL; } const atf_tc_t * atf_tp_get_tc(const atf_tp_t *tp, const char *id) { const atf_tc_t *tc = find_tc(tp, id); PRE(tc != NULL); return tc; } const atf_tc_t *const * atf_tp_get_tcs(const atf_tp_t *tp) { const atf_tc_t **array; atf_list_citer_t iter; size_t i; array = malloc(sizeof(atf_tc_t *) * (atf_list_size(&tp->pimpl->m_tcs) + 1)); if (array == NULL) goto out; i = 0; atf_list_for_each_c(iter, &tp->pimpl->m_tcs) { array[i] = atf_list_citer_data(iter); if (array[i] == NULL) { free(array); array = NULL; goto out; } i++; } array[i] = NULL; out: return array; } /* * Modifiers. */ atf_error_t atf_tp_add_tc(atf_tp_t *tp, atf_tc_t *tc) { atf_error_t err; PRE(find_tc(tp, atf_tc_get_ident(tc)) == NULL); err = atf_list_append(&tp->pimpl->m_tcs, tc, false); POST(find_tc(tp, atf_tc_get_ident(tc)) != NULL); return err; } /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_tp_run(const atf_tp_t *tp, const char *tcname, const char *resfile) { const atf_tc_t *tc; tc = find_tc(tp, tcname); PRE(tc != NULL); return atf_tc_run(tc, resfile); } atf_error_t atf_tp_cleanup(const atf_tp_t *tp, const char *tcname) { const atf_tc_t *tc; tc = find_tc(tp, tcname); PRE(tc != NULL); return atf_tc_cleanup(tc); } Index: head/contrib/atf/atf-c/tp.h =================================================================== --- head/contrib/atf/atf-c/tp.h (revision 273928) +++ head/contrib/atf/atf-c/tp.h (revision 273929) @@ -1,69 +1,65 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_TP_H) #define ATF_C_TP_H #include #include struct atf_tc; /* --------------------------------------------------------------------- * The "atf_tp" type. * --------------------------------------------------------------------- */ struct atf_tp_impl; struct atf_tp { struct atf_tp_impl *pimpl; }; typedef struct atf_tp atf_tp_t; /* Constructors/destructors. */ atf_error_t atf_tp_init(atf_tp_t *, const char *const *); void atf_tp_fini(atf_tp_t *); /* Getters. */ char **atf_tp_get_config(const atf_tp_t *); bool atf_tp_has_tc(const atf_tp_t *, const char *); const struct atf_tc *atf_tp_get_tc(const atf_tp_t *, const char *); const struct atf_tc *const *atf_tp_get_tcs(const atf_tp_t *); /* Modifiers. */ atf_error_t atf_tp_add_tc(atf_tp_t *, struct atf_tc *); /* --------------------------------------------------------------------- * Free functions. * --------------------------------------------------------------------- */ atf_error_t atf_tp_run(const atf_tp_t *, const char *, const char *); atf_error_t atf_tp_cleanup(const atf_tp_t *, const char *); -#endif /* ATF_C_TP_H */ +#endif /* !defined(ATF_C_TP_H) */ Index: head/contrib/atf/atf-c/tp_test.c =================================================================== --- head/contrib/atf/atf-c/tp_test.c (revision 273928) +++ head/contrib/atf/atf-c/tp_test.c (revision 273929) @@ -1,101 +1,88 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2010 The NetBSD Foundation, Inc. +/* Copyright (c) 2010 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/tp.h" + #include #include #include -#include "detail/test_helpers.h" - ATF_TC(getopt); ATF_TC_HEAD(getopt, tc) { atf_tc_set_md_var(tc, "descr", "Checks if getopt(3) global state is " "reset by the test program driver so that test cases can use " "getopt(3) again"); } ATF_TC_BODY(getopt, tc) { /* Provide an option that is unknown to the test program driver and * one that is, together with an argument that would be swallowed by * the test program option if it were recognized. */ int argc = 4; char arg1[] = "progname"; char arg2[] = "-Z"; char arg3[] = "-s"; char arg4[] = "foo"; char *const argv[] = { arg1, arg2, arg3, arg4, NULL }; int ch; bool zflag; /* Given that this obviously is a test program, and that we used the * same driver to start, we can test getopt(3) right here without doing * any fancy stuff. */ zflag = false; while ((ch = getopt(argc, argv, ":Z")) != -1) { switch (ch) { case 'Z': zflag = true; break; case '?': default: if (optopt != 's') atf_tc_fail("Unexpected unknown option -%c found", optopt); } } ATF_REQUIRE(zflag); ATF_REQUIRE_EQ_MSG(1, argc - optind, "Invalid number of arguments left " "after the call to getopt(3)"); ATF_CHECK_STREQ_MSG("foo", argv[optind], "The non-option argument is " "invalid"); } /* --------------------------------------------------------------------- - * Tests cases for the header file. - * --------------------------------------------------------------------- */ - -HEADER_TC(include, "atf-c/tp.h"); - -/* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, getopt); - - /* Add the test cases for the header file. */ - ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c/unused_test.c =================================================================== --- head/contrib/atf/atf-c/unused_test.c (revision 273928) +++ head/contrib/atf/atf-c/unused_test.c (revision 273929) @@ -1,56 +1,52 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2012 The NetBSD Foundation, Inc. +/* Copyright (c) 2012 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include +#include ATF_TC(this_is_used); ATF_TC_HEAD(this_is_used, tc) { atf_tc_set_md_var(tc, "descr", "A test case that is not referenced"); } ATF_TC_BODY(this_is_used, tc) { } ATF_TC(this_is_unused); ATF_TC_HEAD(this_is_unused, tc) { atf_tc_set_md_var(tc, "descr", "A test case that is referenced"); } ATF_TC_BODY(this_is_unused, tc) { } ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, this_is_used); /* ATF_TP_ADD_TC(tp, this_is_unused); */ return atf_no_error(); } Index: head/contrib/atf/atf-c/utils.c =================================================================== --- head/contrib/atf/atf-c/utils.c (revision 273928) +++ head/contrib/atf/atf-c/utils.c (revision 273929) @@ -1,415 +1,456 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2010 The NetBSD Foundation, Inc. +/* Copyright (c) 2010 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "atf-c/utils.h" #include #include #include #include #include #include #include #include #include #include #include -#include "detail/dynstr.h" +#include "atf-c/detail/dynstr.h" +/** Allocate a filename to be used by atf_utils_{fork,wait}. + * + * In case of a failure, marks the calling test as failed when in_parent is + * true, else terminates execution. + * + * \param [out] name String to contain the generated file. + * \param pid PID of the process that will write to the file. + * \param suffix Either "out" or "err". + * \param in_parent If true, fail with atf_tc_fail; else use err(3). */ +static void +init_out_filename(atf_dynstr_t *name, const pid_t pid, const char *suffix, + const bool in_parent) +{ + atf_error_t error; + + error = atf_dynstr_init_fmt(name, "atf_utils_fork_%d_%s.txt", + (int)pid, suffix); + if (atf_is_error(error)) { + char buffer[1024]; + atf_error_format(error, buffer, sizeof(buffer)); + if (in_parent) { + atf_tc_fail("Failed to create output file: %s", buffer); + } else { + err(EXIT_FAILURE, "Failed to create output file: %s", buffer); + } + } +} + /** Searches for a regexp in a string. * * \param regex The regexp to look for. * \param str The string in which to look for the expression. * * \return True if there is a match; false otherwise. */ static bool grep_string(const char *regex, const char *str) { int res; regex_t preg; printf("Looking for '%s' in '%s'\n", regex, str); ATF_REQUIRE(regcomp(&preg, regex, REG_EXTENDED) == 0); res = regexec(&preg, str, 0, NULL, 0); ATF_REQUIRE(res == 0 || res == REG_NOMATCH); regfree(&preg); return res == 0; } /** Prints the contents of a file to stdout. * * \param name The name of the file to be printed. * \param prefix An string to be prepended to every line of the printed * file. */ void atf_utils_cat_file(const char *name, const char *prefix) { const int fd = open(name, O_RDONLY); ATF_REQUIRE_MSG(fd != -1, "Cannot open %s", name); char buffer[1024]; ssize_t count; bool continued = false; while ((count = read(fd, buffer, sizeof(buffer) - 1)) > 0) { buffer[count] = '\0'; if (!continued) printf("%s", prefix); char *iter = buffer; char *end; while ((end = strchr(iter, '\n')) != NULL) { *end = '\0'; printf("%s\n", iter); iter = end + 1; if (iter != buffer + count) printf("%s", prefix); else continued = false; } if (iter < buffer + count) { printf("%s", iter); continued = true; } } ATF_REQUIRE(count == 0); } /** Compares a file against the given golden contents. * * \param name Name of the file to be compared. * \param contents Expected contents of the file. * * \return True if the file matches the contents; false otherwise. */ bool atf_utils_compare_file(const char *name, const char *contents) { const int fd = open(name, O_RDONLY); ATF_REQUIRE_MSG(fd != -1, "Cannot open %s", name); const char *pos = contents; ssize_t remaining = strlen(contents); char buffer[1024]; ssize_t count; while ((count = read(fd, buffer, sizeof(buffer))) > 0 && count <= remaining) { if (memcmp(pos, buffer, count) != 0) { close(fd); return false; } remaining -= count; pos += count; } close(fd); return count == 0 && remaining == 0; } /** Copies a file. * * \param source Path to the source file. * \param destination Path to the destination file. */ void atf_utils_copy_file(const char *source, const char *destination) { const int input = open(source, O_RDONLY); ATF_REQUIRE_MSG(input != -1, "Failed to open source file during " "copy (%s)", source); const int output = open(destination, O_WRONLY | O_CREAT | O_TRUNC, 0777); ATF_REQUIRE_MSG(output != -1, "Failed to open destination file during " "copy (%s)", destination); char buffer[1024]; ssize_t length; while ((length = read(input, buffer, sizeof(buffer))) > 0) ATF_REQUIRE_MSG(write(output, buffer, length) == length, "Failed to write to %s during copy", destination); ATF_REQUIRE_MSG(length != -1, "Failed to read from %s during copy", source); struct stat sb; ATF_REQUIRE_MSG(fstat(input, &sb) != -1, "Failed to stat source file %s during copy", source); ATF_REQUIRE_MSG(fchmod(output, sb.st_mode) != -1, "Failed to chmod destination file %s during copy", destination); close(output); close(input); } /** Creates a file. * * \param name Name of the file to create. * \param contents Text to write into the created file. * \param ... Positional parameters to the contents. */ void atf_utils_create_file(const char *name, const char *contents, ...) { va_list ap; atf_dynstr_t formatted; atf_error_t error; va_start(ap, contents); error = atf_dynstr_init_ap(&formatted, contents, ap); va_end(ap); ATF_REQUIRE(!atf_is_error(error)); const int fd = open(name, O_WRONLY | O_CREAT | O_TRUNC, 0644); ATF_REQUIRE_MSG(fd != -1, "Cannot create file %s", name); ATF_REQUIRE(write(fd, atf_dynstr_cstring(&formatted), atf_dynstr_length(&formatted)) != -1); close(fd); atf_dynstr_fini(&formatted); } /** Checks if a file exists. * * \param path Location of the file to check for. * * \return True if the file exists, false otherwise. */ bool atf_utils_file_exists(const char *path) { const int ret = access(path, F_OK); if (ret == -1) { if (errno != ENOENT) atf_tc_fail("Failed to check the existence of %s: %s", path, strerror(errno)); else return false; } else return true; } /** Spawns a subprocess and redirects its output to files. * * Use the atf_utils_wait() function to wait for the completion of the spawned * subprocess and validate its exit conditions. * * \return 0 in the new child; the PID of the new child in the parent. Does * not return in error conditions. */ pid_t atf_utils_fork(void) { const pid_t pid = fork(); if (pid == -1) atf_tc_fail("fork failed"); if (pid == 0) { - atf_utils_redirect(STDOUT_FILENO, "atf_utils_fork_out.txt"); - atf_utils_redirect(STDERR_FILENO, "atf_utils_fork_err.txt"); + atf_dynstr_t out_name; + init_out_filename(&out_name, getpid(), "out", false); + + atf_dynstr_t err_name; + init_out_filename(&err_name, getpid(), "err", false); + + atf_utils_redirect(STDOUT_FILENO, atf_dynstr_cstring(&out_name)); + atf_utils_redirect(STDERR_FILENO, atf_dynstr_cstring(&err_name)); + + atf_dynstr_fini(&err_name); + atf_dynstr_fini(&out_name); } return pid; } /** Frees an dynamically-allocated "argv" array. * * \param argv A dynamically-allocated array of dynamically-allocated * strings. */ void atf_utils_free_charpp(char **argv) { char **ptr; for (ptr = argv; *ptr != NULL; ptr++) free(*ptr); free(argv); } /** Searches for a regexp in a file. * * \param regex The regexp to look for. * \param file The file in which to look for the expression. * \param ... Positional parameters to the regex. * * \return True if there is a match; false otherwise. */ bool atf_utils_grep_file(const char *regex, const char *file, ...) { int fd; va_list ap; atf_dynstr_t formatted; atf_error_t error; va_start(ap, file); error = atf_dynstr_init_ap(&formatted, regex, ap); va_end(ap); ATF_REQUIRE(!atf_is_error(error)); ATF_REQUIRE((fd = open(file, O_RDONLY)) != -1); bool found = false; char *line = NULL; while (!found && (line = atf_utils_readline(fd)) != NULL) { found = grep_string(atf_dynstr_cstring(&formatted), line); free(line); } close(fd); atf_dynstr_fini(&formatted); return found; } /** Searches for a regexp in a string. * * \param regex The regexp to look for. * \param str The string in which to look for the expression. * \param ... Positional parameters to the regex. * * \return True if there is a match; false otherwise. */ bool atf_utils_grep_string(const char *regex, const char *str, ...) { bool res; va_list ap; atf_dynstr_t formatted; atf_error_t error; va_start(ap, str); error = atf_dynstr_init_ap(&formatted, regex, ap); va_end(ap); ATF_REQUIRE(!atf_is_error(error)); res = grep_string(atf_dynstr_cstring(&formatted), str); atf_dynstr_fini(&formatted); return res; } /** Reads a line of arbitrary length. * * \param fd The descriptor from which to read the line. * * \return A pointer to the read line, which must be released with free(), or * NULL if there was nothing to read from the file. */ char * atf_utils_readline(const int fd) { char ch; ssize_t cnt; atf_dynstr_t temp; atf_error_t error; error = atf_dynstr_init(&temp); ATF_REQUIRE(!atf_is_error(error)); while ((cnt = read(fd, &ch, sizeof(ch))) == sizeof(ch) && ch != '\n') { error = atf_dynstr_append_fmt(&temp, "%c", ch); ATF_REQUIRE(!atf_is_error(error)); } ATF_REQUIRE(cnt != -1); if (cnt == 0 && atf_dynstr_length(&temp) == 0) { atf_dynstr_fini(&temp); return NULL; } else return atf_dynstr_fini_disown(&temp); } /** Redirects a file descriptor to a file. * * \param target_fd The file descriptor to be replaced. * \param name The name of the file to direct the descriptor to. * * \pre Should only be called from the process spawned by fork_for_testing * because this exits uncontrolledly. * \post Terminates execution if the redirection fails. */ void atf_utils_redirect(const int target_fd, const char *name) { if (target_fd == STDOUT_FILENO) fflush(stdout); else if (target_fd == STDERR_FILENO) fflush(stderr); const int new_fd = open(name, O_WRONLY | O_CREAT | O_TRUNC, 0644); if (new_fd == -1) err(EXIT_FAILURE, "Cannot create %s", name); if (new_fd != target_fd) { if (dup2(new_fd, target_fd) == -1) err(EXIT_FAILURE, "Cannot redirect to fd %d", target_fd); } close(new_fd); } /** Waits for a subprocess and validates its exit condition. * * \param pid The process to be waited for. Must have been started by * testutils_fork(). * \param exitstatus Expected exit status. * \param expout Expected contents of stdout. * \param experr Expected contents of stderr. */ void atf_utils_wait(const pid_t pid, const int exitstatus, const char *expout, const char *experr) { int status; ATF_REQUIRE(waitpid(pid, &status, 0) != -1); - atf_utils_cat_file("atf_utils_fork_out.txt", "subprocess stdout: "); - atf_utils_cat_file("atf_utils_fork_err.txt", "subprocess stderr: "); + atf_dynstr_t out_name; + init_out_filename(&out_name, pid, "out", true); + atf_dynstr_t err_name; + init_out_filename(&err_name, pid, "err", true); + + atf_utils_cat_file(atf_dynstr_cstring(&out_name), "subprocess stdout: "); + atf_utils_cat_file(atf_dynstr_cstring(&err_name), "subprocess stderr: "); + ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(exitstatus, WEXITSTATUS(status)); const char *save_prefix = "save:"; const size_t save_prefix_length = strlen(save_prefix); if (strlen(expout) > save_prefix_length && strncmp(expout, save_prefix, save_prefix_length) == 0) { - atf_utils_copy_file("atf_utils_fork_out.txt", + atf_utils_copy_file(atf_dynstr_cstring(&out_name), expout + save_prefix_length); } else { - ATF_REQUIRE(atf_utils_compare_file("atf_utils_fork_out.txt", expout)); + ATF_REQUIRE(atf_utils_compare_file(atf_dynstr_cstring(&out_name), + expout)); } if (strlen(experr) > save_prefix_length && strncmp(experr, save_prefix, save_prefix_length) == 0) { - atf_utils_copy_file("atf_utils_fork_err.txt", + atf_utils_copy_file(atf_dynstr_cstring(&err_name), experr + save_prefix_length); } else { - ATF_REQUIRE(atf_utils_compare_file("atf_utils_fork_err.txt", experr)); + ATF_REQUIRE(atf_utils_compare_file(atf_dynstr_cstring(&err_name), + experr)); } - ATF_REQUIRE(unlink("atf_utils_fork_out.txt") != -1); - ATF_REQUIRE(unlink("atf_utils_fork_err.txt") != -1); + ATF_REQUIRE(unlink(atf_dynstr_cstring(&out_name)) != -1); + ATF_REQUIRE(unlink(atf_dynstr_cstring(&err_name)) != -1); } Index: head/contrib/atf/atf-c/utils.h =================================================================== --- head/contrib/atf/atf-c/utils.h (revision 273928) +++ head/contrib/atf/atf-c/utils.h (revision 273929) @@ -1,54 +1,50 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2010 The NetBSD Foundation, Inc. +/* Copyright (c) 2010 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_UTILS_H) #define ATF_C_UTILS_H #include #include #include void atf_utils_cat_file(const char *, const char *); bool atf_utils_compare_file(const char *, const char *); void atf_utils_copy_file(const char *, const char *); void atf_utils_create_file(const char *, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(2, 3); bool atf_utils_file_exists(const char *); pid_t atf_utils_fork(void); void atf_utils_free_charpp(char **); bool atf_utils_grep_file(const char *, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 3); bool atf_utils_grep_string(const char *, const char *, ...) ATF_DEFS_ATTRIBUTE_FORMAT_PRINTF(1, 3); char *atf_utils_readline(int); void atf_utils_redirect(const int, const char *); void atf_utils_wait(const pid_t, const int, const char *, const char *); -#endif /* ATF_C_UTILS_H */ +#endif /* !defined(ATF_C_UTILS_H) */ Index: head/contrib/atf/atf-c/utils_test.c =================================================================== --- head/contrib/atf/atf-c/utils_test.c (revision 273928) +++ head/contrib/atf/atf-c/utils_test.c (revision 273929) @@ -1,538 +1,570 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2010 The NetBSD Foundation, Inc. +/* Copyright (c) 2010 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "atf-c/utils.h" + #include #include #include #include #include #include #include #include #include -#include "atf-c/utils.h" +#include "atf-c/detail/dynstr.h" +#include "atf-c/detail/test_helpers.h" -#include "detail/test_helpers.h" - /** Reads the contents of a file into a buffer. * * Up to buflen-1 characters are read into buffer. If this function returns, * the contents read into the buffer are guaranteed to be nul-terminated. * Note, however, that if the file contains any nul characters itself, * comparing it "as a string" will not work. * * \param path The file to be read, which must exist. * \param buffer Buffer into which to store the file contents. * \param buflen Size of the target buffer. * * \return The count of bytes read. */ static ssize_t read_file(const char *path, void *const buffer, const size_t buflen) { const int fd = open(path, O_RDONLY); ATF_REQUIRE_MSG(fd != -1, "Cannot open %s", path); const ssize_t length = read(fd, buffer, buflen - 1); close(fd); ATF_REQUIRE(length != -1); ((char *)buffer)[length] = '\0'; return length; } ATF_TC_WITHOUT_HEAD(cat_file__empty); ATF_TC_BODY(cat_file__empty, tc) { atf_utils_create_file("file.txt", "%s", ""); atf_utils_redirect(STDOUT_FILENO, "captured.txt"); atf_utils_cat_file("file.txt", "PREFIX"); fflush(stdout); close(STDOUT_FILENO); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("", buffer); } ATF_TC_WITHOUT_HEAD(cat_file__one_line); ATF_TC_BODY(cat_file__one_line, tc) { atf_utils_create_file("file.txt", "This is a single line\n"); atf_utils_redirect(STDOUT_FILENO, "captured.txt"); atf_utils_cat_file("file.txt", "PREFIX"); fflush(stdout); close(STDOUT_FILENO); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("PREFIXThis is a single line\n", buffer); } ATF_TC_WITHOUT_HEAD(cat_file__several_lines); ATF_TC_BODY(cat_file__several_lines, tc) { atf_utils_create_file("file.txt", "First\nSecond line\nAnd third\n"); atf_utils_redirect(STDOUT_FILENO, "captured.txt"); atf_utils_cat_file("file.txt", ">"); fflush(stdout); close(STDOUT_FILENO); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ(">First\n>Second line\n>And third\n", buffer); } ATF_TC_WITHOUT_HEAD(cat_file__no_newline_eof); ATF_TC_BODY(cat_file__no_newline_eof, tc) { atf_utils_create_file("file.txt", "Foo\n bar baz"); atf_utils_redirect(STDOUT_FILENO, "captured.txt"); atf_utils_cat_file("file.txt", "PREFIX"); fflush(stdout); close(STDOUT_FILENO); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("PREFIXFoo\nPREFIX bar baz", buffer); } ATF_TC_WITHOUT_HEAD(compare_file__empty__match); ATF_TC_BODY(compare_file__empty__match, tc) { atf_utils_create_file("test.txt", "%s", ""); ATF_REQUIRE(atf_utils_compare_file("test.txt", "")); } ATF_TC_WITHOUT_HEAD(compare_file__empty__not_match); ATF_TC_BODY(compare_file__empty__not_match, tc) { atf_utils_create_file("test.txt", "%s", ""); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "\n")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "foo")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", " ")); } ATF_TC_WITHOUT_HEAD(compare_file__short__match); ATF_TC_BODY(compare_file__short__match, tc) { atf_utils_create_file("test.txt", "this is a short file"); ATF_REQUIRE(atf_utils_compare_file("test.txt", "this is a short file")); } ATF_TC_WITHOUT_HEAD(compare_file__short__not_match); ATF_TC_BODY(compare_file__short__not_match, tc) { atf_utils_create_file("test.txt", "this is a short file"); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "\n")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "this is a Short file")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "this is a short fil")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "this is a short file ")); } ATF_TC_WITHOUT_HEAD(compare_file__long__match); ATF_TC_BODY(compare_file__long__match, tc) { char long_contents[3456]; size_t i = 0; for (; i < sizeof(long_contents) - 1; i++) long_contents[i] = '0' + (i % 10); long_contents[i] = '\0'; atf_utils_create_file("test.txt", "%s", long_contents); ATF_REQUIRE(atf_utils_compare_file("test.txt", long_contents)); } ATF_TC_WITHOUT_HEAD(compare_file__long__not_match); ATF_TC_BODY(compare_file__long__not_match, tc) { char long_contents[3456]; size_t i = 0; for (; i < sizeof(long_contents) - 1; i++) long_contents[i] = '0' + (i % 10); long_contents[i] = '\0'; atf_utils_create_file("test.txt", "%s", long_contents); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "\n")); ATF_REQUIRE(!atf_utils_compare_file("test.txt", "0123456789")); long_contents[i - 1] = 'Z'; ATF_REQUIRE(!atf_utils_compare_file("test.txt", long_contents)); } ATF_TC_WITHOUT_HEAD(copy_file__empty); ATF_TC_BODY(copy_file__empty, tc) { atf_utils_create_file("src.txt", "%s", ""); ATF_REQUIRE(chmod("src.txt", 0520) != -1); atf_utils_copy_file("src.txt", "dest.txt"); ATF_REQUIRE(atf_utils_compare_file("dest.txt", "")); struct stat sb; ATF_REQUIRE(stat("dest.txt", &sb) != -1); ATF_REQUIRE_EQ(0520, sb.st_mode & 0xfff); } ATF_TC_WITHOUT_HEAD(copy_file__some_contents); ATF_TC_BODY(copy_file__some_contents, tc) { atf_utils_create_file("src.txt", "This is a\ntest file\n"); atf_utils_copy_file("src.txt", "dest.txt"); ATF_REQUIRE(atf_utils_compare_file("dest.txt", "This is a\ntest file\n")); } ATF_TC_WITHOUT_HEAD(create_file); ATF_TC_BODY(create_file, tc) { atf_utils_create_file("test.txt", "This is a test with %d", 12345); char buffer[128]; read_file("test.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("This is a test with 12345", buffer); } ATF_TC_WITHOUT_HEAD(file_exists); ATF_TC_BODY(file_exists, tc) { atf_utils_create_file("test.txt", "foo"); ATF_REQUIRE( atf_utils_file_exists("test.txt")); ATF_REQUIRE( atf_utils_file_exists("./test.txt")); ATF_REQUIRE(!atf_utils_file_exists("./test.tx")); ATF_REQUIRE(!atf_utils_file_exists("test.txt2")); } ATF_TC_WITHOUT_HEAD(fork); ATF_TC_BODY(fork, tc) { fprintf(stdout, "Should not get into child\n"); fprintf(stderr, "Should not get into child\n"); pid_t pid = atf_utils_fork(); if (pid == 0) { fprintf(stdout, "Child stdout\n"); fprintf(stderr, "Child stderr\n"); exit(EXIT_SUCCESS); } int status; ATF_REQUIRE(waitpid(pid, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); + atf_dynstr_t out_name; + RE(atf_dynstr_init_fmt(&out_name, "atf_utils_fork_%d_out.txt", (int)pid)); + atf_dynstr_t err_name; + RE(atf_dynstr_init_fmt(&err_name, "atf_utils_fork_%d_err.txt", (int)pid)); + char buffer[1024]; - read_file("atf_utils_fork_out.txt", buffer, sizeof(buffer)); + read_file(atf_dynstr_cstring(&out_name), buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("Child stdout\n", buffer); - read_file("atf_utils_fork_err.txt", buffer, sizeof(buffer)); + read_file(atf_dynstr_cstring(&err_name), buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("Child stderr\n", buffer); + + atf_dynstr_fini(&err_name); + atf_dynstr_fini(&out_name); } ATF_TC_WITHOUT_HEAD(free_charpp__empty); ATF_TC_BODY(free_charpp__empty, tc) { char **array = malloc(sizeof(char *) * 1); array[0] = NULL; atf_utils_free_charpp(array); } ATF_TC_WITHOUT_HEAD(free_charpp__some); ATF_TC_BODY(free_charpp__some, tc) { char **array = malloc(sizeof(char *) * 4); array[0] = strdup("first"); array[1] = strdup("second"); array[2] = strdup("third"); array[3] = NULL; atf_utils_free_charpp(array); } ATF_TC_WITHOUT_HEAD(grep_file); ATF_TC_BODY(grep_file, tc) { atf_utils_create_file("test.txt", "line1\nthe second line\naaaabbbb\n"); ATF_CHECK(atf_utils_grep_file("line1", "test.txt")); ATF_CHECK(atf_utils_grep_file("line%d", "test.txt", 1)); ATF_CHECK(atf_utils_grep_file("second line", "test.txt")); ATF_CHECK(atf_utils_grep_file("aa.*bb", "test.txt")); ATF_CHECK(!atf_utils_grep_file("foo", "test.txt")); ATF_CHECK(!atf_utils_grep_file("bar", "test.txt")); ATF_CHECK(!atf_utils_grep_file("aaaaa", "test.txt")); } ATF_TC_WITHOUT_HEAD(grep_string); ATF_TC_BODY(grep_string, tc) { const char *str = "a string - aaaabbbb"; ATF_CHECK(atf_utils_grep_string("a string", str)); ATF_CHECK(atf_utils_grep_string("^a string", str)); ATF_CHECK(atf_utils_grep_string("aaaabbbb$", str)); ATF_CHECK(atf_utils_grep_string("a%s*bb", str, "a.")); ATF_CHECK(!atf_utils_grep_string("foo", str)); ATF_CHECK(!atf_utils_grep_string("bar", str)); ATF_CHECK(!atf_utils_grep_string("aaaaa", str)); } ATF_TC_WITHOUT_HEAD(readline__none); ATF_TC_BODY(readline__none, tc) { atf_utils_create_file("empty.txt", "%s", ""); const int fd = open("empty.txt", O_RDONLY); ATF_REQUIRE(fd != -1); ATF_REQUIRE(atf_utils_readline(fd) == NULL); close(fd); } ATF_TC_WITHOUT_HEAD(readline__some); ATF_TC_BODY(readline__some, tc) { const char *l1 = "First line with % formatting % characters %"; const char *l2 = "Second line; much longer than the first one"; const char *l3 = "Last line, without terminator"; atf_utils_create_file("test.txt", "%s\n%s\n%s", l1, l2, l3); const int fd = open("test.txt", O_RDONLY); ATF_REQUIRE(fd != -1); char *line; line = atf_utils_readline(fd); ATF_REQUIRE_STREQ(l1, line); free(line); line = atf_utils_readline(fd); ATF_REQUIRE_STREQ(l2, line); free(line); line = atf_utils_readline(fd); ATF_REQUIRE_STREQ(l3, line); free(line); close(fd); } ATF_TC_WITHOUT_HEAD(redirect__stdout); ATF_TC_BODY(redirect__stdout, tc) { printf("Buffer this"); atf_utils_redirect(STDOUT_FILENO, "captured.txt"); printf("The printed message"); fflush(stdout); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("The printed message", buffer); } ATF_TC_WITHOUT_HEAD(redirect__stderr); ATF_TC_BODY(redirect__stderr, tc) { fprintf(stderr, "Buffer this"); atf_utils_redirect(STDERR_FILENO, "captured.txt"); fprintf(stderr, "The printed message"); fflush(stderr); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ("The printed message", buffer); } ATF_TC_WITHOUT_HEAD(redirect__other); ATF_TC_BODY(redirect__other, tc) { const char *message = "Foo bar\nbaz\n"; atf_utils_redirect(15, "captured.txt"); ATF_REQUIRE(write(15, message, strlen(message)) != -1); close(15); char buffer[1024]; read_file("captured.txt", buffer, sizeof(buffer)); ATF_REQUIRE_STREQ(message, buffer); } static void fork_and_wait(const int exitstatus, const char* expout, const char* experr) { const pid_t pid = atf_utils_fork(); + ATF_REQUIRE(pid != -1); if (pid == 0) { fprintf(stdout, "Some output\n"); fprintf(stderr, "Some error\n"); exit(123); } atf_utils_wait(pid, exitstatus, expout, experr); exit(EXIT_SUCCESS); } ATF_TC_WITHOUT_HEAD(wait__ok); ATF_TC_BODY(wait__ok, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); } } +ATF_TC_WITHOUT_HEAD(wait__ok_nested); +ATF_TC_BODY(wait__ok_nested, tc) +{ + const pid_t parent = atf_utils_fork(); + ATF_REQUIRE(parent != -1); + if (parent == 0) { + const pid_t child = atf_utils_fork(); + ATF_REQUIRE(child != -1); + if (child == 0) { + fflush(stderr); + fprintf(stdout, "Child output\n"); + fflush(stdout); + fprintf(stderr, "Child error\n"); + exit(50); + } else { + fprintf(stdout, "Parent output\n"); + fprintf(stderr, "Parent error\n"); + atf_utils_wait(child, 50, "Child output\n", "Child error\n"); + exit(40); + } + } else { + atf_utils_wait(parent, 40, + "Parent output\n" + "subprocess stdout: Child output\n" + "subprocess stderr: Child error\n", + "Parent error\n"); + } +} + ATF_TC_WITHOUT_HEAD(wait__invalid_exitstatus); ATF_TC_BODY(wait__invalid_exitstatus, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(120, "Some output\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TC_WITHOUT_HEAD(wait__invalid_stdout); ATF_TC_BODY(wait__invalid_stdout, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output foo\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TC_WITHOUT_HEAD(wait__invalid_stderr); ATF_TC_BODY(wait__invalid_stderr, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "Some error foo\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TC_WITHOUT_HEAD(wait__save_stdout); ATF_TC_BODY(wait__save_stdout, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "save:my-output.txt", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); ATF_REQUIRE(atf_utils_compare_file("my-output.txt", "Some output\n")); } } ATF_TC_WITHOUT_HEAD(wait__save_stderr); ATF_TC_BODY(wait__save_stderr, tc) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "save:my-output.txt"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); ATF_REQUIRE(atf_utils_compare_file("my-output.txt", "Some error\n")); } } -HEADER_TC(include, "atf-c/utils.h"); - ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, cat_file__empty); ATF_TP_ADD_TC(tp, cat_file__one_line); ATF_TP_ADD_TC(tp, cat_file__several_lines); ATF_TP_ADD_TC(tp, cat_file__no_newline_eof); ATF_TP_ADD_TC(tp, compare_file__empty__match); ATF_TP_ADD_TC(tp, compare_file__empty__not_match); ATF_TP_ADD_TC(tp, compare_file__short__match); ATF_TP_ADD_TC(tp, compare_file__short__not_match); ATF_TP_ADD_TC(tp, compare_file__long__match); ATF_TP_ADD_TC(tp, compare_file__long__not_match); ATF_TP_ADD_TC(tp, copy_file__empty); ATF_TP_ADD_TC(tp, copy_file__some_contents); ATF_TP_ADD_TC(tp, create_file); ATF_TP_ADD_TC(tp, file_exists); ATF_TP_ADD_TC(tp, fork); ATF_TP_ADD_TC(tp, free_charpp__empty); ATF_TP_ADD_TC(tp, free_charpp__some); ATF_TP_ADD_TC(tp, grep_file); ATF_TP_ADD_TC(tp, grep_string); ATF_TP_ADD_TC(tp, readline__none); ATF_TP_ADD_TC(tp, readline__some); ATF_TP_ADD_TC(tp, redirect__stdout); ATF_TP_ADD_TC(tp, redirect__stderr); ATF_TP_ADD_TC(tp, redirect__other); ATF_TP_ADD_TC(tp, wait__ok); + ATF_TP_ADD_TC(tp, wait__ok_nested); ATF_TP_ADD_TC(tp, wait__save_stdout); ATF_TP_ADD_TC(tp, wait__save_stderr); ATF_TP_ADD_TC(tp, wait__invalid_exitstatus); ATF_TP_ADD_TC(tp, wait__invalid_stdout); ATF_TP_ADD_TC(tp, wait__invalid_stderr); - - ATF_TP_ADD_TC(tp, include); return atf_no_error(); } Index: head/contrib/atf/atf-c++/config_test.cpp =================================================================== --- head/contrib/atf/atf-c++/config_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/config_test.cpp (nonexistent) @@ -1,227 +0,0 @@ -// -// Automated Testing Framework (atf) -// -// Copyright (c) 2007 The NetBSD Foundation, Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND -// CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -// IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY -// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE -// GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER -// IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR -// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -// IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#include -#include - -#include "config.hpp" -#include "macros.hpp" - -#include "detail/env.hpp" -#include "detail/exceptions.hpp" -#include "detail/test_helpers.hpp" - -static const char *test_value = "env-value"; - -static struct varnames { - const char *lc; - const char *uc; - bool can_be_empty; -} all_vars[] = { - { "atf_build_cc", "ATF_BUILD_CC", false }, - { "atf_build_cflags", "ATF_BUILD_CFLAGS", true }, - { "atf_build_cpp", "ATF_BUILD_CPP", false }, - { "atf_build_cppflags", "ATF_BUILD_CPPFLAGS", true }, - { "atf_build_cxx", "ATF_BUILD_CXX", false }, - { "atf_build_cxxflags", "ATF_BUILD_CXXFLAGS", true }, - { "atf_includedir", "ATF_INCLUDEDIR", false }, - { "atf_libexecdir", "ATF_LIBEXECDIR", false }, - { "atf_pkgdatadir", "ATF_PKGDATADIR", false }, - { "atf_shell", "ATF_SHELL", false }, - { "atf_workdir", "ATF_WORKDIR", false }, - { NULL, NULL, false } -}; - -// ------------------------------------------------------------------------ -// Auxiliary functions. -// ------------------------------------------------------------------------ - -namespace atf { - namespace config { - void __reinit(void); - } -} - -static -void -set_env_var(const char* name, const char* val) -{ - try { - atf::env::set(name, val); - } catch (const atf::system_error&) { - ATF_FAIL(std::string("set_env_var(") + name + ", " + val + - ") failed"); - } -} - -static -void -unset_env_var(const char* name) -{ - try { - atf::env::unset(name); - } catch (const atf::system_error&) { - ATF_FAIL(std::string("unset_env_var(") + name + ") failed"); - } -} - -static -size_t -all_vars_count(void) -{ - size_t count = 0; - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - count++; - return count; -} - -static -void -unset_all(void) -{ - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - unset_env_var(v->uc); -} - -static -void -compare_one(const char* var, const char* expvalue) -{ - std::cout << "Checking that " << var << " is set to " << expvalue << "\n"; - - for (const struct varnames* v = all_vars; v->lc != NULL; v++) { - if (std::strcmp(v->lc, var) == 0) - ATF_REQUIRE_EQ(atf::config::get(v->lc), test_value); - else - ATF_REQUIRE(atf::config::get(v->lc) != test_value); - } -} - -// ------------------------------------------------------------------------ -// Test cases for the free functions. -// ------------------------------------------------------------------------ - -ATF_TEST_CASE(get); -ATF_TEST_CASE_HEAD(get) -{ - set_md_var("descr", "Tests the config::get function"); -} -ATF_TEST_CASE_BODY(get) -{ - // Unset all known environment variables and make sure the built-in - // values do not match the bogus value we will use for testing. - unset_all(); - atf::config::__reinit(); - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - ATF_REQUIRE(atf::config::get(v->lc) != test_value); - - // Test the behavior of empty values. - for (const struct varnames* v = all_vars; v->lc != NULL; v++) { - unset_all(); - if (!atf::config::get(v->lc).empty()) { - set_env_var(v->uc, ""); - atf::config::__reinit(); - if (v->can_be_empty) - ATF_REQUIRE(atf::config::get(v->lc).empty()); - else - ATF_REQUIRE(!atf::config::get(v->lc).empty()); - } - } - - // Check if the ATF_ARCH variable is recognized. - for (const struct varnames* v = all_vars; v->lc != NULL; v++) { - unset_all(); - set_env_var(v->uc, test_value); - atf::config::__reinit(); - compare_one(v->lc, test_value); - } -} - -ATF_TEST_CASE(get_all); -ATF_TEST_CASE_HEAD(get_all) -{ - set_md_var("descr", "Tests the config::get_all function"); -} -ATF_TEST_CASE_BODY(get_all) -{ - atf::config::__reinit(); - - // Check that the valid variables, and only those, are returned. - std::map< std::string, std::string > vars = atf::config::get_all(); - ATF_REQUIRE_EQ(vars.size(), all_vars_count()); - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - ATF_REQUIRE(vars.find(v->lc) != vars.end()); -} - -ATF_TEST_CASE(has); -ATF_TEST_CASE_HEAD(has) -{ - set_md_var("descr", "Tests the config::has function"); -} -ATF_TEST_CASE_BODY(has) -{ - atf::config::__reinit(); - - // Check for all the variables that must exist. - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - ATF_REQUIRE(atf::config::has(v->lc)); - - // Same as above, but using uppercase (which is incorrect). - for (const struct varnames* v = all_vars; v->lc != NULL; v++) - ATF_REQUIRE(!atf::config::has(v->uc)); - - // Check for some other variables that cannot exist. - ATF_REQUIRE(!atf::config::has("foo")); - ATF_REQUIRE(!atf::config::has("BAR")); - ATF_REQUIRE(!atf::config::has("atf_foo")); - ATF_REQUIRE(!atf::config::has("ATF_BAR")); - ATF_REQUIRE(!atf::config::has("atf_shel")); - ATF_REQUIRE(!atf::config::has("atf_shells")); -} - -// ------------------------------------------------------------------------ -// Tests cases for the header file. -// ------------------------------------------------------------------------ - -HEADER_TC(include, "atf-c++/config.hpp"); - -// ------------------------------------------------------------------------ -// Main. -// ------------------------------------------------------------------------ - -ATF_INIT_TEST_CASES(tcs) -{ - // Add the test cases for the free functions. - ATF_ADD_TEST_CASE(tcs, has); - ATF_ADD_TEST_CASE(tcs, get); - ATF_ADD_TEST_CASE(tcs, get_all); - - // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); -} Index: head/contrib/atf/atf-c++/config.hpp =================================================================== --- head/contrib/atf/atf-c++/config.hpp (revision 273928) +++ head/contrib/atf/atf-c++/config.hpp (nonexistent) @@ -1,75 +0,0 @@ -// -// Automated Testing Framework (atf) -// -// Copyright (c) 2007 The NetBSD Foundation, Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND -// CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -// IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY -// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE -// GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER -// IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR -// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -// IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#if !defined(_ATF_CXX_CONFIG_HPP_) -#define _ATF_CXX_CONFIG_HPP_ - -#include -#include - -namespace atf { - -namespace config { - -//! -//! \brief Gets a build-time configuration variable's value. -//! -//! Given the name of a build-time configuration variable, returns its -//! textual value. The user is free to override these by setting their -//! corresponding environment variables. Therefore always use this -//! interface to get the value of these variables. -//! -//! \pre The variable must exist. -//! -const std::string& get(const std::string&); - -//! -//! \brief Returns all the build-time configuration variables. -//! -//! Returns a name to value map containing all build-time configuration -//! variables. -//! -const std::map< std::string, std::string >& get_all(void); - -//! -//! \brief Checks whether a build-time configuration variable exists. -//! -//! Given the name of a build-time configuration variable, checks -//! whether it is defined and returns a boolean indicating this -//! condition. The program only has to use this function to sanity-check -//! a variable name provided by the user. Otherwise it can assume that -//! the variables are defined. -//! -bool has(const std::string&); - -} // namespace config - -} // namespace atf - -#endif // !defined(_ATF_CXX_CONFIG_HPP_) Index: head/contrib/atf/atf-c++/config.cpp =================================================================== --- head/contrib/atf/atf-c++/config.cpp (revision 273928) +++ head/contrib/atf/atf-c++/config.cpp (nonexistent) @@ -1,119 +0,0 @@ -// -// Automated Testing Framework (atf) -// -// Copyright (c) 2007 The NetBSD Foundation, Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND -// CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -// IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY -// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE -// GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER -// IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR -// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -// IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#include - -extern "C" { -#include "atf-c/config.h" -} - -#include "config.hpp" - -#include "detail/env.hpp" -#include "detail/sanity.hpp" - -static std::map< std::string, std::string > m_variables; - -// -// Adds all predefined standard build-time variables to the m_variables -// map, considering the values a user may have provided in the environment. -// -// Can only be called once during the program's lifetime. -// -static -void -init_variables(void) -{ - PRE(m_variables.empty()); - - m_variables["atf_build_cc"] = atf_config_get("atf_build_cc"); - m_variables["atf_build_cflags"] = atf_config_get("atf_build_cflags"); - m_variables["atf_build_cpp"] = atf_config_get("atf_build_cpp"); - m_variables["atf_build_cppflags"] = atf_config_get("atf_build_cppflags"); - m_variables["atf_build_cxx"] = atf_config_get("atf_build_cxx"); - m_variables["atf_build_cxxflags"] = atf_config_get("atf_build_cxxflags"); - m_variables["atf_includedir"] = atf_config_get("atf_includedir"); - m_variables["atf_libexecdir"] = atf_config_get("atf_libexecdir"); - m_variables["atf_pkgdatadir"] = atf_config_get("atf_pkgdatadir"); - m_variables["atf_shell"] = atf_config_get("atf_shell"); - m_variables["atf_workdir"] = atf_config_get("atf_workdir"); - - POST(!m_variables.empty()); -} - -const std::string& -atf::config::get(const std::string& varname) -{ - if (m_variables.empty()) - init_variables(); - - PRE(has(varname)); - return m_variables[varname]; -} - -const std::map< std::string, std::string >& -atf::config::get_all(void) -{ - if (m_variables.empty()) - init_variables(); - - return m_variables; -} - -bool -atf::config::has(const std::string& varname) -{ - if (m_variables.empty()) - init_variables(); - - return m_variables.find(varname) != m_variables.end(); -} - -extern "C" { -void __atf_config_reinit(void); -} - -namespace atf { -namespace config { -// -// Auxiliary function for the t_config test program so that it can -// revert the configuration's global status to an empty state and -// do new tests from there on. -// -// Ideally this shouldn't be part of the production library... but -// this is so small that it does not matter. -// -void -__reinit(void) -{ - __atf_config_reinit(); - m_variables.clear(); -} -} // namespace config -} // namespace atf Index: head/contrib/atf/atf-c++/Kyuafile =================================================================== --- head/contrib/atf/atf-c++/Kyuafile (revision 273928) +++ head/contrib/atf/atf-c++/Kyuafile (revision 273929) @@ -1,14 +1,13 @@ syntax("kyuafile", 1) test_suite("atf") atf_test_program{name="atf_c++_test"} atf_test_program{name="build_test"} atf_test_program{name="check_test"} -atf_test_program{name="config_test"} atf_test_program{name="macros_test"} atf_test_program{name="pkg_config_test"} atf_test_program{name="tests_test"} atf_test_program{name="utils_test"} include("detail/Kyuafile") Index: head/contrib/atf/atf-c++/atf-c++.3 =================================================================== --- head/contrib/atf/atf-c++/atf-c++.3 (nonexistent) +++ head/contrib/atf/atf-c++/atf-c++.3 (revision 273929) @@ -0,0 +1,649 @@ +.\" Copyright (c) 2008 The NetBSD Foundation, Inc. +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND +.\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +.\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.Dd October 13, 2014 +.Dt ATF-C++ 3 +.Os +.Sh NAME +.Nm atf-c++ , +.Nm ATF_ADD_TEST_CASE , +.Nm ATF_CHECK_ERRNO , +.Nm ATF_FAIL , +.Nm ATF_INIT_TEST_CASES , +.Nm ATF_PASS , +.Nm ATF_REQUIRE , +.Nm ATF_REQUIRE_EQ , +.Nm ATF_REQUIRE_ERRNO , +.Nm ATF_REQUIRE_IN , +.Nm ATF_REQUIRE_MATCH , +.Nm ATF_REQUIRE_NOT_IN , +.Nm ATF_REQUIRE_THROW , +.Nm ATF_REQUIRE_THROW_RE , +.Nm ATF_SKIP , +.Nm ATF_TEST_CASE , +.Nm ATF_TEST_CASE_BODY , +.Nm ATF_TEST_CASE_CLEANUP , +.Nm ATF_TEST_CASE_HEAD , +.Nm ATF_TEST_CASE_NAME , +.Nm ATF_TEST_CASE_USE , +.Nm ATF_TEST_CASE_WITH_CLEANUP , +.Nm ATF_TEST_CASE_WITHOUT_HEAD , +.Nm atf::utils::cat_file , +.Nm atf::utils::compare_file , +.Nm atf::utils::copy_file , +.Nm atf::utils::create_file , +.Nm atf::utils::file_exists , +.Nm atf::utils::fork , +.Nm atf::utils::grep_collection , +.Nm atf::utils::grep_file , +.Nm atf::utils::grep_string , +.Nm atf::utils::redirect , +.Nm atf::utils::wait +.Nd C++ API to write ATF-based test programs +.Sh SYNOPSIS +.In atf-c++.hpp +.Fn ATF_ADD_TEST_CASE "tcs" "name" +.Fn ATF_CHECK_ERRNO "expected_errno" "bool_expression" +.Fn ATF_FAIL "reason" +.Fn ATF_INIT_TEST_CASES "tcs" +.Fn ATF_PASS +.Fn ATF_REQUIRE "expression" +.Fn ATF_REQUIRE_EQ "expected_expression" "actual_expression" +.Fn ATF_REQUIRE_ERRNO "expected_errno" "bool_expression" +.Fn ATF_REQUIRE_IN "element" "collection" +.Fn ATF_REQUIRE_MATCH "regexp" "string_expression" +.Fn ATF_REQUIRE_NOT_IN "element" "collection" +.Fn ATF_REQUIRE_THROW "expected_exception" "statement" +.Fn ATF_REQUIRE_THROW_RE "expected_exception" "regexp" "statement" +.Fn ATF_SKIP "reason" +.Fn ATF_TEST_CASE "name" +.Fn ATF_TEST_CASE_BODY "name" +.Fn ATF_TEST_CASE_CLEANUP "name" +.Fn ATF_TEST_CASE_HEAD "name" +.Fn ATF_TEST_CASE_NAME "name" +.Fn ATF_TEST_CASE_USE "name" +.Fn ATF_TEST_CASE_WITH_CLEANUP "name" +.Fn ATF_TEST_CASE_WITHOUT_HEAD "name" +.Ft void +.Fo atf::utils::cat_file +.Fa "const std::string& path" +.Fa "const std::string& prefix" +.Fc +.Ft bool +.Fo atf::utils::compare_file +.Fa "const std::string& path" +.Fa "const std::string& contents" +.Fc +.Ft void +.Fo atf::utils::copy_file +.Fa "const std::string& source" +.Fa "const std::string& destination" +.Fc +.Ft void +.Fo atf::utils::create_file +.Fa "const std::string& path" +.Fa "const std::string& contents" +.Fc +.Ft void +.Fo atf::utils::file_exists +.Fa "const std::string& path" +.Fc +.Ft pid_t +.Fo atf::utils::fork +.Fa "void" +.Fc +.Ft bool +.Fo atf::utils::grep_collection +.Fa "const std::string& regexp" +.Fa "const Collection& collection" +.Fc +.Ft bool +.Fo atf::utils::grep_file +.Fa "const std::string& regexp" +.Fa "const std::string& path" +.Fc +.Ft bool +.Fo atf::utils::grep_string +.Fa "const std::string& regexp" +.Fa "const std::string& path" +.Fc +.Ft void +.Fo atf::utils::redirect +.Fa "const int fd" +.Fa "const std::string& path" +.Fc +.Ft void +.Fo atf::utils::wait +.Fa "const pid_t pid" +.Fa "const int expected_exit_status" +.Fa "const std::string& expected_stdout" +.Fa "const std::string& expected_stderr" +.Fc +.Sh DESCRIPTION +ATF provides a C++ programming interface to implement test programs. +C++-based test programs follow this template: +.Bd -literal -offset indent +extern "C" { +.Ns ... C-specific includes go here ... +} + +.Ns ... C++-specific includes go here ... + +#include + +ATF_TEST_CASE(tc1); +ATF_TEST_CASE_HEAD(tc1) +{ + ... first test case's header ... +} +ATF_TEST_CASE_BODY(tc1) +{ + ... first test case's body ... +} + +ATF_TEST_CASE_WITH_CLEANUP(tc2); +ATF_TEST_CASE_HEAD(tc2) +{ + ... second test case's header ... +} +ATF_TEST_CASE_BODY(tc2) +{ + ... second test case's body ... +} +ATF_TEST_CASE_CLEANUP(tc2) +{ + ... second test case's cleanup ... +} + +ATF_TEST_CASE(tc3); +ATF_TEST_CASE_BODY(tc3) +{ + ... third test case's body ... +} + +.Ns ... additional test cases ... + +ATF_INIT_TEST_CASES(tcs) +{ + ATF_ADD_TEST_CASE(tcs, tc1); + ATF_ADD_TEST_CASE(tcs, tc2); + ATF_ADD_TEST_CASE(tcs, tc3); + ... add additional test cases ... +} +.Ed +.Ss Definition of test cases +Test cases have an identifier and are composed of three different parts: +the header, the body and an optional cleanup routine, all of which are +described in +.Xr atf-test-case 4 . +To define test cases, one can use the +.Fn ATF_TEST_CASE , +.Fn ATF_TEST_CASE_WITH_CLEANUP +or the +.Fn ATF_TEST_CASE_WITHOUT_HEAD +macros, which take a single parameter specifiying the test case's +name. +.Fn ATF_TEST_CASE , +requires to define a head and a body for the test case, +.Fn ATF_TEST_CASE_WITH_CLEANUP +requires to define a head, a body and a cleanup for the test case and +.Fn ATF_TEST_CASE_WITHOUT_HEAD +requires only a body for the test case. +It is important to note that these +.Em do not +set the test case up for execution when the program is run. +In order to do so, a later registration is needed through the +.Fn ATF_ADD_TEST_CASE +macro detailed in +.Sx Program initialization . +.Pp +Later on, one must define the three parts of the body by means of three +functions. +Their headers are given by the +.Fn ATF_TEST_CASE_HEAD , +.Fn ATF_TEST_CASE_BODY +and +.Fn ATF_TEST_CASE_CLEANUP +macros, all of which take the test case's name. +Following each of these, a block of code is expected, surrounded by the +opening and closing brackets. +.Pp +Additionally, the +.Fn ATF_TEST_CASE_NAME +macro can be used to obtain the name of the class corresponding to a +particular test case, as the name is internally manged by the library to +prevent clashes with other user identifiers. +Similarly, the +.Fn ATF_TEST_CASE_USE +macro can be executed on a particular test case to mark it as "used" and +thus prevent compiler warnings regarding unused symbols. +Note that +.Em you should never have to use these macros during regular operation. +.Ss Program initialization +The library provides a way to easily define the test program's +.Fn main +function. +You should never define one on your own, but rely on the +library to do it for you. +This is done by using the +.Fn ATF_INIT_TEST_CASES +macro, which is passed the name of the list that will hold the test cases. +This name can be whatever you want as long as it is a valid variable value. +.Pp +After the macro, you are supposed to provide the body of a function, which +should only use the +.Fn ATF_ADD_TEST_CASE +macro to register the test cases the test program will execute. +The first parameter of this macro matches the name you provided in the +former call. +.Ss Header definitions +The test case's header can define the meta-data by using the +.Fn set_md_var +method, which takes two parameters: the first one specifies the +meta-data variable to be set and the second one specifies its value. +Both of them are strings. +.Ss Configuration variables +The test case has read-only access to the current configuration variables +by means of the +.Ft bool +.Fn has_config_var +and the +.Ft std::string +.Fn get_config_var +methods, which can be called in any of the three parts of a test case. +.Ss Access to the source directory +It is possible to get the path to the test case's source directory from any +of its three components by querying the +.Sq srcdir +configuration variable. +.Ss Requiring programs +Aside from the +.Va require.progs +meta-data variable available in the header only, one can also check for +additional programs in the test case's body by using the +.Fn require_prog +function, which takes the base name or full path of a single binary. +Relative paths are forbidden. +If it is not found, the test case will be automatically skipped. +.Ss Test case finalization +The test case finalizes either when the body reaches its end, at which +point the test is assumed to have +.Em passed , +or at any explicit call to +.Fn ATF_PASS , +.Fn ATF_FAIL +or +.Fn ATF_SKIP . +These three macros terminate the execution of the test case immediately. +The cleanup routine will be processed afterwards in a completely automated +way, regardless of the test case's termination reason. +.Pp +.Fn ATF_PASS +does not take any parameters. +.Fn ATF_FAIL +and +.Fn ATF_SKIP +take a single string that describes why the test case failed or +was skipped, respectively. +It is very important to provide a clear error message in both cases so that +the user can quickly know why the test did not pass. +.Ss Expectations +Everything explained in the previous section changes when the test case +expectations are redefined by the programmer. +.Pp +Each test case has an internal state called +.Sq expect +that describes what the test case expectations are at any point in time. +The value of this property can change during execution by any of: +.Bl -tag -width indent +.It Fn expect_death "reason" +Expects the test case to exit prematurely regardless of the nature of the +exit. +.It Fn expect_exit "exitcode" "reason" +Expects the test case to exit cleanly. +If +.Va exitcode +is not +.Sq -1 , +the runtime engine will validate that the exit code of the test case +matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Fn expect_fail "reason" +Any failure (be it fatal or non-fatal) raised in this mode is recorded. +However, such failures do not report the test case as failed; instead, the +test case finalizes cleanly and is reported as +.Sq expected failure ; +this report includes the provided +.Fa reason +as part of it. +If no error is raised while running in this mode, then the test case is +reported as +.Sq failed . +.Pp +This mode is useful to reproduce actual known bugs in tests. +Whenever the developer fixes the bug later on, the test case will start +reporting a failure, signaling the developer that the test case must be +adjusted to the new conditions. +In this situation, it is useful, for example, to set +.Fa reason +as the bug number for tracking purposes. +.It Fn expect_pass +This is the normal mode of execution. +In this mode, any failure is reported as such to the user and the test case +is marked as +.Sq failed . +.It Fn expect_race "reason" +Any failure or timeout during the execution of the test case will be +considered as if a race condition has been triggered and reported as such. +If no problems arise, the test will continue execution as usual. +.It Fn expect_signal "signo" "reason" +Expects the test case to terminate due to the reception of a signal. +If +.Va signo +is not +.Sq -1 , +the runtime engine will validate that the signal that terminated the test +case matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Fn expect_timeout "reason" +Expects the test case to execute for longer than its timeout. +.El +.Ss Helper macros for common checks +The library provides several macros that are very handy in multiple +situations. +These basically check some condition after executing a given statement or +processing a given expression and, if the condition is not met, they +automatically call +.Fn ATF_FAIL +with an appropriate error message. +.Pp +.Fn ATF_REQUIRE +takes an expression and raises a failure if it evaluates to false. +.Pp +.Fn ATF_REQUIRE_EQ +takes two expressions and raises a failure if the two do not evaluate to +the same exact value. +The common style is to put the expected value in the first parameter and the +actual value in the second parameter. +.Pp +.Fn ATF_REQUIRE_IN +takes an element and a collection and validates that the element is present in +the collection. +.Pp +.Fn ATF_REQUIRE_MATCH +takes a regular expression and a string and raises a failure if the regular +expression does not match the string. +.Pp +.Fn ATF_REQUIRE_NOT_IN +takes an element and a collection and validates that the element is not present +in the collection. +.Pp +.Fn ATF_REQUIRE_THROW +takes the name of an exception and a statement and raises a failure if +the statement does not throw the specified exception. +.Fn ATF_REQUIRE_THROW_RE +takes the name of an exception, a regular expresion and a statement and raises a +failure if the statement does not throw the specified exception and if the +message of the exception does not match the regular expression. +.Pp +.Fn ATF_CHECK_ERRNO +and +.Fn ATF_REQUIRE_ERRNO +take, first, the error code that the check is expecting to find in the +.Va errno +variable and, second, a boolean expression that, if evaluates to true, +means that a call failed and +.Va errno +has to be checked against the first value. +.Ss Utility functions +The following functions are provided as part of the +.Nm +API to simplify the creation of a variety of tests. +In particular, these are useful to write tests for command-line interfaces. +.Pp +.Ft void +.Fo atf::utils::cat_file +.Fa "const std::string& path" +.Fa "const std::string& prefix" +.Fc +.Bd -ragged -offset indent +Prints the contents of +.Fa path +to the standard output, prefixing every line with the string in +.Fa prefix . +.Ed +.Pp +.Ft bool +.Fo atf::utils::compare_file +.Fa "const std::string& path" +.Fa "const std::string& contents" +.Fc +.Bd -ragged -offset indent +Returns true if the given +.Fa path +matches exactly the expected inlined +.Fa contents . +.Ed +.Pp +.Ft void +.Fo atf::utils::copy_file +.Fa "const std::string& source" +.Fa "const std::string& destination" +.Fc +.Bd -ragged -offset indent +Copies the file +.Fa source +to +.Fa destination . +The permissions of the file are preserved during the code. +.Ed +.Pp +.Ft void +.Fo atf::utils::create_file +.Fa "const std::string& path" +.Fa "const std::string& contents" +.Fc +.Bd -ragged -offset indent +Creates +.Fa file +with the text given in +.Fa contents . +.Ed +.Pp +.Ft void +.Fo atf::utils::file_exists +.Fa "const std::string& path" +.Fc +.Bd -ragged -offset indent +Checks if +.Fa path +exists. +.Ed +.Pp +.Ft pid_t +.Fo atf::utils::fork +.Fa "void" +.Fc +.Bd -ragged -offset indent +Forks a process and redirects the standard output and standard error of the +child to files for later validation with +.Fn atf::utils::wait . +Fails the test case if the fork fails, so this does not return an error. +.Ed +.Pp +.Ft bool +.Fo atf::utils::grep_collection +.Fa "const std::string& regexp" +.Fa "const Collection& collection" +.Fc +.Bd -ragged -offset indent +Searches for the regular expression +.Fa regexp +in any of the strings contained in the +.Fa collection . +This is a template that accepts any one-dimensional container of strings. +.Ed +.Pp +.Ft bool +.Fo atf::utils::grep_file +.Fa "const std::string& regexp" +.Fa "const std::string& path" +.Fc +.Bd -ragged -offset indent +Searches for the regular expression +.Fa regexp +in the file +.Fa path . +The variable arguments are used to construct the regular expression. +.Ed +.Pp +.Ft bool +.Fo atf::utils::grep_string +.Fa "const std::string& regexp" +.Fa "const std::string& str" +.Fc +.Bd -ragged -offset indent +Searches for the regular expression +.Fa regexp +in the string +.Fa str . +.Ed +.Ft void +.Fo atf::utils::redirect +.Fa "const int fd" +.Fa "const std::string& path" +.Fc +.Bd -ragged -offset indent +Redirects the given file descriptor +.Fa fd +to the file +.Fa path . +This function exits the process in case of an error and does not properly mark +the test case as failed. +As a result, it should only be used in subprocesses of the test case; specially +those spawned by +.Fn atf::utils::fork . +.Ed +.Pp +.Ft void +.Fo atf::utils::wait +.Fa "const pid_t pid" +.Fa "const int expected_exit_status" +.Fa "const std::string& expected_stdout" +.Fa "const std::string& expected_stderr" +.Fc +.Bd -ragged -offset indent +Waits and validates the result of a subprocess spawned with +.Fn atf::utils::wait . +The validation involves checking that the subprocess exited cleanly and returned +the code specified in +.Fa expected_exit_status +and that its standard output and standard error match the strings given in +.Fa expected_stdout +and +.Fa expected_stderr . +.Pp +If any of the +.Fa expected_stdout +or +.Fa expected_stderr +strings are prefixed with +.Sq save: , +then they specify the name of the file into which to store the stdout or stderr +of the subprocess, and no comparison is performed. +.Ed +.Sh ENVIRONMENT +The following variables are recognized by +.Nm +but should not be overridden other than for testing purposes: +.Pp +.Bl -tag -width ATFXBUILDXCXXFLAGSXX -compact +.It Va ATF_BUILD_CC +Path to the C compiler. +.It Va ATF_BUILD_CFLAGS +C compiler flags. +.It Va ATF_BUILD_CPP +Path to the C/C++ preprocessor. +.It Va ATF_BUILD_CPPFLAGS +C/C++ preprocessor flags. +.It Va ATF_BUILD_CXX +Path to the C++ compiler. +.It Va ATF_BUILD_CXXFLAGS +C++ compiler flags. +.El +.Sh EXAMPLES +The following shows a complete test program with a single test case that +validates the addition operator: +.Bd -literal -offset indent +#include + +ATF_TEST_CASE(addition); +ATF_TEST_CASE_HEAD(addition) +{ + set_md_var("descr", "Sample tests for the addition operator"); +} +ATF_TEST_CASE_BODY(addition) +{ + ATF_REQUIRE_EQ(0, 0 + 0); + ATF_REQUIRE_EQ(1, 0 + 1); + ATF_REQUIRE_EQ(1, 1 + 0); + + ATF_REQUIRE_EQ(2, 1 + 1); + + ATF_REQUIRE_EQ(300, 100 + 200); +} + +ATF_TEST_CASE(open_failure); +ATF_TEST_CASE_HEAD(open_failure) +{ + set_md_var("descr", "Sample tests for the open function"); +} +ATF_TEST_CASE_BODY(open_failure) +{ + ATF_REQUIRE_ERRNO(ENOENT, open("non-existent", O_RDONLY) == -1); +} + +ATF_TEST_CASE(known_bug); +ATF_TEST_CASE_HEAD(known_bug) +{ + set_md_var("descr", "Reproduces a known bug"); +} +ATF_TEST_CASE_BODY(known_bug) +{ + expect_fail("See bug number foo/bar"); + ATF_REQUIRE_EQ(3, 1 + 1); + expect_pass(); + ATF_REQUIRE_EQ(3, 1 + 2); +} + +ATF_INIT_TEST_CASES(tcs) +{ + ATF_ADD_TEST_CASE(tcs, addition); + ATF_ADD_TEST_CASE(tcs, open_failure); + ATF_ADD_TEST_CASE(tcs, known_bug); +} +.Ed +.Sh SEE ALSO +.Xr atf-test-program 1 , +.Xr atf-test-case 4 Property changes on: head/contrib/atf/atf-c++/atf-c++.3 ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/contrib/atf/atf-c++/atf_c++_test.cpp =================================================================== --- head/contrib/atf/atf-c++/atf_c++_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/atf_c++_test.cpp (revision 273929) @@ -1,48 +1,44 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#include "macros.hpp" +#include -#include "detail/test_helpers.hpp" +#include "atf-c++/detail/test_helpers.hpp" // ------------------------------------------------------------------------ // Tests cases for the header file. // ------------------------------------------------------------------------ HEADER_TC(include, "atf-c++.hpp"); // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the header file. ATF_ADD_TEST_CASE(tcs, include); } Index: head/contrib/atf/atf-c++/build.cpp =================================================================== --- head/contrib/atf/atf-c++/build.cpp (revision 273928) +++ head/contrib/atf/atf-c++/build.cpp (revision 273929) @@ -1,119 +1,115 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/build.hpp" + extern "C" { #include "atf-c/build.h" #include "atf-c/error.h" #include "atf-c/utils.h" } -#include "build.hpp" - -#include "detail/exceptions.hpp" -#include "detail/process.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/process.hpp" namespace impl = atf::build; #define IMPL_NAME "atf::build" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ inline atf::process::argv_array cargv_to_argv(const atf_list_t* l) { std::vector< const char* > aux; atf_list_citer_t iter; atf_list_for_each_c(iter, l) aux.push_back(static_cast< const char* >(atf_list_citer_data(iter))); return atf::process::argv_array(aux); } inline atf::process::argv_array cargv_to_argv_and_free(char** l) { try { atf::process::argv_array argv((const char* const*)l); atf_utils_free_charpp(l); return argv; } catch (...) { atf_utils_free_charpp(l); throw; } } // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ atf::process::argv_array impl::c_o(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { char** l; atf_error_t err = atf_build_c_o(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &l); if (atf_is_error(err)) throw_atf_error(err); return cargv_to_argv_and_free(l); } atf::process::argv_array impl::cpp(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { char** l; atf_error_t err = atf_build_cpp(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &l); if (atf_is_error(err)) throw_atf_error(err); return cargv_to_argv_and_free(l); } atf::process::argv_array impl::cxx_o(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { char** l; atf_error_t err = atf_build_cxx_o(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &l); if (atf_is_error(err)) throw_atf_error(err); return cargv_to_argv_and_free(l); } Index: head/contrib/atf/atf-c++/build.hpp =================================================================== --- head/contrib/atf/atf-c++/build.hpp (revision 273928) +++ head/contrib/atf/atf-c++/build.hpp (revision 273929) @@ -1,57 +1,53 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_BUILD_HPP_) -#define _ATF_CXX_BUILD_HPP_ +#if !defined(ATF_CXX_BUILD_HPP) +#define ATF_CXX_BUILD_HPP #include namespace atf { namespace process { class argv_array; } // namespace process namespace build { // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ process::argv_array c_o(const std::string&, const std::string&, const process::argv_array&); process::argv_array cpp(const std::string&, const std::string&, const process::argv_array&); process::argv_array cxx_o(const std::string&, const std::string&, const process::argv_array&); } // namespace build } // namespace atf -#endif // !defined(_ATF_CXX_BUILD_HPP_) +#endif // !defined(ATF_CXX_BUILD_HPP) Index: head/contrib/atf/atf-c++/build_test.cpp =================================================================== --- head/contrib/atf/atf-c++/build_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/build_test.cpp (revision 273929) @@ -1,247 +1,226 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/build.hpp" + #include #include -#include "../atf-c/h_build.h" +#include -#include "build.hpp" -#include "config.hpp" -#include "macros.hpp" +extern "C" { +#include "atf-c/h_build.h" +} -#include "detail/env.hpp" -#include "detail/process.hpp" -#include "detail/test_helpers.hpp" +#include "atf-c++/detail/env.hpp" +#include "atf-c++/detail/process.hpp" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ -namespace atf { - namespace config { - void __reinit(void); - } -} - template< class C > void print_col(const char* prefix, const C& c) { std::cout << prefix << ":"; for (typename C::const_iterator iter = c.begin(); iter != c.end(); iter++) std::cout << " '" << *iter << "'"; std::cout << "\n"; } static void print_array(const char* prefix, const char* const* a) { std::cout << prefix << ":"; for (; *a != NULL; a++) std::cout << " '" << *a << "'"; std::cout << "\n"; } static void verbose_set_env(const char *var, const char *val) { std::cout << "Setting " << var << " to '" << val << "'\n"; atf::env::set(var, val); } static bool equal_argvs(const atf::process::argv_array& aa, const char* const* array) { bool equal = true; atf::process::argv_array::size_type i = 0; while (equal && (i < aa.size() && array[i] != NULL)) { if (std::strcmp(aa[i], array[i]) != 0) equal = false; else i++; } if (equal && (i < aa.size() || array[i] != NULL)) equal = false; return equal; } static void check_equal_argvs(const atf::process::argv_array& aa, const char* const* array) { print_array("Expected arguments", array); print_col("Arguments returned", aa); if (!equal_argvs(aa, array)) ATF_FAIL("The constructed argv differs from the expected values"); } // ------------------------------------------------------------------------ // Internal test cases. // ------------------------------------------------------------------------ ATF_TEST_CASE(equal_argvs); ATF_TEST_CASE_HEAD(equal_argvs) { set_md_var("descr", "Tests the test case internal equal_argvs function"); } ATF_TEST_CASE_BODY(equal_argvs) { { const char* const array[] = { NULL }; const char* const argv[] = { NULL }; ATF_REQUIRE(equal_argvs(atf::process::argv_array(argv), array)); } { const char* const array[] = { NULL }; const char* const argv[] = { "foo", NULL }; ATF_REQUIRE(!equal_argvs(atf::process::argv_array(argv), array)); } { const char* const array[] = { "foo", NULL }; const char* const argv[] = { NULL }; ATF_REQUIRE(!equal_argvs(atf::process::argv_array(argv), array)); } { const char* const array[] = { "foo", NULL }; const char* const argv[] = { "foo", NULL }; ATF_REQUIRE(equal_argvs(atf::process::argv_array(argv), array)); } } // ------------------------------------------------------------------------ // Test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(c_o); ATF_TEST_CASE_HEAD(c_o) { set_md_var("descr", "Tests the c_o function"); } ATF_TEST_CASE_BODY(c_o) { for (struct c_o_test* test = c_o_tests; test->expargv[0] != NULL; test++) { std::cout << "> Test: " << test->msg << "\n"; verbose_set_env("ATF_BUILD_CC", test->cc); verbose_set_env("ATF_BUILD_CFLAGS", test->cflags); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - atf::config::__reinit(); atf::process::argv_array argv = atf::build::c_o(test->sfile, test->ofile, atf::process::argv_array(test->optargs)); check_equal_argvs(argv, test->expargv); } } ATF_TEST_CASE(cpp); ATF_TEST_CASE_HEAD(cpp) { set_md_var("descr", "Tests the cpp function"); } ATF_TEST_CASE_BODY(cpp) { for (struct cpp_test* test = cpp_tests; test->expargv[0] != NULL; test++) { std::cout << "> Test: " << test->msg << "\n"; verbose_set_env("ATF_BUILD_CPP", test->cpp); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - atf::config::__reinit(); atf::process::argv_array argv = atf::build::cpp(test->sfile, test->ofile, atf::process::argv_array(test->optargs)); check_equal_argvs(argv, test->expargv); } } ATF_TEST_CASE(cxx_o); ATF_TEST_CASE_HEAD(cxx_o) { set_md_var("descr", "Tests the cxx_o function"); } ATF_TEST_CASE_BODY(cxx_o) { for (struct cxx_o_test* test = cxx_o_tests; test->expargv[0] != NULL; test++) { std::cout << "> Test: " << test->msg << "\n"; verbose_set_env("ATF_BUILD_CXX", test->cxx); verbose_set_env("ATF_BUILD_CXXFLAGS", test->cxxflags); verbose_set_env("ATF_BUILD_CPPFLAGS", test->cppflags); - atf::config::__reinit(); atf::process::argv_array argv = atf::build::cxx_o(test->sfile, test->ofile, atf::process::argv_array(test->optargs)); check_equal_argvs(argv, test->expargv); } } // ------------------------------------------------------------------------ -// Tests cases for the header file. -// ------------------------------------------------------------------------ - -HEADER_TC(include, "atf-c++/build.hpp"); - -// ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the internal test cases. ATF_ADD_TEST_CASE(tcs, equal_argvs); // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, c_o); ATF_ADD_TEST_CASE(tcs, cpp); ATF_ADD_TEST_CASE(tcs, cxx_o); - - // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); } Index: head/contrib/atf/atf-c++/check.cpp =================================================================== --- head/contrib/atf/atf-c++/check.cpp (revision 273928) +++ head/contrib/atf/atf-c++/check.cpp (revision 273929) @@ -1,158 +1,154 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/check.hpp" + #include extern "C" { #include "atf-c/build.h" #include "atf-c/error.h" } -#include "check.hpp" - -#include "detail/exceptions.hpp" -#include "detail/process.hpp" -#include "detail/sanity.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/process.hpp" +#include "atf-c++/detail/sanity.hpp" namespace impl = atf::check; #define IMPL_NAME "atf::check" // ------------------------------------------------------------------------ // The "check_result" class. // ------------------------------------------------------------------------ impl::check_result::check_result(const atf_check_result_t* result) { std::memcpy(&m_result, result, sizeof(m_result)); } impl::check_result::~check_result(void) { atf_check_result_fini(&m_result); } bool impl::check_result::exited(void) const { return atf_check_result_exited(&m_result); } int impl::check_result::exitcode(void) const { PRE(exited()); return atf_check_result_exitcode(&m_result); } bool impl::check_result::signaled(void) const { return atf_check_result_signaled(&m_result); } int impl::check_result::termsig(void) const { PRE(signaled()); return atf_check_result_termsig(&m_result); } const std::string impl::check_result::stdout_path(void) const { return atf_check_result_stdout(&m_result); } const std::string impl::check_result::stderr_path(void) const { return atf_check_result_stderr(&m_result); } // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ bool impl::build_c_o(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { bool success; atf_error_t err = atf_check_build_c_o(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &success); if (atf_is_error(err)) throw_atf_error(err); return success; } bool impl::build_cpp(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { bool success; atf_error_t err = atf_check_build_cpp(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &success); if (atf_is_error(err)) throw_atf_error(err); return success; } bool impl::build_cxx_o(const std::string& sfile, const std::string& ofile, const atf::process::argv_array& optargs) { bool success; atf_error_t err = atf_check_build_cxx_o(sfile.c_str(), ofile.c_str(), optargs.exec_argv(), &success); if (atf_is_error(err)) throw_atf_error(err); return success; } std::auto_ptr< impl::check_result > impl::exec(const atf::process::argv_array& argva) { atf_check_result_t result; atf_error_t err = atf_check_exec_array(argva.exec_argv(), &result); if (atf_is_error(err)) throw_atf_error(err); return std::auto_ptr< impl::check_result >(new impl::check_result(&result)); } Index: head/contrib/atf/atf-c++/check.hpp =================================================================== --- head/contrib/atf/atf-c++/check.hpp (revision 273928) +++ head/contrib/atf/atf-c++/check.hpp (revision 273929) @@ -1,135 +1,131 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_CHECK_HPP_) -#define _ATF_CXX_CHECK_HPP_ +#if !defined(ATF_CXX_CHECK_HPP) +#define ATF_CXX_CHECK_HPP extern "C" { #include } #include #include #include #include namespace atf { namespace process { class argv_array; } // namespace process namespace check { // ------------------------------------------------------------------------ // The "check_result" class. // ------------------------------------------------------------------------ //! //! \brief A class that contains results of executed command. //! //! The check_result class holds information about results //! of executing arbitrary command and manages files containing //! its output. //! class check_result { // Non-copyable. check_result(const check_result&); check_result& operator=(const check_result&); //! //! \brief Internal representation of a result. //! atf_check_result_t m_result; //! //! \brief Constructs a results object and grabs ownership of the //! parameter passed in. //! check_result(const atf_check_result_t* result); friend check_result test_constructor(const char* const*); friend std::auto_ptr< check_result > exec(const atf::process::argv_array&); public: //! //! \brief Destroys object and removes all managed files. //! ~check_result(void); //! //! \brief Returns whether the command exited correctly or not. //! bool exited(void) const; //! //! \brief Returns command's exit status. //! int exitcode(void) const; //! //! \brief Returns whether the command received a signal or not. //! bool signaled(void) const; //! //! \brief Returns the signal that terminated the command. //! int termsig(void) const; //! //! \brief Returns the path to file contaning command's stdout. //! const std::string stdout_path(void) const; //! //! \brief Returns the path to file contaning command's stderr. //! const std::string stderr_path(void) const; }; // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ bool build_c_o(const std::string&, const std::string&, const atf::process::argv_array&); bool build_cpp(const std::string&, const std::string&, const atf::process::argv_array&); bool build_cxx_o(const std::string&, const std::string&, const atf::process::argv_array&); std::auto_ptr< check_result > exec(const atf::process::argv_array&); // Useful for testing only. check_result test_constructor(void); } // namespace check } // namespace atf -#endif // !defined(_ATF_CXX_CHECK_HPP_) +#endif // !defined(ATF_CXX_CHECK_HPP) Index: head/contrib/atf/atf-c++/check_test.cpp =================================================================== --- head/contrib/atf/atf-c++/check_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/check_test.cpp (revision 273929) @@ -1,408 +1,394 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/check.hpp" + extern "C" { #include #include #include } #include #include #include #include #include #include #include #include -#include "check.hpp" -#include "config.hpp" -#include "utils.hpp" +#include "atf-c++/detail/fs.hpp" +#include "atf-c++/detail/process.hpp" +#include "atf-c++/detail/test_helpers.hpp" +#include "atf-c++/detail/text.hpp" +#include "atf-c++/utils.hpp" -#include "detail/fs.hpp" -#include "detail/process.hpp" -#include "detail/test_helpers.hpp" -#include "detail/text.hpp" - // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ static std::auto_ptr< atf::check::check_result > do_exec(const atf::tests::tc* tc, const char* helper_name) { std::vector< std::string > argv; argv.push_back(get_process_helpers_path(*tc, false).str()); argv.push_back(helper_name); std::cout << "Executing " << argv[0] << " " << argv[1] << "\n"; atf::process::argv_array argva(argv); return atf::check::exec(argva); } static std::auto_ptr< atf::check::check_result > do_exec(const atf::tests::tc* tc, const char* helper_name, const char *carg2) { std::vector< std::string > argv; argv.push_back(get_process_helpers_path(*tc, false).str()); argv.push_back(helper_name); argv.push_back(carg2); std::cout << "Executing " << argv[0] << " " << argv[1] << " " << argv[2] << "\n"; atf::process::argv_array argva(argv); return atf::check::exec(argva); } // ------------------------------------------------------------------------ // Helper test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(h_build_c_o_ok); ATF_TEST_CASE_HEAD(h_build_c_o_ok) { set_md_var("descr", "Helper test case for build_c_o"); } ATF_TEST_CASE_BODY(h_build_c_o_ok) { std::ofstream sfile("test.c"); sfile << "#include \n"; sfile.close(); ATF_REQUIRE(atf::check::build_c_o("test.c", "test.o", atf::process::argv_array())); } ATF_TEST_CASE(h_build_c_o_fail); ATF_TEST_CASE_HEAD(h_build_c_o_fail) { set_md_var("descr", "Helper test case for build_c_o"); } ATF_TEST_CASE_BODY(h_build_c_o_fail) { std::ofstream sfile("test.c"); sfile << "void foo(void) { int a = UNDEFINED_SYMBOL; }\n"; sfile.close(); ATF_REQUIRE(!atf::check::build_c_o("test.c", "test.o", atf::process::argv_array())); } ATF_TEST_CASE(h_build_cpp_ok); ATF_TEST_CASE_HEAD(h_build_cpp_ok) { set_md_var("descr", "Helper test case for build_cpp"); } ATF_TEST_CASE_BODY(h_build_cpp_ok) { std::ofstream sfile("test.c"); sfile << "#define A foo\n"; sfile << "#define B bar\n"; sfile << "A B\n"; sfile.close(); ATF_REQUIRE(atf::check::build_cpp("test.c", "test.p", atf::process::argv_array())); } ATF_TEST_CASE(h_build_cpp_fail); ATF_TEST_CASE_HEAD(h_build_cpp_fail) { set_md_var("descr", "Helper test case for build_cpp"); } ATF_TEST_CASE_BODY(h_build_cpp_fail) { std::ofstream sfile("test.c"); sfile << "#include \"./non-existent.h\"\n"; sfile.close(); ATF_REQUIRE(!atf::check::build_cpp("test.c", "test.p", atf::process::argv_array())); } ATF_TEST_CASE(h_build_cxx_o_ok); ATF_TEST_CASE_HEAD(h_build_cxx_o_ok) { set_md_var("descr", "Helper test case for build_cxx_o"); } ATF_TEST_CASE_BODY(h_build_cxx_o_ok) { std::ofstream sfile("test.cpp"); sfile << "#include \n"; sfile.close(); ATF_REQUIRE(atf::check::build_cxx_o("test.cpp", "test.o", atf::process::argv_array())); } ATF_TEST_CASE(h_build_cxx_o_fail); ATF_TEST_CASE_HEAD(h_build_cxx_o_fail) { set_md_var("descr", "Helper test case for build_cxx_o"); } ATF_TEST_CASE_BODY(h_build_cxx_o_fail) { std::ofstream sfile("test.cpp"); sfile << "void foo(void) { int a = UNDEFINED_SYMBOL; }\n"; sfile.close(); ATF_REQUIRE(!atf::check::build_cxx_o("test.cpp", "test.o", atf::process::argv_array())); } // ------------------------------------------------------------------------ // Test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(build_c_o); ATF_TEST_CASE_HEAD(build_c_o) { set_md_var("descr", "Tests the build_c_o function"); } ATF_TEST_CASE_BODY(build_c_o) { ATF_TEST_CASE_USE(h_build_c_o_ok); run_h_tc< ATF_TEST_CASE_NAME(h_build_c_o_ok) >(); ATF_REQUIRE(atf::utils::grep_file("-o test.o", "stdout")); ATF_REQUIRE(atf::utils::grep_file("-c test.c", "stdout")); ATF_TEST_CASE_USE(h_build_c_o_fail); run_h_tc< ATF_TEST_CASE_NAME(h_build_c_o_fail) >(); ATF_REQUIRE(atf::utils::grep_file("-o test.o", "stdout")); ATF_REQUIRE(atf::utils::grep_file("-c test.c", "stdout")); ATF_REQUIRE(atf::utils::grep_file("test.c", "stderr")); ATF_REQUIRE(atf::utils::grep_file("UNDEFINED_SYMBOL", "stderr")); } ATF_TEST_CASE(build_cpp); ATF_TEST_CASE_HEAD(build_cpp) { set_md_var("descr", "Tests the build_cpp function"); } ATF_TEST_CASE_BODY(build_cpp) { ATF_TEST_CASE_USE(h_build_cpp_ok); run_h_tc< ATF_TEST_CASE_NAME(h_build_cpp_ok) >(); ATF_REQUIRE(atf::utils::grep_file("-o.*test.p", "stdout")); ATF_REQUIRE(atf::utils::grep_file("test.c", "stdout")); ATF_REQUIRE(atf::utils::grep_file("foo bar", "test.p")); ATF_TEST_CASE_USE(h_build_cpp_fail); run_h_tc< ATF_TEST_CASE_NAME(h_build_cpp_fail) >(); ATF_REQUIRE(atf::utils::grep_file("-o test.p", "stdout")); ATF_REQUIRE(atf::utils::grep_file("test.c", "stdout")); ATF_REQUIRE(atf::utils::grep_file("test.c", "stderr")); ATF_REQUIRE(atf::utils::grep_file("non-existent.h", "stderr")); } ATF_TEST_CASE(build_cxx_o); ATF_TEST_CASE_HEAD(build_cxx_o) { set_md_var("descr", "Tests the build_cxx_o function"); } ATF_TEST_CASE_BODY(build_cxx_o) { ATF_TEST_CASE_USE(h_build_cxx_o_ok); run_h_tc< ATF_TEST_CASE_NAME(h_build_cxx_o_ok) >(); ATF_REQUIRE(atf::utils::grep_file("-o test.o", "stdout")); ATF_REQUIRE(atf::utils::grep_file("-c test.cpp", "stdout")); ATF_TEST_CASE_USE(h_build_cxx_o_fail); run_h_tc< ATF_TEST_CASE_NAME(h_build_cxx_o_fail) >(); ATF_REQUIRE(atf::utils::grep_file("-o test.o", "stdout")); ATF_REQUIRE(atf::utils::grep_file("-c test.cpp", "stdout")); ATF_REQUIRE(atf::utils::grep_file("test.cpp", "stderr")); ATF_REQUIRE(atf::utils::grep_file("UNDEFINED_SYMBOL", "stderr")); } ATF_TEST_CASE(exec_cleanup); ATF_TEST_CASE_HEAD(exec_cleanup) { set_md_var("descr", "Tests that exec properly cleans up the temporary " "files it creates"); } ATF_TEST_CASE_BODY(exec_cleanup) { std::auto_ptr< atf::fs::path > out; std::auto_ptr< atf::fs::path > err; { std::auto_ptr< atf::check::check_result > r = do_exec(this, "exit-success"); out.reset(new atf::fs::path(r->stdout_path())); err.reset(new atf::fs::path(r->stderr_path())); ATF_REQUIRE(atf::fs::exists(*out.get())); ATF_REQUIRE(atf::fs::exists(*err.get())); } ATF_REQUIRE(!atf::fs::exists(*out.get())); ATF_REQUIRE(!atf::fs::exists(*err.get())); } ATF_TEST_CASE(exec_exitstatus); ATF_TEST_CASE_HEAD(exec_exitstatus) { set_md_var("descr", "Tests that exec properly captures the exit " "status of the executed command"); } ATF_TEST_CASE_BODY(exec_exitstatus) { { std::auto_ptr< atf::check::check_result > r = do_exec(this, "exit-success"); ATF_REQUIRE(r->exited()); ATF_REQUIRE(!r->signaled()); ATF_REQUIRE_EQ(r->exitcode(), EXIT_SUCCESS); } { std::auto_ptr< atf::check::check_result > r = do_exec(this, "exit-failure"); ATF_REQUIRE(r->exited()); ATF_REQUIRE(!r->signaled()); ATF_REQUIRE_EQ(r->exitcode(), EXIT_FAILURE); } { std::auto_ptr< atf::check::check_result > r = do_exec(this, "exit-signal"); ATF_REQUIRE(!r->exited()); ATF_REQUIRE(r->signaled()); ATF_REQUIRE_EQ(r->termsig(), SIGKILL); } } static void check_lines(const std::string& path, const char* outname, const char* resname) { std::ifstream f(path.c_str()); ATF_REQUIRE(f); std::string line; std::getline(f, line); ATF_REQUIRE_EQ(line, std::string("Line 1 to ") + outname + " for " + resname); std::getline(f, line); ATF_REQUIRE_EQ(line, std::string("Line 2 to ") + outname + " for " + resname); } ATF_TEST_CASE(exec_stdout_stderr); ATF_TEST_CASE_HEAD(exec_stdout_stderr) { set_md_var("descr", "Tests that exec properly captures the stdout " "and stderr streams of the child process"); } ATF_TEST_CASE_BODY(exec_stdout_stderr) { std::auto_ptr< atf::check::check_result > r1 = do_exec(this, "stdout-stderr", "result1"); ATF_REQUIRE(r1->exited()); ATF_REQUIRE_EQ(r1->exitcode(), EXIT_SUCCESS); std::auto_ptr< atf::check::check_result > r2 = do_exec(this, "stdout-stderr", "result2"); ATF_REQUIRE(r2->exited()); ATF_REQUIRE_EQ(r2->exitcode(), EXIT_SUCCESS); const std::string out1 = r1->stdout_path(); const std::string out2 = r2->stdout_path(); const std::string err1 = r1->stderr_path(); const std::string err2 = r2->stderr_path(); ATF_REQUIRE(out1.find("check.XXXXXX") == std::string::npos); ATF_REQUIRE(out2.find("check.XXXXXX") == std::string::npos); ATF_REQUIRE(err1.find("check.XXXXXX") == std::string::npos); ATF_REQUIRE(err2.find("check.XXXXXX") == std::string::npos); ATF_REQUIRE(out1.find("/check") != std::string::npos); ATF_REQUIRE(out2.find("/check") != std::string::npos); ATF_REQUIRE(err1.find("/check") != std::string::npos); ATF_REQUIRE(err2.find("/check") != std::string::npos); ATF_REQUIRE(out1.find("/stdout") != std::string::npos); ATF_REQUIRE(out2.find("/stdout") != std::string::npos); ATF_REQUIRE(err1.find("/stderr") != std::string::npos); ATF_REQUIRE(err2.find("/stderr") != std::string::npos); ATF_REQUIRE(out1 != out2); ATF_REQUIRE(err1 != err2); check_lines(out1, "stdout", "result1"); check_lines(out2, "stdout", "result2"); check_lines(err1, "stderr", "result1"); check_lines(err2, "stderr", "result2"); } ATF_TEST_CASE(exec_unknown); ATF_TEST_CASE_HEAD(exec_unknown) { set_md_var("descr", "Tests that running a non-existing binary " "is handled correctly"); } ATF_TEST_CASE_BODY(exec_unknown) { std::vector< std::string > argv; - argv.push_back(atf::config::get("atf_workdir") + "/non-existent"); + argv.push_back("/foo/bar/non-existent"); atf::process::argv_array argva(argv); std::auto_ptr< atf::check::check_result > r = atf::check::exec(argva); ATF_REQUIRE(r->exited()); ATF_REQUIRE_EQ(r->exitcode(), 127); } // ------------------------------------------------------------------------ -// Tests cases for the header file. -// ------------------------------------------------------------------------ - -HEADER_TC(include, "atf-c++/check.hpp"); - -// ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, build_c_o); ATF_ADD_TEST_CASE(tcs, build_cpp); ATF_ADD_TEST_CASE(tcs, build_cxx_o); ATF_ADD_TEST_CASE(tcs, exec_cleanup); ATF_ADD_TEST_CASE(tcs, exec_exitstatus); ATF_ADD_TEST_CASE(tcs, exec_stdout_stderr); ATF_ADD_TEST_CASE(tcs, exec_unknown); - - // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); } Index: head/contrib/atf/atf-c++/detail/sanity_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/sanity_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/sanity_test.cpp (nonexistent) @@ -1,41 +0,0 @@ -// -// Automated Testing Framework (atf) -// -// Copyright (c) 2009 The NetBSD Foundation, Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND -// CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -// IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY -// DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE -// GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER -// IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR -// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN -// IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#include "../macros.hpp" - -ATF_TEST_CASE_WITHOUT_HEAD(nothing); -ATF_TEST_CASE_BODY(nothing) -{ - // TODO -} - -ATF_INIT_TEST_CASES(tcs) -{ - ATF_ADD_TEST_CASE(tcs, nothing); -} Index: head/contrib/atf/atf-c++/detail/Kyuafile =================================================================== --- head/contrib/atf/atf-c++/detail/Kyuafile (revision 273928) +++ head/contrib/atf/atf-c++/detail/Kyuafile (revision 273929) @@ -1,12 +1,11 @@ syntax("kyuafile", 1) test_suite("atf") atf_test_program{name="application_test"} atf_test_program{name="auto_array_test"} atf_test_program{name="env_test"} atf_test_program{name="exceptions_test"} atf_test_program{name="fs_test"} atf_test_program{name="process_test"} -atf_test_program{name="sanity_test"} atf_test_program{name="text_test"} Index: head/contrib/atf/atf-c++/detail/application.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/application.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/application.cpp (revision 273929) @@ -1,252 +1,249 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/application.hpp" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif extern "C" { #include } #include #include #include #include #include extern "C" { #include "atf-c/defs.h" } -#include "application.hpp" -#include "sanity.hpp" +#include "atf-c++/detail/sanity.hpp" #if !defined(HAVE_VSNPRINTF_IN_STD) namespace std { using ::vsnprintf; } #endif // !defined(HAVE_VSNPRINTF_IN_STD) namespace impl = atf::application; #define IMPL_NAME "atf::application" // ------------------------------------------------------------------------ // The "usage_error" class. // ------------------------------------------------------------------------ impl::usage_error::usage_error(const char *fmt, ...) throw() : std::runtime_error("usage_error; message unformatted") { va_list ap; va_start(ap, fmt); std::vsnprintf(m_text, sizeof(m_text), fmt, ap); va_end(ap); } impl::usage_error::~usage_error(void) throw() { } const char* impl::usage_error::what(void) const throw() { return m_text; } // ------------------------------------------------------------------------ // The "application" class. // ------------------------------------------------------------------------ impl::option::option(char ch, const std::string& a, const std::string& desc) : m_character(ch), m_argument(a), m_description(desc) { } bool impl::option::operator<(const impl::option& o) const { return m_character < o.m_character; } impl::app::app(const std::string& description, const std::string& manpage) : m_argc(-1), m_argv(NULL), m_prog_name(NULL), m_description(description), m_manpage(manpage) { } impl::app::~app(void) { } bool impl::app::inited(void) { return m_argc != -1; } impl::app::options_set impl::app::options(void) { return specific_options(); } std::string impl::app::specific_args(void) const { return ""; } impl::app::options_set impl::app::specific_options(void) const { return options_set(); } void impl::app::process_option(int ch ATF_DEFS_ATTRIBUTE_UNUSED, const char* arg ATF_DEFS_ATTRIBUTE_UNUSED) { } void impl::app::process_options(void) { PRE(inited()); std::string optstr; #if defined(HAVE_GNU_GETOPT) optstr += '+'; // Turn on POSIX behavior. #endif optstr += ':'; { options_set opts = options(); for (options_set::const_iterator iter = opts.begin(); iter != opts.end(); iter++) { const option& opt = (*iter); optstr += opt.m_character; if (!opt.m_argument.empty()) optstr += ':'; } } int ch; const int old_opterr = ::opterr; ::opterr = 0; while ((ch = ::getopt(m_argc, m_argv, optstr.c_str())) != -1) { switch (ch) { case ':': throw usage_error("Option -%c requires an argument.", ::optopt); case '?': throw usage_error("Unknown option -%c.", ::optopt); default: process_option(ch, ::optarg); } } m_argc -= ::optind; m_argv += ::optind; // Clear getopt state just in case the test wants to use it. opterr = old_opterr; optind = 1; #if defined(HAVE_OPTRESET) optreset = 1; #endif } int impl::app::run(int argc, char* const* argv) { PRE(argc > 0); PRE(argv != NULL); m_argc = argc; m_argv = argv; m_argv0 = m_argv[0]; m_prog_name = std::strrchr(m_argv[0], '/'); if (m_prog_name == NULL) m_prog_name = m_argv[0]; else m_prog_name++; // Libtool workaround: if running from within the source tree (binaries // that are not installed yet), skip the "lt-" prefix added to files in // the ".libs" directory to show the real (not temporary) name. if (std::strncmp(m_prog_name, "lt-", 3) == 0) m_prog_name += 3; const std::string bug = std::string("This is probably a bug in ") + m_prog_name + " or one of the libraries it uses. Please report this problem to " PACKAGE_BUGREPORT " and provide as many details as possible " "describing how you got to this condition."; int errcode; try { process_options(); errcode = main(); } catch (const usage_error& e) { std::cerr << m_prog_name << ": ERROR: " << e.what() << "\n"; std::cerr << m_prog_name << ": See " << m_manpage << " for usage " "details.\n"; errcode = EXIT_FAILURE; } catch (const std::runtime_error& e) { std::cerr << m_prog_name << ": ERROR: " << e.what() << "\n"; errcode = EXIT_FAILURE; } catch (const std::exception& e) { std::cerr << m_prog_name << ": ERROR: Caught unexpected error: " << e.what() << "\n"; errcode = EXIT_FAILURE; } catch (...) { std::cerr << m_prog_name << ": ERROR: Caught unknown error\n"; errcode = EXIT_FAILURE; } return errcode; } Index: head/contrib/atf/atf-c++/detail/application.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/application.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/application.hpp (revision 273929) @@ -1,111 +1,107 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_APPLICATION_HPP_) -#define _ATF_CXX_APPLICATION_HPP_ +#if !defined(ATF_CXX_DETAIL_APPLICATION_HPP) +#define ATF_CXX_DETAIL_APPLICATION_HPP #include #include #include #include namespace atf { namespace application { // ------------------------------------------------------------------------ // The "usage_error" class. // ------------------------------------------------------------------------ class usage_error : public std::runtime_error { char m_text[4096]; public: usage_error(const char*, ...) throw(); ~usage_error(void) throw(); const char* what(void) const throw(); }; // ------------------------------------------------------------------------ // The "option" class. // ------------------------------------------------------------------------ class option { char m_character; std::string m_argument; std::string m_description; friend class app; public: option(char, const std::string&, const std::string&); bool operator<(const option&) const; }; // ------------------------------------------------------------------------ // The "app" class. // ------------------------------------------------------------------------ class app { void process_options(void); void usage(std::ostream&); bool inited(void); protected: typedef std::set< option > options_set; int m_argc; char* const* m_argv; const char* m_argv0; const char* m_prog_name; std::string m_description; std::string m_manpage; options_set options(void); // To be redefined. virtual std::string specific_args(void) const; virtual options_set specific_options(void) const; virtual void process_option(int, const char*); virtual int main(void) = 0; public: app(const std::string&, const std::string&); virtual ~app(void); int run(int, char* const*); }; } // namespace application } // namespace atf -#endif // !defined(_ATF_CXX_APPLICATION_HPP_) +#endif // !defined(ATF_CXX_DETAIL_APPLICATION_HPP) Index: head/contrib/atf/atf-c++/detail/application_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/application_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/application_test.cpp (revision 273929) @@ -1,94 +1,90 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/application.hpp" + extern "C" { #include } -#include "application.hpp" - -#include "../macros.hpp" +#include class getopt_app : public atf::application::app { public: getopt_app(void) : app("description", "manpage") {} int main(void) { // Provide an option that is unknown to the application driver and // one that is, together with an argument that would be swallowed by // the test program option if it were recognized. int argc = 4; char arg1[] = "progname"; char arg2[] = "-Z"; char arg3[] = "-s"; char arg4[] = "foo"; char *const argv[] = { arg1, arg2, arg3, arg4, NULL }; int ch; bool zflag; // Given that this obviously is an application, and that we used the // same driver to start, we can test getopt(3) right here without doing // any fancy stuff. zflag = false; while ((ch = ::getopt(argc, argv, ":Z")) != -1) { switch (ch) { case 'Z': zflag = true; break; case '?': default: if (optopt != 's') ATF_FAIL("Unexpected unknown option found"); } } ATF_REQUIRE(zflag); ATF_REQUIRE_EQ(1, argc - optind); ATF_REQUIRE_EQ(std::string("foo"), argv[optind]); return 0; } }; ATF_TEST_CASE_WITHOUT_HEAD(getopt); ATF_TEST_CASE_BODY(getopt) { int argc = 1; char arg1[] = "progname"; char *const argv[] = { arg1, NULL }; ATF_REQUIRE_EQ(0, getopt_app().run(argc, argv)); } ATF_INIT_TEST_CASES(tcs) { ATF_ADD_TEST_CASE(tcs, getopt); } Index: head/contrib/atf/atf-c++/detail/auto_array.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/auto_array.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/auto_array.hpp (revision 273929) @@ -1,179 +1,175 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_AUTO_ARRAY_HPP_) -#define _ATF_CXX_AUTO_ARRAY_HPP_ +#if !defined(ATF_CXX_DETAIL_AUTO_ARRAY_HPP) +#define ATF_CXX_DETAIL_AUTO_ARRAY_HPP #include namespace atf { // ------------------------------------------------------------------------ // The "auto_array" class. // ------------------------------------------------------------------------ template< class T > struct auto_array_ref { T* m_ptr; explicit auto_array_ref(T*); }; template< class T > auto_array_ref< T >::auto_array_ref(T* ptr) : m_ptr(ptr) { } template< class T > class auto_array { T* m_ptr; public: auto_array(T* = NULL) throw(); auto_array(auto_array< T >&) throw(); auto_array(auto_array_ref< T >) throw(); ~auto_array(void) throw(); T* get(void) throw(); const T* get(void) const throw(); T* release(void) throw(); void reset(T* = NULL) throw(); auto_array< T >& operator=(auto_array< T >&) throw(); auto_array< T >& operator=(auto_array_ref< T >) throw(); T& operator[](int) throw(); operator auto_array_ref< T >(void) throw(); }; template< class T > auto_array< T >::auto_array(T* ptr) throw() : m_ptr(ptr) { } template< class T > auto_array< T >::auto_array(auto_array< T >& ptr) throw() : m_ptr(ptr.release()) { } template< class T > auto_array< T >::auto_array(auto_array_ref< T > ref) throw() : m_ptr(ref.m_ptr) { } template< class T > auto_array< T >::~auto_array(void) throw() { if (m_ptr != NULL) delete [] m_ptr; } template< class T > T* auto_array< T >::get(void) throw() { return m_ptr; } template< class T > const T* auto_array< T >::get(void) const throw() { return m_ptr; } template< class T > T* auto_array< T >::release(void) throw() { T* ptr = m_ptr; m_ptr = NULL; return ptr; } template< class T > void auto_array< T >::reset(T* ptr) throw() { if (m_ptr != NULL) delete [] m_ptr; m_ptr = ptr; } template< class T > auto_array< T >& auto_array< T >::operator=(auto_array< T >& ptr) throw() { reset(ptr.release()); return *this; } template< class T > auto_array< T >& auto_array< T >::operator=(auto_array_ref< T > ref) throw() { if (m_ptr != ref.m_ptr) { delete [] m_ptr; m_ptr = ref.m_ptr; } return *this; } template< class T > T& auto_array< T >::operator[](int pos) throw() { return m_ptr[pos]; } template< class T > auto_array< T >::operator auto_array_ref< T >(void) throw() { return auto_array_ref< T >(release()); } } // namespace atf -#endif // !defined(_ATF_CXX_AUTO_ARRAY_HPP_) +#endif // !defined(ATF_CXX_DETAIL_AUTO_ARRAY_HPP) Index: head/contrib/atf/atf-c++/detail/auto_array_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/auto_array_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/auto_array_test.cpp (revision 273929) @@ -1,304 +1,302 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/auto_array.hpp" + extern "C" { #include } #include -#include "atf-c/defs.h" +#include -#include "../macros.hpp" - -#include "auto_array.hpp" +extern "C" { +#include "atf-c/defs.h" +} // ------------------------------------------------------------------------ // Tests for the "auto_array" class. // ------------------------------------------------------------------------ class test_array { public: int m_value; static ssize_t m_nblocks; static atf::auto_array< test_array > do_copy(atf::auto_array< test_array >& ta) { return atf::auto_array< test_array >(ta); } void* operator new(size_t size ATF_DEFS_ATTRIBUTE_UNUSED) { ATF_FAIL("New called but should have been new[]"); return new int(5); } void* operator new[](size_t size) { m_nblocks++; void* mem = ::operator new(size); std::cout << "Allocated 'test_array' object " << mem << "\n"; return mem; } void operator delete(void* mem ATF_DEFS_ATTRIBUTE_UNUSED) { ATF_FAIL("Delete called but should have been delete[]"); } void operator delete[](void* mem) { std::cout << "Releasing 'test_array' object " << mem << "\n"; if (m_nblocks == 0) ATF_FAIL("Unbalanced delete[]"); m_nblocks--; ::operator delete(mem); } }; ssize_t test_array::m_nblocks = 0; ATF_TEST_CASE(auto_array_scope); ATF_TEST_CASE_HEAD(auto_array_scope) { set_md_var("descr", "Tests the automatic scope handling in the " "auto_array smart pointer class"); } ATF_TEST_CASE_BODY(auto_array_scope) { using atf::auto_array; ATF_REQUIRE_EQ(test_array::m_nblocks, 0); { auto_array< test_array > t(new test_array[10]); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_copy); ATF_TEST_CASE_HEAD(auto_array_copy) { set_md_var("descr", "Tests the auto_array smart pointer class' copy " "constructor"); } ATF_TEST_CASE_BODY(auto_array_copy) { using atf::auto_array; ATF_REQUIRE_EQ(test_array::m_nblocks, 0); { auto_array< test_array > t1(new test_array[10]); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); { auto_array< test_array > t2(t1); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_copy_ref); ATF_TEST_CASE_HEAD(auto_array_copy_ref) { set_md_var("descr", "Tests the auto_array smart pointer class' copy " "constructor through the auxiliary auto_array_ref object"); } ATF_TEST_CASE_BODY(auto_array_copy_ref) { using atf::auto_array; ATF_REQUIRE_EQ(test_array::m_nblocks, 0); { auto_array< test_array > t1(new test_array[10]); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); { auto_array< test_array > t2 = test_array::do_copy(t1); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_get); ATF_TEST_CASE_HEAD(auto_array_get) { set_md_var("descr", "Tests the auto_array smart pointer class' get " "method"); } ATF_TEST_CASE_BODY(auto_array_get) { using atf::auto_array; test_array* ta = new test_array[10]; auto_array< test_array > t(ta); ATF_REQUIRE_EQ(t.get(), ta); } ATF_TEST_CASE(auto_array_release); ATF_TEST_CASE_HEAD(auto_array_release) { set_md_var("descr", "Tests the auto_array smart pointer class' release " "method"); } ATF_TEST_CASE_BODY(auto_array_release) { using atf::auto_array; test_array* ta1 = new test_array[10]; { auto_array< test_array > t(ta1); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); test_array* ta2 = t.release(); ATF_REQUIRE_EQ(ta2, ta1); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 1); delete [] ta1; } ATF_TEST_CASE(auto_array_reset); ATF_TEST_CASE_HEAD(auto_array_reset) { set_md_var("descr", "Tests the auto_array smart pointer class' reset " "method"); } ATF_TEST_CASE_BODY(auto_array_reset) { using atf::auto_array; test_array* ta1 = new test_array[10]; test_array* ta2 = new test_array[10]; ATF_REQUIRE_EQ(test_array::m_nblocks, 2); { auto_array< test_array > t(ta1); ATF_REQUIRE_EQ(test_array::m_nblocks, 2); t.reset(ta2); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); t.reset(); ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_assign); ATF_TEST_CASE_HEAD(auto_array_assign) { set_md_var("descr", "Tests the auto_array smart pointer class' " "assignment operator"); } ATF_TEST_CASE_BODY(auto_array_assign) { using atf::auto_array; ATF_REQUIRE_EQ(test_array::m_nblocks, 0); { auto_array< test_array > t1(new test_array[10]); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); { auto_array< test_array > t2; t2 = t1; ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_assign_ref); ATF_TEST_CASE_HEAD(auto_array_assign_ref) { set_md_var("descr", "Tests the auto_array smart pointer class' " "assignment operator through the auxiliary auto_array_ref " "object"); } ATF_TEST_CASE_BODY(auto_array_assign_ref) { using atf::auto_array; ATF_REQUIRE_EQ(test_array::m_nblocks, 0); { auto_array< test_array > t1(new test_array[10]); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); { auto_array< test_array > t2; t2 = test_array::do_copy(t1); ATF_REQUIRE_EQ(test_array::m_nblocks, 1); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_REQUIRE_EQ(test_array::m_nblocks, 0); } ATF_TEST_CASE(auto_array_access); ATF_TEST_CASE_HEAD(auto_array_access) { set_md_var("descr", "Tests the auto_array smart pointer class' access " "operator"); } ATF_TEST_CASE_BODY(auto_array_access) { using atf::auto_array; auto_array< test_array > t(new test_array[10]); for (int i = 0; i < 10; i++) t[i].m_value = i * 2; for (int i = 0; i < 10; i++) ATF_REQUIRE_EQ(t[i].m_value, i * 2); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test for the "auto_array" class. ATF_ADD_TEST_CASE(tcs, auto_array_scope); ATF_ADD_TEST_CASE(tcs, auto_array_copy); ATF_ADD_TEST_CASE(tcs, auto_array_copy_ref); ATF_ADD_TEST_CASE(tcs, auto_array_get); ATF_ADD_TEST_CASE(tcs, auto_array_release); ATF_ADD_TEST_CASE(tcs, auto_array_reset); ATF_ADD_TEST_CASE(tcs, auto_array_assign); ATF_ADD_TEST_CASE(tcs, auto_array_assign_ref); ATF_ADD_TEST_CASE(tcs, auto_array_access); } Index: head/contrib/atf/atf-c++/detail/env.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/env.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/env.cpp (revision 273929) @@ -1,73 +1,75 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -extern "C" { -#include "../../atf-c/error.h" +#include "atf-c++/detail/env.hpp" -#include "../../atf-c/detail/env.h" +extern "C" { +#include "atf-c/detail/env.h" +#include "atf-c/error.h" } -#include "env.hpp" -#include "exceptions.hpp" -#include "sanity.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/sanity.hpp" namespace impl = atf::env; #define IMPL_NAME "atf::env" // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ std::string impl::get(const std::string& name) { return atf_env_get(name.c_str()); +} + +std::string +impl::get(const std::string& name, const std::string& default_value) +{ + return atf_env_get_with_default(name.c_str(), default_value.c_str()); } bool impl::has(const std::string& name) { return atf_env_has(name.c_str()); } void impl::set(const std::string& name, const std::string& val) { atf_error_t err = atf_env_set(name.c_str(), val.c_str()); if (atf_is_error(err)) throw_atf_error(err); } void impl::unset(const std::string& name) { atf_error_t err = atf_env_unset(name.c_str()); if (atf_is_error(err)) throw_atf_error(err); } Index: head/contrib/atf/atf-c++/detail/env.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/env.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/env.hpp (revision 273929) @@ -1,84 +1,85 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_ENV_HPP_) -#define _ATF_CXX_ENV_HPP_ +#if !defined(ATF_CXX_DETAIL_ENV_HPP) +#define ATF_CXX_DETAIL_ENV_HPP #include namespace atf { namespace env { // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ //! //! \brief Returns the value of an environment variable. //! //! Returns the value of the specified environment variable. The variable //! must be defined. //! std::string get(const std::string&); //! +//! \brief Returns the value of an environment variable with a default. +//! +std::string get(const std::string&, const std::string&); + +//! //! \brief Checks if the environment has a variable. //! //! Checks if the environment has a given variable. //! bool has(const std::string&); //! //! \brief Sets an environment variable to a given value. //! //! Sets the specified environment variable to the given value. Note that //! variables set to the empty string are different to undefined ones. //! //! Be aware that this alters the program's global status, which in general //! is a bad thing to do due to the side-effects it may have. There are //! some legitimate usages for this function, though. //! void set(const std::string&, const std::string&); //! //! \brief Unsets an environment variable. //! //! Unsets the specified environment variable Note that undefined //! variables are different to those defined but set to an empty value. //! //! Be aware that this alters the program's global status, which in general //! is a bad thing to do due to the side-effects it may have. There are //! some legitimate usages for this function, though. //! void unset(const std::string&); } // namespace env } // namespace atf -#endif // !defined(_ATF_CXX_ENV_HPP_) +#endif // !defined(ATF_CXX_DETAIL_ENV_HPP) Index: head/contrib/atf/atf-c++/detail/env_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/env_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/env_test.cpp (revision 273929) @@ -1,91 +1,101 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#include "../macros.hpp" +#include "atf-c++/detail/env.hpp" -#include "env.hpp" +#include // ------------------------------------------------------------------------ // Test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(has_get); ATF_TEST_CASE_HEAD(has_get) { set_md_var("descr", "Tests the has and get functions"); } ATF_TEST_CASE_BODY(has_get) { ATF_REQUIRE(atf::env::has("PATH")); ATF_REQUIRE(!atf::env::get("PATH").empty()); ATF_REQUIRE(!atf::env::has("_UNDEFINED_VARIABLE_")); } +ATF_TEST_CASE(get_with_default); +ATF_TEST_CASE_HEAD(get_with_default) +{ + set_md_var("descr", "Tests the get function with a default value"); +} +ATF_TEST_CASE_BODY(get_with_default) +{ + ATF_REQUIRE(atf::env::has("PATH")); + ATF_REQUIRE(atf::env::get("PATH", "default value") != "default value"); + + ATF_REQUIRE_EQ(atf::env::get("_UNDEFINED_VARIABLE_", "foo bar"), "foo bar"); +} + ATF_TEST_CASE(set); ATF_TEST_CASE_HEAD(set) { set_md_var("descr", "Tests the set function"); } ATF_TEST_CASE_BODY(set) { ATF_REQUIRE(atf::env::has("PATH")); const std::string& oldval = atf::env::get("PATH"); atf::env::set("PATH", "foo-bar"); ATF_REQUIRE(atf::env::get("PATH") != oldval); ATF_REQUIRE_EQ(atf::env::get("PATH"), "foo-bar"); ATF_REQUIRE(!atf::env::has("_UNDEFINED_VARIABLE_")); atf::env::set("_UNDEFINED_VARIABLE_", "foo2-bar2"); ATF_REQUIRE_EQ(atf::env::get("_UNDEFINED_VARIABLE_"), "foo2-bar2"); } ATF_TEST_CASE(unset); ATF_TEST_CASE_HEAD(unset) { set_md_var("descr", "Tests the unset function"); } ATF_TEST_CASE_BODY(unset) { ATF_REQUIRE(atf::env::has("PATH")); atf::env::unset("PATH"); ATF_REQUIRE(!atf::env::has("PATH")); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, has_get); + ATF_ADD_TEST_CASE(tcs, get_with_default); ATF_ADD_TEST_CASE(tcs, set); ATF_ADD_TEST_CASE(tcs, unset); } Index: head/contrib/atf/atf-c++/detail/exceptions.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/exceptions.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/exceptions.cpp (revision 273929) @@ -1,157 +1,154 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/exceptions.hpp" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include #include #include extern "C" { -#include "../../atf-c/error.h" -}; +#include "atf-c/error.h" +} -#include "exceptions.hpp" -#include "sanity.hpp" +#include "atf-c++/detail/sanity.hpp" // ------------------------------------------------------------------------ // The "system_error" type. // ------------------------------------------------------------------------ atf::system_error::system_error(const std::string& who, const std::string& message, int sys_err) : std::runtime_error(who + ": " + message), m_sys_err(sys_err) { } atf::system_error::~system_error(void) throw() { } int atf::system_error::code(void) const throw() { return m_sys_err; } const char* atf::system_error::what(void) const throw() { try { if (m_message.length() == 0) { m_message = std::string(std::runtime_error::what()) + ": "; m_message += ::strerror(m_sys_err); } return m_message.c_str(); } catch (...) { return "Unable to format system_error message"; } } // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ static void throw_libc_error(atf_error_t err) { PRE(atf_error_is(err, "libc")); const int ecode = atf_libc_error_code(err); const std::string msg = atf_libc_error_msg(err); atf_error_free(err); throw atf::system_error("XXX", msg, ecode); } static void throw_no_memory_error(atf_error_t err) { PRE(atf_error_is(err, "no_memory")); atf_error_free(err); throw std::bad_alloc(); } static void throw_unknown_error(atf_error_t err) { PRE(atf_is_error(err)); static char buf[4096]; atf_error_format(err, buf, sizeof(buf)); atf_error_free(err); throw std::runtime_error(buf); } void atf::throw_atf_error(atf_error_t err) { static struct handler { const char* m_name; void (*m_func)(atf_error_t); } handlers[] = { { "libc", throw_libc_error }, { "no_memory", throw_no_memory_error }, { NULL, throw_unknown_error }, }; PRE(atf_is_error(err)); handler* h = handlers; while (h->m_name != NULL) { if (atf_error_is(err, h->m_name)) { h->m_func(err); UNREACHABLE; } else h++; } // XXX: I'm not sure that raising an "unknown" error is a wise thing // to do here. The C++ binding is supposed to have feature parity // with the C one, so all possible errors raised by the C library // should have their counterpart in the C++ library. Still, removing // this will require some code auditing that I can't afford at the // moment. INV(h->m_name == NULL && h->m_func != NULL); h->m_func(err); UNREACHABLE; } Index: head/contrib/atf/atf-c++/detail/exceptions.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/exceptions.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/exceptions.hpp (revision 273929) @@ -1,58 +1,54 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_EXCEPTIONS_HPP_) -#define _ATF_CXX_EXCEPTIONS_HPP_ +#if !defined(ATF_CXX_DETAIL_EXCEPTIONS_HPP) +#define ATF_CXX_DETAIL_EXCEPTIONS_HPP #include #include extern "C" { struct atf_error; } namespace atf { class system_error : public std::runtime_error { int m_sys_err; mutable std::string m_message; public: system_error(const std::string&, const std::string&, int); ~system_error(void) throw(); int code(void) const throw(); const char* what(void) const throw(); }; void throw_atf_error(struct atf_error *); } // namespace atf -#endif // !defined(_ATF_CXX_EXCEPTIONS_HPP_) +#endif // !defined(ATF_CXX_DETAIL_EXCEPTIONS_HPP) Index: head/contrib/atf/atf-c++/detail/exceptions_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/exceptions_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/exceptions_test.cpp (revision 273929) @@ -1,148 +1,145 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/exceptions.hpp" + extern "C" { -#include "../../atf-c/error.h" +#include "atf-c/error.h" } #include #include -#include "../macros.hpp" +#include -#include "exceptions.hpp" -#include "sanity.hpp" +#include "atf-c++/detail/sanity.hpp" // ------------------------------------------------------------------------ // The "test" error. // ------------------------------------------------------------------------ extern "C" { struct test_error_data { const char* m_msg; }; typedef struct test_error_data test_error_data_t; static void test_format(const atf_error_t err, char *buf, size_t buflen) { const test_error_data_t* data; PRE(atf_error_is(err, "test")); data = static_cast< const test_error_data_t * >(atf_error_data(err)); snprintf(buf, buflen, "Message: %s", data->m_msg); } static atf_error_t test_error(const char* msg) { atf_error_t err; test_error_data_t data; data.m_msg = msg; err = atf_error_new("test", &data, sizeof(data), test_format); return err; } } // extern // ------------------------------------------------------------------------ // Tests cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(throw_atf_error_libc); ATF_TEST_CASE_HEAD(throw_atf_error_libc) { set_md_var("descr", "Tests the throw_atf_error function when raising " "a libc error"); } ATF_TEST_CASE_BODY(throw_atf_error_libc) { try { atf::throw_atf_error(atf_libc_error(1, "System error 1")); } catch (const atf::system_error& e) { ATF_REQUIRE(e.code() == 1); ATF_REQUIRE(std::string(e.what()).find("System error 1") != std::string::npos); } catch (const std::exception& e) { ATF_FAIL(std::string("Got unexpected exception: ") + e.what()); } } ATF_TEST_CASE(throw_atf_error_no_memory); ATF_TEST_CASE_HEAD(throw_atf_error_no_memory) { set_md_var("descr", "Tests the throw_atf_error function when raising " "a no_memory error"); } ATF_TEST_CASE_BODY(throw_atf_error_no_memory) { try { atf::throw_atf_error(atf_no_memory_error()); } catch (const std::bad_alloc&) { } catch (const std::exception& e) { ATF_FAIL(std::string("Got unexpected exception: ") + e.what()); } } ATF_TEST_CASE(throw_atf_error_unknown); ATF_TEST_CASE_HEAD(throw_atf_error_unknown) { set_md_var("descr", "Tests the throw_atf_error function when raising " "an unknown error"); } ATF_TEST_CASE_BODY(throw_atf_error_unknown) { try { atf::throw_atf_error(test_error("The message")); } catch (const std::runtime_error& e) { const std::string msg = e.what(); ATF_REQUIRE(msg.find("The message") != std::string::npos); } catch (const std::exception& e) { ATF_FAIL(std::string("Got unexpected exception: ") + e.what()); } } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, throw_atf_error_libc); ATF_ADD_TEST_CASE(tcs, throw_atf_error_no_memory); ATF_ADD_TEST_CASE(tcs, throw_atf_error_unknown); } Index: head/contrib/atf/atf-c++/detail/fs.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/fs.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/fs.cpp (revision 273929) @@ -1,517 +1,513 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/fs.hpp" + #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif extern "C" { #include #include #include #include #include #include #include #include } #include #include #include extern "C" { -#include "../../atf-c/error.h" +#include "atf-c/error.h" } -#include "../utils.hpp" - -#include "exceptions.hpp" -#include "env.hpp" -#include "fs.hpp" -#include "process.hpp" -#include "sanity.hpp" -#include "text.hpp" +#include "atf-c++/detail/env.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/process.hpp" +#include "atf-c++/detail/sanity.hpp" +#include "atf-c++/detail/text.hpp" +#include "atf-c++/utils.hpp" namespace impl = atf::fs; #define IMPL_NAME "atf::fs" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ static bool safe_access(const impl::path&, int, int); //! //! \brief A controlled version of access(2). //! //! This function reimplements the standard access(2) system call to //! safely control its exit status and raise an exception in case of //! failure. //! static bool safe_access(const impl::path& p, int mode, int experr) { bool ok; atf_error_t err = atf_fs_eaccess(p.c_path(), mode); if (atf_is_error(err)) { if (atf_error_is(err, "libc")) { if (atf_libc_error_code(err) == experr) { atf_error_free(err); ok = false; } else { atf::throw_atf_error(err); // XXX Silence warning; maybe throw_atf_error should be // an exception and not a function. ok = false; } } else { atf::throw_atf_error(err); // XXX Silence warning; maybe throw_atf_error should be // an exception and not a function. ok = false; } } else ok = true; return ok; } // ------------------------------------------------------------------------ // The "path" class. // ------------------------------------------------------------------------ impl::path::path(const std::string& s) { atf_error_t err = atf_fs_path_init_fmt(&m_path, "%s", s.c_str()); if (atf_is_error(err)) throw_atf_error(err); } impl::path::path(const path& p) { atf_error_t err = atf_fs_path_copy(&m_path, &p.m_path); if (atf_is_error(err)) throw_atf_error(err); } impl::path::path(const atf_fs_path_t *p) { atf_error_t err = atf_fs_path_copy(&m_path, p); if (atf_is_error(err)) throw_atf_error(err); } impl::path::~path(void) { atf_fs_path_fini(&m_path); } const char* impl::path::c_str(void) const { return atf_fs_path_cstring(&m_path); } const atf_fs_path_t* impl::path::c_path(void) const { return &m_path; } std::string impl::path::str(void) const { return c_str(); } bool impl::path::is_absolute(void) const { return atf_fs_path_is_absolute(&m_path); } bool impl::path::is_root(void) const { return atf_fs_path_is_root(&m_path); } impl::path impl::path::branch_path(void) const { atf_fs_path_t bp; atf_error_t err; err = atf_fs_path_branch_path(&m_path, &bp); if (atf_is_error(err)) throw_atf_error(err); path p(atf_fs_path_cstring(&bp)); atf_fs_path_fini(&bp); return p; } std::string impl::path::leaf_name(void) const { atf_dynstr_t ln; atf_error_t err; err = atf_fs_path_leaf_name(&m_path, &ln); if (atf_is_error(err)) throw_atf_error(err); std::string s(atf_dynstr_cstring(&ln)); atf_dynstr_fini(&ln); return s; } impl::path impl::path::to_absolute(void) const { atf_fs_path_t pa; atf_error_t err = atf_fs_path_to_absolute(&m_path, &pa); if (atf_is_error(err)) throw_atf_error(err); path p(atf_fs_path_cstring(&pa)); atf_fs_path_fini(&pa); return p; } impl::path& impl::path::operator=(const path& p) { atf_fs_path_t tmp; atf_error_t err = atf_fs_path_init_fmt(&tmp, "%s", p.c_str()); if (atf_is_error(err)) throw_atf_error(err); else { atf_fs_path_fini(&m_path); m_path = tmp; } return *this; } bool impl::path::operator==(const path& p) const { return atf_equal_fs_path_fs_path(&m_path, &p.m_path); } bool impl::path::operator!=(const path& p) const { return !atf_equal_fs_path_fs_path(&m_path, &p.m_path); } impl::path impl::path::operator/(const std::string& p) const { path p2 = *this; atf_error_t err = atf_fs_path_append_fmt(&p2.m_path, "%s", p.c_str()); if (atf_is_error(err)) throw_atf_error(err); return p2; } impl::path impl::path::operator/(const path& p) const { path p2 = *this; atf_error_t err = atf_fs_path_append_fmt(&p2.m_path, "%s", atf_fs_path_cstring(&p.m_path)); if (atf_is_error(err)) throw_atf_error(err); return p2; } bool impl::path::operator<(const path& p) const { const char *s1 = atf_fs_path_cstring(&m_path); const char *s2 = atf_fs_path_cstring(&p.m_path); return std::strcmp(s1, s2) < 0; } // ------------------------------------------------------------------------ // The "file_info" class. // ------------------------------------------------------------------------ const int impl::file_info::blk_type = atf_fs_stat_blk_type; const int impl::file_info::chr_type = atf_fs_stat_chr_type; const int impl::file_info::dir_type = atf_fs_stat_dir_type; const int impl::file_info::fifo_type = atf_fs_stat_fifo_type; const int impl::file_info::lnk_type = atf_fs_stat_lnk_type; const int impl::file_info::reg_type = atf_fs_stat_reg_type; const int impl::file_info::sock_type = atf_fs_stat_sock_type; const int impl::file_info::wht_type = atf_fs_stat_wht_type; impl::file_info::file_info(const path& p) { atf_error_t err; err = atf_fs_stat_init(&m_stat, p.c_path()); if (atf_is_error(err)) throw_atf_error(err); } impl::file_info::file_info(const file_info& fi) { atf_fs_stat_copy(&m_stat, &fi.m_stat); } impl::file_info::~file_info(void) { atf_fs_stat_fini(&m_stat); } dev_t impl::file_info::get_device(void) const { return atf_fs_stat_get_device(&m_stat); } ino_t impl::file_info::get_inode(void) const { return atf_fs_stat_get_inode(&m_stat); } mode_t impl::file_info::get_mode(void) const { return atf_fs_stat_get_mode(&m_stat); } off_t impl::file_info::get_size(void) const { return atf_fs_stat_get_size(&m_stat); } int impl::file_info::get_type(void) const { return atf_fs_stat_get_type(&m_stat); } bool impl::file_info::is_owner_readable(void) const { return atf_fs_stat_is_owner_readable(&m_stat); } bool impl::file_info::is_owner_writable(void) const { return atf_fs_stat_is_owner_writable(&m_stat); } bool impl::file_info::is_owner_executable(void) const { return atf_fs_stat_is_owner_executable(&m_stat); } bool impl::file_info::is_group_readable(void) const { return atf_fs_stat_is_group_readable(&m_stat); } bool impl::file_info::is_group_writable(void) const { return atf_fs_stat_is_group_writable(&m_stat); } bool impl::file_info::is_group_executable(void) const { return atf_fs_stat_is_group_executable(&m_stat); } bool impl::file_info::is_other_readable(void) const { return atf_fs_stat_is_other_readable(&m_stat); } bool impl::file_info::is_other_writable(void) const { return atf_fs_stat_is_other_writable(&m_stat); } bool impl::file_info::is_other_executable(void) const { return atf_fs_stat_is_other_executable(&m_stat); } // ------------------------------------------------------------------------ // The "directory" class. // ------------------------------------------------------------------------ impl::directory::directory(const path& p) { DIR* dp = ::opendir(p.c_str()); if (dp == NULL) throw system_error(IMPL_NAME "::directory::directory(" + p.str() + ")", "opendir(3) failed", errno); struct dirent* dep; while ((dep = ::readdir(dp)) != NULL) { path entryp = p / dep->d_name; insert(value_type(dep->d_name, file_info(entryp))); } if (::closedir(dp) == -1) throw system_error(IMPL_NAME "::directory::directory(" + p.str() + ")", "closedir(3) failed", errno); } std::set< std::string > impl::directory::names(void) const { std::set< std::string > ns; for (const_iterator iter = begin(); iter != end(); iter++) ns.insert((*iter).first); return ns; } // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ bool impl::exists(const path& p) { atf_error_t err; bool b; err = atf_fs_exists(p.c_path(), &b); if (atf_is_error(err)) throw_atf_error(err); return b; } bool impl::have_prog_in_path(const std::string& prog) { PRE(prog.find('/') == std::string::npos); // Do not bother to provide a default value for PATH. If it is not // there something is broken in the user's environment. if (!atf::env::has("PATH")) throw std::runtime_error("PATH not defined in the environment"); std::vector< std::string > dirs = atf::text::split(atf::env::get("PATH"), ":"); bool found = false; for (std::vector< std::string >::const_iterator iter = dirs.begin(); !found && iter != dirs.end(); iter++) { const path& dir = path(*iter); if (is_executable(dir / prog)) found = true; } return found; } bool impl::is_executable(const path& p) { if (!exists(p)) return false; return safe_access(p, atf_fs_access_x, EACCES); } void impl::remove(const path& p) { if (file_info(p).get_type() == file_info::dir_type) throw atf::system_error(IMPL_NAME "::remove(" + p.str() + ")", "Is a directory", EPERM); if (::unlink(p.c_str()) == -1) throw atf::system_error(IMPL_NAME "::remove(" + p.str() + ")", "unlink(" + p.str() + ") failed", errno); } void impl::rmdir(const path& p) { atf_error_t err = atf_fs_rmdir(p.c_path()); if (atf_is_error(err)) throw_atf_error(err); } Index: head/contrib/atf/atf-c++/detail/fs.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/fs.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/fs.hpp (revision 273929) @@ -1,391 +1,387 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_FS_HPP_) -#define _ATF_CXX_FS_HPP_ +#if !defined(ATF_CXX_DETAIL_FS_HPP) +#define ATF_CXX_DETAIL_FS_HPP extern "C" { #include } #include #include #include #include #include #include extern "C" { -#include "../../atf-c/detail/fs.h" +#include "atf-c/detail/fs.h" } namespace atf { namespace io { class systembuf; } // namespace io namespace fs { // ------------------------------------------------------------------------ // The "path" class. // ------------------------------------------------------------------------ //! //! \brief A class to represent a path to a file. //! //! The path class represents the route to a file or directory in the //! file system. All file manipulation operations use this class to //! represent their arguments as it takes care of normalizing user-provided //! strings and ensures they are valid. //! //! It is important to note that the file pointed to by a path need not //! exist. //! class path { //! //! \brief Internal representation of a path. //! atf_fs_path_t m_path; public: //! \brief Constructs a new path from a user-provided string. //! //! This constructor takes a string, either provided by the program's //! code or by the user and constructs a new path object. The string //! is normalized to not contain multiple delimiters together and to //! remove any trailing one. //! //! The input string cannot be empty. //! explicit path(const std::string&); //! //! \brief Copy constructor. //! path(const path&); //! //! \brief Copy constructor. //! path(const atf_fs_path_t *); //! //! \brief Destructor for the path class. //! ~path(void); //! //! \brief Returns a pointer to a C-style string representing this path. //! const char* c_str(void) const; //! //! \brief Returns a pointer to the implementation data. //! const atf_fs_path_t* c_path(void) const; //! //! \brief Returns a string representing this path. //! XXX Really needed? //! std::string str(void) const; //! //! \brief Returns the branch path of this path. //! //! Calculates and returns the branch path of this path. In other //! words, it returns what the standard ::dirname function would return. //! path branch_path(void) const; //! //! \brief Returns the leaf name of this path. //! //! Calculates and returns the leaf name of this path. In other words, //! it returns what the standard ::basename function would return. //! std::string leaf_name(void) const; //! //! \brief Checks whether this path is absolute or not. //! //! Returns a boolean indicating if this is an absolute path or not; //! i.e. if it starts with a slash. //! bool is_absolute(void) const; //! //! \brief Checks whether this path points to the root directory or not. //! //! Returns a boolean indicating if this is path points to the root //! directory or not. The checks made by this are extremely simple (so //! the results cannot always be trusted) but they are enough for our //! modest sanity-checking needs. I.e. "/../" could return false. //! bool is_root(void) const; //! //! \brief Converts the path to be absolute. //! //! \pre The path was not absolute. //! path to_absolute(void) const; //! //! \brief Assignment operator. //! path& operator=(const path&); //! //! \brief Checks if two paths are equal. //! bool operator==(const path&) const; //! //! \brief Checks if two paths are different. //! bool operator!=(const path&) const; //! //! \brief Concatenates a path with a string. //! //! Constructs a new path object that is the concatenation of the //! left-hand path with the right-hand string. The string is normalized //! before the concatenation, and a path delimiter is introduced between //! the two components if needed. //! path operator/(const std::string&) const; //! //! \brief Concatenates a path with another path. //! //! Constructs a new path object that is the concatenation of the //! left-hand path with the right-hand one. A path delimiter is //! introduced between the two components if needed. //! path operator/(const path&) const; //! //! \brief Checks if a path has to be sorted before another one //! lexicographically. //! bool operator<(const path&) const; }; // ------------------------------------------------------------------------ // The "file_info" class. // ------------------------------------------------------------------------ class directory; //! //! \brief A class that contains information about a file. //! //! The file_info class holds information about an specific file that //! exists in the file system. //! class file_info { atf_fs_stat_t m_stat; public: //! //! \brief The file's type. //! static const int blk_type; static const int chr_type; static const int dir_type; static const int fifo_type; static const int lnk_type; static const int reg_type; static const int sock_type; static const int wht_type; //! //! \brief Constructs a new file_info based on a given file. //! //! This constructor creates a new file_info object and fills it with //! the data returned by ::stat when run on the given file, which must //! exist. //! explicit file_info(const path&); //! //! \brief The copy constructor. //! file_info(const file_info&); //! //! \brief The destructor. //! ~file_info(void); //! //! \brief Returns the device containing the file. //! dev_t get_device(void) const; //! //! \brief Returns the file's inode. //! ino_t get_inode(void) const; //! //! \brief Returns the file's permissions. //! mode_t get_mode(void) const; //! //! \brief Returns the file's size. //! off_t get_size(void) const; //! //! \brief Returns the file's type. //! int get_type(void) const; //! //! \brief Returns whether the file is readable by its owner or not. //! bool is_owner_readable(void) const; //! //! \brief Returns whether the file is writable by its owner or not. //! bool is_owner_writable(void) const; //! //! \brief Returns whether the file is executable by its owner or not. //! bool is_owner_executable(void) const; //! //! \brief Returns whether the file is readable by the users belonging //! to its group or not. //! bool is_group_readable(void) const; //! //! \brief Returns whether the file is writable the users belonging to //! its group or not. //! bool is_group_writable(void) const; //! //! \brief Returns whether the file is executable by the users //! belonging to its group or not. //! bool is_group_executable(void) const; //! //! \brief Returns whether the file is readable by people different //! than the owner and those belonging to the group or not. //! bool is_other_readable(void) const; //! //! \brief Returns whether the file is write by people different //! than the owner and those belonging to the group or not. //! bool is_other_writable(void) const; //! //! \brief Returns whether the file is executable by people different //! than the owner and those belonging to the group or not. //! bool is_other_executable(void) const; }; // ------------------------------------------------------------------------ // The "directory" class. // ------------------------------------------------------------------------ //! //! \brief A class representing a file system directory. //! //! The directory class represents a group of files in the file system and //! corresponds to exactly one directory. //! class directory : public std::map< std::string, file_info > { public: //! //! \brief Constructs a new directory. //! //! Constructs a new directory object representing the given path. //! The directory must exist at creation time as the contents of the //! class are gathered from it. //! directory(const path&); //! //! \brief Returns the file names of the files in the directory. //! //! Returns the leaf names of all files contained in the directory. //! I.e. the keys of the directory map. //! std::set< std::string > names(void) const; }; // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ //! //! \brief Checks if the given path exists. //! bool exists(const path&); //! //! \brief Looks for the given program in the PATH. //! //! Given a program name (without slashes) looks for it in the path and //! returns its full path name if found, otherwise an empty path. //! bool have_prog_in_path(const std::string&); //! //! \brief Checks if the given path exists, is accessible and is executable. //! bool is_executable(const path&); //! //! \brief Removes a given file. //! void remove(const path&); //! //! \brief Removes an empty directory. //! void rmdir(const path&); } // namespace fs } // namespace atf -#endif // !defined(_ATF_CXX_FS_HPP_) +#endif // !defined(ATF_CXX_DETAIL_FS_HPP) Index: head/contrib/atf/atf-c++/detail/fs_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/fs_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/fs_test.cpp (revision 273929) @@ -1,545 +1,542 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/fs.hpp" + extern "C" { #include #include } #include #include #include -#include "../macros.hpp" +#include -#include "exceptions.hpp" -#include "fs.hpp" +#include "atf-c++/detail/exceptions.hpp" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ static void create_files(void) { ::mkdir("files", 0755); ::mkdir("files/dir", 0755); std::ofstream os("files/reg"); os.close(); // TODO: Should create all other file types (blk, chr, fifo, lnk, sock) // and test for them... but the underlying file system may not support // most of these. Specially as we are working on /tmp, which can be // mounted with flags such as "nodev". See how to deal with this // situation. } // ------------------------------------------------------------------------ // Test cases for the "path" class. // ------------------------------------------------------------------------ ATF_TEST_CASE(path_normalize); ATF_TEST_CASE_HEAD(path_normalize) { set_md_var("descr", "Tests the path's normalization"); } ATF_TEST_CASE_BODY(path_normalize) { using atf::fs::path; ATF_REQUIRE_EQ(path(".").str(), "."); ATF_REQUIRE_EQ(path("..").str(), ".."); ATF_REQUIRE_EQ(path("foo").str(), "foo"); ATF_REQUIRE_EQ(path("foo/bar").str(), "foo/bar"); ATF_REQUIRE_EQ(path("foo/bar/").str(), "foo/bar"); ATF_REQUIRE_EQ(path("/foo").str(), "/foo"); ATF_REQUIRE_EQ(path("/foo/bar").str(), "/foo/bar"); ATF_REQUIRE_EQ(path("/foo/bar/").str(), "/foo/bar"); ATF_REQUIRE_EQ(path("///foo").str(), "/foo"); ATF_REQUIRE_EQ(path("///foo///bar").str(), "/foo/bar"); ATF_REQUIRE_EQ(path("///foo///bar///").str(), "/foo/bar"); } ATF_TEST_CASE(path_is_absolute); ATF_TEST_CASE_HEAD(path_is_absolute) { set_md_var("descr", "Tests the path::is_absolute function"); } ATF_TEST_CASE_BODY(path_is_absolute) { using atf::fs::path; ATF_REQUIRE( path("/").is_absolute()); ATF_REQUIRE( path("////").is_absolute()); ATF_REQUIRE( path("////a").is_absolute()); ATF_REQUIRE( path("//a//").is_absolute()); ATF_REQUIRE(!path("a////").is_absolute()); ATF_REQUIRE(!path("../foo").is_absolute()); } ATF_TEST_CASE(path_is_root); ATF_TEST_CASE_HEAD(path_is_root) { set_md_var("descr", "Tests the path::is_root function"); } ATF_TEST_CASE_BODY(path_is_root) { using atf::fs::path; ATF_REQUIRE( path("/").is_root()); ATF_REQUIRE( path("////").is_root()); ATF_REQUIRE(!path("////a").is_root()); ATF_REQUIRE(!path("//a//").is_root()); ATF_REQUIRE(!path("a////").is_root()); ATF_REQUIRE(!path("../foo").is_root()); } ATF_TEST_CASE(path_branch_path); ATF_TEST_CASE_HEAD(path_branch_path) { set_md_var("descr", "Tests the path::branch_path function"); } ATF_TEST_CASE_BODY(path_branch_path) { using atf::fs::path; ATF_REQUIRE_EQ(path(".").branch_path().str(), "."); ATF_REQUIRE_EQ(path("foo").branch_path().str(), "."); ATF_REQUIRE_EQ(path("foo/bar").branch_path().str(), "foo"); ATF_REQUIRE_EQ(path("/foo").branch_path().str(), "/"); ATF_REQUIRE_EQ(path("/foo/bar").branch_path().str(), "/foo"); } ATF_TEST_CASE(path_leaf_name); ATF_TEST_CASE_HEAD(path_leaf_name) { set_md_var("descr", "Tests the path::leaf_name function"); } ATF_TEST_CASE_BODY(path_leaf_name) { using atf::fs::path; ATF_REQUIRE_EQ(path(".").leaf_name(), "."); ATF_REQUIRE_EQ(path("foo").leaf_name(), "foo"); ATF_REQUIRE_EQ(path("foo/bar").leaf_name(), "bar"); ATF_REQUIRE_EQ(path("/foo").leaf_name(), "foo"); ATF_REQUIRE_EQ(path("/foo/bar").leaf_name(), "bar"); } ATF_TEST_CASE(path_compare_equal); ATF_TEST_CASE_HEAD(path_compare_equal) { set_md_var("descr", "Tests the comparison for equality between paths"); } ATF_TEST_CASE_BODY(path_compare_equal) { using atf::fs::path; ATF_REQUIRE(path("/") == path("///")); ATF_REQUIRE(path("/a") == path("///a")); ATF_REQUIRE(path("/a") == path("///a///")); ATF_REQUIRE(path("a/b/c") == path("a//b//c")); ATF_REQUIRE(path("a/b/c") == path("a//b//c///")); } ATF_TEST_CASE(path_compare_different); ATF_TEST_CASE_HEAD(path_compare_different) { set_md_var("descr", "Tests the comparison for difference between paths"); } ATF_TEST_CASE_BODY(path_compare_different) { using atf::fs::path; ATF_REQUIRE(path("/") != path("//a/")); ATF_REQUIRE(path("/a") != path("a///")); ATF_REQUIRE(path("a/b/c") != path("a/b")); ATF_REQUIRE(path("a/b/c") != path("a//b")); ATF_REQUIRE(path("a/b/c") != path("/a/b/c")); ATF_REQUIRE(path("a/b/c") != path("/a//b//c")); } ATF_TEST_CASE(path_concat); ATF_TEST_CASE_HEAD(path_concat) { set_md_var("descr", "Tests the concatenation of multiple paths"); } ATF_TEST_CASE_BODY(path_concat) { using atf::fs::path; ATF_REQUIRE_EQ((path("foo") / "bar").str(), "foo/bar"); ATF_REQUIRE_EQ((path("foo/") / "/bar").str(), "foo/bar"); ATF_REQUIRE_EQ((path("foo/") / "/bar/baz").str(), "foo/bar/baz"); ATF_REQUIRE_EQ((path("foo/") / "///bar///baz").str(), "foo/bar/baz"); } ATF_TEST_CASE(path_to_absolute); ATF_TEST_CASE_HEAD(path_to_absolute) { set_md_var("descr", "Tests the conversion of a relative path to an " "absolute one"); } ATF_TEST_CASE_BODY(path_to_absolute) { using atf::fs::file_info; using atf::fs::path; create_files(); { const path p("."); path pa = p.to_absolute(); ATF_REQUIRE(pa.is_absolute()); file_info fi(p); file_info fia(pa); ATF_REQUIRE_EQ(fi.get_device(), fia.get_device()); ATF_REQUIRE_EQ(fi.get_inode(), fia.get_inode()); } { const path p("files/reg"); path pa = p.to_absolute(); ATF_REQUIRE(pa.is_absolute()); file_info fi(p); file_info fia(pa); ATF_REQUIRE_EQ(fi.get_device(), fia.get_device()); ATF_REQUIRE_EQ(fi.get_inode(), fia.get_inode()); } } ATF_TEST_CASE(path_op_less); ATF_TEST_CASE_HEAD(path_op_less) { set_md_var("descr", "Tests that the path's less-than operator works"); } ATF_TEST_CASE_BODY(path_op_less) { using atf::fs::path; create_files(); ATF_REQUIRE(!(path("aaa") < path("aaa"))); ATF_REQUIRE( path("aab") < path("abc")); ATF_REQUIRE(!(path("abc") < path("aab"))); } // ------------------------------------------------------------------------ // Test cases for the "directory" class. // ------------------------------------------------------------------------ ATF_TEST_CASE(directory_read); ATF_TEST_CASE_HEAD(directory_read) { set_md_var("descr", "Tests the directory class creation, which reads " "the contents of a directory"); } ATF_TEST_CASE_BODY(directory_read) { using atf::fs::directory; using atf::fs::path; create_files(); directory d(path("files")); ATF_REQUIRE_EQ(d.size(), 4); ATF_REQUIRE(d.find(".") != d.end()); ATF_REQUIRE(d.find("..") != d.end()); ATF_REQUIRE(d.find("dir") != d.end()); ATF_REQUIRE(d.find("reg") != d.end()); } ATF_TEST_CASE(directory_file_info); ATF_TEST_CASE_HEAD(directory_file_info) { set_md_var("descr", "Tests that the file_info objects attached to the " "directory are valid"); } ATF_TEST_CASE_BODY(directory_file_info) { using atf::fs::directory; using atf::fs::file_info; using atf::fs::path; create_files(); directory d(path("files")); { directory::const_iterator iter = d.find("dir"); ATF_REQUIRE(iter != d.end()); const file_info& fi = (*iter).second; ATF_REQUIRE(fi.get_type() == file_info::dir_type); } { directory::const_iterator iter = d.find("reg"); ATF_REQUIRE(iter != d.end()); const file_info& fi = (*iter).second; ATF_REQUIRE(fi.get_type() == file_info::reg_type); } } ATF_TEST_CASE(directory_names); ATF_TEST_CASE_HEAD(directory_names) { set_md_var("descr", "Tests the directory's names method"); } ATF_TEST_CASE_BODY(directory_names) { using atf::fs::directory; using atf::fs::path; create_files(); directory d(path("files")); std::set< std::string > ns = d.names(); ATF_REQUIRE_EQ(ns.size(), 4); ATF_REQUIRE(ns.find(".") != ns.end()); ATF_REQUIRE(ns.find("..") != ns.end()); ATF_REQUIRE(ns.find("dir") != ns.end()); ATF_REQUIRE(ns.find("reg") != ns.end()); } // ------------------------------------------------------------------------ // Test cases for the "file_info" class. // ------------------------------------------------------------------------ ATF_TEST_CASE(file_info_stat); ATF_TEST_CASE_HEAD(file_info_stat) { set_md_var("descr", "Tests the file_info creation and its basic contents"); } ATF_TEST_CASE_BODY(file_info_stat) { using atf::fs::file_info; using atf::fs::path; create_files(); { path p("files/dir"); file_info fi(p); ATF_REQUIRE(fi.get_type() == file_info::dir_type); } { path p("files/reg"); file_info fi(p); ATF_REQUIRE(fi.get_type() == file_info::reg_type); } } ATF_TEST_CASE(file_info_perms); ATF_TEST_CASE_HEAD(file_info_perms) { set_md_var("descr", "Tests the file_info methods to get the file's " "permissions"); } ATF_TEST_CASE_BODY(file_info_perms) { using atf::fs::file_info; using atf::fs::path; path p("file"); std::ofstream os(p.c_str()); os.close(); #define perms(ur, uw, ux, gr, gw, gx, othr, othw, othx) \ { \ file_info fi(p); \ ATF_REQUIRE(fi.is_owner_readable() == ur); \ ATF_REQUIRE(fi.is_owner_writable() == uw); \ ATF_REQUIRE(fi.is_owner_executable() == ux); \ ATF_REQUIRE(fi.is_group_readable() == gr); \ ATF_REQUIRE(fi.is_group_writable() == gw); \ ATF_REQUIRE(fi.is_group_executable() == gx); \ ATF_REQUIRE(fi.is_other_readable() == othr); \ ATF_REQUIRE(fi.is_other_writable() == othw); \ ATF_REQUIRE(fi.is_other_executable() == othx); \ } ::chmod(p.c_str(), 0000); perms(false, false, false, false, false, false, false, false, false); ::chmod(p.c_str(), 0001); perms(false, false, false, false, false, false, false, false, true); ::chmod(p.c_str(), 0010); perms(false, false, false, false, false, true, false, false, false); ::chmod(p.c_str(), 0100); perms(false, false, true, false, false, false, false, false, false); ::chmod(p.c_str(), 0002); perms(false, false, false, false, false, false, false, true, false); ::chmod(p.c_str(), 0020); perms(false, false, false, false, true, false, false, false, false); ::chmod(p.c_str(), 0200); perms(false, true, false, false, false, false, false, false, false); ::chmod(p.c_str(), 0004); perms(false, false, false, false, false, false, true, false, false); ::chmod(p.c_str(), 0040); perms(false, false, false, true, false, false, false, false, false); ::chmod(p.c_str(), 0400); perms(true, false, false, false, false, false, false, false, false); ::chmod(p.c_str(), 0644); perms(true, true, false, true, false, false, true, false, false); ::chmod(p.c_str(), 0755); perms(true, true, true, true, false, true, true, false, true); ::chmod(p.c_str(), 0777); perms(true, true, true, true, true, true, true, true, true); #undef perms } // ------------------------------------------------------------------------ // Test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(exists); ATF_TEST_CASE_HEAD(exists) { set_md_var("descr", "Tests the exists function"); } ATF_TEST_CASE_BODY(exists) { using atf::fs::exists; using atf::fs::path; create_files(); ATF_REQUIRE( exists(path("files"))); ATF_REQUIRE(!exists(path("file"))); ATF_REQUIRE(!exists(path("files2"))); ATF_REQUIRE( exists(path("files/."))); ATF_REQUIRE( exists(path("files/.."))); ATF_REQUIRE( exists(path("files/dir"))); ATF_REQUIRE( exists(path("files/reg"))); ATF_REQUIRE(!exists(path("files/foo"))); } ATF_TEST_CASE(is_executable); ATF_TEST_CASE_HEAD(is_executable) { set_md_var("descr", "Tests the is_executable function"); } ATF_TEST_CASE_BODY(is_executable) { using atf::fs::is_executable; using atf::fs::path; create_files(); ATF_REQUIRE( is_executable(path("files"))); ATF_REQUIRE( is_executable(path("files/."))); ATF_REQUIRE( is_executable(path("files/.."))); ATF_REQUIRE( is_executable(path("files/dir"))); ATF_REQUIRE(!is_executable(path("non-existent"))); ATF_REQUIRE(!is_executable(path("files/reg"))); ATF_REQUIRE(::chmod("files/reg", 0755) != -1); ATF_REQUIRE( is_executable(path("files/reg"))); } ATF_TEST_CASE(remove); ATF_TEST_CASE_HEAD(remove) { set_md_var("descr", "Tests the remove function"); } ATF_TEST_CASE_BODY(remove) { using atf::fs::exists; using atf::fs::path; using atf::fs::remove; create_files(); ATF_REQUIRE( exists(path("files/reg"))); remove(path("files/reg")); ATF_REQUIRE(!exists(path("files/reg"))); ATF_REQUIRE( exists(path("files/dir"))); ATF_REQUIRE_THROW(atf::system_error, remove(path("files/dir"))); ATF_REQUIRE( exists(path("files/dir"))); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the tests for the "path" class. ATF_ADD_TEST_CASE(tcs, path_normalize); ATF_ADD_TEST_CASE(tcs, path_is_absolute); ATF_ADD_TEST_CASE(tcs, path_is_root); ATF_ADD_TEST_CASE(tcs, path_branch_path); ATF_ADD_TEST_CASE(tcs, path_leaf_name); ATF_ADD_TEST_CASE(tcs, path_compare_equal); ATF_ADD_TEST_CASE(tcs, path_compare_different); ATF_ADD_TEST_CASE(tcs, path_concat); ATF_ADD_TEST_CASE(tcs, path_to_absolute); ATF_ADD_TEST_CASE(tcs, path_op_less); // Add the tests for the "file_info" class. ATF_ADD_TEST_CASE(tcs, file_info_stat); ATF_ADD_TEST_CASE(tcs, file_info_perms); // Add the tests for the "directory" class. ATF_ADD_TEST_CASE(tcs, directory_read); ATF_ADD_TEST_CASE(tcs, directory_names); ATF_ADD_TEST_CASE(tcs, directory_file_info); // Add the tests for the free functions. ATF_ADD_TEST_CASE(tcs, exists); ATF_ADD_TEST_CASE(tcs, is_executable); ATF_ADD_TEST_CASE(tcs, remove); } Index: head/contrib/atf/atf-c++/detail/process.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/process.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/process.cpp (revision 273929) @@ -1,355 +1,346 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/process.hpp" + extern "C" { #include -#include "../../atf-c/error.h" - -#include "../../atf-c/detail/process.h" +#include "atf-c/detail/process.h" +#include "atf-c/error.h" } #include -#include "exceptions.hpp" -#include "process.hpp" -#include "sanity.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/sanity.hpp" namespace detail = atf::process::detail; namespace impl = atf::process; #define IMPL_NAME "atf::process" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ template< class C > atf::auto_array< const char* > collection_to_argv(const C& c) { atf::auto_array< const char* > argv(new const char*[c.size() + 1]); std::size_t pos = 0; for (typename C::const_iterator iter = c.begin(); iter != c.end(); iter++) { argv[pos] = (*iter).c_str(); pos++; } INV(pos == c.size()); argv[pos] = NULL; return argv; } template< class C > C argv_to_collection(const char* const* argv) { C c; for (const char* const* iter = argv; *iter != NULL; iter++) c.push_back(std::string(*iter)); return c; } // ------------------------------------------------------------------------ // The "argv_array" type. // ------------------------------------------------------------------------ impl::argv_array::argv_array(void) : m_exec_argv(collection_to_argv(m_args)) { } impl::argv_array::argv_array(const char* arg1, ...) { m_args.push_back(arg1); { va_list ap; const char* nextarg; va_start(ap, arg1); while ((nextarg = va_arg(ap, const char*)) != NULL) m_args.push_back(nextarg); va_end(ap); } ctor_init_exec_argv(); } impl::argv_array::argv_array(const char* const* ca) : m_args(argv_to_collection< args_vector >(ca)), m_exec_argv(collection_to_argv(m_args)) { } impl::argv_array::argv_array(const argv_array& a) : m_args(a.m_args), m_exec_argv(collection_to_argv(m_args)) { } void impl::argv_array::ctor_init_exec_argv(void) { m_exec_argv = collection_to_argv(m_args); } const char* const* impl::argv_array::exec_argv(void) const { return m_exec_argv.get(); } impl::argv_array::size_type impl::argv_array::size(void) const { return m_args.size(); } const char* impl::argv_array::operator[](int idx) const { return m_args[idx].c_str(); } impl::argv_array::const_iterator impl::argv_array::begin(void) const { return m_args.begin(); } impl::argv_array::const_iterator impl::argv_array::end(void) const { return m_args.end(); } impl::argv_array& impl::argv_array::operator=(const argv_array& a) { if (this != &a) { m_args = a.m_args; m_exec_argv = collection_to_argv(m_args); } return *this; } // ------------------------------------------------------------------------ // The "stream" types. // ------------------------------------------------------------------------ impl::basic_stream::basic_stream(void) : m_inited(false) { } impl::basic_stream::~basic_stream(void) { if (m_inited) atf_process_stream_fini(&m_sb); } const atf_process_stream_t* impl::basic_stream::get_sb(void) const { INV(m_inited); return &m_sb; } impl::stream_capture::stream_capture(void) { atf_error_t err = atf_process_stream_init_capture(&m_sb); if (atf_is_error(err)) throw_atf_error(err); m_inited = true; } impl::stream_connect::stream_connect(const int src_fd, const int tgt_fd) { atf_error_t err = atf_process_stream_init_connect(&m_sb, src_fd, tgt_fd); if (atf_is_error(err)) throw_atf_error(err); m_inited = true; } impl::stream_inherit::stream_inherit(void) { atf_error_t err = atf_process_stream_init_inherit(&m_sb); if (atf_is_error(err)) throw_atf_error(err); m_inited = true; } impl::stream_redirect_fd::stream_redirect_fd(const int fd) { atf_error_t err = atf_process_stream_init_redirect_fd(&m_sb, fd); if (atf_is_error(err)) throw_atf_error(err); m_inited = true; } impl::stream_redirect_path::stream_redirect_path(const fs::path& p) { atf_error_t err = atf_process_stream_init_redirect_path(&m_sb, p.c_path()); if (atf_is_error(err)) throw_atf_error(err); m_inited = true; } // ------------------------------------------------------------------------ // The "status" type. // ------------------------------------------------------------------------ impl::status::status(atf_process_status_t& s) : m_status(s) { } impl::status::~status(void) { atf_process_status_fini(&m_status); } bool impl::status::exited(void) const { return atf_process_status_exited(&m_status); } int impl::status::exitstatus(void) const { return atf_process_status_exitstatus(&m_status); } bool impl::status::signaled(void) const { return atf_process_status_signaled(&m_status); } int impl::status::termsig(void) const { return atf_process_status_termsig(&m_status); } bool impl::status::coredump(void) const { return atf_process_status_coredump(&m_status); } // ------------------------------------------------------------------------ // The "child" type. // ------------------------------------------------------------------------ impl::child::child(atf_process_child_t& c) : m_child(c), m_waited(false) { } impl::child::~child(void) { if (!m_waited) { ::kill(atf_process_child_pid(&m_child), SIGTERM); atf_process_status_t s; atf_error_t err = atf_process_child_wait(&m_child, &s); INV(!atf_is_error(err)); atf_process_status_fini(&s); } } impl::status impl::child::wait(void) { atf_process_status_t s; atf_error_t err = atf_process_child_wait(&m_child, &s); if (atf_is_error(err)) throw_atf_error(err); m_waited = true; return status(s); } pid_t impl::child::pid(void) const { return atf_process_child_pid(&m_child); } int impl::child::stdout_fd(void) { return atf_process_child_stdout(&m_child); } int impl::child::stderr_fd(void) { return atf_process_child_stderr(&m_child); } // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ void detail::flush_streams(void) { - // This is a weird hack to ensure that the output of the parent process - // is flushed before executing a child which prevents, for example, the - // output of the atf-run hooks to appear before the output of atf-run - // itself. - // // TODO: This should only be executed when inheriting the stdout or // stderr file descriptors. However, the flushing is specific to the // iostreams, so we cannot do it from the C library where all the process // logic is performed. Come up with a better design. std::cout.flush(); std::cerr.flush(); } Index: head/contrib/atf/atf-c++/detail/process.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/process.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/process.hpp (revision 273929) @@ -1,279 +1,274 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_PROCESS_HPP_) -#define _ATF_CXX_PROCESS_HPP_ +#if !defined(ATF_CXX_DETAIL_PROCESS_HPP) +#define ATF_CXX_DETAIL_PROCESS_HPP extern "C" { #include -#include "../../atf-c/error.h" - -#include "../../atf-c/detail/process.h" +#include +#include } #include #include -#include "auto_array.hpp" -#include "exceptions.hpp" -#include "fs.hpp" +#include +#include +#include namespace atf { namespace process { class child; class status; // ------------------------------------------------------------------------ // The "argv_array" type. // ------------------------------------------------------------------------ class argv_array { typedef std::vector< std::string > args_vector; args_vector m_args; // TODO: This is immutable, so we should be able to use // std::tr1::shared_array instead when it becomes widely available. // The reason would be to remove all copy constructors and assignment // operators from this class. auto_array< const char* > m_exec_argv; void ctor_init_exec_argv(void); public: typedef args_vector::const_iterator const_iterator; typedef args_vector::size_type size_type; argv_array(void); argv_array(const char*, ...); explicit argv_array(const char* const*); template< class C > explicit argv_array(const C&); argv_array(const argv_array&); const char* const* exec_argv(void) const; size_type size(void) const; const char* operator[](int) const; const_iterator begin(void) const; const_iterator end(void) const; argv_array& operator=(const argv_array&); }; template< class C > argv_array::argv_array(const C& c) { for (typename C::const_iterator iter = c.begin(); iter != c.end(); iter++) m_args.push_back(*iter); ctor_init_exec_argv(); } // ------------------------------------------------------------------------ // The "stream" types. // ------------------------------------------------------------------------ class basic_stream { protected: atf_process_stream_t m_sb; bool m_inited; const atf_process_stream_t* get_sb(void) const; public: basic_stream(void); ~basic_stream(void); }; class stream_capture : basic_stream { // Allow access to the getters. template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); public: stream_capture(void); }; class stream_connect : basic_stream { // Allow access to the getters. template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); public: stream_connect(const int, const int); }; class stream_inherit : basic_stream { // Allow access to the getters. template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); public: stream_inherit(void); }; class stream_redirect_fd : basic_stream { // Allow access to the getters. template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); public: stream_redirect_fd(const int); }; class stream_redirect_path : basic_stream { // Allow access to the getters. template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); public: stream_redirect_path(const fs::path&); }; // ------------------------------------------------------------------------ // The "status" type. // ------------------------------------------------------------------------ class status { atf_process_status_t m_status; friend class child; template< class OutStream, class ErrStream > friend status exec(const atf::fs::path&, const argv_array&, const OutStream&, const ErrStream&, void (*)(void)); status(atf_process_status_t&); public: ~status(void); bool exited(void) const; int exitstatus(void) const; bool signaled(void) const; int termsig(void) const; bool coredump(void) const; }; // ------------------------------------------------------------------------ // The "child" type. // ------------------------------------------------------------------------ class child { atf_process_child_t m_child; bool m_waited; template< class OutStream, class ErrStream > friend child fork(void (*)(void*), const OutStream&, const ErrStream&, void*); child(atf_process_child_t& c); public: ~child(void); status wait(void); pid_t pid(void) const; int stdout_fd(void); int stderr_fd(void); }; // ------------------------------------------------------------------------ // Free functions. // ------------------------------------------------------------------------ namespace detail { void flush_streams(void); } // namespace detail // TODO: The void* cookie can probably be templatized, thus also allowing // const data structures. template< class OutStream, class ErrStream > child fork(void (*start)(void*), const OutStream& outsb, const ErrStream& errsb, void* v) { atf_process_child_t c; detail::flush_streams(); atf_error_t err = atf_process_fork(&c, start, outsb.get_sb(), errsb.get_sb(), v); if (atf_is_error(err)) throw_atf_error(err); return child(c); } template< class OutStream, class ErrStream > status exec(const atf::fs::path& prog, const argv_array& argv, const OutStream& outsb, const ErrStream& errsb, void (*prehook)(void)) { atf_process_status_t s; detail::flush_streams(); atf_error_t err = atf_process_exec_array(&s, prog.c_path(), argv.exec_argv(), outsb.get_sb(), errsb.get_sb(), prehook); if (atf_is_error(err)) throw_atf_error(err); return status(s); } template< class OutStream, class ErrStream > status exec(const atf::fs::path& prog, const argv_array& argv, const OutStream& outsb, const ErrStream& errsb) { return exec(prog, argv, outsb, errsb, NULL); } } // namespace process } // namespace atf -#endif // !defined(_ATF_CXX_PROCESS_HPP_) +#endif // !defined(ATF_CXX_DETAIL_PROCESS_HPP) Index: head/contrib/atf/atf-c++/detail/process_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/process_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/process_test.cpp (revision 273929) @@ -1,357 +1,354 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/process.hpp" + #include #include -#include "../macros.hpp" +#include -#include "process.hpp" -#include "test_helpers.hpp" +#include "atf-c++/detail/test_helpers.hpp" // TODO: Testing the fork function is a huge task and I'm afraid of // copy/pasting tons of stuff from the C version. I'd rather not do that // until some code can be shared, which cannot happen until the C++ binding // is cleaned by a fair amount. Instead... just rely (at the moment) on // the system tests for the tools using this module. // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ static std::size_t array_size(const char* const* array) { std::size_t size = 0; for (const char* const* ptr = array; *ptr != NULL; ptr++) size++; return size; } static atf::process::status exec_process_helpers(const atf::tests::tc& tc, const char* helper_name) { using atf::process::exec; std::vector< std::string > argv; argv.push_back(get_process_helpers_path(tc, true).leaf_name()); argv.push_back(helper_name); return exec(get_process_helpers_path(tc, true), atf::process::argv_array(argv), atf::process::stream_inherit(), atf::process::stream_inherit()); } // ------------------------------------------------------------------------ // Tests for the "argv_array" type. // ------------------------------------------------------------------------ ATF_TEST_CASE(argv_array_init_carray); ATF_TEST_CASE_HEAD(argv_array_init_carray) { set_md_var("descr", "Tests that argv_array is correctly constructed " "from a C-style array of strings"); } ATF_TEST_CASE_BODY(argv_array_init_carray) { { const char* const carray[] = { NULL }; atf::process::argv_array argv(carray); ATF_REQUIRE_EQ(argv.size(), 0); } { const char* const carray[] = { "arg0", NULL }; atf::process::argv_array argv(carray); ATF_REQUIRE_EQ(argv.size(), 1); ATF_REQUIRE(std::strcmp(argv[0], carray[0]) == 0); } { const char* const carray[] = { "arg0", "arg1", "arg2", NULL }; atf::process::argv_array argv(carray); ATF_REQUIRE_EQ(argv.size(), 3); ATF_REQUIRE(std::strcmp(argv[0], carray[0]) == 0); ATF_REQUIRE(std::strcmp(argv[1], carray[1]) == 0); ATF_REQUIRE(std::strcmp(argv[2], carray[2]) == 0); } } ATF_TEST_CASE(argv_array_init_col); ATF_TEST_CASE_HEAD(argv_array_init_col) { set_md_var("descr", "Tests that argv_array is correctly constructed " "from a string collection"); } ATF_TEST_CASE_BODY(argv_array_init_col) { { std::vector< std::string > col; atf::process::argv_array argv(col); ATF_REQUIRE_EQ(argv.size(), 0); } { std::vector< std::string > col; col.push_back("arg0"); atf::process::argv_array argv(col); ATF_REQUIRE_EQ(argv.size(), 1); ATF_REQUIRE_EQ(argv[0], col[0]); } { std::vector< std::string > col; col.push_back("arg0"); col.push_back("arg1"); col.push_back("arg2"); atf::process::argv_array argv(col); ATF_REQUIRE_EQ(argv.size(), 3); ATF_REQUIRE_EQ(argv[0], col[0]); ATF_REQUIRE_EQ(argv[1], col[1]); ATF_REQUIRE_EQ(argv[2], col[2]); } } ATF_TEST_CASE(argv_array_init_empty); ATF_TEST_CASE_HEAD(argv_array_init_empty) { set_md_var("descr", "Tests that argv_array is correctly constructed " "by the default constructor"); } ATF_TEST_CASE_BODY(argv_array_init_empty) { atf::process::argv_array argv; ATF_REQUIRE_EQ(argv.size(), 0); } ATF_TEST_CASE(argv_array_init_varargs); ATF_TEST_CASE_HEAD(argv_array_init_varargs) { set_md_var("descr", "Tests that argv_array is correctly constructed " "from a variable list of arguments"); } ATF_TEST_CASE_BODY(argv_array_init_varargs) { { atf::process::argv_array argv("arg0", NULL); ATF_REQUIRE_EQ(argv.size(), 1); ATF_REQUIRE_EQ(argv[0], std::string("arg0")); } { atf::process::argv_array argv("arg0", "arg1", "arg2", NULL); ATF_REQUIRE_EQ(argv.size(), 3); ATF_REQUIRE_EQ(argv[0], std::string("arg0")); ATF_REQUIRE_EQ(argv[1], std::string("arg1")); ATF_REQUIRE_EQ(argv[2], std::string("arg2")); } } ATF_TEST_CASE(argv_array_assign); ATF_TEST_CASE_HEAD(argv_array_assign) { set_md_var("descr", "Tests that assigning an argv_array works"); } ATF_TEST_CASE_BODY(argv_array_assign) { using atf::process::argv_array; const char* const carray1[] = { "arg1", NULL }; const char* const carray2[] = { "arg1", "arg2", NULL }; std::auto_ptr< argv_array > argv1(new argv_array(carray1)); std::auto_ptr< argv_array > argv2(new argv_array(carray2)); *argv2 = *argv1; ATF_REQUIRE_EQ(argv2->size(), argv1->size()); ATF_REQUIRE(std::strcmp((*argv2)[0], (*argv1)[0]) == 0); ATF_REQUIRE(argv2->exec_argv() != argv1->exec_argv()); argv1.release(); { const char* const* eargv2 = argv2->exec_argv(); ATF_REQUIRE(std::strcmp(eargv2[0], carray1[0]) == 0); ATF_REQUIRE_EQ(eargv2[1], static_cast< const char* >(NULL)); } argv2.release(); } ATF_TEST_CASE(argv_array_copy); ATF_TEST_CASE_HEAD(argv_array_copy) { set_md_var("descr", "Tests that copying an argv_array constructed from " "a C-style array of strings works"); } ATF_TEST_CASE_BODY(argv_array_copy) { using atf::process::argv_array; const char* const carray[] = { "arg0", NULL }; std::auto_ptr< argv_array > argv1(new argv_array(carray)); std::auto_ptr< argv_array > argv2(new argv_array(*argv1)); ATF_REQUIRE_EQ(argv2->size(), argv1->size()); ATF_REQUIRE(std::strcmp((*argv2)[0], (*argv1)[0]) == 0); ATF_REQUIRE(argv2->exec_argv() != argv1->exec_argv()); argv1.release(); { const char* const* eargv2 = argv2->exec_argv(); ATF_REQUIRE(std::strcmp(eargv2[0], carray[0]) == 0); ATF_REQUIRE_EQ(eargv2[1], static_cast< const char* >(NULL)); } argv2.release(); } ATF_TEST_CASE(argv_array_exec_argv); ATF_TEST_CASE_HEAD(argv_array_exec_argv) { set_md_var("descr", "Tests that the exec argv provided by an argv_array " "is correct"); } ATF_TEST_CASE_BODY(argv_array_exec_argv) { using atf::process::argv_array; { argv_array argv; const char* const* eargv = argv.exec_argv(); ATF_REQUIRE_EQ(array_size(eargv), 0); ATF_REQUIRE_EQ(eargv[0], static_cast< const char* >(NULL)); } { const char* const carray[] = { "arg0", NULL }; argv_array argv(carray); const char* const* eargv = argv.exec_argv(); ATF_REQUIRE_EQ(array_size(eargv), 1); ATF_REQUIRE(std::strcmp(eargv[0], "arg0") == 0); ATF_REQUIRE_EQ(eargv[1], static_cast< const char* >(NULL)); } { std::vector< std::string > col; col.push_back("arg0"); argv_array argv(col); const char* const* eargv = argv.exec_argv(); ATF_REQUIRE_EQ(array_size(eargv), 1); ATF_REQUIRE(std::strcmp(eargv[0], "arg0") == 0); ATF_REQUIRE_EQ(eargv[1], static_cast< const char* >(NULL)); } } ATF_TEST_CASE(argv_array_iter); ATF_TEST_CASE_HEAD(argv_array_iter) { set_md_var("descr", "Tests that an argv_array can be iterated"); } ATF_TEST_CASE_BODY(argv_array_iter) { using atf::process::argv_array; std::vector< std::string > vector; vector.push_back("arg0"); vector.push_back("arg1"); vector.push_back("arg2"); argv_array argv(vector); ATF_REQUIRE_EQ(argv.size(), 3); std::vector< std::string >::size_type pos = 0; for (argv_array::const_iterator iter = argv.begin(); iter != argv.end(); iter++) { ATF_REQUIRE_EQ(*iter, vector[pos]); pos++; } } // ------------------------------------------------------------------------ // Tests cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(exec_failure); ATF_TEST_CASE_HEAD(exec_failure) { set_md_var("descr", "Tests execing a command that reports failure"); } ATF_TEST_CASE_BODY(exec_failure) { const atf::process::status s = exec_process_helpers(*this, "exit-failure"); ATF_REQUIRE(s.exited()); ATF_REQUIRE_EQ(s.exitstatus(), EXIT_FAILURE); } ATF_TEST_CASE(exec_success); ATF_TEST_CASE_HEAD(exec_success) { set_md_var("descr", "Tests execing a command that reports success"); } ATF_TEST_CASE_BODY(exec_success) { const atf::process::status s = exec_process_helpers(*this, "exit-success"); ATF_REQUIRE(s.exited()); ATF_REQUIRE_EQ(s.exitstatus(), EXIT_SUCCESS); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the "argv_array" type. ATF_ADD_TEST_CASE(tcs, argv_array_assign); ATF_ADD_TEST_CASE(tcs, argv_array_copy); ATF_ADD_TEST_CASE(tcs, argv_array_exec_argv); ATF_ADD_TEST_CASE(tcs, argv_array_init_carray); ATF_ADD_TEST_CASE(tcs, argv_array_init_col); ATF_ADD_TEST_CASE(tcs, argv_array_init_empty); ATF_ADD_TEST_CASE(tcs, argv_array_init_varargs); ATF_ADD_TEST_CASE(tcs, argv_array_iter); // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, exec_failure); ATF_ADD_TEST_CASE(tcs, exec_success); } Index: head/contrib/atf/atf-c++/detail/sanity.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/sanity.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/sanity.hpp (revision 273929) @@ -1,37 +1,33 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_SANITY_HPP_) -#define _ATF_CXX_SANITY_HPP_ +#if !defined(ATF_CXX_DETAIL_SANITY_HPP) +#define ATF_CXX_DETAIL_SANITY_HPP extern "C" { -#include "../../atf-c/detail/sanity.h" +#include } -#endif // !defined(_ATF_CXX_SANITY_HPP_) +#endif // !defined(ATF_CXX_DETAIL_SANITY_HPP) Index: head/contrib/atf/atf-c++/detail/test_helpers.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/test_helpers.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/test_helpers.cpp (revision 273929) @@ -1,103 +1,100 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/test_helpers.hpp" + #include #include #include #include -#include "../check.hpp" -#include "../config.hpp" -#include "../macros.hpp" +#include -#include "fs.hpp" -#include "process.hpp" -#include "test_helpers.hpp" +#include "atf-c++/check.hpp" +#include "atf-c++/detail/env.hpp" +#include "atf-c++/detail/fs.hpp" +#include "atf-c++/detail/process.hpp" // Path to the directory containing the libatf-c tests, used to locate the // process_helpers program. If NULL (the default), the code will use a // relative path. Otherwise, the provided path will be used; this is so // that we can locate the helpers binary if the installation uses a // different layout than the one we provide (as is the case in FreeBSD). #if defined(ATF_C_TESTS_BASE) static const char* atf_c_tests_base = ATF_C_TESTS_BASE; #else static const char* atf_c_tests_base = NULL; #endif #undef ATF_C_TESTS_BASE bool build_check_cxx_o(const char* sfile) { std::vector< std::string > optargs; - optargs.push_back("-I" + atf::config::get("atf_includedir")); + optargs.push_back("-I" + atf::env::get("ATF_INCLUDEDIR", ATF_INCLUDEDIR)); optargs.push_back("-Wall"); optargs.push_back("-Werror"); return atf::check::build_cxx_o(sfile, "test.o", atf::process::argv_array(optargs)); } bool build_check_cxx_o_srcdir(const atf::tests::tc& tc, const char* sfile) { const atf::fs::path sfilepath = atf::fs::path(tc.get_config_var("srcdir")) / sfile; return build_check_cxx_o(sfilepath.c_str()); } void header_check(const char *hdrname) { std::ofstream srcfile("test.cpp"); ATF_REQUIRE(srcfile); srcfile << "#include <" << hdrname << ">\n"; srcfile.close(); const std::string failmsg = std::string("Header check failed; ") + hdrname + " is not self-contained"; if (!build_check_cxx_o("test.cpp")) ATF_FAIL(failmsg); } atf::fs::path get_process_helpers_path(const atf::tests::tc& tc, bool is_detail) { const char* helper = "detail/process_helpers"; if (atf_c_tests_base == NULL) { if (is_detail) return atf::fs::path(tc.get_config_var("srcdir")) / ".." / ".." / "atf-c" / helper; else return atf::fs::path(tc.get_config_var("srcdir")) / ".." / "atf-c" / helper; } else { return atf::fs::path(atf_c_tests_base) / helper; } } Index: head/contrib/atf/atf-c++/detail/test_helpers.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/test_helpers.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/test_helpers.hpp (revision 273929) @@ -1,111 +1,107 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2009 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if defined(TESTS_ATF_ATF_CXX_TEST_HELPERS_H) +#if defined(ATF_CXX_DETAIL_TEST_HELPERS_H) # error "Cannot include test_helpers.hpp more than once." #else -# define TESTS_ATF_ATF_CXX_TEST_HELPERS_H +# define ATF_CXX_DETAIL_TEST_HELPERS_H #endif #include #include #include #include -#include "../macros.hpp" -#include "../tests.hpp" -#include "process.hpp" +#include + +#include #define HEADER_TC(name, hdrname) \ ATF_TEST_CASE(name); \ ATF_TEST_CASE_HEAD(name) \ { \ set_md_var("descr", "Tests that the " hdrname " file can be " \ "included on its own, without any prerequisites"); \ } \ ATF_TEST_CASE_BODY(name) \ { \ header_check(hdrname); \ } #define BUILD_TC(name, sfile, descr, failmsg) \ ATF_TEST_CASE(name); \ ATF_TEST_CASE_HEAD(name) \ { \ set_md_var("descr", descr); \ } \ ATF_TEST_CASE_BODY(name) \ { \ if (!build_check_cxx_o_srcdir(*this, sfile)) \ ATF_FAIL(failmsg); \ } namespace atf { namespace tests { class tc; } } void header_check(const char*); bool build_check_cxx_o(const char*); bool build_check_cxx_o_srcdir(const atf::tests::tc&, const char*); atf::fs::path get_process_helpers_path(const atf::tests::tc&, bool); struct run_h_tc_data { const atf::tests::vars_map& m_config; run_h_tc_data(const atf::tests::vars_map& config) : m_config(config) {} }; template< class TestCase > void run_h_tc_child(void* v) { run_h_tc_data* data = static_cast< run_h_tc_data* >(v); TestCase tc; tc.init(data->m_config); tc.run("result"); std::exit(EXIT_SUCCESS); } template< class TestCase > void run_h_tc(atf::tests::vars_map config = atf::tests::vars_map()) { run_h_tc_data data(config); atf::process::child c = atf::process::fork( run_h_tc_child< TestCase >, atf::process::stream_redirect_path(atf::fs::path("stdout")), atf::process::stream_redirect_path(atf::fs::path("stderr")), &data); const atf::process::status s = c.wait(); ATF_REQUIRE(s.exited()); } Index: head/contrib/atf/atf-c++/detail/text.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/text.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/text.cpp (revision 273929) @@ -1,160 +1,156 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/text.hpp" + extern "C" { #include } #include #include extern "C" { -#include "../../atf-c/error.h" - -#include "../../atf-c/detail/text.h" +#include "atf-c/detail/text.h" +#include "atf-c/error.h" } -#include "exceptions.hpp" -#include "text.hpp" +#include "atf-c++/detail/exceptions.hpp" namespace impl = atf::text; #define IMPL_NAME "atf::text" char* impl::duplicate(const char* str) { char* copy = new char[std::strlen(str) + 1]; std::strcpy(copy, str); return copy; } bool impl::match(const std::string& str, const std::string& regex) { bool found; // Special case: regcomp does not like empty regular expressions. if (regex.empty()) { found = str.empty(); } else { ::regex_t preg; if (::regcomp(&preg, regex.c_str(), REG_EXTENDED) != 0) throw std::runtime_error("Invalid regular expression '" + regex + "'"); const int res = ::regexec(&preg, str.c_str(), 0, NULL, 0); regfree(&preg); if (res != 0 && res != REG_NOMATCH) throw std::runtime_error("Invalid regular expression " + regex); found = res == 0; } return found; } std::string impl::to_lower(const std::string& str) { std::string lc; for (std::string::const_iterator iter = str.begin(); iter != str.end(); iter++) lc += std::tolower(*iter); return lc; } std::vector< std::string > impl::split(const std::string& str, const std::string& delim) { std::vector< std::string > words; std::string::size_type pos = 0, newpos = 0; while (pos < str.length() && newpos != std::string::npos) { newpos = str.find(delim, pos); if (newpos != pos) words.push_back(str.substr(pos, newpos - pos)); pos = newpos + delim.length(); } return words; } std::string impl::trim(const std::string& str) { std::string::size_type pos1 = str.find_first_not_of(" \t"); std::string::size_type pos2 = str.find_last_not_of(" \t"); if (pos1 == std::string::npos && pos2 == std::string::npos) return ""; else if (pos1 == std::string::npos) return str.substr(0, str.length() - pos2); else if (pos2 == std::string::npos) return str.substr(pos1); else return str.substr(pos1, pos2 - pos1 + 1); } bool impl::to_bool(const std::string& str) { bool b; atf_error_t err = atf_text_to_bool(str.c_str(), &b); if (atf_is_error(err)) throw_atf_error(err); return b; } int64_t impl::to_bytes(std::string str) { if (str.empty()) throw std::runtime_error("Empty value"); const char unit = str[str.length() - 1]; int64_t multiplier; switch (unit) { case 'k': case 'K': multiplier = 1 << 10; break; case 'm': case 'M': multiplier = 1 << 20; break; case 'g': case 'G': multiplier = 1 << 30; break; case 't': case 'T': multiplier = int64_t(1) << 40; break; default: if (!std::isdigit(unit)) throw std::runtime_error(std::string("Unknown size unit '") + unit + "'"); multiplier = 1; } if (multiplier != 1) str.erase(str.length() - 1); return to_type< int64_t >(str) * multiplier; } Index: head/contrib/atf/atf-c++/detail/text.hpp =================================================================== --- head/contrib/atf/atf-c++/detail/text.hpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/text.hpp (revision 273929) @@ -1,153 +1,149 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_TEXT_HPP_) -#define _ATF_CXX_TEXT_HPP_ +#if !defined(ATF_CXX_DETAIL_TEXT_HPP) +#define ATF_CXX_DETAIL_TEXT_HPP extern "C" { #include } #include #include #include #include namespace atf { namespace text { //! //! \brief Duplicates a C string using the new[] allocator. //! //! Replaces the functionality of strdup by using the new[] allocator and //! thus allowing the resulting memory to be managed by utils::auto_array. //! char* duplicate(const char*); //! //! \brief Joins multiple words into a string. //! //! Joins a list of words into a string, separating them using the provided //! separator. Empty words are not omitted. //! template< class T > std::string join(const T& words, const std::string& separator) { std::string str; typename T::const_iterator iter = words.begin(); bool done = iter == words.end(); while (!done) { str += *iter; iter++; if (iter != words.end()) str += separator; else done = true; } return str; } //! //! \brief Checks if the string matches a regular expression. //! bool match(const std::string&, const std::string&); //! //! \brief Splits a string into words. //! //! Splits the given string into multiple words, all separated by the //! given delimiter. Multiple occurrences of the same delimiter are //! not condensed so that rejoining the words later on using the same //! delimiter results in the original string. //! std::vector< std::string > split(const std::string&, const std::string&); //! //! \brief Removes whitespace from the beginning and end of a string. //! std::string trim(const std::string&); //! //! \brief Converts a string to a boolean value. //! bool to_bool(const std::string&); //! //! \brief Converts the given string to a bytes size. //! int64_t to_bytes(std::string); //! //! \brief Changes the case of a string to lowercase. //! //! Returns a new string that is a lowercased version of the original //! one. //! std::string to_lower(const std::string&); //! //! \brief Converts the given object to a string. //! //! Returns a string with the representation of the given object. There //! must exist an operator<< method for that object. //! template< class T > std::string to_string(const T& ob) { std::ostringstream ss; ss << ob; return ss.str(); } //! //! \brief Converts the given string to another type. //! //! Attempts to convert the given string to the requested type. Throws //! an exception if the conversion failed. //! template< class T > T to_type(const std::string& str) { std::istringstream ss(str); T value; ss >> value; if (!ss.eof() || (ss.eof() && (ss.fail() || ss.bad()))) throw std::runtime_error("Cannot convert string to requested type"); return value; } } // namespace text } // namespace atf -#endif // !defined(_ATF_CXX_TEXT_HPP_) +#endif // !defined(ATF_CXX_DETAIL_TEXT_HPP) Index: head/contrib/atf/atf-c++/detail/text_test.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/text_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/text_test.cpp (revision 273929) @@ -1,390 +1,386 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/detail/text.hpp" + #include #include #include -#include "../macros.hpp" - -#include "text.hpp" +#include // ------------------------------------------------------------------------ // Test cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE(duplicate); ATF_TEST_CASE_HEAD(duplicate) { set_md_var("descr", "Tests the duplicate function"); } ATF_TEST_CASE_BODY(duplicate) { using atf::text::duplicate; const char* orig = "foo"; char* copy = duplicate(orig); ATF_REQUIRE_EQ(std::strlen(copy), 3); ATF_REQUIRE(std::strcmp(copy, "foo") == 0); std::strcpy(copy, "bar"); ATF_REQUIRE(std::strcmp(copy, "bar") == 0); ATF_REQUIRE(std::strcmp(orig, "foo") == 0); } ATF_TEST_CASE(join); ATF_TEST_CASE_HEAD(join) { set_md_var("descr", "Tests the join function"); } ATF_TEST_CASE_BODY(join) { using atf::text::join; // First set of tests using a non-sorted collection, std::vector. { std::vector< std::string > words; std::string str; words.clear(); str = join(words, ","); ATF_REQUIRE_EQ(str, ""); words.clear(); words.push_back(""); str = join(words, ","); ATF_REQUIRE_EQ(str, ""); words.clear(); words.push_back(""); words.push_back(""); str = join(words, ","); ATF_REQUIRE_EQ(str, ","); words.clear(); words.push_back("foo"); words.push_back(""); words.push_back("baz"); str = join(words, ","); ATF_REQUIRE_EQ(str, "foo,,baz"); words.clear(); words.push_back("foo"); words.push_back("bar"); words.push_back("baz"); str = join(words, ","); ATF_REQUIRE_EQ(str, "foo,bar,baz"); } // Second set of tests using a sorted collection, std::set. { std::set< std::string > words; std::string str; words.clear(); str = join(words, ","); ATF_REQUIRE_EQ(str, ""); words.clear(); words.insert(""); str = join(words, ","); ATF_REQUIRE_EQ(str, ""); words.clear(); words.insert("foo"); words.insert(""); words.insert("baz"); str = join(words, ","); ATF_REQUIRE_EQ(str, ",baz,foo"); words.clear(); words.insert("foo"); words.insert("bar"); words.insert("baz"); str = join(words, ","); ATF_REQUIRE_EQ(str, "bar,baz,foo"); } } ATF_TEST_CASE(match); ATF_TEST_CASE_HEAD(match) { set_md_var("descr", "Tests the match function"); } ATF_TEST_CASE_BODY(match) { using atf::text::match; ATF_REQUIRE_THROW(std::runtime_error, match("", "[")); ATF_REQUIRE(match("", "")); ATF_REQUIRE(!match("foo", "")); ATF_REQUIRE(match("", ".*")); ATF_REQUIRE(match("", "[a-z]*")); ATF_REQUIRE(match("hello", "hello")); ATF_REQUIRE(match("hello", "[a-z]+")); ATF_REQUIRE(match("hello", "^[a-z]+$")); ATF_REQUIRE(!match("hello", "helooo")); ATF_REQUIRE(!match("hello", "[a-z]+5")); ATF_REQUIRE(!match("hello", "^ [a-z]+$")); } ATF_TEST_CASE(split); ATF_TEST_CASE_HEAD(split) { set_md_var("descr", "Tests the split function"); } ATF_TEST_CASE_BODY(split) { using atf::text::split; std::vector< std::string > words; words = split("", " "); ATF_REQUIRE_EQ(words.size(), 0); words = split(" ", " "); ATF_REQUIRE_EQ(words.size(), 0); words = split(" ", " "); ATF_REQUIRE_EQ(words.size(), 0); words = split("a b", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "a"); ATF_REQUIRE_EQ(words[1], "b"); words = split("a b c d", " "); ATF_REQUIRE_EQ(words.size(), 4); ATF_REQUIRE_EQ(words[0], "a"); ATF_REQUIRE_EQ(words[1], "b"); ATF_REQUIRE_EQ(words[2], "c"); ATF_REQUIRE_EQ(words[3], "d"); words = split("foo bar", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); words = split("foo bar baz foobar", " "); ATF_REQUIRE_EQ(words.size(), 4); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); ATF_REQUIRE_EQ(words[2], "baz"); ATF_REQUIRE_EQ(words[3], "foobar"); words = split(" foo bar", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); words = split("foo bar", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); words = split("foo bar ", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); words = split(" foo bar ", " "); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "foo"); ATF_REQUIRE_EQ(words[1], "bar"); } ATF_TEST_CASE(split_delims); ATF_TEST_CASE_HEAD(split_delims) { set_md_var("descr", "Tests the split function using different delimiters"); } ATF_TEST_CASE_BODY(split_delims) { using atf::text::split; std::vector< std::string > words; words = split("", "/"); ATF_REQUIRE_EQ(words.size(), 0); words = split(" ", "/"); ATF_REQUIRE_EQ(words.size(), 1); ATF_REQUIRE_EQ(words[0], " "); words = split(" ", "/"); ATF_REQUIRE_EQ(words.size(), 1); ATF_REQUIRE_EQ(words[0], " "); words = split("a/b", "/"); ATF_REQUIRE_EQ(words.size(), 2); ATF_REQUIRE_EQ(words[0], "a"); ATF_REQUIRE_EQ(words[1], "b"); words = split("aLONGDELIMbcdLONGDELIMef", "LONGDELIM"); ATF_REQUIRE_EQ(words.size(), 3); ATF_REQUIRE_EQ(words[0], "a"); ATF_REQUIRE_EQ(words[1], "bcd"); ATF_REQUIRE_EQ(words[2], "ef"); } ATF_TEST_CASE(trim); ATF_TEST_CASE_HEAD(trim) { set_md_var("descr", "Tests the trim function"); } ATF_TEST_CASE_BODY(trim) { using atf::text::trim; ATF_REQUIRE_EQ(trim(""), ""); ATF_REQUIRE_EQ(trim(" "), ""); ATF_REQUIRE_EQ(trim("\t"), ""); ATF_REQUIRE_EQ(trim(" foo"), "foo"); ATF_REQUIRE_EQ(trim("\t foo"), "foo"); ATF_REQUIRE_EQ(trim(" \tfoo"), "foo"); ATF_REQUIRE_EQ(trim("foo\t "), "foo"); ATF_REQUIRE_EQ(trim("foo \t"), "foo"); ATF_REQUIRE_EQ(trim("foo bar"), "foo bar"); ATF_REQUIRE_EQ(trim("\t foo bar"), "foo bar"); ATF_REQUIRE_EQ(trim(" \tfoo bar"), "foo bar"); ATF_REQUIRE_EQ(trim("foo bar\t "), "foo bar"); ATF_REQUIRE_EQ(trim("foo bar \t"), "foo bar"); } ATF_TEST_CASE(to_bool); ATF_TEST_CASE_HEAD(to_bool) { set_md_var("descr", "Tests the to_string function"); } ATF_TEST_CASE_BODY(to_bool) { using atf::text::to_bool; ATF_REQUIRE(to_bool("true")); ATF_REQUIRE(to_bool("TRUE")); ATF_REQUIRE(to_bool("yes")); ATF_REQUIRE(to_bool("YES")); ATF_REQUIRE(!to_bool("false")); ATF_REQUIRE(!to_bool("FALSE")); ATF_REQUIRE(!to_bool("no")); ATF_REQUIRE(!to_bool("NO")); ATF_REQUIRE_THROW(std::runtime_error, to_bool("")); ATF_REQUIRE_THROW(std::runtime_error, to_bool("tru")); ATF_REQUIRE_THROW(std::runtime_error, to_bool("true2")); ATF_REQUIRE_THROW(std::runtime_error, to_bool("fals")); ATF_REQUIRE_THROW(std::runtime_error, to_bool("false2")); } ATF_TEST_CASE(to_bytes); ATF_TEST_CASE_HEAD(to_bytes) { set_md_var("descr", "Tests the to_bytes function"); } ATF_TEST_CASE_BODY(to_bytes) { using atf::text::to_bytes; ATF_REQUIRE_EQ(0, to_bytes("0")); ATF_REQUIRE_EQ(12345, to_bytes("12345")); ATF_REQUIRE_EQ(2 * 1024, to_bytes("2k")); ATF_REQUIRE_EQ(4 * 1024 * 1024, to_bytes("4m")); ATF_REQUIRE_EQ(int64_t(8) * 1024 * 1024 * 1024, to_bytes("8g")); ATF_REQUIRE_EQ(int64_t(16) * 1024 * 1024 * 1024 * 1024, to_bytes("16t")); ATF_REQUIRE_THROW_RE(std::runtime_error, "Empty", to_bytes("")); ATF_REQUIRE_THROW_RE(std::runtime_error, "Unknown size unit 'd'", to_bytes("12d")); ATF_REQUIRE_THROW(std::runtime_error, to_bytes(" ")); ATF_REQUIRE_THROW(std::runtime_error, to_bytes(" k")); } ATF_TEST_CASE(to_string); ATF_TEST_CASE_HEAD(to_string) { set_md_var("descr", "Tests the to_string function"); } ATF_TEST_CASE_BODY(to_string) { using atf::text::to_string; ATF_REQUIRE_EQ(to_string('a'), "a"); ATF_REQUIRE_EQ(to_string("a"), "a"); ATF_REQUIRE_EQ(to_string(5), "5"); } ATF_TEST_CASE(to_type); ATF_TEST_CASE_HEAD(to_type) { set_md_var("descr", "Tests the to_type function"); } ATF_TEST_CASE_BODY(to_type) { using atf::text::to_type; ATF_REQUIRE_EQ(to_type< int >("0"), 0); ATF_REQUIRE_EQ(to_type< int >("1234"), 1234); ATF_REQUIRE_THROW(std::runtime_error, to_type< int >(" ")); ATF_REQUIRE_THROW(std::runtime_error, to_type< int >("0 a")); ATF_REQUIRE_THROW(std::runtime_error, to_type< int >("a")); ATF_REQUIRE_EQ(to_type< float >("0.5"), 0.5); ATF_REQUIRE_EQ(to_type< float >("1234.5"), 1234.5); ATF_REQUIRE_THROW(std::runtime_error, to_type< float >("0.5 a")); ATF_REQUIRE_THROW(std::runtime_error, to_type< float >("a")); ATF_REQUIRE_EQ(to_type< std::string >("a"), "a"); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the free functions. ATF_ADD_TEST_CASE(tcs, duplicate); ATF_ADD_TEST_CASE(tcs, join); ATF_ADD_TEST_CASE(tcs, match); ATF_ADD_TEST_CASE(tcs, split); ATF_ADD_TEST_CASE(tcs, split_delims); ATF_ADD_TEST_CASE(tcs, trim); ATF_ADD_TEST_CASE(tcs, to_bool); ATF_ADD_TEST_CASE(tcs, to_bytes); ATF_ADD_TEST_CASE(tcs, to_string); ATF_ADD_TEST_CASE(tcs, to_type); } Index: head/contrib/atf/atf-c++/detail/version_helper.cpp =================================================================== --- head/contrib/atf/atf-c++/detail/version_helper.cpp (revision 273928) +++ head/contrib/atf/atf-c++/detail/version_helper.cpp (revision 273929) @@ -1,41 +1,41 @@ // Copyright 2014 Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: // // * Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // * Neither the name of Google Inc. nor the names of its contributors // may be used to endorse or promote products derived from this software // without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #if defined(HAVE_CONFIG_H) -#include "bconfig.h" +#include "config.h" #endif #include #include int main(void) { std::cout << PACKAGE_VERSION << "\n"; return EXIT_SUCCESS; } Index: head/contrib/atf/atf-c++/macros.hpp =================================================================== --- head/contrib/atf/atf-c++/macros.hpp (revision 273928) +++ head/contrib/atf/atf-c++/macros.hpp (revision 273929) @@ -1,222 +1,225 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_MACROS_HPP_) -#define _ATF_CXX_MACROS_HPP_ +#if !defined(ATF_CXX_MACROS_HPP) +#define ATF_CXX_MACROS_HPP #include #include #include #include // Do not define inline methods for the test case classes. Doing so // significantly increases the memory requirements of GNU G++ during // compilation. #define ATF_TEST_CASE_WITHOUT_HEAD(name) \ namespace { \ class atfu_tc_ ## name : public atf::tests::tc { \ void body(void) const; \ public: \ atfu_tc_ ## name(void); \ }; \ static atfu_tc_ ## name* atfu_tcptr_ ## name; \ atfu_tc_ ## name::atfu_tc_ ## name(void) : atf::tests::tc(#name, false) {} \ } #define ATF_TEST_CASE(name) \ namespace { \ class atfu_tc_ ## name : public atf::tests::tc { \ void head(void); \ void body(void) const; \ public: \ atfu_tc_ ## name(void); \ }; \ static atfu_tc_ ## name* atfu_tcptr_ ## name; \ atfu_tc_ ## name::atfu_tc_ ## name(void) : atf::tests::tc(#name, false) {} \ } #define ATF_TEST_CASE_WITH_CLEANUP(name) \ namespace { \ class atfu_tc_ ## name : public atf::tests::tc { \ void head(void); \ void body(void) const; \ void cleanup(void) const; \ public: \ atfu_tc_ ## name(void); \ }; \ static atfu_tc_ ## name* atfu_tcptr_ ## name; \ atfu_tc_ ## name::atfu_tc_ ## name(void) : atf::tests::tc(#name, true) {} \ } #define ATF_TEST_CASE_NAME(name) atfu_tc_ ## name #define ATF_TEST_CASE_USE(name) (atfu_tcptr_ ## name) = NULL #define ATF_TEST_CASE_HEAD(name) \ void \ atfu_tc_ ## name::head(void) #define ATF_TEST_CASE_BODY(name) \ void \ atfu_tc_ ## name::body(void) \ const #define ATF_TEST_CASE_CLEANUP(name) \ void \ atfu_tc_ ## name::cleanup(void) \ const #define ATF_FAIL(reason) atf::tests::tc::fail(reason) #define ATF_SKIP(reason) atf::tests::tc::skip(reason) #define ATF_PASS() atf::tests::tc::pass() -#define ATF_REQUIRE(x) \ +#define ATF_REQUIRE(expression) \ do { \ - if (!(x)) { \ + if (!(expression)) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " << #x << " not met"; \ + atfu_ss << "Line " << __LINE__ << ": " << #expression \ + << " not met"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } while (false) -#define ATF_REQUIRE_EQ(x, y) \ +#define ATF_REQUIRE_EQ(expected, actual) \ do { \ - if ((x) != (y)) { \ + if ((expected) != (actual)) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " << #x << " != " << #y \ - << " (" << (x) << " != " << (y) << ")"; \ + atfu_ss << "Line " << __LINE__ << ": " \ + << #expected << " != " << #actual \ + << " (" << (expected) << " != " << (actual) << ")"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } while (false) #define ATF_REQUIRE_IN(element, collection) \ ATF_REQUIRE((collection).find(element) != (collection).end()) #define ATF_REQUIRE_NOT_IN(element, collection) \ ATF_REQUIRE((collection).find(element) == (collection).end()) #define ATF_REQUIRE_MATCH(regexp, string) \ do { \ if (!atf::tests::detail::match(regexp, string)) { \ std::ostringstream atfu_ss; \ atfu_ss << "Line " << __LINE__ << ": '" << string << "' does not " \ << "match regexp '" << regexp << "'"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } while (false) -#define ATF_REQUIRE_THROW(e, x) \ +#define ATF_REQUIRE_THROW(expected_exception, statement) \ do { \ try { \ - x; \ + statement; \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " did not throw " \ - #e " as expected"; \ + atfu_ss << "Line " << __LINE__ \ + << ": " #statement " did not throw " #expected_exception \ + " as expected"; \ atf::tests::tc::fail(atfu_ss.str()); \ - } catch (const e&) { \ + } catch (const expected_exception&) { \ } catch (const std::exception& atfu_e) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " threw an " \ - "unexpected error (not " #e "): " << atfu_e.what(); \ + atfu_ss << "Line " << __LINE__ << ": " #statement " threw an " \ + "unexpected error (not " #expected_exception "): " \ + << atfu_e.what(); \ atf::tests::tc::fail(atfu_ss.str()); \ } catch (...) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " threw an " \ - "unexpected error (not " #e ")"; \ + atfu_ss << "Line " << __LINE__ << ": " #statement " threw an " \ + "unexpected error (not " #expected_exception ")"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } while (false) -#define ATF_REQUIRE_THROW_RE(type, regexp, x) \ +#define ATF_REQUIRE_THROW_RE(expected_exception, regexp, statement) \ do { \ try { \ - x; \ + statement; \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " did not throw " \ - #type " as expected"; \ + atfu_ss << "Line " << __LINE__ \ + << ": " #statement " did not throw " #expected_exception \ + " as expected"; \ atf::tests::tc::fail(atfu_ss.str()); \ - } catch (const type& e) { \ + } catch (const expected_exception& e) { \ if (!atf::tests::detail::match(regexp, e.what())) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " threw " #type "(" \ + atfu_ss << "Line " << __LINE__ \ + << ": " #statement " threw " #expected_exception "(" \ << e.what() << "), but does not match '" << regexp \ << "'"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } catch (const std::exception& atfu_e) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " threw an " \ - "unexpected error (not " #type "): " << atfu_e.what(); \ + atfu_ss << "Line " << __LINE__ << ": " #statement " threw an " \ + "unexpected error (not " #expected_exception "): " \ + << atfu_e.what(); \ atf::tests::tc::fail(atfu_ss.str()); \ } catch (...) { \ std::ostringstream atfu_ss; \ - atfu_ss << "Line " << __LINE__ << ": " #x " threw an " \ - "unexpected error (not " #type ")"; \ + atfu_ss << "Line " << __LINE__ << ": " #statement " threw an " \ + "unexpected error (not " #expected_exception ")"; \ atf::tests::tc::fail(atfu_ss.str()); \ } \ } while (false) -#define ATF_CHECK_ERRNO(exp_errno, bool_expr) \ - atf::tests::tc::check_errno(__FILE__, __LINE__, exp_errno, #bool_expr, \ - bool_expr) +#define ATF_CHECK_ERRNO(expected_errno, bool_expr) \ + atf::tests::tc::check_errno(__FILE__, __LINE__, expected_errno, \ + #bool_expr, bool_expr) -#define ATF_REQUIRE_ERRNO(exp_errno, bool_expr) \ - atf::tests::tc::require_errno(__FILE__, __LINE__, exp_errno, #bool_expr, \ - bool_expr) +#define ATF_REQUIRE_ERRNO(expected_errno, bool_expr) \ + atf::tests::tc::require_errno(__FILE__, __LINE__, expected_errno, \ + #bool_expr, bool_expr) #define ATF_INIT_TEST_CASES(tcs) \ namespace atf { \ namespace tests { \ - int run_tp(int, char* const*, \ + int run_tp(int, char**, \ void (*)(std::vector< atf::tests::tc * >&)); \ } \ } \ \ static void atfu_init_tcs(std::vector< atf::tests::tc * >&); \ \ int \ - main(int argc, char* const* argv) \ + main(int argc, char** argv) \ { \ return atf::tests::run_tp(argc, argv, atfu_init_tcs); \ } \ \ static \ void \ atfu_init_tcs(std::vector< atf::tests::tc * >& tcs) #define ATF_ADD_TEST_CASE(tcs, tcname) \ do { \ atfu_tcptr_ ## tcname = new atfu_tc_ ## tcname(); \ (tcs).push_back(atfu_tcptr_ ## tcname); \ } while (0); -#endif // !defined(_ATF_CXX_MACROS_HPP_) +#endif // !defined(ATF_CXX_MACROS_HPP) Index: head/contrib/atf/atf-c++/macros_hpp_test.cpp =================================================================== --- head/contrib/atf/atf-c++/macros_hpp_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/macros_hpp_test.cpp (revision 273929) @@ -1,130 +1,126 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#include - #include + +#include void atf_check_errno_semicolons(void) { // Check that ATF_CHECK_ERRNO does not contain a semicolon that would // cause an empty-statement that confuses some compilers. ATF_CHECK_ERRNO(1, 1 == 1); ATF_CHECK_ERRNO(2, 2 == 2); } void atf_require_inside_if(void) { // Make sure that ATF_REQUIRE can be used inside an if statement that // does not have braces. Earlier versions of it generated an error // if there was an else clause because they confused the compiler // by defining an unprotected nested if. if (true) ATF_REQUIRE(true); else ATF_REQUIRE(true); } void atf_require_eq_inside_if(void) { // Make sure that ATF_REQUIRE_EQ can be used inside an if statement // that does not have braces. Earlier versions of it generated an // error if there was an else clause because they confused the // compiler by defining an unprotected nested if. if (true) ATF_REQUIRE_EQ(true, true); else ATF_REQUIRE_EQ(true, true); } void atf_require_throw_runtime_error(void) { // Check that we can pass std::runtime_error to ATF_REQUIRE_THROW. // Earlier versions generated a warning because the macro's code also // attempted to capture this exception, and thus we had a duplicate // catch clause. ATF_REQUIRE_THROW(std::runtime_error, (void)0); } void atf_require_throw_inside_if(void) { // Make sure that ATF_REQUIRE_THROW can be used inside an if statement // that does not have braces. Earlier versions of it generated an // error because a trailing ; after a catch block was not allowed. if (true) ATF_REQUIRE_THROW(std::runtime_error, (void)0); else ATF_REQUIRE_THROW(std::runtime_error, (void)1); } void atf_require_errno_semicolons(void) { // Check that ATF_REQUIRE_ERRNO does not contain a semicolon that would // cause an empty-statement that confuses some compilers. ATF_REQUIRE_ERRNO(1, 1 == 1); ATF_REQUIRE_ERRNO(2, 2 == 2); } // Test case names should not be expanded during instatiation so that they // can have the exact same name as macros. #define TEST_MACRO_1 invalid + name #define TEST_MACRO_2 invalid + name #define TEST_MACRO_3 invalid + name ATF_TEST_CASE(TEST_MACRO_1); ATF_TEST_CASE_HEAD(TEST_MACRO_1) { } ATF_TEST_CASE_BODY(TEST_MACRO_1) { } void instantiate_1(void) { ATF_TEST_CASE_USE(TEST_MACRO_1); atf::tests::tc* the_test = new ATF_TEST_CASE_NAME(TEST_MACRO_1)(); delete the_test; } ATF_TEST_CASE_WITH_CLEANUP(TEST_MACRO_2); ATF_TEST_CASE_HEAD(TEST_MACRO_2) { } ATF_TEST_CASE_BODY(TEST_MACRO_2) { } ATF_TEST_CASE_CLEANUP(TEST_MACRO_2) { } void instatiate_2(void) { ATF_TEST_CASE_USE(TEST_MACRO_2); atf::tests::tc* the_test = new ATF_TEST_CASE_NAME(TEST_MACRO_2)(); delete the_test; } ATF_TEST_CASE_WITH_CLEANUP(TEST_MACRO_3); ATF_TEST_CASE_HEAD(TEST_MACRO_3) { } ATF_TEST_CASE_BODY(TEST_MACRO_3) { } ATF_TEST_CASE_CLEANUP(TEST_MACRO_3) { } void instatiate_3(void) { ATF_TEST_CASE_USE(TEST_MACRO_3); atf::tests::tc* the_test = new ATF_TEST_CASE_NAME(TEST_MACRO_3)(); delete the_test; } Index: head/contrib/atf/atf-c++/macros_test.cpp =================================================================== --- head/contrib/atf/atf-c++/macros_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/macros_test.cpp (revision 273929) @@ -1,815 +1,811 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/macros.hpp" + extern "C" { #include #include } #include #include #include #include -#include "macros.hpp" -#include "utils.hpp" +#include -#include "detail/fs.hpp" -#include "detail/process.hpp" -#include "detail/sanity.hpp" -#include "detail/test_helpers.hpp" -#include "detail/text.hpp" +#include "atf-c++/detail/fs.hpp" +#include "atf-c++/detail/process.hpp" +#include "atf-c++/detail/sanity.hpp" +#include "atf-c++/detail/test_helpers.hpp" +#include "atf-c++/detail/text.hpp" +#include "atf-c++/utils.hpp" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ static void create_ctl_file(const char *name) { ATF_REQUIRE(open(name, O_CREAT | O_WRONLY | O_TRUNC, 0644) != -1); } // ------------------------------------------------------------------------ // Auxiliary test cases. // ------------------------------------------------------------------------ ATF_TEST_CASE(h_pass); ATF_TEST_CASE_HEAD(h_pass) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_pass) { create_ctl_file("before"); ATF_PASS(); create_ctl_file("after"); } ATF_TEST_CASE(h_fail); ATF_TEST_CASE_HEAD(h_fail) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_fail) { create_ctl_file("before"); ATF_FAIL("Failed on purpose"); create_ctl_file("after"); } ATF_TEST_CASE(h_skip); ATF_TEST_CASE_HEAD(h_skip) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_skip) { create_ctl_file("before"); ATF_SKIP("Skipped on purpose"); create_ctl_file("after"); } ATF_TEST_CASE(h_require); ATF_TEST_CASE_HEAD(h_require) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require) { bool condition = atf::text::to_bool(get_config_var("condition")); create_ctl_file("before"); ATF_REQUIRE(condition); create_ctl_file("after"); } ATF_TEST_CASE(h_require_eq); ATF_TEST_CASE_HEAD(h_require_eq) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_eq) { long v1 = atf::text::to_type< long >(get_config_var("v1")); long v2 = atf::text::to_type< long >(get_config_var("v2")); create_ctl_file("before"); ATF_REQUIRE_EQ(v1, v2); create_ctl_file("after"); } ATF_TEST_CASE(h_require_in); ATF_TEST_CASE_HEAD(h_require_in) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_in) { const std::string element = get_config_var("value"); std::set< std::string > collection; collection.insert("foo"); collection.insert("bar"); collection.insert("baz"); create_ctl_file("before"); ATF_REQUIRE_IN(element, collection); create_ctl_file("after"); } ATF_TEST_CASE(h_require_match); ATF_TEST_CASE_HEAD(h_require_match) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_match) { const std::string regexp = get_config_var("regexp"); const std::string string = get_config_var("string"); create_ctl_file("before"); ATF_REQUIRE_MATCH(regexp, string); create_ctl_file("after"); } ATF_TEST_CASE(h_require_not_in); ATF_TEST_CASE_HEAD(h_require_not_in) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_not_in) { const std::string element = get_config_var("value"); std::set< std::string > collection; collection.insert("foo"); collection.insert("bar"); collection.insert("baz"); create_ctl_file("before"); ATF_REQUIRE_NOT_IN(element, collection); create_ctl_file("after"); } ATF_TEST_CASE(h_require_throw); ATF_TEST_CASE_HEAD(h_require_throw) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_throw) { create_ctl_file("before"); if (get_config_var("what") == "throw_int") ATF_REQUIRE_THROW(std::runtime_error, if (1) throw int(5)); else if (get_config_var("what") == "throw_rt") ATF_REQUIRE_THROW(std::runtime_error, if (1) throw std::runtime_error("e")); else if (get_config_var("what") == "no_throw_rt") ATF_REQUIRE_THROW(std::runtime_error, if (0) throw std::runtime_error("e")); create_ctl_file("after"); } ATF_TEST_CASE(h_require_throw_re); ATF_TEST_CASE_HEAD(h_require_throw_re) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_throw_re) { create_ctl_file("before"); if (get_config_var("what") == "throw_int") ATF_REQUIRE_THROW_RE(std::runtime_error, "5", if (1) throw int(5)); else if (get_config_var("what") == "throw_rt_match") ATF_REQUIRE_THROW_RE(std::runtime_error, "foo.*baz", if (1) throw std::runtime_error("a foo bar baz")); else if (get_config_var("what") == "throw_rt_no_match") ATF_REQUIRE_THROW_RE(std::runtime_error, "foo.*baz", if (1) throw std::runtime_error("baz foo bar a")); else if (get_config_var("what") == "no_throw_rt") ATF_REQUIRE_THROW_RE(std::runtime_error, "e", if (0) throw std::runtime_error("e")); create_ctl_file("after"); } static int errno_fail_stub(const int raised_errno) { errno = raised_errno; return -1; } static int errno_ok_stub(void) { return 0; } ATF_TEST_CASE(h_check_errno); ATF_TEST_CASE_HEAD(h_check_errno) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_check_errno) { create_ctl_file("before"); if (get_config_var("what") == "no_error") ATF_CHECK_ERRNO(-1, errno_ok_stub() == -1); else if (get_config_var("what") == "errno_ok") ATF_CHECK_ERRNO(2, errno_fail_stub(2) == -1); else if (get_config_var("what") == "errno_fail") ATF_CHECK_ERRNO(3, errno_fail_stub(4) == -1); else UNREACHABLE; create_ctl_file("after"); } ATF_TEST_CASE(h_require_errno); ATF_TEST_CASE_HEAD(h_require_errno) { set_md_var("descr", "Helper test case"); } ATF_TEST_CASE_BODY(h_require_errno) { create_ctl_file("before"); if (get_config_var("what") == "no_error") ATF_REQUIRE_ERRNO(-1, errno_ok_stub() == -1); else if (get_config_var("what") == "errno_ok") ATF_REQUIRE_ERRNO(2, errno_fail_stub(2) == -1); else if (get_config_var("what") == "errno_fail") ATF_REQUIRE_ERRNO(3, errno_fail_stub(4) == -1); else UNREACHABLE; create_ctl_file("after"); } // ------------------------------------------------------------------------ // Test cases for the macros. // ------------------------------------------------------------------------ ATF_TEST_CASE(pass); ATF_TEST_CASE_HEAD(pass) { set_md_var("descr", "Tests the ATF_PASS macro"); } ATF_TEST_CASE_BODY(pass) { ATF_TEST_CASE_USE(h_pass); run_h_tc< ATF_TEST_CASE_NAME(h_pass) >(); ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(atf::fs::path("before"))); ATF_REQUIRE(!atf::fs::exists(atf::fs::path("after"))); } ATF_TEST_CASE(fail); ATF_TEST_CASE_HEAD(fail) { set_md_var("descr", "Tests the ATF_FAIL macro"); } ATF_TEST_CASE_BODY(fail) { ATF_TEST_CASE_USE(h_fail); run_h_tc< ATF_TEST_CASE_NAME(h_fail) >(); ATF_REQUIRE(atf::utils::grep_file("^failed: Failed on purpose", "result")); ATF_REQUIRE(atf::fs::exists(atf::fs::path("before"))); ATF_REQUIRE(!atf::fs::exists(atf::fs::path("after"))); } ATF_TEST_CASE(skip); ATF_TEST_CASE_HEAD(skip) { set_md_var("descr", "Tests the ATF_SKIP macro"); } ATF_TEST_CASE_BODY(skip) { ATF_TEST_CASE_USE(h_skip); run_h_tc< ATF_TEST_CASE_NAME(h_skip) >(); ATF_REQUIRE(atf::utils::grep_file("^skipped: Skipped on purpose", "result")); ATF_REQUIRE(atf::fs::exists(atf::fs::path("before"))); ATF_REQUIRE(!atf::fs::exists(atf::fs::path("after"))); } ATF_TEST_CASE(require); ATF_TEST_CASE_HEAD(require) { set_md_var("descr", "Tests the ATF_REQUIRE macro"); } ATF_TEST_CASE_BODY(require) { struct test { const char *cond; bool ok; } *t, tests[] = { { "false", false }, { "true", true }, { NULL, false } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->cond != NULL; t++) { atf::tests::vars_map config; config["condition"] = t->cond; std::cout << "Checking with a " << t->cond << " value\n"; ATF_TEST_CASE_USE(h_require); run_h_tc< ATF_TEST_CASE_NAME(h_require) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { ATF_REQUIRE(atf::utils::grep_file( "^failed: .*condition not met", "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_eq); ATF_TEST_CASE_HEAD(require_eq) { set_md_var("descr", "Tests the ATF_REQUIRE_EQ macro"); } ATF_TEST_CASE_BODY(require_eq) { struct test { const char *v1; const char *v2; bool ok; } *t, tests[] = { { "1", "1", true }, { "1", "2", false }, { "2", "1", false }, { "2", "2", true }, { NULL, NULL, false } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->v1 != NULL; t++) { atf::tests::vars_map config; config["v1"] = t->v1; config["v2"] = t->v2; std::cout << "Checking with " << t->v1 << ", " << t->v2 << " and expecting " << (t->ok ? "true" : "false") << "\n"; ATF_TEST_CASE_USE(h_require_eq); run_h_tc< ATF_TEST_CASE_NAME(h_require_eq) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { ATF_REQUIRE(atf::utils::grep_file("^failed: .*v1 != v2", "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_in); ATF_TEST_CASE_HEAD(require_in) { set_md_var("descr", "Tests the ATF_REQUIRE_IN macro"); } ATF_TEST_CASE_BODY(require_in) { struct test { const char *value; bool ok; } *t, tests[] = { { "foo", true }, { "bar", true }, { "baz", true }, { "xxx", false }, { "fooa", false }, { "foo ", false }, { NULL, false } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->value != NULL; t++) { atf::tests::vars_map config; config["value"] = t->value; ATF_TEST_CASE_USE(h_require_in); run_h_tc< ATF_TEST_CASE_NAME(h_require_in) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { ATF_REQUIRE(atf::utils::grep_file("^failed: ", "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_match); ATF_TEST_CASE_HEAD(require_match) { set_md_var("descr", "Tests the ATF_REQUIRE_MATCH macro"); } ATF_TEST_CASE_BODY(require_match) { struct test { const char *regexp; const char *string; bool ok; } *t, tests[] = { { "foo.*bar", "this is a foo, bar, baz", true }, { "bar.*baz", "this is a baz, bar, foo", false }, { NULL, NULL, false } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->regexp != NULL; t++) { atf::tests::vars_map config; config["regexp"] = t->regexp; config["string"] = t->string; std::cout << "Checking with " << t->regexp << ", " << t->string << " and expecting " << (t->ok ? "true" : "false") << "\n"; ATF_TEST_CASE_USE(h_require_match); run_h_tc< ATF_TEST_CASE_NAME(h_require_match) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { ATF_REQUIRE(atf::utils::grep_file("^failed: ", "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_not_in); ATF_TEST_CASE_HEAD(require_not_in) { set_md_var("descr", "Tests the ATF_REQUIRE_NOT_IN macro"); } ATF_TEST_CASE_BODY(require_not_in) { struct test { const char *value; bool ok; } *t, tests[] = { { "foo", false }, { "bar", false }, { "baz", false }, { "xxx", true }, { "fooa", true }, { "foo ", true }, { NULL, false } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->value != NULL; t++) { atf::tests::vars_map config; config["value"] = t->value; ATF_TEST_CASE_USE(h_require_not_in); run_h_tc< ATF_TEST_CASE_NAME(h_require_not_in) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { ATF_REQUIRE(atf::utils::grep_file("^failed: ", "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_throw); ATF_TEST_CASE_HEAD(require_throw) { set_md_var("descr", "Tests the ATF_REQUIRE_THROW macro"); } ATF_TEST_CASE_BODY(require_throw) { struct test { const char *what; bool ok; const char *msg; } *t, tests[] = { { "throw_int", false, "unexpected error" }, { "throw_rt", true, NULL }, { "no_throw_rt", false, "did not throw" }, { NULL, false, NULL } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->what != NULL; t++) { atf::tests::vars_map config; config["what"] = t->what; std::cout << "Checking with " << t->what << " and expecting " << (t->ok ? "true" : "false") << "\n"; ATF_TEST_CASE_USE(h_require_throw); run_h_tc< ATF_TEST_CASE_NAME(h_require_throw) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { std::cout << "Checking that message contains '" << t->msg << "'\n"; std::string exp_result = std::string("^failed: .*") + t->msg; ATF_REQUIRE(atf::utils::grep_file(exp_result.c_str(), "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(require_throw_re); ATF_TEST_CASE_HEAD(require_throw_re) { set_md_var("descr", "Tests the ATF_REQUIRE_THROW_RE macro"); } ATF_TEST_CASE_BODY(require_throw_re) { struct test { const char *what; bool ok; const char *msg; } *t, tests[] = { { "throw_int", false, "unexpected error" }, { "throw_rt_match", true, NULL }, { "throw_rt_no_match", false, "threw.*runtime_error\\(baz foo bar a\\).*" "does not match 'foo\\.\\*baz'" }, { "no_throw_rt", false, "did not throw" }, { NULL, false, NULL } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->what != NULL; t++) { atf::tests::vars_map config; config["what"] = t->what; std::cout << "Checking with " << t->what << " and expecting " << (t->ok ? "true" : "false") << "\n"; ATF_TEST_CASE_USE(h_require_throw_re); run_h_tc< ATF_TEST_CASE_NAME(h_require_throw_re) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { std::cout << "Checking that message contains '" << t->msg << "'\n"; std::string exp_result = std::string("^failed: .*") + t->msg; ATF_REQUIRE(atf::utils::grep_file(exp_result.c_str(), "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } ATF_TEST_CASE(check_errno); ATF_TEST_CASE_HEAD(check_errno) { set_md_var("descr", "Tests the ATF_CHECK_ERRNO macro"); } ATF_TEST_CASE_BODY(check_errno) { struct test { const char *what; bool ok; const char *msg; } *t, tests[] = { { "no_error", false, "Expected true value in errno_ok_stub\\(\\) == -1" }, { "errno_ok", true, NULL }, { "errno_fail", false, "Expected errno 3, got 4, in errno_fail_stub\\(4\\) == -1" }, { NULL, false, NULL } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->what != NULL; t++) { atf::tests::vars_map config; config["what"] = t->what; ATF_TEST_CASE_USE(h_check_errno); run_h_tc< ATF_TEST_CASE_NAME(h_check_errno) >(config); ATF_REQUIRE(atf::fs::exists(before)); ATF_REQUIRE(atf::fs::exists(after)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); } else { ATF_REQUIRE(atf::utils::grep_file("^failed", "result")); std::string exp_result = "macros_test.cpp:[0-9]+: " + std::string(t->msg) + "$"; ATF_REQUIRE(atf::utils::grep_file(exp_result.c_str(), "stderr")); } atf::fs::remove(before); atf::fs::remove(after); } } ATF_TEST_CASE(require_errno); ATF_TEST_CASE_HEAD(require_errno) { set_md_var("descr", "Tests the ATF_REQUIRE_ERRNO macro"); } ATF_TEST_CASE_BODY(require_errno) { struct test { const char *what; bool ok; const char *msg; } *t, tests[] = { { "no_error", false, "Expected true value in errno_ok_stub\\(\\) == -1" }, { "errno_ok", true, NULL }, { "errno_fail", false, "Expected errno 3, got 4, in errno_fail_stub\\(4\\) == -1" }, { NULL, false, NULL } }; const atf::fs::path before("before"); const atf::fs::path after("after"); for (t = &tests[0]; t->what != NULL; t++) { atf::tests::vars_map config; config["what"] = t->what; ATF_TEST_CASE_USE(h_require_errno); run_h_tc< ATF_TEST_CASE_NAME(h_require_errno) >(config); ATF_REQUIRE(atf::fs::exists(before)); if (t->ok) { ATF_REQUIRE(atf::utils::grep_file("^passed", "result")); ATF_REQUIRE(atf::fs::exists(after)); } else { std::string exp_result = "^failed: .*macros_test.cpp:[0-9]+: " + std::string(t->msg) + "$"; ATF_REQUIRE(atf::utils::grep_file(exp_result.c_str(), "result")); ATF_REQUIRE(!atf::fs::exists(after)); } atf::fs::remove(before); if (t->ok) atf::fs::remove(after); } } // ------------------------------------------------------------------------ // Tests cases for the header file. // ------------------------------------------------------------------------ -HEADER_TC(include, "atf-c++/macros.hpp"); BUILD_TC(use, "macros_hpp_test.cpp", "Tests that the macros provided by the atf-c++/macros.hpp file " "do not cause syntax errors when used", "Build of macros_hpp_test.cpp failed; some macros in " "atf-c++/macros.hpp are broken"); ATF_TEST_CASE(detect_unused_tests); ATF_TEST_CASE_HEAD(detect_unused_tests) { set_md_var("descr", "Tests that defining an unused test case raises a warning (and " "thus an error)"); } ATF_TEST_CASE_BODY(detect_unused_tests) { const char* validate_compiler = "class test_class { public: int dummy; };\n" "#define define_unused static test_class unused\n" "define_unused;\n"; atf::utils::create_file("compiler_test.cpp", validate_compiler); if (build_check_cxx_o("compiler_test.cpp")) expect_fail("Compiler does not raise a warning on an unused " "static global variable declared by a macro"); if (build_check_cxx_o_srcdir(*this, "unused_test.cpp")) ATF_FAIL("Build of unused_test.cpp passed; unused test cases are " "not properly detected"); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test cases for the macros. ATF_ADD_TEST_CASE(tcs, pass); ATF_ADD_TEST_CASE(tcs, fail); ATF_ADD_TEST_CASE(tcs, skip); ATF_ADD_TEST_CASE(tcs, check_errno); ATF_ADD_TEST_CASE(tcs, require); ATF_ADD_TEST_CASE(tcs, require_eq); ATF_ADD_TEST_CASE(tcs, require_in); ATF_ADD_TEST_CASE(tcs, require_match); ATF_ADD_TEST_CASE(tcs, require_not_in); ATF_ADD_TEST_CASE(tcs, require_throw); ATF_ADD_TEST_CASE(tcs, require_throw_re); ATF_ADD_TEST_CASE(tcs, require_errno); // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); ATF_ADD_TEST_CASE(tcs, use); ATF_ADD_TEST_CASE(tcs, detect_unused_tests); } Index: head/contrib/atf/atf-c++/pkg_config_test.sh =================================================================== --- head/contrib/atf/atf-c++/pkg_config_test.sh (revision 273928) +++ head/contrib/atf/atf-c++/pkg_config_test.sh (revision 273929) @@ -1,147 +1,143 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # The following tests assume that the atfc++.pc file is installed in a # directory that is known by pkg-config. Otherwise they will fail, # and you will be required to adjust PKG_CONFIG_PATH accordingly. # # It would be possible to bypass this requirement by setting the path # explicitly during the tests, but then this would not do a real check # to ensure that the installation is working. require_pc() { pkg-config ${1} || atf_fail "pkg-config could not locate ${1}.pc;" \ "maybe need to set PKG_CONFIG_PATH?" } check_version() { ver1=$($(atf_get_srcdir)/detail/version_helper) echo "Version reported by builtin PACKAGE_VERSION: ${ver1}" atf_check -s eq:0 -o save:stdout -e empty pkg-config --modversion "${1}" ver2=$(cat stdout) echo "Version reported by pkg-config: ${ver2}" atf_check_equal ${ver1} ${ver2} } atf_test_case version version_head() { atf_set "descr" "Checks that the version in atf-c++ is correct" atf_set "require.progs" "pkg-config" } version_body() { require_pc "atf-c++" check_version "atf-c++" } atf_test_case build build_head() { atf_set "descr" "Checks that a test program can be built against" \ "the C++ library based on the pkg-config information" atf_set "require.progs" "pkg-config" } build_body() { require_pc "atf-c++" atf_check -s eq:0 -o save:stdout -e empty \ pkg-config --variable=cxx atf-c++ cxx=$(cat stdout) echo "Compiler is: ${cxx}" atf_require_prog ${cxx} cat >tp.cpp < #include ATF_TEST_CASE(tc); ATF_TEST_CASE_HEAD(tc) { set_md_var("descr", "A test case"); } ATF_TEST_CASE_BODY(tc) { std::cout << "Running\n"; } ATF_INIT_TEST_CASES(tcs) { ATF_ADD_TEST_CASE(tcs, tc); } EOF atf_check -s eq:0 -o save:stdout -e empty pkg-config --cflags atf-c++ cxxflags=$(cat stdout) echo "CXXFLAGS are: ${cxxflags}" atf_check -s eq:0 -o save:stdout -e empty \ pkg-config --libs-only-L --libs-only-other atf-c++ ldflags=$(cat stdout) atf_check -s eq:0 -o save:stdout -e empty \ pkg-config --libs-only-l atf-c++ libs=$(cat stdout) echo "LDFLAGS are: ${ldflags}" echo "LIBS are: ${libs}" atf_check -s eq:0 -o empty -e empty ${cxx} ${cxxflags} -o tp.o -c tp.cpp atf_check -s eq:0 -o empty -e empty ${cxx} ${ldflags} -o tp tp.o ${libs} libpath= for f in ${ldflags}; do case ${f} in -L*) dir=$(echo ${f} | sed -e 's,^-L,,') if [ -z "${libpath}" ]; then libpath="${dir}" else libpath="${libpath}:${dir}" fi ;; *) ;; esac done atf_check -s eq:0 -o empty -e empty test -x tp atf_check -s eq:0 -o match:'Running' -e empty -x \ "LD_LIBRARY_PATH=${libpath} ./tp tc" } atf_init_test_cases() { atf_add_test_case version atf_add_test_case build } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-c++/tests.cpp =================================================================== --- head/contrib/atf/atf-c++/tests.cpp (revision 273928) +++ head/contrib/atf/atf-c++/tests.cpp (revision 273929) @@ -1,710 +1,658 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/tests.hpp" + +#if defined(HAVE_CONFIG_H) +#include "config.h" +#endif + extern "C" { #include #include #include #include #include #include } #include #include #include #include #include #include #include #include #include #include #include #include extern "C" { #include "atf-c/error.h" #include "atf-c/tc.h" #include "atf-c/utils.h" } -#include "tests.hpp" +#include "atf-c++/detail/application.hpp" +#include "atf-c++/detail/auto_array.hpp" +#include "atf-c++/detail/env.hpp" +#include "atf-c++/detail/exceptions.hpp" +#include "atf-c++/detail/fs.hpp" +#include "atf-c++/detail/sanity.hpp" +#include "atf-c++/detail/text.hpp" -#include "detail/application.hpp" -#include "detail/auto_array.hpp" -#include "detail/env.hpp" -#include "detail/exceptions.hpp" -#include "detail/fs.hpp" -#include "detail/sanity.hpp" -#include "detail/text.hpp" +#if defined(HAVE_GNU_GETOPT) +# define GETOPT_POSIX "+" +#else +# define GETOPT_POSIX "" +#endif namespace impl = atf::tests; namespace detail = atf::tests::detail; #define IMPL_NAME "atf::tests" +using atf::application::usage_error; + // ------------------------------------------------------------------------ // The "atf_tp_writer" class. // ------------------------------------------------------------------------ detail::atf_tp_writer::atf_tp_writer(std::ostream& os) : m_os(os), m_is_first(true) { m_os << "Content-Type: application/X-atf-tp; version=\"1\"\n\n"; } void detail::atf_tp_writer::start_tc(const std::string& ident) { if (!m_is_first) m_os << "\n"; m_os << "ident: " << ident << "\n"; m_os.flush(); } void detail::atf_tp_writer::end_tc(void) { if (m_is_first) m_is_first = false; } void detail::atf_tp_writer::tc_meta_data(const std::string& name, const std::string& value) { PRE(name != "ident"); m_os << name << ": " << value << "\n"; m_os.flush(); } // ------------------------------------------------------------------------ // Free helper functions. // ------------------------------------------------------------------------ +std::string Program_Name; + +static void +set_program_name(const char* argv0) +{ + const std::string program_name = atf::fs::path(argv0).leaf_name(); + // Libtool workaround: if running from within the source tree (binaries + // that are not installed yet), skip the "lt-" prefix added to files in + // the ".libs" directory to show the real (not temporary) name. + if (program_name.substr(0, 3) == "lt-") + Program_Name = program_name.substr(3); + else + Program_Name = program_name; +} + bool detail::match(const std::string& regexp, const std::string& str) { return atf::text::match(str, regexp); } // ------------------------------------------------------------------------ // The "tc" class. // ------------------------------------------------------------------------ static std::map< atf_tc_t*, impl::tc* > wraps; static std::map< const atf_tc_t*, const impl::tc* > cwraps; struct impl::tc_impl { private: // Non-copyable. tc_impl(const tc_impl&); tc_impl& operator=(const tc_impl&); public: std::string m_ident; atf_tc_t m_tc; bool m_has_cleanup; tc_impl(const std::string& ident, const bool has_cleanup) : m_ident(ident), m_has_cleanup(has_cleanup) { } static void wrap_head(atf_tc_t *tc) { std::map< atf_tc_t*, impl::tc* >::iterator iter = wraps.find(tc); INV(iter != wraps.end()); (*iter).second->head(); } static void wrap_body(const atf_tc_t *tc) { std::map< const atf_tc_t*, const impl::tc* >::const_iterator iter = cwraps.find(tc); INV(iter != cwraps.end()); - try { - (*iter).second->body(); - } catch (const std::exception& e) { - (*iter).second->fail("Caught unhandled exception: " + std::string( - e.what())); - } catch (...) { - (*iter).second->fail("Caught unknown exception"); - } + (*iter).second->body(); } static void wrap_cleanup(const atf_tc_t *tc) { std::map< const atf_tc_t*, const impl::tc* >::const_iterator iter = cwraps.find(tc); INV(iter != cwraps.end()); (*iter).second->cleanup(); } }; impl::tc::tc(const std::string& ident, const bool has_cleanup) : pimpl(new tc_impl(ident, has_cleanup)) { } impl::tc::~tc(void) { cwraps.erase(&pimpl->m_tc); wraps.erase(&pimpl->m_tc); atf_tc_fini(&pimpl->m_tc); } void impl::tc::init(const vars_map& config) { atf_error_t err; auto_array< const char * > array(new const char*[(config.size() * 2) + 1]); const char **ptr = array.get(); for (vars_map::const_iterator iter = config.begin(); iter != config.end(); iter++) { *ptr = (*iter).first.c_str(); *(ptr + 1) = (*iter).second.c_str(); ptr += 2; } *ptr = NULL; wraps[&pimpl->m_tc] = this; cwraps[&pimpl->m_tc] = this; err = atf_tc_init(&pimpl->m_tc, pimpl->m_ident.c_str(), pimpl->wrap_head, pimpl->wrap_body, pimpl->m_has_cleanup ? pimpl->wrap_cleanup : NULL, array.get()); if (atf_is_error(err)) throw_atf_error(err); } bool impl::tc::has_config_var(const std::string& var) const { return atf_tc_has_config_var(&pimpl->m_tc, var.c_str()); } bool impl::tc::has_md_var(const std::string& var) const { return atf_tc_has_md_var(&pimpl->m_tc, var.c_str()); } const std::string impl::tc::get_config_var(const std::string& var) const { return atf_tc_get_config_var(&pimpl->m_tc, var.c_str()); } const std::string impl::tc::get_config_var(const std::string& var, const std::string& defval) const { return atf_tc_get_config_var_wd(&pimpl->m_tc, var.c_str(), defval.c_str()); } const std::string impl::tc::get_md_var(const std::string& var) const { return atf_tc_get_md_var(&pimpl->m_tc, var.c_str()); } const impl::vars_map impl::tc::get_md_vars(void) const { vars_map vars; char **array = atf_tc_get_md_vars(&pimpl->m_tc); try { char **ptr; for (ptr = array; *ptr != NULL; ptr += 2) vars[*ptr] = *(ptr + 1); } catch (...) { atf_utils_free_charpp(array); throw; } return vars; } void impl::tc::set_md_var(const std::string& var, const std::string& val) { atf_error_t err = atf_tc_set_md_var(&pimpl->m_tc, var.c_str(), val.c_str()); if (atf_is_error(err)) throw_atf_error(err); } void impl::tc::run(const std::string& resfile) const { atf_error_t err = atf_tc_run(&pimpl->m_tc, resfile.c_str()); if (atf_is_error(err)) throw_atf_error(err); } void impl::tc::run_cleanup(void) const { atf_error_t err = atf_tc_cleanup(&pimpl->m_tc); if (atf_is_error(err)) throw_atf_error(err); } void impl::tc::head(void) { } void impl::tc::cleanup(void) const { } void impl::tc::require_prog(const std::string& prog) const { atf_tc_require_prog(prog.c_str()); } void impl::tc::pass(void) { atf_tc_pass(); } void impl::tc::fail(const std::string& reason) { atf_tc_fail("%s", reason.c_str()); } void impl::tc::fail_nonfatal(const std::string& reason) { atf_tc_fail_nonfatal("%s", reason.c_str()); } void impl::tc::skip(const std::string& reason) { atf_tc_skip("%s", reason.c_str()); } void impl::tc::check_errno(const char* file, const int line, const int exp_errno, const char* expr_str, const bool result) { atf_tc_check_errno(file, line, exp_errno, expr_str, result); } void impl::tc::require_errno(const char* file, const int line, const int exp_errno, const char* expr_str, const bool result) { atf_tc_require_errno(file, line, exp_errno, expr_str, result); } void impl::tc::expect_pass(void) { atf_tc_expect_pass(); } void impl::tc::expect_fail(const std::string& reason) { atf_tc_expect_fail("%s", reason.c_str()); } void impl::tc::expect_exit(const int exitcode, const std::string& reason) { atf_tc_expect_exit(exitcode, "%s", reason.c_str()); } void impl::tc::expect_signal(const int signo, const std::string& reason) { atf_tc_expect_signal(signo, "%s", reason.c_str()); } void impl::tc::expect_death(const std::string& reason) { atf_tc_expect_death("%s", reason.c_str()); } void impl::tc::expect_timeout(const std::string& reason) { atf_tc_expect_timeout("%s", reason.c_str()); } // ------------------------------------------------------------------------ -// The "tp" class. +// Test program main code. // ------------------------------------------------------------------------ -class tp : public atf::application::app { -public: - typedef std::vector< impl::tc * > tc_vector; +namespace { -private: - static const char* m_description; +typedef std::vector< impl::tc * > tc_vector; - bool m_lflag; - atf::fs::path m_resfile; - std::string m_srcdir_arg; - atf::fs::path m_srcdir; +enum tc_part { BODY, CLEANUP }; - atf::tests::vars_map m_vars; - - std::string specific_args(void) const; - options_set specific_options(void) const; - void process_option(int, const char*); - - void (*m_add_tcs)(tc_vector&); - tc_vector m_tcs; - - void parse_vflag(const std::string&); - void handle_srcdir(void); - - tc_vector init_tcs(void); - - enum tc_part { - BODY, - CLEANUP, - }; - - void list_tcs(void); - impl::tc* find_tc(tc_vector, const std::string&); - static std::pair< std::string, tc_part > process_tcarg(const std::string&); - int run_tc(const std::string&); - -public: - tp(void (*)(tc_vector&)); - ~tp(void); - - int main(void); -}; - -const char* tp::m_description = - "This is an independent atf test program."; - -tp::tp(void (*add_tcs)(tc_vector&)) : - app(m_description, "atf-test-program(1)"), - m_lflag(false), - m_resfile("/dev/stdout"), - m_srcdir("."), - m_add_tcs(add_tcs) +static void +parse_vflag(const std::string& str, atf::tests::vars_map& vars) { -} - -tp::~tp(void) -{ - for (tc_vector::iterator iter = m_tcs.begin(); - iter != m_tcs.end(); iter++) { - impl::tc* tc = *iter; - - delete tc; - } -} - -std::string -tp::specific_args(void) - const -{ - return "test_case"; -} - -tp::options_set -tp::specific_options(void) - const -{ - using atf::application::option; - options_set opts; - opts.insert(option('l', "", "List test cases and their purpose")); - opts.insert(option('r', "resfile", "The file to which the test program " - "will write the results of the " - "executed test case")); - opts.insert(option('s', "srcdir", "Directory where the test's data " - "files are located")); - opts.insert(option('v', "var=value", "Sets the configuration variable " - "`var' to `value'")); - return opts; -} - -void -tp::process_option(int ch, const char* arg) -{ - switch (ch) { - case 'l': - m_lflag = true; - break; - - case 'r': - m_resfile = atf::fs::path(arg); - break; - - case 's': - m_srcdir_arg = arg; - break; - - case 'v': - parse_vflag(arg); - break; - - default: - UNREACHABLE; - } -} - -void -tp::parse_vflag(const std::string& str) -{ if (str.empty()) throw std::runtime_error("-v requires a non-empty argument"); std::vector< std::string > ws = atf::text::split(str, "="); if (ws.size() == 1 && str[str.length() - 1] == '=') { - m_vars[ws[0]] = ""; + vars[ws[0]] = ""; } else { if (ws.size() != 2) throw std::runtime_error("-v requires an argument of the form " "var=value"); - m_vars[ws[0]] = ws[1]; + vars[ws[0]] = ws[1]; } } -void -tp::handle_srcdir(void) +static atf::fs::path +handle_srcdir(const char* argv0, const std::string& srcdir_arg) { - if (m_srcdir_arg.empty()) { - m_srcdir = atf::fs::path(m_argv0).branch_path(); - if (m_srcdir.leaf_name() == ".libs") - m_srcdir = m_srcdir.branch_path(); + atf::fs::path srcdir("."); + + if (srcdir_arg.empty()) { + srcdir = atf::fs::path(argv0).branch_path(); + if (srcdir.leaf_name() == ".libs") + srcdir = srcdir.branch_path(); } else - m_srcdir = atf::fs::path(m_srcdir_arg); + srcdir = atf::fs::path(srcdir_arg); - if (!atf::fs::exists(m_srcdir / m_prog_name)) - throw std::runtime_error("Cannot find the test program in the " - "source directory `" + m_srcdir.str() + "'"); + if (!atf::fs::exists(srcdir / Program_Name)) + throw usage_error("Cannot find the test program in the source " + "directory `%s'", srcdir.c_str()); - if (!m_srcdir.is_absolute()) - m_srcdir = m_srcdir.to_absolute(); + if (!srcdir.is_absolute()) + srcdir = srcdir.to_absolute(); - m_vars["srcdir"] = m_srcdir.str(); + return srcdir; } -tp::tc_vector -tp::init_tcs(void) +static void +init_tcs(void (*add_tcs)(tc_vector&), tc_vector& tcs, + const atf::tests::vars_map& vars) { - m_add_tcs(m_tcs); - for (tc_vector::iterator iter = m_tcs.begin(); - iter != m_tcs.end(); iter++) { + add_tcs(tcs); + for (tc_vector::iterator iter = tcs.begin(); iter != tcs.end(); iter++) { impl::tc* tc = *iter; - tc->init(m_vars); + tc->init(vars); } - return m_tcs; } -// -// An auxiliary unary predicate that compares the given test case's -// identifier to the identifier stored in it. -// -class tc_equal_to_ident { - const std::string& m_ident; - -public: - tc_equal_to_ident(const std::string& i) : - m_ident(i) - { - } - - bool operator()(const impl::tc* tc) - { - return tc->get_md_var("ident") == m_ident; - } -}; - -void -tp::list_tcs(void) +static int +list_tcs(const tc_vector& tcs) { - tc_vector tcs = init_tcs(); detail::atf_tp_writer writer(std::cout); for (tc_vector::const_iterator iter = tcs.begin(); iter != tcs.end(); iter++) { const impl::vars_map vars = (*iter)->get_md_vars(); { impl::vars_map::const_iterator iter2 = vars.find("ident"); INV(iter2 != vars.end()); writer.start_tc((*iter2).second); } for (impl::vars_map::const_iterator iter2 = vars.begin(); iter2 != vars.end(); iter2++) { const std::string& key = (*iter2).first; if (key != "ident") writer.tc_meta_data(key, (*iter2).second); } writer.end_tc(); } + + return EXIT_SUCCESS; } -impl::tc* -tp::find_tc(tc_vector tcs, const std::string& name) +static impl::tc* +find_tc(tc_vector tcs, const std::string& name) { std::vector< std::string > ids; for (tc_vector::iterator iter = tcs.begin(); iter != tcs.end(); iter++) { impl::tc* tc = *iter; if (tc->get_md_var("ident") == name) return tc; } - throw atf::application::usage_error("Unknown test case `%s'", - name.c_str()); + throw usage_error("Unknown test case `%s'", name.c_str()); } -std::pair< std::string, tp::tc_part > -tp::process_tcarg(const std::string& tcarg) +static std::pair< std::string, tc_part > +process_tcarg(const std::string& tcarg) { const std::string::size_type pos = tcarg.find(':'); if (pos == std::string::npos) { return std::make_pair(tcarg, BODY); } else { const std::string tcname = tcarg.substr(0, pos); const std::string partname = tcarg.substr(pos + 1); if (partname == "body") return std::make_pair(tcname, BODY); else if (partname == "cleanup") return std::make_pair(tcname, CLEANUP); else { - using atf::application::usage_error; throw usage_error("Invalid test case part `%s'", partname.c_str()); } } } -int -tp::run_tc(const std::string& tcarg) +static int +run_tc(tc_vector& tcs, const std::string& tcarg, const atf::fs::path& resfile) { const std::pair< std::string, tc_part > fields = process_tcarg(tcarg); - impl::tc* tc = find_tc(init_tcs(), fields.first); + impl::tc* tc = find_tc(tcs, fields.first); if (!atf::env::has("__RUNNING_INSIDE_ATF_RUN") || atf::env::get( "__RUNNING_INSIDE_ATF_RUN") != "internal-yes-value") { - std::cerr << m_prog_name << ": WARNING: Running test cases without " - "atf-run(1) is unsupported\n"; - std::cerr << m_prog_name << ": WARNING: No isolation nor timeout " + std::cerr << Program_Name << ": WARNING: Running test cases outside " + "of kyua(1) is unsupported\n"; + std::cerr << Program_Name << ": WARNING: No isolation nor timeout " "control is being applied; you may get unexpected failures; see " "atf-test-case(4)\n"; } - try { - switch (fields.second) { - case BODY: - tc->run(m_resfile.str()); + switch (fields.second) { + case BODY: + tc->run(resfile.str()); + break; + case CLEANUP: + tc->run_cleanup(); + break; + default: + UNREACHABLE; + } + return EXIT_SUCCESS; +} + +static int +safe_main(int argc, char** argv, void (*add_tcs)(tc_vector&)) +{ + const char* argv0 = argv[0]; + + bool lflag = false; + atf::fs::path resfile("/dev/stdout"); + std::string srcdir_arg; + atf::tests::vars_map vars; + + int ch; + int old_opterr; + + old_opterr = opterr; + ::opterr = 0; + while ((ch = ::getopt(argc, argv, GETOPT_POSIX ":lr:s:v:")) != -1) { + switch (ch) { + case 'l': + lflag = true; break; - case CLEANUP: - tc->run_cleanup(); + + case 'r': + resfile = atf::fs::path(::optarg); break; + + case 's': + srcdir_arg = ::optarg; + break; + + case 'v': + parse_vflag(::optarg, vars); + break; + + case ':': + throw usage_error("Option -%c requires an argument.", ::optopt); + break; + + case '?': default: - UNREACHABLE; + throw usage_error("Unknown option -%c.", ::optopt); } - return EXIT_SUCCESS; - } catch (const std::runtime_error& e) { - std::cerr << "ERROR: " << e.what() << "\n"; - return EXIT_FAILURE; } -} + argc -= optind; + argv += optind; -int -tp::main(void) -{ - using atf::application::usage_error; + // Clear getopt state just in case the test wants to use it. + ::opterr = old_opterr; + ::optind = 1; +#if defined(HAVE_OPTRESET) + ::optreset = 1; +#endif + vars["srcdir"] = handle_srcdir(argv0, srcdir_arg).str(); + int errcode; - handle_srcdir(); - - if (m_lflag) { - if (m_argc > 0) + tc_vector tcs; + if (lflag) { + if (argc > 0) throw usage_error("Cannot provide test case names with -l"); - list_tcs(); - errcode = EXIT_SUCCESS; + init_tcs(add_tcs, tcs, vars); + errcode = list_tcs(tcs); } else { - if (m_argc == 0) + if (argc == 0) throw usage_error("Must provide a test case name"); - else if (m_argc > 1) + else if (argc > 1) throw usage_error("Cannot provide more than one test case name"); - INV(m_argc == 1); + INV(argc == 1); - errcode = run_tc(m_argv[0]); + init_tcs(add_tcs, tcs, vars); + errcode = run_tc(tcs, argv[0], resfile); } + for (tc_vector::iterator iter = tcs.begin(); iter != tcs.end(); iter++) { + impl::tc* tc = *iter; + delete tc; + } + return errcode; } +} // anonymous namespace + namespace atf { namespace tests { - int run_tp(int, char* const*, void (*)(tp::tc_vector&)); + int run_tp(int, char**, void (*)(tc_vector&)); } } int -impl::run_tp(int argc, char* const* argv, void (*add_tcs)(tp::tc_vector&)) +impl::run_tp(int argc, char** argv, void (*add_tcs)(tc_vector&)) { - return tp(add_tcs).run(argc, argv); + try { + set_program_name(argv[0]); + return ::safe_main(argc, argv, add_tcs); + } catch (const usage_error& e) { + std::cerr + << Program_Name << ": ERROR: " << e.what() << '\n' + << Program_Name << ": See atf-test-program(1) for usage details.\n"; + return EXIT_FAILURE; + } } Index: head/contrib/atf/atf-c++/tests.hpp =================================================================== --- head/contrib/atf/atf-c++/tests.hpp (revision 273928) +++ head/contrib/atf/atf-c++/tests.hpp (revision 273929) @@ -1,129 +1,125 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_TESTS_HPP_) -#define _ATF_CXX_TESTS_HPP_ +#if !defined(ATF_CXX_TESTS_HPP) +#define ATF_CXX_TESTS_HPP #include #include #include extern "C" { #include } namespace atf { namespace tests { namespace detail { class atf_tp_writer { std::ostream& m_os; bool m_is_first; public: atf_tp_writer(std::ostream&); void start_tc(const std::string&); void end_tc(void); void tc_meta_data(const std::string&, const std::string&); }; bool match(const std::string&, const std::string&); } // namespace // ------------------------------------------------------------------------ // The "vars_map" class. // ------------------------------------------------------------------------ typedef std::map< std::string, std::string > vars_map; // ------------------------------------------------------------------------ // The "tc" class. // ------------------------------------------------------------------------ struct tc_impl; class tc { // Non-copyable. tc(const tc&); tc& operator=(const tc&); std::auto_ptr< tc_impl > pimpl; protected: virtual void head(void); virtual void body(void) const = 0; virtual void cleanup(void) const; void require_prog(const std::string&) const; friend struct tc_impl; public: tc(const std::string&, const bool); virtual ~tc(void); void init(const vars_map&); const std::string get_config_var(const std::string&) const; const std::string get_config_var(const std::string&, const std::string&) const; const std::string get_md_var(const std::string&) const; const vars_map get_md_vars(void) const; bool has_config_var(const std::string&) const; bool has_md_var(const std::string&) const; void set_md_var(const std::string&, const std::string&); void run(const std::string&) const; void run_cleanup(void) const; // To be called from the child process only. static void pass(void) ATF_DEFS_ATTRIBUTE_NORETURN; static void fail(const std::string&) ATF_DEFS_ATTRIBUTE_NORETURN; static void fail_nonfatal(const std::string&); static void skip(const std::string&) ATF_DEFS_ATTRIBUTE_NORETURN; static void check_errno(const char*, const int, const int, const char*, const bool); static void require_errno(const char*, const int, const int, const char*, const bool); static void expect_pass(void); static void expect_fail(const std::string&); static void expect_exit(const int, const std::string&); static void expect_signal(const int, const std::string&); static void expect_death(const std::string&); static void expect_timeout(const std::string&); }; } // namespace tests } // namespace atf -#endif // !defined(_ATF_CXX_TESTS_HPP_) +#endif // !defined(ATF_CXX_TESTS_HPP) Index: head/contrib/atf/atf-c++/tests_test.cpp =================================================================== --- head/contrib/atf/atf-c++/tests_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/tests_test.cpp (revision 273929) @@ -1,201 +1,190 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/tests.hpp" + extern "C" { #include #include #include #include } #include +#include #include -#include "macros.hpp" +#include -#include "detail/test_helpers.hpp" -#include "detail/text.hpp" +#include "atf-c++/detail/text.hpp" // ------------------------------------------------------------------------ // Tests for the "atf_tp_writer" class. // ------------------------------------------------------------------------ static void print_indented(const std::string& str) { std::vector< std::string > ws = atf::text::split(str, "\n"); for (std::vector< std::string >::const_iterator iter = ws.begin(); iter != ws.end(); iter++) std::cout << ">>" << *iter << "<<\n"; } // XXX Should this string handling and verbosity level be part of the // ATF_REQUIRE_EQ macro? It may be hard to predict sometimes that a // string can have newlines in it, and so the error message generated // at the moment will be bogus if there are some. static void check_equal(const atf::tests::tc& tc, const std::string& str, const std::string& exp) { if (str != exp) { std::cout << "String equality check failed.\n" "Adding >> and << to delimit the string boundaries below.\n"; std::cout << "GOT:\n"; print_indented(str); std::cout << "EXPECTED:\n"; print_indented(exp); tc.fail("Constructed string differs from the expected one"); } } ATF_TEST_CASE(atf_tp_writer); ATF_TEST_CASE_HEAD(atf_tp_writer) { set_md_var("descr", "Verifies the application/X-atf-tp writer"); } ATF_TEST_CASE_BODY(atf_tp_writer) { std::ostringstream expss; std::ostringstream ss; #define RESET \ expss.str(""); \ ss.str("") #define CHECK \ check_equal(*this, ss.str(), expss.str()) { RESET; atf::tests::detail::atf_tp_writer w(ss); expss << "Content-Type: application/X-atf-tp; version=\"1\"\n\n"; CHECK; } { RESET; atf::tests::detail::atf_tp_writer w(ss); expss << "Content-Type: application/X-atf-tp; version=\"1\"\n\n"; CHECK; w.start_tc("test1"); expss << "ident: test1\n"; CHECK; w.end_tc(); CHECK; } { RESET; atf::tests::detail::atf_tp_writer w(ss); expss << "Content-Type: application/X-atf-tp; version=\"1\"\n\n"; CHECK; w.start_tc("test1"); expss << "ident: test1\n"; CHECK; w.end_tc(); CHECK; w.start_tc("test2"); expss << "\nident: test2\n"; CHECK; w.end_tc(); CHECK; } { RESET; atf::tests::detail::atf_tp_writer w(ss); expss << "Content-Type: application/X-atf-tp; version=\"1\"\n\n"; CHECK; w.start_tc("test1"); expss << "ident: test1\n"; CHECK; w.tc_meta_data("descr", "the description"); expss << "descr: the description\n"; CHECK; w.end_tc(); CHECK; w.start_tc("test2"); expss << "\nident: test2\n"; CHECK; w.tc_meta_data("descr", "second test case"); expss << "descr: second test case\n"; CHECK; w.tc_meta_data("require.progs", "/bin/cp"); expss << "require.progs: /bin/cp\n"; CHECK; w.tc_meta_data("X-custom", "foo bar baz"); expss << "X-custom: foo bar baz\n"; CHECK; w.end_tc(); CHECK; } #undef CHECK #undef RESET } // ------------------------------------------------------------------------ -// Tests cases for the header file. -// ------------------------------------------------------------------------ - -HEADER_TC(include, "atf-c++/tests.hpp"); - -// ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add tests for the "atf_tp_writer" class. ATF_ADD_TEST_CASE(tcs, atf_tp_writer); - - // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); } Index: head/contrib/atf/atf-c++/unused_test.cpp =================================================================== --- head/contrib/atf/atf-c++/unused_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/unused_test.cpp (revision 273929) @@ -1,52 +1,48 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2012 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#include +#include ATF_TEST_CASE(this_is_used); ATF_TEST_CASE_HEAD(this_is_used) { } ATF_TEST_CASE_BODY(this_is_used) { } ATF_TEST_CASE(this_is_unused); ATF_TEST_CASE_HEAD(this_is_unused) { } ATF_TEST_CASE_BODY(this_is_unused) { } ATF_INIT_TEST_CASES(tcs) { ATF_ADD_TEST_CASE(tcs, this_is_used); //ATF_ADD_TEST_CASE(tcs, this_is_unused); } Index: head/contrib/atf/atf-c++/utils.cpp =================================================================== --- head/contrib/atf/atf-c++/utils.cpp (revision 273928) +++ head/contrib/atf/atf-c++/utils.cpp (revision 273929) @@ -1,104 +1,100 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/utils.hpp" + extern "C" { #include "atf-c/utils.h" } #include #include - -#include "utils.hpp" void atf::utils::cat_file(const std::string& path, const std::string& prefix) { atf_utils_cat_file(path.c_str(), prefix.c_str()); } void atf::utils::copy_file(const std::string& source, const std::string& destination) { atf_utils_copy_file(source.c_str(), destination.c_str()); } bool atf::utils::compare_file(const std::string& path, const std::string& contents) { return atf_utils_compare_file(path.c_str(), contents.c_str()); } void atf::utils::create_file(const std::string& path, const std::string& contents) { atf_utils_create_file(path.c_str(), "%s", contents.c_str()); } bool atf::utils::file_exists(const std::string& path) { return atf_utils_file_exists(path.c_str()); } pid_t atf::utils::fork(void) { std::cout.flush(); std::cerr.flush(); return atf_utils_fork(); } bool atf::utils::grep_file(const std::string& regex, const std::string& path) { return atf_utils_grep_file("%s", path.c_str(), regex.c_str()); } bool atf::utils::grep_string(const std::string& regex, const std::string& str) { return atf_utils_grep_string("%s", str.c_str(), regex.c_str()); } void atf::utils::redirect(const int fd, const std::string& path) { if (fd == STDOUT_FILENO) std::cout.flush(); else if (fd == STDERR_FILENO) std::cerr.flush(); atf_utils_redirect(fd, path.c_str()); } void atf::utils::wait(const pid_t pid, const int exitstatus, const std::string& expout, const std::string& experr) { atf_utils_wait(pid, exitstatus, expout.c_str(), experr.c_str()); } Index: head/contrib/atf/atf-c++/utils.hpp =================================================================== --- head/contrib/atf/atf-c++/utils.hpp (revision 273928) +++ head/contrib/atf/atf-c++/utils.hpp (revision 273929) @@ -1,68 +1,64 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_UTILS_HPP_) -#define _ATF_CXX_UTILS_HPP_ +#if !defined(ATF_CXX_UTILS_HPP) +#define ATF_CXX_UTILS_HPP extern "C" { #include } #include namespace atf { namespace utils { void cat_file(const std::string&, const std::string&); bool compare_file(const std::string&, const std::string&); void copy_file(const std::string&, const std::string&); void create_file(const std::string&, const std::string&); bool file_exists(const std::string&); pid_t fork(void); bool grep_file(const std::string&, const std::string&); bool grep_string(const std::string&, const std::string&); void redirect(const int, const std::string&); void wait(const pid_t, const int, const std::string&, const std::string&); template< typename Collection > bool grep_collection(const std::string& regexp, const Collection& collection) { for (typename Collection::const_iterator iter = collection.begin(); iter != collection.end(); ++iter) { if (grep_string(regexp, *iter)) return true; } return false; } } // namespace utils } // namespace atf -#endif // !defined(_ATF_CXX_UTILS_HPP_) +#endif // !defined(ATF_CXX_UTILS_HPP) Index: head/contrib/atf/atf-c++/utils_test.cpp =================================================================== --- head/contrib/atf/atf-c++/utils_test.cpp (revision 273928) +++ head/contrib/atf/atf-c++/utils_test.cpp (revision 273929) @@ -1,487 +1,509 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +#include "atf-c++/utils.hpp" + extern "C" { #include #include #include #include } #include #include #include +#include #include #include -#include "macros.hpp" -#include "utils.hpp" +#include -#include "detail/test_helpers.hpp" - static std::string -read_file(const char *path) +read_file(const std::string& path) { char buffer[1024]; - const int fd = open(path, O_RDONLY); + const int fd = open(path.c_str(), O_RDONLY); if (fd == -1) - ATF_FAIL("Cannot open " + std::string(path)); + ATF_FAIL("Cannot open " + path); const ssize_t length = read(fd, buffer, sizeof(buffer) - 1); close(fd); ATF_REQUIRE(length != -1); if (length == sizeof(buffer) - 1) ATF_FAIL("Internal buffer not long enough to read temporary file"); ((char *)buffer)[length] = '\0'; return buffer; } // ------------------------------------------------------------------------ // Tests cases for the free functions. // ------------------------------------------------------------------------ ATF_TEST_CASE_WITHOUT_HEAD(cat_file__empty); ATF_TEST_CASE_BODY(cat_file__empty) { atf::utils::create_file("file.txt", ""); atf::utils::redirect(STDOUT_FILENO, "captured.txt"); atf::utils::cat_file("file.txt", "PREFIX"); std::cout.flush(); close(STDOUT_FILENO); ATF_REQUIRE_EQ("", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(cat_file__one_line); ATF_TEST_CASE_BODY(cat_file__one_line) { atf::utils::create_file("file.txt", "This is a single line\n"); atf::utils::redirect(STDOUT_FILENO, "captured.txt"); atf::utils::cat_file("file.txt", "PREFIX"); std::cout.flush(); close(STDOUT_FILENO); ATF_REQUIRE_EQ("PREFIXThis is a single line\n", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(cat_file__several_lines); ATF_TEST_CASE_BODY(cat_file__several_lines) { atf::utils::create_file("file.txt", "First\nSecond line\nAnd third\n"); atf::utils::redirect(STDOUT_FILENO, "captured.txt"); atf::utils::cat_file("file.txt", ">"); std::cout.flush(); close(STDOUT_FILENO); ATF_REQUIRE_EQ(">First\n>Second line\n>And third\n", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(cat_file__no_newline_eof); ATF_TEST_CASE_BODY(cat_file__no_newline_eof) { atf::utils::create_file("file.txt", "Foo\n bar baz"); atf::utils::redirect(STDOUT_FILENO, "captured.txt"); atf::utils::cat_file("file.txt", "PREFIX"); std::cout.flush(); close(STDOUT_FILENO); ATF_REQUIRE_EQ("PREFIXFoo\nPREFIX bar baz", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__empty__match); ATF_TEST_CASE_BODY(compare_file__empty__match) { atf::utils::create_file("test.txt", ""); ATF_REQUIRE(atf::utils::compare_file("test.txt", "")); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__empty__not_match); ATF_TEST_CASE_BODY(compare_file__empty__not_match) { atf::utils::create_file("test.txt", ""); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "\n")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "foo")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", " ")); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__short__match); ATF_TEST_CASE_BODY(compare_file__short__match) { atf::utils::create_file("test.txt", "this is a short file"); ATF_REQUIRE(atf::utils::compare_file("test.txt", "this is a short file")); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__short__not_match); ATF_TEST_CASE_BODY(compare_file__short__not_match) { atf::utils::create_file("test.txt", "this is a short file"); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "\n")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "this is a Short file")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "this is a short fil")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "this is a short file ")); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__long__match); ATF_TEST_CASE_BODY(compare_file__long__match) { char long_contents[3456]; size_t i = 0; for (; i < sizeof(long_contents) - 1; i++) long_contents[i] = '0' + (i % 10); long_contents[i] = '\0'; atf::utils::create_file("test.txt", long_contents); ATF_REQUIRE(atf::utils::compare_file("test.txt", long_contents)); } ATF_TEST_CASE_WITHOUT_HEAD(compare_file__long__not_match); ATF_TEST_CASE_BODY(compare_file__long__not_match) { char long_contents[3456]; size_t i = 0; for (; i < sizeof(long_contents) - 1; i++) long_contents[i] = '0' + (i % 10); long_contents[i] = '\0'; atf::utils::create_file("test.txt", long_contents); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "\n")); ATF_REQUIRE(!atf::utils::compare_file("test.txt", "0123456789")); long_contents[i - 1] = 'Z'; ATF_REQUIRE(!atf::utils::compare_file("test.txt", long_contents)); } ATF_TEST_CASE_WITHOUT_HEAD(copy_file__empty); ATF_TEST_CASE_BODY(copy_file__empty) { atf::utils::create_file("src.txt", ""); ATF_REQUIRE(chmod("src.txt", 0520) != -1); atf::utils::copy_file("src.txt", "dest.txt"); ATF_REQUIRE(atf::utils::compare_file("dest.txt", "")); struct stat sb; ATF_REQUIRE(stat("dest.txt", &sb) != -1); ATF_REQUIRE_EQ(0520, sb.st_mode & 0xfff); } ATF_TEST_CASE_WITHOUT_HEAD(copy_file__some_contents); ATF_TEST_CASE_BODY(copy_file__some_contents) { atf::utils::create_file("src.txt", "This is a\ntest file\n"); atf::utils::copy_file("src.txt", "dest.txt"); ATF_REQUIRE(atf::utils::compare_file("dest.txt", "This is a\ntest file\n")); } ATF_TEST_CASE_WITHOUT_HEAD(create_file); ATF_TEST_CASE_BODY(create_file) { atf::utils::create_file("test.txt", "This is a %d test"); ATF_REQUIRE_EQ("This is a %d test", read_file("test.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(file_exists); ATF_TEST_CASE_BODY(file_exists) { atf::utils::create_file("test.txt", "foo"); ATF_REQUIRE( atf::utils::file_exists("test.txt")); ATF_REQUIRE( atf::utils::file_exists("./test.txt")); ATF_REQUIRE(!atf::utils::file_exists("./test.tx")); ATF_REQUIRE(!atf::utils::file_exists("test.txt2")); } ATF_TEST_CASE_WITHOUT_HEAD(fork); ATF_TEST_CASE_BODY(fork) { std::cout << "Should not get into child\n"; std::cerr << "Should not get into child\n"; pid_t pid = atf::utils::fork(); if (pid == 0) { std::cout << "Child stdout\n"; std::cerr << "Child stderr\n"; exit(EXIT_SUCCESS); } int status; ATF_REQUIRE(waitpid(pid, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); - ATF_REQUIRE_EQ("Child stdout\n", read_file("atf_utils_fork_out.txt")); - ATF_REQUIRE_EQ("Child stderr\n", read_file("atf_utils_fork_err.txt")); + std::ostringstream out_name; + out_name << "atf_utils_fork_" << pid << "_out.txt"; + std::ostringstream err_name; + err_name << "atf_utils_fork_" << pid << "_err.txt"; + + ATF_REQUIRE_EQ("Child stdout\n", read_file(out_name.str())); + ATF_REQUIRE_EQ("Child stderr\n", read_file(err_name.str())); } ATF_TEST_CASE_WITHOUT_HEAD(grep_collection__set); ATF_TEST_CASE_BODY(grep_collection__set) { std::set< std::string > strings; strings.insert("First"); strings.insert("Second"); ATF_REQUIRE( atf::utils::grep_collection("irs", strings)); ATF_REQUIRE( atf::utils::grep_collection("cond", strings)); ATF_REQUIRE(!atf::utils::grep_collection("Third", strings)); } ATF_TEST_CASE_WITHOUT_HEAD(grep_collection__vector); ATF_TEST_CASE_BODY(grep_collection__vector) { std::vector< std::string > strings; strings.push_back("First"); strings.push_back("Second"); ATF_REQUIRE( atf::utils::grep_collection("irs", strings)); ATF_REQUIRE( atf::utils::grep_collection("cond", strings)); ATF_REQUIRE(!atf::utils::grep_collection("Third", strings)); } ATF_TEST_CASE_WITHOUT_HEAD(grep_file); ATF_TEST_CASE_BODY(grep_file) { atf::utils::create_file("test.txt", "line1\nthe second line\naaaabbbb\n"); ATF_REQUIRE(atf::utils::grep_file("line1", "test.txt")); ATF_REQUIRE(atf::utils::grep_file("second line", "test.txt")); ATF_REQUIRE(atf::utils::grep_file("aa.*bb", "test.txt")); ATF_REQUIRE(!atf::utils::grep_file("foo", "test.txt")); ATF_REQUIRE(!atf::utils::grep_file("bar", "test.txt")); ATF_REQUIRE(!atf::utils::grep_file("aaaaa", "test.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(grep_string); ATF_TEST_CASE_BODY(grep_string) { const char *str = "a string - aaaabbbb"; ATF_REQUIRE(atf::utils::grep_string("a string", str)); ATF_REQUIRE(atf::utils::grep_string("^a string", str)); ATF_REQUIRE(atf::utils::grep_string("aaaabbbb$", str)); ATF_REQUIRE(atf::utils::grep_string("aa.*bb", str)); ATF_REQUIRE(!atf::utils::grep_string("foo", str)); ATF_REQUIRE(!atf::utils::grep_string("bar", str)); ATF_REQUIRE(!atf::utils::grep_string("aaaaa", str)); } ATF_TEST_CASE_WITHOUT_HEAD(redirect__stdout); ATF_TEST_CASE_BODY(redirect__stdout) { std::cout << "Buffer this"; atf::utils::redirect(STDOUT_FILENO, "captured.txt"); std::cout << "The printed message"; std::cout.flush(); ATF_REQUIRE_EQ("The printed message", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(redirect__stderr); ATF_TEST_CASE_BODY(redirect__stderr) { std::cerr << "Buffer this"; atf::utils::redirect(STDERR_FILENO, "captured.txt"); std::cerr << "The printed message"; std::cerr.flush(); ATF_REQUIRE_EQ("The printed message", read_file("captured.txt")); } ATF_TEST_CASE_WITHOUT_HEAD(redirect__other); ATF_TEST_CASE_BODY(redirect__other) { const std::string message = "Foo bar\nbaz\n"; atf::utils::redirect(15, "captured.txt"); ATF_REQUIRE(write(15, message.c_str(), message.length()) != -1); close(15); ATF_REQUIRE_EQ(message, read_file("captured.txt")); } static void fork_and_wait(const int exitstatus, const char* expout, const char* experr) { const pid_t pid = atf::utils::fork(); if (pid == 0) { std::cout << "Some output\n"; std::cerr << "Some error\n"; exit(123); } atf::utils::wait(pid, exitstatus, expout, experr); exit(EXIT_SUCCESS); } ATF_TEST_CASE_WITHOUT_HEAD(wait__ok); ATF_TEST_CASE_BODY(wait__ok) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); } } +ATF_TEST_CASE_WITHOUT_HEAD(wait__ok_nested); +ATF_TEST_CASE_BODY(wait__ok_nested) +{ + const pid_t parent = atf::utils::fork(); + ATF_REQUIRE(parent != -1); + if (parent == 0) { + const pid_t child = atf::utils::fork(); + ATF_REQUIRE(child != -1); + if (child == 0) { + std::cerr.flush(); + std::cout << "Child output\n"; + std::cout.flush(); + std::cerr << "Child error\n"; + std::exit(50); + } else { + std::cout << "Parent output\n"; + std::cerr << "Parent error\n"; + atf::utils::wait(child, 50, "Child output\n", "Child error\n"); + std::exit(40); + } + } else { + atf::utils::wait(parent, 40, + "Parent output\n" + "subprocess stdout: Child output\n" + "subprocess stderr: Child error\n", + "Parent error\n"); + } +} + ATF_TEST_CASE_WITHOUT_HEAD(wait__invalid_exitstatus); ATF_TEST_CASE_BODY(wait__invalid_exitstatus) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(120, "Some output\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TEST_CASE_WITHOUT_HEAD(wait__invalid_stdout); ATF_TEST_CASE_BODY(wait__invalid_stdout) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output foo\n", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TEST_CASE_WITHOUT_HEAD(wait__invalid_stderr); ATF_TEST_CASE_BODY(wait__invalid_stderr) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "Some error foo\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_FAILURE, WEXITSTATUS(status)); } } ATF_TEST_CASE_WITHOUT_HEAD(wait__save_stdout); ATF_TEST_CASE_BODY(wait__save_stdout) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "save:my-output.txt", "Some error\n"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); ATF_REQUIRE(atf::utils::compare_file("my-output.txt", "Some output\n")); } } ATF_TEST_CASE_WITHOUT_HEAD(wait__save_stderr); ATF_TEST_CASE_BODY(wait__save_stderr) { const pid_t control = fork(); ATF_REQUIRE(control != -1); if (control == 0) fork_and_wait(123, "Some output\n", "save:my-output.txt"); else { int status; ATF_REQUIRE(waitpid(control, &status, 0) != -1); ATF_REQUIRE(WIFEXITED(status)); ATF_REQUIRE_EQ(EXIT_SUCCESS, WEXITSTATUS(status)); ATF_REQUIRE(atf::utils::compare_file("my-output.txt", "Some error\n")); } } // ------------------------------------------------------------------------ -// Tests cases for the header file. -// ------------------------------------------------------------------------ - -HEADER_TC(include, "atf-c++/utils.hpp"); - -// ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add the test for the free functions. ATF_ADD_TEST_CASE(tcs, cat_file__empty); ATF_ADD_TEST_CASE(tcs, cat_file__one_line); ATF_ADD_TEST_CASE(tcs, cat_file__several_lines); ATF_ADD_TEST_CASE(tcs, cat_file__no_newline_eof); ATF_ADD_TEST_CASE(tcs, compare_file__empty__match); ATF_ADD_TEST_CASE(tcs, compare_file__empty__not_match); ATF_ADD_TEST_CASE(tcs, compare_file__short__match); ATF_ADD_TEST_CASE(tcs, compare_file__short__not_match); ATF_ADD_TEST_CASE(tcs, compare_file__long__match); ATF_ADD_TEST_CASE(tcs, compare_file__long__not_match); ATF_ADD_TEST_CASE(tcs, copy_file__empty); ATF_ADD_TEST_CASE(tcs, copy_file__some_contents); ATF_ADD_TEST_CASE(tcs, create_file); ATF_ADD_TEST_CASE(tcs, file_exists); ATF_ADD_TEST_CASE(tcs, fork); ATF_ADD_TEST_CASE(tcs, grep_collection__set); ATF_ADD_TEST_CASE(tcs, grep_collection__vector); ATF_ADD_TEST_CASE(tcs, grep_file); ATF_ADD_TEST_CASE(tcs, grep_string); ATF_ADD_TEST_CASE(tcs, redirect__stdout); ATF_ADD_TEST_CASE(tcs, redirect__stderr); ATF_ADD_TEST_CASE(tcs, redirect__other); ATF_ADD_TEST_CASE(tcs, wait__ok); + ATF_ADD_TEST_CASE(tcs, wait__ok_nested); ATF_ADD_TEST_CASE(tcs, wait__invalid_exitstatus); ATF_ADD_TEST_CASE(tcs, wait__invalid_stdout); ATF_ADD_TEST_CASE(tcs, wait__invalid_stderr); ATF_ADD_TEST_CASE(tcs, wait__save_stdout); ATF_ADD_TEST_CASE(tcs, wait__save_stderr); - - // Add the test cases for the header file. - ATF_ADD_TEST_CASE(tcs, include); } Index: head/contrib/atf/atf-c++.hpp =================================================================== --- head/contrib/atf/atf-c++.hpp (revision 273928) +++ head/contrib/atf/atf-c++.hpp (revision 273929) @@ -1,36 +1,32 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -#if !defined(_ATF_CXX_HPP_) -#define _ATF_CXX_HPP_ +#if !defined(ATF_CXX_HPP) +#define ATF_CXX_HPP #include #include -#endif // !defined(_ATF_CXX_HPP_) +#endif // !defined(ATF_CXX_HPP) Index: head/contrib/atf/atf-c.h =================================================================== --- head/contrib/atf/atf-c.h (revision 273928) +++ head/contrib/atf/atf-c.h (revision 273929) @@ -1,37 +1,33 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2008 The NetBSD Foundation, Inc. +/* Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #if !defined(ATF_C_H) #define ATF_C_H #include #include #include #endif /* !defined(ATF_C_H) */ Index: head/contrib/atf/atf-sh/atf-check.1 =================================================================== --- head/contrib/atf/atf-sh/atf-check.1 (revision 273928) +++ head/contrib/atf/atf-sh/atf-check.1 (revision 273929) @@ -1,153 +1,160 @@ -.\" -.\" Automated Testing Framework (atf) -.\" .\" Copyright (c) 2008 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND .\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY .\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE .\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER .\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" -.Dd March 2, 2014 +.Dd October 5, 2014 .Dt ATF-CHECK 1 .Os .Sh NAME .Nm atf-check .Nd executes a command and analyzes its results .Sh SYNOPSIS .Nm .Op Fl s Ar qual:value .Op Fl o Ar action:arg ... .Op Fl e Ar action:arg ... .Op Fl x .Ar command -.Nm -.Fl h .Sh DESCRIPTION .Nm executes a given command and analyzes its results, including exit code, stdout and stderr. .Pp +.Em Test cases must use +.Em Xr atf-sh 3 Ns ' Ns s +.Em Nm atf_check +.Em builtin function instead of calling this utility directly. +.Pp In the first synopsis form, .Nm will execute the provided command and apply checks specified by arguments. By default it will act as if it was run with .Fl s .Ar exit:0 .Fl o .Ar empty .Fl e .Ar empty . Multiple checks for the same output channel are allowed and, if specified, their results will be combined as a logical and (meaning that the output must match all the provided checks). .Pp In the second synopsis form, .Nm will print information about all supported options and their purpose. .Pp The following options are available: .Bl -tag -width XqualXvalueXX -.It Fl h -Shows a short summary of all available options and their purpose. .It Fl s Ar qual:value Analyzes termination status. Must be one of: .Bl -tag -width signal: -compact .It Ar exit: checks that the program exited cleanly and that its exit status is equal to .Va value . The exit code can be omitted altogether, in which case any clean exit is accepted. .It Ar ignore ignores the exit check. .It Ar signal: checks that the program exited due to a signal and that the signal that terminated it is .Va value . The signal can be specified both as a number or as a name, or it can also be omitted altogether, in which case any signal is accepted. .El .Pp Most of these checkers can be prefixed by the .Sq not- string, which effectively reverses the check. .It Fl o Ar action:arg Analyzes standard output. Must be one of: .Bl -tag -width inline: -compact .It Ar empty checks that stdout is empty .It Ar ignore ignores stdout .It Ar file: compares stdout with given file .It Ar inline: compares stdout with inline value .It Ar match: looks for a regular expression in stdout .It Ar save: saves stdout to given file .El .Pp Most of these checkers can be prefixed by the .Sq not- string, which effectively reverses the check. .It Fl e Ar action:arg Analyzes standard error (syntax identical to above) .It Fl x Executes .Ar command as a shell command line, executing it with the system shell defined by .Va ATF_SHELL . You should avoid using this flag if at all possible to prevent shell quoting issues. .El .Sh EXIT STATUS .Nm exits 0 on success, and other (unspecified) value on failure. .Sh ENVIRONMENT .Bl -tag -width ATFXSHELLXX -compact .It Va ATF_SHELL Path to the system shell to be used when the .Fl x is given to run commands. .El .Sh EXAMPLES +The following are sample invocations from within a test case. +Note that we use the +.Nm atf_check +function provided by +.Xr atf-sh 3 +instead of executing +.Nm +directly: .Bd -literal -offset indent # Exit code 0, nothing on stdout/stderr -atf-check 'true' +atf_check 'true' # Typical usage if failure is expected -atf-check -s not-exit:0 'false' +atf_check -s not-exit:0 'false' # Checking stdout/stderr echo foobar >expout -atf-check -o file:expout -e inline:"xx\etyy\en" \e +atf_check -o file:expout -e inline:"xx\etyy\en" \e 'echo foobar ; printf "xx\etyy\en" >&2' # Checking for a crash -atf-check -s signal:sigsegv my_program +atf_check -s signal:sigsegv my_program # Combined checks -atf-check -o match:foo -o not-match:bar echo foo baz +atf_check -o match:foo -o not-match:bar echo foo baz .Ed +.Sh SEE ALSO +.Xr atf-sh 1 Index: head/contrib/atf/atf-sh/atf-check.cpp =================================================================== --- head/contrib/atf/atf-sh/atf-check.cpp (revision 273928) +++ head/contrib/atf/atf-sh/atf-check.cpp (revision 273929) @@ -1,838 +1,834 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2008 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// extern "C" { #include #include #include #include #include } #include #include #include #include #include #include #include #include #include #include #include "atf-c++/check.hpp" -#include "atf-c++/config.hpp" - #include "atf-c++/detail/application.hpp" #include "atf-c++/detail/auto_array.hpp" +#include "atf-c++/detail/env.hpp" #include "atf-c++/detail/exceptions.hpp" #include "atf-c++/detail/fs.hpp" #include "atf-c++/detail/process.hpp" #include "atf-c++/detail/sanity.hpp" #include "atf-c++/detail/text.hpp" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ namespace { enum status_check_t { sc_exit, sc_ignore, sc_signal, }; struct status_check { status_check_t type; bool negated; int value; status_check(const status_check_t& p_type, const bool p_negated, const int p_value) : type(p_type), negated(p_negated), value(p_value) { } }; enum output_check_t { oc_ignore, oc_inline, oc_file, oc_empty, oc_match, oc_save }; struct output_check { output_check_t type; bool negated; std::string value; output_check(const output_check_t& p_type, const bool p_negated, const std::string& p_value) : type(p_type), negated(p_negated), value(p_value) { } }; class temp_file : public std::ostream { std::auto_ptr< atf::fs::path > m_path; int m_fd; public: - temp_file(const atf::fs::path& p) : + temp_file(const char* pattern) : std::ostream(NULL), m_fd(-1) { - atf::auto_array< char > buf(new char[p.str().length() + 1]); - std::strcpy(buf.get(), p.c_str()); + const atf::fs::path file = atf::fs::path( + atf::env::get("TMPDIR", "/tmp")) / pattern; + atf::auto_array< char > buf(new char[file.str().length() + 1]); + std::strcpy(buf.get(), file.c_str()); + m_fd = ::mkstemp(buf.get()); if (m_fd == -1) throw atf::system_error("atf_check::temp_file::temp_file(" + - p.str() + ")", "mkstemp(3) failed", + file.str() + ")", "mkstemp(3) failed", errno); m_path.reset(new atf::fs::path(buf.get())); } ~temp_file(void) { close(); try { remove(*m_path); } catch (const atf::system_error&) { // Ignore deletion errors. } } const atf::fs::path& get_path(void) const { return *m_path; } void write(const std::string& text) { if (::write(m_fd, text.c_str(), text.size()) == -1) throw atf::system_error("atf_check", "write(2) failed", errno); } void close(void) { if (m_fd != -1) { flush(); ::close(m_fd); m_fd = -1; } } }; } // anonymous namespace static int parse_exit_code(const std::string& str) { try { const int value = atf::text::to_type< int >(str); if (value < 0 || value > 255) throw std::runtime_error("Unused reason"); return value; } catch (const std::runtime_error&) { throw atf::application::usage_error("Invalid exit code for -s option; " "must be an integer in range 0-255"); } } static struct name_number { const char *name; int signo; } signal_names_to_numbers[] = { { "hup", SIGHUP }, { "int", SIGINT }, { "quit", SIGQUIT }, { "trap", SIGTRAP }, { "abrt", SIGABRT }, { "kill", SIGKILL }, { "segv", SIGSEGV }, { "pipe", SIGPIPE }, { "alrm", SIGALRM }, { "term", SIGTERM }, { "usr1", SIGUSR1 }, { "usr2", SIGUSR2 }, { NULL, INT_MIN }, }; static int signal_name_to_number(const std::string& str) { struct name_number* iter = signal_names_to_numbers; int signo = INT_MIN; while (signo == INT_MIN && iter->name != NULL) { if (str == iter->name || str == std::string("sig") + iter->name) signo = iter->signo; else iter++; } return signo; } static int parse_signal(const std::string& str) { const int signo = signal_name_to_number(str); if (signo == INT_MIN) { try { return atf::text::to_type< int >(str); } catch (std::runtime_error) { throw atf::application::usage_error("Invalid signal name or number " "in -s option"); } } INV(signo != INT_MIN); return signo; } static status_check parse_status_check_arg(const std::string& arg) { const std::string::size_type delimiter = arg.find(':'); bool negated = (arg.compare(0, 4, "not-") == 0); const std::string action_str = arg.substr(0, delimiter); const std::string action = negated ? action_str.substr(4) : action_str; const std::string value_str = ( delimiter == std::string::npos ? "" : arg.substr(delimiter + 1)); int value; status_check_t type; if (action == "eq") { // Deprecated; use exit instead. TODO: Remove after 0.10. type = sc_exit; if (negated) throw atf::application::usage_error("Cannot negate eq checker"); negated = false; value = parse_exit_code(value_str); } else if (action == "exit") { type = sc_exit; if (value_str.empty()) value = INT_MIN; else value = parse_exit_code(value_str); } else if (action == "ignore") { if (negated) throw atf::application::usage_error("Cannot negate ignore checker"); type = sc_ignore; value = INT_MIN; } else if (action == "ne") { // Deprecated; use not-exit instead. TODO: Remove after 0.10. type = sc_exit; if (negated) throw atf::application::usage_error("Cannot negate ne checker"); negated = true; value = parse_exit_code(value_str); } else if (action == "signal") { type = sc_signal; if (value_str.empty()) value = INT_MIN; else value = parse_signal(value_str); } else throw atf::application::usage_error("Invalid status checker"); return status_check(type, negated, value); } static output_check parse_output_check_arg(const std::string& arg) { const std::string::size_type delimiter = arg.find(':'); const bool negated = (arg.compare(0, 4, "not-") == 0); const std::string action_str = arg.substr(0, delimiter); const std::string action = negated ? action_str.substr(4) : action_str; output_check_t type; if (action == "empty") type = oc_empty; else if (action == "file") type = oc_file; else if (action == "ignore") { if (negated) throw atf::application::usage_error("Cannot negate ignore checker"); type = oc_ignore; } else if (action == "inline") type = oc_inline; else if (action == "match") type = oc_match; else if (action == "save") { if (negated) throw atf::application::usage_error("Cannot negate save checker"); type = oc_save; } else throw atf::application::usage_error("Invalid output checker"); return output_check(type, negated, arg.substr(delimiter + 1)); } static std::string flatten_argv(char* const* argv) { std::string cmdline; char* const* arg = &argv[0]; while (*arg != NULL) { if (arg != &argv[0]) cmdline += ' '; cmdline += *arg; arg++; } return cmdline; } static std::auto_ptr< atf::check::check_result > execute(const char* const* argv) { // TODO: This should go to stderr... but fixing it now may be hard as test // cases out there might be relying on stderr being silent. std::cout << "Executing command [ "; for (int i = 0; argv[i] != NULL; ++i) std::cout << argv[i] << " "; std::cout << "]\n"; std::cout.flush(); atf::process::argv_array argva(argv); return atf::check::exec(argva); } static std::auto_ptr< atf::check::check_result > execute_with_shell(char* const* argv) { const std::string cmd = flatten_argv(argv); const char* sh_argv[4]; - sh_argv[0] = atf::config::get("atf_shell").c_str(); + sh_argv[0] = atf::env::get("ATF_SHELL", ATF_SHELL).c_str(); sh_argv[1] = "-c"; sh_argv[2] = cmd.c_str(); sh_argv[3] = NULL; return execute(sh_argv); } static void cat_file(const atf::fs::path& path) { std::ifstream stream(path.c_str()); if (!stream) throw std::runtime_error("Failed to open " + path.str()); stream >> std::noskipws; std::istream_iterator< char > begin(stream), end; std::ostream_iterator< char > out(std::cerr); std::copy(begin, end, out); stream.close(); } static bool grep_file(const atf::fs::path& path, const std::string& regexp) { std::ifstream stream(path.c_str()); if (!stream) throw std::runtime_error("Failed to open " + path.str()); bool found = false; std::string line; while (!found && !std::getline(stream, line).fail()) { if (atf::text::match(line, regexp)) found = true; } stream.close(); return found; } static bool file_empty(const atf::fs::path& p) { atf::fs::file_info f(p); return (f.get_size() == 0); } static bool compare_files(const atf::fs::path& p1, const atf::fs::path& p2) { bool equal = false; std::ifstream f1(p1.c_str()); if (!f1) throw std::runtime_error("Failed to open " + p1.str()); std::ifstream f2(p2.c_str()); if (!f2) throw std::runtime_error("Failed to open " + p1.str()); for (;;) { char buf1[512], buf2[512]; f1.read(buf1, sizeof(buf1)); if (f1.bad()) throw std::runtime_error("Failed to read from " + p1.str()); f2.read(buf2, sizeof(buf2)); if (f2.bad()) throw std::runtime_error("Failed to read from " + p1.str()); if ((f1.gcount() == 0) && (f2.gcount() == 0)) { equal = true; break; } if ((f1.gcount() != f2.gcount()) || (std::memcmp(buf1, buf2, f1.gcount()) != 0)) { break; } } return equal; } static void print_diff(const atf::fs::path& p1, const atf::fs::path& p2) { const atf::process::status s = atf::process::exec(atf::fs::path("diff"), atf::process::argv_array("diff", "-u", p1.c_str(), p2.c_str(), NULL), atf::process::stream_connect(STDOUT_FILENO, STDERR_FILENO), atf::process::stream_inherit()); if (!s.exited()) std::cerr << "Failed to run diff(3)\n"; if (s.exitstatus() != 1) std::cerr << "Error while running diff(3)\n"; } static std::string decode(const std::string& s) { size_t i; std::string res; res.reserve(s.length()); i = 0; while (i < s.length()) { char c = s[i++]; if (c == '\\') { switch (s[i++]) { case 'a': c = '\a'; break; case 'b': c = '\b'; break; case 'c': break; case 'e': c = 033; break; case 'f': c = '\f'; break; case 'n': c = '\n'; break; case 'r': c = '\r'; break; case 't': c = '\t'; break; case 'v': c = '\v'; break; case '\\': break; case '0': { int count = 3; c = 0; while (--count >= 0 && (unsigned)(s[i] - '0') < 8) c = (c << 3) + (s[i++] - '0'); break; } default: --i; break; } } res.push_back(c); } return res; } static bool run_status_check(const status_check& sc, const atf::check::check_result& cr) { bool result; if (sc.type == sc_exit) { if (cr.exited() && sc.value != INT_MIN) { const int status = cr.exitcode(); if (!sc.negated && sc.value != status) { std::cerr << "Fail: incorrect exit status: " << status << ", expected: " << sc.value << "\n"; result = false; } else if (sc.negated && sc.value == status) { std::cerr << "Fail: incorrect exit status: " << status << ", expected: " << "anything else\n"; result = false; } else result = true; } else if (cr.exited() && sc.value == INT_MIN) { result = true; } else { std::cerr << "Fail: program did not exit cleanly\n"; result = false; } } else if (sc.type == sc_ignore) { result = true; } else if (sc.type == sc_signal) { if (cr.signaled() && sc.value != INT_MIN) { const int status = cr.termsig(); if (!sc.negated && sc.value != status) { std::cerr << "Fail: incorrect signal received: " << status << ", expected: " << sc.value << "\n"; result = false; } else if (sc.negated && sc.value == status) { std::cerr << "Fail: incorrect signal received: " << status << ", expected: " << "anything else\n"; result = false; } else result = true; } else if (cr.signaled() && sc.value == INT_MIN) { result = true; } else { std::cerr << "Fail: program did not receive a signal\n"; result = false; } } else { UNREACHABLE; result = false; } if (result == false) { std::cerr << "stdout:\n"; cat_file(atf::fs::path(cr.stdout_path())); std::cerr << "\n"; std::cerr << "stderr:\n"; cat_file(atf::fs::path(cr.stderr_path())); std::cerr << "\n"; } return result; } static bool run_status_checks(const std::vector< status_check >& checks, const atf::check::check_result& result) { bool ok = false; for (std::vector< status_check >::const_iterator iter = checks.begin(); !ok && iter != checks.end(); iter++) { ok |= run_status_check(*iter, result); } return ok; } static bool run_output_check(const output_check oc, const atf::fs::path& path, const std::string& stdxxx) { bool result; if (oc.type == oc_empty) { const bool is_empty = file_empty(path); if (!oc.negated && !is_empty) { std::cerr << "Fail: " << stdxxx << " not empty\n"; print_diff(atf::fs::path("/dev/null"), path); result = false; } else if (oc.negated && is_empty) { std::cerr << "Fail: " << stdxxx << " is empty\n"; result = false; } else result = true; } else if (oc.type == oc_file) { const bool equals = compare_files(path, atf::fs::path(oc.value)); if (!oc.negated && !equals) { std::cerr << "Fail: " << stdxxx << " does not match golden " "output\n"; print_diff(atf::fs::path(oc.value), path); result = false; } else if (oc.negated && equals) { std::cerr << "Fail: " << stdxxx << " matches golden output\n"; cat_file(atf::fs::path(oc.value)); result = false; } else result = true; } else if (oc.type == oc_ignore) { result = true; } else if (oc.type == oc_inline) { - atf::fs::path path2 = atf::fs::path(atf::config::get("atf_workdir")) - / "inline.XXXXXX"; - temp_file temp(path2); + temp_file temp("atf-check.XXXXXX"); temp.write(decode(oc.value)); temp.close(); const bool equals = compare_files(path, temp.get_path()); if (!oc.negated && !equals) { std::cerr << "Fail: " << stdxxx << " does not match expected " "value\n"; print_diff(temp.get_path(), path); result = false; } else if (oc.negated && equals) { std::cerr << "Fail: " << stdxxx << " matches expected value\n"; cat_file(temp.get_path()); result = false; } else result = true; } else if (oc.type == oc_match) { const bool matches = grep_file(path, oc.value); if (!oc.negated && !matches) { std::cerr << "Fail: regexp " + oc.value + " not in " << stdxxx << "\n"; cat_file(path); result = false; } else if (oc.negated && matches) { std::cerr << "Fail: regexp " + oc.value + " is in " << stdxxx << "\n"; cat_file(path); result = false; } else result = true; } else if (oc.type == oc_save) { INV(!oc.negated); std::ifstream ifs(path.c_str(), std::fstream::binary); ifs >> std::noskipws; std::istream_iterator< char > begin(ifs), end; std::ofstream ofs(oc.value.c_str(), std::fstream::binary | std::fstream::trunc); std::ostream_iterator obegin(ofs); std::copy(begin, end, obegin); result = true; } else { UNREACHABLE; result = false; } return result; } static bool run_output_checks(const std::vector< output_check >& checks, const atf::fs::path& path, const std::string& stdxxx) { bool ok = true; for (std::vector< output_check >::const_iterator iter = checks.begin(); iter != checks.end(); iter++) { ok &= run_output_check(*iter, path, stdxxx); } return ok; } // ------------------------------------------------------------------------ // The "atf_check" application. // ------------------------------------------------------------------------ namespace { class atf_check : public atf::application::app { bool m_xflag; std::vector< status_check > m_status_checks; std::vector< output_check > m_stdout_checks; std::vector< output_check > m_stderr_checks; static const char* m_description; bool run_output_checks(const atf::check::check_result&, const std::string&) const; std::string specific_args(void) const; options_set specific_options(void) const; void process_option(int, const char*); void process_option_s(const std::string&); public: atf_check(void); int main(void); }; } // anonymous namespace const char* atf_check::m_description = "atf-check executes given command and analyzes its results."; atf_check::atf_check(void) : app(m_description, "atf-check(1)"), m_xflag(false) { } bool atf_check::run_output_checks(const atf::check::check_result& r, const std::string& stdxxx) const { if (stdxxx == "stdout") { return ::run_output_checks(m_stdout_checks, atf::fs::path(r.stdout_path()), "stdout"); } else if (stdxxx == "stderr") { return ::run_output_checks(m_stderr_checks, atf::fs::path(r.stderr_path()), "stderr"); } else { UNREACHABLE; return false; } } std::string atf_check::specific_args(void) const { return ""; } atf_check::options_set atf_check::specific_options(void) const { using atf::application::option; options_set opts; opts.insert(option('s', "qual:value", "Handle status. Qualifier " "must be one of: ignore exit: signal:")); opts.insert(option('o', "action:arg", "Handle stdout. Action must be " "one of: empty ignore file: inline: match:regexp " "save:")); opts.insert(option('e', "action:arg", "Handle stderr. Action must be " "one of: empty ignore file: inline: match:regexp " "save:")); opts.insert(option('x', "", "Execute command as a shell command")); return opts; } void atf_check::process_option(int ch, const char* arg) { switch (ch) { case 's': m_status_checks.push_back(parse_status_check_arg(arg)); break; case 'o': m_stdout_checks.push_back(parse_output_check_arg(arg)); break; case 'e': m_stderr_checks.push_back(parse_output_check_arg(arg)); break; case 'x': m_xflag = true; break; default: UNREACHABLE; } } int atf_check::main(void) { if (m_argc < 1) throw atf::application::usage_error("No command specified"); int status = EXIT_FAILURE; std::auto_ptr< atf::check::check_result > r = m_xflag ? execute_with_shell(m_argv) : execute(m_argv); if (m_status_checks.empty()) m_status_checks.push_back(status_check(sc_exit, false, EXIT_SUCCESS)); else if (m_status_checks.size() > 1) { // TODO: Remove this restriction. throw atf::application::usage_error("Cannot specify -s more than once"); } if (m_stdout_checks.empty()) m_stdout_checks.push_back(output_check(oc_empty, false, "")); if (m_stderr_checks.empty()) m_stderr_checks.push_back(output_check(oc_empty, false, "")); if ((run_status_checks(m_status_checks, *r) == false) || (run_output_checks(*r, "stderr") == false) || (run_output_checks(*r, "stdout") == false)) status = EXIT_FAILURE; else status = EXIT_SUCCESS; return status; } int main(int argc, char* const* argv) { return atf_check().run(argc, argv); } Index: head/contrib/atf/atf-sh/atf-check_test.sh =================================================================== --- head/contrib/atf/atf-sh/atf-check_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/atf-check_test.sh (revision 273929) @@ -1,463 +1,441 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # The Atf_Check and Atf-Shell variables are set by atf-sh. h_pass() { cmd="$1"; shift echo "Running [atf-check $*] against [${cmd}]" cat >script.sh <tmp; then cat tmp atf_fail "atf-check failed" fi } h_fail() { cmd="$1"; shift echo "Running [atf-check $*] against [${cmd}]" cat >script.sh <tmp; then cat tmp atf_fail "atf-check succeeded but should fail" fi } atf_test_case sflag_eq_ne sflag_eq_ne_head() { atf_set "descr" "Tests for the -s option using the 'eq' and 'ne' qualifiers" } sflag_eq_ne_body() { h_pass "true" -s eq:0 h_pass "false" -s ne:0 h_pass "exit 255" -s eq:255 h_pass "exit 0" -s ne:255 h_fail "exit 256" -s eq:256 h_fail "exit -1" -s eq:-1 h_fail "true" -s ne:256 h_fail "true" -s ne:-1 } atf_test_case sflag_exit sflag_exit_head() { atf_set "descr" "Tests for the -s option using the 'exit' qualifier" } sflag_exit_body() { h_pass 'true' -s exit:0 h_pass 'false' -s not-exit:0 h_pass 'exit 255' -s exit:255 h_pass 'exit 0' -s not-exit:255 h_fail 'exit 256' -s exit:256 h_fail 'exit -1' -s exit:-1 h_fail 'true' -s not-exit:256 h_fail 'true' -s not-exit:-1 h_pass 'true' -s exit h_pass 'false' -s exit if ${Atf_Check} -s exit -x 'kill $$'; then atf_fail "Signal detected as clean exit" fi } atf_test_case sflag_ignore sflag_ignore_head() { atf_set "descr" "Tests for the -s option using the 'ignore' qualifier" } sflag_ignore_body() { h_pass 'true' -s ignore h_pass 'false' -s ignore if ${Atf_Check} -s ignored -x 'kill $$'; then atf_fail "Signal not ignored" fi } atf_test_case sflag_signal sflag_signal_head() { atf_set "descr" "Tests for the -s option using the 'signal' qualifier" } sflag_signal_body() { ${Atf_Check} -s signal:hup -x 'kill -1 $$' || atf_fail "Signal not detected" ${Atf_Check} -s signal:sighup -x 'kill -1 $$' || atf_fail "Signal not" \ "detected" ${Atf_Check} -s signal:1 -x 'kill -1 $$' || atf_fail "Signal not detected" ${Atf_Check} -s signal -x 'kill -1 $$' || atf_fail "Signal not detected" ${Atf_Check} -s not-signal:kill -x 'kill -9 $$' && \ atf_fail "not-signal:kill matched kill -9" ${Atf_Check} -s not-signal:kill -x 'kill -1 $$' || \ atf_fail "not-signal:kill did not match kill -1" h_fail 'true' -s signal h_fail 'false' -s signal } atf_test_case xflag xflag_head() { atf_set "descr" "Tests for the -x option" } xflag_body() { ${Atf_Check} -s ne:0 -o ignore -e ignore "echo foo 2>&1" || \ atf_fail "Shell command succeeded without -x" ${Atf_Check} -e inline:"foo\n" -x "echo foo 1>&2" || \ atf_fail "Cannot run command with -x" ${Atf_Check} -o inline:"foo\n" -x echo foo || \ atf_fail "Using -x does not respect all provided arguments" } atf_test_case oflag_empty oflag_empty_head() { atf_set "descr" "Tests for the -o option using the 'empty' argument" } oflag_empty_body() { h_pass "true" -o empty h_fail "echo foo" -o empty } atf_test_case oflag_ignore oflag_ignore_head() { atf_set "descr" "Tests for the -o option using the 'ignore' argument" } oflag_ignore_body() { h_pass "true" -o ignore h_pass "echo foo" -o ignore } atf_test_case oflag_file oflag_file_head() { atf_set "descr" "Tests for the -o option using the 'file:' argument" } oflag_file_body() { touch empty h_pass "true" -o file:empty echo foo >text h_pass "echo foo" -o file:text h_fail "echo bar" -o file:text dd if=/dev/urandom of=bin bs=1k count=10 h_pass "cat bin" -o file:bin } atf_test_case oflag_inline oflag_inline_head() { atf_set "descr" "Tests for the -o option using the 'inline:' argument" } oflag_inline_body() { h_pass "true" -o inline: h_pass "echo foo bar" -o inline:"foo bar\n" h_pass "printf 'foo bar'" -o inline:"foo bar" h_pass "printf '\t\n\t\n'" -o inline:"\t\n\t\n" - # XXX Ugly hack to workaround the lack of \e in FreeBSD. Also, \e doesn't - # seem to work as expected in Linux. Look for a nicer solution. - case $(uname) in - Darwin|FreeBSD|Linux) - h_pass "printf '\a\b\f\n\r\t\v'" -o inline:"\a\b\f\n\r\t\v" - ;; - *) - h_pass "printf '\a\b\e\f\n\r\t\v'" -o inline:"\a\b\e\f\n\r\t\v" - ;; - esac + h_pass "printf '\a\b\033\f\n\r\t\v'" -o inline:"\a\b\e\f\n\r\t\v" h_pass "printf '\011\022\033\012'" -o inline:"\011\022\033\012" h_fail "echo foo bar" -o inline:"foo bar" h_fail "echo -n foo bar" -o inline:"foo bar\n" } atf_test_case oflag_match oflag_match_head() { atf_set "descr" "Tests for the -o option using the 'match:' argument" } oflag_match_body() { h_pass "printf no-newline" -o "match:^no-newline" h_pass "echo line1; echo foo bar" -o "match:^foo" h_pass "echo foo bar" -o "match:o b" h_fail "echo foo bar" -o "match:baz" h_fail "echo foo bar" -o "match:^bar" } atf_test_case oflag_save oflag_save_head() { atf_set "descr" "Tests for the -o option using the 'save:' argument" } oflag_save_body() { h_pass "echo foo" -o save:out echo foo >exp cmp -s out exp || atf_fail "Saved output does not match expected results" } atf_test_case oflag_multiple oflag_multiple_head() { atf_set "descr" "Tests for multiple occurrences of the -o option" } oflag_multiple_body() { h_pass "echo foo bar" -o match:foo -o match:bar h_pass "echo foo; echo bar" -o match:foo -o match:bar h_fail "echo foo baz" -o match:bar -o match:foo h_fail "echo foo; echo baz" -o match:bar -o match:foo } atf_test_case oflag_negated oflag_negated_head() { atf_set "descr" "Tests for negated occurrences of the -o option" } oflag_negated_body() { h_fail "echo foo" -o empty h_pass "echo foo" -o not-empty h_pass "echo foo bar" -o match:foo h_fail "echo foo bar" -o not-match:foo } atf_test_case eflag_empty eflag_empty_head() { atf_set "descr" "Tests for the -e option using the 'empty' argument" } eflag_empty_body() { h_pass "true 1>&2" -e empty h_fail "echo foo 1>&2" -e empty } atf_test_case eflag_ignore eflag_ignore_head() { atf_set "descr" "Tests for the -e option using the 'ignore' argument" } eflag_ignore_body() { h_pass "true 1>&2" -e ignore h_pass "echo foo 1>&2" -e ignore } atf_test_case eflag_file eflag_file_head() { atf_set "descr" "Tests for the -e option using the 'file:' argument" } eflag_file_body() { touch empty h_pass "true 1>&2" -e file:empty echo foo >text h_pass "echo foo 1>&2" -e file:text h_fail "echo bar 1>&2" -e file:text dd if=/dev/urandom of=bin bs=1k count=10 h_pass "cat bin 1>&2" -e file:bin } atf_test_case eflag_inline eflag_inline_head() { atf_set "descr" "Tests for the -e option using the 'inline:' argument" } eflag_inline_body() { h_pass "true 1>&2" -e inline: h_pass "echo foo bar 1>&2" -e inline:"foo bar\n" h_pass "printf 'foo bar' 1>&2" -e inline:"foo bar" h_pass "printf '\t\n\t\n' 1>&2" -e inline:"\t\n\t\n" - # XXX Ugly hack to workaround the lack of \e in FreeBSD. Also, \e doesn't - # seem to work as expected in Linux. Look for a nicer solution. - case $(uname) in - Darwin|FreeBSD|Linux) - h_pass "printf '\a\b\f\n\r\t\v' 1>&2" -e inline:"\a\b\f\n\r\t\v" - ;; - *) - h_pass "printf '\a\b\e\f\n\r\t\v' 1>&2" -e inline:"\a\b\e\f\n\r\t\v" - ;; - esac + h_pass "printf '\a\b\033\f\n\r\t\v' 1>&2" -e inline:"\a\b\e\f\n\r\t\v" h_pass "printf '\011\022\033\012' 1>&2" -e inline:"\011\022\033\012" h_fail "echo foo bar 1>&2" -e inline:"foo bar" h_fail "echo -n foo bar 1>&2" -e inline:"foo bar\n" } atf_test_case eflag_save eflag_save_head() { atf_set "descr" "Tests for the -e option using the 'save:' argument" } eflag_save_body() { h_pass "echo foo 1>&2" -e save:out echo foo >exp cmp -s out exp || atf_fail "Saved output does not match expected results" } atf_test_case eflag_match eflag_match_head() { atf_set "descr" "Tests for the -e option using the 'match:' argument" } eflag_match_body() { h_pass "printf no-newline 1>&2" -e "match:^no-newline" h_pass "echo line1 1>&2; echo foo bar 1>&2" -e "match:^foo" h_pass "echo foo bar 1>&2" -e "match:o b" h_fail "echo foo bar 1>&2" -e "match:baz" h_fail "echo foo bar 1>&2" -e "match:^bar" } atf_test_case eflag_multiple eflag_multiple_head() { atf_set "descr" "Tests for multiple occurrences of the -e option" } eflag_multiple_body() { h_pass "echo foo bar 1>&2" -e match:foo -e match:bar h_pass "echo foo 1>&2; echo bar 1>&2" -e match:foo -e match:bar h_fail "echo foo baz 1>&2" -e match:bar -e match:foo h_fail "echo foo 1>&2; echo baz 1>&2" -e match:bar -e match:foo } atf_test_case eflag_negated eflag_negated_head() { atf_set "descr" "Tests for negated occurrences of the -e option" } eflag_negated_body() { h_fail "echo foo 1>&2" -e empty h_pass "echo foo 1>&2" -e not-empty h_pass "echo foo bar 1>&2" -e match:foo h_fail "echo foo bar 1>&2" -e not-match:foo } atf_test_case stdin stdin_head() { atf_set "descr" "Tests that stdin is preserved" } stdin_body() { echo "hello" | ${Atf_Check} -o match:"hello" cat || \ atf_fail "atf-check does not seem to respect stdin" } atf_test_case invalid_umask invalid_umask_head() { atf_set "descr" "Tests for a correct error condition if the umask is" \ "too restrictive" } invalid_umask_body() { umask 0222 ${Atf_Check} false 2>stderr && \ atf_fail "atf-check returned 0 but it should have failed" cat stderr grep 'temporary.*current umask.*0222' stderr >/dev/null || \ atf_fail "atf-check did not report an error related to the" \ "current umask" } atf_init_test_cases() { atf_add_test_case sflag_eq_ne atf_add_test_case sflag_exit atf_add_test_case sflag_ignore atf_add_test_case sflag_signal atf_add_test_case xflag atf_add_test_case oflag_empty atf_add_test_case oflag_ignore atf_add_test_case oflag_file atf_add_test_case oflag_inline atf_add_test_case oflag_match atf_add_test_case oflag_save atf_add_test_case oflag_multiple atf_add_test_case oflag_negated atf_add_test_case eflag_empty atf_add_test_case eflag_ignore atf_add_test_case eflag_file atf_add_test_case eflag_inline atf_add_test_case eflag_match atf_add_test_case eflag_save atf_add_test_case eflag_multiple atf_add_test_case eflag_negated atf_add_test_case stdin atf_add_test_case invalid_umask } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/atf-sh.1 =================================================================== --- head/contrib/atf/atf-sh/atf-sh.1 (revision 273928) +++ head/contrib/atf/atf-sh/atf-sh.1 (revision 273929) @@ -1,75 +1,107 @@ -.\" -.\" Automated Testing Framework (atf) -.\" .\" Copyright (c) 2010 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND .\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY .\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE .\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER .\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" -.Dd March 2, 2014 +.Dd September 27, 2014 .Dt ATF-SH 1 .Os .Sh NAME .Nm atf-sh +.Op Fl s Ar shell .Nd interpreter for shell-based test programs .Sh SYNOPSIS .Nm .Ar script -.Nm -.Fl h .Sh DESCRIPTION .Nm is an interpreter that runs the test program given in .Ar script after loading the -.Xr atf-sh-api 3 +.Xr atf-sh 3 library. .Pp .Nm is not a real interpreter though: it is just a wrapper around the system-wide shell defined by .Va ATF_SHELL . .Nm executes the interpreter, loads the -.Xr atf-sh-api 3 +.Xr atf-sh 3 library and then runs the script. +You must consider +.Nm atf-sh +to be a POSIX shell by default and thus should not use any non-standard +extensions. .Pp +The following options are available: +.Bl -tag -width XsXshellXXX +.It Fl s Ar shell +Specifies the shell to use instead of the value provided by +.Va ATF_SHELL . +.El +.Sh ENVIRONMENT +.Bl -tag -width ATFXLIBEXECDIRXX -compact +.It Va ATF_LIBEXECDIR +Overrides the builtin directory where +.Nm +is located. +Should not be overridden other than for testing purposes. +.It Va ATF_PKGDATADIR +Overrides the builtin directory where +.Pa libatf-sh.subr +is located. +Should not be overridden other than for testing purposes. +.It Va ATF_SHELL +Path to the system shell to be used in the generated scripts. +Scripts must not rely on this variable being set to select a specific +interpreter. +.El +.Sh EXAMPLES Scripts using -.Xr atf-sh-api 3 +.Xr atf-sh 3 should start with: .Bd -literal -offset indent #! /usr/bin/env atf-sh .Ed .Pp -The following options are available: -.Bl -tag -width XhXX -.It Fl h -Shows a short summary of all available options and their purpose. -.El +Alternatively, if you want to explicitly choose a shell interpreter, you cannot +rely on +.Xr env 1 +to find +.Nm . +Instead, you have to hardcode the path to +.Nm +in the script and then use the +.Fl s +option afterwards as a +.Em single parameter : +.Bd -literal -offset indent +#! /path/to/bin/atf-sh -s/bin/bash +.Ed .Sh ENVIRONMENT .Bl -tag -width ATFXSHELLXX -compact .It Va ATF_SHELL Path to the system shell to be used in the generated scripts. .El .Sh SEE ALSO -.Xr atf-sh-api 3 +.Xr atf-sh 3 Index: head/contrib/atf/atf-sh/atf-sh.3 =================================================================== --- head/contrib/atf/atf-sh/atf-sh.3 (nonexistent) +++ head/contrib/atf/atf-sh/atf-sh.3 (revision 273929) @@ -0,0 +1,372 @@ +.\" Copyright (c) 2008 The NetBSD Foundation, Inc. +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND +.\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +.\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.Dd October 13, 2014 +.Dt ATF-SH 3 +.Os +.Sh NAME +.Nm atf_add_test_case , +.Nm atf_check , +.Nm atf_check_equal , +.Nm atf_config_get , +.Nm atf_config_has , +.Nm atf_expect_death , +.Nm atf_expect_exit , +.Nm atf_expect_fail , +.Nm atf_expect_pass , +.Nm atf_expect_signal , +.Nm atf_expect_timeout , +.Nm atf_fail , +.Nm atf_get , +.Nm atf_get_srcdir , +.Nm atf_pass , +.Nm atf_require_prog , +.Nm atf_set , +.Nm atf_skip , +.Nm atf_test_case +.Nd POSIX shell API to write ATF-based test programs +.Sh SYNOPSIS +.Nm atf_add_test_case +.Qq name +.Nm atf_check +.Qq command +.Nm atf_check_equal +.Qq expected_expression +.Qq actual_expression +.Nm atf_config_get +.Qq var_name +.Nm atf_config_has +.Qq var_name +.Nm atf_expect_death +.Qq reason +.Qq ... +.Nm atf_expect_exit +.Qq exitcode +.Qq reason +.Qq ... +.Nm atf_expect_fail +.Qq reason +.Qq ... +.Nm atf_expect_pass +.Qq +.Nm atf_expect_signal +.Qq signo +.Qq reason +.Qq ... +.Nm atf_expect_timeout +.Qq reason +.Qq ... +.Nm atf_fail +.Qq reason +.Nm atf_get +.Qq var_name +.Nm atf_get_srcdir +.Nm atf_pass +.Nm atf_require_prog +.Qq prog_name +.Nm atf_set +.Qq var_name +.Qq value +.Nm atf_skip +.Qq reason +.Nm atf_test_case +.Qq name +.Qq cleanup +.Sh DESCRIPTION +ATF +provides a simple but powerful interface to easily write test programs in +the POSIX shell language. +These are extremely helpful given that they are trivial to write due to the +language simplicity and the great deal of available external tools, so they +are often ideal to test other applications at the user level. +.Pp +Test programs written using this library must be run using the +.Xr atf-sh 1 +interpreter by putting the following on their very first line: +.Bd -literal -offset indent +#! /usr/bin/env atf-sh +.Ed +.Pp +Shell-based test programs always follow this template: +.Bd -literal -offset indent +atf_test_case tc1 +tc1_head() { + ... first test case's header ... +} +tc1_body() { + ... first test case's body ... +} + +atf_test_case tc2 cleanup +tc2_head() { + ... second test case's header ... +} +tc2_body() { + ... second test case's body ... +} +tc2_cleanup() { + ... second test case's cleanup ... +} + +.Ns ... additional test cases ... + +atf_init_test_cases() { + atf_add_test_case tc1 + atf_add_test_case tc2 + ... add additional test cases ... +} +.Ed +.Ss Definition of test cases +Test cases have an identifier and are composed of three different parts: +the header, the body and an optional cleanup routine, all of which are +described in +.Xr atf-test-case 4 . +To define test cases, one can use the +.Nm atf_test_case +function, which takes a first parameter specifiying the test case's +name and instructs the library to set things up to accept it as a valid +test case. +The second parameter is optional and, if provided, must be +.Sq cleanup ; +providing this parameter allows defining a cleanup routine for the test +case. +It is important to note that this function +.Em does not +set the test case up for execution when the program is run. +In order to do so, a later registration is needed through the +.Nm atf_add_test_case +function detailed in +.Sx Program initialization . +.Pp +Later on, one must define the three parts of the body by providing two +or three functions (remember that the cleanup routine is optional). +These functions are named after the test case's identifier, and are +.Nm \*(Ltid\*(Gt_head , +.Nm \*(Ltid\*(Gt_body +and +.Nm \*(Ltid\*(Gt_cleanup . +None of these take parameters when executed. +.Ss Program initialization +The test program must define an +.Nm atf_init_test_cases +function, which is in charge of registering the test cases that will be +executed at run time by using the +.Nm atf_add_test_case +function, which takes the name of a test case as its single parameter. +This main function should not do anything else, except maybe sourcing +auxiliary source files that define extra variables and functions. +.Ss Configuration variables +The test case has read-only access to the current configuration variables +through the +.Nm atf_config_has +and +.Nm atf_config_get +methods. +The former takes a single parameter specifying a variable name and returns +a boolean indicating whether the variable is defined or not. +The latter can take one or two parameters. +If it takes only one, it specifies the variable from which to get the +value, and this variable must be defined. +If it takes two, the second one specifies a default value to be returned +if the variable is not available. +.Ss Access to the source directory +It is possible to get the path to the test case's source directory from +anywhere in the test program by using the +.Nm atf_get_srcdir +function. +It is interesting to note that this can be used inside +.Nm atf_init_test_cases +to silently include additional helper files from the source directory. +.Ss Requiring programs +Aside from the +.Va require.progs +meta-data variable available in the header only, one can also check for +additional programs in the test case's body by using the +.Nm atf_require_prog +function, which takes the base name or full path of a single binary. +Relative paths are forbidden. +If it is not found, the test case will be automatically skipped. +.Ss Test case finalization +The test case finalizes either when the body reaches its end, at which +point the test is assumed to have +.Em passed , +or at any explicit call to +.Nm atf_pass , +.Nm atf_fail +or +.Nm atf_skip . +These three functions terminate the execution of the test case immediately. +The cleanup routine will be processed afterwards in a completely automated +way, regardless of the test case's termination reason. +.Pp +.Nm atf_pass +does not take any parameters. +.Nm atf_fail +and +.Nm atf_skip +take a single string parameter that describes why the test case failed or +was skipped, respectively. +It is very important to provide a clear error message in both cases so that +the user can quickly know why the test did not pass. +.Ss Expectations +Everything explained in the previous section changes when the test case +expectations are redefined by the programmer. +.Pp +Each test case has an internal state called +.Sq expect +that describes what the test case expectations are at any point in time. +The value of this property can change during execution by any of: +.Bl -tag -width indent +.It Nm atf_expect_death Qo reason Qc Qo ... Qc +Expects the test case to exit prematurely regardless of the nature of the +exit. +.It Nm atf_expect_exit Qo exitcode Qc Qo reason Qc Qo ... Qc +Expects the test case to exit cleanly. +If +.Va exitcode +is not +.Sq -1 , +the runtime engine will validate that the exit code of the test case +matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Nm atf_expect_fail Qo reason Qc +Any failure raised in this mode is recorded, but such failures do not report +the test case as failed; instead, the test case finalizes cleanly and is +reported as +.Sq expected failure ; +this report includes the provided +.Fa reason +as part of it. +If no error is raised while running in this mode, then the test case is +reported as +.Sq failed . +.Pp +This mode is useful to reproduce actual known bugs in tests. +Whenever the developer fixes the bug later on, the test case will start +reporting a failure, signaling the developer that the test case must be +adjusted to the new conditions. +In this situation, it is useful, for example, to set +.Fa reason +as the bug number for tracking purposes. +.It Nm atf_expect_pass +This is the normal mode of execution. +In this mode, any failure is reported as such to the user and the test case +is marked as +.Sq failed . +.It Nm atf_expect_signal Qo signo Qc Qo reason Qc Qo ... Qc +Expects the test case to terminate due to the reception of a signal. +If +.Va signo +is not +.Sq -1 , +the runtime engine will validate that the signal that terminated the test +case matches the one provided in this call. +Otherwise, the exact value will be ignored. +.It Nm atf_expect_timeout Qo reason Qc Qo ... Qc +Expects the test case to execute for longer than its timeout. +.El +.Ss Helper functions for common checks +.Bl -tag -width indent +.It Nm atf_check Qo [options] Qc Qo command Qc Qo [args] Qc +Executes a command, performs checks on its exit code and its output, and +fails the test case if any of the checks is not successful. +This function is particularly useful in integration tests that verify the +correct functioning of a binary. +.Pp +Internally, this function is just a wrapper over the +.Xr atf-check 1 +tool (whose manual page provides all details on the calling syntax). +You should always use the +.Nm atf_check +function instead of the +.Xr atf-check 1 +tool in your scripts; the latter is not even in the path. +.It Nm atf_check_equal Qo expected_expression Qc Qo actual_expression Qc +This function takes two expressions, evaluates them and, if their +results differ, aborts the test case with an appropriate failure message. +The common style is to put the expected value in the first parameter and the +actual value in the second parameter. +.El +.Sh EXAMPLES +The following shows a complete test program with a single test case that +validates the addition operator: +.Bd -literal -offset indent +atf_test_case addition +addition_head() { + atf_set "descr" "Sample tests for the addition operator" +} +addition_body() { + atf_check_equal 0 $((0 + 0)) + atf_check_equal 1 $((0 + 1)) + atf_check_equal 1 $((1 + 0)) + + atf_check_equal 2 $((1 + 1)) + + atf_check_equal 300 $((100 + 200)) +} + +atf_init_test_cases() { + atf_add_test_case addition +} +.Ed +.Pp +This other example shows how to include a file with extra helper functions +in the test program: +.Bd -literal -offset indent +.Ns ... definition of test cases ... + +atf_init_test_cases() { + . $(atf_get_srcdir)/helper_functions.sh + + atf_add_test_case foo1 + atf_add_test_case foo2 +} +.Ed +.Pp +This example demonstrates the use of the very useful +.Nm atf_check +function: +.Bd -literal -offset indent +# Check for silent output +atf_check -s exit:0 -o empty -e empty 'true' + +# Check for silent output and failure +atf_check -s exit:1 -o empty -e empty 'false' + +# Check for known stdout and silent stderr +echo foo >expout +atf_check -s exit:0 -o file:expout -e empty 'echo foo' + +# Generate a file for later inspection +atf_check -s exit:0 -o save:stdout -e empty 'ls' +grep foo ls || atf_fail "foo file not found in listing" + +# Or just do the match along the way +atf_check -s exit:0 -o match:"^foo$" -e empty 'ls' +.Ed +.Sh SEE ALSO +.Xr atf-check 1 , +.Xr atf-sh 1 , +.Xr atf-test-program 1 , +.Xr atf-test-case 4 Property changes on: head/contrib/atf/atf-sh/atf-sh.3 ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/contrib/atf/atf-sh/atf-sh.cpp =================================================================== --- head/contrib/atf/atf-sh/atf-sh.cpp (revision 273928) +++ head/contrib/atf/atf-sh/atf-sh.cpp (revision 273929) @@ -1,156 +1,185 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2010 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// extern "C" { #include } #include #include #include #include -#include "atf-c++/config.hpp" - #include "atf-c++/detail/application.hpp" +#include "atf-c++/detail/env.hpp" #include "atf-c++/detail/fs.hpp" #include "atf-c++/detail/sanity.hpp" // ------------------------------------------------------------------------ // Auxiliary functions. // ------------------------------------------------------------------------ namespace { static std::string fix_plain_name(const char *filename) { const atf::fs::path filepath(filename); if (filepath.branch_path().str() == ".") return std::string("./") + filename; else return std::string(filename); } static std::string* construct_script(const char* filename) { - const std::string libexecdir = atf::config::get("atf_libexecdir"); - const std::string pkgdatadir = atf::config::get("atf_pkgdatadir"); - const std::string shell = atf::config::get("atf_shell"); + const std::string libexecdir = atf::env::get( + "ATF_LIBEXECDIR", ATF_LIBEXECDIR); + const std::string pkgdatadir = atf::env::get( + "ATF_PKGDATADIR", ATF_PKGDATADIR); + const std::string shell = atf::env::get("ATF_SHELL", ATF_SHELL); std::string* command = new std::string(); command->reserve(512); (*command) += ("Atf_Check='" + libexecdir + "/atf-check' ; " + "Atf_Shell='" + shell + "' ; " + ". " + pkgdatadir + "/libatf-sh.subr ; " + ". " + fix_plain_name(filename) + " ; " + "main \"${@}\""); return command; } static const char** construct_argv(const std::string& shell, const int interpreter_argc, const char* const* interpreter_argv) { PRE(interpreter_argc >= 1); PRE(interpreter_argv[0] != NULL); const std::string* script = construct_script(interpreter_argv[0]); const int count = 4 + (interpreter_argc - 1) + 1; const char** argv = new const char*[count]; argv[0] = shell.c_str(); argv[1] = "-c"; argv[2] = script->c_str(); argv[3] = interpreter_argv[0]; for (int i = 1; i < interpreter_argc; i++) argv[4 + i - 1] = interpreter_argv[i]; argv[count - 1] = NULL; return argv; } } // anonymous namespace // ------------------------------------------------------------------------ // The "atf_sh" class. // ------------------------------------------------------------------------ class atf_sh : public atf::application::app { static const char* m_description; + atf::fs::path m_shell; + + options_set specific_options(void) const; + void process_option(int, const char*); + public: atf_sh(void); int main(void); }; const char* atf_sh::m_description = "atf-sh is a shell interpreter that extends the functionality of the " "system sh(1) with the atf-sh library."; atf_sh::atf_sh(void) : - app(m_description, "atf-sh(1)") + app(m_description, "atf-sh(1)"), + m_shell(atf::fs::path(atf::env::get("ATF_SHELL", ATF_SHELL))) { } +atf_sh::options_set +atf_sh::specific_options(void) + const +{ + using atf::application::option; + options_set opts; + + INV(m_shell == atf::fs::path(atf::env::get("ATF_SHELL", ATF_SHELL))); + opts.insert(option('s', "shell", "Path to the shell interpreter to use; " + "default: " + m_shell.str())); + + return opts; +} + +void +atf_sh::process_option(int ch, const char* arg) +{ + switch (ch) { + case 's': + m_shell = atf::fs::path(arg); + break; + + default: + UNREACHABLE; + } +} + int atf_sh::main(void) { if (m_argc < 1) throw atf::application::usage_error("No test program provided"); const atf::fs::path script(m_argv[0]); if (!atf::fs::exists(script)) throw std::runtime_error("The test program '" + script.str() + "' " "does not exist"); - const std::string shell = atf::config::get("atf_shell"); - const char** argv = construct_argv(shell, m_argc, m_argv); + const char** argv = construct_argv(m_shell.str(), m_argc, m_argv); // Don't bother keeping track of the memory allocated by construct_argv: // we are going to exec or die immediately. - const int ret = execv(shell.c_str(), const_cast< char** >(argv)); + const int ret = execv(m_shell.c_str(), const_cast< char** >(argv)); INV(ret == -1); - std::cerr << "Failed to execute " << shell << ": " << std::strerror(errno) - << "\n"; + std::cerr << "Failed to execute " << m_shell.str() << ": " + << std::strerror(errno) << "\n"; return EXIT_FAILURE; } int main(int argc, char* const* argv) { return atf_sh().run(argc, argv); } Index: head/contrib/atf/atf-sh/atf_check_test.sh =================================================================== --- head/contrib/atf/atf-sh/atf_check_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/atf_check_test.sh (revision 273929) @@ -1,197 +1,193 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # TODO: Bring in the checks in the bootstrap testsuite for atf_check. atf_test_case info_ok info_ok_head() { atf_set "descr" "Verifies that atf_check prints an informative" \ "message even when the command is successful" } info_ok_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:0 -o save:stdout -e save:stderr -x \ "${h} atf_check_info_ok" grep 'Executing command.*true' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" atf_check -s eq:0 -o save:stdout -e save:stderr -x \ "${h} atf_check_info_fail" grep 'Executing command.*false' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" } atf_test_case expout_mismatch expout_mismatch_head() { atf_set "descr" "Verifies that atf_check prints a diff of the" \ "stdout and the expected stdout if the two do not" \ "match" } expout_mismatch_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:1 -o save:stdout -e save:stderr -x \ "${h} atf_check_expout_mismatch" grep 'Executing command.*echo bar' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" grep 'stdout does not match golden output' stderr >/dev/null || \ atf_fail "atf_check does not print the stdout header" grep 'stderr' stderr >/dev/null && \ atf_fail "atf_check prints the stderr header" grep '^-foo' stderr >/dev/null || \ atf_fail "atf_check does not print the stdout's diff" grep '^+bar' stderr >/dev/null || \ atf_fail "atf_check does not print the stdout's diff" } atf_test_case experr_mismatch experr_mismatch_head() { atf_set "descr" "Verifies that atf_check prints a diff of the" \ "stderr and the expected stderr if the two do not" \ "match" } experr_mismatch_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:1 -o save:stdout -e save:stderr -x \ "${h} atf_check_experr_mismatch" grep 'Executing command.*echo bar' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" grep 'stdout' stderr >/dev/null && \ atf_fail "atf_check prints the stdout header" grep 'stderr does not match golden output' stderr >/dev/null || \ atf_fail "atf_check does not print the stderr header" grep '^-foo' stderr >/dev/null || \ atf_fail "atf_check does not print the stderr's diff" grep '^+bar' stderr >/dev/null || \ atf_fail "atf_check does not print the stderr's diff" } atf_test_case null_stdout null_stdout_head() { atf_set "descr" "Verifies that atf_check prints a the stdout it got" \ "when it was supposed to be null" } null_stdout_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:1 -o save:stdout -e save:stderr -x \ "${h} atf_check_null_stdout" grep 'Executing command.*echo.*These.*contents' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" grep 'stdout not empty' stderr >/dev/null || \ atf_fail "atf_check does not print the stdout header" grep 'stderr' stderr >/dev/null && \ atf_fail "atf_check prints the stderr header" grep 'These are the contents' stderr >/dev/null || \ atf_fail "atf_check does not print stdout's contents" } atf_test_case null_stderr null_stderr_head() { atf_set "descr" "Verifies that atf_check prints a the stderr it got" \ "when it was supposed to be null" } null_stderr_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:1 -o save:stdout -e save:stderr -x \ "${h} atf_check_null_stderr" grep 'Executing command.*echo.*These.*contents' stdout >/dev/null || \ atf_fail "atf_check does not print an informative message" grep 'stdout' stderr >/dev/null && \ atf_fail "atf_check prints the stdout header" grep 'stderr not empty' stderr >/dev/null || \ atf_fail "atf_check does not print the stderr header" grep 'These are the contents' stderr >/dev/null || \ atf_fail "atf_check does not print stderr's contents" } atf_test_case equal equal_head() { atf_set "descr" "Verifies that atf_check_equal works" } equal_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:0 -o ignore -e ignore -x "${h} atf_check_equal_ok" atf_check -s eq:1 -o ignore -e ignore -x \ "${h} -r resfile atf_check_equal_fail" atf_check -s eq:0 -o ignore -e empty grep '^failed: a != b (a != b)$' \ resfile atf_check -s eq:0 -o ignore -e ignore -x "${h} atf_check_equal_eval_ok" atf_check -s eq:1 -o ignore -e ignore -x \ "${h} -r resfile atf_check_equal_eval_fail" atf_check -s eq:0 -o ignore -e empty \ grep '^failed: \${x} != \${y} (a != b)$' resfile } atf_test_case flush_stdout_on_timeout flush_stdout_on_timeout_body() { "$(atf_get_srcdir)/misc_helpers" -s "$(atf_get_srcdir)" atf_check_timeout \ >out 2>err & pid="${!}" sleep 1 kill "${pid}" grep 'Executing command.*true' out \ || atf_fail 'First command not in output' grep 'Executing command.*sleep 42' out \ || atf_fail 'Second command not in output' } atf_init_test_cases() { atf_add_test_case info_ok atf_add_test_case expout_mismatch atf_add_test_case experr_mismatch atf_add_test_case null_stdout atf_add_test_case null_stderr atf_add_test_case equal atf_add_test_case flush_stdout_on_timeout } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/config_test.sh =================================================================== --- head/contrib/atf/atf-sh/config_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/config_test.sh (revision 273929) @@ -1,83 +1,79 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case has has_head() { atf_set "descr" "Verifies that atf_config_has works" } has_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:0 -o match:'foo not found' -e ignore -x \ "TEST_VARIABLE=foo ${h} config_has" atf_check -s eq:0 -o match:'foo found' -e ignore -x \ "TEST_VARIABLE=foo ${h} -v foo=bar config_has" echo "Checking for deprecated variables" atf_check -s eq:0 -o match:'workdir not found' -e ignore -x \ "TEST_VARIABLE=workdir ${h} config_has" } atf_test_case get get_head() { atf_set "descr" "Verifies that atf_config_get works" } get_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" echo "Querying an undefined variable" ( atf_config_get "undefined" ) >out 2>err && \ atf_fail "Getting an undefined variable succeeded" grep 'not find' err || \ atf_fail "Getting an undefined variable did not report an error" echo "Querying an undefined variable using a default value" v=$(atf_config_get "undefined" "the default value") [ "${v}" = "the default value" ] || \ atf_fail "Default value does not work" atf_check -s eq:0 -o match:'foo = bar' -e ignore -x \ "TEST_VARIABLE=foo ${h} -v foo=bar config_get" atf_check -s eq:0 -o match:'foo = baz' -e ignore -x \ "TEST_VARIABLE=foo ${h} -v foo=baz config_get" } atf_init_test_cases() { atf_add_test_case has atf_add_test_case get } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/integration_test.sh =================================================================== --- head/contrib/atf/atf-sh/integration_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/integration_test.sh (revision 273929) @@ -1,91 +1,160 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2010 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# +: ${ATF_SH:="__ATF_SH__"} + create_test_program() { - echo '#! /usr/bin/env atf-sh' >"${1}" - cat >>"${1}" - chmod +x "${1}" + local output="${1}"; shift + echo "#! ${ATF_SH} ${*}" >"${output}" + cat >>"${output}" + chmod +x "${output}" } atf_test_case no_args no_args_body() { cat >experr <experr <>>\${0}<<<" while test \${#} -gt 0; do echo ">>>\${1}<<<" shift done true } EOF cat >expout <>>./tp<<< >>> a b <<< >>>foo<<< EOF atf_check -s eq:0 -o file:expout -e empty ./tp ' a b ' foo cat >expout <>>tp<<< >>> hello bye <<< >>>foo bar<<< EOF - atf_check -s eq:0 -o file:expout -e empty atf-sh tp ' hello bye ' 'foo bar' + atf_check -s eq:0 -o file:expout -e empty "${ATF_SH}" tp \ + ' hello bye ' 'foo bar' } +atf_test_case custom_shell__command_line +custom_shell__command_line_body() +{ + cat >expout <custom-shell <expout <custom-shell <custom-shell <tp <_head and _body, and optionally by # a _cleanup function. # atf_add_test_case() { Test_Cases="${Test_Cases} ${1}" } # # atf_check cmd expcode expout experr # # Executes atf-check with given arguments and automatically calls # atf_fail in case of failure. # atf_check() { ${Atf_Check} "${@}" || \ atf_fail "atf-check failed; see the output of the test for details" } # -# atf_check_equal expr1 expr2 +# atf_check_equal expected_expression actual_expression # -# Checks that expr1's value matches expr2's and, if not, raises an -# error. Ideally expr1 and expr2 should be provided quoted (not -# expanded) so that the error message is helpful; otherwise it will -# only show the values, not the expressions themselves. +# Checks that expected_expression's value matches actual_expression's +# and, if not, raises an error. Ideally expected_expression and +# actual_expression should be provided quoted (not expanded) so that +# the error message is helpful; otherwise it will only show the values, +# not the expressions themselves. # atf_check_equal() { eval _val1=\"${1}\" eval _val2=\"${2}\" test "${_val1}" = "${_val2}" || \ atf_fail "${1} != ${2} (${_val1} != ${_val2})" } # # atf_config_get varname [defvalue] # # Prints the value of a configuration variable. If it is not # defined, prints the given default value. # atf_config_get() { _varname="__tc_config_var_$(_atf_normalize ${1})" if [ ${#} -eq 1 ]; then eval _value=\"\${${_varname}-__unset__}\" [ "${_value}" = __unset__ ] && \ _atf_error 1 "Could not find configuration variable \`${1}'" echo ${_value} elif [ ${#} -eq 2 ]; then eval echo \${${_varname}-${2}} else _atf_error 1 "Incorrect number of parameters for atf_config_get" fi } # # atf_config_has varname # # Returns a boolean indicating if the given configuration variable is # defined or not. # atf_config_has() { _varname="__tc_config_var_$(_atf_normalize ${1})" eval _value=\"\${${_varname}-__unset__}\" [ "${_value}" != __unset__ ] } # # atf_expect_death reason # # Sets the expectations to 'death'. # atf_expect_death() { _atf_validate_expect Expect=death _atf_create_resfile "expected_death: ${*}" } # # atf_expect_timeout reason # # Sets the expectations to 'timeout'. # atf_expect_timeout() { _atf_validate_expect Expect=timeout _atf_create_resfile "expected_timeout: ${*}" } # # atf_expect_exit exitcode reason # # Sets the expectations to 'exit'. # atf_expect_exit() { _exitcode="${1}"; shift _atf_validate_expect Expect=exit if [ "${_exitcode}" = "-1" ]; then _atf_create_resfile "expected_exit: ${*}" else _atf_create_resfile "expected_exit(${_exitcode}): ${*}" fi } # # atf_expect_fail reason # # Sets the expectations to 'fail'. # atf_expect_fail() { _atf_validate_expect Expect=fail Expect_Reason="${*}" } # # atf_expect_pass # # Sets the expectations to 'pass'. # atf_expect_pass() { _atf_validate_expect Expect=pass Expect_Reason= } # # atf_expect_signal signo reason # # Sets the expectations to 'signal'. # atf_expect_signal() { _signo="${1}"; shift _atf_validate_expect Expect=signal if [ "${_signo}" = "-1" ]; then _atf_create_resfile "expected_signal: ${*}" else _atf_create_resfile "expected_signal(${_signo}): ${*}" fi } # # atf_expected_failure msg1 [.. msgN] # # Makes the test case report an expected failure with the given error # message. Multiple words can be provided, which are concatenated with # a single blank space. # atf_expected_failure() { _atf_create_resfile "expected_failure: ${Expect_Reason}: ${*}" exit 0 } # # atf_fail msg1 [.. msgN] # # Makes the test case fail with the given error message. Multiple # words can be provided, in which case they are joined by a single # blank space. # atf_fail() { case "${Expect}" in fail) atf_expected_failure "${@}" ;; pass) _atf_create_resfile "failed: ${*}" exit 1 ;; *) _atf_error 128 "Unreachable" ;; esac } # # atf_get varname # # Prints the value of a test case-specific variable. Given that one # should not get the value of non-existent variables, it is fine to # always use this function as 'val=$(atf_get var)'. # atf_get() { eval echo \${__tc_var_${Test_Case}_$(_atf_normalize ${1})} } # # atf_get_srcdir # # Prints the value of the test case's source directory. # atf_get_srcdir() { echo ${Source_Dir} } # # atf_pass # # Makes the test case pass. Shouldn't be used in general, as a test # case that does not explicitly fail is assumed to pass. # atf_pass() { case "${Expect}" in fail) Expect=pass atf_fail "Test case was expecting a failure but got a pass instead" ;; pass) _atf_create_resfile passed exit 0 ;; *) _atf_error 128 "Unreachable" ;; esac } # # atf_require_prog prog # # Checks that the given program name (either provided as an absolute # path or as a plain file name) can be found. If it is not available, # automatically skips the test case with an appropriate message. # # Relative paths are not allowed because the test case cannot predict # where it will be executed from. # atf_require_prog() { _prog= case ${1} in /*) _prog="${1}" [ -x ${_prog} ] || \ atf_skip "The required program ${1} could not be found" ;; */*) atf_fail "atf_require_prog does not accept relative path names \`${1}'" ;; *) _prog=$(_atf_find_in_path "${1}") [ -n "${_prog}" ] || \ atf_skip "The required program ${1} could not be found" \ "in the PATH" ;; esac } # # atf_set varname val1 [.. valN] # # Sets the test case's variable 'varname' to the specified values # which are concatenated using a single blank space. This function # is supposed to be called form the test case's head only. # atf_set() { ${Parsing_Head} || \ _atf_error 128 "atf_set called from the test case's body" Test_Case_Vars="${Test_Case_Vars} ${1}" _var=$(_atf_normalize ${1}); shift eval __tc_var_${Test_Case}_${_var}=\"\${*}\" } # # atf_skip msg1 [.. msgN] # # Skips the test case because of the reason provided. Multiple words # can be given, in which case they are joined by a single blank space. # atf_skip() { _atf_create_resfile "skipped: ${*}" exit 0 } # # atf_test_case tc-name cleanup # # Defines a new test case named tc-name. The name provided here must be # accompanied by two functions named after it: _head and # _body. If cleanup is set to 'cleanup', then this also expects # a _cleanup function to be defined. # atf_test_case() { eval "${1}_head() { :; }" eval "${1}_body() { atf_fail 'Test case not implemented'; }" if [ "${2}" = cleanup ]; then eval __has_cleanup_${1}=true eval "${1}_cleanup() { :; }" else eval "${1}_cleanup() { _atf_error 1 'Test case ${1} declared without a cleanup routine'; }" fi } # ------------------------------------------------------------------------ # PRIVATE INTERFACE # ------------------------------------------------------------------------ # # _atf_config_set varname val1 [.. valN] # # Sets the test case's private variable 'varname' to the specified # values which are concatenated using a single blank space. # _atf_config_set() { _var=$(_atf_normalize ${1}); shift eval __tc_config_var_${_var}=\"\${*}\" Config_Vars="${Config_Vars} __tc_config_var_${_var}" } # # _atf_config_set_str varname=val # # Sets the test case's private variable 'varname' to the specified # value. The parameter is of the form 'varname=val'. # _atf_config_set_from_str() { _oldifs=${IFS} IFS='=' set -- ${*} _var=${1} shift _val="${@}" IFS=${_oldifs} _atf_config_set "${_var}" "${_val}" } # # _atf_create_resfile contents # # Creates the results file. # _atf_create_resfile() { if [ -n "${Results_File}" ]; then echo "${*}" >"${Results_File}" || \ _atf_error 128 "Cannot create results file '${Results_File}'" else echo "${*}" fi } # # _atf_error error_code [msg1 [.. msgN]] # # Prints the given error message (which can be composed of multiple # arguments, in which case are joined by a single space) and exits # with the specified error code. # # This must not be used by test programs themselves (hence making # the function private) to indicate a test case's failure. They # have to use the atf_fail function. # _atf_error() { _error_code="${1}"; shift echo "${Prog_Name}: ERROR:" "$@" 1>&2 exit ${_error_code} } # # _atf_warning msg1 [.. msgN] # # Prints the given warning message (which can be composed of multiple # arguments, in which case are joined by a single space). # _atf_warning() { echo "${Prog_Name}: WARNING:" "$@" 1>&2 } # # _atf_find_in_path program # # Looks for a program in the path and prints the full path to it or # nothing if it could not be found. It also returns true in case of # success. # _atf_find_in_path() { _prog="${1}" _oldifs=${IFS} IFS=: for _dir in ${PATH} do if [ -x ${_dir}/${_prog} ]; then IFS=${_oldifs} echo ${_dir}/${_prog} return 0 fi done IFS=${_oldifs} return 1 } # # _atf_has_tc name # # Returns true if the given test case exists. # _atf_has_tc() { for _tc in ${Test_Cases}; do [ "${_tc}" != "${1}" ] || return 0 done return 1 } # # _atf_list_tcs # # Describes all test cases and prints the list to the standard output. # _atf_list_tcs() { echo 'Content-Type: application/X-atf-tp; version="1"' echo set -- ${Test_Cases} while [ ${#} -gt 0 ]; do _atf_parse_head ${1} echo "ident: $(atf_get ident)" for _var in ${Test_Case_Vars}; do [ "${_var}" != "ident" ] && echo "${_var}: $(atf_get ${_var})" done [ ${#} -gt 1 ] && echo shift done } # # _atf_normalize str # # Normalizes a string so that it is a valid shell variable name. # _atf_normalize() { echo ${1} | tr .- __ } # # _atf_parse_head tcname # # Evaluates a test case's head to gather its variables and prepares the # test program to run it. # _atf_parse_head() { Parsing_Head=true Test_Case="${1}" Test_Case_Vars= if _atf_has_cleanup "${1}"; then atf_set has.cleanup "true" fi ${1}_head atf_set ident "${1}" Parsing_Head=false } # # _atf_run_tc tc # # Runs the specified test case. Prints its exit status to the # standard output and returns a boolean indicating if the test was # successful or not. # _atf_run_tc() { case ${1} in *:*) _tcname=${1%%:*} _tcpart=${1#*:} if [ "${_tcpart}" != body -a "${_tcpart}" != cleanup ]; then _atf_syntax_error "Unknown test case part \`${_tcpart}'" fi ;; *) _tcname=${1} _tcpart=body ;; esac _atf_has_tc "${_tcname}" || _atf_syntax_error "Unknown test case \`${1}'" if [ "${__RUNNING_INSIDE_ATF_RUN}" != "internal-yes-value" ]; then - _atf_warning "Running test cases without atf-run(1) is unsupported" + _atf_warning "Running test cases outside of kyua(1) is unsupported" _atf_warning "No isolation nor timeout control is being applied;" \ "you may get unexpected failures; see atf-test-case(4)" fi _atf_parse_head ${_tcname} case ${_tcpart} in body) if ${_tcname}_body; then _atf_validate_expect _atf_create_resfile passed else Expect=pass atf_fail "Test case body returned a non-ok exit code, but" \ "this is not allowed" fi ;; cleanup) if _atf_has_cleanup "${_tcname}"; then ${_tcname}_cleanup || _atf_error 128 "The test case cleanup" \ "returned a non-ok exit code, but this is not allowed" fi ;; *) _atf_error 128 "Unknown test case part" ;; esac } # # _atf_syntax_error msg1 [.. msgN] # # Formats and prints a syntax error message and terminates the # program prematurely. # _atf_syntax_error() { echo "${Prog_Name}: ERROR: ${@}" 1>&2 echo "${Prog_Name}: See atf-test-program(1) for usage details." 1>&2 exit 1 } # # _atf_has_cleanup tc-name # # Returns a boolean indicating if the given test case has a cleanup # routine or not. # _atf_has_cleanup() { _found=true eval "[ x\"\${__has_cleanup_${1}}\" = xtrue ] || _found=false" [ "${_found}" = true ] } # # _atf_validate_expect # # Ensures that the current test case state is correct regarding the expect # status. # _atf_validate_expect() { case "${Expect}" in death) Expect=pass atf_fail "Test case was expected to terminate abruptly but it" \ "continued execution" ;; exit) Expect=pass atf_fail "Test case was expected to exit cleanly but it continued" \ "execution" ;; fail) Expect=pass atf_fail "Test case was expecting a failure but none were raised" ;; pass) ;; signal) Expect=pass atf_fail "Test case was expected to receive a termination signal" \ "but it continued execution" ;; timeout) Expect=pass atf_fail "Test case was expected to hang but it continued execution" ;; *) _atf_error 128 "Unreachable" ;; esac } # # _atf_warning [msg1 [.. msgN]] # # Prints the given warning message (which can be composed of multiple # arguments, in which case are joined by a single space). # # This must not be used by test programs themselves (hence making # the function private). # _atf_warning() { echo "${Prog_Name}: WARNING:" "$@" 1>&2 } # # main [options] test_case # # Test program's entry point. # main() { # Process command-line options first. _numargs=${#} _lflag=false while getopts :lr:s:v: arg; do case ${arg} in l) _lflag=true ;; r) Results_File=${OPTARG} ;; s) Source_Dir=${OPTARG} ;; v) _atf_config_set_from_str "${OPTARG}" ;; \?) _atf_syntax_error "Unknown option -${OPTARG}." # NOTREACHED ;; esac done shift `expr ${OPTIND} - 1` - # First of all, make sure that the source directory is correct. It - # doesn't matter if the user did not change it, because the default - # value may not work. (TODO: It possibly should, even though it is - # not a big deal because atf-run deals with this.) case ${Source_Dir} in /*) ;; *) Source_Dir=$(pwd)/${Source_Dir} ;; esac [ -f ${Source_Dir}/${Prog_Name} ] || \ _atf_error 1 "Cannot find the test program in the source" \ "directory \`${Source_Dir}'" # Call the test program's hook to register all available test cases. atf_init_test_cases # Run or list test cases. if `${_lflag}`; then if [ ${#} -gt 0 ]; then _atf_syntax_error "Cannot provide test case names with -l" fi _atf_list_tcs else if [ ${#} -eq 0 ]; then _atf_syntax_error "Must provide a test case name" elif [ ${#} -gt 1 ]; then _atf_syntax_error "Cannot provide more than one test case name" else _atf_run_tc "${1}" fi fi } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/misc_helpers.sh =================================================================== --- head/contrib/atf/atf-sh/misc_helpers.sh (revision 273928) +++ head/contrib/atf/atf-sh/misc_helpers.sh (revision 273929) @@ -1,309 +1,305 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # ------------------------------------------------------------------------- # Helper tests for "t_atf_check". # ------------------------------------------------------------------------- atf_test_case atf_check_info_ok atf_check_info_ok_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_info_ok_body() { atf_check -s eq:0 -o empty -e empty true } atf_test_case atf_check_info_fail atf_check_info_fail_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_info_fail_body() { # In Solaris, /usr/bin/false returns 255 rather than 1. Use the # built-in version for the check. atf_check -s eq:1 -o empty -e empty sh -c "false" } atf_test_case atf_check_expout_mismatch atf_check_expout_mismatch_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_expout_mismatch_body() { cat >expout <experr <&2' } atf_test_case atf_check_null_stdout atf_check_null_stdout_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_null_stdout_body() { atf_check -s eq:0 -o empty -e empty echo "These are the contents" } atf_test_case atf_check_null_stderr atf_check_null_stderr_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_null_stderr_body() { atf_check -s eq:0 -o empty -e empty -x 'echo "These are the contents" 1>&2' } atf_test_case atf_check_equal_ok atf_check_equal_ok_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_equal_ok_body() { atf_check_equal a a } atf_test_case atf_check_equal_fail atf_check_equal_fail_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_equal_fail_body() { atf_check_equal a b } atf_test_case atf_check_equal_eval_ok atf_check_equal_eval_ok_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_equal_eval_ok_body() { x=a y=a atf_check_equal '${x}' '${y}' } atf_test_case atf_check_equal_eval_fail atf_check_equal_eval_fail_head() { atf_set "descr" "Helper test case for the t_atf_check test program" } atf_check_equal_eval_fail_body() { x=a y=b atf_check_equal '${x}' '${y}' } atf_test_case atf_check_timeout atf_check_timeout_head() { atf_set "descr" "Helper test case for the t_atf_check test program" atf_set "timeout" 1 } atf_check_timeout_body() { atf_check true atf_check sleep 42 } # ------------------------------------------------------------------------- # Helper tests for "t_config". # ------------------------------------------------------------------------- atf_test_case config_get config_get_head() { atf_set "descr" "Helper test case for the t_config test program" } config_get_body() { if atf_config_has ${TEST_VARIABLE}; then echo "${TEST_VARIABLE} = $(atf_config_get ${TEST_VARIABLE})" fi } atf_test_case config_has config_has_head() { atf_set "descr" "Helper test case for the t_config test program" } config_has_body() { if atf_config_has ${TEST_VARIABLE}; then echo "${TEST_VARIABLE} found" else echo "${TEST_VARIABLE} not found" fi } # ------------------------------------------------------------------------- # Helper tests for "t_normalize". # ------------------------------------------------------------------------- atf_test_case normalize normalize_head() { atf_set "descr" "Helper test case for the t_normalize test program" atf_set "a.b" "test value 1" atf_set "c-d" "test value 2" } normalize_body() { echo "a.b: $(atf_get a.b)" echo "c-d: $(atf_get c-d)" } # ------------------------------------------------------------------------- # Helper tests for "t_tc". # ------------------------------------------------------------------------- atf_test_case tc_pass_true tc_pass_true_head() { atf_set "descr" "Helper test case for the t_tc test program" } tc_pass_true_body() { true } atf_test_case tc_pass_false tc_pass_false_head() { atf_set "descr" "Helper test case for the t_tc test program" } tc_pass_false_body() { false } atf_test_case tc_pass_return_error tc_pass_return_error_head() { atf_set "descr" "Helper test case for the t_tc test program" } tc_pass_return_error_body() { return 1 } atf_test_case tc_fail tc_fail_head() { atf_set "descr" "Helper test case for the t_tc test program" } tc_fail_body() { echo "An error" 1>&2 exit 1 } atf_test_case tc_missing_body tc_missing_body_head() { atf_set "descr" "Helper test case for the t_tc test program" } # ------------------------------------------------------------------------- # Helper tests for "t_tp". # ------------------------------------------------------------------------- atf_test_case tp_srcdir tp_srcdir_head() { atf_set "descr" "Helper test case for the t_tp test program" } tp_srcdir_body() { echo "Calling helper" helper_subr || atf_fail "Could not call helper subroutine" } # ------------------------------------------------------------------------- # Main. # ------------------------------------------------------------------------- atf_init_test_cases() { # Add helper tests for t_atf_check. atf_add_test_case atf_check_info_ok atf_add_test_case atf_check_info_fail atf_add_test_case atf_check_expout_mismatch atf_add_test_case atf_check_experr_mismatch atf_add_test_case atf_check_null_stdout atf_add_test_case atf_check_null_stderr atf_add_test_case atf_check_equal_ok atf_add_test_case atf_check_equal_fail atf_add_test_case atf_check_equal_eval_ok atf_add_test_case atf_check_equal_eval_fail atf_add_test_case atf_check_timeout # Add helper tests for t_config. atf_add_test_case config_get atf_add_test_case config_has # Add helper tests for t_normalize. atf_add_test_case normalize # Add helper tests for t_tc. atf_add_test_case tc_pass_true atf_add_test_case tc_pass_false atf_add_test_case tc_pass_return_error atf_add_test_case tc_fail atf_add_test_case tc_missing_body # Add helper tests for t_tp. [ -f $(atf_get_srcdir)/subrs ] && . $(atf_get_srcdir)/subrs atf_add_test_case tp_srcdir } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/normalize_test.sh =================================================================== --- head/contrib/atf/atf-sh/normalize_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/normalize_test.sh (revision 273929) @@ -1,48 +1,44 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case main main_head() { atf_set "descr" "Verifies that variable names with symbols not" \ "allowed as part of shell variable names work" } main_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:0 -o match:'a.b: test value 1' \ -o match:'c-d: test value 2' -e ignore ${h} normalize } atf_init_test_cases() { atf_add_test_case main } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/tc_test.sh =================================================================== --- head/contrib/atf/atf-sh/tc_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/tc_test.sh (revision 273929) @@ -1,64 +1,60 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case default_status default_status_head() { atf_set "descr" "Verifies that test cases get the correct default" \ "status if they did not provide any" } default_status_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:0 -o ignore -e ignore ${h} tc_pass_true atf_check -s eq:1 -o ignore -e ignore ${h} tc_pass_false atf_check -s eq:1 -o match:'failed:.*body.*non-ok exit code' -e ignore \ ${h} tc_pass_return_error atf_check -s eq:1 -o ignore -e match:'An error' ${h} tc_fail } atf_test_case missing_body missing_body_head() { atf_set "descr" "Verifies that test cases without a body are reported" \ "as failed" } missing_body_body() { h="$(atf_get_srcdir)/misc_helpers -s $(atf_get_srcdir)" atf_check -s eq:1 -o ignore -e ignore ${h} tc_missing_body } atf_init_test_cases() { atf_add_test_case default_status atf_add_test_case missing_body } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/atf-sh/tp_test.sh =================================================================== --- head/contrib/atf/atf-sh/tp_test.sh (revision 273928) +++ head/contrib/atf/atf-sh/tp_test.sh (revision 273929) @@ -1,56 +1,52 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case srcdir srcdir_head() { atf_set "descr" "Verifies that the source directory can be queried" \ "from the initialization function" } srcdir_body() { mkdir work atf_check -s eq:0 -o empty -e empty cp "$(atf_get_srcdir)/misc_helpers" work cat >work/subrs < header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if getcwd(NULL, 0) works */ +#define HAVE_GETCWD_DYN 1 + +/* Define to 1 if getopt allows a + sign for POSIX behavior */ +/* #undef HAVE_GNU_GETOPT */ + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if getopt has optreset */ +#define HAVE_OPTRESET 1 + +/* Define to 1 if you have the `putenv' function. */ +#define HAVE_PUTENV 1 + +/* Define to 1 if you have the `setenv' function. */ +#define HAVE_SETENV 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to 1 if you have the `unsetenv' function. */ +#define HAVE_UNSETENV 1 + +/* Define to 1 if vsnprintf is in std */ +/* #undef HAVE_VSNPRINTF_IN_STD */ + +/* Define to the sub-directory where libtool stores uninstalled libraries. */ +#define LT_OBJDIR ".libs/" + +/* Name of package */ +#define PACKAGE "atf" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "atf-discuss@googlegroups.com" + +/* Define to the copyright string applicable to this package. */ +#define PACKAGE_COPYRIGHT "Copyright (c) 2007-2012 The NetBSD Foundation, Inc." + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "Automated Testing Framework" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "Automated Testing Framework 0.21" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "atf" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "https://github.com/jmmv/atf/" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "0.21" + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Version number of package */ +#define VERSION "0.21" Index: head/contrib/atf/doc/atf-test-case.4 =================================================================== --- head/contrib/atf/doc/atf-test-case.4 (revision 273928) +++ head/contrib/atf/doc/atf-test-case.4 (revision 273929) @@ -1,314 +1,321 @@ -.\" -.\" Automated Testing Framework (atf) -.\" .\" Copyright (c) 2007 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND .\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY .\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE .\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER .\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" -.Dd March 2, 2014 +.Dd October 5, 2014 .Dt ATF-TEST-CASE 4 .Os .Sh NAME .Nm atf-test-case .Nd generic description of test cases .Sh DESCRIPTION A .Em test case is a piece of code that stress-tests a specific feature of the software. This feature is typically self-contained enough, either in the amount of code that implements it or in the general idea that describes it, to warrant its independent testing. Given this, test cases are very fine-grained, but they attempt to group similar smaller tests which are semantically related. .Pp A test case is defined by three components regardless of the language it is implemented in: a header, a body and a cleanup routine. The .Em header is, basically, a declarative piece of code that defines several properties to describe what the test case does and how it behaves. In other words: it defines the test case's .Em meta-data , further described in the .Sx Meta-data section. The .Em body is the test case itself. It executes all actions needed to reproduce the test, and checks for failures. This body is only executed if the abstract conditions specified by the header are met. The .Em cleanup routine is a piece of code always executed after the body, regardless of the exit status of the test case. It can be used to undo side-effects of the test case. Note that almost all side-effects of a test case are automatically cleaned up by the library; this is explained in more detail in the rest of this document. .Pp It is extremely important to keep the separation between a test case's header and body well-defined, because the header is .Em always parsed, whereas the body is only executed when the conditions defined in the header are met and when the user specifies that test case. .Pp At last, test cases are always contained into test programs. The test programs act as a front-end to them, providing a consistent interface to the user and several APIs to ease their implementation. .Ss Results Upon termination, a test case reports a status and, optionally, a textual reason describing why the test reported such status. The caller must ensure that the test case really performed the task that its status describes, as the test program may be bogus and therefore providing a misleading result (e.g. providing a result that indicates success but the error code of the program says otherwise). .Pp The possible exit status of a test case are one of the following: .Bl -tag -width expectedXfailureXX .It expected_death The test case expects to terminate abruptly. .It expected_exit The test case expects to exit cleanly. .It expected_failure The test case expects to exit with a controller fatal/non-fatal failure. If this happens, the test program exits with a success error code. .It expected_signal The test case expects to receive a signal that makes it terminate. .It expected_timeout The test case expects to execute for longer than its timeout. .It passed The test case was executed successfully. The test program exits with a success error code. .It skipped The test case could not be executed because some preconditions were not met. This is not a failure because it can typically be resolved by adjusting the system to meet the necessary conditions. This is always accompanied by a .Em reason , a message describing why the test was skipped. The test program exits with a success error code. .It failed An error appeared during the execution of the test case. This is always accompanied by a .Em reason , a message describing why the test failed. The test program exits with a failure error code. .El .Pp The usefulness of the .Sq expected_* results comes when writing test cases that verify known failures caused, in general, due to programming errors (aka bugs). Whenever the faulty condition that the .Sq expected_* result is trying to cover is fixed, then the test case will be reported as .Sq failed and the developer will have to adjust it to match its new condition. .Pp It is important to note that all .Sq expected_* results are only provided as a .Em hint to the caller; the caller must verify that the test case did actually terminate as the expected condition says. .Ss Input/output Test cases are free to print whatever they want to their .Xr stdout 4 and .Xr stderr 4 file descriptors. They are, in fact, encouraged to print status information as they execute to keep the user informed of their actions. This is specially important for long test cases. .Pp Test cases will log their results to an auxiliary file, which is then collected by the test program they are contained in. The developer need not care about this as long as he uses the correct APIs to implement the test cases. .Pp The standard input of the test cases is unconditionally connected to .Sq /dev/zero . .Ss Meta-data The following list describes all meta-data properties interpreted internally by ATF. You are free to define new properties in your test cases and use them as you wish, but non-standard properties must be prefixed by .Sq X- . .Bl -tag -width requireXmachineXX .It descr Type: textual. Required. .Pp A brief textual description of the test case's purpose. Will be shown to the user in reports. Also good for documentation purposes. .It has.cleanup Type: boolean. Optional. .Pp If set to true, specifies that the test case has a cleanup routine that has to be executed by the runtime engine during the cleanup phase of the execution. This property is automatically set by the framework when defining a test case with a cleanup routine, so it should never be set by hand. .It ident Type: textual. Required. .Pp The test case's identifier. Must be unique inside the test program and should be short but descriptive. .It require.arch Type: textual. Optional. .Pp A whitespace separated list of architectures that the test case can be run under without causing errors due to an architecture mismatch. .It require.config Type: textual. Optional. .Pp A whitespace separated list of configuration variables that must be defined to execute the test case. If any of the required variables is not defined, the test case is .Em skipped . +.It require.diskspace +Type: integer. +Optional. +Specifies the minimum amount of available disk space needed by the test. +The value can have a size suffix such as +.Sq K , +.Sq M , +.Sq G +or +.Sq T +to make the amount of bytes easier to type and read. .It require.files Type: textual. Optional. .Pp A whitespace separated list of files that must be present to execute the test case. The names of these files must be absolute paths. If any of the required files is not found, the test case is .Em skipped . .It require.machine Type: textual. Optional. .Pp A whitespace separated list of machine types that the test case can be run under without causing errors due to a machine type mismatch. .It require.memory Type: integer. Optional. Specifies the minimum amount of physical memory needed by the test. The value can have a size suffix such as .Sq K , .Sq M , .Sq G or .Sq T to make the amount of bytes easier to type and read. .It require.progs Type: textual. Optional. .Pp A whitespace separated list of programs that must be present to execute the test case. These can be given as plain names, in which case they are looked in the user's .Ev PATH , or as absolute paths. If any of the required programs is not found, the test case is .Em skipped . .It require.user Type: textual. Optional. .Pp The required privileges to execute the test case. Can be one of .Sq root or .Sq unprivileged . .Pp If the test case is running as a regular user and this property is .Sq root , the test case is .Em skipped . .Pp If the test case is running as root and this property is .Sq unprivileged , the runtime engine will automatically drop the privileges if the .Sq unprivileged-user configuration property is set; otherwise the test case is .Em skipped . .It timeout Type: integral. Optional; defaults to .Sq 300 . .Pp Specifies the maximum amount of time the test case can run. This is particularly useful because some tests can stall either because they are incorrectly coded or because they trigger an anomalous behavior of the program. It is not acceptable for these tests to stall the whole execution of the test program. .Pp Can optionally be set to zero, in which case the test case has no run-time limit. This is discouraged. .El .Ss Environment Every time a test case is executed, several environment variables are cleared or reseted to sane values to ensure they do not make the test fail due to unexpected conditions. These variables are: .Bl -tag -width LCXMESSAGESXX .It Ev HOME Set to the work directory's path. .It Ev LANG Undefined. .It Ev LC_ALL Undefined. .It Ev LC_COLLATE Undefined. .It Ev LC_CTYPE Undefined. .It Ev LC_MESSAGES Undefined. .It Ev LC_MONETARY Undefined. .It Ev LC_NUMERIC Undefined. .It Ev LC_TIME Undefined. .It Ev TZ Hardcoded to .Sq UTC . .El .Ss Work directories The test program always creates a temporary directory and switches to it before running the test case's body. This way the test case is free to modify its current directory as it wishes, and the runtime engine will be able to clean it up later on in a safe way, removing any traces of its execution from the system. To do so, the runtime engine will perform a recursive removal of the work directory without crossing mount points; if a mount point is found, the file system will be unmounted (if possible). .Ss File creation mode mask (umask) Test cases are always executed with a file creation mode mask (umask) of .Sq 0022 . The test case's code is free to change this during execution. .Sh SEE ALSO .Xr atf-test-program 1 Index: head/contrib/atf/doc/atf-test-program.1 =================================================================== --- head/contrib/atf/doc/atf-test-program.1 (revision 273928) +++ head/contrib/atf/doc/atf-test-program.1 (revision 273929) @@ -1,103 +1,99 @@ -.\" -.\" Automated Testing Framework (atf) -.\" .\" Copyright (c) 2007 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND .\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY .\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE .\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER .\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" .Dd March 2, 2014 .Dt ATF-TEST-PROGRAM 1 .Os .Sh NAME .Nm atf-test-program .Nd common interface to ATF test programs .Sh SYNOPSIS .Nm .Op Fl r Ar resfile .Op Fl s Ar srcdir .Op Fl v Ar var1=value1 Op .. Fl v Ar varN=valueN .Ar test_case .Nm .Fl l .Sh DESCRIPTION Test programs written using the ATF libraries all share a common user interface, which is what this manual page describes. .Em NOTE: There is no binary known as .Nm ; .Em what is described in this manual page is the command-line interface .Em exposed by the atf-c, atf-c++ and atf-sh bindings . .Pp In the first synopsis form, the test program will execute the provided test case and print its results to the standard output, unless otherwise stated by the .Fl r flag. Optionally, the test case name can be suffixed by .Sq :cleanup , in which case the cleanup routine of the test case will be executed instead of the test case body; see .Xr atf-test-case 4 . Note that the test case is .Em executed without isolation , so it can and probably will create and modify files in the current directory. To execute test cases in a controller manner, you need a runtime engine that understands the ATF interface. The recommended runtime engine is .Xr kyua 1 . You should only execute test cases by hand for debugging purposes. .Pp In the second synopsis form, the test program will list all available test cases alongside their meta-data properties in a format that is machine parseable. This list is processed by .Xr kyua 1 to know how to execute the test cases of a given test program. .Pp The following options are available: .Bl -tag -width XvXvarXvalueXX .It Fl l Lists available test cases alongside a brief description for each of them. .It Fl r Ar resfile Specifies the file that will receive the test case result. If not specified, the test case prints its results to stdout. If the result of a test case needs to be parsed by another program, you must use this option to redirect the result to a file and then read the resulting file from the other program. Note: .Em do not try to process the stdout of the test case because your program may break in the future. .It Fl s Ar srcdir The path to the directory where the test program is located. This is needed in all cases, except when the test program is being executed from the current directory. The test program will use this path to locate any helper data files or utilities. .It Fl v Ar var=value Sets the configuration variable .Ar var to the value .Ar value . .El .Sh SEE ALSO .Xr kyua 1 Index: head/contrib/atf/doc/atf.7.in =================================================================== --- head/contrib/atf/doc/atf.7.in (nonexistent) +++ head/contrib/atf/doc/atf.7.in (revision 273929) @@ -0,0 +1,120 @@ +.\" Copyright (c) 2007 The NetBSD Foundation, Inc. +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND +.\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +.\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.Dd September 14, 2014 +.Dt ATF 7 +.Os +.Sh NAME +.Nm ATF +.Nd introduction to the Automated Testing Framework +.Sh DESCRIPTION +The Automated Testing Framework +.Pf ( Nm ) +is a +.Em collection of libraries +to implement test programs in a variety of languages. +These libraries all offer similar functionality and any test program +written with them exposes a consistent user interface. +.Pp +Test programs using the +.Nm +libraries rely on a separate runtime engine to execute them in a +deterministic fashion. +The runtime engine isolates the test programs from the rest of the system +and ensures some common side-effects are cleaned up. +The runtime engine is also responsible for gathering the results of all +tests and composing reports. +The current runtime of choice is Kyua, described in +.Xr kyua 1 . +.Pp +If your operating systems distributes +.Nm , +it should also provide an introductory +.Xr tests 7 +manual page. +You are encouraged to read it now. +.Pp +The rest of this manual page serves as a cross-reference to all the other +documentation shipped with +.Nm . +.Ss Language bindings +.Bl -tag -width atfXtestXprogramXXXXX +.It Xr atf-c 3 +C programming interface. +.It Xr atf-c++ 3 +C++ programming interface. +.It Xr atf-sh 3 +.Xr sh 1 +programming interface. +.El +.Ss Miscellaneous pages +.Bl -tag -width atfXtestXprogramXXXXX +.It Xr atf-test-case 4 +Generic description of test cases, independent of the language they are +implemented in. +.It Xr atf-test-program 1 +Common interface provided by the test programs written using the +.Nm +libraries. +.El +.Sh SEE ALSO +.Xr kyua 1 , +.Xr tests 7 +.Sh HISTORY +.Nm +started as a Google Summer of Code 2007 project mentored by The NetBSD +Foundation. +Its original goal was to provide a testing framework for the +.Nx +operating system, but it grew as an independent project because the +framework itself did not need to be tied to a specific operating system. +.Pp +Originally, +.Nm +shipped the collection of libraries described in this manual page as well +as a runtime engine. +The runtime engine has since been replaced by Kyua and the old tools were +removed in +.Nm 0.20 , +which shipped in early 2014. +.Pp +As of late 2014, both +.Fx +and +.Nx +ship +.Nm +in their base systems and provide extensive test suites based on it. +.Pp +For more details on historical changes, refer to: +.Bd -literal -offset indent +.Pa __DOCDIR__/NEWS +.Ed +.Sh AUTHORS +For more details on the people that made +.Nm +possible, refer to: +.Bd -literal -offset indent +.Pa __DOCDIR__/AUTHORS +.Ed Property changes on: head/contrib/atf/doc/atf.7.in ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/contrib/atf/test-programs/c_helpers.c =================================================================== --- head/contrib/atf/test-programs/c_helpers.c (revision 273928) +++ head/contrib/atf/test-programs/c_helpers.c (revision 273929) @@ -1,508 +1,503 @@ -/* - * Automated Testing Framework (atf) - * - * Copyright (c) 2007 The NetBSD Foundation, Inc. +/* Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN - * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include #include #include #include #include #include #include #include #include -#include "atf-c/error.h" - #include "atf-c/detail/env.h" #include "atf-c/detail/fs.h" #include "atf-c/detail/test_helpers.h" #include "atf-c/detail/text.h" +#include "atf-c/error.h" /* --------------------------------------------------------------------- * Auxiliary functions. * --------------------------------------------------------------------- */ static void safe_remove(const char* path) { if (unlink(path) == -1) atf_tc_fail("unlink(2) of %s failed", path); } static void touch(const char *path) { int fd; fd = open(path, O_WRONLY | O_TRUNC | O_CREAT, 0644); if (fd == -1) atf_tc_fail("Could not create file %s", path); close(fd); } /* --------------------------------------------------------------------- * Helper tests for "t_cleanup". * --------------------------------------------------------------------- */ ATF_TC_WITH_CLEANUP(cleanup_pass); ATF_TC_HEAD(cleanup_pass, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_cleanup test " "program"); } ATF_TC_BODY(cleanup_pass, tc) { touch(atf_tc_get_config_var(tc, "tmpfile")); } ATF_TC_CLEANUP(cleanup_pass, tc) { if (atf_tc_get_config_var_as_bool(tc, "cleanup")) safe_remove(atf_tc_get_config_var(tc, "tmpfile")); } ATF_TC_WITH_CLEANUP(cleanup_fail); ATF_TC_HEAD(cleanup_fail, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_cleanup test " "program"); } ATF_TC_BODY(cleanup_fail, tc) { touch(atf_tc_get_config_var(tc, "tmpfile")); atf_tc_fail("On purpose"); } ATF_TC_CLEANUP(cleanup_fail, tc) { if (atf_tc_get_config_var_as_bool(tc, "cleanup")) safe_remove(atf_tc_get_config_var(tc, "tmpfile")); } ATF_TC_WITH_CLEANUP(cleanup_skip); ATF_TC_HEAD(cleanup_skip, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_cleanup test " "program"); } ATF_TC_BODY(cleanup_skip, tc) { touch(atf_tc_get_config_var(tc, "tmpfile")); atf_tc_skip("On purpose"); } ATF_TC_CLEANUP(cleanup_skip, tc) { if (atf_tc_get_config_var_as_bool(tc, "cleanup")) safe_remove(atf_tc_get_config_var(tc, "tmpfile")); } ATF_TC_WITH_CLEANUP(cleanup_curdir); ATF_TC_HEAD(cleanup_curdir, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_cleanup test " "program"); } ATF_TC_BODY(cleanup_curdir, tc) { FILE *f; f = fopen("oldvalue", "w"); if (f == NULL) atf_tc_fail("Failed to create oldvalue file"); fprintf(f, "1234"); fclose(f); } ATF_TC_CLEANUP(cleanup_curdir, tc) { FILE *f; f = fopen("oldvalue", "r"); if (f != NULL) { int i; if (fscanf(f, "%d", &i) != 1) fprintf(stderr, "Failed to read old value\n"); else printf("Old value: %d", i); fclose(f); } } ATF_TC_WITH_CLEANUP(cleanup_sigterm); ATF_TC_HEAD(cleanup_sigterm, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_cleanup test " "program"); } ATF_TC_BODY(cleanup_sigterm, tc) { char *nofile; touch(atf_tc_get_config_var(tc, "tmpfile")); kill(getpid(), SIGTERM); RE(atf_text_format(&nofile, "%s.no", atf_tc_get_config_var(tc, "tmpfile"))); touch(nofile); free(nofile); } ATF_TC_CLEANUP(cleanup_sigterm, tc) { safe_remove(atf_tc_get_config_var(tc, "tmpfile")); } /* --------------------------------------------------------------------- * Helper tests for "t_config". * --------------------------------------------------------------------- */ ATF_TC(config_unset); ATF_TC_HEAD(config_unset, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_config test " "program"); } ATF_TC_BODY(config_unset, tc) { ATF_REQUIRE(!atf_tc_has_config_var(tc, "test")); } ATF_TC(config_empty); ATF_TC_HEAD(config_empty, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_config test " "program"); } ATF_TC_BODY(config_empty, tc) { ATF_REQUIRE(atf_tc_has_config_var(tc, "test")); ATF_REQUIRE(strlen(atf_tc_get_config_var(tc, "test")) == 0); } ATF_TC(config_value); ATF_TC_HEAD(config_value, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_config test " "program"); } ATF_TC_BODY(config_value, tc) { ATF_REQUIRE(atf_tc_has_config_var(tc, "test")); ATF_REQUIRE(strcmp(atf_tc_get_config_var(tc, "test"), "foo") == 0); } ATF_TC(config_multi_value); ATF_TC_HEAD(config_multi_value, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_config test " "program"); } ATF_TC_BODY(config_multi_value, tc) { ATF_REQUIRE(atf_tc_has_config_var(tc, "test")); ATF_REQUIRE(strcmp(atf_tc_get_config_var(tc, "test"), "foo bar") == 0); } /* --------------------------------------------------------------------- * Helper tests for "t_expect". * --------------------------------------------------------------------- */ ATF_TC_WITHOUT_HEAD(expect_pass_and_pass); ATF_TC_BODY(expect_pass_and_pass, tc) { atf_tc_expect_pass(); } ATF_TC_WITHOUT_HEAD(expect_pass_but_fail_requirement); ATF_TC_BODY(expect_pass_but_fail_requirement, tc) { atf_tc_expect_pass(); atf_tc_fail("Some reason"); } ATF_TC_WITHOUT_HEAD(expect_pass_but_fail_check); ATF_TC_BODY(expect_pass_but_fail_check, tc) { atf_tc_expect_pass(); atf_tc_fail_nonfatal("Some reason"); } ATF_TC_WITHOUT_HEAD(expect_fail_and_fail_requirement); ATF_TC_BODY(expect_fail_and_fail_requirement, tc) { atf_tc_expect_fail("Fail %s", "reason"); atf_tc_fail("The failure"); atf_tc_expect_pass(); } ATF_TC_WITHOUT_HEAD(expect_fail_and_fail_check); ATF_TC_BODY(expect_fail_and_fail_check, tc) { atf_tc_expect_fail("Fail first"); atf_tc_fail_nonfatal("abc"); atf_tc_expect_pass(); atf_tc_expect_fail("And fail again"); atf_tc_fail_nonfatal("def"); atf_tc_expect_pass(); } ATF_TC_WITHOUT_HEAD(expect_fail_but_pass); ATF_TC_BODY(expect_fail_but_pass, tc) { atf_tc_expect_fail("Fail first"); atf_tc_fail_nonfatal("abc"); atf_tc_expect_pass(); atf_tc_expect_fail("Will not fail"); atf_tc_expect_pass(); atf_tc_expect_fail("And fail again"); atf_tc_fail_nonfatal("def"); atf_tc_expect_pass(); } ATF_TC_WITHOUT_HEAD(expect_exit_any_and_exit); ATF_TC_BODY(expect_exit_any_and_exit, tc) { atf_tc_expect_exit(-1, "Call will exit"); exit(EXIT_SUCCESS); } ATF_TC_WITHOUT_HEAD(expect_exit_code_and_exit); ATF_TC_BODY(expect_exit_code_and_exit, tc) { atf_tc_expect_exit(123, "Call will exit"); exit(123); } ATF_TC_WITHOUT_HEAD(expect_exit_but_pass); ATF_TC_BODY(expect_exit_but_pass, tc) { atf_tc_expect_exit(-1, "Call won't exit"); } ATF_TC_WITHOUT_HEAD(expect_signal_any_and_signal); ATF_TC_BODY(expect_signal_any_and_signal, tc) { atf_tc_expect_signal(-1, "Call will signal"); kill(getpid(), SIGKILL); } ATF_TC_WITHOUT_HEAD(expect_signal_no_and_signal); ATF_TC_BODY(expect_signal_no_and_signal, tc) { atf_tc_expect_signal(SIGHUP, "Call will signal"); kill(getpid(), SIGHUP); } ATF_TC_WITHOUT_HEAD(expect_signal_but_pass); ATF_TC_BODY(expect_signal_but_pass, tc) { atf_tc_expect_signal(-1, "Call won't signal"); } ATF_TC_WITHOUT_HEAD(expect_death_and_exit); ATF_TC_BODY(expect_death_and_exit, tc) { atf_tc_expect_death("Exit case"); exit(123); } ATF_TC_WITHOUT_HEAD(expect_death_and_signal); ATF_TC_BODY(expect_death_and_signal, tc) { atf_tc_expect_death("Signal case"); kill(getpid(), SIGKILL); } ATF_TC_WITHOUT_HEAD(expect_death_but_pass); ATF_TC_BODY(expect_death_but_pass, tc) { atf_tc_expect_death("Call won't die"); } ATF_TC(expect_timeout_and_hang); ATF_TC_HEAD(expect_timeout_and_hang, tc) { atf_tc_set_md_var(tc, "timeout", "1"); } ATF_TC_BODY(expect_timeout_and_hang, tc) { atf_tc_expect_timeout("Will overrun"); sleep(5); } ATF_TC(expect_timeout_but_pass); ATF_TC_HEAD(expect_timeout_but_pass, tc) { atf_tc_set_md_var(tc, "timeout", "1"); } ATF_TC_BODY(expect_timeout_but_pass, tc) { atf_tc_expect_timeout("Will just exit"); } /* --------------------------------------------------------------------- * Helper tests for "t_meta_data". * --------------------------------------------------------------------- */ ATF_TC_WITHOUT_HEAD(metadata_no_descr); ATF_TC_BODY(metadata_no_descr, tc) { } ATF_TC_WITHOUT_HEAD(metadata_no_head); ATF_TC_BODY(metadata_no_head, tc) { } /* --------------------------------------------------------------------- * Helper tests for "t_srcdir". * --------------------------------------------------------------------- */ ATF_TC(srcdir_exists); ATF_TC_HEAD(srcdir_exists, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_srcdir test " "program"); } ATF_TC_BODY(srcdir_exists, tc) { atf_fs_path_t p; bool b; RE(atf_fs_path_init_fmt(&p, "%s/datafile", atf_tc_get_config_var(tc, "srcdir"))); RE(atf_fs_exists(&p, &b)); atf_fs_path_fini(&p); if (!b) atf_tc_fail("Cannot find datafile"); } /* --------------------------------------------------------------------- * Helper tests for "t_result". * --------------------------------------------------------------------- */ ATF_TC_WITHOUT_HEAD(result_pass); ATF_TC_BODY(result_pass, tc) { printf("msg\n"); } ATF_TC_WITHOUT_HEAD(result_fail); ATF_TC_BODY(result_fail, tc) { printf("msg\n"); atf_tc_fail("Failure reason"); } ATF_TC_WITHOUT_HEAD(result_skip); ATF_TC_BODY(result_skip, tc) { printf("msg\n"); atf_tc_skip("Skipped reason"); } ATF_TC(result_newlines_fail); ATF_TC_HEAD(result_newlines_fail, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_result test " "program"); } ATF_TC_BODY(result_newlines_fail, tc) { atf_tc_fail("First line\nSecond line"); } ATF_TC(result_newlines_skip); ATF_TC_HEAD(result_newlines_skip, tc) { atf_tc_set_md_var(tc, "descr", "Helper test case for the t_result test " "program"); } ATF_TC_BODY(result_newlines_skip, tc) { atf_tc_skip("First line\nSecond line"); } /* --------------------------------------------------------------------- * Main. * --------------------------------------------------------------------- */ ATF_TP_ADD_TCS(tp) { /* Add helper tests for t_cleanup. */ ATF_TP_ADD_TC(tp, cleanup_pass); ATF_TP_ADD_TC(tp, cleanup_fail); ATF_TP_ADD_TC(tp, cleanup_skip); ATF_TP_ADD_TC(tp, cleanup_curdir); ATF_TP_ADD_TC(tp, cleanup_sigterm); /* Add helper tests for t_config. */ ATF_TP_ADD_TC(tp, config_unset); ATF_TP_ADD_TC(tp, config_empty); ATF_TP_ADD_TC(tp, config_value); ATF_TP_ADD_TC(tp, config_multi_value); /* Add helper tests for t_expect. */ ATF_TP_ADD_TC(tp, expect_pass_and_pass); ATF_TP_ADD_TC(tp, expect_pass_but_fail_requirement); ATF_TP_ADD_TC(tp, expect_pass_but_fail_check); ATF_TP_ADD_TC(tp, expect_fail_and_fail_requirement); ATF_TP_ADD_TC(tp, expect_fail_and_fail_check); ATF_TP_ADD_TC(tp, expect_fail_but_pass); ATF_TP_ADD_TC(tp, expect_exit_any_and_exit); ATF_TP_ADD_TC(tp, expect_exit_code_and_exit); ATF_TP_ADD_TC(tp, expect_exit_but_pass); ATF_TP_ADD_TC(tp, expect_signal_any_and_signal); ATF_TP_ADD_TC(tp, expect_signal_no_and_signal); ATF_TP_ADD_TC(tp, expect_signal_but_pass); ATF_TP_ADD_TC(tp, expect_death_and_exit); ATF_TP_ADD_TC(tp, expect_death_and_signal); ATF_TP_ADD_TC(tp, expect_death_but_pass); ATF_TP_ADD_TC(tp, expect_timeout_and_hang); ATF_TP_ADD_TC(tp, expect_timeout_but_pass); /* Add helper tests for t_meta_data. */ ATF_TP_ADD_TC(tp, metadata_no_descr); ATF_TP_ADD_TC(tp, metadata_no_head); /* Add helper tests for t_srcdir. */ ATF_TP_ADD_TC(tp, srcdir_exists); /* Add helper tests for t_result. */ ATF_TP_ADD_TC(tp, result_pass); ATF_TP_ADD_TC(tp, result_fail); ATF_TP_ADD_TC(tp, result_skip); ATF_TP_ADD_TC(tp, result_newlines_fail); ATF_TP_ADD_TC(tp, result_newlines_skip); return atf_no_error(); } Index: head/contrib/atf/test-programs/common.sh =================================================================== --- head/contrib/atf/test-programs/common.sh (revision 273928) +++ head/contrib/atf/test-programs/common.sh (revision 273929) @@ -1,43 +1,39 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2008 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# get_helpers() { srcdir=$(atf_get_srcdir) if [ ${#} -eq 0 ]; then set -- c_helpers cpp_helpers sh_helpers fi for h_name in "${@}"; do echo ${srcdir}/${h_name} done } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/config_test.sh =================================================================== --- head/contrib/atf/test-programs/config_test.sh (revision 273928) +++ head/contrib/atf/test-programs/config_test.sh (revision 273929) @@ -1,62 +1,58 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case vflag vflag_head() { atf_set "descr" "Tests that the -v flag works correctly to set" \ "configuration variables" } vflag_body() { for h in $(get_helpers); do atf_check -s eq:0 -o ignore -e ignore ${h} -s $(atf_get_srcdir) \ -r resfile config_unset atf_check -s eq:0 -o ignore -e empty grep 'passed' resfile atf_check -s eq:0 -o ignore -e ignore ${h} -s $(atf_get_srcdir) \ -r resfile -v 'test=' config_empty atf_check -s eq:0 -o ignore -e empty grep 'passed' resfile atf_check -s eq:0 -o ignore -e ignore ${h} -s $(atf_get_srcdir) \ -r resfile -v 'test=foo' config_value atf_check -s eq:0 -o ignore -e empty grep 'passed' resfile atf_check -s eq:0 -o ignore -e ignore -x ${h} -s $(atf_get_srcdir) \ -r resfile -v \'test=foo bar\' config_multi_value atf_check -s eq:0 -o ignore -e empty grep 'passed' resfile done } atf_init_test_cases() { atf_add_test_case vflag } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/cpp_helpers.cpp =================================================================== --- head/contrib/atf/test-programs/cpp_helpers.cpp (revision 273928) +++ head/contrib/atf/test-programs/cpp_helpers.cpp (revision 273929) @@ -1,359 +1,355 @@ -// -// Automated Testing Framework (atf) -// // Copyright (c) 2007 The NetBSD Foundation, Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND // CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE // GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN // IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// extern "C" { #include #include } #include #include #include #include #include "atf-c++/detail/fs.hpp" // ------------------------------------------------------------------------ // Helper tests for "t_config". // ------------------------------------------------------------------------ ATF_TEST_CASE(config_unset); ATF_TEST_CASE_HEAD(config_unset) { set_md_var("descr", "Helper test case for the t_config test program"); } ATF_TEST_CASE_BODY(config_unset) { ATF_REQUIRE(!has_config_var("test")); } ATF_TEST_CASE(config_empty); ATF_TEST_CASE_HEAD(config_empty) { set_md_var("descr", "Helper test case for the t_config test program"); } ATF_TEST_CASE_BODY(config_empty) { ATF_REQUIRE_EQ(get_config_var("test"), ""); } ATF_TEST_CASE(config_value); ATF_TEST_CASE_HEAD(config_value) { set_md_var("descr", "Helper test case for the t_config test program"); } ATF_TEST_CASE_BODY(config_value) { ATF_REQUIRE_EQ(get_config_var("test"), "foo"); } ATF_TEST_CASE(config_multi_value); ATF_TEST_CASE_HEAD(config_multi_value) { set_md_var("descr", "Helper test case for the t_config test program"); } ATF_TEST_CASE_BODY(config_multi_value) { ATF_REQUIRE_EQ(get_config_var("test"), "foo bar"); } // ------------------------------------------------------------------------ // Helper tests for "t_expect". // ------------------------------------------------------------------------ ATF_TEST_CASE_WITHOUT_HEAD(expect_pass_and_pass); ATF_TEST_CASE_BODY(expect_pass_and_pass) { expect_pass(); } ATF_TEST_CASE_WITHOUT_HEAD(expect_pass_but_fail_requirement); ATF_TEST_CASE_BODY(expect_pass_but_fail_requirement) { expect_pass(); fail("Some reason"); } ATF_TEST_CASE_WITHOUT_HEAD(expect_pass_but_fail_check); ATF_TEST_CASE_BODY(expect_pass_but_fail_check) { expect_pass(); fail_nonfatal("Some reason"); } ATF_TEST_CASE_WITHOUT_HEAD(expect_fail_and_fail_requirement); ATF_TEST_CASE_BODY(expect_fail_and_fail_requirement) { expect_fail("Fail reason"); fail("The failure"); expect_pass(); } ATF_TEST_CASE_WITHOUT_HEAD(expect_fail_and_fail_check); ATF_TEST_CASE_BODY(expect_fail_and_fail_check) { expect_fail("Fail first"); fail_nonfatal("abc"); expect_pass(); expect_fail("And fail again"); fail_nonfatal("def"); expect_pass(); } ATF_TEST_CASE_WITHOUT_HEAD(expect_fail_but_pass); ATF_TEST_CASE_BODY(expect_fail_but_pass) { expect_fail("Fail first"); fail_nonfatal("abc"); expect_pass(); expect_fail("Will not fail"); expect_pass(); expect_fail("And fail again"); fail_nonfatal("def"); expect_pass(); } ATF_TEST_CASE_WITHOUT_HEAD(expect_exit_any_and_exit); ATF_TEST_CASE_BODY(expect_exit_any_and_exit) { expect_exit(-1, "Call will exit"); std::exit(EXIT_SUCCESS); } ATF_TEST_CASE_WITHOUT_HEAD(expect_exit_code_and_exit); ATF_TEST_CASE_BODY(expect_exit_code_and_exit) { expect_exit(123, "Call will exit"); std::exit(123); } ATF_TEST_CASE_WITHOUT_HEAD(expect_exit_but_pass); ATF_TEST_CASE_BODY(expect_exit_but_pass) { expect_exit(-1, "Call won't exit"); } ATF_TEST_CASE_WITHOUT_HEAD(expect_signal_any_and_signal); ATF_TEST_CASE_BODY(expect_signal_any_and_signal) { expect_signal(-1, "Call will signal"); ::kill(getpid(), SIGKILL); } ATF_TEST_CASE_WITHOUT_HEAD(expect_signal_no_and_signal); ATF_TEST_CASE_BODY(expect_signal_no_and_signal) { expect_signal(SIGHUP, "Call will signal"); ::kill(getpid(), SIGHUP); } ATF_TEST_CASE_WITHOUT_HEAD(expect_signal_but_pass); ATF_TEST_CASE_BODY(expect_signal_but_pass) { expect_signal(-1, "Call won't signal"); } ATF_TEST_CASE_WITHOUT_HEAD(expect_death_and_exit); ATF_TEST_CASE_BODY(expect_death_and_exit) { expect_death("Exit case"); std::exit(123); } ATF_TEST_CASE_WITHOUT_HEAD(expect_death_and_signal); ATF_TEST_CASE_BODY(expect_death_and_signal) { expect_death("Signal case"); kill(getpid(), SIGKILL); } ATF_TEST_CASE_WITHOUT_HEAD(expect_death_but_pass); ATF_TEST_CASE_BODY(expect_death_but_pass) { expect_death("Call won't die"); } ATF_TEST_CASE(expect_timeout_and_hang); ATF_TEST_CASE_HEAD(expect_timeout_and_hang) { set_md_var("timeout", "1"); } ATF_TEST_CASE_BODY(expect_timeout_and_hang) { expect_timeout("Will overrun"); ::sleep(5); } ATF_TEST_CASE(expect_timeout_but_pass); ATF_TEST_CASE_HEAD(expect_timeout_but_pass) { set_md_var("timeout", "1"); } ATF_TEST_CASE_BODY(expect_timeout_but_pass) { expect_timeout("Will just exit"); } // ------------------------------------------------------------------------ // Helper tests for "t_meta_data". // ------------------------------------------------------------------------ ATF_TEST_CASE(metadata_no_descr); ATF_TEST_CASE_HEAD(metadata_no_descr) { } ATF_TEST_CASE_BODY(metadata_no_descr) { } ATF_TEST_CASE_WITHOUT_HEAD(metadata_no_head); ATF_TEST_CASE_BODY(metadata_no_head) { } // ------------------------------------------------------------------------ // Helper tests for "t_srcdir". // ------------------------------------------------------------------------ ATF_TEST_CASE(srcdir_exists); ATF_TEST_CASE_HEAD(srcdir_exists) { set_md_var("descr", "Helper test case for the t_srcdir test program"); } ATF_TEST_CASE_BODY(srcdir_exists) { if (!atf::fs::exists(atf::fs::path(get_config_var("srcdir")) / "datafile")) ATF_FAIL("Cannot find datafile"); } // ------------------------------------------------------------------------ // Helper tests for "t_result". // ------------------------------------------------------------------------ ATF_TEST_CASE(result_pass); ATF_TEST_CASE_HEAD(result_pass) { } ATF_TEST_CASE_BODY(result_pass) { std::cout << "msg\n"; } ATF_TEST_CASE(result_fail); ATF_TEST_CASE_HEAD(result_fail) { } ATF_TEST_CASE_BODY(result_fail) { std::cout << "msg\n"; ATF_FAIL("Failure reason"); } ATF_TEST_CASE(result_skip); ATF_TEST_CASE_HEAD(result_skip) { } ATF_TEST_CASE_BODY(result_skip) { std::cout << "msg\n"; ATF_SKIP("Skipped reason"); } ATF_TEST_CASE(result_newlines_fail); ATF_TEST_CASE_HEAD(result_newlines_fail) { set_md_var("descr", "Helper test case for the t_result test program"); } ATF_TEST_CASE_BODY(result_newlines_fail) { ATF_FAIL("First line\nSecond line"); } ATF_TEST_CASE(result_newlines_skip); ATF_TEST_CASE_HEAD(result_newlines_skip) { set_md_var("descr", "Helper test case for the t_result test program"); } ATF_TEST_CASE_BODY(result_newlines_skip) { ATF_SKIP("First line\nSecond line"); } ATF_TEST_CASE(result_exception); ATF_TEST_CASE_HEAD(result_exception) { } ATF_TEST_CASE_BODY(result_exception) { throw std::runtime_error("This is unhandled"); } // ------------------------------------------------------------------------ // Main. // ------------------------------------------------------------------------ ATF_INIT_TEST_CASES(tcs) { // Add helper tests for t_config. ATF_ADD_TEST_CASE(tcs, config_unset); ATF_ADD_TEST_CASE(tcs, config_empty); ATF_ADD_TEST_CASE(tcs, config_value); ATF_ADD_TEST_CASE(tcs, config_multi_value); // Add helper tests for t_expect. ATF_ADD_TEST_CASE(tcs, expect_pass_and_pass); ATF_ADD_TEST_CASE(tcs, expect_pass_but_fail_requirement); ATF_ADD_TEST_CASE(tcs, expect_pass_but_fail_check); ATF_ADD_TEST_CASE(tcs, expect_fail_and_fail_requirement); ATF_ADD_TEST_CASE(tcs, expect_fail_and_fail_check); ATF_ADD_TEST_CASE(tcs, expect_fail_but_pass); ATF_ADD_TEST_CASE(tcs, expect_exit_any_and_exit); ATF_ADD_TEST_CASE(tcs, expect_exit_code_and_exit); ATF_ADD_TEST_CASE(tcs, expect_exit_but_pass); ATF_ADD_TEST_CASE(tcs, expect_signal_any_and_signal); ATF_ADD_TEST_CASE(tcs, expect_signal_no_and_signal); ATF_ADD_TEST_CASE(tcs, expect_signal_but_pass); ATF_ADD_TEST_CASE(tcs, expect_death_and_exit); ATF_ADD_TEST_CASE(tcs, expect_death_and_signal); ATF_ADD_TEST_CASE(tcs, expect_death_but_pass); ATF_ADD_TEST_CASE(tcs, expect_timeout_and_hang); ATF_ADD_TEST_CASE(tcs, expect_timeout_but_pass); // Add helper tests for t_meta_data. ATF_ADD_TEST_CASE(tcs, metadata_no_descr); ATF_ADD_TEST_CASE(tcs, metadata_no_head); // Add helper tests for t_srcdir. ATF_ADD_TEST_CASE(tcs, srcdir_exists); // Add helper tests for t_result. ATF_ADD_TEST_CASE(tcs, result_pass); ATF_ADD_TEST_CASE(tcs, result_fail); ATF_ADD_TEST_CASE(tcs, result_skip); ATF_ADD_TEST_CASE(tcs, result_newlines_fail); ATF_ADD_TEST_CASE(tcs, result_newlines_skip); ATF_ADD_TEST_CASE(tcs, result_exception); } Index: head/contrib/atf/test-programs/expect_test.sh =================================================================== --- head/contrib/atf/test-programs/expect_test.sh (revision 273928) +++ head/contrib/atf/test-programs/expect_test.sh (revision 273929) @@ -1,155 +1,151 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# check_result() { file="${1}"; shift atf_check -s eq:0 -o match:"${*}" -e empty cat "${file}" rm "${file}" } atf_test_case expect_pass expect_pass_body() { for h in $(get_helpers); do atf_check -s eq:0 -e ignore "${h}" -r result expect_pass_and_pass check_result result "passed" atf_check -s eq:1 -e ignore "${h}" -r result \ expect_pass_but_fail_requirement check_result result "failed: Some reason" # atf-sh does not support non-fatal failures yet; skip checks for # such conditions. case "${h}" in *sh_helpers*) continue ;; esac atf_check -s eq:1 -o empty -e match:"Some reason" \ "${h}" -r result expect_pass_but_fail_check check_result result "failed: 1 checks failed" done } atf_test_case expect_fail expect_fail_body() { for h in $(get_helpers c_helpers cpp_helpers); do atf_check -s eq:0 "${h}" -r result expect_fail_and_fail_requirement check_result result "expected_failure: Fail reason: The failure" atf_check -s eq:1 -e match:"Expected check failure: Fail first: abc" \ -e not-match:"And fail again" "${h}" -r result expect_fail_but_pass check_result result "failed: .*expecting a failure" # atf-sh does not support non-fatal failures yet; skip checks for # such conditions. case "${h}" in *sh_helpers*) continue ;; esac atf_check -s eq:0 -e match:"Expected check failure: Fail first: abc" \ -e match:"Expected check failure: And fail again: def" \ "${h}" -r result expect_fail_and_fail_check check_result result "expected_failure: And fail again: 2 checks" \ "failed as expected" done # atf-sh does not support non-fatal failures yet; skip checks for # such conditions. for h in $(get_helpers sh_helpers); do atf_check -s eq:0 -e ignore "${h}" -r result \ expect_fail_and_fail_requirement check_result result "expected_failure: Fail reason: The failure" atf_check -s eq:1 -e ignore "${h}" -r result expect_fail_but_pass check_result result "failed: .*expecting a failure" done } atf_test_case expect_exit expect_exit_body() { for h in $(get_helpers); do atf_check -s eq:0 -e ignore "${h}" -r result expect_exit_any_and_exit check_result result "expected_exit: Call will exit" atf_check -s eq:123 -e ignore "${h}" -r result expect_exit_code_and_exit check_result result "expected_exit\(123\): Call will exit" atf_check -s eq:1 -e ignore "${h}" -r result expect_exit_but_pass check_result result "failed: .*expected to exit" done } atf_test_case expect_signal expect_signal_body() { for h in $(get_helpers); do atf_check -s signal:9 -e ignore "${h}" -r result \ expect_signal_any_and_signal check_result result "expected_signal: Call will signal" atf_check -s signal:hup -e ignore "${h}" -r result \ expect_signal_no_and_signal check_result result "expected_signal\(1\): Call will signal" atf_check -s eq:1 -e ignore "${h}" -r result \ expect_signal_but_pass check_result result "failed: .*termination signal" done } atf_test_case expect_death expect_death_body() { for h in $(get_helpers); do atf_check -s eq:123 -e ignore "${h}" -r result expect_death_and_exit check_result result "expected_death: Exit case" atf_check -s signal:kill -e ignore "${h}" -r result \ expect_death_and_signal check_result result "expected_death: Signal case" atf_check -s eq:1 -e ignore "${h}" -r result expect_death_but_pass check_result result "failed: .*terminate abruptly" done } atf_test_case expect_timeout expect_timeout_body() { for h in $(get_helpers); do atf_check -s eq:1 -e ignore "${h}" -r result expect_timeout_but_pass check_result result "failed: Test case was expected to hang but it" \ "continued execution" done } atf_init_test_cases() { atf_add_test_case expect_pass atf_add_test_case expect_fail atf_add_test_case expect_exit atf_add_test_case expect_signal atf_add_test_case expect_death atf_add_test_case expect_timeout } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/meta_data_test.sh =================================================================== --- head/contrib/atf/test-programs/meta_data_test.sh (revision 273928) +++ head/contrib/atf/test-programs/meta_data_test.sh (revision 273929) @@ -1,64 +1,60 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2010 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# atf_test_case no_descr no_descr_head() { atf_set "descr" "Tests that the description may not be present" } no_descr_body() { for h in $(get_helpers); do atf_check -s eq:0 -o ignore -e ignore ${h} -s $(atf_get_srcdir) -l atf_check -s eq:0 -o match:passed -e ignore ${h} -s $(atf_get_srcdir) \ metadata_no_descr done } atf_test_case no_head no_head_head() { atf_set "descr" "Tests that the head may not be present" } no_head_body() { for h in $(get_helpers); do atf_check -s eq:0 -o ignore -e ignore ${h} -s $(atf_get_srcdir) -l atf_check -s eq:0 -o match:passed -e ignore ${h} -s $(atf_get_srcdir) \ metadata_no_head done } atf_init_test_cases() { atf_add_test_case no_descr atf_add_test_case no_head } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/result_test.sh =================================================================== --- head/contrib/atf/test-programs/result_test.sh (revision 273928) +++ head/contrib/atf/test-programs/result_test.sh (revision 273929) @@ -1,139 +1,135 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# -atf_test_case atf_run_warnings -atf_run_warnings_head() +atf_test_case runtime_warnings +runtime_warnings_head() { # The fact that this test case is in this test program is an abuse. atf_set "descr" "Tests that the test case prints a warning because" \ - "it is not being run by atf-run" + "it is being run outside of a runtime engine" } -atf_run_warnings_body() +runtime_warnings_body() { unset __RUNNING_INSIDE_ATF_RUN srcdir="$(atf_get_srcdir)" for h in $(get_helpers); do - atf_check -s eq:0 -o match:"passed" -e match:"WARNING.*atf-run" \ + atf_check -s eq:0 -o match:"passed" -e match:"WARNING.*kyua" \ "${h}" -s "${srcdir}" result_pass done } atf_test_case result_on_stdout result_on_stdout_head() { atf_set "descr" "Tests that the test case result is printed on stdout" \ "by default" } result_on_stdout_body() { srcdir="$(atf_get_srcdir)" for h in $(get_helpers); do atf_check -s eq:0 -o match:"passed" -o match:"msg" \ -e ignore "${h}" -s "${srcdir}" result_pass atf_check -s eq:1 -o match:"failed: Failure reason" -o match:"msg" \ -e ignore "${h}" -s "${srcdir}" result_fail atf_check -s eq:0 -o match:"skipped: Skipped reason" -o match:"msg" \ -e ignore "${h}" -s "${srcdir}" result_skip done } atf_test_case result_to_file result_to_file_head() { atf_set "descr" "Tests that the test case result is sent to a file if -r" \ "is used" } result_to_file_body() { srcdir="$(atf_get_srcdir)" for h in $(get_helpers); do atf_check -s eq:0 -o inline:"msg\n" -e ignore "${h}" -s "${srcdir}" \ -r resfile result_pass atf_check -o inline:"passed\n" cat resfile atf_check -s eq:1 -o inline:"msg\n" -e ignore "${h}" -s "${srcdir}" \ -r resfile result_fail atf_check -o inline:"failed: Failure reason\n" cat resfile atf_check -s eq:0 -o inline:"msg\n" -e ignore "${h}" -s "${srcdir}" \ -r resfile result_skip atf_check -o inline:"skipped: Skipped reason\n" cat resfile done } atf_test_case result_to_file_fail result_to_file_fail_head() { atf_set "descr" "Tests controlled failure if the test program fails to" \ "create the results file" atf_set "require.user" "unprivileged" } result_to_file_fail_body() { mkdir dir chmod 444 dir srcdir="$(atf_get_srcdir)" for h in $(get_helpers c_helpers cpp_helpers); do atf_check -s signal -o ignore \ -e match:"FATAL ERROR: Cannot create.*'dir/resfile'" \ "${h}" -s "${srcdir}" -r dir/resfile result_pass done for h in $(get_helpers sh_helpers); do atf_check -s exit -o ignore \ -e match:"ERROR: Cannot create.*'dir/resfile'" \ "${h}" -s "${srcdir}" -r dir/resfile result_pass done } atf_test_case result_exception result_exception_head() { atf_set "descr" "Tests that an unhandled exception is correctly captured" } result_exception_body() { for h in $(get_helpers cpp_helpers); do - atf_check -s exit:1 -o match:'failed: .*This is unhandled' \ - "${h}" -s "${srcdir}" result_exception + atf_check -s signal -o not-match:'failed: .*This is unhandled' \ + -e ignore "${h}" -s "${srcdir}" result_exception done } atf_init_test_cases() { - atf_add_test_case atf_run_warnings + atf_add_test_case runtime_warnings atf_add_test_case result_on_stdout atf_add_test_case result_to_file atf_add_test_case result_to_file_fail atf_add_test_case result_exception } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/sh_helpers.sh =================================================================== --- head/contrib/atf/test-programs/sh_helpers.sh (revision 273928) +++ head/contrib/atf/test-programs/sh_helpers.sh (revision 273929) @@ -1,394 +1,390 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# # ------------------------------------------------------------------------- # Helper tests for "t_cleanup". # ------------------------------------------------------------------------- atf_test_case cleanup_pass cleanup cleanup_pass_head() { atf_set "descr" "Helper test case for the t_cleanup test program" } cleanup_pass_body() { touch $(atf_config_get tmpfile) } cleanup_pass_cleanup() { if [ $(atf_config_get cleanup no) = yes ]; then rm $(atf_config_get tmpfile) fi } atf_test_case cleanup_fail cleanup cleanup_fail_head() { atf_set "descr" "Helper test case for the t_cleanup test program" } cleanup_fail_body() { touch $(atf_config_get tmpfile) atf_fail "On purpose" } cleanup_fail_cleanup() { if [ $(atf_config_get cleanup no) = yes ]; then rm $(atf_config_get tmpfile) fi } atf_test_case cleanup_skip cleanup cleanup_skip_head() { atf_set "descr" "Helper test case for the t_cleanup test program" } cleanup_skip_body() { touch $(atf_config_get tmpfile) atf_skip "On purpose" } cleanup_skip_cleanup() { if [ $(atf_config_get cleanup no) = yes ]; then rm $(atf_config_get tmpfile) fi } atf_test_case cleanup_curdir cleanup cleanup_curdir_head() { atf_set "descr" "Helper test case for the t_cleanup test program" } cleanup_curdir_body() { echo 1234 >oldvalue } cleanup_curdir_cleanup() { test -f oldvalue && echo "Old value: $(cat oldvalue)" } atf_test_case cleanup_sigterm cleanup cleanup_sigterm_head() { atf_set "descr" "Helper test case for the t_cleanup test program" } cleanup_sigterm_body() { touch $(atf_config_get tmpfile) kill $$ touch $(atf_config_get tmpfile).no } cleanup_sigterm_cleanup() { rm $(atf_config_get tmpfile) } # ------------------------------------------------------------------------- # Helper tests for "t_config". # ------------------------------------------------------------------------- atf_test_case config_unset config_unset_head() { atf_set "descr" "Helper test case for the t_config test program" } config_unset_body() { if atf_config_has 'test'; then atf_fail "Test variable already defined" fi } atf_test_case config_empty config_empty_head() { atf_set "descr" "Helper test case for the t_config test program" } config_empty_body() { atf_check_equal "$(atf_config_get 'test')" "" } atf_test_case config_value config_value_head() { atf_set "descr" "Helper test case for the t_config test program" } config_value_body() { atf_check_equal "$(atf_config_get 'test')" "foo" } atf_test_case config_multi_value config_multi_value_head() { atf_set "descr" "Helper test case for the t_config test program" } config_multi_value_body() { atf_check_equal "$(atf_config_get 'test')" "foo bar" } # ------------------------------------------------------------------------- # Helper tests for "t_expect". # ------------------------------------------------------------------------- atf_test_case expect_pass_and_pass expect_pass_and_pass_body() { atf_expect_pass } atf_test_case expect_pass_but_fail_requirement expect_pass_but_fail_requirement_body() { atf_expect_pass atf_fail "Some reason" } atf_test_case expect_pass_but_fail_check expect_pass_but_fail_check_body() { atf_fail "Non-fatal failures not implemented" } atf_test_case expect_fail_and_fail_requirement expect_fail_and_fail_requirement_body() { atf_expect_fail "Fail reason" atf_fail "The failure" atf_expect_pass } atf_test_case expect_fail_and_fail_check expect_fail_and_fail_check_body() { atf_fail "Non-fatal failures not implemented" } atf_test_case expect_fail_but_pass expect_fail_but_pass_body() { atf_expect_fail "Fail first" atf_expect_pass } atf_test_case expect_exit_any_and_exit expect_exit_any_and_exit_body() { atf_expect_exit -1 "Call will exit" exit 0 } atf_test_case expect_exit_code_and_exit expect_exit_code_and_exit_body() { atf_expect_exit 123 "Call will exit" exit 123 } atf_test_case expect_exit_but_pass expect_exit_but_pass_body() { atf_expect_exit -1 "Call won't exit" } atf_test_case expect_signal_any_and_signal expect_signal_any_and_signal_body() { atf_expect_signal -1 "Call will signal" kill -9 $$ } atf_test_case expect_signal_no_and_signal expect_signal_no_and_signal_body() { atf_expect_signal 1 "Call will signal" kill -1 $$ } atf_test_case expect_signal_but_pass expect_signal_but_pass_body() { atf_expect_signal -1 "Call won't signal" } atf_test_case expect_death_and_exit expect_death_and_exit_body() { atf_expect_death "Exit case" exit 123 } atf_test_case expect_death_and_signal expect_death_and_signal_body() { atf_expect_death "Signal case" kill -9 $$ } atf_test_case expect_death_but_pass expect_death_but_pass_body() { atf_expect_death "Call won't die" } atf_test_case expect_timeout_and_hang expect_timeout_and_hang_head() { atf_set "timeout" "1" } expect_timeout_and_hang_body() { atf_expect_timeout "Will overrun" sleep 5 } atf_test_case expect_timeout_but_pass expect_timeout_but_pass_head() { atf_set "timeout" "1" } expect_timeout_but_pass_body() { atf_expect_timeout "Will just exit" } # ------------------------------------------------------------------------- # Helper tests for "t_meta_data". # ------------------------------------------------------------------------- atf_test_case metadata_no_descr metadata_no_descr_head() { : } metadata_no_descr_body() { : } atf_test_case metadata_no_head metadata_no_head_body() { : } # ------------------------------------------------------------------------- # Helper tests for "t_srcdir". # ------------------------------------------------------------------------- atf_test_case srcdir_exists srcdir_exists_head() { atf_set "descr" "Helper test case for the t_srcdir test program" } srcdir_exists_body() { [ -f "$(atf_get_srcdir)/datafile" ] || atf_fail "Cannot find datafile" } # ------------------------------------------------------------------------- # Helper tests for "t_result". # ------------------------------------------------------------------------- atf_test_case result_pass result_pass_body() { echo "msg" } atf_test_case result_fail result_fail_body() { echo "msg" atf_fail "Failure reason" } atf_test_case result_skip result_skip_body() { echo "msg" atf_skip "Skipped reason" } # ------------------------------------------------------------------------- # Main. # ------------------------------------------------------------------------- atf_init_test_cases() { # Add helper tests for t_cleanup. atf_add_test_case cleanup_pass atf_add_test_case cleanup_fail atf_add_test_case cleanup_skip atf_add_test_case cleanup_curdir atf_add_test_case cleanup_sigterm # Add helper tests for t_config. atf_add_test_case config_unset atf_add_test_case config_empty atf_add_test_case config_value atf_add_test_case config_multi_value # Add helper tests for t_expect. atf_add_test_case expect_pass_and_pass atf_add_test_case expect_pass_but_fail_requirement atf_add_test_case expect_pass_but_fail_check atf_add_test_case expect_fail_and_fail_requirement atf_add_test_case expect_fail_and_fail_check atf_add_test_case expect_fail_but_pass atf_add_test_case expect_exit_any_and_exit atf_add_test_case expect_exit_code_and_exit atf_add_test_case expect_exit_but_pass atf_add_test_case expect_signal_any_and_signal atf_add_test_case expect_signal_no_and_signal atf_add_test_case expect_signal_but_pass atf_add_test_case expect_death_and_exit atf_add_test_case expect_death_and_signal atf_add_test_case expect_death_but_pass atf_add_test_case expect_timeout_and_hang atf_add_test_case expect_timeout_but_pass # Add helper tests for t_meta_data. atf_add_test_case metadata_no_descr atf_add_test_case metadata_no_head # Add helper tests for t_srcdir. atf_add_test_case srcdir_exists # Add helper tests for t_result. atf_add_test_case result_pass atf_add_test_case result_fail atf_add_test_case result_skip } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf/test-programs/srcdir_test.sh =================================================================== --- head/contrib/atf/test-programs/srcdir_test.sh (revision 273928) +++ head/contrib/atf/test-programs/srcdir_test.sh (revision 273929) @@ -1,149 +1,145 @@ -# -# Automated Testing Framework (atf) -# # Copyright (c) 2007 The NetBSD Foundation, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND # CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER # IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# create_files() { mkdir tmp touch tmp/datafile } atf_test_case default default_head() { atf_set "descr" "Checks that the program can find its files if" \ "executed from the same directory" } default_body() { create_files for hp in $(get_helpers); do h=${hp##*/} cp ${hp} tmp atf_check -s eq:0 -o ignore -e ignore -x \ "cd tmp && ./${h} srcdir_exists" atf_check -s eq:1 -o empty -e ignore "${hp}" -r res srcdir_exists atf_check -s eq:0 -o ignore -e empty grep "Cannot find datafile" res done } atf_test_case libtool libtool_head() { atf_set "descr" "Checks that the program can find its files if" \ "executed from the source directory and if it" \ "was built with libtool" } libtool_body() { create_files mkdir tmp/.libs for hp in $(get_helpers c_helpers cpp_helpers); do h=${hp##*/} cp ${hp} tmp cp ${hp} tmp/.libs atf_check -s eq:0 -o ignore -e ignore -x \ "cd tmp && ./.libs/${h} srcdir_exists" atf_check -s eq:1 -o empty -e ignore "${hp}" -r res srcdir_exists atf_check -s eq:0 -o ignore -e empty grep "Cannot find datafile" res done for hp in $(get_helpers c_helpers cpp_helpers); do h=${hp##*/} cp ${hp} tmp cp ${hp} tmp/.libs/lt-${h} atf_check -s eq:0 -o ignore -e ignore -x \ "cd tmp && ./.libs/lt-${h} srcdir_exists" atf_check -s eq:1 -o empty -e ignore "${hp}" -r res srcdir_exists atf_check -s eq:0 -o ignore -e empty grep "Cannot find datafile" res done } atf_test_case sflag sflag_head() { atf_set "descr" "Checks that the program can find its files when" \ "using the -s flag" } sflag_body() { create_files for hp in $(get_helpers); do h=${hp##*/} cp ${hp} tmp atf_check -s eq:0 -o ignore -e ignore -x \ "cd tmp && ./${h} -s $(pwd)/tmp \ srcdir_exists" atf_check -s eq:1 -o empty -e save:stderr "${hp}" -r res srcdir_exists atf_check -s eq:0 -o ignore -e empty grep "Cannot find datafile" res atf_check -s eq:0 -o ignore -e ignore \ "${hp}" -s "$(pwd)"/tmp srcdir_exists done } atf_test_case relative relative_head() { atf_set "descr" "Checks that passing a relative path through -s" \ "works" } relative_body() { create_files for hp in $(get_helpers); do h=${hp##*/} cp ${hp} tmp for p in tmp tmp/. ./tmp; do echo "Helper is: ${h}" echo "Using source directory: ${p}" atf_check -s eq:0 -o ignore -e ignore \ "./tmp/${h}" -s "${p}" srcdir_exists atf_check -s eq:1 -o empty -e save:stderr "${hp}" -r res \ srcdir_exists atf_check -s eq:0 -o ignore -e empty grep "Cannot find datafile" res atf_check -s eq:0 -o ignore -e ignore \ "${hp}" -s "${p}" srcdir_exists done done } atf_init_test_cases() { atf_add_test_case default atf_add_test_case libtool atf_add_test_case sflag atf_add_test_case relative } # vim: syntax=sh:expandtab:shiftwidth=4:softtabstop=4 Index: head/contrib/atf =================================================================== --- head/contrib/atf (revision 273928) +++ head/contrib/atf (revision 273929) Property changes on: head/contrib/atf ___________________________________________________________________ Modified: svn:mergeinfo ## -0,0 +0,1 ## Merged /vendor/atf/dist:r261890-273873 Index: head/lib/atf/Makefile.inc =================================================================== --- head/lib/atf/Makefile.inc (revision 273928) +++ head/lib/atf/Makefile.inc (revision 273929) @@ -1,53 +1,30 @@ #- # Copyright (c) 2011 Google, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ -_CFLAGS:= ${CFLAGS} -_CPPFLAGS:= ${CPPFLAGS} -_CXXFLAGS:= ${CXXFLAGS} - CFLAGS+= -DHAVE_CONFIG_H -CFLAGS+= -DATF_ARCH='"${MACHINE}"' -CFLAGS+= -DATF_BUILD_CC='"${CC}"' -CFLAGS+= -DATF_BUILD_CFLAGS='"${_CFLAGS}"' -CFLAGS+= -DATF_BUILD_CPP='"${CPP}"' -CFLAGS+= -DATF_BUILD_CPPFLAGS='"${_CPPFLAGS}"' -CFLAGS+= -DATF_BUILD_CXX='"${CXX}"' -CFLAGS+= -DATF_BUILD_CXXFLAGS='"${_CXXFLAGS}"' -CFLAGS+= -DATF_CONFDIR='"${CONFDIR}/atf"' -CFLAGS+= -DATF_C_TESTS_BASE='"${TESTSBASE}/lib/atf/libatf-c"' -CFLAGS+= -DATF_INCLUDEDIR='"${INCLUDEDIR}"' -CFLAGS+= -DATF_LIBDIR='"${LIBDIR}"' -CFLAGS+= -DATF_LIBEXECDIR='"${LIBEXECDIR}"' -CFLAGS+= -DATF_MACHINE='"${MACHINE_ARCH}"' -CFLAGS+= -DATF_M4='"/usr/bin/m4"' -CFLAGS+= -DATF_PKGDATADIR='"${SHAREDIR}/atf"' -CFLAGS+= -DATF_SHELL='"/bin/sh"' -CFLAGS+= -DATF_WORKDIR='"/tmp"' WARNS?= 3 - -# vim: syntax=make Index: head/lib/atf/common.mk =================================================================== --- head/lib/atf/common.mk (revision 273928) +++ head/lib/atf/common.mk (revision 273929) @@ -1,19 +1,19 @@ # $FreeBSD$ # # Common Makefile code for all components of ATF. # .if !defined(ATF) .error "ATF must be defined and point to the contrib/atf directory" .endif # Depend on the atf-version target to generate a file that contains the # version number of the currently imported ATF release and that only # changes on new imports. atf-version: atf-version-real @cmp -s atf-version atf-version-real \ || cp atf-version-real atf-version atf-version-real: .PHONY - @grep 'define VERSION' ${ATF}/bconfig.h \ + @grep 'define VERSION' ${ATF}/config.h \ | cut -d '"' -f 2 >atf-version-real CLEANFILES+= atf-version atf-version-real Index: head/lib/atf/libatf-c/Makefile =================================================================== --- head/lib/atf/libatf-c/Makefile (revision 273928) +++ head/lib/atf/libatf-c/Makefile (revision 273929) @@ -1,84 +1,93 @@ #- # Copyright (c) 2011 Google, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ .include .include +_CFLAGS:= ${CFLAGS} +_CPPFLAGS:= ${CPPFLAGS} +_CXXFLAGS:= ${CXXFLAGS} + LIB= atf-c PRIVATELIB= true -SHLIB_MAJOR= 0 +SHLIB_MAJOR= 1 ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF} .PATH: ${ATF}/atf-c .PATH: ${ATF}/atf-c/detail +CFLAGS+= -DATF_BUILD_CC='"${CC}"' +CFLAGS+= -DATF_BUILD_CFLAGS='"${_CFLAGS}"' +CFLAGS+= -DATF_BUILD_CPP='"${CPP}"' +CFLAGS+= -DATF_BUILD_CPPFLAGS='"${_CPPFLAGS}"' +CFLAGS+= -DATF_BUILD_CXX='"${CXX}"' +CFLAGS+= -DATF_BUILD_CXXFLAGS='"${_CXXFLAGS}"' CFLAGS+= -I${ATF} CFLAGS+= -I${.CURDIR} CFLAGS+= -I. SRCS= build.c \ check.c \ - config.c \ dynstr.c \ env.c \ error.c \ fs.c \ list.c \ map.c \ process.c \ sanity.c \ text.c \ user.c \ utils.c \ tc.c \ tp.c \ tp_main.c INCS= build.h \ check.h \ - config.h \ defs.h \ error.h \ error_fwd.h \ macros.h \ tc.h \ tp.h \ utils.h INCSDIR= ${INCLUDEDIR}/atf-c INCS+= atf-c.h INCSDIR_atf-c.h= ${INCLUDEDIR} -MAN= atf-c-api.3 +MAN= atf-c.3 +MLINKS+= atf-c.3 atf-c-api.3 # Backwards compatibility. .if ${MK_TESTS} != "no" SUBDIR= tests .endif .include "../common.mk" .include Index: head/lib/atf/libatf-c/tests/Makefile =================================================================== --- head/lib/atf/libatf-c/tests/Makefile (revision 273928) +++ head/lib/atf/libatf-c/tests/Makefile (revision 273929) @@ -1,36 +1,36 @@ # $FreeBSD$ .include TESTSDIR= ${TESTSBASE}/lib/atf/libatf-c TESTS_SUBDIRS= detail ATF= ${.CURDIR:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-c .PATH: ${ATF}/atf-c/detail +CFLAGS+= -DATF_INCLUDEDIR='"${INCLUDEDIR}"' CFLAGS+= -I${ATF} # macros_test.c contains a double 'const const' which will be gone with # the import of atf-0.18. # TODO(jmmv): Remove this workaround once we do that update. CFLAGS.clang+= -Wno-duplicate-decl-specifier FILESDIR= ${TESTSDIR} FILES= macros_h_test.c FILES+= unused_test.c .for _T in atf_c_test \ build_test \ check_test \ - config_test \ error_test \ macros_test \ tc_test \ tp_test \ utils_test ATF_TESTS_C+= ${_T} SRCS.${_T}= ${_T}.c test_helpers.c .endfor .include Index: head/lib/atf/libatf-c/tests/detail/Makefile =================================================================== --- head/lib/atf/libatf-c/tests/detail/Makefile (revision 273928) +++ head/lib/atf/libatf-c/tests/detail/Makefile (revision 273929) @@ -1,34 +1,35 @@ # $FreeBSD$ .include TESTSDIR= ${TESTSBASE}/lib/atf/libatf-c/detail ATF= ${.CURDIR:H:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-c/detail +CFLAGS+= -DATF_INCLUDEDIR='"${INCLUDEDIR}"' CFLAGS+= -I${ATF} .for _T in dynstr_test \ env_test \ fs_test \ list_test \ map_test \ process_test \ sanity_test \ text_test \ user_test ATF_TESTS_C+= ${_T} SRCS.${_T}= ${_T}.c test_helpers.c .endfor .for p in process_helpers version_helper PROGS+= ${p} SRCS.${p}= ${p}.c MAN.${p}= # defined BINDIR.${p}= ${TESTSDIR} .endfor version_helper.o: atf-version .include "../../../common.mk" .include Index: head/lib/atf/libatf-c++/Makefile =================================================================== --- head/lib/atf/libatf-c++/Makefile (revision 273928) +++ head/lib/atf/libatf-c++/Makefile (revision 273929) @@ -1,82 +1,81 @@ #- # Copyright (c) 2011 Google, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ .include .include LIB= atf-c++ PRIVATELIB= true -SHLIB_MAJOR= 1 +SHLIB_MAJOR= 2 # libatf-c++ depends on the C version of the ATF library to build. DPADD= ${LIBATF_C} LDADD= -latf-c LDFLAGS+= -L${.OBJDIR}/../libatf-c ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF} .PATH: ${ATF}/atf-c++ .PATH: ${ATF}/atf-c++/detail CFLAGS+= -I${ATF} CFLAGS+= -I${.CURDIR}/../libatf-c CFLAGS+= -I. CFLAGS+= -DHAVE_CONFIG_H SRCS= application.cpp \ build.cpp \ check.cpp \ - config.cpp \ env.cpp \ exceptions.cpp \ fs.cpp \ process.cpp \ tests.cpp \ text.cpp \ utils.cpp INCS= build.hpp \ check.hpp \ - config.hpp \ macros.hpp \ tests.hpp \ utils.hpp INCSDIR= ${INCLUDEDIR}/atf-c++ INCS+= atf-c++.hpp INCSDIR_atf-c++.hpp= ${INCLUDEDIR} -MAN= atf-c++-api.3 +MAN= atf-c++.3 +MLINKS+= atf-c++.3 atf-c-api++.3 # Backwards compatibility. .if ${MK_TESTS} != "no" SUBDIR= tests .endif .include "../common.mk" .include Index: head/lib/atf/libatf-c++/tests/Makefile =================================================================== --- head/lib/atf/libatf-c++/tests/Makefile (revision 273928) +++ head/lib/atf/libatf-c++/tests/Makefile (revision 273929) @@ -1,29 +1,30 @@ # $FreeBSD$ .include TESTSDIR= ${TESTSBASE}/lib/atf/libatf-c++ TESTS_SUBDIRS= detail ATF= ${.CURDIR:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-c++ .PATH: ${ATF}/atf-c++/detail +CFLAGS+= -DATF_C_TESTS_BASE='"${TESTSBASE}/lib/atf/libatf-c"' +CFLAGS+= -DATF_INCLUDEDIR='"${INCLUDEDIR}"' CFLAGS+= -I${ATF} FILESDIR= ${TESTSDIR} FILES= macros_hpp_test.cpp FILES+= unused_test.cpp .for _T in atf_c++_test \ build_test \ check_test \ - config_test \ macros_test \ tests_test \ utils_test ATF_TESTS_CXX+= ${_T} SRCS.${_T}= ${_T}.cpp test_helpers.cpp .endfor .include Index: head/lib/atf/libatf-c++/tests/detail/Makefile =================================================================== --- head/lib/atf/libatf-c++/tests/detail/Makefile (revision 273928) +++ head/lib/atf/libatf-c++/tests/detail/Makefile (revision 273929) @@ -1,32 +1,33 @@ # $FreeBSD$ .include TESTSDIR= ${TESTSBASE}/lib/atf/libatf-c++/detail ATF= ${.CURDIR:H:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-c++/detail +CFLAGS+= -DATF_C_TESTS_BASE='"${TESTSBASE}/lib/atf/libatf-c"' +CFLAGS+= -DATF_INCLUDEDIR='"${INCLUDEDIR}"' CFLAGS+= -I${ATF} .for _T in application_test \ env_test \ exceptions_test \ fs_test \ process_test \ - sanity_test \ text_test ATF_TESTS_CXX+= ${_T} SRCS.${_T}= ${_T}.cpp test_helpers.cpp .endfor .for p in version_helper PROGS_CXX+= ${p} SRCS.${p}= ${p}.cpp MAN.${p}= # defined BINDIR.${p}= ${TESTSDIR} .endfor version_helper.o: atf-version .include "../../../common.mk" .include Index: head/libexec/atf/atf-check/Makefile =================================================================== --- head/libexec/atf/atf-check/Makefile (revision 273928) +++ head/libexec/atf/atf-check/Makefile (revision 273929) @@ -1,48 +1,49 @@ #- # Copyright (c) 2011 Google, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ .include .include ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF}/atf-sh PROG_CXX= atf-check SRCS= atf-check.cpp MAN= atf-check.1 CFLAGS+= -I${ATF} +CFLAGS+= -DATF_SHELL='"/bin/sh"' DPADD+= ${LIBATF_CXX} ${LIBATF_C} LDADD+= ${LDATF_CXX} ${LDATF_C} USEPRIVATELIB= atf-c++ atf-c .if ${MK_TESTS} != "no" SUBDIR+= tests .endif .include Index: head/libexec/atf/atf-sh/Makefile =================================================================== --- head/libexec/atf/atf-sh/Makefile (revision 273928) +++ head/libexec/atf/atf-sh/Makefile (revision 273929) @@ -1,55 +1,59 @@ #- # Copyright (c) 2011 Google, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ .include .include ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF}/atf-sh PROG_CXX= atf-sh SRCS= atf-sh.cpp -MAN= atf-sh.1 atf-sh-api.3 +MAN= atf-sh.1 atf-sh.3 +MLINKS+= atf-sh.3 atf-sh-api.3 # Backwards compatibility. CFLAGS+= -DHAVE_CONFIG_H +CFLAGS+= -DATF_LIBEXECDIR='"${LIBEXECDIR}"' +CFLAGS+= -DATF_PKGDATADIR='"${SHAREDIR}/atf"' +CFLAGS+= -DATF_SHELL='"/bin/sh"' CFLAGS+= -I${ATF} DPADD+= ${LIBATF_C} ${LIBATF_CXX} LDADD+= ${LDATF_C} ${LDATF_CXX} USEPRIVATELIB= atf-c++ atf-c FILESGROUPS= SUBR SUBRDIR= ${SHAREDIR}/atf SUBR= libatf-sh.subr .if ${MK_TESTS} != "no" SUBDIR+= tests .endif .include "../../../lib/atf/common.mk" .include Index: head/libexec/atf/atf-sh/tests/Makefile =================================================================== --- head/libexec/atf/atf-sh/tests/Makefile (revision 273928) +++ head/libexec/atf/atf-sh/tests/Makefile (revision 273929) @@ -1,31 +1,30 @@ # $FreeBSD$ .include TESTSDIR= ${TESTSBASE}/libexec/atf/atf-sh ATF= ${.CURDIR:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-sh ATF_TESTS_SH+= atf_check_test ATF_TESTS_SH+= config_test ATF_TESTS_SH+= integration_test ATF_TESTS_SH+= normalize_test ATF_TESTS_SH+= tc_test ATF_TESTS_SH+= tp_test integration_test: Makefile ATF_TESTS_SH_SED_integration_test= \ - -e 's,atf_check,PATH=/usr/libexec:$${PATH} atf_check,g' \ - -e 's,/usr/bin/env *atf-sh,/usr/libexec/atf-sh,g' + -e 's,__ATF_SH__,/usr/libexec/atf-sh,g' SCRIPTS+= misc_helpers SCRIPTSDIR_misc_helpers=${TESTSDIR} CLEANFILES+= misc_helpers misc_helpers.tmp misc_helpers: misc_helpers.sh echo '#! /usr/libexec/atf-sh' >${.TARGET}.tmp cat ${.ALLSRC} >>${.TARGET}.tmp chmod +x ${.TARGET}.tmp mv ${.TARGET}.tmp ${.TARGET} .include Index: head/share/man/man7/Makefile =================================================================== --- head/share/man/man7/Makefile (revision 273928) +++ head/share/man/man7/Makefile (revision 273929) @@ -1,40 +1,51 @@ # @(#)Makefile 8.1 (Berkeley) 6/5/93 # $FreeBSD$ -.include +.include #MISSING: eqnchar.7 ms.7 term.7 MAN= adding_user.7 \ ascii.7 \ bsd.snmpmod.mk.7 \ build.7 \ clocks.7 \ c99.7 \ development.7 \ environ.7 \ ffs.7 \ firewall.7 \ hier.7 \ hostname.7 \ intro.7 \ maclabel.7 \ mailaddr.7 \ operator.7 \ ports.7 \ release.7 \ sdoc.7 \ security.7 \ sprog.7 \ stdint.7 \ sticky.7 \ tests.7 \ tuning.7 MLINKS= intro.7 miscellaneous.7 MLINKS+= security.7 securelevel.7 MLINKS+= c99.7 c.7 MLINKS+= c99.7 c78.7 MLINKS+= c99.7 c89.7 MLINKS+= c99.7 c90.7 + +.if ${MK_TESTS} != "no" +ATF= ${.CURDIR}/../../../contrib/atf +.PATH: ${ATF}/doc +MAN+= atf.7 + +CLEANFILES+= atf.7 +atf.7: atf.7.in + sed -e 's,__DOCDIR__,/usr/share/doc/atf,g' \ + <"${ATF}/doc/atf.7.in" >atf.7 +.endif .include Index: head/tools/build/mk/OptionalObsoleteFiles.inc =================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc (revision 273928) +++ head/tools/build/mk/OptionalObsoleteFiles.inc (revision 273929) @@ -1,4784 +1,4789 @@ # # $FreeBSD$ # # This file add support for the WITHOUT_* and WITH_* knobs in src.conf(5) to # the check-old and delete-old* targets. # .if ${MK_ACCT} == no OLD_FILES+=etc/periodic/daily/310.accounting OLD_FILES+=usr/sbin/accton OLD_FILES+=usr/sbin/sa OLD_FILES+=usr/share/man/man8/accton.8.gz OLD_FILES+=usr/share/man/man8/sa.8.gz .endif .if ${MK_ACPI} == no OLD_FILES+=usr/sbin/acpiconf OLD_FILES+=usr/sbin/acpidb OLD_FILES+=usr/sbin/acpidump OLD_FILES+=usr/sbin/iasl OLD_FILES+=usr/share/man/man8/acpiconf.8.gz OLD_FILES+=usr/share/man/man8/acpidb.8.gz OLD_FILES+=usr/share/man/man8/acpidump.8.gz OLD_FILES+=usr/share/man/man8/iasl.8.gz .endif .if ${MK_AMD} == no OLD_FILES+=etc/amd.map OLD_FILES+=usr/bin/pawd OLD_FILES+=usr/sbin/amd OLD_FILES+=usr/sbin/amq OLD_FILES+=usr/sbin/fixmount OLD_FILES+=usr/sbin/fsinfo OLD_FILES+=usr/sbin/hlfsd OLD_FILES+=usr/sbin/mk-amd-map OLD_FILES+=usr/sbin/wire-test OLD_FILES+=usr/share/examples/etc/amd.map OLD_FILES+=usr/share/info/am-utils.info.gz OLD_FILES+=usr/share/man/man1/pawd.1.gz OLD_FILES+=usr/share/man/man5/amd.conf.5.gz OLD_FILES+=usr/share/man/man8/amd.8.gz OLD_FILES+=usr/share/man/man8/amq.8.gz OLD_FILES+=usr/share/man/man8/fixmount.8.gz OLD_FILES+=usr/share/man/man8/fsinfo.8.gz OLD_FILES+=usr/share/man/man8/hlfsd.8.gz OLD_FILES+=usr/share/man/man8/mk-amd-map.8.gz OLD_FILES+=usr/share/man/man8/wire-test.8.gz .endif .if ${MK_APM} == no OLD_FILES+=etc/apmd.conf OLD_FILES+=usr/sbin/apm OLD_FILES+=usr/share/examples/etc/apmd.conf OLD_FILES+=usr/share/man/man8/amd64/apm.8.gz OLD_FILES+=usr/share/man/man8/amd64/apmconf.8.gz .endif .if ${MK_AT} == no OLD_FILES+=usr/bin/at OLD_FILES+=usr/bin/atq OLD_FILES+=usr/bin/atrm OLD_FILES+=usr/bin/batch OLD_FILES+=usr/libexec/atrun OLD_FILES+=usr/share/man/man1/at.1.gz OLD_FILES+=usr/share/man/man1/atq.1.gz OLD_FILES+=usr/share/man/man1/atrm.1.gz OLD_FILES+=usr/share/man/man1/batch.1.gz OLD_FILES+=usr/share/man/man8/atrun.8.gz .endif .if ${MK_ATM} == no OLD_FILES+=rescue/atmconfig OLD_FILES+=sbin/atmconfig OLD_FILES+=usr/bin/sscop OLD_FILES+=usr/include/bsnmp/snmp_atm.h OLD_FILES+=usr/include/netnatm/addr.h OLD_FILES+=usr/include/netnatm/api/atmapi.h OLD_FILES+=usr/include/netnatm/api/ccatm.h OLD_FILES+=usr/include/netnatm/api/unisap.h OLD_DIRS+=usr/include/netnatm/api OLD_FILES+=usr/include/netnatm/msg/uni_config.h OLD_FILES+=usr/include/netnatm/msg/uni_hdr.h OLD_FILES+=usr/include/netnatm/msg/uni_ie.h OLD_FILES+=usr/include/netnatm/msg/uni_msg.h OLD_FILES+=usr/include/netnatm/msg/unimsglib.h OLD_FILES+=usr/include/netnatm/msg/uniprint.h OLD_FILES+=usr/include/netnatm/msg/unistruct.h OLD_DIRS+=usr/include/netnatm/msg OLD_FILES+=usr/include/netnatm/saal/sscfu.h OLD_FILES+=usr/include/netnatm/saal/sscfudef.h OLD_FILES+=usr/include/netnatm/saal/sscop.h OLD_FILES+=usr/include/netnatm/saal/sscopdef.h OLD_DIRS+=usr/include/netnatm/saal OLD_FILES+=usr/include/netnatm/sig/uni.h OLD_FILES+=usr/include/netnatm/sig/unidef.h OLD_FILES+=usr/include/netnatm/sig/unisig.h OLD_DIRS+=usr/include/netnatm/sig OLD_FILES+=usr/include/netnatm/unimsg.h OLD_FILES+=usr/lib/libngatm.a OLD_FILES+=usr/lib/libngatm.so OLD_LIBS+=usr/lib/libngatm.so.4 OLD_FILES+=usr/lib/libngatm_p.a OLD_FILES+=usr/lib/snmp_atm.so OLD_LIBS+=usr/lib/snmp_atm.so.6 .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libngatm.a OLD_FILES+=usr/lib32/libngatm.so OLD_LIBS+=usr/lib32/libngatm.so.4 OLD_FILES+=usr/lib32/libngatm_p.a .endif OLD_FILES+=usr/share/doc/atm/atmconfig.help OLD_FILES+=usr/share/doc/atm/atmconfig_device.help OLD_DIRS+=usr/share/doc/atm OLD_FILES+=usr/share/man/man1/sscop.1.gz OLD_FILES+=usr/share/man/man3/libngatm.3.gz OLD_FILES+=usr/share/man/man3/snmp_atm.3.gz OLD_FILES+=usr/share/man/man3/uniaddr.3.gz OLD_FILES+=usr/share/man/man3/unifunc.3.gz OLD_FILES+=usr/share/man/man3/unimsg.3.gz OLD_FILES+=usr/share/man/man3/unisap.3.gz OLD_FILES+=usr/share/man/man3/unistruct.3.gz OLD_FILES+=usr/share/man/man8/atmconfig.8.gz OLD_FILES+=usr/share/snmp/defs/atm_freebsd.def OLD_FILES+=usr/share/snmp/defs/atm_tree.def OLD_FILES+=usr/share/snmp/mibs/BEGEMOT-ATM-FREEBSD-MIB.txt OLD_FILES+=usr/share/snmp/mibs/BEGEMOT-ATM.txt .endif .if ${MK_AUDIT} == no OLD_FILES+=usr/sbin/audit OLD_FILES+=usr/sbin/auditd OLD_FILES+=usr/sbin/auditreduce OLD_FILES+=usr/sbin/praudit OLD_FILES+=usr/share/man/man1/auditreduce.1.gz OLD_FILES+=usr/share/man/man1/praudit.1.gz OLD_FILES+=usr/share/man/man8/audit.8.gz OLD_FILES+=usr/share/man/man8/auditd.8.gz .endif .if ${MK_AUTHPF} == no OLD_FILES+=usr/sbin/authpf OLD_FILES+=usr/sbin/authpf-noip OLD_FILES+=usr/share/man/man8/authpf.8.gz OLD_FILES+=usr/share/man/man8/authpf-noip.8.gz .endif .if ${MK_BLUETOOTH} == no OLD_FILES+=etc/bluetooth/hcsecd.conf OLD_FILES+=etc/bluetooth/hosts OLD_FILES+=etc/bluetooth/protocols OLD_DIRS+=etc/bluetooth OLD_FILES+=usr/bin/bthost OLD_FILES+=usr/bin/btsockstat OLD_FILES+=usr/bin/rfcomm_sppd OLD_FILES+=usr/include/bluetooth.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_bluetooth.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_bt3c.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_btsocket.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_btsocket_hci_raw.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_btsocket_l2cap.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_btsocket_rfcomm.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_btsocket_sco.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_h4.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_hci.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_l2cap.h OLD_FILES+=usr/include/netgraph/bluetooth/include/ng_ubt.h OLD_DIRS+=usr/include/netgraph/bluetooth/include OLD_DIRS+=usr/include/netgraph/bluetooth OLD_FILES+=usr/include/sdp.h OLD_FILES+=usr/lib/libbluetooth.a OLD_FILES+=usr/lib/libbluetooth.so OLD_LIBS+=usr/lib/libbluetooth.so.4 OLD_FILES+=usr/lib/libbluetooth_p.a OLD_FILES+=usr/lib/libsdp.a OLD_FILES+=usr/lib/libsdp.so OLD_LIBS+=usr/lib/libsdp.so.4 OLD_FILES+=usr/lib/libsdp_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libbluetooth.a OLD_FILES+=usr/lib32/libbluetooth.so OLD_LIBS+=usr/lib32/libbluetooth.so.4 OLD_FILES+=usr/lib32/libbluetooth_p.a OLD_FILES+=usr/lib32/libsdp.a OLD_FILES+=usr/lib32/libsdp.so OLD_LIBS+=usr/lib32/libsdp.so.4 OLD_FILES+=usr/lib32/libsdp_p.a .endif OLD_FILES+=usr/sbin/bcmfw OLD_FILES+=usr/sbin/bt3cfw OLD_FILES+=usr/sbin/bthidcontrol OLD_FILES+=usr/sbin/bthidd OLD_FILES+=usr/sbin/btpand OLD_FILES+=usr/sbin/hccontrol OLD_FILES+=usr/sbin/hcsecd OLD_FILES+=usr/sbin/hcseriald OLD_FILES+=usr/sbin/l2control OLD_FILES+=usr/sbin/l2ping OLD_FILES+=usr/sbin/rfcomm_pppd OLD_FILES+=usr/sbin/sdpcontrol OLD_FILES+=usr/sbin/sdpd OLD_FILES+=usr/share/man/man1/bthost.1.gz OLD_FILES+=usr/share/man/man1/btsockstat.1.gz OLD_FILES+=usr/share/man/man1/rfcomm_sppd.1.gz OLD_FILES+=usr/share/man/man3/SDP_GET128.3.gz OLD_FILES+=usr/share/man/man3/SDP_GET16.3.gz OLD_FILES+=usr/share/man/man3/SDP_GET32.3.gz OLD_FILES+=usr/share/man/man3/SDP_GET64.3.gz OLD_FILES+=usr/share/man/man3/SDP_GET8.3.gz OLD_FILES+=usr/share/man/man3/SDP_PUT128.3.gz OLD_FILES+=usr/share/man/man3/SDP_PUT16.3.gz OLD_FILES+=usr/share/man/man3/SDP_PUT32.3.gz OLD_FILES+=usr/share/man/man3/SDP_PUT64.3.gz OLD_FILES+=usr/share/man/man3/SDP_PUT8.3.gz OLD_FILES+=usr/share/man/man3/bdaddr_any.3.gz OLD_FILES+=usr/share/man/man3/bdaddr_copy.3.gz OLD_FILES+=usr/share/man/man3/bdaddr_same.3.gz OLD_FILES+=usr/share/man/man3/bluetooth.3.gz OLD_FILES+=usr/share/man/man3/bt_aton.3.gz OLD_FILES+=usr/share/man/man3/bt_devaddr.3.gz OLD_FILES+=usr/share/man/man3/bt_devclose.3.gz OLD_FILES+=usr/share/man/man3/bt_devenum.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_evt_clr.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_evt_set.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_evt_tst.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_pkt_clr.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_pkt_set.3.gz OLD_FILES+=usr/share/man/man3/bt_devfilter_pkt_tst.3.gz OLD_FILES+=usr/share/man/man3/bt_devinfo.3.gz OLD_FILES+=usr/share/man/man3/bt_devinquiry.3.gz OLD_FILES+=usr/share/man/man3/bt_devname.3.gz OLD_FILES+=usr/share/man/man3/bt_devopen.3.gz OLD_FILES+=usr/share/man/man3/bt_devreq.3.gz OLD_FILES+=usr/share/man/man3/bt_devsend.3.gz OLD_FILES+=usr/share/man/man3/bt_endhostent.3.gz OLD_FILES+=usr/share/man/man3/bt_endprotoent.3.gz OLD_FILES+=usr/share/man/man3/bt_gethostbyaddr.3.gz OLD_FILES+=usr/share/man/man3/bt_gethostbyname.3.gz OLD_FILES+=usr/share/man/man3/bt_gethostent.3.gz OLD_FILES+=usr/share/man/man3/bt_getprotobyname.3.gz OLD_FILES+=usr/share/man/man3/bt_getprotobynumber.3.gz OLD_FILES+=usr/share/man/man3/bt_getprotoent.3.gz OLD_FILES+=usr/share/man/man3/bt_ntoa.3.gz OLD_FILES+=usr/share/man/man3/bt_sethostent.3.gz OLD_FILES+=usr/share/man/man3/bt_setprotoent.3.gz OLD_FILES+=usr/share/man/man3/sdp.3.gz OLD_FILES+=usr/share/man/man3/sdp_attr2desc.3.gz OLD_FILES+=usr/share/man/man3/sdp_change_service.3.gz OLD_FILES+=usr/share/man/man3/sdp_close.3.gz OLD_FILES+=usr/share/man/man3/sdp_error.3.gz OLD_FILES+=usr/share/man/man3/sdp_open.3.gz OLD_FILES+=usr/share/man/man3/sdp_open_local.3.gz OLD_FILES+=usr/share/man/man3/sdp_register_service.3.gz OLD_FILES+=usr/share/man/man3/sdp_search.3.gz OLD_FILES+=usr/share/man/man3/sdp_unregister_service.3.gz OLD_FILES+=usr/share/man/man3/sdp_uuid2desc.3.gz OLD_FILES+=usr/share/man/man5/hcsecd.conf.5.gz OLD_FILES+=usr/share/man/man8/bcmfw.8.gz OLD_FILES+=usr/share/man/man8/bt3cfw.8.gz OLD_FILES+=usr/share/man/man8/bthidcontrol.8.gz OLD_FILES+=usr/share/man/man8/bthidd.8.gz OLD_FILES+=usr/share/man/man8/btpand.8.gz OLD_FILES+=usr/share/man/man8/hccontrol.8.gz OLD_FILES+=usr/share/man/man8/hcsecd.8.gz OLD_FILES+=usr/share/man/man8/hcseriald.8.gz OLD_FILES+=usr/share/man/man8/l2control.8.gz OLD_FILES+=usr/share/man/man8/l2ping.8.gz OLD_FILES+=usr/share/man/man8/rfcomm_pppd.8.gz OLD_FILES+=usr/share/man/man8/sdpcontrol.8.gz OLD_FILES+=usr/share/man/man8/sdpd.8.gz .endif #.if ${MK_BOOT} == no # to be filled in #.endif .if ${MK_CALENDAR} == no OLD_FILES+=etc/periodic/daily/300.calendar OLD_FILES+=usr/bin/calendar OLD_FILES+=usr/share/calendar/calendar.all OLD_FILES+=usr/share/calendar/calendar.australia OLD_FILES+=usr/share/calendar/calendar.birthday OLD_FILES+=usr/share/calendar/calendar.brazilian OLD_FILES+=usr/share/calendar/calendar.christian OLD_FILES+=usr/share/calendar/calendar.computer OLD_FILES+=usr/share/calendar/calendar.croatian OLD_FILES+=usr/share/calendar/calendar.dutch OLD_FILES+=usr/share/calendar/calendar.freebsd OLD_FILES+=usr/share/calendar/calendar.french OLD_FILES+=usr/share/calendar/calendar.german OLD_FILES+=usr/share/calendar/calendar.history OLD_FILES+=usr/share/calendar/calendar.holiday OLD_FILES+=usr/share/calendar/calendar.hungarian OLD_FILES+=usr/share/calendar/calendar.judaic OLD_FILES+=usr/share/calendar/calendar.lotr OLD_FILES+=usr/share/calendar/calendar.music OLD_FILES+=usr/share/calendar/calendar.newzealand OLD_FILES+=usr/share/calendar/calendar.russian OLD_FILES+=usr/share/calendar/calendar.southafrica OLD_FILES+=usr/share/calendar/calendar.ukrainian OLD_FILES+=usr/share/calendar/calendar.usholiday OLD_FILES+=usr/share/calendar/calendar.world OLD_FILES+=usr/share/calendar/de_AT.ISO_8859-15/calendar.feiertag OLD_DIRS+=usr/share/calendar/de_AT.ISO_8859-15 OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.all OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.feiertag OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.geschichte OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.kirche OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.literatur OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.musik OLD_FILES+=usr/share/calendar/de_DE.ISO8859-1/calendar.wissenschaft OLD_DIRS+=usr/share/calendar/de_DE.ISO8859-1 OLD_FILES+=usr/share/calendar/de_DE.ISO8859-15 OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-1/calendar.all OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-1/calendar.fetes OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-1/calendar.french OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-1/calendar.jferies OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-1/calendar.proverbes OLD_DIRS+=usr/share/calendar/fr_FR.ISO8859-1 OLD_FILES+=usr/share/calendar/fr_FR.ISO8859-15 OLD_FILES+=usr/share/calendar/hr_HR.ISO8859-2/calendar.all OLD_FILES+=usr/share/calendar/hr_HR.ISO8859-2/calendar.praznici OLD_DIRS+=usr/share/calendar/hr_HR.ISO8859-2 OLD_FILES+=usr/share/calendar/hu_HU.ISO8859-2/calendar.all OLD_FILES+=usr/share/calendar/hu_HU.ISO8859-2/calendar.nevnapok OLD_FILES+=usr/share/calendar/hu_HU.ISO8859-2/calendar.unnepek OLD_DIRS+=usr/share/calendar/hu_HU.ISO8859-2 OLD_FILES+=usr/share/calendar/pt_BR.ISO8859-1/calendar.all OLD_FILES+=usr/share/calendar/pt_BR.ISO8859-1/calendar.commemorative OLD_FILES+=usr/share/calendar/pt_BR.ISO8859-1/calendar.holidays OLD_FILES+=usr/share/calendar/pt_BR.ISO8859-1/calendar.mcommemorative OLD_DIRS+=usr/share/calendar/pt_BR.ISO8859-1 OLD_FILES+=usr/share/calendar/pt_BR.UTF-8/calendar.all OLD_FILES+=usr/share/calendar/pt_BR.UTF-8/calendar.commemorative OLD_FILES+=usr/share/calendar/pt_BR.UTF-8/calendar.holidays OLD_FILES+=usr/share/calendar/pt_BR.UTF-8/calendar.mcommemorative OLD_DIRS+=usr/share/calendar/pt_BR.UTF-8 OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.all OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.common OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.holiday OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.military OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.orthodox OLD_FILES+=usr/share/calendar/ru_RU.KOI8-R/calendar.pagan OLD_DIRS+=usr/share/calendar/ru_RU.KOI8-R OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.all OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.common OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.holiday OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.military OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.orthodox OLD_FILES+=usr/share/calendar/ru_RU.UTF-8/calendar.pagan OLD_DIRS+=usr/share/calendar/ru_RU.UTF-8 OLD_FILES+=usr/share/calendar/uk_UA.KOI8-U/calendar.all OLD_FILES+=usr/share/calendar/uk_UA.KOI8-U/calendar.holiday OLD_FILES+=usr/share/calendar/uk_UA.KOI8-U/calendar.misc OLD_FILES+=usr/share/calendar/uk_UA.KOI8-U/calendar.orthodox OLD_DIRS+=usr/share/calendar/uk_UA.KOI8-U OLD_DIRS+=usr/share/calendar OLD_FILES+=usr/share/man/man1/calendar.1.gz .endif .if ${MK_CASPER} == no OLD_FILES+=etc/rc.d/casperd OLD_LIBS+=lib/libcasper.so.0 OLD_FILES+=sbin/casper OLD_FILES+=usr/lib/libcasper.a .endif .if ${MK_CDDL} == no OLD_LIBS+=lib/libavl.so.2 OLD_LIBS+=lib/libctf.so.2 OLD_LIBS+=lib/libdtrace.so.2 OLD_LIBS+=lib/libnvpair.so.2 OLD_LIBS+=lib/libumem.so.2 OLD_LIBS+=lib/libuutil.so.2 OLD_FILES+=usr/bin/ctfconvert OLD_FILES+=usr/bin/ctfdump OLD_FILES+=usr/bin/ctfmerge OLD_FILES+=usr/bin/sgsmsg OLD_FILES+=usr/lib/dtrace/drti.o OLD_FILES+=usr/lib/dtrace/errno.d OLD_FILES+=usr/lib/dtrace/io.d OLD_FILES+=usr/lib/dtrace/ip.d OLD_FILES+=usr/lib/dtrace/psinfo.d .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/lib/dtrace/regs_x86.d .endif OLD_FILES+=usr/lib/dtrace/signal.d OLD_FILES+=usr/lib/dtrace/tcp.d OLD_FILES+=usr/lib/dtrace/udp.d OLD_FILES+=usr/lib/dtrace/unistd.d OLD_DIRS+=usr/lib/dtrace OLD_FILES+=usr/lib/libavl.a OLD_FILES+=usr/lib/libavl.so OLD_FILES+=usr/lib/libavl_p.a OLD_FILES+=usr/lib/libctf.a OLD_FILES+=usr/lib/libctf.so OLD_FILES+=usr/lib/libctf_p.a OLD_FILES+=usr/lib/libdtrace.a OLD_FILES+=usr/lib/libdtrace.so OLD_FILES+=usr/lib/libdtrace_p.a OLD_FILES+=usr/lib/libnvpair.a OLD_FILES+=usr/lib/libnvpair.so OLD_FILES+=usr/lib/libnvpair_p.a OLD_FILES+=usr/lib/libumem.a OLD_FILES+=usr/lib/libumem.so OLD_FILES+=usr/lib/libumem_p.a OLD_FILES+=usr/lib/libuutil.a OLD_FILES+=usr/lib/libuutil.so OLD_FILES+=usr/lib/libuutil_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/dtrace/drti.o OLD_DIRS+=usr/lib32/dtrace OLD_FILES+=usr/lib32/libavl.a OLD_FILES+=usr/lib32/libavl.so OLD_LIBS+=usr/lib32/libavl.so.2 OLD_FILES+=usr/lib32/libavl_p.a OLD_FILES+=usr/lib32/libctf.a OLD_FILES+=usr/lib32/libctf.so OLD_LIBS+=usr/lib32/libctf.so.2 OLD_FILES+=usr/lib32/libctf_p.a OLD_FILES+=usr/lib32/libdtrace.a OLD_FILES+=usr/lib32/libdtrace.so OLD_LIBS+=usr/lib32/libdtrace.so.2 OLD_FILES+=usr/lib32/libdtrace_p.a OLD_FILES+=usr/lib32/libnvpair.a OLD_FILES+=usr/lib32/libnvpair.so OLD_LIBS+=usr/lib32/libnvpair.so.2 OLD_FILES+=usr/lib32/libnvpair_p.a OLD_FILES+=usr/lib32/libumem.a OLD_FILES+=usr/lib32/libumem.so OLD_LIBS+=usr/lib32/libumem.so.2 OLD_FILES+=usr/lib32/libumem_p.a OLD_FILES+=usr/lib32/libuutil.a OLD_FILES+=usr/lib32/libuutil.so OLD_LIBS+=usr/lib32/libuutil.so.2 OLD_FILES+=usr/lib32/libuutil_p.a .endif OLD_FILES+=usr/sbin/dtrace OLD_FILES+=usr/sbin/lockstat OLD_FILES+=usr/share/man/man1/dtrace.1.gz .endif .if ${MK_ZFS} == no OLD_FILES+=boot/gptzfsboot OLD_FILES+=boot/zfsboot OLD_FILES+=boot/zfsloader OLD_FILES+=etc/devd/zfs.conf OLD_FILES+=etc/periodic/daily/404.status-zfs OLD_FILES+=etc/periodic/daily/800.scrub-zfs OLD_LIBS+=lib/libzfs.so.2 OLD_LIBS+=lib/libzfs_core.so.2 OLD_LIBS+=lib/libzpool.so.2 OLD_FILES+=rescue/zfs OLD_FILES+=rescue/zpool OLD_FILES+=sbin/zfs OLD_FILES+=sbin/zpool OLD_FILES+=usr/bin/zinject OLD_FILES+=usr/bin/ztest OLD_FILES+=usr/lib/libzfs.a OLD_FILES+=usr/lib/libzfs.so OLD_FILES+=usr/lib/libzfs_core.a OLD_FILES+=usr/lib/libzfs_core.so OLD_FILES+=usr/lib/libzfs_core_p.a OLD_FILES+=usr/lib/libzfs_p.a OLD_FILES+=usr/lib/libzpool.a OLD_FILES+=usr/lib/libzpool.so .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libzfs.a OLD_FILES+=usr/lib32/libzfs.so OLD_LIBS+=usr/lib32/libzfs.so.2 OLD_FILES+=usr/lib32/libzfs_core.a OLD_FILES+=usr/lib32/libzfs_core.so OLD_LIBS+=usr/lib32/libzfs_core.so.2 OLD_FILES+=usr/lib32/libzfs_core_p.a OLD_FILES+=usr/lib32/libzfs_p.a OLD_FILES+=usr/lib32/libzpool.a OLD_FILES+=usr/lib32/libzpool.so OLD_LIBS+=usr/lib32/libzpool.so.2 .endif OLD_FILES+=usr/sbin/zdb OLD_FILES+=usr/share/man/man8/zdb.8.gz OLD_FILES+=usr/share/man/man8/zfs.8.gz OLD_FILES+=usr/share/man/man8/zpool.8.gz .endif .if ${MK_CLANG} == no OLD_FILES+=usr/bin/clang OLD_FILES+=usr/bin/clang++ OLD_FILES+=usr/bin/clang-cpp OLD_FILES+=usr/bin/clang-tblgen OLD_FILES+=usr/bin/tblgen OLD_FILES+=usr/include/clang/3.4.1/__wmmintrin_aes.h OLD_FILES+=usr/include/clang/3.4.1/__wmmintrin_pclmul.h OLD_FILES+=usr/include/clang/3.4.1/altivec.h OLD_FILES+=usr/include/clang/3.4.1/ammintrin.h OLD_FILES+=usr/include/clang/3.4.1/arm_neon.h OLD_FILES+=usr/include/clang/3.4.1/avx2intrin.h OLD_FILES+=usr/include/clang/3.4.1/avxintrin.h OLD_FILES+=usr/include/clang/3.4.1/bmi2intrin.h OLD_FILES+=usr/include/clang/3.4.1/bmiintrin.h OLD_FILES+=usr/include/clang/3.4.1/cpuid.h OLD_FILES+=usr/include/clang/3.4.1/emmintrin.h OLD_FILES+=usr/include/clang/3.4.1/f16cintrin.h OLD_FILES+=usr/include/clang/3.4.1/fma4intrin.h OLD_FILES+=usr/include/clang/3.4.1/fmaintrin.h OLD_FILES+=usr/include/clang/3.4.1/immintrin.h OLD_FILES+=usr/include/clang/3.4.1/lzcntintrin.h OLD_FILES+=usr/include/clang/3.4.1/mm3dnow.h OLD_FILES+=usr/include/clang/3.4.1/mm_malloc.h OLD_FILES+=usr/include/clang/3.4.1/mmintrin.h OLD_FILES+=usr/include/clang/3.4.1/module.map OLD_FILES+=usr/include/clang/3.4.1/nmmintrin.h OLD_FILES+=usr/include/clang/3.4.1/pmmintrin.h OLD_FILES+=usr/include/clang/3.4.1/popcntintrin.h OLD_FILES+=usr/include/clang/3.4.1/prfchwintrin.h OLD_FILES+=usr/include/clang/3.4.1/rdseedintrin.h OLD_FILES+=usr/include/clang/3.4.1/rtmintrin.h OLD_FILES+=usr/include/clang/3.4.1/shaintrin.h OLD_FILES+=usr/include/clang/3.4.1/smmintrin.h OLD_FILES+=usr/include/clang/3.4.1/tbmintrin.h OLD_FILES+=usr/include/clang/3.4.1/tmmintrin.h OLD_FILES+=usr/include/clang/3.4.1/wmmintrin.h OLD_FILES+=usr/include/clang/3.4.1/x86intrin.h OLD_FILES+=usr/include/clang/3.4.1/xmmintrin.h OLD_FILES+=usr/include/clang/3.4.1/xopintrin.h OLD_DIRS+=usr/include/clang/3.4.1 OLD_DIRS+=usr/include/clang OLD_FILES+=usr/share/doc/llvm/clang/LICENSE.TXT OLD_DIRS+=usr/share/doc/llvm/clang OLD_FILES+=usr/share/doc/llvm/COPYRIGHT.regex OLD_FILES+=usr/share/doc/llvm/LICENSE.TXT OLD_DIRS+=usr/share/doc/llvm OLD_FILES+=usr/share/man/man1/clang.1.gz OLD_FILES+=usr/share/man/man1/clang++.1.gz OLD_FILES+=usr/share/man/man1/clang-cpp.1.gz OLD_FILES+=usr/share/man/man1/tblgen.1.gz .endif .if ${MK_CLANG_EXTRAS} == no OLD_FILES+=usr/bin/bugpoint OLD_FILES+=usr/bin/llc OLD_FILES+=usr/bin/lli OLD_FILES+=usr/bin/llvm-ar OLD_FILES+=usr/bin/llvm-as OLD_FILES+=usr/bin/llvm-bcanalyzer OLD_FILES+=usr/bin/llvm-diff OLD_FILES+=usr/bin/llvm-dis OLD_FILES+=usr/bin/llvm-extract OLD_FILES+=usr/bin/llvm-ld OLD_FILES+=usr/bin/llvm-link OLD_FILES+=usr/bin/llvm-mc OLD_FILES+=usr/bin/llvm-nm OLD_FILES+=usr/bin/llvm-objdump OLD_FILES+=usr/bin/llvm-rtdyld OLD_FILES+=usr/bin/llvm-stub OLD_FILES+=usr/bin/macho-dump OLD_FILES+=usr/bin/opt OLD_FILES+=usr/share/man/man1/bugpoint.1.gz OLD_FILES+=usr/share/man/man1/llc.1.gz OLD_FILES+=usr/share/man/man1/lli.1.gz OLD_FILES+=usr/share/man/man1/llvm-ar.1.gz OLD_FILES+=usr/share/man/man1/llvm-as.1.gz OLD_FILES+=usr/share/man/man1/llvm-bcanalyzer.1.gz OLD_FILES+=usr/share/man/man1/llvm-diff.1.gz OLD_FILES+=usr/share/man/man1/llvm-dis.1.gz OLD_FILES+=usr/share/man/man1/llvm-extract.1.gz OLD_FILES+=usr/share/man/man1/llvm-ld.1.gz OLD_FILES+=usr/share/man/man1/llvm-link.1.gz OLD_FILES+=usr/share/man/man1/llvm-nm.1.gz OLD_FILES+=usr/share/man/man1/opt.1.gz .endif .if ${MK_CPP} == no OLD_FILES+=usr/bin/cpp OLD_FILES+=usr/share/man/man1/cpp.1.gz .endif #.if ${MK_CRYPT} == no # to be filled in #.endif .if ${MK_CTM} == no OLD_FILES+=usr/sbin/ctm OLD_FILES+=usr/sbin/ctm_dequeue OLD_FILES+=usr/sbin/ctm_rmail OLD_FILES+=usr/sbin/ctm_smail OLD_FILES+=usr/share/man/man1/ctm.1.gz OLD_FILES+=usr/share/man/man1/ctm_dequeue.1.gz OLD_FILES+=usr/share/man/man1/ctm_rmail.1.gz OLD_FILES+=usr/share/man/man1/ctm_smail.1.gz OLD_FILES+=usr/share/man/man5/ctm.5.gz .endif # devd(8) not listed here on purpose .if ${MK_CXX} == no OLD_FILES+=usr/bin/CC OLD_FILES+=usr/bin/c++ OLD_FILES+=usr/bin/c++filt OLD_FILES+=usr/bin/g++ OLD_FILES+=usr/libexec/cc1plus .if ${MK_GCC} == no OLD_FILES+=usr/bin/gperf OLD_FILES+=usr/share/info/gperf.info.gz OLD_FILES+=usr/share/man/man1/gperf.1.gz .endif .endif .if ${MK_FMTREE} == no OLD_FILES+=usr/sbin/fmtree OLD_FILES+=usr/share/man/man8/fmtree.8.gz .endif .if ${MK_GNUCXX} == no OLD_FILES+=usr/bin/g++ OLD_FILES+=usr/include/c++/4.2/algorithm OLD_FILES+=usr/include/c++/4.2/backward/algo.h OLD_FILES+=usr/include/c++/4.2/backward/algobase.h OLD_FILES+=usr/include/c++/4.2/backward/alloc.h OLD_FILES+=usr/include/c++/4.2/backward/backward_warning.h OLD_FILES+=usr/include/c++/4.2/backward/bvector.h OLD_FILES+=usr/include/c++/4.2/backward/complex.h OLD_FILES+=usr/include/c++/4.2/backward/defalloc.h OLD_FILES+=usr/include/c++/4.2/backward/deque.h OLD_FILES+=usr/include/c++/4.2/backward/fstream.h OLD_FILES+=usr/include/c++/4.2/backward/function.h OLD_FILES+=usr/include/c++/4.2/backward/hash_map.h OLD_FILES+=usr/include/c++/4.2/backward/hash_set.h OLD_FILES+=usr/include/c++/4.2/backward/hashtable.h OLD_FILES+=usr/include/c++/4.2/backward/heap.h OLD_FILES+=usr/include/c++/4.2/backward/iomanip.h OLD_FILES+=usr/include/c++/4.2/backward/iostream.h OLD_FILES+=usr/include/c++/4.2/backward/istream.h OLD_FILES+=usr/include/c++/4.2/backward/iterator.h OLD_FILES+=usr/include/c++/4.2/backward/list.h OLD_FILES+=usr/include/c++/4.2/backward/map.h OLD_FILES+=usr/include/c++/4.2/backward/multimap.h OLD_FILES+=usr/include/c++/4.2/backward/multiset.h OLD_FILES+=usr/include/c++/4.2/backward/new.h OLD_FILES+=usr/include/c++/4.2/backward/ostream.h OLD_FILES+=usr/include/c++/4.2/backward/pair.h OLD_FILES+=usr/include/c++/4.2/backward/queue.h OLD_FILES+=usr/include/c++/4.2/backward/rope.h OLD_FILES+=usr/include/c++/4.2/backward/set.h OLD_FILES+=usr/include/c++/4.2/backward/slist.h OLD_FILES+=usr/include/c++/4.2/backward/stack.h OLD_FILES+=usr/include/c++/4.2/backward/stream.h OLD_FILES+=usr/include/c++/4.2/backward/streambuf.h OLD_FILES+=usr/include/c++/4.2/backward/strstream OLD_FILES+=usr/include/c++/4.2/backward/tempbuf.h OLD_FILES+=usr/include/c++/4.2/backward/tree.h OLD_FILES+=usr/include/c++/4.2/backward/vector.h OLD_FILES+=usr/include/c++/4.2/bits/allocator.h OLD_FILES+=usr/include/c++/4.2/bits/atomic_word.h OLD_FILES+=usr/include/c++/4.2/bits/basic_file.h OLD_FILES+=usr/include/c++/4.2/bits/basic_ios.h OLD_FILES+=usr/include/c++/4.2/bits/basic_ios.tcc OLD_FILES+=usr/include/c++/4.2/bits/basic_string.h OLD_FILES+=usr/include/c++/4.2/bits/basic_string.tcc OLD_FILES+=usr/include/c++/4.2/bits/boost_concept_check.h OLD_FILES+=usr/include/c++/4.2/bits/c++allocator.h OLD_FILES+=usr/include/c++/4.2/bits/c++config.h OLD_FILES+=usr/include/c++/4.2/bits/c++io.h OLD_FILES+=usr/include/c++/4.2/bits/c++locale.h OLD_FILES+=usr/include/c++/4.2/bits/c++locale_internal.h OLD_FILES+=usr/include/c++/4.2/bits/char_traits.h OLD_FILES+=usr/include/c++/4.2/bits/cmath.tcc OLD_FILES+=usr/include/c++/4.2/bits/codecvt.h OLD_FILES+=usr/include/c++/4.2/bits/compatibility.h OLD_FILES+=usr/include/c++/4.2/bits/concept_check.h OLD_FILES+=usr/include/c++/4.2/bits/cpp_type_traits.h OLD_FILES+=usr/include/c++/4.2/bits/cpu_defines.h OLD_FILES+=usr/include/c++/4.2/bits/ctype_base.h OLD_FILES+=usr/include/c++/4.2/bits/ctype_inline.h OLD_FILES+=usr/include/c++/4.2/bits/ctype_noninline.h OLD_FILES+=usr/include/c++/4.2/bits/cxxabi_tweaks.h OLD_FILES+=usr/include/c++/4.2/bits/deque.tcc OLD_FILES+=usr/include/c++/4.2/bits/fstream.tcc OLD_FILES+=usr/include/c++/4.2/bits/functexcept.h OLD_FILES+=usr/include/c++/4.2/bits/gslice.h OLD_FILES+=usr/include/c++/4.2/bits/gslice_array.h OLD_FILES+=usr/include/c++/4.2/bits/gthr-default.h OLD_FILES+=usr/include/c++/4.2/bits/gthr-posix.h OLD_FILES+=usr/include/c++/4.2/bits/gthr-single.h OLD_FILES+=usr/include/c++/4.2/bits/gthr-tpf.h OLD_FILES+=usr/include/c++/4.2/bits/gthr.h OLD_FILES+=usr/include/c++/4.2/bits/indirect_array.h OLD_FILES+=usr/include/c++/4.2/bits/ios_base.h OLD_FILES+=usr/include/c++/4.2/bits/istream.tcc OLD_FILES+=usr/include/c++/4.2/bits/list.tcc OLD_FILES+=usr/include/c++/4.2/bits/locale_classes.h OLD_FILES+=usr/include/c++/4.2/bits/locale_facets.h OLD_FILES+=usr/include/c++/4.2/bits/locale_facets.tcc OLD_FILES+=usr/include/c++/4.2/bits/localefwd.h OLD_FILES+=usr/include/c++/4.2/bits/mask_array.h OLD_FILES+=usr/include/c++/4.2/bits/messages_members.h OLD_FILES+=usr/include/c++/4.2/bits/os_defines.h OLD_FILES+=usr/include/c++/4.2/bits/ostream.tcc OLD_FILES+=usr/include/c++/4.2/bits/ostream_insert.h OLD_FILES+=usr/include/c++/4.2/bits/postypes.h OLD_FILES+=usr/include/c++/4.2/bits/slice_array.h OLD_FILES+=usr/include/c++/4.2/bits/sstream.tcc OLD_FILES+=usr/include/c++/4.2/bits/stl_algo.h OLD_FILES+=usr/include/c++/4.2/bits/stl_algobase.h OLD_FILES+=usr/include/c++/4.2/bits/stl_bvector.h OLD_FILES+=usr/include/c++/4.2/bits/stl_construct.h OLD_FILES+=usr/include/c++/4.2/bits/stl_deque.h OLD_FILES+=usr/include/c++/4.2/bits/stl_function.h OLD_FILES+=usr/include/c++/4.2/bits/stl_heap.h OLD_FILES+=usr/include/c++/4.2/bits/stl_iterator.h OLD_FILES+=usr/include/c++/4.2/bits/stl_iterator_base_funcs.h OLD_FILES+=usr/include/c++/4.2/bits/stl_iterator_base_types.h OLD_FILES+=usr/include/c++/4.2/bits/stl_list.h OLD_FILES+=usr/include/c++/4.2/bits/stl_map.h OLD_FILES+=usr/include/c++/4.2/bits/stl_multimap.h OLD_FILES+=usr/include/c++/4.2/bits/stl_multiset.h OLD_FILES+=usr/include/c++/4.2/bits/stl_numeric.h OLD_FILES+=usr/include/c++/4.2/bits/stl_pair.h OLD_FILES+=usr/include/c++/4.2/bits/stl_queue.h OLD_FILES+=usr/include/c++/4.2/bits/stl_raw_storage_iter.h OLD_FILES+=usr/include/c++/4.2/bits/stl_relops.h OLD_FILES+=usr/include/c++/4.2/bits/stl_set.h OLD_FILES+=usr/include/c++/4.2/bits/stl_stack.h OLD_FILES+=usr/include/c++/4.2/bits/stl_tempbuf.h OLD_FILES+=usr/include/c++/4.2/bits/stl_tree.h OLD_FILES+=usr/include/c++/4.2/bits/stl_uninitialized.h OLD_FILES+=usr/include/c++/4.2/bits/stl_vector.h OLD_FILES+=usr/include/c++/4.2/bits/stream_iterator.h OLD_FILES+=usr/include/c++/4.2/bits/streambuf.tcc OLD_FILES+=usr/include/c++/4.2/bits/streambuf_iterator.h OLD_FILES+=usr/include/c++/4.2/bits/stringfwd.h OLD_FILES+=usr/include/c++/4.2/bits/time_members.h OLD_FILES+=usr/include/c++/4.2/bits/valarray_after.h OLD_FILES+=usr/include/c++/4.2/bits/valarray_array.h OLD_FILES+=usr/include/c++/4.2/bits/valarray_array.tcc OLD_FILES+=usr/include/c++/4.2/bits/valarray_before.h OLD_FILES+=usr/include/c++/4.2/bits/vector.tcc OLD_FILES+=usr/include/c++/4.2/bitset OLD_FILES+=usr/include/c++/4.2/cassert OLD_FILES+=usr/include/c++/4.2/cctype OLD_FILES+=usr/include/c++/4.2/cerrno OLD_FILES+=usr/include/c++/4.2/cfloat OLD_FILES+=usr/include/c++/4.2/ciso646 OLD_FILES+=usr/include/c++/4.2/climits OLD_FILES+=usr/include/c++/4.2/clocale OLD_FILES+=usr/include/c++/4.2/cmath OLD_FILES+=usr/include/c++/4.2/complex OLD_FILES+=usr/include/c++/4.2/csetjmp OLD_FILES+=usr/include/c++/4.2/csignal OLD_FILES+=usr/include/c++/4.2/cstdarg OLD_FILES+=usr/include/c++/4.2/cstddef OLD_FILES+=usr/include/c++/4.2/cstdio OLD_FILES+=usr/include/c++/4.2/cstdlib OLD_FILES+=usr/include/c++/4.2/cstring OLD_FILES+=usr/include/c++/4.2/ctime OLD_FILES+=usr/include/c++/4.2/cwchar OLD_FILES+=usr/include/c++/4.2/cwctype OLD_FILES+=usr/include/c++/4.2/cxxabi.h OLD_FILES+=usr/include/c++/4.2/debug/bitset OLD_FILES+=usr/include/c++/4.2/debug/debug.h OLD_FILES+=usr/include/c++/4.2/debug/deque OLD_FILES+=usr/include/c++/4.2/debug/formatter.h OLD_FILES+=usr/include/c++/4.2/debug/functions.h OLD_FILES+=usr/include/c++/4.2/debug/hash_map OLD_FILES+=usr/include/c++/4.2/debug/hash_map.h OLD_FILES+=usr/include/c++/4.2/debug/hash_multimap.h OLD_FILES+=usr/include/c++/4.2/debug/hash_multiset.h OLD_FILES+=usr/include/c++/4.2/debug/hash_set OLD_FILES+=usr/include/c++/4.2/debug/hash_set.h OLD_FILES+=usr/include/c++/4.2/debug/list OLD_FILES+=usr/include/c++/4.2/debug/macros.h OLD_FILES+=usr/include/c++/4.2/debug/map OLD_FILES+=usr/include/c++/4.2/debug/map.h OLD_FILES+=usr/include/c++/4.2/debug/multimap.h OLD_FILES+=usr/include/c++/4.2/debug/multiset.h OLD_FILES+=usr/include/c++/4.2/debug/safe_base.h OLD_FILES+=usr/include/c++/4.2/debug/safe_iterator.h OLD_FILES+=usr/include/c++/4.2/debug/safe_iterator.tcc OLD_FILES+=usr/include/c++/4.2/debug/safe_sequence.h OLD_FILES+=usr/include/c++/4.2/debug/set OLD_FILES+=usr/include/c++/4.2/debug/set.h OLD_FILES+=usr/include/c++/4.2/debug/string OLD_FILES+=usr/include/c++/4.2/debug/vector OLD_FILES+=usr/include/c++/4.2/deque OLD_FILES+=usr/include/c++/4.2/exception OLD_FILES+=usr/include/c++/4.2/exception_defines.h OLD_FILES+=usr/include/c++/4.2/ext/algorithm OLD_FILES+=usr/include/c++/4.2/ext/array_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/atomicity.h OLD_FILES+=usr/include/c++/4.2/ext/bitmap_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/codecvt_specializations.h OLD_FILES+=usr/include/c++/4.2/ext/concurrence.h OLD_FILES+=usr/include/c++/4.2/ext/debug_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/functional OLD_FILES+=usr/include/c++/4.2/ext/hash_fun.h OLD_FILES+=usr/include/c++/4.2/ext/hash_map OLD_FILES+=usr/include/c++/4.2/ext/hash_set OLD_FILES+=usr/include/c++/4.2/ext/hashtable.h OLD_FILES+=usr/include/c++/4.2/ext/iterator OLD_FILES+=usr/include/c++/4.2/ext/malloc_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/memory OLD_FILES+=usr/include/c++/4.2/ext/mt_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/new_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/numeric OLD_FILES+=usr/include/c++/4.2/ext/numeric_traits.h OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/assoc_container.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/basic_tree_policy/basic_tree_policy_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/basic_tree_policy/null_node_metadata.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/basic_tree_policy/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/basic_types.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/cond_dtor_entry_dealtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/cond_key_dtor_entry_dealtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/bin_search_tree_/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/const_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/const_point_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/entry_cmp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/entry_pred.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/resize_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/standard_policies.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cc_hash_table_map_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/cond_dealtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/container_base_dispatch.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/eq_fn/eq_by_less.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/eq_fn/hash_eq_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/debug_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/debug_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/erase_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/erase_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/find_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/find_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/insert_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/insert_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/iterator_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/resize_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/resize_no_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/resize_store_hash_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/standard_policies.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/gp_hash_table_map_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/direct_mask_range_hashing_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/direct_mod_range_hashing_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/linear_probe_fn_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/mask_based_range_hashing.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/mod_based_range_hashing.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/probe_fn_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/quadratic_probe_fn_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/ranged_hash_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/ranged_probe_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/sample_probe_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/sample_range_hashing.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/sample_ranged_hash_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/hash_fn/sample_ranged_probe_fn.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/const_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/const_point_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/node.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/null_metadata.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/left_child_next_sibling_heap_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/constructor_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/entry_metadata_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/lu_map_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_map_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_policy/counter_lu_metadata.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_policy/counter_lu_policy_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_policy/mtf_lu_policy_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/list_update_policy/sample_update_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/map_debug_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/cond_dtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/node_iterators.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/ov_tree_map_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/ov_tree_map_/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/child_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/cond_dtor_entry_dealtor.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/const_child_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/head.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/internal_node.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/leaf.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/node_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/node_iterators.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/node_metadata_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/pat_trie_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/point_iterators.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/split_join_branch_bag.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/synth_e_access_traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/priority_queue_base_dispatch.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/node.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rb_tree_map_/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/rc.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/resize_policy/sample_size_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/node.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/splay_tree_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/splay_tree_/traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/standard_policies.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/thin_heap_.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/tree_policy/null_node_update_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/tree_trace_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/null_node_update_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/sample_trie_e_access_traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/string_trie_e_access_traits_imp.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/trie_policy/trie_policy_base.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/type_utils.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/types_traits.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/unordered_iterator/const_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/unordered_iterator/const_point_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/unordered_iterator/iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/detail/unordered_iterator/point_iterator.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/exception.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/hash_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/list_update_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/priority_queue.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/tag_and_trait.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/tree_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pb_ds/trie_policy.hpp OLD_FILES+=usr/include/c++/4.2/ext/pod_char_traits.h OLD_FILES+=usr/include/c++/4.2/ext/pool_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/rb_tree OLD_FILES+=usr/include/c++/4.2/ext/rc_string_base.h OLD_FILES+=usr/include/c++/4.2/ext/rope OLD_FILES+=usr/include/c++/4.2/ext/ropeimpl.h OLD_FILES+=usr/include/c++/4.2/ext/slist OLD_FILES+=usr/include/c++/4.2/ext/sso_string_base.h OLD_FILES+=usr/include/c++/4.2/ext/stdio_filebuf.h OLD_FILES+=usr/include/c++/4.2/ext/stdio_sync_filebuf.h OLD_FILES+=usr/include/c++/4.2/ext/throw_allocator.h OLD_FILES+=usr/include/c++/4.2/ext/type_traits.h OLD_FILES+=usr/include/c++/4.2/ext/typelist.h OLD_FILES+=usr/include/c++/4.2/ext/vstring.h OLD_FILES+=usr/include/c++/4.2/ext/vstring.tcc OLD_FILES+=usr/include/c++/4.2/ext/vstring_fwd.h OLD_FILES+=usr/include/c++/4.2/ext/vstring_util.h OLD_FILES+=usr/include/c++/4.2/fstream OLD_FILES+=usr/include/c++/4.2/functional OLD_FILES+=usr/include/c++/4.2/iomanip OLD_FILES+=usr/include/c++/4.2/ios OLD_FILES+=usr/include/c++/4.2/iosfwd OLD_FILES+=usr/include/c++/4.2/iostream OLD_FILES+=usr/include/c++/4.2/istream OLD_FILES+=usr/include/c++/4.2/iterator OLD_FILES+=usr/include/c++/4.2/limits OLD_FILES+=usr/include/c++/4.2/list OLD_FILES+=usr/include/c++/4.2/locale OLD_FILES+=usr/include/c++/4.2/map OLD_FILES+=usr/include/c++/4.2/memory OLD_FILES+=usr/include/c++/4.2/new OLD_FILES+=usr/include/c++/4.2/numeric OLD_FILES+=usr/include/c++/4.2/ostream OLD_FILES+=usr/include/c++/4.2/queue OLD_FILES+=usr/include/c++/4.2/set OLD_FILES+=usr/include/c++/4.2/sstream OLD_FILES+=usr/include/c++/4.2/stack OLD_FILES+=usr/include/c++/4.2/stdexcept OLD_FILES+=usr/include/c++/4.2/streambuf OLD_FILES+=usr/include/c++/4.2/string OLD_FILES+=usr/include/c++/4.2/tr1/array OLD_FILES+=usr/include/c++/4.2/tr1/bind_iterate.h OLD_FILES+=usr/include/c++/4.2/tr1/bind_repeat.h OLD_FILES+=usr/include/c++/4.2/tr1/boost_shared_ptr.h OLD_FILES+=usr/include/c++/4.2/tr1/cctype OLD_FILES+=usr/include/c++/4.2/tr1/cfenv OLD_FILES+=usr/include/c++/4.2/tr1/cfloat OLD_FILES+=usr/include/c++/4.2/tr1/cinttypes OLD_FILES+=usr/include/c++/4.2/tr1/climits OLD_FILES+=usr/include/c++/4.2/tr1/cmath OLD_FILES+=usr/include/c++/4.2/tr1/common.h OLD_FILES+=usr/include/c++/4.2/tr1/complex OLD_FILES+=usr/include/c++/4.2/tr1/cstdarg OLD_FILES+=usr/include/c++/4.2/tr1/cstdbool OLD_FILES+=usr/include/c++/4.2/tr1/cstdint OLD_FILES+=usr/include/c++/4.2/tr1/cstdio OLD_FILES+=usr/include/c++/4.2/tr1/cstdlib OLD_FILES+=usr/include/c++/4.2/tr1/ctgmath OLD_FILES+=usr/include/c++/4.2/tr1/ctime OLD_FILES+=usr/include/c++/4.2/tr1/ctype.h OLD_FILES+=usr/include/c++/4.2/tr1/cwchar OLD_FILES+=usr/include/c++/4.2/tr1/cwctype OLD_FILES+=usr/include/c++/4.2/tr1/fenv.h OLD_FILES+=usr/include/c++/4.2/tr1/float.h OLD_FILES+=usr/include/c++/4.2/tr1/functional OLD_FILES+=usr/include/c++/4.2/tr1/functional_hash.h OLD_FILES+=usr/include/c++/4.2/tr1/functional_iterate.h OLD_FILES+=usr/include/c++/4.2/tr1/hashtable OLD_FILES+=usr/include/c++/4.2/tr1/hashtable_policy.h OLD_FILES+=usr/include/c++/4.2/tr1/inttypes.h OLD_FILES+=usr/include/c++/4.2/tr1/limits.h OLD_FILES+=usr/include/c++/4.2/tr1/math.h OLD_FILES+=usr/include/c++/4.2/tr1/memory OLD_FILES+=usr/include/c++/4.2/tr1/mu_iterate.h OLD_FILES+=usr/include/c++/4.2/tr1/random OLD_FILES+=usr/include/c++/4.2/tr1/random.tcc OLD_FILES+=usr/include/c++/4.2/tr1/ref_fwd.h OLD_FILES+=usr/include/c++/4.2/tr1/ref_wrap_iterate.h OLD_FILES+=usr/include/c++/4.2/tr1/repeat.h OLD_FILES+=usr/include/c++/4.2/tr1/stdarg.h OLD_FILES+=usr/include/c++/4.2/tr1/stdbool.h OLD_FILES+=usr/include/c++/4.2/tr1/stdint.h OLD_FILES+=usr/include/c++/4.2/tr1/stdio.h OLD_FILES+=usr/include/c++/4.2/tr1/stdlib.h OLD_FILES+=usr/include/c++/4.2/tr1/tgmath.h OLD_FILES+=usr/include/c++/4.2/tr1/tuple OLD_FILES+=usr/include/c++/4.2/tr1/tuple_defs.h OLD_FILES+=usr/include/c++/4.2/tr1/tuple_iterate.h OLD_FILES+=usr/include/c++/4.2/tr1/type_traits OLD_FILES+=usr/include/c++/4.2/tr1/type_traits_fwd.h OLD_FILES+=usr/include/c++/4.2/tr1/unordered_map OLD_FILES+=usr/include/c++/4.2/tr1/unordered_set OLD_FILES+=usr/include/c++/4.2/tr1/utility OLD_FILES+=usr/include/c++/4.2/tr1/wchar.h OLD_FILES+=usr/include/c++/4.2/tr1/wctype.h OLD_FILES+=usr/include/c++/4.2/typeinfo OLD_FILES+=usr/include/c++/4.2/utility OLD_FILES+=usr/include/c++/4.2/valarray OLD_FILES+=usr/include/c++/4.2/vector OLD_FILES+=usr/lib/libstdc++.a OLD_FILES+=usr/lib/libstdc++.so OLD_LIBS+=usr/lib/libstdc++.so.6 OLD_FILES+=usr/lib/libstdc++_p.a OLD_FILES+=usr/lib/libsupc++.a OLD_FILES+=usr/lib/libsupc++.so OLD_LIBS+=usr/lib/libsupc++.so.1 OLD_FILES+=usr/lib/libsupc++_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libstdc++.a OLD_FILES+=usr/lib32/libstdc++.so OLD_LIBS+=usr/lib32/libstdc++.so.6 OLD_FILES+=usr/lib32/libstdc++_p.a OLD_FILES+=usr/lib32/libsupc++.a OLD_FILES+=usr/lib32/libsupc++.so OLD_LIBS+=usr/lib32/libsupc++.so.1 OLD_FILES+=usr/lib32/libsupc++_p.a .endif OLD_FILES+=usr/libexec/cc1plus .endif .if ${MK_DICT} == no OLD_FILES+=usr/share/dict/README OLD_FILES+=usr/share/dict/eign OLD_FILES+=usr/share/dict/freebsd OLD_FILES+=usr/share/dict/propernames OLD_FILES+=usr/share/dict/web2 OLD_FILES+=usr/share/dict/web2a OLD_FILES+=usr/share/dict/words OLD_DIRS+=usr/share/dict .endif #.if ${MK_EXAMPLES} == no # to be filled in #.endif .if ${MK_FLOPPY} == no OLD_FILES+=usr/sbin/fdcontrol OLD_FILES+=usr/sbin/fdformat OLD_FILES+=usr/sbin/fdread OLD_FILES+=usr/sbin/fdwrite OLD_FILES+=usr/share/man/man1/fdformat.1.gz OLD_FILES+=usr/share/man/man1/fdread.1.gz OLD_FILES+=usr/share/man/man1/fdwrite.1.gz OLD_FILES+=usr/share/man/man8/fdcontrol.8.gz .endif .if ${MK_FREEBSD_UPDATE} == no OLD_FILES+=etc/freebsd-update.conf OLD_FILES+=usr/sbin/freebsd-update OLD_FILES+=usr/share/examples/etc/freebsd-update.conf OLD_FILES+=usr/share/man/man5/freebsd-update.conf.5.gz OLD_FILES+=usr/share/man/man8/freebsd-update.8.gz .endif .if ${MK_GAMES} == no OLD_FILES+=usr/games/bcd OLD_FILES+=usr/games/caesar OLD_FILES+=usr/games/factor OLD_FILES+=usr/games/fortune OLD_FILES+=usr/games/grdc OLD_FILES+=usr/games/morse OLD_FILES+=usr/games/number OLD_FILES+=usr/games/pom OLD_FILES+=usr/games/ppt OLD_FILES+=usr/games/primes OLD_FILES+=usr/games/random OLD_FILES+=usr/games/rot13 OLD_FILES+=usr/games/strfile OLD_FILES+=usr/games/unstr OLD_DIRS+=usr/games OLD_FILES+=usr/share/games/fortune/fortunes OLD_FILES+=usr/share/games/fortune/fortunes.dat OLD_FILES+=usr/share/games/fortune/freebsd-tips OLD_FILES+=usr/share/games/fortune/freebsd-tips.dat OLD_FILES+=usr/share/games/fortune/gerrold.limerick OLD_FILES+=usr/share/games/fortune/gerrold.limerick.dat OLD_FILES+=usr/share/games/fortune/limerick OLD_FILES+=usr/share/games/fortune/limerick.dat OLD_FILES+=usr/share/games/fortune/murphy OLD_FILES+=usr/share/games/fortune/murphy-o OLD_FILES+=usr/share/games/fortune/murphy-o.dat OLD_FILES+=usr/share/games/fortune/murphy.dat OLD_FILES+=usr/share/games/fortune/startrek OLD_FILES+=usr/share/games/fortune/startrek.dat OLD_FILES+=usr/share/games/fortune/zippy OLD_FILES+=usr/share/games/fortune/zippy.dat OLD_DIRS+=usr/share/games/fortune OLD_DIRS+=usr/share/games OLD_FILES+=usr/share/man/man6/bcd.6.gz OLD_FILES+=usr/share/man/man6/caesar.6.gz OLD_FILES+=usr/share/man/man6/factor.6.gz OLD_FILES+=usr/share/man/man6/fortune.6.gz OLD_FILES+=usr/share/man/man6/grdc.6.gz OLD_FILES+=usr/share/man/man6/morse.6.gz OLD_FILES+=usr/share/man/man6/number.6.gz OLD_FILES+=usr/share/man/man6/pom.6.gz OLD_FILES+=usr/share/man/man6/ppt.6.gz OLD_FILES+=usr/share/man/man6/primes.6.gz OLD_FILES+=usr/share/man/man6/random.6.gz OLD_FILES+=usr/share/man/man6/rot13.6.gz OLD_FILES+=usr/share/man/man8/strfile.8.gz OLD_FILES+=usr/share/man/man8/unstr.8.gz .endif .if ${MK_GCC} == no OLD_FILES+=usr/bin/c++filt OLD_FILES+=usr/bin/g++ OLD_FILES+=usr/bin/gcc OLD_FILES+=usr/bin/gcov OLD_FILES+=usr/bin/gcpp .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386" OLD_FILES+=usr/include/gcc/4.2/__wmmintrin_aes.h OLD_FILES+=usr/include/gcc/4.2/__wmmintrin_pclmul.h OLD_FILES+=usr/include/gcc/4.2/ammintrin.h OLD_FILES+=usr/include/gcc/4.2/emmintrin.h OLD_FILES+=usr/include/gcc/4.2/mm3dnow.h OLD_FILES+=usr/include/gcc/4.2/mm_malloc.h OLD_FILES+=usr/include/gcc/4.2/mmintrin.h OLD_FILES+=usr/include/gcc/4.2/pmmintrin.h OLD_FILES+=usr/include/gcc/4.2/tmmintrin.h OLD_FILES+=usr/include/gcc/4.2/wmmintrin.h OLD_FILES+=usr/include/gcc/4.2/xmmintrin.h .elif ${TARGET_ARCH} == "arm" OLD_FILES+=usr/include/gcc/4.2/mmintrin.h .elif ${TARGET_ARCH} == "powerpc" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/include/gcc/4.2/altivec.h OLD_FILES+=usr/include/gcc/4.2/ppc-asm.h OLD_FILES+=usr/include/gcc/4.2/spe.h .endif OLD_FILES+=usr/libexec/cc1 OLD_FILES+=usr/libexec/cc1plus OLD_FILES+=usr/share/info/cpp.info.gz OLD_FILES+=usr/share/info/cppinternals.info.gz OLD_FILES+=usr/share/info/gcc.info.gz OLD_FILES+=usr/share/info/gccint.info.gz OLD_FILES+=usr/share/man/man1/g++.1.gz OLD_FILES+=usr/share/man/man1/gcc.1.gz OLD_FILES+=usr/share/man/man1/gcov.1.gz OLD_FILES+=usr/share/man/man1/gcpp.1.gz .endif .if ${MK_GCOV} == no OLD_FILES+=usr/bin/gcov OLD_FILES+=usr/share/man/man1/gcov.1.gz .endif .if ${MK_GDB} == no OLD_FILES+=usr/bin/gdb OLD_FILES+=usr/bin/gdbserver OLD_FILES+=usr/bin/gdbtui OLD_FILES+=usr/bin/kgdb OLD_FILES+=usr/share/info/gdb.info.gz OLD_FILES+=usr/share/info/gdbint.info.gz OLD_FILES+=usr/share/info/stabs.info.gz OLD_FILES+=usr/share/man/man1/gdb.1.gz OLD_FILES+=usr/share/man/man1/gdbserver.1.gz OLD_FILES+=usr/share/man/man1/kgdb.1.gz .endif .if ${MK_GPIB} == no OLD_FILES+=usr/include/dev/ieee488/ibfoo_int.h OLD_FILES+=usr/include/dev/ieee488/tnt4882.h OLD_FILES+=usr/include/dev/ieee488/ugpib.h OLD_FILES+=usr/include/dev/ieee488/upd7210.h OLD_DIRS+=usr/include/dev/ieee488 OLD_FILES+=usr/include/gpib/gpib.h OLD_DIRS+=usr/include/gpib OLD_FILES+=usr/lib/libgpib.a OLD_FILES+=usr/lib/libgpib.so OLD_LIBS+=usr/lib/libgpib.so.3 OLD_FILES+=usr/lib/libgpib_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libgpib.a OLD_FILES+=usr/lib32/libgpib.so OLD_LIBS+=usr/lib32/libgpib.so.3 OLD_FILES+=usr/lib32/libgpib_p.a .endif .endif .if ${MK_GPIO} == no OLD_FILES+=usr/sbin/gpioctl OLD_FILES+=usr/share/man/man8/gpioctl.8.gz .endif # Also includes vgrind(1) .if ${MK_GROFF} == no OLD_FILES+=usr/bin/addftinfo OLD_FILES+=usr/bin/afmtodit OLD_FILES+=usr/bin/eqn OLD_FILES+=usr/bin/grn OLD_FILES+=usr/bin/grodvi OLD_FILES+=usr/bin/groff OLD_FILES+=usr/bin/grog OLD_FILES+=usr/bin/grolbp OLD_FILES+=usr/bin/grolj4 OLD_FILES+=usr/bin/grops OLD_FILES+=usr/bin/grotty OLD_FILES+=usr/bin/hpftodit OLD_FILES+=usr/bin/indxbib OLD_FILES+=usr/bin/lkbib OLD_FILES+=usr/bin/lookbib OLD_FILES+=usr/bin/mmroff OLD_FILES+=usr/bin/neqn OLD_FILES+=usr/bin/nroff OLD_FILES+=usr/bin/pfbtops OLD_FILES+=usr/bin/pic OLD_FILES+=usr/bin/post-grohtml OLD_FILES+=usr/bin/pre-grohtml OLD_FILES+=usr/bin/psroff OLD_FILES+=usr/bin/refer OLD_FILES+=usr/bin/soelim OLD_FILES+=usr/bin/tbl OLD_FILES+=usr/bin/tfmtodit OLD_FILES+=usr/bin/troff OLD_FILES+=usr/bin/vgrind OLD_FILES+=usr/libexec/vfontedpr OLD_FILES+=usr/share/groff_font/devX100-12/CB OLD_FILES+=usr/share/groff_font/devX100-12/CBI OLD_FILES+=usr/share/groff_font/devX100-12/CI OLD_FILES+=usr/share/groff_font/devX100-12/CR OLD_FILES+=usr/share/groff_font/devX100-12/DESC OLD_FILES+=usr/share/groff_font/devX100-12/HB OLD_FILES+=usr/share/groff_font/devX100-12/HBI OLD_FILES+=usr/share/groff_font/devX100-12/HI OLD_FILES+=usr/share/groff_font/devX100-12/HR OLD_FILES+=usr/share/groff_font/devX100-12/NB OLD_FILES+=usr/share/groff_font/devX100-12/NBI OLD_FILES+=usr/share/groff_font/devX100-12/NI OLD_FILES+=usr/share/groff_font/devX100-12/NR OLD_FILES+=usr/share/groff_font/devX100-12/S OLD_FILES+=usr/share/groff_font/devX100-12/TB OLD_FILES+=usr/share/groff_font/devX100-12/TBI OLD_FILES+=usr/share/groff_font/devX100-12/TI OLD_FILES+=usr/share/groff_font/devX100-12/TR OLD_DIRS+=usr/share/groff_font/devX100-12 OLD_FILES+=usr/share/groff_font/devX100/CB OLD_FILES+=usr/share/groff_font/devX100/CBI OLD_FILES+=usr/share/groff_font/devX100/CI OLD_FILES+=usr/share/groff_font/devX100/CR OLD_FILES+=usr/share/groff_font/devX100/DESC OLD_FILES+=usr/share/groff_font/devX100/HB OLD_FILES+=usr/share/groff_font/devX100/HBI OLD_FILES+=usr/share/groff_font/devX100/HI OLD_FILES+=usr/share/groff_font/devX100/HR OLD_FILES+=usr/share/groff_font/devX100/NB OLD_FILES+=usr/share/groff_font/devX100/NBI OLD_FILES+=usr/share/groff_font/devX100/NI OLD_FILES+=usr/share/groff_font/devX100/NR OLD_FILES+=usr/share/groff_font/devX100/S OLD_FILES+=usr/share/groff_font/devX100/TB OLD_FILES+=usr/share/groff_font/devX100/TBI OLD_FILES+=usr/share/groff_font/devX100/TI OLD_FILES+=usr/share/groff_font/devX100/TR OLD_DIRS+=usr/share/groff_font/devX100 OLD_FILES+=usr/share/groff_font/devX75-12/CB OLD_FILES+=usr/share/groff_font/devX75-12/CBI OLD_FILES+=usr/share/groff_font/devX75-12/CI OLD_FILES+=usr/share/groff_font/devX75-12/CR OLD_FILES+=usr/share/groff_font/devX75-12/DESC OLD_FILES+=usr/share/groff_font/devX75-12/HB OLD_FILES+=usr/share/groff_font/devX75-12/HBI OLD_FILES+=usr/share/groff_font/devX75-12/HI OLD_FILES+=usr/share/groff_font/devX75-12/HR OLD_FILES+=usr/share/groff_font/devX75-12/NB OLD_FILES+=usr/share/groff_font/devX75-12/NBI OLD_FILES+=usr/share/groff_font/devX75-12/NI OLD_FILES+=usr/share/groff_font/devX75-12/NR OLD_FILES+=usr/share/groff_font/devX75-12/S OLD_FILES+=usr/share/groff_font/devX75-12/TB OLD_FILES+=usr/share/groff_font/devX75-12/TBI OLD_FILES+=usr/share/groff_font/devX75-12/TI OLD_FILES+=usr/share/groff_font/devX75-12/TR OLD_DIRS+=usr/share/groff_font/devX75-12 OLD_FILES+=usr/share/groff_font/devX75/CB OLD_FILES+=usr/share/groff_font/devX75/CBI OLD_FILES+=usr/share/groff_font/devX75/CI OLD_FILES+=usr/share/groff_font/devX75/CR OLD_FILES+=usr/share/groff_font/devX75/DESC OLD_FILES+=usr/share/groff_font/devX75/HB OLD_FILES+=usr/share/groff_font/devX75/HBI OLD_FILES+=usr/share/groff_font/devX75/HI OLD_FILES+=usr/share/groff_font/devX75/HR OLD_FILES+=usr/share/groff_font/devX75/NB OLD_FILES+=usr/share/groff_font/devX75/NBI OLD_FILES+=usr/share/groff_font/devX75/NI OLD_FILES+=usr/share/groff_font/devX75/NR OLD_FILES+=usr/share/groff_font/devX75/S OLD_FILES+=usr/share/groff_font/devX75/TB OLD_FILES+=usr/share/groff_font/devX75/TBI OLD_FILES+=usr/share/groff_font/devX75/TI OLD_FILES+=usr/share/groff_font/devX75/TR OLD_DIRS+=usr/share/groff_font/devX75 OLD_FILES+=usr/share/groff_font/devascii/B OLD_FILES+=usr/share/groff_font/devascii/BI OLD_FILES+=usr/share/groff_font/devascii/CW OLD_FILES+=usr/share/groff_font/devascii/DESC OLD_FILES+=usr/share/groff_font/devascii/I OLD_FILES+=usr/share/groff_font/devascii/L OLD_FILES+=usr/share/groff_font/devascii/R OLD_FILES+=usr/share/groff_font/devascii/S OLD_DIRS+=usr/share/groff_font/devascii OLD_FILES+=usr/share/groff_font/devcp1047/B OLD_FILES+=usr/share/groff_font/devcp1047/BI OLD_FILES+=usr/share/groff_font/devcp1047/CW OLD_FILES+=usr/share/groff_font/devcp1047/DESC OLD_FILES+=usr/share/groff_font/devcp1047/I OLD_FILES+=usr/share/groff_font/devcp1047/L OLD_FILES+=usr/share/groff_font/devcp1047/R OLD_FILES+=usr/share/groff_font/devcp1047/S OLD_DIRS+=usr/share/groff_font/devcp1047 OLD_FILES+=usr/share/groff_font/devdvi/CW OLD_FILES+=usr/share/groff_font/devdvi/CWEC OLD_FILES+=usr/share/groff_font/devdvi/CWI OLD_FILES+=usr/share/groff_font/devdvi/CWIEC OLD_FILES+=usr/share/groff_font/devdvi/CWITC OLD_FILES+=usr/share/groff_font/devdvi/CWTC OLD_FILES+=usr/share/groff_font/devdvi/CompileFonts OLD_FILES+=usr/share/groff_font/devdvi/DESC OLD_FILES+=usr/share/groff_font/devdvi/EX OLD_FILES+=usr/share/groff_font/devdvi/HB OLD_FILES+=usr/share/groff_font/devdvi/HBEC OLD_FILES+=usr/share/groff_font/devdvi/HBI OLD_FILES+=usr/share/groff_font/devdvi/HBIEC OLD_FILES+=usr/share/groff_font/devdvi/HBITC OLD_FILES+=usr/share/groff_font/devdvi/HBTC OLD_FILES+=usr/share/groff_font/devdvi/HI OLD_FILES+=usr/share/groff_font/devdvi/HIEC OLD_FILES+=usr/share/groff_font/devdvi/HITC OLD_FILES+=usr/share/groff_font/devdvi/HR OLD_FILES+=usr/share/groff_font/devdvi/HREC OLD_FILES+=usr/share/groff_font/devdvi/HRTC OLD_FILES+=usr/share/groff_font/devdvi/MI OLD_FILES+=usr/share/groff_font/devdvi/Makefile OLD_FILES+=usr/share/groff_font/devdvi/S OLD_FILES+=usr/share/groff_font/devdvi/SA OLD_FILES+=usr/share/groff_font/devdvi/SB OLD_FILES+=usr/share/groff_font/devdvi/SC OLD_FILES+=usr/share/groff_font/devdvi/TB OLD_FILES+=usr/share/groff_font/devdvi/TBEC OLD_FILES+=usr/share/groff_font/devdvi/TBI OLD_FILES+=usr/share/groff_font/devdvi/TBIEC OLD_FILES+=usr/share/groff_font/devdvi/TBITC OLD_FILES+=usr/share/groff_font/devdvi/TBTC OLD_FILES+=usr/share/groff_font/devdvi/TI OLD_FILES+=usr/share/groff_font/devdvi/TIEC OLD_FILES+=usr/share/groff_font/devdvi/TITC OLD_FILES+=usr/share/groff_font/devdvi/TR OLD_FILES+=usr/share/groff_font/devdvi/TREC OLD_FILES+=usr/share/groff_font/devdvi/TRTC OLD_FILES+=usr/share/groff_font/devdvi/ec.map OLD_FILES+=usr/share/groff_font/devdvi/msam.map OLD_FILES+=usr/share/groff_font/devdvi/msbm.map OLD_FILES+=usr/share/groff_font/devdvi/tc.map OLD_FILES+=usr/share/groff_font/devdvi/texb.map OLD_FILES+=usr/share/groff_font/devdvi/texex.map OLD_FILES+=usr/share/groff_font/devdvi/texi.map OLD_FILES+=usr/share/groff_font/devdvi/texmi.map OLD_FILES+=usr/share/groff_font/devdvi/texr.map OLD_FILES+=usr/share/groff_font/devdvi/texsy.map OLD_FILES+=usr/share/groff_font/devdvi/textex.map OLD_FILES+=usr/share/groff_font/devdvi/textt.map OLD_DIRS+=usr/share/groff_font/devdvi OLD_FILES+=usr/share/groff_font/devhtml/B OLD_FILES+=usr/share/groff_font/devhtml/BI OLD_FILES+=usr/share/groff_font/devhtml/CB OLD_FILES+=usr/share/groff_font/devhtml/CBI OLD_FILES+=usr/share/groff_font/devhtml/CI OLD_FILES+=usr/share/groff_font/devhtml/CR OLD_FILES+=usr/share/groff_font/devhtml/DESC OLD_FILES+=usr/share/groff_font/devhtml/I OLD_FILES+=usr/share/groff_font/devhtml/R OLD_FILES+=usr/share/groff_font/devhtml/S OLD_DIRS+=usr/share/groff_font/devhtml OLD_FILES+=usr/share/groff_font/devkoi8-r/B OLD_FILES+=usr/share/groff_font/devkoi8-r/BI OLD_FILES+=usr/share/groff_font/devkoi8-r/CW OLD_FILES+=usr/share/groff_font/devkoi8-r/DESC OLD_FILES+=usr/share/groff_font/devkoi8-r/I OLD_FILES+=usr/share/groff_font/devkoi8-r/L OLD_FILES+=usr/share/groff_font/devkoi8-r/R OLD_FILES+=usr/share/groff_font/devkoi8-r/S OLD_DIRS+=usr/share/groff_font/devkoi8-r OLD_FILES+=usr/share/groff_font/devlatin1/B OLD_FILES+=usr/share/groff_font/devlatin1/BI OLD_FILES+=usr/share/groff_font/devlatin1/CW OLD_FILES+=usr/share/groff_font/devlatin1/DESC OLD_FILES+=usr/share/groff_font/devlatin1/I OLD_FILES+=usr/share/groff_font/devlatin1/L OLD_FILES+=usr/share/groff_font/devlatin1/R OLD_FILES+=usr/share/groff_font/devlatin1/S OLD_DIRS+=usr/share/groff_font/devlatin1 OLD_FILES+=usr/share/groff_font/devlbp/CB OLD_FILES+=usr/share/groff_font/devlbp/CI OLD_FILES+=usr/share/groff_font/devlbp/CR OLD_FILES+=usr/share/groff_font/devlbp/DESC OLD_FILES+=usr/share/groff_font/devlbp/EB OLD_FILES+=usr/share/groff_font/devlbp/EI OLD_FILES+=usr/share/groff_font/devlbp/ER OLD_FILES+=usr/share/groff_font/devlbp/HB OLD_FILES+=usr/share/groff_font/devlbp/HBI OLD_FILES+=usr/share/groff_font/devlbp/HI OLD_FILES+=usr/share/groff_font/devlbp/HNB OLD_FILES+=usr/share/groff_font/devlbp/HNBI OLD_FILES+=usr/share/groff_font/devlbp/HNI OLD_FILES+=usr/share/groff_font/devlbp/HNR OLD_FILES+=usr/share/groff_font/devlbp/HR OLD_FILES+=usr/share/groff_font/devlbp/TB OLD_FILES+=usr/share/groff_font/devlbp/TBI OLD_FILES+=usr/share/groff_font/devlbp/TI OLD_FILES+=usr/share/groff_font/devlbp/TR OLD_DIRS+=usr/share/groff_font/devlbp OLD_FILES+=usr/share/groff_font/devlj4/AB OLD_FILES+=usr/share/groff_font/devlj4/ABI OLD_FILES+=usr/share/groff_font/devlj4/AI OLD_FILES+=usr/share/groff_font/devlj4/ALBB OLD_FILES+=usr/share/groff_font/devlj4/ALBR OLD_FILES+=usr/share/groff_font/devlj4/AOB OLD_FILES+=usr/share/groff_font/devlj4/AOI OLD_FILES+=usr/share/groff_font/devlj4/AOR OLD_FILES+=usr/share/groff_font/devlj4/AR OLD_FILES+=usr/share/groff_font/devlj4/CB OLD_FILES+=usr/share/groff_font/devlj4/CBI OLD_FILES+=usr/share/groff_font/devlj4/CI OLD_FILES+=usr/share/groff_font/devlj4/CLARENDON OLD_FILES+=usr/share/groff_font/devlj4/CORONET OLD_FILES+=usr/share/groff_font/devlj4/CR OLD_FILES+=usr/share/groff_font/devlj4/DESC OLD_FILES+=usr/share/groff_font/devlj4/GB OLD_FILES+=usr/share/groff_font/devlj4/GBI OLD_FILES+=usr/share/groff_font/devlj4/GI OLD_FILES+=usr/share/groff_font/devlj4/GR OLD_FILES+=usr/share/groff_font/devlj4/LGB OLD_FILES+=usr/share/groff_font/devlj4/LGI OLD_FILES+=usr/share/groff_font/devlj4/LGR OLD_FILES+=usr/share/groff_font/devlj4/MARIGOLD OLD_FILES+=usr/share/groff_font/devlj4/OB OLD_FILES+=usr/share/groff_font/devlj4/OBI OLD_FILES+=usr/share/groff_font/devlj4/OI OLD_FILES+=usr/share/groff_font/devlj4/OR OLD_FILES+=usr/share/groff_font/devlj4/S OLD_FILES+=usr/share/groff_font/devlj4/SYMBOL OLD_FILES+=usr/share/groff_font/devlj4/TB OLD_FILES+=usr/share/groff_font/devlj4/TBI OLD_FILES+=usr/share/groff_font/devlj4/TI OLD_FILES+=usr/share/groff_font/devlj4/TNRB OLD_FILES+=usr/share/groff_font/devlj4/TNRBI OLD_FILES+=usr/share/groff_font/devlj4/TNRI OLD_FILES+=usr/share/groff_font/devlj4/TNRR OLD_FILES+=usr/share/groff_font/devlj4/TR OLD_FILES+=usr/share/groff_font/devlj4/UB OLD_FILES+=usr/share/groff_font/devlj4/UBI OLD_FILES+=usr/share/groff_font/devlj4/UCB OLD_FILES+=usr/share/groff_font/devlj4/UCBI OLD_FILES+=usr/share/groff_font/devlj4/UCI OLD_FILES+=usr/share/groff_font/devlj4/UCR OLD_FILES+=usr/share/groff_font/devlj4/UI OLD_FILES+=usr/share/groff_font/devlj4/UR OLD_FILES+=usr/share/groff_font/devlj4/WINGDINGS OLD_DIRS+=usr/share/groff_font/devlj4 OLD_FILES+=usr/share/groff_font/devps/AB OLD_FILES+=usr/share/groff_font/devps/ABI OLD_FILES+=usr/share/groff_font/devps/AI OLD_FILES+=usr/share/groff_font/devps/AR OLD_FILES+=usr/share/groff_font/devps/BMB OLD_FILES+=usr/share/groff_font/devps/BMBI OLD_FILES+=usr/share/groff_font/devps/BMI OLD_FILES+=usr/share/groff_font/devps/BMR OLD_FILES+=usr/share/groff_font/devps/CB OLD_FILES+=usr/share/groff_font/devps/CBI OLD_FILES+=usr/share/groff_font/devps/CI OLD_FILES+=usr/share/groff_font/devps/CR OLD_FILES+=usr/share/groff_font/devps/DESC OLD_FILES+=usr/share/groff_font/devps/EURO OLD_FILES+=usr/share/groff_font/devps/HB OLD_FILES+=usr/share/groff_font/devps/HBI OLD_FILES+=usr/share/groff_font/devps/HI OLD_FILES+=usr/share/groff_font/devps/HNB OLD_FILES+=usr/share/groff_font/devps/HNBI OLD_FILES+=usr/share/groff_font/devps/HNI OLD_FILES+=usr/share/groff_font/devps/HNR OLD_FILES+=usr/share/groff_font/devps/HR OLD_FILES+=usr/share/groff_font/devps/Makefile OLD_FILES+=usr/share/groff_font/devps/NB OLD_FILES+=usr/share/groff_font/devps/NBI OLD_FILES+=usr/share/groff_font/devps/NI OLD_FILES+=usr/share/groff_font/devps/NR OLD_FILES+=usr/share/groff_font/devps/PB OLD_FILES+=usr/share/groff_font/devps/PBI OLD_FILES+=usr/share/groff_font/devps/PI OLD_FILES+=usr/share/groff_font/devps/PR OLD_FILES+=usr/share/groff_font/devps/S OLD_FILES+=usr/share/groff_font/devps/SS OLD_FILES+=usr/share/groff_font/devps/TB OLD_FILES+=usr/share/groff_font/devps/TBI OLD_FILES+=usr/share/groff_font/devps/TI OLD_FILES+=usr/share/groff_font/devps/TR OLD_FILES+=usr/share/groff_font/devps/ZCMI OLD_FILES+=usr/share/groff_font/devps/ZD OLD_FILES+=usr/share/groff_font/devps/ZDR OLD_FILES+=usr/share/groff_font/devps/afmname OLD_FILES+=usr/share/groff_font/devps/dingbats.map OLD_FILES+=usr/share/groff_font/devps/dingbats.rmap OLD_FILES+=usr/share/groff_font/devps/download OLD_FILES+=usr/share/groff_font/devps/freeeuro.pfa OLD_FILES+=usr/share/groff_font/devps/lgreekmap OLD_FILES+=usr/share/groff_font/devps/prologue OLD_FILES+=usr/share/groff_font/devps/symbol.sed OLD_FILES+=usr/share/groff_font/devps/symbolchars OLD_FILES+=usr/share/groff_font/devps/symbolsl.afm OLD_FILES+=usr/share/groff_font/devps/symbolsl.pfa OLD_FILES+=usr/share/groff_font/devps/text.enc OLD_FILES+=usr/share/groff_font/devps/textmap OLD_FILES+=usr/share/groff_font/devps/zapfdr.pfa OLD_DIRS+=usr/share/groff_font/devps OLD_FILES+=usr/share/groff_font/devutf8/B OLD_FILES+=usr/share/groff_font/devutf8/BI OLD_FILES+=usr/share/groff_font/devutf8/CW OLD_FILES+=usr/share/groff_font/devutf8/DESC OLD_FILES+=usr/share/groff_font/devutf8/I OLD_FILES+=usr/share/groff_font/devutf8/L OLD_FILES+=usr/share/groff_font/devutf8/R OLD_FILES+=usr/share/groff_font/devutf8/S OLD_DIRS+=usr/share/groff_font/devutf8 OLD_DIRS+=usr/share/groff_font OLD_FILES+=usr/share/info/groff.info.gz OLD_FILES+=usr/share/man/man1/addftinfo.1.gz OLD_FILES+=usr/share/man/man1/afmtodit.1.gz OLD_FILES+=usr/share/man/man1/eqn.1.gz OLD_FILES+=usr/share/man/man1/grn.1.gz OLD_FILES+=usr/share/man/man1/grodvi.1.gz OLD_FILES+=usr/share/man/man1/groff.1.gz OLD_FILES+=usr/share/man/man1/grog.1.gz OLD_FILES+=usr/share/man/man1/grolbp.1.gz OLD_FILES+=usr/share/man/man1/grolj4.1.gz OLD_FILES+=usr/share/man/man1/grops.1.gz OLD_FILES+=usr/share/man/man1/grotty.1.gz OLD_FILES+=usr/share/man/man1/hpftodit.1.gz OLD_FILES+=usr/share/man/man1/indxbib.1.gz OLD_FILES+=usr/share/man/man1/lkbib.1.gz OLD_FILES+=usr/share/man/man1/lookbib.1.gz OLD_FILES+=usr/share/man/man1/mmroff.1.gz OLD_FILES+=usr/share/man/man1/neqn.1.gz OLD_FILES+=usr/share/man/man1/nroff.1.gz OLD_FILES+=usr/share/man/man1/pfbtops.1.gz OLD_FILES+=usr/share/man/man1/pic.1.gz OLD_FILES+=usr/share/man/man1/psroff.1.gz OLD_FILES+=usr/share/man/man1/refer.1.gz OLD_FILES+=usr/share/man/man1/soelim.1.gz OLD_FILES+=usr/share/man/man1/tbl.1.gz OLD_FILES+=usr/share/man/man1/tfmtodit.1.gz OLD_FILES+=usr/share/man/man1/troff.1.gz OLD_FILES+=usr/share/man/man1/vgrind.1.gz OLD_FILES+=usr/share/man/man5/groff_font.5.gz OLD_FILES+=usr/share/man/man5/groff_out.5.gz OLD_FILES+=usr/share/man/man5/groff_tmac.5.gz OLD_FILES+=usr/share/man/man5/lj4_font.5.gz OLD_FILES+=usr/share/man/man5/tmac.5.gz OLD_FILES+=usr/share/man/man5/vgrindefs.5.gz OLD_FILES+=usr/share/man/man7/ditroff.7.gz OLD_FILES+=usr/share/man/man7/groff.7.gz OLD_FILES+=usr/share/man/man7/groff_char.7.gz OLD_FILES+=usr/share/man/man7/groff_diff.7.gz OLD_FILES+=usr/share/man/man7/groff_man.7.gz OLD_FILES+=usr/share/man/man7/groff_mdoc.7.gz OLD_FILES+=usr/share/man/man7/groff_me.7.gz OLD_FILES+=usr/share/man/man7/groff_mm.7.gz OLD_FILES+=usr/share/man/man7/groff_mmse.7.gz OLD_FILES+=usr/share/man/man7/groff_ms.7.gz OLD_FILES+=usr/share/man/man7/groff_trace.7.gz OLD_FILES+=usr/share/man/man7/groff_www.7.gz OLD_FILES+=usr/share/man/man7/man.7.gz OLD_FILES+=usr/share/man/man7/mdoc.7.gz OLD_FILES+=usr/share/man/man7/mdoc.samples.7.gz OLD_FILES+=usr/share/man/man7/me.7.gz OLD_FILES+=usr/share/man/man7/mm.7.gz OLD_FILES+=usr/share/man/man7/mmse.7.gz OLD_FILES+=usr/share/man/man7/ms.7.gz OLD_FILES+=usr/share/man/man7/orig_me.7.gz OLD_FILES+=usr/share/man/man7/roff.7.gz OLD_FILES+=usr/share/me/acm.me OLD_FILES+=usr/share/me/chars.me OLD_FILES+=usr/share/me/deltext.me OLD_FILES+=usr/share/me/eqn.me OLD_FILES+=usr/share/me/float.me OLD_FILES+=usr/share/me/footnote.me OLD_FILES+=usr/share/me/index.me OLD_FILES+=usr/share/me/letterhead.me OLD_FILES+=usr/share/me/local.me OLD_FILES+=usr/share/me/null.me OLD_FILES+=usr/share/me/refer.me OLD_FILES+=usr/share/me/revisions OLD_FILES+=usr/share/me/sh.me OLD_FILES+=usr/share/me/tbl.me OLD_FILES+=usr/share/me/thesis.me OLD_DIRS+=usr/share/me OLD_FILES+=usr/share/misc/vgrindefs OLD_FILES+=usr/share/misc/vgrindefs.db OLD_FILES+=usr/share/tmac/X.tmac OLD_FILES+=usr/share/tmac/Xps.tmac OLD_FILES+=usr/share/tmac/a4.tmac OLD_FILES+=usr/share/tmac/an-old.tmac OLD_FILES+=usr/share/tmac/an.tmac OLD_FILES+=usr/share/tmac/andoc.tmac OLD_FILES+=usr/share/tmac/composite.tmac OLD_FILES+=usr/share/tmac/cp1047.tmac OLD_FILES+=usr/share/tmac/devtag.tmac OLD_FILES+=usr/share/tmac/doc.tmac OLD_FILES+=usr/share/tmac/dvi.tmac OLD_FILES+=usr/share/tmac/e.tmac OLD_FILES+=usr/share/tmac/ec.tmac OLD_FILES+=usr/share/tmac/eqnrc OLD_FILES+=usr/share/tmac/europs.tmac OLD_FILES+=usr/share/tmac/html-end.tmac OLD_FILES+=usr/share/tmac/html.tmac OLD_FILES+=usr/share/tmac/hyphen.ru OLD_FILES+=usr/share/tmac/hyphen.us OLD_FILES+=usr/share/tmac/hyphenex.us OLD_FILES+=usr/share/tmac/koi8-r.tmac OLD_FILES+=usr/share/tmac/latin1.tmac OLD_FILES+=usr/share/tmac/latin2.tmac OLD_FILES+=usr/share/tmac/latin9.tmac OLD_FILES+=usr/share/tmac/lbp.tmac OLD_FILES+=usr/share/tmac/lj4.tmac OLD_FILES+=usr/share/tmac/m.tmac OLD_FILES+=usr/share/tmac/man.local OLD_FILES+=usr/share/tmac/man.tmac OLD_FILES+=usr/share/tmac/mandoc.tmac OLD_FILES+=usr/share/tmac/mdoc.local OLD_FILES+=usr/share/tmac/mdoc.tmac OLD_FILES+=usr/share/tmac/mdoc/doc-common OLD_FILES+=usr/share/tmac/mdoc/doc-ditroff OLD_FILES+=usr/share/tmac/mdoc/doc-nroff OLD_FILES+=usr/share/tmac/mdoc/doc-syms OLD_FILES+=usr/share/tmac/mdoc/fr.ISO8859-1 OLD_FILES+=usr/share/tmac/mdoc/ru.KOI8-R OLD_DIRS+=usr/share/tmac/mdoc OLD_FILES+=usr/share/tmac/me.tmac OLD_FILES+=usr/share/tmac/mm/0.MT OLD_FILES+=usr/share/tmac/mm/4.MT OLD_FILES+=usr/share/tmac/mm/5.MT OLD_FILES+=usr/share/tmac/mm/locale OLD_FILES+=usr/share/tmac/mm/mm.tmac OLD_FILES+=usr/share/tmac/mm/mmse.tmac OLD_FILES+=usr/share/tmac/mm/ms.cov OLD_FILES+=usr/share/tmac/mm/se_locale OLD_FILES+=usr/share/tmac/mm/se_ms.cov OLD_DIRS+=usr/share/tmac/mm OLD_FILES+=usr/share/tmac/ms.tmac OLD_FILES+=usr/share/tmac/mse.tmac OLD_FILES+=usr/share/tmac/papersize.tmac OLD_FILES+=usr/share/tmac/pic.tmac OLD_FILES+=usr/share/tmac/ps.tmac OLD_FILES+=usr/share/tmac/psatk.tmac OLD_FILES+=usr/share/tmac/psold.tmac OLD_FILES+=usr/share/tmac/pspic.tmac OLD_FILES+=usr/share/tmac/s.tmac OLD_FILES+=usr/share/tmac/safer.tmac OLD_FILES+=usr/share/tmac/tmac.orig_me OLD_FILES+=usr/share/tmac/tmac.vgrind OLD_FILES+=usr/share/tmac/trace.tmac OLD_FILES+=usr/share/tmac/troffrc OLD_FILES+=usr/share/tmac/troffrc-end OLD_FILES+=usr/share/tmac/tty-char.tmac OLD_FILES+=usr/share/tmac/tty.tmac OLD_FILES+=usr/share/tmac/unicode.tmac OLD_FILES+=usr/share/tmac/www.tmac OLD_DIRS+=usr/share/tmac .endif .if ${MK_GSSAPI} == no OLD_FILES+=usr/include/gssapi/gssapi.h OLD_DIRS+=usr/include/gssapi OLD_FILES+=usr/include/gssapi.h OLD_FILES+=usr/lib/libgssapi.a OLD_FILES+=usr/lib/libgssapi.so OLD_LIBS+=usr/lib/libgssapi.so.10 OLD_FILES+=usr/lib/libgssapi_p.a OLD_FILES+=usr/lib/librpcsec_gss.a OLD_FILES+=usr/lib/librpcsec_gss.so OLD_LIBS+=usr/lib/librpcsec_gss.so.1 .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libgssapi.a OLD_FILES+=usr/lib32/libgssapi.so OLD_LIBS+=usr/lib32/libgssapi.so.10 OLD_FILES+=usr/lib32/libgssapi_p.a OLD_FILES+=usr/lib32/librpcsec_gss.a OLD_FILES+=usr/lib32/librpcsec_gss.so OLD_LIBS+=usr/lib32/librpcsec_gss.so.1 .endif OLD_FILES+=usr/sbin/gssd OLD_FILES+=usr/share/man/man3/gss_accept_sec_context.3.gz OLD_FILES+=usr/share/man/man3/gss_acquire_cred.3.gz OLD_FILES+=usr/share/man/man3/gss_add_cred.3.gz OLD_FILES+=usr/share/man/man3/gss_add_oid_set_member.3.gz OLD_FILES+=usr/share/man/man3/gss_canonicalize_name.3.gz OLD_FILES+=usr/share/man/man3/gss_compare_name.3.gz OLD_FILES+=usr/share/man/man3/gss_context_time.3.gz OLD_FILES+=usr/share/man/man3/gss_create_empty_oid_set.3.gz OLD_FILES+=usr/share/man/man3/gss_delete_sec_context.3.gz OLD_FILES+=usr/share/man/man3/gss_display_name.3.gz OLD_FILES+=usr/share/man/man3/gss_display_status.3.gz OLD_FILES+=usr/share/man/man3/gss_duplicate_name.3.gz OLD_FILES+=usr/share/man/man3/gss_export_name.3.gz OLD_FILES+=usr/share/man/man3/gss_export_sec_context.3.gz OLD_FILES+=usr/share/man/man3/gss_get_mic.3.gz OLD_FILES+=usr/share/man/man3/gss_import_name.3.gz OLD_FILES+=usr/share/man/man3/gss_import_sec_context.3.gz OLD_FILES+=usr/share/man/man3/gss_indicate_mechs.3.gz OLD_FILES+=usr/share/man/man3/gss_init_sec_context.3.gz OLD_FILES+=usr/share/man/man3/gss_inquire_context.3.gz OLD_FILES+=usr/share/man/man3/gss_inquire_cred.3.gz OLD_FILES+=usr/share/man/man3/gss_inquire_cred_by_mech.3.gz OLD_FILES+=usr/share/man/man3/gss_inquire_mechs_for_name.3.gz OLD_FILES+=usr/share/man/man3/gss_inquire_names_for_mech.3.gz OLD_FILES+=usr/share/man/man3/gss_process_context_token.3.gz OLD_FILES+=usr/share/man/man3/gss_release_buffer.3.gz OLD_FILES+=usr/share/man/man3/gss_release_cred.3.gz OLD_FILES+=usr/share/man/man3/gss_release_name.3.gz OLD_FILES+=usr/share/man/man3/gss_release_oid_set.3.gz OLD_FILES+=usr/share/man/man3/gss_seal.3.gz OLD_FILES+=usr/share/man/man3/gss_sign.3.gz OLD_FILES+=usr/share/man/man3/gss_test_oid_set_member.3.gz OLD_FILES+=usr/share/man/man3/gss_unseal.3.gz OLD_FILES+=usr/share/man/man3/gss_unwrap.3.gz OLD_FILES+=usr/share/man/man3/gss_verify.3.gz OLD_FILES+=usr/share/man/man3/gss_verify_mic.3.gz OLD_FILES+=usr/share/man/man3/gss_wrap.3.gz OLD_FILES+=usr/share/man/man3/gss_wrap_size_limit.3.gz OLD_FILES+=usr/share/man/man3/gssapi.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_get_error.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_get_mech_info.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_get_mechanisms.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_get_principal_name.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_get_versions.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_getcred.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_is_installed.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_max_data_length.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_mech_to_oid.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_oid_to_mech.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_qop_to_num.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_seccreate.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_set_callback.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_set_defaults.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_set_svc_name.3.gz OLD_FILES+=usr/share/man/man3/rpc_gss_svc_max_data_length.3.gz OLD_FILES+=usr/share/man/man3/rpcsec_gss.3.gz OLD_FILES+=usr/share/man/man5/mech.5.gz OLD_FILES+=usr/share/man/man5/qop.5.gz OLD_FILES+=usr/share/man/man8/gssd.8.gz .endif .if ${MK_HESIOD} == no OLD_FILES+=usr/bin/hesinfo OLD_FILES+=usr/include/hesiod.h OLD_FILES+=usr/share/man/man1/hesinfo.1.gz OLD_FILES+=usr/share/man/man3/hesiod.3.gz OLD_FILES+=usr/share/man/man5/hesiod.conf.5.gz .endif #.if ${MK_HTML} == no # to be filled in #.endif .if ${MK_ICONV} == no OLD_FILES+=usr/bin/iconv OLD_FILES+=usr/bin/mkcsmapper OLD_FILES+=usr/bin/mkesdb OLD_FILES+=usr/include/_libiconv_compat.h OLD_FILES+=usr/include/iconv.h OLD_FILES+=usr/share/man/man1/iconv.1.gz OLD_FILES+=usr/share/man/man1/mkcsmapper.1.gz OLD_FILES+=usr/share/man/man1/mkesdb.1.gz OLD_FILES+=usr/share/man/man3/__iconv.3.gz OLD_FILES+=usr/share/man/man3/__iconv_free_list.3.gz OLD_FILES+=usr/share/man/man3/__iconv_get_list.3.gz OLD_FILES+=usr/share/man/man3/iconv.3.gz OLD_FILES+=usr/share/man/man3/iconv_canonicalize.3.gz OLD_FILES+=usr/share/man/man3/iconv_close.3.gz OLD_FILES+=usr/share/man/man3/iconv_open.3.gz OLD_FILES+=usr/share/man/man3/iconv_open_into.3.gz OLD_FILES+=usr/share/man/man3/iconvctl.3.gz OLD_FILES+=usr/share/man/man3/iconvlist.3.gz .endif .if ${MK_INET6} == no OLD_FILES+=sbin/ping6 OLD_FILES+=sbin/rtsol OLD_FILES+=usr/sbin/faithd OLD_FILES+=usr/sbin/ip6addrctl OLD_FILES+=usr/sbin/mld6query OLD_FILES+=usr/sbin/ndp OLD_FILES+=usr/sbin/rip6query OLD_FILES+=usr/sbin/route6d OLD_FILES+=usr/sbin/rrenumd OLD_FILES+=usr/sbin/rtadvd OLD_FILES+=usr/sbin/rtsold OLD_FILES+=usr/sbin/traceroute6 OLD_FILES+=usr/share/man/man5/rrenumd.conf.5.gz OLD_FILES+=usr/share/man/man5/rtadvd.conf.5.gz OLD_FILES+=usr/share/man/man8/ip6addrctl.8.gz OLD_FILES+=usr/share/man/man8/mld6query.8.gz OLD_FILES+=usr/share/man/man8/ndp.8.gz OLD_FILES+=usr/share/man/man8/ping6.8.gz OLD_FILES+=usr/share/man/man8/rip6query.8.gz OLD_FILES+=usr/share/man/man8/route6d.8.gz OLD_FILES+=usr/share/man/man8/rrenumd.8.gz OLD_FILES+=usr/share/man/man8/rtadvd.8.gz OLD_FILES+=usr/share/man/man8/rtsol.8.gz OLD_FILES+=usr/share/man/man8/rtsold.8.gz OLD_FILES+=usr/share/man/man8/traceroute6.8.gz .endif .if ${MK_INET6_SUPPORT} == no OLD_FILES+=rescue/ping6 .endif .if ${MK_INFO} == no OLD_FILES+=usr/bin/info OLD_FILES+=usr/bin/infokey OLD_FILES+=usr/bin/install-info OLD_FILES+=usr/bin/makeinfo OLD_FILES+=usr/bin/texindex OLD_FILES+=usr/share/info/am-utils.info.gz OLD_FILES+=usr/share/info/as-utils.info.gz OLD_FILES+=usr/share/info/binutils.info.gz OLD_FILES+=usr/share/info/com_err.info.gz OLD_FILES+=usr/share/info/diff.info.gz OLD_FILES+=usr/share/info/gdb.info.gz OLD_FILES+=usr/share/info/gdbint.info.gz OLD_FILES+=usr/share/info/gperf.info.gz OLD_FILES+=usr/share/info/grep.info.gz OLD_FILES+=usr/share/info/groff.info.gz OLD_FILES+=usr/share/info/heimdal.info.gz OLD_FILES+=usr/share/info/history.info.gz OLD_FILES+=usr/share/info/info-stnd.info.gz OLD_FILES+=usr/share/info/info.info.gz OLD_FILES+=usr/share/info/ld.info.gz OLD_FILES+=usr/share/info/regex.info.gz OLD_FILES+=usr/share/info/rluserman.info.gz OLD_FILES+=usr/share/info/stabs.info.gz OLD_FILES+=usr/share/info/texinfo.info.gz OLD_FILES+=usr/share/man/man1/info.1.gz OLD_FILES+=usr/share/man/man1/infokey.1.gz OLD_FILES+=usr/share/man/man1/install-info.1.gz OLD_FILES+=usr/share/man/man1/makeinfo.1.gz OLD_FILES+=usr/share/man/man1/texindex.1.gz OLD_FILES+=usr/share/man/man5/info.5.gz OLD_FILES+=usr/share/man/man5/texinfo.5.gz .endif .if ${MK_IPFILTER} == no OLD_FILES+=etc/periodic/security/510.ipfdenied OLD_FILES+=etc/periodic/security/610.ipf6denied OLD_FILES+=rescue/ipf OLD_FILES+=sbin/ipf OLD_FILES+=sbin/ipfs OLD_FILES+=sbin/ipfstat OLD_FILES+=sbin/ipftest OLD_FILES+=sbin/ipmon OLD_FILES+=sbin/ipnat OLD_FILES+=sbin/ippool OLD_FILES+=sbin/ipresend OLD_FILES+=usr/include/netinet/ip_auth.h OLD_FILES+=usr/include/netinet/ip_compat.h OLD_FILES+=usr/include/netinet/ip_fil.h OLD_FILES+=usr/include/netinet/ip_frag.h OLD_FILES+=usr/include/netinet/ip_htable.h OLD_FILES+=usr/include/netinet/ip_lookup.h OLD_FILES+=usr/include/netinet/ip_nat.h OLD_FILES+=usr/include/netinet/ip_pool.h OLD_FILES+=usr/include/netinet/ip_proxy.h OLD_FILES+=usr/include/netinet/ip_rules.h OLD_FILES+=usr/include/netinet/ip_scan.h OLD_FILES+=usr/include/netinet/ip_state.h OLD_FILES+=usr/include/netinet/ip_sync.h OLD_FILES+=usr/include/netinet/ipl.h OLD_FILES+=usr/share/examples/ipfilter/README OLD_FILES+=usr/share/examples/ipfilter/BASIC.NAT OLD_FILES+=usr/share/examples/ipfilter/BASIC_1.FW OLD_FILES+=usr/share/examples/ipfilter/BASIC_2.FW OLD_FILES+=usr/share/examples/ipfilter/example.1 OLD_FILES+=usr/share/examples/ipfilter/example.2 OLD_FILES+=usr/share/examples/ipfilter/example.3 OLD_FILES+=usr/share/examples/ipfilter/example.4 OLD_FILES+=usr/share/examples/ipfilter/example.5 OLD_FILES+=usr/share/examples/ipfilter/example.6 OLD_FILES+=usr/share/examples/ipfilter/example.7 OLD_FILES+=usr/share/examples/ipfilter/example.8 OLD_FILES+=usr/share/examples/ipfilter/example.9 OLD_FILES+=usr/share/examples/ipfilter/example.10 OLD_FILES+=usr/share/examples/ipfilter/example.11 OLD_FILES+=usr/share/examples/ipfilter/example.12 OLD_FILES+=usr/share/examples/ipfilter/example.13 OLD_FILES+=usr/share/examples/ipfilter/example.sr OLD_FILES+=usr/share/examples/ipfilter/firewall OLD_FILES+=usr/share/examples/ipfilter/ftp-proxy OLD_FILES+=usr/share/examples/ipfilter/ftppxy OLD_FILES+=usr/share/examples/ipfilter/nat-setup OLD_FILES+=usr/share/examples/ipfilter/nat.eg OLD_FILES+=usr/share/examples/ipfilter/server OLD_FILES+=usr/share/examples/ipfilter/tcpstate OLD_FILES+=usr/share/examples/ipfilter/example.14 OLD_FILES+=usr/share/examples/ipfilter/firewall.1 OLD_FILES+=usr/share/examples/ipfilter/firewall.2 OLD_FILES+=usr/share/examples/ipfilter/ipf.conf.permissive OLD_FILES+=usr/share/examples/ipfilter/ipf.conf.restrictive OLD_FILES+=usr/share/examples/ipfilter/ipf.conf.sample OLD_FILES+=usr/share/examples/ipfilter/ipnat.conf.sample OLD_FILES+=usr/share/examples/ipfilter/ipf-howto.txt OLD_FILES+=usr/share/examples/ipfilter/examples.txt OLD_FILES+=usr/share/examples/ipfilter/rules.txt OLD_FILES+=usr/share/examples/ipfilter/mkfilters OLD_DIRS+=usr/share/examples/ipfilter OLD_FILES+=usr/share/man/man1/ipftest.1.gz OLD_FILES+=usr/share/man/man1/ipresend.1.gz OLD_FILES+=usr/share/man/man4/ipf.4.gz OLD_FILES+=usr/share/man/man4/ipl.4.gz OLD_FILES+=usr/share/man/man4/ipfilter.4.gz OLD_FILES+=usr/share/man/man4/ipnat.4.gz OLD_FILES+=usr/share/man/man5/ipf.5.gz OLD_FILES+=usr/share/man/man5/ipf.conf.5.gz OLD_FILES+=usr/share/man/man5/ipf6.conf.5.gz OLD_FILES+=usr/share/man/man5/ipnat.5.gz OLD_FILES+=usr/share/man/man5/ipnat.conf.5.gz OLD_FILES+=usr/share/man/man5/ippool.5.gz OLD_FILES+=usr/share/man/man8/ipf.8.gz OLD_FILES+=usr/share/man/man8/ipfs.8.gz OLD_FILES+=usr/share/man/man8/ipfstat.8.gz OLD_FILES+=usr/share/man/man8/ipmon.8.gz OLD_FILES+=usr/share/man/man8/ipnat.8.gz OLD_FILES+=usr/share/man/man8/ippool.8.gz .endif .if ${MK_IPFW} == no OLD_FILES+=etc/periodic/security/500.ipfwdenied OLD_FILES+=etc/periodic/security/550.ipfwlimit OLD_FILES+=sbin/ipfw OLD_FILES+=sbin/natd OLD_FILES+=usr/sbin/ipfwpcap OLD_FILES+=usr/share/man/man8/ipfw.8.gz OLD_FILES+=usr/share/man/man8/ipfwpcap.8.gz OLD_FILES+=usr/share/man/man8/natd.8.gz .endif .if ${MK_JAIL} == no OLD_FILES+=usr/sbin/jail OLD_FILES+=usr/sbin/jexec OLD_FILES+=usr/sbin/jls OLD_FILES+=usr/share/man/man8/jail.8.gz OLD_FILES+=usr/share/man/man8/jexec.8.gz OLD_FILES+=usr/share/man/man8/jls.8.gz .endif .if ${MK_KERBEROS} == no OLD_FILES+=usr/bin/compile_et OLD_FILES+=usr/bin/hxtool OLD_FILES+=usr/bin/kadmin OLD_FILES+=usr/bin/kdestroy OLD_FILES+=usr/bin/kf OLD_FILES+=usr/bin/kgetcred OLD_FILES+=usr/bin/kinit OLD_FILES+=usr/bin/klist OLD_FILES+=usr/bin/kpasswd OLD_FILES+=usr/bin/krb5-config OLD_FILES+=usr/bin/ksu OLD_FILES+=usr/bin/kswitch OLD_FILES+=usr/bin/string2key OLD_FILES+=usr/bin/verify_krb5_conf OLD_FILES+=usr/include/asn1-common.h OLD_FILES+=usr/include/asn1_err.h OLD_FILES+=usr/include/base64.h OLD_FILES+=usr/include/cms_asn1.h OLD_FILES+=usr/include/crmf_asn1.h OLD_FILES+=usr/include/der-private.h OLD_FILES+=usr/include/der-protos.h OLD_FILES+=usr/include/der.h OLD_FILES+=usr/include/digest_asn1.h OLD_FILES+=usr/include/getarg.h OLD_FILES+=usr/include/gssapi/gssapi_krb5.h OLD_FILES+=usr/include/hdb-protos.h OLD_FILES+=usr/include/hdb.h OLD_FILES+=usr/include/hdb_asn1.h OLD_FILES+=usr/include/hdb_err.h OLD_FILES+=usr/include/heim_asn1.h OLD_FILES+=usr/include/heim_err.h OLD_FILES+=usr/include/heim_threads.h OLD_FILES+=usr/include/heimbase.h OLD_FILES+=usr/include/heimntlm-protos.h OLD_FILES+=usr/include/heimntlm.h OLD_FILES+=usr/include/hex.h OLD_FILES+=usr/include/hx509-private.h OLD_FILES+=usr/include/hx509-protos.h OLD_FILES+=usr/include/hx509.h OLD_FILES+=usr/include/hx509_err.h OLD_FILES+=usr/include/k524_err.h OLD_FILES+=usr/include/kadm5/admin.h OLD_FILES+=usr/include/kadm5/kadm5-private.h OLD_FILES+=usr/include/kadm5/kadm5-protos.h OLD_FILES+=usr/include/kadm5/kadm5-pwcheck.h OLD_FILES+=usr/include/kadm5/kadm5_err.h OLD_FILES+=usr/include/kadm5/private.h OLD_DIRS+=usr/include/kadm5 OLD_FILES+=usr/include/kafs.h OLD_FILES+=usr/include/kdc-protos.h OLD_FILES+=usr/include/kdc.h OLD_FILES+=usr/include/krb5-private.h OLD_FILES+=usr/include/krb5-protos.h OLD_FILES+=usr/include/krb5-types.h OLD_FILES+=usr/include/krb5.h OLD_FILES+=usr/include/krb5/ccache_plugin.h OLD_FILES+=usr/include/krb5/locate_plugin.h OLD_FILES+=usr/include/krb5/send_to_kdc_plugin.h OLD_FILES+=usr/include/krb5/windc_plugin.h OLD_DIRS+=usr/include/krb5 OLD_FILES+=usr/include/krb5_asn1.h OLD_FILES+=usr/include/krb5_ccapi.h OLD_FILES+=usr/include/krb5_err.h OLD_FILES+=usr/include/kx509_asn1.h OLD_FILES+=usr/include/ntlm_err.h OLD_FILES+=usr/include/ocsp_asn1.h OLD_FILES+=usr/include/parse_bytes.h OLD_FILES+=usr/include/parse_time.h OLD_FILES+=usr/include/parse_units.h OLD_FILES+=usr/include/pkcs10_asn1.h OLD_FILES+=usr/include/pkcs12_asn1.h OLD_FILES+=usr/include/pkcs8_asn1.h OLD_FILES+=usr/include/pkcs9_asn1.h OLD_FILES+=usr/include/pkinit_asn1.h OLD_FILES+=usr/include/resolve.h OLD_FILES+=usr/include/rfc2459_asn1.h OLD_FILES+=usr/include/roken-common.h OLD_FILES+=usr/include/rtbl.h OLD_FILES+=usr/include/wind.h OLD_FILES+=usr/include/wind_err.h OLD_FILES+=usr/include/xdbm.h OLD_FILES+=usr/lib/libasn1.a OLD_FILES+=usr/lib/libasn1.so OLD_LIBS+=usr/lib/libasn1.so.11 OLD_FILES+=usr/lib/libasn1_p.a OLD_FILES+=usr/lib/libcom_err.a OLD_FILES+=usr/lib/libcom_err.so OLD_LIBS+=usr/lib/libcom_err.so.5 OLD_FILES+=usr/lib/libcom_err_p.a OLD_FILES+=usr/lib/libgssapi_krb5.a OLD_FILES+=usr/lib/libgssapi_krb5.so OLD_LIBS+=usr/lib/libgssapi_krb5.so.10 OLD_FILES+=usr/lib/libgssapi_krb5_p.a OLD_FILES+=usr/lib/libgssapi_ntlm.a OLD_FILES+=usr/lib/libgssapi_ntlm.so OLD_LIBS+=usr/lib/libgssapi_ntlm.so.10 OLD_FILES+=usr/lib/libgssapi_ntlm_p.a OLD_FILES+=usr/lib/libgssapi_spnego.a OLD_FILES+=usr/lib/libgssapi_spnego.so OLD_LIBS+=usr/lib/libgssapi_spnego.so.10 OLD_FILES+=usr/lib/libgssapi_spnego_p.a OLD_FILES+=usr/lib/libhdb.a OLD_FILES+=usr/lib/libhdb.so OLD_LIBS+=usr/lib/libhdb.so.11 OLD_FILES+=usr/lib/libhdb_p.a OLD_FILES+=usr/lib/libheimbase.a OLD_FILES+=usr/lib/libheimbase.so OLD_LIBS+=usr/lib/libheimbase.so.11 OLD_FILES+=usr/lib/libheimbase_p.a OLD_FILES+=usr/lib/libheimntlm.a OLD_FILES+=usr/lib/libheimntlm.so OLD_LIBS+=usr/lib/libheimntlm.so.11 OLD_FILES+=usr/lib/libheimntlm_p.a OLD_FILES+=usr/lib/libheimsqlite.a OLD_FILES+=usr/lib/libheimsqlite.so OLD_LIBS+=usr/lib/libheimsqlite.so.11 OLD_FILES+=usr/lib/libheimsqlite_p.a OLD_FILES+=usr/lib/libhx509.a OLD_FILES+=usr/lib/libhx509.so OLD_LIBS+=usr/lib/libhx509.so.11 OLD_FILES+=usr/lib/libhx509_p.a OLD_FILES+=usr/lib/libkadm5clnt.a OLD_FILES+=usr/lib/libkadm5clnt.so OLD_LIBS+=usr/lib/libkadm5clnt.so.11 OLD_FILES+=usr/lib/libkadm5clnt_p.a OLD_FILES+=usr/lib/libkadm5srv.a OLD_FILES+=usr/lib/libkadm5srv.so OLD_LIBS+=usr/lib/libkadm5srv.so.11 OLD_FILES+=usr/lib/libkadm5srv_p.a OLD_FILES+=usr/lib/libkafs5.a OLD_FILES+=usr/lib/libkafs5.so OLD_LIBS+=usr/lib/libkafs5.so.11 OLD_FILES+=usr/lib/libkafs5_p.a OLD_FILES+=usr/lib/libkdc.a OLD_FILES+=usr/lib/libkdc.so OLD_LIBS+=usr/lib/libkdc.so.11 OLD_FILES+=usr/lib/libkdc_p.a OLD_FILES+=usr/lib/libkrb5.a OLD_FILES+=usr/lib/libkrb5.so OLD_LIBS+=usr/lib/libkrb5.so.11 OLD_FILES+=usr/lib/libkrb5_p.a OLD_FILES+=usr/lib/libroken.a OLD_FILES+=usr/lib/libroken.so OLD_LIBS+=usr/lib/libroken.so.11 OLD_FILES+=usr/lib/libroken_p.a OLD_FILES+=usr/lib/libwind.a OLD_FILES+=usr/lib/libwind.so OLD_LIBS+=usr/lib/libwind.so.11 OLD_FILES+=usr/lib/libwind_p.a OLD_FILES+=usr/lib/pam_krb5.so OLD_LIBS+=usr/lib/pam_krb5.so.5 OLD_FILES+=usr/lib/pam_ksu.so OLD_LIBS+=usr/lib/pam_ksu.so.5 OLD_FILES+=usr/lib/private/libheimipcc.a OLD_FILES+=usr/lib/private/libheimipcc.so OLD_LIBS+=usr/lib/private/libheimipcc.so.11 OLD_FILES+=usr/lib/private/libheimipcc_p.a OLD_FILES+=usr/lib/private/libheimipcs.a OLD_FILES+=usr/lib/private/libheimipcs.so OLD_LIBS+=usr/lib/private/libheimipcs.so.11 OLD_FILES+=usr/lib/private/libheimipcs_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libasn1.a OLD_FILES+=usr/lib32/libasn1.so OLD_LIBS+=usr/lib32/libasn1.so.11 OLD_FILES+=usr/lib32/libasn1_p.a OLD_FILES+=usr/lib32/libgssapi_krb5.a OLD_FILES+=usr/lib32/libgssapi_krb5.so OLD_LIBS+=usr/lib32/libgssapi_krb5.so.10 OLD_FILES+=usr/lib32/libgssapi_krb5_p.a OLD_FILES+=usr/lib32/libgssapi_ntlm.a OLD_FILES+=usr/lib32/libgssapi_ntlm.so OLD_LIBS+=usr/lib32/libgssapi_ntlm.so.10 OLD_FILES+=usr/lib32/libgssapi_ntlm_p.a OLD_FILES+=usr/lib32/libgssapi_spnego.a OLD_FILES+=usr/lib32/libgssapi_spnego.so OLD_LIBS+=usr/lib32/libgssapi_spnego.so.10 OLD_FILES+=usr/lib32/libgssapi_spnego_p.a OLD_FILES+=usr/lib32/libhdb.a OLD_FILES+=usr/lib32/libhdb.so OLD_LIBS+=usr/lib32/libhdb.so.11 OLD_FILES+=usr/lib32/libhdb_p.a OLD_FILES+=usr/lib32/libheimbase.a OLD_FILES+=usr/lib32/libheimbase.so OLD_LIBS+=usr/lib32/libheimbase.so.11 OLD_FILES+=usr/lib32/libheimbase_p.a OLD_FILES+=usr/lib32/libheimntlm.a OLD_FILES+=usr/lib32/libheimntlm.so OLD_LIBS+=usr/lib32/libheimntlm.so.11 OLD_FILES+=usr/lib32/libheimntlm_p.a OLD_FILES+=usr/lib32/libheimsqlite.a OLD_FILES+=usr/lib32/libheimsqlite.so OLD_LIBS+=usr/lib32/libheimsqlite.so.11 OLD_FILES+=usr/lib32/libheimsqlite_p.a OLD_FILES+=usr/lib32/libhx509.a OLD_FILES+=usr/lib32/libhx509.so OLD_LIBS+=usr/lib32/libhx509.so.11 OLD_FILES+=usr/lib32/libhx509_p.a OLD_FILES+=usr/lib32/libkadm5clnt.a OLD_FILES+=usr/lib32/libkadm5clnt.so OLD_LIBS+=usr/lib32/libkadm5clnt.so.11 OLD_FILES+=usr/lib32/libkadm5clnt_p.a OLD_FILES+=usr/lib32/libkadm5srv.a OLD_FILES+=usr/lib32/libkadm5srv.so OLD_LIBS+=usr/lib32/libkadm5srv.so.11 OLD_FILES+=usr/lib32/libkadm5srv_p.a OLD_FILES+=usr/lib32/libkafs5.a OLD_FILES+=usr/lib32/libkafs5.so OLD_LIBS+=usr/lib32/libkafs5.so.11 OLD_FILES+=usr/lib32/libkafs5_p.a OLD_FILES+=usr/lib32/libkdc.a OLD_FILES+=usr/lib32/libkdc.so OLD_LIBS+=usr/lib32/libkdc.so.11 OLD_FILES+=usr/lib32/libkdc_p.a OLD_FILES+=usr/lib32/libkrb5.a OLD_FILES+=usr/lib32/libkrb5.so OLD_LIBS+=usr/lib32/libkrb5.so.11 OLD_FILES+=usr/lib32/libkrb5_p.a OLD_FILES+=usr/lib32/libroken.a OLD_FILES+=usr/lib32/libroken.so OLD_LIBS+=usr/lib32/libroken.so.11 OLD_FILES+=usr/lib32/libroken_p.a OLD_FILES+=usr/lib32/libwind.a OLD_FILES+=usr/lib32/libwind.so OLD_LIBS+=usr/lib32/libwind.so.11 OLD_FILES+=usr/lib32/libwind_p.a OLD_FILES+=usr/lib32/pam_krb5.so OLD_LIBS+=usr/lib32/pam_krb5.so.5 OLD_FILES+=usr/lib32/pam_ksu.so OLD_LIBS+=usr/lib32/pam_ksu.so.5 OLD_FILES+=usr/lib32/private/libheimipcc.a OLD_FILES+=usr/lib32/private/libheimipcc.so OLD_LIBS+=usr/lib32/private/libheimipcc.so.11 OLD_FILES+=usr/lib32/private/libheimipcc_p.a OLD_FILES+=usr/lib32/private/libheimipcs.a OLD_FILES+=usr/lib32/private/libheimipcs.so OLD_LIBS+=usr/lib32/private/libheimipcs.so.11 OLD_FILES+=usr/lib32/private/libheimipcs_p.a .endif OLD_FILES+=usr/libexec/digest-service OLD_FILES+=usr/libexec/hprop OLD_FILES+=usr/libexec/hpropd OLD_FILES+=usr/libexec/ipropd-master OLD_FILES+=usr/libexec/ipropd-slave OLD_FILES+=usr/libexec/kadmind OLD_FILES+=usr/libexec/kcm OLD_FILES+=usr/libexec/kdc OLD_FILES+=usr/libexec/kdigest OLD_FILES+=usr/libexec/kfd OLD_FILES+=usr/libexec/kimpersonate OLD_FILES+=usr/libexec/kpasswdd OLD_FILES+=usr/sbin/kstash OLD_FILES+=usr/sbin/ktutil OLD_FILES+=usr/sbin/iprop-log OLD_FILES+=usr/share/info/heimdal.info.gz OLD_FILES+=usr/share/man/man1/kdestroy.1.gz OLD_FILES+=usr/share/man/man1/kf.1.gz OLD_FILES+=usr/share/man/man1/kinit.1.gz OLD_FILES+=usr/share/man/man1/klist.1.gz OLD_FILES+=usr/share/man/man1/kpasswd.1.gz OLD_FILES+=usr/share/man/man1/krb5-config.1.gz OLD_FILES+=usr/share/man/man1/kswitch.1.gz OLD_FILES+=usr/share/man/man3/HDB.3.gz OLD_FILES+=usr/share/man/man3/hdb__del.3.gz OLD_FILES+=usr/share/man/man3/hdb__get.3.gz OLD_FILES+=usr/share/man/man3/hdb__put.3.gz OLD_FILES+=usr/share/man/man3/hdb_auth_status.3.gz OLD_FILES+=usr/share/man/man3/hdb_check_constrained_delegation.3.gz OLD_FILES+=usr/share/man/man3/hdb_check_pkinit_ms_upn_match.3.gz OLD_FILES+=usr/share/man/man3/hdb_check_s4u2self.3.gz OLD_FILES+=usr/share/man/man3/hdb_close.3.gz OLD_FILES+=usr/share/man/man3/hdb_destroy.3.gz OLD_FILES+=usr/share/man/man3/hdb_entry_ex.3.gz OLD_FILES+=usr/share/man/man3/hdb_fetch_kvno.3.gz OLD_FILES+=usr/share/man/man3/hdb_firstkey.3.gz OLD_FILES+=usr/share/man/man3/hdb_free.3.gz OLD_FILES+=usr/share/man/man3/hdb_get_realms.3.gz OLD_FILES+=usr/share/man/man3/hdb_lock.3.gz OLD_FILES+=usr/share/man/man3/hdb_name.3.gz OLD_FILES+=usr/share/man/man3/hdb_nextkey.3.gz OLD_FILES+=usr/share/man/man3/hdb_open.3.gz OLD_FILES+=usr/share/man/man3/hdb_password.3.gz OLD_FILES+=usr/share/man/man3/hdb_remove.3.gz OLD_FILES+=usr/share/man/man3/hdb_rename.3.gz OLD_FILES+=usr/share/man/man3/hdb_store.3.gz OLD_FILES+=usr/share/man/man3/hdb_unlock.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_build_ntlm1_master.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_build_ntlm2_master.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_calculate_lm2.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_calculate_ntlm1.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_calculate_ntlm2.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_decode_targetinfo.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_encode_targetinfo.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_encode_type1.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_encode_type2.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_encode_type3.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_free_buf.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_free_targetinfo.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_free_type1.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_free_type2.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_free_type3.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_keyex_unwrap.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_nt_key.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_ntlmv2_key.3.gz OLD_FILES+=usr/share/man/man3/heim_ntlm_verify_ntlm2.3.gz OLD_FILES+=usr/share/man/man3/hx509.3.gz OLD_FILES+=usr/share/man/man3/hx509_bitstring_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_sign.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_sign_self.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_crl_dp_uri.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_eku.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_hostname.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_jid.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_ms_upn.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_otherName.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_pkinit.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_add_san_rfc822name.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_ca.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_domaincontroller.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_notAfter.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_notAfter_lifetime.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_notBefore.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_proxy.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_serialnumber.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_spki.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_subject.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_template.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_set_unique.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_subject_expand.3.gz OLD_FILES+=usr/share/man/man3/hx509_ca_tbs_template_units.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_binary.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_check_eku.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_cmp.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_find_subjectAltName_otherName.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_SPKI.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_SPKI_AlgorithmIdentifier.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_attribute.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_base_subject.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_friendly_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_issuer.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_issuer_unique_id.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_notAfter.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_notBefore.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_serialnumber.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_subject.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_get_subject_unique_id.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_init_data.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_keyusage_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_ref.3.gz OLD_FILES+=usr/share/man/man3/hx509_cert_set_friendly_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_add.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_append.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_end_seq.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_filter.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_find.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_info.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_iter_f.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_merge.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_next_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_start_seq.3.gz OLD_FILES+=usr/share/man/man3/hx509_certs_store.3.gz OLD_FILES+=usr/share/man/man3/hx509_ci_print_names.3.gz OLD_FILES+=usr/share/man/man3/hx509_clear_error_string.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_create_signed_1.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_envelope_1.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_unenvelope.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_unwrap_ContentInfo.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_verify_signed.3.gz OLD_FILES+=usr/share/man/man3/hx509_cms_wrap_ContentInfo.3.gz OLD_FILES+=usr/share/man/man3/hx509_context_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_context_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_context_set_missing_revoke.3.gz OLD_FILES+=usr/share/man/man3/hx509_crl_add_revoked_certs.3.gz OLD_FILES+=usr/share/man/man3/hx509_crl_alloc.3.gz OLD_FILES+=usr/share/man/man3/hx509_crl_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_crl_lifetime.3.gz OLD_FILES+=usr/share/man/man3/hx509_crl_sign.3.gz OLD_FILES+=usr/share/man/man3/hx509_crypto.3.gz OLD_FILES+=usr/share/man/man3/hx509_env.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_add.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_add_binding.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_find.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_find_binding.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_env_lfind.3.gz OLD_FILES+=usr/share/man/man3/hx509_err.3.gz OLD_FILES+=usr/share/man/man3/hx509_error.3.gz OLD_FILES+=usr/share/man/man3/hx509_free_error_string.3.gz OLD_FILES+=usr/share/man/man3/hx509_free_octet_string_list.3.gz OLD_FILES+=usr/share/man/man3/hx509_general_name_unparse.3.gz OLD_FILES+=usr/share/man/man3/hx509_get_error_string.3.gz OLD_FILES+=usr/share/man/man3/hx509_get_one_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_keyset.3.gz OLD_FILES+=usr/share/man/man3/hx509_lock.3.gz OLD_FILES+=usr/share/man/man3/hx509_misc.3.gz OLD_FILES+=usr/share/man/man3/hx509_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_binary.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_cmp.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_copy.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_expand.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_is_null_p.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_to_Name.3.gz OLD_FILES+=usr/share/man/man3/hx509_name_to_string.3.gz OLD_FILES+=usr/share/man/man3/hx509_ocsp_request.3.gz OLD_FILES+=usr/share/man/man3/hx509_ocsp_verify.3.gz OLD_FILES+=usr/share/man/man3/hx509_oid_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_oid_sprint.3.gz OLD_FILES+=usr/share/man/man3/hx509_parse_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer_info_add_cms_alg.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer_info_alloc.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer_info_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer_info_set_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_peer_info_set_cms_algs.3.gz OLD_FILES+=usr/share/man/man3/hx509_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_print_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_print_stdout.3.gz OLD_FILES+=usr/share/man/man3/hx509_query.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_alloc.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_match_cmp_func.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_match_eku.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_match_friendly_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_match_issuer_serial.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_match_option.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_statistic_file.3.gz OLD_FILES+=usr/share/man/man3/hx509_query_unparse_stats.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_add_crl.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_add_ocsp.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_ocsp_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_revoke_verify.3.gz OLD_FILES+=usr/share/man/man3/hx509_set_error_string.3.gz OLD_FILES+=usr/share/man/man3/hx509_set_error_stringv.3.gz OLD_FILES+=usr/share/man/man3/hx509_unparse_der_name.3.gz OLD_FILES+=usr/share/man/man3/hx509_validate_cert.3.gz OLD_FILES+=usr/share/man/man3/hx509_validate_ctx_add_flags.3.gz OLD_FILES+=usr/share/man/man3/hx509_validate_ctx_free.3.gz OLD_FILES+=usr/share/man/man3/hx509_validate_ctx_init.3.gz OLD_FILES+=usr/share/man/man3/hx509_validate_ctx_set_print.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_attach_anchors.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_attach_revoke.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_ctx_f_allow_default_trustanchors.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_destroy_ctx.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_hostname.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_init_ctx.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_path.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_set_max_depth.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_set_proxy_certificate.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_set_strict_rfc3280_verification.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_set_time.3.gz OLD_FILES+=usr/share/man/man3/hx509_verify_signature.3.gz OLD_FILES+=usr/share/man/man3/hx509_xfree.3.gz OLD_FILES+=usr/share/man/man3/k_afs_cell_of_file.3.gz OLD_FILES+=usr/share/man/man3/k_hasafs.3.gz OLD_FILES+=usr/share/man/man3/k_pioctl.3.gz OLD_FILES+=usr/share/man/man3/k_setpag.3.gz OLD_FILES+=usr/share/man/man3/k_unlog.3.gz OLD_FILES+=usr/share/man/man3/kadm5_pwcheck.3.gz OLD_FILES+=usr/share/man/man3/kafs.3.gz OLD_FILES+=usr/share/man/man3/kafs5.3.gz OLD_FILES+=usr/share/man/man3/kafs_set_verbose.3.gz OLD_FILES+=usr/share/man/man3/kafs_settoken.3.gz OLD_FILES+=usr/share/man/man3/kafs_settoken5.3.gz OLD_FILES+=usr/share/man/man3/kafs_settoken_rxkad.3.gz OLD_FILES+=usr/share/man/man3/krb5.3.gz OLD_FILES+=usr/share/man/man3/krb524_convert_creds_kdc.3.gz OLD_FILES+=usr/share/man/man3/krb524_convert_creds_kdc_ccache.3.gz OLD_FILES+=usr/share/man/man3/krb5_425_conv_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_425_conv_principal_ext.3.gz OLD_FILES+=usr/share/man/man3/krb5_524_conv_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_acc_ops.3.gz OLD_FILES+=usr/share/man/man3/krb5_acl_match_file.3.gz OLD_FILES+=usr/share/man/man3/krb5_acl_match_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_add_et_list.3.gz OLD_FILES+=usr/share/man/man3/krb5_add_extra_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_add_ignore_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_addlog_dest.3.gz OLD_FILES+=usr/share/man/man3/krb5_addlog_func.3.gz OLD_FILES+=usr/share/man/man3/krb5_addr2sockaddr.3.gz OLD_FILES+=usr/share/man/man3/krb5_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_address_compare.3.gz OLD_FILES+=usr/share/man/man3/krb5_address_order.3.gz OLD_FILES+=usr/share/man/man3/krb5_address_prefixlen_boundary.3.gz OLD_FILES+=usr/share/man/man3/krb5_address_search.3.gz OLD_FILES+=usr/share/man/man3/krb5_afslog.3.gz OLD_FILES+=usr/share/man/man3/krb5_afslog_uid.3.gz OLD_FILES+=usr/share/man/man3/krb5_allow_weak_crypto.3.gz OLD_FILES+=usr/share/man/man3/krb5_aname_to_localname.3.gz OLD_FILES+=usr/share/man/man3/krb5_anyaddr.3.gz OLD_FILES+=usr/share/man/man3/krb5_appdefault.3.gz OLD_FILES+=usr/share/man/man3/krb5_appdefault_boolean.3.gz OLD_FILES+=usr/share/man/man3/krb5_appdefault_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_appdefault_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_append_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_genaddrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getaddrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getflags.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getlocalsubkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getrcache.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getremotesubkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_getuserkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_initivector.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setaddrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setaddrs_from_fd.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setflags.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setivector.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setlocalsubkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setrcache.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setremotesubkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_con_setuserkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_context.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_getauthenticator.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_getcksumtype.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_getkeytype.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_getlocalseqnumber.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_getremoteseqnumber.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_setcksumtype.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_setkeytype.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_setlocalseqnumber.3.gz OLD_FILES+=usr/share/man/man3/krb5_auth_setremoteseqnumber.3.gz OLD_FILES+=usr/share/man/man3/krb5_build_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_build_principal_ext.3.gz OLD_FILES+=usr/share/man/man3/krb5_build_principal_va.3.gz OLD_FILES+=usr/share/man/man3/krb5_build_principal_va_ext.3.gz OLD_FILES+=usr/share/man/man3/krb5_c_enctype_compare.3.gz OLD_FILES+=usr/share/man/man3/krb5_c_make_checksum.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_cache_end_seq_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_cache_get_first.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_cache_match.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_cache_next.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_clear_mcred.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_close.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_copy_cache.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_copy_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_copy_match_f.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_default_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_destroy.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_end_seq_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_gen_new.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_config.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_friendly_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_full_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_kdc_offset.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_lifetime.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_ops.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_prefix_ops.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_type.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_get_version.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_initialize.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_last_change_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_move.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_new_unique.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_next_cred.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_register.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_remove_cred.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_resolve.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_retrieve_cred.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_set_config.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_set_default_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_set_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_set_friendly_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_set_kdc_offset.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_start_seq_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_store_cred.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_support_switch.3.gz OLD_FILES+=usr/share/man/man3/krb5_cc_switch.3.gz OLD_FILES+=usr/share/man/man3/krb5_ccache.3.gz OLD_FILES+=usr/share/man/man3/krb5_ccache_intro.3.gz OLD_FILES+=usr/share/man/man3/krb5_cccol_cursor_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_cccol_cursor_new.3.gz OLD_FILES+=usr/share/man/man3/krb5_cccol_cursor_next.3.gz OLD_FILES+=usr/share/man/man3/krb5_cccol_last_change_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_change_password.3.gz OLD_FILES+=usr/share/man/man3/krb5_check_transited.3.gz OLD_FILES+=usr/share/man/man3/krb5_checksum_is_collision_proof.3.gz OLD_FILES+=usr/share/man/man3/krb5_checksum_is_keyed.3.gz OLD_FILES+=usr/share/man/man3/krb5_checksumsize.3.gz OLD_FILES+=usr/share/man/man3/krb5_cksumtype_to_enctype.3.gz OLD_FILES+=usr/share/man/man3/krb5_clear_error_message.3.gz OLD_FILES+=usr/share/man/man3/krb5_clear_error_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_closelog.3.gz OLD_FILES+=usr/share/man/man3/krb5_compare_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_file_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_free_strings.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_bool.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_bool_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_list.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_string_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_strings.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_get_time_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_parse_file_multi.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_parse_string_multi.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_bool.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_bool_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_list.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_string_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_strings.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_config_vget_time_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_context.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_creds_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_host_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_keyblock.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_keyblock_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_copy_ticket.3.gz OLD_FILES+=usr/share/man/man3/krb5_create_checksum.3.gz OLD_FILES+=usr/share/man/man3/krb5_create_checksum_iov.3.gz OLD_FILES+=usr/share/man/man3/krb5_credential.3.gz OLD_FILES+=usr/share/man/man3/krb5_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_creds_get_ticket_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_destroy.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_fx_cf2.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_getblocksize.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_getconfoundersize.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_getenctype.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_getpadsize.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_crypto_iov.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_alloc.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_cmp.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_copy.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_ct_cmp.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_realloc.3.gz OLD_FILES+=usr/share/man/man3/krb5_data_zero.3.gz OLD_FILES+=usr/share/man/man3/krb5_decrypt.3.gz OLD_FILES+=usr/share/man/man3/krb5_decrypt_EncryptedData.3.gz OLD_FILES+=usr/share/man/man3/krb5_decrypt_iov_ivec.3.gz OLD_FILES+=usr/share/man/man3/krb5_deprecated.3.gz OLD_FILES+=usr/share/man/man3/krb5_digest.3.gz OLD_FILES+=usr/share/man/man3/krb5_digest_probe.3.gz OLD_FILES+=usr/share/man/man3/krb5_eai_to_heim_errno.3.gz OLD_FILES+=usr/share/man/man3/krb5_encrypt.3.gz OLD_FILES+=usr/share/man/man3/krb5_encrypt_EncryptedData.3.gz OLD_FILES+=usr/share/man/man3/krb5_encrypt_iov_ivec.3.gz OLD_FILES+=usr/share/man/man3/krb5_enctype_disable.3.gz OLD_FILES+=usr/share/man/man3/krb5_enctype_enable.3.gz OLD_FILES+=usr/share/man/man3/krb5_enctype_valid.3.gz OLD_FILES+=usr/share/man/man3/krb5_enctypes_compatible_keys.3.gz OLD_FILES+=usr/share/man/man3/krb5_error.3.gz OLD_FILES+=usr/share/man/man3/krb5_expand_hostname.3.gz OLD_FILES+=usr/share/man/man3/krb5_expand_hostname_realms.3.gz OLD_FILES+=usr/share/man/man3/krb5_fcc_ops.3.gz OLD_FILES+=usr/share/man/man3/krb5_fileformats.3.gz OLD_FILES+=usr/share/man/man3/krb5_find_padata.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_config_files.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_context.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_cred_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_creds_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_data_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_error_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_host_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_keyblock.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_keyblock_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_krbhst.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_ticket.3.gz OLD_FILES+=usr/share/man/man3/krb5_free_unparsed_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_fwd_tgt_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_generate_random_block.3.gz OLD_FILES+=usr/share/man/man3/krb5_generate_subkey.3.gz OLD_FILES+=usr/share/man/man3/krb5_generate_subkey_extended.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_all_client_addrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_all_server_addrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_cred_from_kdc.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_cred_from_kdc_opt.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_credentials.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_default_config_files.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_default_in_tkt_etypes.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_default_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_default_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_default_realms.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_dns_canonicalize_hostname.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_extra_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_fcache_version.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_forwarded_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_host_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_ignore_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_in_cred.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_in_tkt_with_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_in_tkt_with_password.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_in_tkt_with_skey.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_keyblock.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_opt_alloc.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_opt_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_opt_get_error.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_opt_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_init_creds_password.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_kdc_sec_offset.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_krb524hst.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_krb_admin_hst.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_krb_changepw_hst.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_krbhst.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_max_time_skew.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_use_admin_kdc.3.gz OLD_FILES+=usr/share/man/man3/krb5_get_validated_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_getportbyname.3.gz OLD_FILES+=usr/share/man/man3/krb5_h_addr2addr.3.gz OLD_FILES+=usr/share/man/man3/krb5_h_addr2sockaddr.3.gz OLD_FILES+=usr/share/man/man3/krb5_h_errno_to_heim_errno.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_context.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_get_error.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_intro.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_set_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_set_password.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_set_service.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_creds_step.3.gz OLD_FILES+=usr/share/man/man3/krb5_init_ets.3.gz OLD_FILES+=usr/share/man/man3/krb5_initlog.3.gz OLD_FILES+=usr/share/man/man3/krb5_introduction.3.gz OLD_FILES+=usr/share/man/man3/krb5_is_config_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_is_thread_safe.3.gz OLD_FILES+=usr/share/man/man3/krb5_kerberos_enctypes.3.gz OLD_FILES+=usr/share/man/man3/krb5_keyblock_get_enctype.3.gz OLD_FILES+=usr/share/man/man3/krb5_keyblock_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_keyblock_zero.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytab_intro.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytab_key_proc.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytype_to_enctypes.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytype_to_enctypes_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_keytype_to_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_format_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_get_addrinfo.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_next.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_next_as_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_krbhst_reset.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_add_entry.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_close.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_compare.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_copy_entry_contents.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_default_modify_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_default_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_destroy.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_end_seq_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_free_entry.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_get_entry.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_get_full_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_get_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_get_type.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_have_content.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_next_entry.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_read_service_key.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_register.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_remove_entry.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_resolve.3.gz OLD_FILES+=usr/share/man/man3/krb5_kt_start_seq_get.3.gz OLD_FILES+=usr/share/man/man3/krb5_kuserok.3.gz OLD_FILES+=usr/share/man/man3/krb5_log.3.gz OLD_FILES+=usr/share/man/man3/krb5_log_msg.3.gz OLD_FILES+=usr/share/man/man3/krb5_make_addrport.3.gz OLD_FILES+=usr/share/man/man3/krb5_make_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_max_sockaddr_size.3.gz OLD_FILES+=usr/share/man/man3/krb5_mcc_ops.3.gz OLD_FILES+=usr/share/man/man3/krb5_mk_req.3.gz OLD_FILES+=usr/share/man/man3/krb5_mk_safe.3.gz OLD_FILES+=usr/share/man/man3/krb5_openlog.3.gz OLD_FILES+=usr/share/man/man3/krb5_pac.3.gz OLD_FILES+=usr/share/man/man3/krb5_pac_get_buffer.3.gz OLD_FILES+=usr/share/man/man3/krb5_pac_verify.3.gz OLD_FILES+=usr/share/man/man3/krb5_parse_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_parse_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_parse_name_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_parse_nametype.3.gz OLD_FILES+=usr/share/man/man3/krb5_password_key_proc.3.gz OLD_FILES+=usr/share/man/man3/krb5_plugin_register.3.gz OLD_FILES+=usr/share/man/man3/krb5_prepend_config_files_default.3.gz OLD_FILES+=usr/share/man/man3/krb5_princ_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_princ_set_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_compare.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_compare_any_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_get_comp_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_get_num_comp.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_get_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_get_type.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_intro.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_is_krbtgt.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_match.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_set_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_principal_set_type.3.gz OLD_FILES+=usr/share/man/man3/krb5_print_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_random_to_key.3.gz OLD_FILES+=usr/share/man/man3/krb5_rcache.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_error.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_ctx.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_in_ctx_alloc.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_in_set_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_in_set_pac_check.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_out_ctx_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_req_out_get_server.3.gz OLD_FILES+=usr/share/man/man3/krb5_rd_safe.3.gz OLD_FILES+=usr/share/man/man3/krb5_realm_compare.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_addrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_authdata.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_creds_tag.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_int16.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_int32.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_int8.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_keyblock.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_stringz.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_times.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_uint16.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_uint32.3.gz OLD_FILES+=usr/share/man/man3/krb5_ret_uint8.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_config_files.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_default_in_tkt_etypes.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_default_realm.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_dns_canonicalize_hostname.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_error_message.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_error_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_extra_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_fcache_version.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_home_dir_access.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_ignore_addresses.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_kdc_sec_offset.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_max_time_skew.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_password.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_real_time.3.gz OLD_FILES+=usr/share/man/man3/krb5_set_use_admin_kdc.3.gz OLD_FILES+=usr/share/man/man3/krb5_sname_to_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_sock_to_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_sockaddr2address.3.gz OLD_FILES+=usr/share/man/man3/krb5_sockaddr2port.3.gz OLD_FILES+=usr/share/man/man3/krb5_sockaddr_uninteresting.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_clear_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_emem.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_free.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_from_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_from_fd.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_from_mem.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_from_readonly_mem.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_get_byteorder.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_get_eof_code.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_is_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_read.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_seek.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_set_byteorder.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_set_eof_code.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_set_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_set_max_alloc.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_to_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_truncate.3.gz OLD_FILES+=usr/share/man/man3/krb5_storage_write.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_address.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_addrs.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_authdata.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_creds_tag.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_data.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_int16.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_int32.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_int8.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_keyblock.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_principal.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_stringz.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_times.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_uint16.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_uint32.3.gz OLD_FILES+=usr/share/man/man3/krb5_store_uint8.3.gz OLD_FILES+=usr/share/man/man3/krb5_string_to_key.3.gz OLD_FILES+=usr/share/man/man3/krb5_string_to_keytype.3.gz OLD_FILES+=usr/share/man/man3/krb5_support.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket_get_authorization_data_type.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket_get_client.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket_get_endtime.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket_get_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_ticket_get_server.3.gz OLD_FILES+=usr/share/man/man3/krb5_timeofday.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name_fixed.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name_fixed_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name_fixed_short.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_unparse_name_short.3.gz OLD_FILES+=usr/share/man/man3/krb5_us_timeofday.3.gz OLD_FILES+=usr/share/man/man3/krb5_v4compat.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_checksum.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_checksum_iov.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_init_creds.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_opt_init.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_opt_set_flags.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_opt_set_keytab.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_opt_set_secure.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_opt_set_service.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_user.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_user_lrealm.3.gz OLD_FILES+=usr/share/man/man3/krb5_verify_user_opt.3.gz OLD_FILES+=usr/share/man/man3/krb5_vlog.3.gz OLD_FILES+=usr/share/man/man3/krb5_vlog_msg.3.gz OLD_FILES+=usr/share/man/man3/krb5_vset_error_string.3.gz OLD_FILES+=usr/share/man/man3/krb5_vwarn.3.gz OLD_FILES+=usr/share/man/man3/krb_afslog.3.gz OLD_FILES+=usr/share/man/man3/krb_afslog_uid.3.gz OLD_FILES+=usr/share/man/man3/ntlm_buf.3.gz OLD_FILES+=usr/share/man/man3/ntlm_core.3.gz OLD_FILES+=usr/share/man/man3/ntlm_type1.3.gz OLD_FILES+=usr/share/man/man3/ntlm_type2.3.gz OLD_FILES+=usr/share/man/man3/ntlm_type3.3.gz OLD_FILES+=usr/share/man/man5/krb5.conf.5.gz OLD_FILES+=usr/share/man/man8/hprop.8.gz OLD_FILES+=usr/share/man/man8/hpropd.8.gz OLD_FILES+=usr/share/man/man8/iprop-log.8.gz OLD_FILES+=usr/share/man/man8/iprop.8.gz OLD_FILES+=usr/share/man/man8/kadmin.8.gz OLD_FILES+=usr/share/man/man8/kadmind.8.gz OLD_FILES+=usr/share/man/man8/kcm.8.gz OLD_FILES+=usr/share/man/man8/kdc.8.gz OLD_FILES+=usr/share/man/man8/kdigest.8.gz OLD_FILES+=usr/share/man/man8/kerberos.8.gz OLD_FILES+=usr/share/man/man8/kimpersonate.8.gz OLD_FILES+=usr/share/man/man8/kpasswdd.8.gz OLD_FILES+=usr/share/man/man8/kstash.8.gz OLD_FILES+=usr/share/man/man8/ktutil.8.gz OLD_FILES+=usr/share/man/man8/pam_krb5.8.gz OLD_FILES+=usr/share/man/man8/pam_ksu.8.gz OLD_FILES+=usr/share/man/man8/string2key.8.gz OLD_FILES+=usr/share/man/man8/verify_krb5_conf.8.gz .endif .if ${MK_LDNS} == no OLD_FILES+=usr/lib/private/libldns.a OLD_FILES+=usr/lib/private/libldns.so OLD_LIBS+=usr/lib/private/libldns.so.5 OLD_FILES+=usr/lib/private/libldns_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/private/libldns.a OLD_FILES+=usr/lib32/private/libldns.so OLD_LIBS+=usr/lib32/private/libldns.so.5 OLD_FILES+=usr/lib32/private/libldns_p.a .endif .endif .if ${MK_LDNS_UTILS} == no OLD_FILES+=usr/bin/drill OLD_FILES+=usr/share/man/man1/drill.1.gz OLD_FILES+=usr/bin/host OLD_FILES+=usr/share/man/man1/host.1.gz .endif #.if ${MK_LIB32} == no # to be filled in #.endif .if ${MK_LIBCPLUSPLUS} == no OLD_LIBS+=lib/libcxxrt.so.1 OLD_FILES+=usr/lib/libc++.a OLD_FILES+=usr/lib/libc++_p.a OLD_FILES+=usr/lib/libc++.so OLD_LIBS+=usr/lib/libc++.so.1 OLD_FILES+=usr/lib/libcxxrt.a OLD_FILES+=usr/lib/libcxxrt.so OLD_FILES+=usr/lib/libcxxrt_p.a OLD_FILES+=usr/include/c++/v1/__bit_reference OLD_FILES+=usr/include/c++/v1/__config OLD_FILES+=usr/include/c++/v1/__debug OLD_FILES+=usr/include/c++/v1/__functional_03 OLD_FILES+=usr/include/c++/v1/__functional_base OLD_FILES+=usr/include/c++/v1/__functional_base_03 OLD_FILES+=usr/include/c++/v1/__hash_table OLD_FILES+=usr/include/c++/v1/__locale OLD_FILES+=usr/include/c++/v1/__mutex_base OLD_FILES+=usr/include/c++/v1/__split_buffer OLD_FILES+=usr/include/c++/v1/__sso_allocator OLD_FILES+=usr/include/c++/v1/__std_stream OLD_FILES+=usr/include/c++/v1/__tree OLD_FILES+=usr/include/c++/v1/__tuple OLD_FILES+=usr/include/c++/v1/__tuple_03 OLD_FILES+=usr/include/c++/v1/__undef_min_max OLD_FILES+=usr/include/c++/v1/algorithm OLD_FILES+=usr/include/c++/v1/array OLD_FILES+=usr/include/c++/v1/atomic OLD_FILES+=usr/include/c++/v1/bitset OLD_FILES+=usr/include/c++/v1/cassert OLD_FILES+=usr/include/c++/v1/ccomplex OLD_FILES+=usr/include/c++/v1/cctype OLD_FILES+=usr/include/c++/v1/cerrno OLD_FILES+=usr/include/c++/v1/cfenv OLD_FILES+=usr/include/c++/v1/cfloat OLD_FILES+=usr/include/c++/v1/chrono OLD_FILES+=usr/include/c++/v1/cinttypes OLD_FILES+=usr/include/c++/v1/ciso646 OLD_FILES+=usr/include/c++/v1/climits OLD_FILES+=usr/include/c++/v1/clocale OLD_FILES+=usr/include/c++/v1/cmath OLD_FILES+=usr/include/c++/v1/codecvt OLD_FILES+=usr/include/c++/v1/complex OLD_FILES+=usr/include/c++/v1/complex.h OLD_FILES+=usr/include/c++/v1/condition_variable OLD_FILES+=usr/include/c++/v1/csetjmp OLD_FILES+=usr/include/c++/v1/csignal OLD_FILES+=usr/include/c++/v1/cstdarg OLD_FILES+=usr/include/c++/v1/cstdbool OLD_FILES+=usr/include/c++/v1/cstddef OLD_FILES+=usr/include/c++/v1/cstdint OLD_FILES+=usr/include/c++/v1/cstdio OLD_FILES+=usr/include/c++/v1/cstdlib OLD_FILES+=usr/include/c++/v1/cstring OLD_FILES+=usr/include/c++/v1/ctgmath OLD_FILES+=usr/include/c++/v1/ctime OLD_FILES+=usr/include/c++/v1/cwchar OLD_FILES+=usr/include/c++/v1/cwctype OLD_FILES+=usr/include/c++/v1/cxxabi.h OLD_FILES+=usr/include/c++/v1/deque OLD_FILES+=usr/include/c++/v1/exception OLD_FILES+=usr/include/c++/v1/experimental/dynarray OLD_FILES+=usr/include/c++/v1/experimental/optional OLD_FILES+=usr/include/c++/v1/ext/__hash OLD_FILES+=usr/include/c++/v1/ext/hash_map OLD_FILES+=usr/include/c++/v1/ext/hash_set OLD_FILES+=usr/include/c++/v1/forward_list OLD_FILES+=usr/include/c++/v1/fstream OLD_FILES+=usr/include/c++/v1/functional OLD_FILES+=usr/include/c++/v1/future OLD_FILES+=usr/include/c++/v1/initializer_list OLD_FILES+=usr/include/c++/v1/iomanip OLD_FILES+=usr/include/c++/v1/ios OLD_FILES+=usr/include/c++/v1/iosfwd OLD_FILES+=usr/include/c++/v1/iostream OLD_FILES+=usr/include/c++/v1/istream OLD_FILES+=usr/include/c++/v1/iterator OLD_FILES+=usr/include/c++/v1/limits OLD_FILES+=usr/include/c++/v1/list OLD_FILES+=usr/include/c++/v1/locale OLD_FILES+=usr/include/c++/v1/map OLD_FILES+=usr/include/c++/v1/memory OLD_FILES+=usr/include/c++/v1/mutex OLD_FILES+=usr/include/c++/v1/new OLD_FILES+=usr/include/c++/v1/numeric OLD_FILES+=usr/include/c++/v1/ostream OLD_FILES+=usr/include/c++/v1/queue OLD_FILES+=usr/include/c++/v1/random OLD_FILES+=usr/include/c++/v1/ratio OLD_FILES+=usr/include/c++/v1/regex OLD_FILES+=usr/include/c++/v1/scoped_allocator OLD_FILES+=usr/include/c++/v1/set OLD_FILES+=usr/include/c++/v1/sstream OLD_FILES+=usr/include/c++/v1/stack OLD_FILES+=usr/include/c++/v1/stdexcept OLD_FILES+=usr/include/c++/v1/streambuf OLD_FILES+=usr/include/c++/v1/string OLD_FILES+=usr/include/c++/v1/strstream OLD_FILES+=usr/include/c++/v1/system_error OLD_FILES+=usr/include/c++/v1/tgmath.h OLD_FILES+=usr/include/c++/v1/thread OLD_FILES+=usr/include/c++/v1/tuple OLD_FILES+=usr/include/c++/v1/type_traits OLD_FILES+=usr/include/c++/v1/typeindex OLD_FILES+=usr/include/c++/v1/typeinfo OLD_FILES+=usr/include/c++/v1/unordered_map OLD_FILES+=usr/include/c++/v1/unordered_set OLD_FILES+=usr/include/c++/v1/unwind-arm.h OLD_FILES+=usr/include/c++/v1/unwind-itanium.h OLD_FILES+=usr/include/c++/v1/unwind.h OLD_FILES+=usr/include/c++/v1/utility OLD_FILES+=usr/include/c++/v1/valarray OLD_FILES+=usr/include/c++/v1/vector OLD_DIRS+=usr/include/c++/v1/experimental OLD_DIRS+=usr/include/c++/v1/ext OLD_DIRS+=usr/include/c++/v1 .endif #.if ${MK_LIBTHR} == no # to be filled in #.endif #.if ${MK_LOCALES} == no # to be filled in #.endif .if ${MK_LOCATE} == no OLD_FILES+=etc/locate.rc OLD_FILES+=etc/periodic/weekly/310.locate OLD_FILES+=usr/bin/locate OLD_FILES+=usr/libexec/locate.bigram OLD_FILES+=usr/libexec/locate.code OLD_FILES+=usr/libexec/locate.concatdb OLD_FILES+=usr/libexec/locate.mklocatedb OLD_FILES+=usr/libexec/locate.updatedb OLD_FILES+=usr/share/man/man1/locate.1.gz OLD_FILES+=usr/share/man/man8/locate.updatedb.8.gz OLD_FILES+=usr/share/man/man8/updatedb.8.gz .endif .if ${MK_LPR} == no OLD_FILES+=etc/hosts.lpd OLD_FILES+=etc/printcap OLD_FILES+=usr/bin/lp OLD_FILES+=usr/bin/lpq OLD_FILES+=usr/bin/lpr OLD_FILES+=usr/bin/lprm OLD_FILES+=usr/libexec/lpr/ru/bjc-240.sh.sample OLD_FILES+=usr/libexec/lpr/ru/koi2alt OLD_FILES+=usr/libexec/lpr/ru/koi2855 OLD_DIRS+=usr/libexec/lpr/ru OLD_FILES+=usr/libexec/lpr/lpf OLD_DIRS+=usr/libexec/lpr OLD_FILES+=usr/sbin/chkprintcap OLD_FILES+=usr/sbin/lpc OLD_FILES+=usr/sbin/lpd OLD_FILES+=usr/sbin/lptest OLD_FILES+=usr/sbin/pac OLD_FILES+=usr/share/doc/smm/07.lpd/paper.ascii.gz OLD_DIRS+=usr/share/doc/smm/07.lpd OLD_FILES+=usr/share/examples/etc/hosts.lpd OLD_FILES+=usr/share/examples/etc/printcap OLD_FILES+=usr/share/man/man1/lp.1.gz OLD_FILES+=usr/share/man/man1/lpq.1.gz OLD_FILES+=usr/share/man/man1/lpr.1.gz OLD_FILES+=usr/share/man/man1/lprm.1.gz OLD_FILES+=usr/share/man/man1/lptest.1.gz OLD_FILES+=usr/share/man/man5/printcap.5.gz OLD_FILES+=usr/share/man/man8/chkprintcap.8.gz OLD_FILES+=usr/share/man/man8/lpc.8.gz OLD_FILES+=usr/share/man/man8/lpd.8.gz OLD_FILES+=usr/share/man/man8/pac.8.gz .endif .if ${MK_MAIL} == no OLD_FILES+=etc/periodic/daily/130.clean-msgs OLD_FILES+=usr/bin/Mail OLD_FILES+=usr/bin/biff OLD_FILES+=usr/bin/from OLD_FILES+=usr/bin/mail OLD_FILES+=usr/bin/mailx OLD_FILES+=usr/bin/msgs OLD_FILES+=usr/libexec/comsat OLD_FILES+=usr/share/examples/etc/mail.rc OLD_FILES+=usr/share/man/man1/Mail.1.gz OLD_FILES+=usr/share/man/man1/biff.1.gz OLD_FILES+=usr/share/man/man1/from.1.gz OLD_FILES+=usr/share/man/man1/mail.1.gz OLD_FILES+=usr/share/man/man1/mailx.1.gz OLD_FILES+=usr/share/man/man1/msgs.1.gz OLD_FILES+=usr/share/man/man8/comsat.8.gz OLD_FILES+=usr/share/misc/mail.help OLD_FILES+=usr/share/misc/mail.tildehelp .endif .if ${MK_MAILWRAPPER} == no OLD_FILES+=etc/mail/mailer.conf .if ${MK_SENDMAIL} == no OLD_FILES+=usr/sbin/mailwrapper .endif OLD_FILES+=usr/share/man/man8/mailwrapper.8.gz .endif #.if ${MK_MAN} == no # This should add a dependency to a special target which removes all man pages. # Listing all of them here is overkill. #.endif .if ${MK_NDIS} == no OLD_FILES+=usr/sbin/ndiscvt OLD_FILES+=usr/sbin/ndisgen OLD_FILES+=usr/share/man/man8/ndiscvt.8.gz OLD_FILES+=usr/share/man/man8/ndisgen.8.gz OLD_FILES+=usr/share/misc/windrv_stub.c .endif .if ${MK_NETCAT} == no OLD_FILES+=usr/bin/nc OLD_FILES+=usr/share/man/man1/nc.1.gz .endif .if ${MK_NIS} == no OLD_FILES+=usr/bin/ypcat OLD_FILES+=usr/bin/ypchfn OLD_FILES+=usr/bin/ypchpass OLD_FILES+=usr/bin/ypchsh OLD_FILES+=usr/bin/ypmatch OLD_FILES+=usr/bin/yppasswd OLD_FILES+=usr/bin/ypwhich OLD_FILES+=usr/include/ypclnt.h OLD_FILES+=usr/lib/libypclnt.a OLD_FILES+=usr/lib/libypclnt.so OLD_LIBS+=usr/lib/libypclnt.so.4 OLD_FILES+=usr/lib/libypclnt_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libypclnt.a OLD_FILES+=usr/lib32/libypclnt.so OLD_LIBS+=usr/lib32/libypclnt.so.4 OLD_FILES+=usr/lib32/libypclnt_p.a .endif OLD_FILES+=usr/libexec/mknetid OLD_FILES+=usr/libexec/yppwupdate OLD_FILES+=usr/libexec/ypxfr OLD_FILES+=usr/sbin/rpc.yppasswdd OLD_FILES+=usr/sbin/rpc.ypupdated OLD_FILES+=usr/sbin/rpc.ypxfrd OLD_FILES+=usr/sbin/yp_mkdb OLD_FILES+=usr/sbin/ypbind OLD_FILES+=usr/sbin/ypinit OLD_FILES+=usr/sbin/yppoll OLD_FILES+=usr/sbin/yppush OLD_FILES+=usr/sbin/ypserv OLD_FILES+=usr/sbin/ypset OLD_FILES+=usr/share/man/man1/ypcat.1.gz OLD_FILES+=usr/share/man/man1/ypchfn.1.gz OLD_FILES+=usr/share/man/man1/ypchpass.1.gz OLD_FILES+=usr/share/man/man1/ypchsh.1.gz OLD_FILES+=usr/share/man/man1/ypmatch.1.gz OLD_FILES+=usr/share/man/man1/yppasswd.1.gz OLD_FILES+=usr/share/man/man1/ypwhich.1.gz OLD_FILES+=usr/share/man/man5/netid.5.gz OLD_FILES+=usr/share/man/man8/mknetid.8.gz OLD_FILES+=usr/share/man/man8/rpc.yppasswdd.8.gz OLD_FILES+=usr/share/man/man8/rpc.ypxfrd.8.gz OLD_FILES+=usr/share/man/man8/yp_mkdb.8.gz OLD_FILES+=usr/share/man/man8/ypbind.8.gz OLD_FILES+=usr/share/man/man8/ypinit.8.gz OLD_FILES+=usr/share/man/man8/yppoll.8.gz OLD_FILES+=usr/share/man/man8/yppush.8.gz OLD_FILES+=usr/share/man/man8/ypserv.8.gz OLD_FILES+=usr/share/man/man8/ypset.8.gz OLD_FILES+=usr/share/man/man8/ypxfr.8.gz OLD_FILES+=var/yp/Makefile OLD_FILES+=var/yp/Makefile.dist .endif .if ${MK_NLS} == no OLD_FILES+=usr/tests/bin/sh/builtins/locale1.0 # to be filled in .endif .if ${MK_NTP} == no OLD_FILES+=etc/ntp.conf OLD_FILES+=etc/periodic/daily/480.status-ntpd OLD_FILES+=usr/bin/ntpq OLD_FILES+=usr/sbin/ntp-keygen OLD_FILES+=usr/sbin/ntpd OLD_FILES+=usr/sbin/ntpdate OLD_FILES+=usr/sbin/ntpdc OLD_FILES+=usr/sbin/ntptime OLD_FILES+=usr/sbin/sntp OLD_FILES+=usr/share/doc/ntp/accopt.html OLD_FILES+=usr/share/doc/ntp/assoc.html OLD_FILES+=usr/share/doc/ntp/audio.html OLD_FILES+=usr/share/doc/ntp/authopt.html OLD_FILES+=usr/share/doc/ntp/build.html OLD_FILES+=usr/share/doc/ntp/clockopt.html OLD_FILES+=usr/share/doc/ntp/config.html OLD_FILES+=usr/share/doc/ntp/confopt.html OLD_FILES+=usr/share/doc/ntp/copyright.html OLD_FILES+=usr/share/doc/ntp/debug.html OLD_FILES+=usr/share/doc/ntp/driver1.html OLD_FILES+=usr/share/doc/ntp/driver10.html OLD_FILES+=usr/share/doc/ntp/driver11.html OLD_FILES+=usr/share/doc/ntp/driver12.html OLD_FILES+=usr/share/doc/ntp/driver16.html OLD_FILES+=usr/share/doc/ntp/driver18.html OLD_FILES+=usr/share/doc/ntp/driver19.html OLD_FILES+=usr/share/doc/ntp/driver2.html OLD_FILES+=usr/share/doc/ntp/driver20.html OLD_FILES+=usr/share/doc/ntp/driver22.html OLD_FILES+=usr/share/doc/ntp/driver26.html OLD_FILES+=usr/share/doc/ntp/driver27.html OLD_FILES+=usr/share/doc/ntp/driver28.html OLD_FILES+=usr/share/doc/ntp/driver29.html OLD_FILES+=usr/share/doc/ntp/driver3.html OLD_FILES+=usr/share/doc/ntp/driver30.html OLD_FILES+=usr/share/doc/ntp/driver32.html OLD_FILES+=usr/share/doc/ntp/driver33.html OLD_FILES+=usr/share/doc/ntp/driver34.html OLD_FILES+=usr/share/doc/ntp/driver35.html OLD_FILES+=usr/share/doc/ntp/driver36.html OLD_FILES+=usr/share/doc/ntp/driver37.html OLD_FILES+=usr/share/doc/ntp/driver4.html OLD_FILES+=usr/share/doc/ntp/driver5.html OLD_FILES+=usr/share/doc/ntp/driver6.html OLD_FILES+=usr/share/doc/ntp/driver7.html OLD_FILES+=usr/share/doc/ntp/driver8.html OLD_FILES+=usr/share/doc/ntp/driver9.html OLD_FILES+=usr/share/doc/ntp/extern.html OLD_FILES+=usr/share/doc/ntp/hints.html OLD_FILES+=usr/share/doc/ntp/howto.html OLD_FILES+=usr/share/doc/ntp/index.html OLD_FILES+=usr/share/doc/ntp/kern.html OLD_FILES+=usr/share/doc/ntp/ldisc.html OLD_FILES+=usr/share/doc/ntp/measure.html OLD_FILES+=usr/share/doc/ntp/miscopt.html OLD_FILES+=usr/share/doc/ntp/monopt.html OLD_FILES+=usr/share/doc/ntp/mx4200data.html OLD_FILES+=usr/share/doc/ntp/notes.html OLD_FILES+=usr/share/doc/ntp/ntpd.html OLD_FILES+=usr/share/doc/ntp/ntpdate.html OLD_FILES+=usr/share/doc/ntp/ntpdc.html OLD_FILES+=usr/share/doc/ntp/ntpq.html OLD_FILES+=usr/share/doc/ntp/ntptime.html OLD_FILES+=usr/share/doc/ntp/ntptrace.html OLD_FILES+=usr/share/doc/ntp/parsedata.html OLD_FILES+=usr/share/doc/ntp/parsenew.html OLD_FILES+=usr/share/doc/ntp/patches.html OLD_FILES+=usr/share/doc/ntp/porting.html OLD_FILES+=usr/share/doc/ntp/pps.html OLD_FILES+=usr/share/doc/ntp/prefer.html OLD_FILES+=usr/share/doc/ntp/quick.html OLD_FILES+=usr/share/doc/ntp/rdebug.html OLD_FILES+=usr/share/doc/ntp/refclock.html OLD_FILES+=usr/share/doc/ntp/release.html OLD_FILES+=usr/share/doc/ntp/tickadj.html OLD_DIRS+=usr/share/doc/ntp OLD_FILES+=usr/share/examples/etc/ntp.conf OLD_FILES+=usr/share/man/man5/ntp.conf.5.gz OLD_FILES+=usr/share/man/man5/ntp.keys.5.gz OLD_FILES+=usr/share/man/man8/ntp-keygen.8.gz OLD_FILES+=usr/share/man/man8/ntpd.8.gz OLD_FILES+=usr/share/man/man8/ntpdate.8.gz OLD_FILES+=usr/share/man/man8/ntpdc.8.gz OLD_FILES+=usr/share/man/man8/ntpq.8.gz OLD_FILES+=usr/share/man/man8/ntptime.8.gz .endif #.if ${MK_OBJC} == no # to be filled in #.endif .if ${MK_OPENSSH} == no OLD_FILES+=usr/bin/sftp OLD_FILES+=usr/bin/ssh OLD_FILES+=usr/bin/ssh-add OLD_FILES+=usr/bin/ssh-agent OLD_FILES+=usr/bin/ssh-copy-id OLD_FILES+=usr/bin/ssh-keygen OLD_FILES+=usr/bin/ssh-keyscan OLD_FILES+=usr/lib/private/libssh.a OLD_FILES+=usr/lib/private/libssh.so OLD_LIBS+=usr/lib/private/libssh.so.5 OLD_FILES+=usr/lib/private/libssh_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/private/libssh.a OLD_FILES+=usr/lib32/private/libssh.so OLD_LIBS+=usr/lib32/private/libssh.so.5 OLD_FILES+=usr/lib32/private/libssh_p.a .endif OLD_FILES+=usr/libexec/sftp-server OLD_FILES+=usr/libexec/ssh-keysign OLD_FILES+=usr/libexec/ssh-pkcs11-helper OLD_FILES+=usr/sbin/sshd .endif .if ${MK_OPENSSL} == no OLD_FILES+=etc/rc.d/keyserv .endif .if ${MK_PC_SYSINSTALL} == no # backend-partmanager OLD_FILES+=usr/share/pc-sysinstall/backend-partmanager/create-part.sh OLD_FILES+=usr/share/pc-sysinstall/backend-partmanager/delete-part.sh # backend-query OLD_FILES+=usr/share/pc-sysinstall/backend-query/detect-emulation.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/detect-laptop.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/detect-nics.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/disk-info.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/disk-list.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/disk-part.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/enable-net.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/get-packages.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-components.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-config.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-mirrors.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-packages.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-rsync-backups.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/list-tzones.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/query-langs.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/send-logs.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/setup-ssh-keys.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/set-mirror.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/sys-mem.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/test-live.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/test-netup.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/update-part-list.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/xkeyboard-layouts.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/xkeyboard-models.sh OLD_FILES+=usr/share/pc-sysinstall/backend-query/xkeyboard-variants.sh # backend OLD_FILES+=usr/share/pc-sysinstall/backend/functions-bsdlabel.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-cleanup.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-disk.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-extractimage.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-ftp.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-installcomponents.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-installpackages.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-localize.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-mountdisk.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-mountoptical.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-networking.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-newfs.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-parse.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-packages.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-runcommands.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-unmount.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-upgrade.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions-users.sh OLD_FILES+=usr/share/pc-sysinstall/backend/functions.sh OLD_FILES+=usr/share/pc-sysinstall/backend/installimage.sh OLD_FILES+=usr/share/pc-sysinstall/backend/parseconfig.sh OLD_FILES+=usr/share/pc-sysinstall/backend/startautoinstall.sh # conf OLD_FILES+=usr/share/pc-sysinstall/conf/avail-langs OLD_FILES+=usr/share/pc-sysinstall/conf/exclude-from-upgrade OLD_FILES+=usr/share/pc-sysinstall/conf/license/bsd-en.txt OLD_FILES+=usr/share/pc-sysinstall/conf/license/intel-en.txt OLD_FILES+=usr/share/pc-sysinstall/conf/license/nvidia-en.txt OLD_FILES+=usr/share/pc-sysinstall/conf/pc-sysinstall.conf # doc OLD_FILES+=usr/share/pc-sysinstall/doc/help-disk-list OLD_FILES+=usr/share/pc-sysinstall/doc/help-disk-size OLD_FILES+=usr/share/pc-sysinstall/doc/help-index OLD_FILES+=usr/share/pc-sysinstall/doc/help-start-autoinstall # examples OLD_FILES+=usr/share/examples/pc-sysinstall/README OLD_FILES+=usr/share/examples/pc-sysinstall/pc-autoinstall.conf OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.fbsd-netinstall OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.geli OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.gmirror OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.netinstall OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.restore OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.rsync OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.upgrade OLD_FILES+=usr/share/examples/pc-sysinstall/pcinstall.cfg.zfs # pc-sysinstall OLD_FILES+=usr/sbin/pc-sysinstall OLD_FILES+=usr/share/man/man8/pc-sysinstall.8.gz OLD_DIRS+=usr/share/pc-sysinstall/backend OLD_DIRS+=usr/share/pc-sysinstall/backend-partmanager OLD_DIRS+=usr/share/pc-sysinstall/backend-query OLD_DIRS+=usr/share/pc-sysinstall/conf/license OLD_DIRS+=usr/share/pc-sysinstall/conf OLD_DIRS+=usr/share/pc-sysinstall/doc OLD_DIRS+=usr/share/pc-sysinstall OLD_DIRS+=usr/share/examples/pc-sysinstall .endif .if ${MK_PF} == no OLD_FILES+=etc/periodic/security/520.pfdenied OLD_FILES+=etc/pf.os OLD_FILES+=etc/rc.d/ftp-proxy OLD_FILES+=sbin/pfctl OLD_FILES+=sbin/pflogd OLD_FILES+=usr/libexec/tftp-proxy OLD_FILES+=usr/sbin/ftp-proxy OLD_FILES+=usr/share/examples/etc/pf.os OLD_FILES+=usr/share/examples/pf/ackpri OLD_FILES+=usr/share/examples/pf/faq-example1 OLD_FILES+=usr/share/examples/pf/faq-example2 OLD_FILES+=usr/share/examples/pf/faq-example3 OLD_FILES+=usr/share/examples/pf/pf.conf OLD_FILES+=usr/share/examples/pf/queue1 OLD_FILES+=usr/share/examples/pf/queue2 OLD_FILES+=usr/share/examples/pf/queue3 OLD_FILES+=usr/share/examples/pf/queue4 OLD_FILES+=usr/share/examples/pf/spamd OLD_DIRS+=usr/share/examples/pf OLD_FILES+=usr/share/man/man4/pf.4.gz OLD_FILES+=usr/share/man/man4/pflog.4.gz OLD_FILES+=usr/share/man/man4/pfsync.4.gz OLD_FILES+=usr/share/man/man5/pf.conf.5.gz OLD_FILES+=usr/share/man/man5/pf.os.5.gz OLD_FILES+=usr/share/man/man8/ftp-proxy.8.gz OLD_FILES+=usr/share/man/man8/pfctl.8.gz OLD_FILES+=usr/share/man/man8/pflogd.8.gz OLD_FILES+=usr/share/man/man8/tftp-proxy.8.gz .endif .if ${MK_PKGBOOTSTRAP} == no OLD_FILES+=usr/sbin/pkg OLD_FILES+=usr/share/man/man7/pkg.7.gz .endif .if ${MK_PORTSNAP} == no OLD_FILES+=etc/portsnap.conf OLD_FILES+=usr/libexec/make_index OLD_FILES+=usr/libexec/phttpget OLD_FILES+=usr/sbin/portsnap OLD_FILES+=usr/share/examples/etc/portsnap.conf OLD_FILES+=usr/share/man/man8/portsnap.8.gz .endif .if ${MK_PPP} == no OLD_FILES+=etc/ppp/ppp.conf OLD_DIRS+=etc/ppp OLD_FILES+=usr/sbin/ppp OLD_FILES+=usr/sbin/pppctl OLD_FILES+=usr/share/man/man8/ppp.8.gz OLD_FILES+=usr/share/man/man8/pppctl.8.gz .endif .if ${MK_PROFILE} == no OLD_FILES+=usr/lib/libalias_cuseeme_p.a OLD_FILES+=usr/lib/libalias_dummy_p.a OLD_FILES+=usr/lib/libalias_ftp_p.a OLD_FILES+=usr/lib/libalias_irc_p.a OLD_FILES+=usr/lib/libalias_nbt_p.a OLD_FILES+=usr/lib/libalias_p.a OLD_FILES+=usr/lib/libalias_pptp_p.a OLD_FILES+=usr/lib/libalias_skinny_p.a OLD_FILES+=usr/lib/libalias_smedia_p.a OLD_FILES+=usr/lib/libarchive_p.a OLD_FILES+=usr/lib/libasn1_p.a OLD_FILES+=usr/lib/libbegemot_p.a OLD_FILES+=usr/lib/libbluetooth_p.a OLD_FILES+=usr/lib/libbsdxml_p.a OLD_FILES+=usr/lib/libbsm_p.a OLD_FILES+=usr/lib/libbsnmp_p.a OLD_FILES+=usr/lib/libbz2_p.a OLD_FILES+=usr/lib/libc_p.a OLD_FILES+=usr/lib/libcalendar_p.a OLD_FILES+=usr/lib/libcam_p.a OLD_FILES+=usr/lib/libcom_err_p.a OLD_FILES+=usr/lib/libcompat_p.a OLD_FILES+=usr/lib/libcrypt_p.a OLD_FILES+=usr/lib/libcrypto_p.a OLD_FILES+=usr/lib/libcurses_p.a OLD_FILES+=usr/lib/libcursesw_p.a OLD_FILES+=usr/lib/libdevinfo_p.a OLD_FILES+=usr/lib/libdevstat_p.a OLD_FILES+=usr/lib/libdialog_p.a OLD_FILES+=usr/lib/libedit_p.a OLD_FILES+=usr/lib/libelf_p.a OLD_FILES+=usr/lib/libfetch_p.a OLD_FILES+=usr/lib/libfl_p.a OLD_FILES+=usr/lib/libform_p.a OLD_FILES+=usr/lib/libformw_p.a OLD_FILES+=usr/lib/libgcc_p.a OLD_FILES+=usr/lib/libgeom_p.a OLD_FILES+=usr/lib/libgnuregex_p.a OLD_FILES+=usr/lib/libgpib_p.a OLD_FILES+=usr/lib/libgssapi_krb5_p.a OLD_FILES+=usr/lib/libgssapi_p.a OLD_FILES+=usr/lib/libhdb_p.a OLD_FILES+=usr/lib/libheimbase_p.a OLD_FILES+=usr/lib/libheimsqlite_p.a OLD_FILES+=usr/lib/libhistory_p.a OLD_FILES+=usr/lib/libipsec_p.a OLD_FILES+=usr/lib/libjail_p.a OLD_FILES+=usr/lib/libkadm5clnt_p.a OLD_FILES+=usr/lib/libkadm5srv_p.a OLD_FILES+=usr/lib/libkafs5_p.a OLD_FILES+=usr/lib/libkdc_p.a OLD_FILES+=usr/lib/libkiconv_p.a OLD_FILES+=usr/lib/libkrb5_p.a OLD_FILES+=usr/lib/libkvm_p.a OLD_FILES+=usr/lib/libl_p.a OLD_FILES+=usr/lib/libln_p.a OLD_FILES+=usr/lib/libm_p.a OLD_FILES+=usr/lib/libmagic_p.a OLD_FILES+=usr/lib/libmd_p.a OLD_FILES+=usr/lib/libmemstat_p.a OLD_FILES+=usr/lib/libmenu_p.a OLD_FILES+=usr/lib/libmenuw_p.a OLD_FILES+=usr/lib/libmilter_p.a OLD_FILES+=usr/lib/libmp_p.a OLD_FILES+=usr/lib/libncurses_p.a OLD_FILES+=usr/lib/libncursesw_p.a OLD_FILES+=usr/lib/libnetgraph_p.a OLD_FILES+=usr/lib/libngatm_p.a OLD_FILES+=usr/lib/libopie_p.a OLD_FILES+=usr/lib/libpanel_p.a OLD_FILES+=usr/lib/libpanelw_p.a OLD_FILES+=usr/lib/libpcap_p.a OLD_FILES+=usr/lib/libpmc_p.a OLD_FILES+=usr/lib/libpthread_p.a OLD_FILES+=usr/lib/libradius_p.a OLD_FILES+=usr/lib/libroken_p.a OLD_FILES+=usr/lib/librpcsvc_p.a OLD_FILES+=usr/lib/librt_p.a OLD_FILES+=usr/lib/libsbuf_p.a OLD_FILES+=usr/lib/libsdp_p.a OLD_FILES+=usr/lib/libsmb_p.a OLD_FILES+=usr/lib/libssl_p.a OLD_FILES+=usr/lib/libstdc++_p.a OLD_FILES+=usr/lib/libsupc++_p.a OLD_FILES+=usr/lib/libtacplus_p.a OLD_FILES+=usr/lib/libtermcap_p.a OLD_FILES+=usr/lib/libtermcapw_p.a OLD_FILES+=usr/lib/libtermlib_p.a OLD_FILES+=usr/lib/libtermlibw_p.a OLD_FILES+=usr/lib/libthr_p.a OLD_FILES+=usr/lib/libthread_db_p.a OLD_FILES+=usr/lib/libtinfo_p.a OLD_FILES+=usr/lib/libtinfow_p.a OLD_FILES+=usr/lib/libufs_p.a OLD_FILES+=usr/lib/libugidfw_p.a OLD_FILES+=usr/lib/libusbhid_p.a OLD_FILES+=usr/lib/libutil_p.a OLD_FILES+=usr/lib/libvgl_p.a OLD_FILES+=usr/lib/libwind_p.a OLD_FILES+=usr/lib/libwrap_p.a OLD_FILES+=usr/lib/liby_p.a OLD_FILES+=usr/lib/libypclnt_p.a OLD_FILES+=usr/lib/libz_p.a OLD_FILES+=usr/lib/private/libldns_p.a OLD_FILES+=usr/lib/private/libssh_p.a .endif .if ${MK_RCMDS} == no OLD_FILES+=bin/rcp OLD_FILES+=etc/rc.d/rwho OLD_FILES+=etc/periodic/daily/140.clean-rwho OLD_FILES+=etc/periodic/daily/430.status-rwho OLD_FILES+=rescue/rcp OLD_FILES+=usr/bin/rlogin OLD_FILES+=usr/bin/rsh OLD_FILES+=usr/bin/ruptime OLD_FILES+=usr/bin/rwho OLD_FILES+=usr/libexec/rlogind OLD_FILES+=usr/libexec/rshd OLD_FILES+=usr/sbin/rwhod OLD_FILES+=usr/share/man/man1/rcp.1.gz OLD_FILES+=usr/share/man/man1/rlogin.1.gz OLD_FILES+=usr/share/man/man1/rsh.1.gz OLD_FILES+=usr/share/man/man1/ruptime.1.gz OLD_FILES+=usr/share/man/man1/rwho.1.gz OLD_FILES+=usr/share/man/man8/rlogind.8.gz OLD_FILES+=usr/share/man/man8/rshd.8.gz OLD_FILES+=usr/share/man/man8/rwhod.8.gz .endif .if ${MK_RCS} == no OLD_FILES+=usr/bin/ci OLD_FILES+=usr/bin/co OLD_FILES+=usr/bin/ident OLD_FILES+=usr/bin/merge OLD_FILES+=usr/bin/rcs OLD_FILES+=usr/bin/rcsclean OLD_FILES+=usr/bin/rcsdiff OLD_FILES+=usr/bin/rcsfreeze OLD_FILES+=usr/bin/rcsmerge OLD_FILES+=usr/bin/rlog OLD_FILES+=usr/sbin/etcupdate OLD_FILES+=usr/share/man/man1/ci.1.gz OLD_FILES+=usr/share/man/man1/co.1.gz OLD_FILES+=usr/share/man/man1/ident.1.gz OLD_FILES+=usr/share/man/man1/merge.1.gz OLD_FILES+=usr/share/man/man1/rcs.1.gz OLD_FILES+=usr/share/man/man1/rcsclean.1.gz OLD_FILES+=usr/share/man/man1/rcsdiff.1.gz OLD_FILES+=usr/share/man/man1/rcsfreeze.1.gz OLD_FILES+=usr/share/man/man1/rcsintro.1.gz OLD_FILES+=usr/share/man/man1/rcsmerge.1.gz OLD_FILES+=usr/share/man/man1/rlog.1.gz OLD_FILES+=usr/share/man/man5/rcsfile.5.gz OLD_FILES+=usr/share/man/man8/etcupdate.8.gz .endif #.if ${MK_RESCUE} == no # to be filled in or replaced with a special target #.endif .if ${MK_ROUTED} == no OLD_FILES+=sbin/routed OLD_FILES+=sbin/rtquery OLD_FILES+=usr/share/man/man8/routed.8.gz OLD_FILES+=usr/share/man/man8/rtquery.8.gz .endif .if ${MK_SENDMAIL} == no OLD_FILES+=etc/periodic/daily/150.clean-hoststat OLD_FILES+=etc/periodic/daily/440.status-mailq OLD_FILES+=etc/periodic/daily/460.status-mail-rejects OLD_FILES+=etc/periodic/daily/500.queuerun .if ${MK_MAILWRAPPER} == no OLD_FILES+=bin/rmail .endif OLD_FILES+=usr/bin/vacation OLD_FILES+=usr/include/libmilter/mfapi.h OLD_FILES+=usr/include/libmilter/mfdef.h OLD_DIRS+=usr/include/libmilter OLD_FILES+=usr/lib/libmilter.a OLD_FILES+=usr/lib/libmilter.so OLD_LIBS+=usr/lib/libmilter.so.5 OLD_FILES+=usr/lib/libmilter_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/libmilter.a OLD_FILES+=usr/lib32/libmilter.so OLD_LIBS+=usr/lib32/libmilter.so.5 OLD_FILES+=usr/lib32/libmilter_p.a .endif OLD_FILES+=usr/libexec/mail.local OLD_FILES+=usr/libexec/sendmail/sendmail OLD_FILES+=usr/libexec/smrsh OLD_FILES+=usr/sbin/editmap OLD_FILES+=usr/sbin/mailstats OLD_FILES+=usr/sbin/makemap OLD_FILES+=usr/sbin/praliases OLD_FILES+=usr/share/doc/smm/08.sendmailop/paper.ascii.gz OLD_DIRS+=usr/share/doc/smm/08.sendmailop OLD_FILES+=usr/share/man/man1/mailq.1.gz OLD_FILES+=usr/share/man/man1/newaliases.1.gz OLD_FILES+=usr/share/man/man1/vacation.1.gz OLD_FILES+=usr/share/man/man5/aliases.5.gz OLD_FILES+=usr/share/man/man8/editmap.8.gz OLD_FILES+=usr/share/man/man8/hoststat.8.gz OLD_FILES+=usr/share/man/man8/mail.local.8.gz OLD_FILES+=usr/share/man/man8/mailstats.8.gz OLD_FILES+=usr/share/man/man8/makemap.8.gz OLD_FILES+=usr/share/man/man8/praliases.8.gz OLD_FILES+=usr/share/man/man8/purgestat.8.gz OLD_FILES+=usr/share/man/man8/rmail.8.gz OLD_FILES+=usr/share/man/man8/sendmail.8.gz OLD_FILES+=usr/share/man/man8/smrsh.8.gz OLD_FILES+=usr/share/sendmail/cf/README OLD_FILES+=usr/share/sendmail/cf/cf/Makefile OLD_FILES+=usr/share/sendmail/cf/cf/README OLD_FILES+=usr/share/sendmail/cf/cf/chez.cs.mc OLD_FILES+=usr/share/sendmail/cf/cf/clientproto.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-hpux10.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-hpux9.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-osf1.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-solaris2.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-sunos4.1.mc OLD_FILES+=usr/share/sendmail/cf/cf/cs-ultrix4.mc OLD_FILES+=usr/share/sendmail/cf/cf/cyrusproto.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-bsd4.4.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-hpux10.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-hpux9.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-linux.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-mpeix.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-nextstep3.3.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-osf1.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-solaris.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-sunos4.1.mc OLD_FILES+=usr/share/sendmail/cf/cf/generic-ultrix4.mc OLD_FILES+=usr/share/sendmail/cf/cf/huginn.cs.mc OLD_FILES+=usr/share/sendmail/cf/cf/knecht.mc OLD_FILES+=usr/share/sendmail/cf/cf/mail.cs.mc OLD_FILES+=usr/share/sendmail/cf/cf/mail.eecs.mc OLD_FILES+=usr/share/sendmail/cf/cf/mailspool.cs.mc OLD_FILES+=usr/share/sendmail/cf/cf/python.cs.mc OLD_FILES+=usr/share/sendmail/cf/cf/s2k-osf1.mc OLD_FILES+=usr/share/sendmail/cf/cf/s2k-ultrix4.mc OLD_FILES+=usr/share/sendmail/cf/cf/submit.cf OLD_FILES+=usr/share/sendmail/cf/cf/submit.mc OLD_FILES+=usr/share/sendmail/cf/cf/tcpproto.mc OLD_FILES+=usr/share/sendmail/cf/cf/ucbarpa.mc OLD_FILES+=usr/share/sendmail/cf/cf/ucbvax.mc OLD_FILES+=usr/share/sendmail/cf/cf/uucpproto.mc OLD_FILES+=usr/share/sendmail/cf/cf/vangogh.cs.mc OLD_DIRS+=usr/share/sendmail/cf/cf OLD_FILES+=usr/share/sendmail/cf/domain/Berkeley.EDU.m4 OLD_FILES+=usr/share/sendmail/cf/domain/CS.Berkeley.EDU.m4 OLD_FILES+=usr/share/sendmail/cf/domain/EECS.Berkeley.EDU.m4 OLD_FILES+=usr/share/sendmail/cf/domain/S2K.Berkeley.EDU.m4 OLD_FILES+=usr/share/sendmail/cf/domain/berkeley-only.m4 OLD_FILES+=usr/share/sendmail/cf/domain/generic.m4 OLD_DIRS+=usr/share/sendmail/cf/domain OLD_FILES+=usr/share/sendmail/cf/feature/accept_unqualified_senders.m4 OLD_FILES+=usr/share/sendmail/cf/feature/accept_unresolvable_domains.m4 OLD_FILES+=usr/share/sendmail/cf/feature/access_db.m4 OLD_FILES+=usr/share/sendmail/cf/feature/allmasquerade.m4 OLD_FILES+=usr/share/sendmail/cf/feature/always_add_domain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/authinfo.m4 OLD_FILES+=usr/share/sendmail/cf/feature/badmx.m4 OLD_FILES+=usr/share/sendmail/cf/feature/bestmx_is_local.m4 OLD_FILES+=usr/share/sendmail/cf/feature/bitdomain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/blacklist_recipients.m4 OLD_FILES+=usr/share/sendmail/cf/feature/block_bad_helo.m4 OLD_FILES+=usr/share/sendmail/cf/feature/compat_check.m4 OLD_FILES+=usr/share/sendmail/cf/feature/conncontrol.m4 OLD_FILES+=usr/share/sendmail/cf/feature/delay_checks.m4 OLD_FILES+=usr/share/sendmail/cf/feature/dnsbl.m4 OLD_FILES+=usr/share/sendmail/cf/feature/domaintable.m4 OLD_FILES+=usr/share/sendmail/cf/feature/enhdnsbl.m4 OLD_FILES+=usr/share/sendmail/cf/feature/generics_entire_domain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/genericstable.m4 OLD_FILES+=usr/share/sendmail/cf/feature/greet_pause.m4 OLD_FILES+=usr/share/sendmail/cf/feature/ldap_routing.m4 OLD_FILES+=usr/share/sendmail/cf/feature/limited_masquerade.m4 OLD_FILES+=usr/share/sendmail/cf/feature/local_lmtp.m4 OLD_FILES+=usr/share/sendmail/cf/feature/local_no_masquerade.m4 OLD_FILES+=usr/share/sendmail/cf/feature/local_procmail.m4 OLD_FILES+=usr/share/sendmail/cf/feature/lookupdotdomain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/loose_relay_check.m4 OLD_FILES+=usr/share/sendmail/cf/feature/mailertable.m4 OLD_FILES+=usr/share/sendmail/cf/feature/masquerade_entire_domain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/masquerade_envelope.m4 OLD_FILES+=usr/share/sendmail/cf/feature/msp.m4 OLD_FILES+=usr/share/sendmail/cf/feature/mtamark.m4 OLD_FILES+=usr/share/sendmail/cf/feature/no_default_msa.m4 OLD_FILES+=usr/share/sendmail/cf/feature/nocanonify.m4 OLD_FILES+=usr/share/sendmail/cf/feature/notsticky.m4 OLD_FILES+=usr/share/sendmail/cf/feature/nouucp.m4 OLD_FILES+=usr/share/sendmail/cf/feature/nullclient.m4 OLD_FILES+=usr/share/sendmail/cf/feature/preserve_local_plus_detail.m4 OLD_FILES+=usr/share/sendmail/cf/feature/preserve_luser_host.m4 OLD_FILES+=usr/share/sendmail/cf/feature/promiscuous_relay.m4 OLD_FILES+=usr/share/sendmail/cf/feature/queuegroup.m4 OLD_FILES+=usr/share/sendmail/cf/feature/ratecontrol.m4 OLD_FILES+=usr/share/sendmail/cf/feature/redirect.m4 OLD_FILES+=usr/share/sendmail/cf/feature/relay_based_on_MX.m4 OLD_FILES+=usr/share/sendmail/cf/feature/relay_entire_domain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/relay_hosts_only.m4 OLD_FILES+=usr/share/sendmail/cf/feature/relay_local_from.m4 OLD_FILES+=usr/share/sendmail/cf/feature/relay_mail_from.m4 OLD_FILES+=usr/share/sendmail/cf/feature/require_rdns.m4 OLD_FILES+=usr/share/sendmail/cf/feature/smrsh.m4 OLD_FILES+=usr/share/sendmail/cf/feature/stickyhost.m4 OLD_FILES+=usr/share/sendmail/cf/feature/use_client_ptr.m4 OLD_FILES+=usr/share/sendmail/cf/feature/use_ct_file.m4 OLD_FILES+=usr/share/sendmail/cf/feature/use_cw_file.m4 OLD_FILES+=usr/share/sendmail/cf/feature/uucpdomain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/virtuser_entire_domain.m4 OLD_FILES+=usr/share/sendmail/cf/feature/virtusertable.m4 OLD_DIRS+=usr/share/sendmail/cf/feature OLD_FILES+=usr/share/sendmail/cf/hack/cssubdomain.m4 OLD_DIRS+=usr/share/sendmail/cf/hack OLD_FILES+=usr/share/sendmail/cf/m4/cf.m4 OLD_FILES+=usr/share/sendmail/cf/m4/cfhead.m4 OLD_FILES+=usr/share/sendmail/cf/m4/proto.m4 OLD_FILES+=usr/share/sendmail/cf/m4/version.m4 OLD_DIRS+=usr/share/sendmail/cf/m4 OLD_FILES+=usr/share/sendmail/cf/mailer/cyrus.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/cyrusv2.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/fax.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/local.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/mail11.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/phquery.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/pop.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/procmail.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/qpage.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/smtp.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/usenet.m4 OLD_FILES+=usr/share/sendmail/cf/mailer/uucp.m4 OLD_DIRS+=usr/share/sendmail/cf/mailer OLD_FILES+=usr/share/sendmail/cf/ostype/a-ux.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/aix3.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/aix4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/aix5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/altos.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/amdahl-uts.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/bsd4.3.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/bsd4.4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/bsdi.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/bsdi1.0.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/bsdi2.0.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/darwin.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/dgux.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/domainos.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/dragonfly.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/dynix3.2.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/freebsd4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/freebsd5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/freebsd6.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/gnu.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/hpux10.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/hpux11.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/hpux9.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/irix4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/irix5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/irix6.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/isc4.1.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/linux.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/maxion.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/mklinux.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/mpeix.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/nextstep.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/openbsd.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/osf1.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/powerux.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/ptx2.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/qnx.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/riscos4.5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/sco-uw-2.1.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/sco3.2.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/sinix.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/solaris11.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/solaris2.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/solaris2.ml.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/solaris2.pre5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/solaris8.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/sunos3.5.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/sunos4.1.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/svr4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/ultrix4.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/unicos.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/unicosmk.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/unicosmp.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/unixware7.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/unknown.m4 OLD_FILES+=usr/share/sendmail/cf/ostype/uxpds.m4 OLD_DIRS+=usr/share/sendmail/cf/ostype OLD_FILES+=usr/share/sendmail/cf/sendmail.schema OLD_FILES+=usr/share/sendmail/cf/sh/makeinfo.sh OLD_DIRS+=usr/share/sendmail/cf/sh OLD_FILES+=usr/share/sendmail/cf/siteconfig/uucp.cogsci.m4 OLD_FILES+=usr/share/sendmail/cf/siteconfig/uucp.old.arpa.m4 OLD_FILES+=usr/share/sendmail/cf/siteconfig/uucp.ucbarpa.m4 OLD_FILES+=usr/share/sendmail/cf/siteconfig/uucp.ucbvax.m4 OLD_DIRS+=usr/share/sendmail/cf/siteconfig OLD_DIRS+=usr/share/sendmail/cf OLD_DIRS+=usr/share/sendmail .endif #.if ${MK_SHAREDOCS} == no # to be filled in #.endif #.if ${MK_SYSCONS} == no # to be filled in #.endif .if ${MK_TCSH} == no OLD_FILES+=bin/csh OLD_FILES+=bin/tcsh OLD_FILES+=rescue/csh OLD_FILES+=rescue/tcsh OLD_FILES+=usr/share/examples/tcsh/complete.tcsh OLD_FILES+=usr/share/examples/tcsh/csh-mode.el OLD_DIRS+=usr/share/examples/tcsh OLD_FILES+=usr/share/man/man1/csh.1.gz OLD_FILES+=usr/share/man/man1/tcsh.1.gz OLD_FILES+=usr/share/nls/de_AT.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/de_AT.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/de_AT.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/de_CH.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/de_CH.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/de_CH.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/de_DE.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/de_DE.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/de_DE.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/el_GR.ISO8859-7/tcsh.cat OLD_FILES+=usr/share/nls/el_GR.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/es_ES.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/es_ES.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/es_ES.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/et_EE.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/et_EE.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/fi_FI.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/fi_FI.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/fi_FI.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/fr_BE.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/fr_BE.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/fr_BE.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/fr_CA.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/fr_CA.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/fr_CA.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/fr_CH.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/fr_CH.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/fr_CH.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/fr_FR.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/fr_FR.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/fr_FR.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/it_CH.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/it_CH.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/it_CH.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/it_IT.ISO8859-1/tcsh.cat OLD_FILES+=usr/share/nls/it_IT.ISO8859-15/tcsh.cat OLD_FILES+=usr/share/nls/it_IT.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/ja_JP.SJIS/tcsh.cat OLD_FILES+=usr/share/nls/ja_JP.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/ja_JP.eucJP/tcsh.cat OLD_FILES+=usr/share/nls/ru_RU.CP1251/tcsh.cat OLD_FILES+=usr/share/nls/ru_RU.CP866/tcsh.cat OLD_FILES+=usr/share/nls/ru_RU.ISO8859-5/tcsh.cat OLD_FILES+=usr/share/nls/ru_RU.KOI8-R/tcsh.cat OLD_FILES+=usr/share/nls/ru_RU.UTF-8/tcsh.cat OLD_FILES+=usr/share/nls/uk_UA.ISO8859-5/tcsh.cat OLD_FILES+=usr/share/nls/uk_UA.KOI8-U/tcsh.cat OLD_FILES+=usr/share/nls/uk_UA.UTF-8/tcsh.cat .endif .if ${MK_TELNET} == no OLD_FILES+=usr/bin/telnet OLD_FILES+=usr/libexec/telnetd OLD_FILES+=usr/share/man/man1/telnet.1.gz OLD_FILES+=usr/share/man/man8/telnetd.8.gz .endif .if ${MK_TESTS} == yes OLD_FILES+=usr/bin/atf-sh +OLD_FILES+=usr/include/atf-c++/config.hpp +OLD_FILES+=usr/include/atf-c/config.h OLD_LIBS+=usr/lib/libatf-c++.a OLD_LIBS+=usr/lib/libatf-c++.so OLD_LIBS+=usr/lib/libatf-c++.so.1 OLD_LIBS+=usr/lib/libatf-c++.so.2 OLD_LIBS+=usr/lib/libatf-c++_p.a OLD_LIBS+=usr/lib/libatf-c.a OLD_LIBS+=usr/lib/libatf-c.so OLD_LIBS+=usr/lib/libatf-c.so.1 OLD_LIBS+=usr/lib/libatf-c_p.a -OLD_LIBS+=usr/lib/private/libatf-c.so.1 -OLD_LIBS+=usr/lib/private/libatf-c++.so.2 +OLD_LIBS+=usr/lib/private/libatf-c.so.0 +OLD_LIBS+=usr/lib/private/libatf-c++.so.1 .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_LIBS+=usr/lib32/libatf-c++.a OLD_LIBS+=usr/lib32/libatf-c++.so OLD_LIBS+=usr/lib32/libatf-c++.so.1 OLD_LIBS+=usr/lib32/libatf-c++.so.2 OLD_LIBS+=usr/lib32/libatf-c++_p.a OLD_LIBS+=usr/lib32/libatf-c.a OLD_LIBS+=usr/lib32/libatf-c.so OLD_LIBS+=usr/lib32/libatf-c.so.1 OLD_LIBS+=usr/lib32/libatf-c_p.a -OLD_LIBS+=usr/lib32/private/libatf-c.so.1 -OLD_LIBS+=usr/lib32/private/libatf-c++.so.2 +OLD_LIBS+=usr/lib32/private/libatf-c.so.0 +OLD_LIBS+=usr/lib32/private/libatf-c++.so.1 .endif OLD_FILES+=usr/libdata/pkgconfig/atf-c++.pc OLD_FILES+=usr/libdata/pkgconfig/atf-c.pc OLD_FILES+=usr/libdata/pkgconfig/atf-sh.pc OLD_FILES+=usr/share/aclocal/atf-c++.m4 OLD_FILES+=usr/share/aclocal/atf-c.m4 OLD_FILES+=usr/share/aclocal/atf-common.m4 OLD_FILES+=usr/share/aclocal/atf-sh.m4 OLD_DIRS+=usr/share/aclocal OLD_FILES+=usr/tests/bin/chown/units_basics OLD_FILES+=usr/tests/bin/date/legacy_test OLD_FILES+=usr/tests/bin/sh/legacy_test OLD_FILES+=usr/tests/usr.bin/atf/Kyuafile OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/Kyuafile OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/atf_check_test OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/config_test OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/integration_test OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/misc_helpers OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/normalize_test OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/tc_test OLD_FILES+=usr/tests/usr.bin/atf/atf-sh/tp_test OLD_DIRS+=usr/tests/usr.bin/atf/atf-sh OLD_DIRS+=usr/tests/usr.bin/atf OLD_FILES+=usr/tests/lib/atf/libatf-c/test_helpers_test OLD_FILES+=usr/tests/lib/atf/test-programs/fork_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/application_test +OLD_FILES+=usr/tests/lib/atf/libatf-c++/config_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/detail/expand_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/detail/parser_test +OLD_FILES+=usr/tests/lib/atf/libatf-c++/detail/sanity_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/detail/ui_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/env_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/exceptions_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/expand_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/fs_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/parser_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/process_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/sanity_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/pkg_config_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/text_test OLD_FILES+=usr/tests/lib/atf/libatf-c++/ui_test +OLD_FILES+=usr/tests/lib/atf/libatf-c/config_test OLD_FILES+=usr/tests/lib/atf/libatf-c/dynstr_test OLD_FILES+=usr/tests/lib/atf/libatf-c/env_test OLD_FILES+=usr/tests/lib/atf/libatf-c/fs_test OLD_FILES+=usr/tests/lib/atf/libatf-c/list_test OLD_FILES+=usr/tests/lib/atf/libatf-c/map_test OLD_FILES+=usr/tests/lib/atf/libatf-c/pkg_config_test OLD_FILES+=usr/tests/lib/atf/libatf-c/process_helpers OLD_FILES+=usr/tests/lib/atf/libatf-c/process_test OLD_FILES+=usr/tests/lib/atf/libatf-c/sanity_test OLD_FILES+=usr/tests/lib/atf/libatf-c/text_test OLD_FILES+=usr/tests/lib/atf/libatf-c/user_test .if ${MK_MAKE} == yes OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/legacy_test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.status.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stderr.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/expected.stdout.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd/libtest.a OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/legacy_test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.status.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stderr.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/expected.stdout.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod/libtest.a OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/legacy_test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.status.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stderr.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.3 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.4 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.5 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.6 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/expected.stdout.7 OLD_FILES+=usr/tests/usr.bin/make/archives/fmt_oldbsd/libtest.a OLD_FILES+=usr/tests/usr.bin/make/archives/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/basic/t0/legacy_test OLD_FILES+=usr/tests/usr.bin/make/basic/t0/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/basic/t0/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t0/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t0/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t1/legacy_test OLD_FILES+=usr/tests/usr.bin/make/basic/t1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/basic/t1/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/basic/t1/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t1/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t1/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t2/legacy_test OLD_FILES+=usr/tests/usr.bin/make/basic/t2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/basic/t2/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/basic/t2/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t2/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t2/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t3/legacy_test OLD_FILES+=usr/tests/usr.bin/make/basic/t3/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/basic/t3/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t3/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/basic/t3/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/basic/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/legacy_test OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/execution/ellipsis/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/execution/empty/legacy_test OLD_FILES+=usr/tests/usr.bin/make/execution/empty/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/execution/empty/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/execution/empty/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/execution/empty/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/execution/empty/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/legacy_test OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/execution/joberr/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/execution/plus/legacy_test OLD_FILES+=usr/tests/usr.bin/make/execution/plus/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/execution/plus/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/execution/plus/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/execution/plus/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/execution/plus/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/execution/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/builtin/sh OLD_FILES+=usr/tests/usr.bin/make/shell/meta/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/meta/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/meta/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/meta/sh OLD_FILES+=usr/tests/usr.bin/make/shell/path/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/path/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/path/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path/sh OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/path_select/shell OLD_FILES+=usr/tests/usr.bin/make/shell/replace/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/replace/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/replace/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/replace/shell OLD_FILES+=usr/tests/usr.bin/make/shell/select/legacy_test OLD_FILES+=usr/tests/usr.bin/make/shell/select/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/shell/select/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/shell/select/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/shell/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/legacy_test OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/TEST1.a OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/basic/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/legacy_test OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/TEST1.a OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/TEST2.a OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild1/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/legacy_test OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/TEST1.a OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/TEST2.a OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/src_wild2/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/suffixes/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/legacy_test OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/directive-t0/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/legacy_test OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.status.3 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.status.4 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.status.5 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stderr.3 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stderr.4 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stderr.5 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stdout.3 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stdout.4 OLD_FILES+=usr/tests/usr.bin/make/syntax/enl/expected.stdout.5 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/legacy_test OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/funny-targets/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/legacy_test OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/syntax/semi/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/syntax/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/legacy_test OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/1/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/mk/sys.mk OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/mk/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t0/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/legacy_test OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/cleanup OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/1/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/mk/sys.mk OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/mk/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/legacy_test OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/cleanup OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/1/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/mk/sys.mk OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/mk/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/t2/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/sysmk/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/legacy_test OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_M/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/legacy_test OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.status.3 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stderr.3 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/variables/modifier_t/expected.stdout.3 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/legacy_test OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.status.2 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.stderr.2 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/variables/opt_V/expected.stdout.2 OLD_FILES+=usr/tests/usr.bin/make/variables/t0/legacy_test OLD_FILES+=usr/tests/usr.bin/make/variables/t0/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/variables/t0/Makefile.test OLD_FILES+=usr/tests/usr.bin/make/variables/t0/expected.status.1 OLD_FILES+=usr/tests/usr.bin/make/variables/t0/expected.stderr.1 OLD_FILES+=usr/tests/usr.bin/make/variables/t0/expected.stdout.1 OLD_FILES+=usr/tests/usr.bin/make/variables/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/Kyuafile OLD_FILES+=usr/tests/usr.bin/make/common.sh OLD_FILES+=usr/tests/usr.bin/make/test-new.mk OLD_DIRS+=usr/tests/usr.bin/make/variables/t0 OLD_DIRS+=usr/tests/usr.bin/make/variables/opt_V OLD_DIRS+=usr/tests/usr.bin/make/variables/modifier_t OLD_DIRS+=usr/tests/usr.bin/make/variables/modifier_M OLD_DIRS+=usr/tests/usr.bin/make/variables OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t2/mk OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t2/2/1 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t2/2 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t2 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t1/mk OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t1/2/1 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t1/2 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t1 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t0/mk OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t0/2/1 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t0/2 OLD_DIRS+=usr/tests/usr.bin/make/sysmk/t0 OLD_DIRS+=usr/tests/usr.bin/make/sysmk OLD_DIRS+=usr/tests/usr.bin/make/syntax/semi OLD_DIRS+=usr/tests/usr.bin/make/syntax/funny-targets OLD_DIRS+=usr/tests/usr.bin/make/syntax/enl OLD_DIRS+=usr/tests/usr.bin/make/syntax/directive-t0 OLD_DIRS+=usr/tests/usr.bin/make/syntax OLD_DIRS+=usr/tests/usr.bin/make/suffixes/src_wild2 OLD_DIRS+=usr/tests/usr.bin/make/suffixes/src_wild1 OLD_DIRS+=usr/tests/usr.bin/make/suffixes/basic OLD_DIRS+=usr/tests/usr.bin/make/suffixes OLD_DIRS+=usr/tests/usr.bin/make/shell/select OLD_DIRS+=usr/tests/usr.bin/make/shell/replace OLD_DIRS+=usr/tests/usr.bin/make/shell/path_select OLD_DIRS+=usr/tests/usr.bin/make/shell/path OLD_DIRS+=usr/tests/usr.bin/make/shell/meta OLD_DIRS+=usr/tests/usr.bin/make/shell/builtin OLD_DIRS+=usr/tests/usr.bin/make/shell OLD_DIRS+=usr/tests/usr.bin/make/execution/plus OLD_DIRS+=usr/tests/usr.bin/make/execution/joberr OLD_DIRS+=usr/tests/usr.bin/make/execution/empty OLD_DIRS+=usr/tests/usr.bin/make/execution/ellipsis OLD_DIRS+=usr/tests/usr.bin/make/execution OLD_DIRS+=usr/tests/usr.bin/make/basic/t3 OLD_DIRS+=usr/tests/usr.bin/make/basic/t2 OLD_DIRS+=usr/tests/usr.bin/make/basic/t1 OLD_DIRS+=usr/tests/usr.bin/make/basic/t0 OLD_DIRS+=usr/tests/usr.bin/make/basic OLD_DIRS+=usr/tests/usr.bin/make/archives/fmt_oldbsd OLD_DIRS+=usr/tests/usr.bin/make/archives/fmt_44bsd_mod OLD_DIRS+=usr/tests/usr.bin/make/archives/fmt_44bsd OLD_DIRS+=usr/tests/usr.bin/make/archives OLD_DIRS+=usr/tests/usr.bin/make OLD_FILES+=usr/tests/usr.bin/yacc/legacy_test OLD_FILES+=usr/tests/usr.bin/yacc/regress.00.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.01.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.02.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.03.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.04.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.05.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.06.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.07.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.08.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.09.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.10.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.11.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.12.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.13.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.14.out OLD_FILES+=usr/tests/usr.bin/yacc/regress.sh OLD_FILES+=usr/tests/usr.bin/yacc/undefined.y .endif .else # ATF libraries. OLD_FILES+=usr/bin/atf-sh OLD_DIRS+=usr/include/atf-c OLD_FILES+=usr/include/atf-c/build.h OLD_FILES+=usr/include/atf-c/check.h OLD_FILES+=usr/include/atf-c/config.h OLD_FILES+=usr/include/atf-c/defs.h OLD_FILES+=usr/include/atf-c/error.h OLD_FILES+=usr/include/atf-c/error_fwd.h OLD_FILES+=usr/include/atf-c/macros.h OLD_FILES+=usr/include/atf-c/tc.h OLD_FILES+=usr/include/atf-c/tp.h OLD_FILES+=usr/include/atf-c/utils.h OLD_FILES+=usr/include/atf-c.h OLD_DIRS+=usr/include/atf-c++ OLD_FILES+=usr/include/atf-c++/build.hpp OLD_FILES+=usr/include/atf-c++/check.hpp OLD_FILES+=usr/include/atf-c++/config.hpp OLD_FILES+=usr/include/atf-c++/macros.hpp OLD_FILES+=usr/include/atf-c++/tests.hpp OLD_FILES+=usr/include/atf-c++/utils.hpp OLD_FILES+=usr/include/atf-c++.hpp OLD_FILES+=usr/lib/libatf-c_p.a OLD_FILES+=usr/lib/libatf-c.so.1 OLD_FILES+=usr/lib/libatf-c.so OLD_FILES+=usr/lib/libatf-c++.a OLD_FILES+=usr/lib/libatf-c++_p.a OLD_FILES+=usr/lib/libatf-c++.so.1 OLD_FILES+=usr/lib/libatf-c++.so OLD_FILES+=usr/lib/libatf-c.a OLD_FILES+=usr/libexec/atf-check OLD_DIRS+=usr/share/atf OLD_FILES+=usr/share/atf/libatf-sh.subr OLD_DIRS+=usr/share/doc/atf OLD_FILES+=usr/share/doc/atf/AUTHORS OLD_FILES+=usr/share/doc/atf/COPYING OLD_FILES+=usr/share/doc/atf/NEWS OLD_FILES+=usr/share/doc/atf/README OLD_FILES+=usr/share/man/man1/atf-check.1.gz OLD_FILES+=usr/share/man/man1/atf-sh.1.gz OLD_FILES+=usr/share/man/man1/atf-test-program.1.gz OLD_FILES+=usr/share/man/man3/atf-c-api.3.gz OLD_FILES+=usr/share/man/man3/atf-c++-api.3.gz OLD_FILES+=usr/share/man/man3/atf-sh-api.3.gz OLD_FILES+=usr/share/man/man4/atf-test-case.4.gz OLD_FILES+=usr/share/mk/atf.test.mk # Test suite. . if(exists(${DESTDIR}/usr/tests/)) TESTS_DIRS!=find ${DESTDIR}/usr/tests -type d | sed -e 's,^${DESTDIR}/,,'; echo OLD_DIRS+=${TESTS_DIRS} TESTS_FILES!=find ${DESTDIR}/usr/tests \! -type d | sed -e 's,^${DESTDIR}/,,'; echo OLD_FILES+=${TESTS_FILES} . endif .endif # Test suite. #.if ${MK_TOOLCHAIN} == no # to be filled in #.endif .if ${MK_UNBOUND} == no OLD_FILES+=etc/rc.d/local_unbound OLD_FILES+=usr/lib/private/libunbound.a OLD_FILES+=usr/lib/private/libunbound.so OLD_LIBS+=usr/lib/private/libunbound.so.5 OLD_FILES+=usr/lib/private/libunbound_p.a .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64" OLD_FILES+=usr/lib32/private/libunbound.a OLD_FILES+=usr/lib32/private/libunbound.so OLD_LIBS+=usr/lib32/private/libunbound.so.5 OLD_FILES+=usr/lib32/private/libunbound_p.a .endif OLD_FILES+=usr/sbin/local-unbound-setup OLD_FILES+=usr/sbin/unbound OLD_FILES+=usr/sbin/unbound-anchor OLD_FILES+=usr/sbin/unbound-checkconf OLD_FILES+=usr/sbin/unbound-control OLD_FILES+=usr/sbin/unbound-control-setup .endif .if ${MK_USB} == no OLD_FILES+=etc/devd/uauth.conf OLD_FILES+=etc/devd/usb.conf .endif .if ${MK_UTMPX} == no OLD_FILES+=etc/periodic/monthly/200.accounting OLD_FILES+=usr/bin/last OLD_FILES+=usr/bin/users OLD_FILES+=usr/bin/who OLD_FILES+=usr/sbin/ac OLD_FILES+=usr/sbin/lastlogin OLD_FILES+=usr/sbin/utx OLD_FILES+=usr/share/man/man1/last.1.gz OLD_FILES+=usr/share/man/man1/users.1.gz OLD_FILES+=usr/share/man/man1/who.1.gz OLD_FILES+=usr/share/man/man8/ac.8.gz OLD_FILES+=usr/share/man/man8/lastlogin.8.gz OLD_FILES+=usr/share/man/man8/utx.8.gz .endif .if ${MK_WIRELESS} == no OLD_FILES+=etc/regdomain.xml OLD_FILES+=usr/sbin/ancontrol OLD_FILES+=usr/sbin/hostapd OLD_FILES+=usr/sbin/hostapd_cli OLD_FILES+=usr/sbin/ndis_events OLD_FILES+=usr/sbin/wlandebug .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/sbin/wlconfig .endif OLD_FILES+=usr/sbin/wpa_cli OLD_FILES+=usr/sbin/wpa_passphrase OLD_FILES+=usr/sbin/wpa_supplicant OLD_FILES+=usr/share/examples/etc/regdomain.xml OLD_FILES+=usr/share/examples/etc/wpa_supplicant.conf OLD_FILES+=usr/share/examples/hostapd/hostapd.conf OLD_FILES+=usr/share/examples/hostapd/hostapd.eap_user OLD_FILES+=usr/share/examples/hostapd/hostapd.wpa_psk OLD_DIRS+=usr/share/examples/hostapd OLD_FILES+=usr/share/man/man5/hostapd.conf.5.gz OLD_FILES+=usr/share/man/man5/wpa_supplicant.conf.5.gz OLD_FILES+=usr/share/man/man8/ancontrol.8.gz OLD_FILES+=usr/share/man/man8/hostapd.8.gz OLD_FILES+=usr/share/man/man8/hostapd_cli.8.gz .if ${TARGET_ARCH} == "i386" OLD_FILES+=usr/share/man/man8/i386/wlconfig.8.gz .endif OLD_FILES+=usr/share/man/man8/ndis_events.8.gz OLD_FILES+=usr/share/man/man8/wlandebug.8.gz OLD_FILES+=usr/share/man/man8/wpa_cli.8.gz OLD_FILES+=usr/share/man/man8/wpa_passphrase.8.gz OLD_FILES+=usr/share/man/man8/wpa_supplicant.8.gz .endif .if ${MK_SVNLITE} == no || ${MK_SVN} == yes OLD_FILES+=usr/bin/svnlite OLD_FILES+=usr/bin/svnliteadmin OLD_FILES+=usr/bin/svnlitedumpfilter OLD_FILES+=usr/bin/svnlitelook OLD_FILES+=usr/bin/svnlitemucc OLD_FILES+=usr/bin/svnliterdump OLD_FILES+=usr/bin/svnliteserve OLD_FILES+=usr/bin/svnlitesync OLD_FILES+=usr/bin/svnliteversion OLD_FILES+=usr/share/man/man1/svnlite.1.gz .endif .if ${MK_SVN} == no OLD_FILES+=usr/bin/svn OLD_FILES+=usr/bin/svnadmin OLD_FILES+=usr/bin/svndumpfilter OLD_FILES+=usr/bin/svnlook OLD_FILES+=usr/bin/svnmucc OLD_FILES+=usr/bin/svnrdump OLD_FILES+=usr/bin/svnserve OLD_FILES+=usr/bin/svnsync OLD_FILES+=usr/bin/svnversion .endif .if ${MK_DMAGENT} == no OLD_FILES+=usr/libexec/dma OLD_FILES+=usr/libexec/dma-mbox-create OLD_FILES+=usr/share/man/man8/dma.8.gz OLD_FILES+=usr/share/examples/dma/mailer.conf .endif .if ${MK_HYPERV} == no OLD_FILES+=etc/devd/hyperv.conf OLD_FILES+=usr/libexec/hyperv/hv_set_ifconfig OLD_FILES+=usr/libexec/hyperv/hv_get_dns_info OLD_FILES+=usr/libexec/hyperv/hv_get_dhcp_info OLD_FILES+=usr/sbin/hv_kvp_daemon OLD_FILES+=usr/share/man/man8/hv_kvp_daemon.8.gz .endif