owickstrom / komposition

The video editor built for screencasters
https://owickstrom.github.io/komposition/
Mozilla Public License 2.0
429 stars 21 forks source link

Build prerequisite brew install invalid option: --with-gtk+3 #85

Closed philderbeast closed 4 years ago

philderbeast commented 5 years ago

Following the instructions below for installing prerequisites before building on osx, the first brew install command passed but the second one failed.

brew install pkg-config gobject-introspection gtk+3 ffmpeg sox gstreamer libffi gst-plugins-base gst-libav
brew install gst-plugins-good --with-gtk+3

export PKG_CONFIG_PATH="/usr/local/opt/libffi/lib/pkgconfig"

# if you get an error in the next step about 'happy' not being on your
# PATH, run this command first:
stack build happy
stack install

The command and fail message:

> brew install gst-plugins-good --with-gtk+3
...
invalid option: --with-gtk+3
sw_vers
ProductName:    Mac OS X
ProductVersion: 10.13.6
BuildVersion:   17G5019
owickstrom commented 5 years ago

Hi,

Does it work without that option (--with-gtk+3)? https://formulae.brew.sh/formula/gst-plugins-good doesn't list it, maybe it's been removed.

philderbeast commented 5 years ago

The brew install command does complete without errors without the --with-gtk+3 option.

philderbeast commented 5 years ago

I'm happy to make a pull request on the docs for this.

owickstrom commented 5 years ago

@philderbeast That would be very helpful, thanks!

philderbeast commented 5 years ago

Unfortunately I'm unable to complete the build so am wary about removal of the --with-gtk+3 option. These are the steps I made:

> brew install pkg-config gobject-introspection gtk+3 ffmpeg sox gstreamer libffi gst-plugins-base gst-libav
> brew install gst-plugins-good
> export PKG_CONFIG_PATH="/usr/local/opt/libffi/lib/pkgconfig"
> stack install

The error I'm seeing is Symbol not found: _gtk_cell_accessible_parent_get_column_header_cells:

