diff options
author | Alyssa Ross <hi@alyssa.is> | 2022-03-19 09:13:54 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2022-03-19 09:13:54 +0000 |
commit | 220273ccc689041667ab5ff55fe5b1e93689227a (patch) | |
tree | d1c95664832920b476ab48ab5dd9ad09ec67d82d /nixpkgs/pkgs/development/libraries/wxwidgets | |
parent | 68bab940e926ec7ae7380947a78c581e6aadcd18 (diff) | |
parent | 6e3ee8957637a60f5072e33d78e05c0f65c54366 (diff) | |
download | nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar.gz nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar.bz2 nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar.lz nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar.xz nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.tar.zst nixlib-220273ccc689041667ab5ff55fe5b1e93689227a.zip |
Merge commit '6e3ee8957637a60f5072e33d78e05c0f65c54366'
Conflicts: nixpkgs/pkgs/applications/networking/browsers/firefox/packages.nix
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/wxwidgets')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/3.1/default.nix | 138 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK28.nix (renamed from nixpkgs/pkgs/development/libraries/wxwidgets/2.8/default.nix) | 0 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK29.nix (renamed from nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix) | 2 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK30.nix (renamed from nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix) | 10 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK31.nix | 149 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/wxwidgets/wxmac30.nix (renamed from nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix) | 0 |
6 files changed, 155 insertions, 144 deletions
diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/3.1/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/3.1/default.nix deleted file mode 100644 index cab0197c9390..000000000000 --- a/nixpkgs/pkgs/development/libraries/wxwidgets/3.1/default.nix +++ /dev/null @@ -1,138 +0,0 @@ -{ lib, stdenv -, fetchFromGitHub -, fetchurl -, pkg-config -, libXinerama -, libSM -, libXxf86vm -, libXtst -, gtk2 -, GConf ? null -, gtk3 -, xorgproto -, gst_all_1 -, setfile -, libGLSupported ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms -, withMesa ? libGLSupported -, libGLU ? null -, libGL ? null -, compat28 ? false -, compat30 ? true -, unicode ? true -, withGtk2 ? true -, withWebKit ? false -, webkitgtk ? null -, AGL ? null -, Carbon ? null -, Cocoa ? null -, Kernel ? null -, QTKit ? null -}: - -with lib; - -assert withMesa -> libGLU != null && libGL != null; -assert withWebKit -> webkitgtk != null; - -assert assertMsg (withGtk2 -> withWebKit == false) "wxGTK31: You cannot enable withWebKit when using withGtk2."; - -stdenv.mkDerivation rec { - version = "3.1.4"; - pname = "wxwidgets"; - - src = fetchFromGitHub { - owner = "wxWidgets"; - repo = "wxWidgets"; - rev = "v${version}"; - sha256 = "1fwzrk6w5k0vs8kqdq5lpzdbp5c09hx740wg6mi6vgmc1r67dv67"; - fetchSubmodules = true; - }; - - buildInputs = [ - libXinerama - libSM - libXxf86vm - libXtst - xorgproto - gst_all_1.gstreamer - gst_all_1.gst-plugins-base - ] ++ optionals withGtk2 [ gtk2 GConf ] - ++ optional (!withGtk2) gtk3 - ++ optional withMesa libGLU - ++ optional withWebKit webkitgtk - ++ optionals stdenv.isDarwin [ setfile Carbon Cocoa Kernel QTKit ]; - - nativeBuildInputs = [ pkg-config ]; - - propagatedBuildInputs = optional stdenv.isDarwin AGL; - - patches = [ - (fetchurl { - # https://trac.wxwidgets.org/ticket/17942 - url = "https://trac.wxwidgets.org/raw-attachment/ticket/17942/" - + "fix_assertion_using_hide_in_destroy.diff"; - sha256 = "009y3dav79wiig789vkkc07g1qdqprg1544lih79199kb1h64lvy"; - }) - ]; - - configureFlags = - [ - "--disable-precomp-headers" - "--enable-mediactrl" - (if compat28 then "--enable-compat28" else "--disable-compat28") - (if compat30 then "--enable-compat30" else "--disable-compat30") - ] - ++ optional unicode "--enable-unicode" - ++ optional withMesa "--with-opengl" - ++ optionals stdenv.isDarwin - # allow building on 64-bit - [ "--with-cocoa" "--enable-universal-binaries" "--with-macosx-version-min=10.7" ] - ++ optionals withWebKit - [ "--enable-webview" "--enable-webviewwebkit" ]; - - SEARCH_LIB = "${libGLU.out}/lib ${libGL.out}/lib "; - - preConfigure = " - substituteInPlace configure --replace 'SEARCH_INCLUDE=' 'DUMMY_SEARCH_INCLUDE=' - substituteInPlace configure --replace 'SEARCH_LIB=' 'DUMMY_SEARCH_LIB=' - substituteInPlace configure --replace /usr /no-such-path - " + optionalString stdenv.isDarwin '' - substituteInPlace configure --replace \ - 'ac_cv_prog_SETFILE="/Developer/Tools/SetFile"' \ - 'ac_cv_prog_SETFILE="${setfile}/bin/SetFile"' - substituteInPlace configure --replace \ - "-framework System" \ - -lSystem - ''; - - postInstall = " - (cd $out/include && ln -s wx-*/* .) - "; - - passthru = { - inherit compat28 compat30 unicode; - gtk = if withGtk2 then gtk2 else gtk3; - }; - - enableParallelBuilding = true; - - meta = { - platforms = with platforms; darwin ++ linux; - license = licenses.wxWindows; - homepage = "https://www.wxwidgets.org/"; - description = "A C++ library that lets developers create applications for Windows, macOS, Linux and other platforms with a single code base"; - longDescription = '' - WxWidgets gives you a single, easy-to-use API for - writing GUI applications on multiple platforms that still utilize the - native platform's controls and utilities. Link with the appropriate library - for your platform and compiler, and your application will adopt the look - and feel appropriate to that platform. On top of great GUI functionality, - wxWidgets gives you: online help, network programming, streams, clipboard - and drag and drop, multithreading, image loading and saving in a variety of - popular formats, database support, HTML viewing and printing, and much - more. - ''; - badPlatforms = [ "x86_64-darwin" ]; - maintainers = with maintainers; [ tfmoraes ]; - }; -} diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/2.8/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK28.nix index 19a57d68e15b..19a57d68e15b 100644 --- a/nixpkgs/pkgs/development/libraries/wxwidgets/2.8/default.nix +++ b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK28.nix diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK29.nix index 34d76e53ff67..d5bef77202f1 100644 --- a/nixpkgs/pkgs/development/libraries/wxwidgets/2.9/default.nix +++ b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK29.nix @@ -36,7 +36,7 @@ stdenv.mkDerivation rec { patches = [ # https://github.com/wxWidgets/wxWidgets/issues/17942 - ../patches/0001-fix-assertion-using-hide-in-destroy.patch + ./patches/0001-fix-assertion-using-hide-in-destroy.patch ]; nativeBuildInputs = [ diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK30.nix index 628d8bd02377..115453303870 100644 --- a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/default.nix +++ b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK30.nix @@ -12,8 +12,8 @@ , pkg-config , xorgproto , withMesa ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms -, compat24 ? false -, compat26 ? true +, compat26 ? false +, compat28 ? true , unicode ? true , withGtk2 ? true , withWebKit ? false, webkitgtk @@ -69,14 +69,14 @@ stdenv.mkDerivation rec { patches = [ # https://github.com/wxWidgets/wxWidgets/issues/17942 - ../patches/0001-fix-assertion-using-hide-in-destroy.patch + ./patches/0001-fix-assertion-using-hide-in-destroy.patch ]; configureFlags = [ "--disable-precomp-headers" "--enable-mediactrl" - (if compat24 then "--enable-compat24" else "--disable-compat24") (if compat26 then "--enable-compat26" else "--disable-compat26") + (if compat28 then "--enable-compat28" else "--disable-compat28") ] ++ lib.optional unicode "--enable-unicode" ++ lib.optional withMesa "--with-opengl" @@ -136,6 +136,6 @@ stdenv.mkDerivation rec { passthru = { inherit gtk; - inherit compat24 compat26 unicode; + inherit compat26 compat28 unicode; }; } diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK31.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK31.nix new file mode 100644 index 000000000000..c262232f30d0 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/wxwidgets/wxGTK31.nix @@ -0,0 +1,149 @@ +{ lib +, stdenv +, fetchFromGitHub +, fetchurl +, gnome2 +, gst_all_1 +, gtk2 +, gtk3 +, libGL +, libGLU +, libSM +, libXinerama +, libXtst +, libXxf86vm +, pkg-config +, xorgproto +, compat28 ? false +, compat30 ? true +, unicode ? true +, withGtk2 ? true +, withMesa ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms +, withWebKit ? false, webkitgtk +, darwin +}: + +assert withMesa -> libGLU != null && libGL != null; +assert withWebKit -> webkitgtk != null; + +assert withGtk2 -> (!withWebKit); + +let + inherit (darwin.stubs) setfile; + inherit (darwin.apple_sdk.frameworks) AGL Carbon Cocoa Kernel QTKit; + inherit (gnome2) GConf; + inherit (gst_all_1) gst-plugins-base gstreamer; + gtk = if withGtk2 then gtk2 else gtk3; +in +stdenv.mkDerivation rec { + pname = "wxwidgets"; + version = "3.1.5"; + + src = fetchFromGitHub { + owner = "wxWidgets"; + repo = "wxWidgets"; + rev = "v${version}"; + hash = "sha256-2zMvcva0GUDmSYK0Wk3/2Y6R3F7MgdqGBrOhmWgVA6g="; + fetchSubmodules = true; + }; + + patches = [ + # https://github.com/wxWidgets/wxWidgets/issues/17942 + ./patches/0001-fix-assertion-using-hide-in-destroy.patch + ]; + + nativeBuildInputs = [ pkg-config ]; + + buildInputs = [ + gst-plugins-base + gstreamer + gtk + libSM + libXinerama + libXtst + libXxf86vm + xorgproto + ] + ++ lib.optionals withGtk2 [ + GConf + ] + ++ lib.optional withMesa libGLU + ++ lib.optional withWebKit webkitgtk + ++ lib.optionals stdenv.isDarwin [ + Carbon + Cocoa + Kernel + QTKit + setfile + ]; + + propagatedBuildInputs = lib.optional stdenv.isDarwin AGL; + + configureFlags = [ + "--disable-precomp-headers" + "--enable-mediactrl" + (if compat28 then "--enable-compat28" else "--disable-compat28") + (if compat30 then "--enable-compat30" else "--disable-compat30") + ] + ++ lib.optional unicode "--enable-unicode" + ++ lib.optional withMesa "--with-opengl" + ++ lib.optionals stdenv.isDarwin [ + # allow building on 64-bit + "--enable-universal-binaries" + "--with-cocoa" + "--with-macosx-version-min=10.7" + ] + ++ lib.optionals withWebKit [ + "--enable-webview" + "--enable-webviewwebkit" + ]; + + SEARCH_LIB = "${libGLU.out}/lib ${libGL.out}/lib "; + + preConfigure = '' + substituteInPlace configure --replace \ + 'SEARCH_INCLUDE=' 'DUMMY_SEARCH_INCLUDE=' + substituteInPlace configure --replace \ + 'SEARCH_LIB=' 'DUMMY_SEARCH_LIB=' + substituteInPlace configure --replace \ + /usr /no-such-path + '' + lib.optionalString stdenv.isDarwin '' + substituteInPlace configure --replace \ + 'ac_cv_prog_SETFILE="/Developer/Tools/SetFile"' \ + 'ac_cv_prog_SETFILE="${setfile}/bin/SetFile"' + substituteInPlace configure --replace \ + "-framework System" "-lSystem" + ''; + + postInstall = " + pushd $out/include + ln -s wx-*/* . + popd + "; + + enableParallelBuilding = true; + + meta = with lib; { + homepage = "https://www.wxwidgets.org/"; + description = "A Cross-Platform C++ GUI Library"; + longDescription = '' + wxWidgets gives you a single, easy-to-use API for writing GUI applications + on multiple platforms that still utilize the native platform's controls + and utilities. Link with the appropriate library for your platform and + compiler, and your application will adopt the look and feel appropriate to + that platform. On top of great GUI functionality, wxWidgets gives you: + online help, network programming, streams, clipboard and drag and drop, + multithreading, image loading and saving in a variety of popular formats, + database support, HTML viewing and printing, and much more. + ''; + license = licenses.wxWindows; + maintainers = with maintainers; [ AndersonTorres tfmoraes ]; + platforms = platforms.unix; + badPlatforms = platforms.darwin; # ofBorg is failing, don't know if internal + }; + + passthru = { + inherit gtk; + inherit compat28 compat30 unicode; + }; +} diff --git a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix b/nixpkgs/pkgs/development/libraries/wxwidgets/wxmac30.nix index e1f732929cec..e1f732929cec 100644 --- a/nixpkgs/pkgs/development/libraries/wxwidgets/3.0/mac.nix +++ b/nixpkgs/pkgs/development/libraries/wxwidgets/wxmac30.nix |