Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update bindgen and crates that depend on it. #23197

Merged
merged 1 commit into from Apr 16, 2019
Merged

Conversation

@jdm
Copy link
Member

jdm commented Apr 12, 2019

This change is Reviewable

@highfive
Copy link

highfive commented Apr 12, 2019

Heads up! This PR modifies the following files:

  • @emilio: components/style/Cargo.toml
@highfive
Copy link

highfive commented Apr 12, 2019

warning Warning warning

  • These commits modify style code, but no tests are modified. Please consider adding a test!
@jhwgh1968
Copy link

jhwgh1968 commented Apr 13, 2019

What I know about the Travis failure so far: the Cargo package itself is messed up in a way that is not implied by my change to it as far as I can tell.

The error message is pointing out that the modification time on a configure script is older than a configure.in file. It was packaged that way on crates.io:

$ pwd
/home/admin/.cargo/registry/cache/github.com-1ecc6299db9ec823
$ zcat mozjs_sys-0.61.9.crate | tar tvf - mozjs_sys-0.61.9/mozjs/js/src/configure mozjs_sys-0.61.9/mozjs/js/src/old-configure.in
-rwxr-xr-x 501/20          260 2019-04-02 13:19 mozjs_sys-0.61.9/mozjs/js/src/configure
-rw-r--r-- 501/20        61990 2019-04-10 10:15 mozjs_sys-0.61.9/mozjs/js/src/old-configure.in

Why did this happen? I'm still digging. But I suspect (trying to confirm) this happened during a "cargo publish" step.

@jhwgh1968
Copy link

jhwgh1968 commented Apr 13, 2019

Okay, here is the Makefile snippet that is supposed to fix this:

# Only touch and run configure if we need to, to avoid unnecessary rebuilds.
# The second two time checks handle the case of configure.in and configure having
# the same timestamp (e.g. after a git checkout)
JSSRC := $(SRC_DIR)/mozjs/js/src
maybe-configure:
    [[ $(JSSRC)/configure -ot $(JSSRC)/configure.in ]] && touch $(JSSRC)/configure || true
    [[ $(JSSRC)/old-configure -ot $(JSSRC)/old-configure.in ]] && touch $(JSSRC)/old-configure || true
    ! [[ $(JSSRC)/configure.in -ot $(JSSRC)/configure ]] && touch $(JSSRC)/configure || true
    ! [[ $(JSSRC)/old-configure.in -ot $(JSSRC)/old-configure ]] && touch $(JSSRC)/old-configure || true
    if [[ $(JSSRC)/configure -nt $(OUT_DIR)/config.status ]] ; then \
      cd $(OUT_DIR) && \
      PYTHON="$(PYTHON)" MOZ_TOOLS="$(MOZ_TOOLS)" \
      CC="$(CC)" CFLAGS="$(CFLAGS)" \
      CPP="$(CPP)" CPPFLAGS="$(CPPFLAGS)" \
      CXX="$(CXX)" CXXFLAGS="$(CXXFLAGS)" \
      AS="$(AS)" AR="$(AR)" \
      STLPORT_LIBS="$(STLPORT_LIBS)" \
      $(JSSRC)/configure $(strip $(CONFIGURE_FLAGS)) || (cat config.log && exit 1) ; \
    fi

And here is the dump of the directory:

$ zcat mozjs_sys-0.61.9.crate | tar tvf - --wildcards mozjs_sys-0.61.9/mozjs/js/src/configure mozjs_sys-0.61.9/mozjs/js/src/'*configure*'
-rwxr-xr-x 501/20          260 2019-04-02 13:19 mozjs_sys-0.61.9/mozjs/js/src/configure
-rw-r--r-- 501/20         1175 2019-03-11 07:17 mozjs_sys-0.61.9/mozjs/js/src/configure.in
-rwxr-xr-x 501/20       663693 2019-03-11 07:17 mozjs_sys-0.61.9/mozjs/js/src/ctypes/libffi/configure
-rw-r--r-- 501/20        17672 2019-03-11 07:17 mozjs_sys-0.61.9/mozjs/js/src/ctypes/libffi/configure.ac
-rw-r--r-- 501/20         2882 2019-03-11 07:17 mozjs_sys-0.61.9/mozjs/js/src/ctypes/libffi/m4/ax_configure_args.m4
-rw-r--r-- 501/20       298317 2019-04-11 09:27 mozjs_sys-0.61.9/mozjs/js/src/old-configure
-rw-r--r-- 501/20        61990 2019-04-10 10:15 mozjs_sys-0.61.9/mozjs/js/src/old-configure.in

So it looks like the case was:

  • configure was not older than configure.in
  • old-configure was not older than old-configure.in
  • configure.in was older than configure
  • old-configure.in was not older than old-configure

Which means the file didn't get updated.

But the Makefile has this rule which also implicitly checks between configure.in and old-configure.in:

$(topsrcdir)/configure: $(topsrcdir)/configure.in $(topsrcdir)/old-configure.in
$(topsrcdir)/js/src/configure: $(topsrcdir)/js/src/configure.in $(topsrcdir)/js/src/old-configure.in
$(topsrcdir)/configure $(topsrcdir)/js/src/configure:
    @echo 'STOP!  $? has changed, and your configure is out of date.'
    @echo 'Please rerun autoconf and re-configure your build directory.'
    @echo 'To ignore this message, touch "$@",'
    @echo 'but your build might not succeed.'
    @exit 1

And that is the rule that's triggering.

In other words, it appears to be a bug in the Makefile logic.

I'm presuming the bottom snippet is the intended one, so the top one should be updated.

@jdm jdm force-pushed the jdm:bindgen branch from 9d6fd2e to 4dfc9fd Apr 16, 2019
@jdm jdm force-pushed the jdm:bindgen branch from 4dfc9fd to cdf5aa7 Apr 16, 2019
@jdm
Copy link
Member Author

jdm commented Apr 16, 2019

I made a new release of mozjs that touched configure and the CI appears to like it better.

@jdm
Copy link
Member Author

jdm commented Apr 16, 2019

@paulrouget This will address your problems with using an updated rust-webvr.

@paulrouget
Copy link
Contributor

paulrouget commented Apr 16, 2019

@bors-servo
Copy link
Contributor

bors-servo commented Apr 16, 2019

📌 Commit cdf5aa7 has been approved by paulrouget

@bors-servo
Copy link
Contributor

bors-servo commented Apr 16, 2019

Testing commit cdf5aa7 with merge a161106...

bors-servo added a commit that referenced this pull request Apr 16, 2019
Update bindgen and crates that depend on it.

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/23197)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Apr 16, 2019

@bors-servo bors-servo merged commit cdf5aa7 into servo:master Apr 16, 2019
4 checks passed
4 checks passed
Taskcluster (pull_request) TaskGroup: success
Details
Travis CI - Pull Request Build Passed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
homu Test successful
Details
@bors-servo bors-servo mentioned this pull request Apr 16, 2019
3 of 3 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.