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

Updates gstreamer and plugins to 1.14.0 #38149

Merged
merged 27 commits into from Apr 4, 2018
Merged

Conversation

bkchr
Copy link
Contributor

@bkchr bkchr commented Mar 30, 2018

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@jtojnar
Copy link
Contributor

jtojnar commented Mar 30, 2018

While at it, could you please also try to port the packages to meson as per #32803?

postInstall = ''
for prog in "$dev/bin/"*; do
wrapProgram "$prog" --suffix GST_PLUGIN_SYSTEM_PATH : "\$(unset _tmp; for profile in \$NIX_PROFILES; do _tmp="\$profile/lib/gstreamer-1.0''$\{_tmp:+:\}\$_tmp"; done; printf "\$_tmp")"
done
'';

preConfigure= ''
configureFlagsArray+=("--exec-prefix=$dev")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will not be used with meson, so you can just remove it. Actually, it does not seem to do anything even with autotools.

];
buildInputs = stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.CoreServices;
buildInputs = [ libcap libunwind ] ++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.CoreServices;

propagatedBuildInputs = [ glib ];

enableParallelBuilding = true;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be removed as well, meson does this by default.

@bkchr
Copy link
Contributor Author

bkchr commented Mar 31, 2018

@jtojnar I ported everything to meson :)
gst-validate could not be ported, because the released package does not contain the meson files. I don't know why they are missing..

@@ -3,7 +3,7 @@ pkgconf = configuration_data()
pkgconf.set('prefix', join_paths(get_option('prefix')))
pkgconf.set('exec_prefix', '${prefix}')
pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libdir needs the same fix as includedir.

@@ -3,7 +3,7 @@ pkgconf = configuration_data()
pkgconf.set('prefix', get_option('prefix'))
pkgconf.set('exec_prefix', '${prefix}')
pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libdir needs the same fix as includedir.

outputs = [ "out" "dev" ];
outputBin = "dev";

nativeBuildInputs = [
pkgconfig perl bison flex python gobjectIntrospection makeWrapper
meson ninja pkgconfig gettext bison flex python3 makeWrapper valgrind gtk3 gsl
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why id gtk3 in nativeBuildInputs? If it is for tests, could you please add a comment?

@@ -3,7 +3,7 @@ pkgconf = configuration_data()
pkgconf.set('prefix', join_paths(get_option('prefix')))
pkgconf.set('exec_prefix', '${prefix}')
pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libdir needs the same fix as includedir.

@@ -3,7 +3,7 @@ pkgconf = configuration_data()
pkgconf.set('prefix', get_option('prefix'))
pkgconf.set('exec_prefix', '${prefix}')
pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The libdir needs the same fix as includedir.

};

outputs = [ "out" "dev" ];

nativeBuildInputs = [ pkgconfig python ];
nativeBuildInputs = [ meson ninja pkgconfig python ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gettext is missing.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why isn't gettext and ninja automatically propagated by meson? But I will add it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not every project uses i18n. And ninja is not needed for meson to work, you can use other builders.

};

outputs = [ "out" "dev" ];

nativeBuildInputs = [
pkgconfig python gobjectIntrospection
pkgconfig python meson ninja
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gettext is missing.

};

outputs = [ "out" "dev" ];

nativeBuildInputs = [ pkgconfig python gobjectIntrospection flex perl ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are you removing gobjectIntrospection?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

};

outputs = [ "out" "dev" ];

nativeBuildInputs = [ pkgconfig ];
nativeBuildInputs = [ meson ninja pkgconfig ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gobjectIntrospection is missing.

};

outputs = [ "out" "dev" ];

