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

Servo build fails at linking #19543

Closed
pyfisch opened this issue Dec 10, 2017 · 12 comments
Closed

Servo build fails at linking #19543

pyfisch opened this issue Dec 10, 2017 · 12 comments

Comments

@pyfisch
Copy link
Contributor

pyfisch commented Dec 10, 2017

https://gist.github.com/pyfisch/b87045ec5b24d07eb87cd867d1dd6b95

I have installed the dependencies listed in the readme. I already did a clean rebuild.
Any suggestions what causes this failure?

Current revision is:

$ git rev-parse HEAD
92cbf5630966c2a3f655e1edefa451628f2811ef

I am using Ubuntu 16.04.

@emilio
Copy link
Member

emilio commented Dec 10, 2017

error: undefined reference to 'GeckoMedia_Initialize'
error: undefined reference to 'GeckoMedia_ProcessEvents'
error: undefined reference to 'GeckoMedia_Shutdown'
error: undefined reference to 'GeckoMedia_CanPlayType'

cc @nox @philn ^

@philn
Copy link
Contributor

philn commented Dec 11, 2017

Can you check if gecko-media alone builds correctly? Try to run the unit-tests locally or the standalone player.

@pyfisch
Copy link
Contributor Author

pyfisch commented Dec 11, 2017

@philn: It does not even build on Travis CI.
The reported error is:

error: Package `serde_derive v1.0.23` does not have these features: `deserialize_from`

Some package seems to have changed under gecko-media. servo itself is protected from this because it distributes a lockfile along with the source code but I don't know how to extract the relevant portions for gecko-media.

@philn
Copy link
Contributor

philn commented Dec 11, 2017

Ah, a workaround was suggested on IRC about this Serde issue. Put this in gecko-media's Cargo.toml:

[patch.crates-io]
serde = { git = "https://github.com/gankro/serde", branch = "deserialize_from_enums3" }
serde_derive = { git = "https://github.com/gankro/serde", branch = "deserialize_from_enums3", feature="deserialize_from" }

But I think this should be properly fixed somehow... CC @nox @Eijebong

@philn
Copy link
Contributor

philn commented Dec 11, 2017

This happens because of the examples dependency on webrender.

@pyfisch
Copy link
Contributor Author

pyfisch commented Dec 11, 2017

Okay, executing cargo build -p gecko-media succeeds with the workaround.

Still building the examples fails with a version mismatch:

error: failed to select a version for `serde` (required by `webrender_api`):
all possible versions conflict with previously selected versions of `serde`
  version 1.0.24 in use by serde v1.0.24
  possible versions to select: 1.0.23

@Eijebong
Copy link
Contributor

cc @gankro too since it's the custom serde fork that's causing all this.

@Gankra
Copy link
Contributor

Gankra commented Dec 12, 2017

Traveling, if I don’t get back to this tomorrow please reping.

(Not sure: it looks like you’re trying to use a version of serde that’s newer than the patch?)

@Eijebong
Copy link
Contributor

Well the [patch.crates-io] section from webrender seems to be ineffective in crates using webrender as a dependency. Not sure if this is the desired behavior but I think this is what causing those errors.

@Gankra
Copy link
Contributor

Gankra commented Dec 12, 2017

Yes patch only applies to binary projects. You can’t apply it to a lib.

@staktrace
Copy link
Contributor

Some things to try:

  • Leave the [patch.crates-io] section in your gecko-media workspace's Cargo.toml, and make sure the version of webrender it's trying to build is f9bc4a5c or newer ; that might fix the problem
  • If that doesn't work, try running cargo update -p serde --precise 1.0.23 which should change your Cargo.lock file to use serde 1.0.23 instead of 1.0.24, and the error with the conflicting versions should go away
  • If neither of those work, try rolling back the version of webrender to e558d41b or earlier ; that will use a version of webrender prior to the serde patching - you will also need to remove the [patch.crates-io] from your gecko-media workspace's Cargo.toml.

(To pin webrender to a particular version you would edit the examples/Cargo.toml file and add a rev = ... attribute into the dependencies.webrender key)

philn added a commit to servo/gecko-media that referenced this issue Dec 15, 2017
Roll back to e558d41b to avoid version conflicts between serde and the patched
version currently needed by webrender git master.

See also servo/servo#19543
bors-servo pushed a commit to servo/gecko-media that referenced this issue Dec 15, 2017
Set explicit revision on examples webrender dependency

Roll back to e558d41b to avoid version conflicts between serde and the patched
version currently needed by webrender git master.

See also servo/servo#19543
@pyfisch
Copy link
Contributor Author

pyfisch commented Jan 20, 2018

#19806 removed gecko-media so this is no longer an issue.

@pyfisch pyfisch closed this as completed Jan 20, 2018
cpearce pushed a commit to cpearce/gecko-media that referenced this issue Aug 24, 2018
Roll back to e558d41b to avoid version conflicts between serde and the patched
version currently needed by webrender git master.

See also servo/servo#19543
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants