diff mbox series

[hurd,commited,3/7] hurd: make build-many-glibcs.py use mainline mig

Message ID 20180127225102.11373-4-samuel.thibault@ens-lyon.org
State New
Headers show
Series fix warnings | expand

Commit Message

Samuel Thibault Jan. 27, 2018, 10:50 p.m. UTC
Some warnings come from code generated by mig, so we need a very recent
version for now.

        * scripts/build-many-glibcs.py (checkout_vcs): Add mig repository
        URL, and run autoreconf, make it the default for now.
---
 ChangeLog                    | 2 ++
 scripts/build-many-glibcs.py | 9 ++++++++-
 2 files changed, 10 insertions(+), 1 deletion(-)

Comments

Joseph Myers Jan. 29, 2018, 2 p.m. UTC | #1
Followup committed:

Make build-many-glibcs.py clean git source directories.

With the git checkouts of Hurd components in build-many-glibcs.py
involving running autoreconf, there's a risk that generated files
could be left behind by an old autoreconf run (if an old version of
the sources generates those files in the source directory but a new
version does not).

This patch avoids that by using git clean -dxfq when updating git
checkouts.  In this patch, that's conditional on --replace-sources, to
avoid removing any local not-checked-in files someone may have in
their checkout unless the option has been specifically passed that
says it's OK to blow old checkouts away, complete with any local
changes to them.

2018-01-29  Joseph Myers  <joseph@codesourcery.com>

	* scripts/build-many-glibcs.py (Context.git_checkout): Use git
	clean -dxfq for git updates when replacing sources.

diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py
index 0c2ea85..baa6704 100755
--- a/scripts/build-many-glibcs.py
+++ b/scripts/build-many-glibcs.py
@@ -816,6 +816,9 @@ class Context(object):
         if update:
             subprocess.run(['git', 'remote', 'prune', 'origin'],
                            cwd=self.component_srcdir(component), check=True)
+            if self.replace_sources:
+                subprocess.run(['git', 'clean', '-dxfq'],
+                               cwd=self.component_srcdir(component), check=True)
             subprocess.run(['git', 'pull', '-q'],
                            cwd=self.component_srcdir(component), check=True)
         else:
diff mbox series

Patch

diff --git a/ChangeLog b/ChangeLog
index 7d7800dbb1..9582d8cfed 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -19,6 +19,8 @@ 
 	timer_ptr2id to cast struct timer_node * to void *.
 	* scripts/build-many-glibcs.py [os == gnu] (build_gcc): Pass
 	--disable-libcilkrts to gcc configure.
+	(checkout_vcs): Add mig repository URL, and run autoreconf, make it the
+	default for now.
 	* sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add
 	-DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c.
 	* mach/Machrules (MIGFLAGS): Do not set -DMACH_IPC_COMPAT=0.
diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py
index fbb701e25d..d7adcc8022 100755
--- a/scripts/build-many-glibcs.py
+++ b/scripts/build-many-glibcs.py
@@ -704,7 +704,7 @@  class Context(object):
                             'linux': '4.14',
                             'mpc': '1.1.0',
                             'mpfr': '4.0.0',
-                            'mig': '1.8',
+                            'mig': 'vcs-mainline',
                             'gnumach': '1.8',
                             'hurd': 'vcs-mainline'}
         use_versions = {}
@@ -786,6 +786,13 @@  class Context(object):
             r = self.git_checkout(component, git_url, git_branch, update)
             self.fix_glibc_timestamps()
             return r
+        elif component == 'mig':
+            git_url = 'git://git.savannah.gnu.org/hurd/mig.git'
+            git_branch = 'master'
+            r = self.git_checkout(component, git_url, git_branch, update)
+            subprocess.run(['autoreconf', '-i'],
+                           cwd=self.component_srcdir(component), check=True)
+            return r
         elif component == 'hurd':
             git_url = 'git://git.savannah.gnu.org/hurd/hurd.git'
             git_branch = 'master'