nativeBuildInputs = [ pkgconfig python ];
nativeBuildInputs = [ meson ninja pkgconfig python ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gettext is missing.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 1, 2018

You might also want to update gst-python.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 1, 2018

Opened an issue about gst-validate lacking meson support: https://bugzilla.gnome.org/show_bug.cgi?id=794871

@bkchr
Copy link
Contributor Author

bkchr commented Apr 1, 2018

@jtojnar I think I'm ready now.

Regarding gst-python, I looked into the package and tried porting it to meson, but my knowledge with meson is not that good. Maybe you could look into it?

pkgconf.set('exec_prefix', '${prefix}')
-pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
-pkgconf.set('includedir', '${prefix}/@0@'.format(get_option('includedir')))
+pkgconf.set('libdir', get_option('libdir'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be absolute. Use join_paths(get_option('prefix'), get_option('ilibdir')).

-pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
-pkgconf.set('includedir', '${prefix}/@0@'.format(get_option('includedir')))
+pkgconf.set('libdir', get_option('libdir'))
+pkgconf.set('includedir', get_option('includedir'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably too, though it works as long we use multiple outputs.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 2, 2018

I am getting the following error when building webkitgtk:

CMake Error in Source/WebCore/CMakeLists.txt:
  Found relative path while evaluating include directories of "WebCore":

    "lib/gstreamer-1.0/include"


pkgconf.set('exec_prefix', '${prefix}')
-pkgconf.set('libdir', '${prefix}/@0@'.format(get_option('libdir')))
-pkgconf.set('includedir', '${prefix}/@0@'.format(get_option('includedir')))
+pkgconf.set('libdir', get_option('libdir'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This path being non-absolute is causing the webkitgtk failure, most likely.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 2, 2018

And for some reason __init__.py files are no longer installed, though arch has the same problem. Maybe open a bug about that?

@bkchr
Copy link
Contributor Author

bkchr commented Apr 2, 2018

Yeah, maybe we should open a bug, if the files are not installed anymore.
Did you finish porting gst-python?

@jtojnar
Copy link
Contributor

jtojnar commented Apr 2, 2018

@bkchr the patch I sent on IRC yesterday worked for me, did you try it?

@bkchr
Copy link
Contributor Author

bkchr commented Apr 2, 2018

No I did not try. Should I test and push or do you want to push it to my pull request?

@jtojnar
Copy link
Contributor

jtojnar commented Apr 2, 2018

If you can, please.

@bkchr bkchr requested a review from FRidh as a code owner April 3, 2018 07:37
@bkchr
Copy link
Contributor Author

bkchr commented Apr 3, 2018

@jtojnar webkitgtk compiles and also gnome-music. I can't run gnome-music, because it crashes with:
ERROR Cannot connect to tracker, error 'tracker_sparql_error-quark: Failed to load SPARQL backend: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.Tracker1 was not provided by any .service files (6)'\Exiting

I think this error occurs, because I don't have any gnome services running. (I'm using KDE)

@jtojnar
Copy link
Contributor

jtojnar commented Apr 3, 2018

I tested it and it starts fine. I cannot play MP3 files, however:

Info <GstPbutils.DiscovererInfo object at 0x7fe9ca07a1b0 (GstDiscovererInfo at 0x15286e0)>: error: gst-core-error-quark: Your GStreamer installation is missing a plug-in. (12)
14:43:45 WARNING	URI: file:///home/jtojnar/Music/Give%20My%20Love%20To%20London/09-mother_wolf.mp3
14:43:45 WARNING	Error from element mpegaudioparse1: Internal data stream error.
14:43:45 WARNING	Debugging info:
     ../libs/gst/base/gstbaseparse.c(3611): gst_base_parse_loop (): /GstPlayBin:player/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin2/GstMpegAudioParse:mpegaudioparse1:
     streaming stopped, reason not-linked (-1)

Maybe something to do with the move of MP3 codecs to gst-plugins-good I noticed in the release notes? Possibly a flag or library needs to be moved over there.

You can also test with quodlibet (fixed version here #38122, or just add gobjectIntrospection dependency) or any other player using gst-python.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 3, 2018

A bug about the __init__.py not getting installed: https://bugzilla.gnome.org/show_bug.cgi?id=726831

But quodlibet plays FLAC music fine so perhaps we can do without.

@bkchr
Copy link
Contributor Author

bkchr commented Apr 3, 2018

But mp3 is not working with quodlibet. Still okay?

@jtojnar
Copy link
Contributor

jtojnar commented Apr 3, 2018

I think that is most likely caused by the move as mentioned above. That should be fixed.

@bkchr
Copy link
Contributor Author

bkchr commented Apr 3, 2018

@jtojnar quodlibet now plays mp3 as designed :)

@bkchr
Copy link
Contributor Author

bkchr commented Apr 4, 2018

@jtojnar corebird now also works. I'm gone through the list of moved things and fixed everything so far.

@jtojnar
Copy link
Contributor

jtojnar commented Apr 4, 2018

Great job, thanks.

@jtojnar jtojnar merged commit c490b05 into NixOS:master Apr 4, 2018
@FRidh
Copy link
Member

FRidh commented Apr 4, 2018

Please check on staging pkgs/development/libraries/gstreamer/{bad,base,good,ugly} because of merge-conflicts.

@bkchr
Copy link
Contributor Author

bkchr commented Apr 4, 2018

@FRidh I rebased staging onto my branch and locally and that worked without any merge conflicts?

@lukateras
Copy link
Member

@bkchr To run gnome-music you will need to enable services.gnome3.tracker.enable and services.gnome3.tracker-miners.enable.

@bkchr
Copy link
Contributor Author

bkchr commented Apr 22, 2018

Ahh, ty :)

@FRidh
Copy link
Member

FRidh commented Apr 22, 2018

@bkchr I meant to check the expressions. There was a merge conflict when merging staging and master, so I'm not quite sure the changes you intended survived.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants