sagemath/sage

Two-line fix for "./configure is too sensitive to stray files/subdirectories"

mkoeppe opened this issue · 17 comments

This branch can be merged by people who are working with tickets pre-9.1.beta2 who cannot easily merge current develop into that ticket.

It turns an error issued by configure when they are stray files in build/pkgs (such as the generated files introduced in #29038).

Before this ticket:

$ mkdir -p build/pkgs/xyzzy/foo
$ ./bootstrap && ./configure
...
configure: error: "/Users/mkoeppe/s/sage/sage-rebasing/worktree-algebraic-2018-spring/build/pkgs/xyzzy/type" is missing.

After this ticket:

...
configure: WARNING: "/Users/mkoeppe/s/sage/sage-rebasing/worktree-algebraic-2018-spring/build/pkgs/xyzzy/type" is missing.  Leftovers from another branch?
...

CC: @dimpase @embray @vbraun

Component: build

Author: Matthias Koeppe

Branch/Commit: 171181f

Reviewer: Dima Pasechnik

Issue created by migration from https://trac.sagemath.org/ticket/29120

Description changed:

--- 
+++ 
@@ -2,4 +2,20 @@
 
 It turns an error issued by `configure` when they are stray files in `build/pkgs` (such as the generated files introduced in #29038).
 
+Before this ticket:
 
+```
+$ mkdir -p build/pkgs/xyzzy/foo
+$ ./bootstrap && ./configure
+...
+configure: error: "/Users/mkoeppe/s/sage/sage-rebasing/worktree-algebraic-2018-spring/build/pkgs/xyzzy/type" is missing.
+```
+
+After this ticket:
+
+```
+...
+configure: WARNING: "/Users/mkoeppe/s/sage/sage-rebasing/worktree-algebraic-2018-spring/build/pkgs/xyzzy/type" is missing.  Leftovers from another branch?
+...
+```
+

Commit: 1f193bf

comment:3

The branch is on top of sage 8.7.


New commits:

1f193bfIssue only a warning, not an error, if there are stray files in build/pkgs

Author: Matthias Koeppe

Reviewer: Dima Pasechnik

comment:7

lgtm

comment:8

Thanks!

Changed commit from 1f193bf to 171181f

Branch pushed to git repo; I updated commit sha1 and set ticket back to needs_review. New commits:

171181ffixup
comment:10

Sometimes 2 lines are better than 1.

comment:12

Could we please avoid continue, by putting the stuff to run fully into then clause?

comment:13

I think it's better if the diff is small.

comment:14

I don't like this Fortran coding style, but OK :-)

comment:15

Thanks!

comment:16

+1 thanks.