> ~/d/s/h/komposition on master ◦ stack install
Didn't see gi-gtk-declarative-0.4.2 in your package indices.
Updating and trying again.
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/
Downloading timestamp
Downloading snapshot
Updating index
Updated package index downloaded
Update complete
Populated index cache.
gi-atk-2.0.15: unregistering
gi-cairo-1.0.17: unregistering
gi-gdk-3.0.16: unregistering
gi-gdkpixbuf-2.0.16: unregistering
gi-gio-2.0.18: unregistering
gi-glib-2.0.17: unregistering
gi-gobject-2.0.16: unregistering
gi-gst-1.0.16: unregistering
gi-gtk-3.0.24: unregistering
gi-gtk-declarative-0.4.1: unregistering
gi-pango-1.0.16: unregistering
haskell-gi-0.21.3: unregistering
pretty-show-1.7: unregistering
pretty-show-1.7: configure
pretty-show-1.7: build
pretty-show-1.7: copy/register
haskell-gi-0.21.3: configure
haskell-gi-0.21.3: build
haskell-gi-0.21.3: copy/register
gi-cairo-1.0.17: configure
gi-cairo-1.0.17: build
gi-glib-2.0.17: configure
gi-cairo-1.0.17: copy/register
gi-glib-2.0.17: build
gi-glib-2.0.17: copy/register
gi-gobject-2.0.16: configure
gi-gobject-2.0.16: build
gi-gobject-2.0.16: copy/register
gi-atk-2.0.15: configure
gi-atk-2.0.15: build
gi-gst-1.0.16: configure
gi-gst-1.0.16: build
gi-pango-1.0.16: configure
gi-pango-1.0.16: build
gi-gio-2.0.18: configure
gi-atk-2.0.15: copy/register
gi-gio-2.0.18: build
gi-pango-1.0.16: copy/register
gi-gst-1.0.16: copy/register
gi-gio-2.0.18: copy/register
gi-gdkpixbuf-2.0.16: configure
gi-gdkpixbuf-2.0.16: build
gi-gdkpixbuf-2.0.16: copy/register
gi-gdk-3.0.16: configure
gi-gdk-3.0.16: build
gi-gdk-3.0.16: copy/register
gi-gtk-3.0.24: configure
gi-gtk-3.0.24: build
gi-gtk-3.0.24: copy/register
gi-gtk-declarative-0.4.2: download
gi-gtk-declarative-0.4.2: configure
gi-gtk-declarative-0.4.2: build
gi-gtk-declarative-0.4.2: copy/register
Building all executables for `komposition' once. After a successful build of all of them, only specified executables will be rebuilt.
komposition-0.1.0: configure (lib + exe)
Configuring komposition-0.1.0...
Warning: Packages using 'cabal-version: >= 1.10' must specify the
'default-language' field for each component (e.g. Haskell98 or Haskell2010).
If a component uses different languages in different modules then list the
other ones in the 'other-languages' field.
clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
komposition-0.1.0: build (lib + exe)
Preprocessing library for komposition-0.1.0..
Building library for komposition-0.1.0..
[ 1 of 62] Compiling Komposition.Application.Form ( src/Komposition/Application/Form.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Application/Form.o )
[ 2 of 62] Compiling Komposition.Classification ( src/Komposition/Classification.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Classification.o )
[ 3 of 62] Compiling Komposition.Prelude ( src/Komposition/Prelude.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Prelude.o )
[ 4 of 62] Compiling Komposition.MediaType ( src/Komposition/MediaType.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/MediaType.o )
[ 5 of 62] Compiling Komposition.Logging ( src/Komposition/Logging.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Logging.o )
[ 6 of 62] Compiling Komposition.Logging.FastLogger ( src/Komposition/Logging/FastLogger.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Logging/FastLogger.o )
[ 7 of 62] Compiling Komposition.KeyMap ( src/Komposition/KeyMap.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/KeyMap.o )
[ 8 of 62] Compiling Komposition.Duration ( src/Komposition/Duration.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Duration.o )
[ 9 of 62] Compiling Control.Monad.Indexed.IO ( src/Control/Monad/Indexed/IO.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Control/Monad/Indexed/IO.o )
[10 of 62] Compiling Komposition.Progress ( src/Komposition/Progress.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/Komposition/Progress.o )
<command line>: can't load .so/.DLL for: /Users/pdejoux/dev/src/haskell/komposition/.stack-work/install/x86_64-osx/lts-12.4/8.4.3/lib/x86_64-osx-ghc-8.4.3/libHSgi-gtk-3.0.24-FLl2XNqL5lVKlwNTwXLnwA-ghc8.4.3.dylib (dlopen(/Users/pdejoux/dev/src/haskell/komposition/.stack-work/install/x86_64-osx/lts-12.4/8.4.3/lib/x86_64-osx-ghc-8.4.3/libHSgi-gtk-3.0.24-FLl2XNqL5lVKlwNTwXLnwA-ghc8.4.3.dylib, 5): Symbol not found: _gtk_cell_accessible_parent_get_column_header_cells
  Referenced from: /Users/pdejoux/dev/src/haskell/komposition/.stack-work/install/x86_64-osx/lts-12.4/8.4.3/lib/x86_64-osx-ghc-8.4.3/libHSgi-gtk-3.0.24-FLl2XNqL5lVKlwNTwXLnwA-ghc8.4.3.dylib
  Expected in: flat namespace
 in /Users/pdejoux/dev/src/haskell/komposition/.stack-work/install/x86_64-osx/lts-12.4/8.4.3/lib/x86_64-osx-ghc-8.4.3/libHSgi-gtk-3.0.24-FLl2XNqL5lVKlwNTwXLnwA-ghc8.4.3.dylib)
Completed 14 action(s).

--  While building package komposition-0.1.0 using:
      /Users/pdejoux/.stack/setup-exe-cache/x86_64-osx/Cabal-simple_mPHDZzAJ_2.2.0.1_ghc-8.4.3 --builddir=.stack-work/dist/x86_64-osx/Cabal-2.2.0.1 build lib:komposition exe:komposition exe:komposition-split --ghc-options " -ddump-hi -ddump-to-file -fdiagnostics-color=always"
    Process exited with code: ExitFailure 1
owickstrom commented 5 years ago

I haven't seen this exact error before. Do you mind checking what version of GTK+ is installed? The gtk+ package in brew, that is.

philderbeast commented 5 years ago

The version is 3.24.5. In the brew info command output I notice the build of gobject-introspection has failed.

> brew info gtk+3
gtk+3: stable 3.24.5 (bottled)
Toolkit for creating graphical user interfaces
https://gtk.org/
/usr/local/Cellar/gtk+3/3.24.5 (1,381 files, 70.7MB) *
  Poured from bottle on 2019-02-15 at 10:05:45
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/gtk+3.rb
==> Dependencies
Build: gobject-introspection ✘, pkg-config ✔
Required: atk ✔, gdk-pixbuf ✔, glib ✔, gsettings-desktop-schemas ✔, hicolor-icon-theme ✔, libepoxy ✔, pango ✔
==> Analytics
install: 19,019 (30 days), 59,326 (90 days), 159,231 (365 days)
install_on_request: 3,749 (30 days), 11,921 (90 days), 29,979 (365 days)
build_error: 0 (30 days)
> brew list gtk+3
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk-builder-tool
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk-encode-symbolic-svg
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk-launch
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk-query-immodules-3.0
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk-query-settings
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk3-demo
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk3-demo-application
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk3-icon-browser
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk3-update-icon-cache
/usr/local/Cellar/gtk+3/3.24.5/bin/gtk3-widget-factory
/usr/local/Cellar/gtk+3/3.24.5/etc/gtk-3.0/im-multipress.conf
/usr/local/Cellar/gtk+3/3.24.5/include/gail-3.0/ (3 files)
/usr/local/Cellar/gtk+3/3.24.5/include/gtk-3.0/ (379 files)
/usr/local/Cellar/gtk+3/3.24.5/lib/libgailutil-3.0.dylib
/usr/local/Cellar/gtk+3/3.24.5/lib/libgdk-3.0.dylib
/usr/local/Cellar/gtk+3/3.24.5/lib/libgtk-3.0.dylib
/usr/local/Cellar/gtk+3/3.24.5/lib/girepository-1.0/ (2 files)
/usr/local/Cellar/gtk+3/3.24.5/lib/gtk-3.0/ (15 files)
/usr/local/Cellar/gtk+3/3.24.5/lib/pkgconfig/ (6 files)
/usr/local/Cellar/gtk+3/3.24.5/lib/ (3 other files)
/usr/local/Cellar/gtk+3/3.24.5/share/aclocal/gtk-3.0.m4
/usr/local/Cellar/gtk+3/3.24.5/share/applications/ (3 files)
/usr/local/Cellar/gtk+3/3.24.5/share/gettext/ (2 files)
/usr/local/Cellar/gtk+3/3.24.5/share/gir-1.0/ (2 files)
/usr/local/Cellar/gtk+3/3.24.5/share/glib-2.0/ (6 files)
/usr/local/Cellar/gtk+3/3.24.5/share/gtk-3.0/gtkbuilder.rng
/usr/local/Cellar/gtk+3/3.24.5/share/gtk-doc/ (668 files)
/usr/local/Cellar/gtk+3/3.24.5/share/icons/ (25 files)
/usr/local/Cellar/gtk+3/3.24.5/share/locale/ (230 files)
/usr/local/Cellar/gtk+3/3.24.5/share/man/ (11 files)
/usr/local/Cellar/gtk+3/3.24.5/share/themes/ (3 files)
owickstrom commented 5 years ago

OK. I don't know why it would fail, but gobject-introspection is required for building the gi-* Haskell libraries AFAIK, so you should start digging there.

owickstrom commented 4 years ago

This application is now available as a Homebrew formula (https://formulae.brew.sh/formula/komposition). If you want to build from source, you should be able to install the same set of dependencies and get it running.

athas commented 4 years ago

The --with-gtk+3 option for gst-plugins-good is now the default (Homebrew removed all options for packages some time ago).