summaryrefslogtreecommitdiffstats
path: root/pkgs/applications
diff options
context:
space:
mode:
authorgithub-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>2021-01-01 18:39:12 +0000
committerGitHub <noreply@github.com>2021-01-01 18:39:12 +0000
commit0eb369d907b3d45d236571870c1ecf7a0a7ec4aa (patch)
treeb3a2fda0cabb8b7f1875b9e5e49e9f1ce755d4eb /pkgs/applications
parentf1df516121d38a64282dcf6db3aab9f7fc0dbb56 (diff)
parentc0a93616873708f710ecd2ced2cf4fcc75f287bd (diff)
Merge staging-next into staging
Diffstat (limited to 'pkgs/applications')
-rw-r--r--pkgs/applications/graphics/emulsion/default.nix85
-rw-r--r--pkgs/applications/networking/browsers/brave/default.nix6
-rw-r--r--pkgs/applications/science/misc/root/default.nix23
-rw-r--r--pkgs/applications/science/misc/root/sw_vers.patch54
4 files changed, 128 insertions, 40 deletions
diff --git a/pkgs/applications/graphics/emulsion/default.nix b/pkgs/applications/graphics/emulsion/default.nix
new file mode 100644
index 000000000000..ba7ebfcfdff6
--- /dev/null
+++ b/pkgs/applications/graphics/emulsion/default.nix
@@ -0,0 +1,85 @@
+{ stdenv
+, lib
+, fetchFromGitHub
+, rustPlatform
+, installShellFiles
+, makeWrapper
+, pkg-config
+, python3
+, libGL
+, libX11
+, libXcursor
+, libXi
+, libXrandr
+, libXxf86vm
+, libxcb
+, libxkbcommon
+, wayland
+, xdg_utils
+, AppKit
+, CoreGraphics
+, CoreServices
+, Foundation
+, OpenGL
+}:
+let
+ rpathLibs = [
+ libGL
+ libX11
+ libXcursor
+ libXi
+ libXrandr
+ libXxf86vm
+ libxcb
+ ] ++ lib.optionals stdenv.isLinux [
+ libxkbcommon
+ wayland
+ ];
+in
+rustPlatform.buildRustPackage rec {
+ pname = "emulsion";
+ version = "7.2";
+
+ src = fetchFromGitHub {
+ owner = "ArturKovacs";
+ repo = pname;
+ rev = "v${version}";
+ sha256 = "1king04p5j4gsvprrfppwaxa5jn4ga4nc0v63wl6fvq2ngwnkg4g";
+ };
+
+ cargoSha256 = "19vb2q5w3063l7349p1b8q40n97a4hxdvc7h7qsx1iiwp75knbd0";
+
+ nativeBuildInputs = [
+ installShellFiles
+ makeWrapper
+ pkg-config
+ python3
+ ];
+
+ buildInputs = rpathLibs ++ lib.optionals stdenv.isDarwin [
+ AppKit
+ CoreGraphics
+ CoreServices
+ Foundation
+ OpenGL
+ ];
+
+ installPhase = ''
+ runHook preInstall
+ install -D $releaseDir/emulsion $out/bin/emulsion
+ '' + lib.optionalString stdenv.isLinux ''
+ patchelf --set-rpath "${lib.makeLibraryPath rpathLibs}" $out/bin/emulsion
+ '' + ''
+ runHook postInstall
+ '';
+
+ dontPatchELF = true;
+
+ meta = with lib; {
+ description = "A fast and minimalistic image viewer";
+ homepage = "https://arturkovacs.github.io/emulsion-website/";
+ maintainers = [ maintainers.magnetophon ];
+ platforms = platforms.unix;
+ license = licenses.mit;
+ };
+}
diff --git a/pkgs/applications/networking/browsers/brave/default.nix b/pkgs/applications/networking/browsers/brave/default.nix
index 9931b6003fb0..92177183b0ca 100644
--- a/pkgs/applications/networking/browsers/brave/default.nix
+++ b/pkgs/applications/networking/browsers/brave/default.nix
@@ -98,6 +98,7 @@ stdenv.mkDerivation rec {
dontConfigure = true;
dontBuild = true;
dontPatchELF = true;
+ doInstallCheck = true;
nativeBuildInputs = [ dpkg wrapGAppsHook ];
@@ -147,6 +148,11 @@ stdenv.mkDerivation rec {
ln -sf ${xdg_utils}/bin/xdg-mime $out/opt/brave.com/brave/xdg-mime
'';
+ installCheckPhase = ''
+ # Bypass upstream wrapper which suppresses errors
+ $out/opt/brave.com/brave/brave --version
+ '';
+
passthru.updateScript = ./update.sh;
meta = with stdenv.lib; {
diff --git a/pkgs/applications/science/misc/root/default.nix b/pkgs/applications/science/misc/root/default.nix
index 97d8d4e7cee5..03b206973103 100644
--- a/pkgs/applications/science/misc/root/default.nix
+++ b/pkgs/applications/science/misc/root/default.nix
@@ -1,19 +1,20 @@
-{ stdenv, lib, fetchurl, makeWrapper, cmake, gl2ps, gsl, libX11, libXpm, libXft
-, libXext, libGLU, libGL, libxml2, lz4, lzma, pcre, pkgconfig, python, xxHash
-, zlib
+{ stdenv, lib, fetchurl, makeWrapper, cmake, ftgl, gl2ps, glew, gsl, llvm_5
+, libX11, libXpm, libXft, libXext, libGLU, libGL, libxml2, lz4, lzma, pcre
+, pkgconfig, python, xxHash, zlib, zstd
+, libAfterImage, giflib, libjpeg, libtiff, libpng
, Cocoa, OpenGL, noSplash ? false }:
stdenv.mkDerivation rec {
pname = "root";
- version = "6.18.04";
+ version = "6.22.06";
src = fetchurl {
url = "https://root.cern.ch/download/root_v${version}.source.tar.gz";
- sha256 = "196ghma6g5a7sqz52wyjkgvmh4hj4vqwppm0zwdypy33hgy8anii";
+ sha256 = "0mqvj42nax0bmz8h83jjlwjm3xxjy1n0n10inc8csip9ly28fs64";
};
nativeBuildInputs = [ makeWrapper cmake pkgconfig ];
- buildInputs = [ gl2ps pcre zlib libxml2 lz4 lzma gsl xxHash python.pkgs.numpy ]
+ buildInputs = [ ftgl gl2ps glew pcre zlib zstd llvm_5 libxml2 lz4 lzma gsl xxHash libAfterImage giflib libjpeg libtiff libpng python.pkgs.numpy ]
++ lib.optionals (!stdenv.isDarwin) [ libX11 libXpm libXft libXext libGLU libGL ]
++ lib.optionals (stdenv.isDarwin) [ Cocoa OpenGL ]
;
@@ -38,6 +39,7 @@ stdenv.mkDerivation rec {
"-DCMAKE_INSTALL_INCLUDEDIR=include"
"-Dalien=OFF"
"-Dbonjour=OFF"
+ "-Dbuiltin_llvm=OFF"
"-Dcastor=OFF"
"-Dchirp=OFF"
"-Dclad=OFF"
@@ -69,7 +71,14 @@ stdenv.mkDerivation rec {
"-Dxrootd=OFF"
]
++ stdenv.lib.optional (stdenv.cc.libc != null) "-DC_INCLUDE_DIRS=${stdenv.lib.getDev stdenv.cc.libc}/include"
- ++ stdenv.lib.optional stdenv.isDarwin "-DOPENGL_INCLUDE_DIR=${OpenGL}/Library/Frameworks";
+ ++ stdenv.lib.optionals stdenv.isDarwin [
+ "-DOPENGL_INCLUDE_DIR=${OpenGL}/Library/Frameworks"
+ "-DCMAKE_DISABLE_FIND_PACKAGE_Python2=TRUE"
+
+ # fatal error: module map file '/nix/store/<hash>-Libsystem-osx-10.12.6/include/module.modulemap' not found
+ # fatal error: could not build module '_Builtin_intrinsics'
+ "-Druntime_cxxmodules=OFF"
+ ];
enableParallelBuilding = true;
diff --git a/pkgs/applications/science/misc/root/sw_vers.patch b/pkgs/applications/science/misc/root/sw_vers.patch
index 34af132c11f8..b2ee1b6a4ceb 100644
--- a/pkgs/applications/science/misc/root/sw_vers.patch
+++ b/pkgs/applications/science/misc/root/sw_vers.patch
@@ -1,19 +1,7 @@
-diff a/build/unix/compiledata.sh b/build/unix/compiledata.sh
---- a/build/unix/compiledata.sh
-+++ b/build/unix/compiledata.sh
-@@ -47,7 +47,7 @@ fi
-
- if [ "$ARCH" = "macosx" ] || [ "$ARCH" = "macosx64" ] || \
- [ "$ARCH" = "macosxicc" ]; then
-- macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2`
-+ macosx_minor=12
- SOEXT="so"
- if [ $macosx_minor -ge 5 ]; then
- if [ "x`echo $SOFLAGS | grep -- '-install_name'`" != "x" ]; then
diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
--- a/cmake/modules/SetUpMacOS.cmake
+++ b/cmake/modules/SetUpMacOS.cmake
-@@ -2,17 +2,8 @@ set(ROOT_ARCHITECTURE macosx)
+@@ -8,17 +8,10 @@ set(ROOT_ARCHITECTURE macosx)
set(ROOT_PLATFORM macosx)
if (CMAKE_SYSTEM_NAME MATCHES Darwin)
@@ -21,8 +9,8 @@ diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
- COMMAND cut -d . -f 1-2
- OUTPUT_VARIABLE MACOSX_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE)
-
-- MESSAGE(STATUS "Found a Mac OS X System ${MACOSX_VERSION}")
--
+ MESSAGE(STATUS "Found a macOS system ${MACOSX_VERSION}")
+
- if(MACOSX_VERSION VERSION_GREATER 10.7 AND ${CMAKE_CXX_COMPILER_ID} MATCHES Clang)
set(libcxx ON CACHE BOOL "Build using libc++" FORCE)
- endif()
@@ -31,7 +19,7 @@ diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
#TODO: check haveconfig and rpath -> set rpath true
#TODO: check Thread, define link command
#TODO: more stuff check configure script
-@@ -25,23 +16,7 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
+@@ -37,23 +30,7 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m64")
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m64")
SET(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -m64")
@@ -56,7 +44,7 @@ diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
if (CMAKE_COMPILER_IS_GNUCXX)
message(STATUS "Found GNU compiler collection")
-@@ -104,7 +79,6 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
+@@ -115,7 +92,6 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
endif()
#---Set Linker flags----------------------------------------------------------------------
@@ -67,33 +55,33 @@ diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
diff a/config/root-config.in b/config/root-config.in
--- a/config/root-config.in
+++ b/config/root-config.in
-@@ -306,12 +306,6 @@ macosxicc)
- auxlibs="-lm -ldl"
+@@ -312,12 +312,6 @@ macosxicc)
;;
- macosx64)
-- # MacOS X with gcc (GNU cc v4.x) in 64 bit mode
+ macosx64|macosxarm64)
+ # MacOS X with gcc (GNU cc v4.x) in 64 bit mode
+- macosx_major=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 1 | sed -e 's/^[[:space:]]*//'`
- macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2`
- # cannot find the one linked to libGraf if relocated after built
-- if [ $macosx_minor -le 4 ]; then
+- if [ $macosx_major -eq 10 -a $macosx_minor -le 4 ]; then
- rootlibs="$rootlibs -lfreetype"
- fi
auxcflags="${cxxversionflag} -m64"
auxldflags="-m64"
auxlibs="-lm -ldl"
-@@ -375,18 +369,11 @@ freebsd* | openbsd* | linux*)
+@@ -378,18 +372,11 @@ freebsd* | openbsd* | linux*)
+ done
+ ;;
macosx*)
+- if [ \( $macosx_major -eq 10 -a $macosx_minor -ge 5 \) -o $macosx_major -gt 10 ]; then
+ auxcflags="-pthread $auxcflags"
+ auxlibs="-lpthread $auxlibs"
+- else
+- auxcflags="-D_REENTRANT $auxcflags"
+- auxlibs="-lpthread $auxlibs"
+- fi
for f in $features ; do
- if test "x$f" = "xthread" ; then
-- if [ $macosx_minor -ge 5 ]; then
- auxcflags="-pthread $auxcflags"
- auxlibs="-lpthread $auxlibs"
-- else
-- auxcflags="-D_REENTRANT $auxcflags"
-- auxlibs="-lpthread $auxlibs"
-- fi
- fi
if test "x$f" = "xrpath" ; then
-- if [ $macosx_minor -ge 5 ]; then
+- if [ \( $macosx_major -eq 10 -a $macosx_minor -ge 5 \) -o $macosx_major -gt 10 ]; then
auxlibs="-Wl,-rpath,$libdir $auxlibs"
- fi
fi