From owner-freebsd-testing@FreeBSD.ORG Thu Jan 9 23:34:13 2014 Return-Path: Delivered-To: freebsd-testing@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 02B5D1000 for ; Thu, 9 Jan 2014 23:34:13 +0000 (UTC) Received: from mail-ea0-f181.google.com (mail-ea0-f181.google.com [209.85.215.181]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8A9CF1AD0 for ; Thu, 9 Jan 2014 23:34:12 +0000 (UTC) Received: by mail-ea0-f181.google.com with SMTP id m10so1758209eaj.26 for ; Thu, 09 Jan 2014 15:34:05 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-type:content-disposition:user-agent; bh=vX+TCRPLYLS8rwp/HjdSRb/j7m3aQmybMOyYe+2Ay+w=; b=jgesx5z/KJyN0qq9cDCvcxat1RjeMvogpBypaocDuKuFM/XJeFVO1nGT9M/UXqN6/0 XHpouca7CF34xh9TNynAWTPyxdXkccvL0b0KBw/JhYnHM51FF5soYf6x/YF9ensPg0xw 6vv44j7dRT6v89zwmAs1LNgw0BZAKQcq2yoAH6e59L0jTAlZLqq71GXrI0lOdlEuA2gY Ahp5DkxtEms0G/JJserWjaaAazEFlfHSpOVhAjMT67B6peYIWM1+CsyD6t2lswaYqxen H87IJ4kQ8ncIc5IEmDgy/RnGdLA95FJXXlf4HQArsu6cDmgOH95fZR6TbOsw+iTMhWLx TqHw== X-Gm-Message-State: ALoCoQnWhhAzG4KG8WoTpq5MS+WZeFHhUHV7BtrMlKYkihkNym0r2fAsxs7n1MGPSgYg8+yVyzI5 X-Received: by 10.14.176.195 with SMTP id b43mr5130496eem.39.1389310445593; Thu, 09 Jan 2014 15:34:05 -0800 (PST) Received: from fbair.virtual.network ([109.255.125.95]) by mx.google.com with ESMTPSA id h3sm9793591eem.15.2014.01.09.15.34.04 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 09 Jan 2014 15:34:04 -0800 (PST) Date: Thu, 9 Jan 2014 18:34:02 -0500 From: Julio Merino To: freebsd-testing@freebsd.org Subject: Fixing installation of Kyuafiles Message-ID: <20140109233402.GA8193@fbair.virtual.network> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="/04w6evG8XlLl3ft" Content-Disposition: inline User-Agent: Mutt/1.5.22 (2013-10-16) Cc: sjg@freebsd.org X-BeenThere: freebsd-testing@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Testing on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jan 2014 23:34:13 -0000 --/04w6evG8XlLl3ft Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello, The bin/sh and bin/test tests are broken because they cannot be run as root, yet the testing machines are currently running stuff as root. This is easy to fix by adding a require_user="unprivileged" property to the tests. I was going to fix this by adding manually-crafted Kyuafile files that do the above in bin/sh/tests/ and bin/test/tests/ and setting KYUAFILE=yes in the corresponding Makefile files... but unfortunately that does not work with NO_CLEAN builds. The problem is that bsd.test.mk generates Kyuafile files in the obj directory and setting KYUAFILE=yes means that make will _still_ see the Kyuafile in the obj directory and not the one that just appeared in src. Does the attached patch seem reasonable to prevent this in the future? The patch does not fix current build trees with NO_CLEAN, but because WITH_TESTS is not yet the default I don't think it's a big deal. Thank you. --/04w6evG8XlLl3ft Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="kyuafiles.diff" Allow tests to provide a Kyuafile when they relied on auto-generation. When generating a Kyuafile in the KYUAFILE=auto case, use a filename that is unlikely to clash with the filename used by explicitly-provided Kyuafiles. This allows a Makefile to set KYUAFILE=yes and provide a Kyuafile in the same directory when such Makefile was previously relying on KYUAFILE=auto. Fixes issues with new Kyuafiles not being picked up in NO_CLEAN builds. Index: UPDATING =================================================================== --- UPDATING (revision 260496) +++ UPDATING (working copy) @@ -31,6 +31,14 @@ disable the most expensive debugging functionality run "ln -s 'abort:false,junk:false' /etc/malloc.conf".) +20140109: + If a Makefile in a tests/ directory was auto-generating a Kyuafile + instead of providing an explicit one, this would prevent such + Makefile from providing its own Kyuafile in the future during + NO_CLEAN builds. This has been fixed in the Makefiles but manual + intervention is needed to clean an objdir if you use NO_CLEAN: + # find /usr/obj -name Kyuafile | xargs rm -f + 20131213: The behavior of gss_pseudo_random() for the krb5 mechanism has changed, for applications requesting a longer random string Index: share/mk/bsd.test.mk =================================================================== --- share/mk/bsd.test.mk (revision 260496) +++ share/mk/bsd.test.mk (working copy) @@ -79,14 +79,17 @@ PROG_VARS+= BINDIR PROGS_TARGETS+= install -.if ${KYUAFILE:tl} != "no" +.if ${KYUAFILE:tl} == "yes" FILES+= Kyuafile FILESDIR_Kyuafile= ${TESTSDIR} +.elif ${KYUAFILE:tl} == "auto" +FILES+= Kyuafile.auto +FILESDIR_Kyuafile.auto= ${TESTSDIR} +FILESNAME_Kyuafile.auto= Kyuafile -.if ${KYUAFILE:tl} == "auto" -CLEANFILES+= Kyuafile Kyuafile.tmp +CLEANFILES+= Kyuafile.auto Kyuafile.auto.tmp -Kyuafile: Makefile +Kyuafile.auto: Makefile @{ \ echo '-- Automatically generated by bsd.test.mk.'; \ echo; \ @@ -94,17 +97,16 @@ echo; \ echo 'test_suite("${TESTSUITE}")'; \ echo; \ - } >Kyuafile.tmp + } >Kyuafile.auto.tmp .for _T in ${_TESTS} @echo "${TEST_INTERFACE.${_T}}_test_program{name=\"${_T}\"}" \ - >>Kyuafile.tmp + >>Kyuafile.auto.tmp .endfor .for _T in ${TESTS_SUBDIRS:N.WAIT} - @echo "include(\"${_T}/Kyuafile\")" >>Kyuafile.tmp + @echo "include(\"${_T}/Kyuafile\")" >>Kyuafile.auto.tmp .endfor - @mv Kyuafile.tmp Kyuafile + @mv Kyuafile.auto.tmp Kyuafile.auto .endif -.endif KYUA?= ${KYUA_PREFIX}/bin/kyua .if exists(${KYUA}) --/04w6evG8XlLl3ft--