public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Lars Wendler" <polynomial-c@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/make/, sys-devel/make/files/
Date: Mon, 23 May 2016 09:07:42 +0000 (UTC)	[thread overview]
Message-ID: <1463994458.aca8dbccd491139f8d0f8a6fcb690f7780933cf2.polynomial-c@gentoo> (raw)

commit:     aca8dbccd491139f8d0f8a6fcb690f7780933cf2
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon May 23 09:07:24 2016 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon May 23 09:07:38 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=aca8dbcc

sys-devel/make: Revbump to revert upstream commit for bug #583812

until a real fix is available.

Package-Manager: portage-2.2.28
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 ...x_double_colon_rules_plus_parallel_builds.patch | 139 +++++++++++++++++++++
 sys-devel/make/make-4.2-r1.ebuild                  |  54 ++++++++
 2 files changed, 193 insertions(+)

diff --git a/sys-devel/make/files/make-4.1-fix_double_colon_rules_plus_parallel_builds.patch b/sys-devel/make/files/make-4.1-fix_double_colon_rules_plus_parallel_builds.patch
new file mode 100644
index 0000000..af7a9f2
--- /dev/null
+++ b/sys-devel/make/files/make-4.1-fix_double_colon_rules_plus_parallel_builds.patch
@@ -0,0 +1,139 @@
+From 9bb994e8319c2b153cd3d6d61e2c2882895e7c3a Mon Sep 17 00:00:00 2001
+From: Joe Crayne <oh.hello.joe@gmail.com>
+Date: Sat, 21 May 2016 21:26:00 +0000
+Subject: [SV 44742] Fix double-colon rules plus parallel builds.
+
+* remake.c (update_file): Don't update double-colon target status
+if we're still building targets.
+(ftime_t): Don't propagate timestamps for double-colon targets that
+we've not examined yet.
+* tests/scripts/features/double_colon: Add parallel build tests.
+
+Copyright-paperwork-exempt: yes
+---
+diff --git a/remake.c b/remake.c
+index 63ee648..df1a9e0 100644
+--- a/remake.c
++++ b/remake.c
+@@ -320,7 +320,7 @@ update_file (struct file *file, unsigned int depth)
+             && !f->dontcare && f->no_diag))
+         {
+           DBF (DB_VERBOSE, _("Pruning file '%s'.\n"));
+-          return f->command_state == cs_finished ? f->update_status : 0;
++          return f->command_state == cs_finished ? f->update_status : us_success;
+         }
+     }
+ 
+@@ -344,12 +344,9 @@ update_file (struct file *file, unsigned int depth)
+ 
+       if (f->command_state == cs_running
+           || f->command_state == cs_deps_running)
+-        {
+-          /* Don't run the other :: rules for this
+-             file until this rule is finished.  */
+-          status = us_success;
+-          break;
+-        }
++        /* Don't run other :: rules for this target until
++           this rule is finished.  */
++        return us_success;
+ 
+       if (new > status)
+         status = new;
+@@ -1274,6 +1271,7 @@ FILE_TIMESTAMP
+ f_mtime (struct file *file, int search)
+ {
+   FILE_TIMESTAMP mtime;
++  int propagate_timestamp;
+ 
+   /* File's mtime is not known; must get it from the system.  */
+ 
+@@ -1450,10 +1448,13 @@ f_mtime (struct file *file, int search)
+         }
+     }
+ 
+-  /* Store the mtime into all the entries for this file.  */
++  /* Store the mtime into all the entries for this file for which it is safe
++     to do so: avoid propagating timestamps to double-colon rules that haven't
++     been examined so they're run or not based on the pre-update timestamp.  */
+   if (file->double_colon)
+     file = file->double_colon;
+ 
++  propagate_timestamp = file->updated;
+   do
+     {
+       /* If this file is not implicit but it is intermediate then it was
+@@ -1465,7 +1466,8 @@ f_mtime (struct file *file, int search)
+           && !file->tried_implicit && file->intermediate)
+         file->intermediate = 0;
+ 
+-      file->last_mtime = mtime;
++      if (file->updated == propagate_timestamp)
++        file->last_mtime = mtime;
+       file = file->prev;
+     }
+   while (file != 0);
+diff --git a/tests/scripts/features/double_colon b/tests/scripts/features/double_colon
+index 1097775..80ddb31 100644
+--- a/tests/scripts/features/double_colon
++++ b/tests/scripts/features/double_colon
+@@ -151,8 +151,7 @@ two');
+ 
+ unlink('result','one','two');
+ 
+-# TEST 10: check for proper backslash handling
+-#          Savannah bug #33399
++# TEST 10: SV 33399 : check for proper backslash handling
+ 
+ run_make_test('
+ a\ xb :: ; @echo one
+@@ -160,5 +159,47 @@ a\ xb :: ; @echo two
+ ',
+               '', "one\ntwo\n");
+ 
++# Test 11: SV 44742 : All double-colon rules should be run in parallel build.
++
++run_make_test('result :: 01
++	@echo update
++	@touch $@
++result :: 02
++	@echo update
++	@touch $@
++result :: 03
++	@echo update
++	@touch $@
++result :: 04
++	@echo update
++	@touch $@
++result :: 05
++	@echo update
++	@touch $@
++01 02 03 04 05:
++	@touch 01 02 03 04 05
++',
++              '-j10 result', "update\nupdate\nupdate\nupdate\nupdate\n");
++
++unlink('result', '01', '02', '03', '04', '05');
++
++# Test 12: SV 44742 : Double-colon rules with parallelism
++
++run_make_test('
++root: all
++	echo root
++all::
++	echo all_one
++all:: 3
++	echo all_two
++%:
++	sleep $*
++',
++              '-rs -j2 1 2 root', "all_one\nall_two\nroot\n");
++
+ # This tells the test driver that the perl test script executed properly.
+ 1;
++
++### Local Variables:
++### eval: (setq whitespace-action (delq 'auto-cleanup whitespace-action))
++### End:
+--
+cgit v0.9.0.2

diff --git a/sys-devel/make/make-4.2-r1.ebuild b/sys-devel/make/make-4.2-r1.ebuild
new file mode 100644
index 0000000..4f5d2e3
--- /dev/null
+++ b/sys-devel/make/make-4.2-r1.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit flag-o-matic eutils
+
+DESCRIPTION="Standard tool to compile source trees"
+HOMEPAGE="https://www.gnu.org/software/make/make.html"
+SRC_URI="mirror://gnu//make/${P}.tar.bz2"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~hppa-hpux ~ia64-hpux ~x86-interix ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="guile nls static"
+
+CDEPEND="guile? ( >=dev-scheme/guile-1.8:= )"
+DEPEND="${CDEPEND}
+	nls? ( sys-devel/gettext )"
+RDEPEND="${CDEPEND}
+	nls? ( virtual/libintl )"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-3.82-darwin-library_search-dylib.patch
+)
+
+src_prepare() {
+	epatch "${PATCHES[@]}"
+
+	# Revert this upstream commit until a real fix is available.
+	# See https://bugs.gentoo.org/583812
+	EPATCH_OPTS="-R" \
+	epatch "${FILESDIR}"/${PN}-4.1-fix_double_colon_rules_plus_parallel_builds.patch
+}
+
+src_configure() {
+	use static && append-ldflags -static
+	econf \
+		--program-prefix=g \
+		$(use_with guile) \
+		$(use_enable nls)
+}
+
+src_install() {
+	emake DESTDIR="${D}" install
+	dodoc AUTHORS NEWS README*
+	if [[ ${USERLAND} == "GNU" ]] ; then
+		# we install everywhere as 'gmake' but on GNU systems,
+		# symlink 'make' to 'gmake'
+		dosym gmake /usr/bin/make
+		dosym gmake.1 /usr/share/man/man1/make.1
+	fi
+}


             reply	other threads:[~2016-05-23  9:07 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-23  9:07 Lars Wendler [this message]
  -- strict thread matches above, loose matches on Subject: below --
2016-05-31  9:06 [gentoo-commits] repo/gentoo:master commit in: sys-devel/make/, sys-devel/make/files/ Lars Wendler
2017-04-14 15:34 Michał Górny
2017-04-14 16:28 Michał Górny
2018-02-10 23:41 Andreas Hüttel
2018-02-19  8:46 Lars Wendler
2018-03-16  8:47 Lars Wendler
2018-03-16  8:47 Lars Wendler
2018-08-04 13:51 Thomas Deutschmann
2018-08-27 19:48 Thomas Deutschmann
2022-04-29  6:12 Sam James

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1463994458.aca8dbccd491139f8d0f8a6fcb690f7780933cf2.polynomial-c@gentoo \
    --to=polynomial-c@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox