Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 84926c9480c8
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: ef0537b9cdd8
Choose a head ref
  • 8 commits
  • 10 files changed
  • 6 contributors

Commits on Apr 4, 2020

  1. osm2pgsql: enable on darwin

    (cherry picked from commit d6f5459)
    sikmir authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    ee4164e View commit details
  2. goldendict: enable on darwin

    (cherry picked from commit 217b221)
    sikmir authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    3c39e18 View commit details
  3. cloudflare-wrangler: adding dependencies for darwin

    (cherry picked from commit 6274ce1)
    mmahut authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    b460ece View commit details
  4. lepton: enable on darwin

    (cherry picked from commit 310b108)
    marsam authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    06fe4b2 View commit details
  5. mame: add darwin support

    (cherry picked from commit 39921bd)
    veprbl authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    8876e5e View commit details
  6. higan: fix darwin build

    (cherry picked from commit 4c931a8)
    veprbl authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    feacec6 View commit details
  7. libunique: add darwin

    libunique builds, and dependencies appear to build and run correctly,
    in OS X.
    
    (cherry picked from commit 45c9ad3)
    cgevans authored and LnL7 committed Apr 4, 2020
    Copy the full SHA
    5de67df View commit details

Commits on Apr 6, 2020

  1. Merge pull request #84332 from LnL7/darwin-backports

    darwin 20.03 backports
    LnL7 authored Apr 6, 2020
    Copy the full SHA
    ef0537b View commit details
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
diff --git i/config.cc w/config.cc
index 04b63f5..7a453d9 100644
--- i/config.cc
+++ w/config.cc
@@ -182,7 +182,7 @@ Preferences::Preferences():
pronounceOnLoadPopup( false ),
useInternalPlayer( InternalPlayerBackend::anyAvailable() ),
internalPlayerBackend( InternalPlayerBackend::defaultBackend() ),
- checkForNewReleases( true ),
+ checkForNewReleases( false ),
disallowContentFromOtherSites( false ),
enableWebPlugins( false ),
hideGoldenDictHeader( false ),
@@ -867,8 +867,8 @@ Class load() THROW_SPEC( exError )
c.preferences.proxyServer.systemProxyPassword = proxy.namedItem( "systemProxyPassword" ).toElement().text();
}

- if ( !preferences.namedItem( "checkForNewReleases" ).isNull() )
- c.preferences.checkForNewReleases = ( preferences.namedItem( "checkForNewReleases" ).toElement().text() == "1" );
+ //if ( !preferences.namedItem( "checkForNewReleases" ).isNull() )
+ // c.preferences.checkForNewReleases = ( preferences.namedItem( "checkForNewReleases" ).toElement().text() == "1" );

if ( !preferences.namedItem( "disallowContentFromOtherSites" ).isNull() )
c.preferences.disallowContentFromOtherSites = ( preferences.namedItem( "disallowContentFromOtherSites" ).toElement().text() == "1" );
@@ -1819,9 +1819,9 @@ void save( Class const & c ) THROW_SPEC( exError )
proxy.appendChild( opt );
}

- opt = dd.createElement( "checkForNewReleases" );
- opt.appendChild( dd.createTextNode( c.preferences.checkForNewReleases ? "1" : "0" ) );
- preferences.appendChild( opt );
+ //opt = dd.createElement( "checkForNewReleases" );
+ //opt.appendChild( dd.createTextNode( c.preferences.checkForNewReleases ? "1" : "0" ) );
+ //preferences.appendChild( opt );

opt = dd.createElement( "disallowContentFromOtherSites" );
opt.appendChild( dd.createTextNode( c.preferences.disallowContentFromOtherSites ? "1" : "0" ) );
diff --git i/preferences.cc w/preferences.cc
index 72c3147..7e48f00 100644
--- i/preferences.cc
+++ w/preferences.cc
@@ -314,6 +314,7 @@ Preferences::Preferences( QWidget * parent, Config::Class & cfg_ ):
this, SLOT( customProxyToggled( bool ) ) );

ui.checkForNewReleases->setChecked( p.checkForNewReleases );
+ ui.checkForNewReleases->setEnabled( false );
ui.disallowContentFromOtherSites->setChecked( p.disallowContentFromOtherSites );
ui.enableWebPlugins->setChecked( p.enableWebPlugins );
ui.hideGoldenDictHeader->setChecked( p.hideGoldenDictHeader );
62 changes: 62 additions & 0 deletions pkgs/applications/misc/goldendict/0001-dont-use-maclibs.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
diff --git i/goldendict.pro w/goldendict.pro
index 328dc20..5202a07 100644
--- i/goldendict.pro
+++ w/goldendict.pro
@@ -210,21 +210,18 @@ mac {
-llzo2
!CONFIG( no_ffmpeg_player ) {
LIBS += -lao \
- -lavutil-gd \
- -lavformat-gd \
- -lavcodec-gd
+ -lavutil \
+ -lavformat \
+ -lavcodec
}
- INCLUDEPATH = $${PWD}/maclibs/include
- LIBS += -L$${PWD}/maclibs/lib -framework AppKit -framework Carbon
+ LIBS += -framework AppKit -framework Carbon
OBJECTIVE_SOURCES += lionsupport.mm \
machotkeywrapper.mm \
macmouseover.mm \
speechclient_mac.mm
ICON = icons/macicon.icns
QMAKE_INFO_PLIST = myInfo.plist
- QMAKE_POST_LINK = mkdir -p GoldenDict.app/Contents/Frameworks & \
- cp -nR $${PWD}/maclibs/lib/ GoldenDict.app/Contents/Frameworks/ & \
- mkdir -p GoldenDict.app/Contents/MacOS/locale & \
+ QMAKE_POST_LINK = mkdir -p GoldenDict.app/Contents/MacOS/locale & \
cp -R locale/*.qm GoldenDict.app/Contents/MacOS/locale/ & \
mkdir -p GoldenDict.app/Contents/MacOS/help & \
cp -R $${PWD}/help/*.qch GoldenDict.app/Contents/MacOS/help/
@@ -232,15 +229,6 @@ mac {
CONFIG += zim_support
!CONFIG( no_chinese_conversion_support ) {
CONFIG += chinese_conversion_support
- CONFIG( x86 ) {
- QMAKE_POST_LINK += & mkdir -p GoldenDict.app/Contents/MacOS/opencc & \
- cp -R $${PWD}/opencc/*.json GoldenDict.app/Contents/MacOS/opencc/ & \
- cp -R $${PWD}/opencc/*.ocd GoldenDict.app/Contents/MacOS/opencc/
- } else {
- QMAKE_POST_LINK += & mkdir -p GoldenDict.app/Contents/MacOS/opencc & \
- cp -R $${PWD}/opencc/x64/*.json GoldenDict.app/Contents/MacOS/opencc/ & \
- cp -R $${PWD}/opencc/x64/*.ocd GoldenDict.app/Contents/MacOS/opencc/
- }
}
}
DEFINES += PROGRAM_VERSION=\\\"$$VERSION\\\"
diff --git i/tiff.cc w/tiff.cc
index e3cb8bf..9ff880f 100644
--- i/tiff.cc
+++ w/tiff.cc
@@ -6,8 +6,8 @@
#include "tiff.hh"

#if defined (Q_OS_MAC) || defined (Q_OS_WIN)
-#include "tiff/tiff.h"
-#include "tiff/tiffio.h"
+#include "tiff.h"
+#include "tiffio.h"
#else
#include "tiff.h"
#include "tiffio.h"
71 changes: 53 additions & 18 deletions pkgs/applications/misc/goldendict/default.nix
Original file line number Diff line number Diff line change
@@ -1,33 +1,68 @@
{ mkDerivation, lib, fetchFromGitHub, pkgconfig, libXtst, libvorbis, hunspell
, libao, ffmpeg, libeb, lzo, xz, libtiff, opencc
, qtbase, qtsvg, qtwebkit, qtx11extras, qttools, qmake }:
mkDerivation {
{ stdenv, mkDerivation, fetchFromGitHub, pkgconfig
, libXtst, libvorbis, hunspell, lzo, xz, bzip2, libiconv
, qtbase, qtsvg, qtwebkit, qtx11extras, qttools, qmake
, withCC ? true, opencc
, withEpwing ? true, libeb
, withExtraTiff ? true, libtiff
, withFFmpeg ? true, libao, ffmpeg
, withMultimedia ? true
, withZim ? true }:

mkDerivation rec {
pname = "goldendict";
version = "2020-01-09";

name = "goldendict-2019-08-01";
src = fetchFromGitHub {
owner = "goldendict";
repo = "goldendict";
rev = "0f951b06a55f3a201891cf645a556e773bda5f52";
sha256 = "1d1hn95vhvsmbq9q96l5adn90g0hg25dl01knb4y4v6v9x4yrl2x";
repo = pname;
rev = "da197ff5cd0e7326124c9240a1853a0e8b1de439";
sha256 = "0dlzwjh9wg4bzhhib71jycpp21qw762ww63a37dd50z1ymi61lxc";
};

patches = [
./0001-dont-check-for-updates.patch
] ++ stdenv.lib.optionals stdenv.isDarwin [
./0001-dont-use-maclibs.patch
];

postPatch = ''
substituteInPlace goldendict.pro \
--replace "hunspell-1.6.1" "hunspell-${stdenv.lib.versions.majorMinor hunspell.version}"
'';

nativeBuildInputs = [ pkgconfig qmake ];
buildInputs = [
qtbase qtsvg qtwebkit qtx11extras qttools
libXtst libvorbis hunspell libao ffmpeg libeb lzo xz libtiff opencc
];
qtbase qtsvg qtwebkit qttools
libvorbis hunspell xz lzo
] ++ stdenv.lib.optionals stdenv.isLinux [ qtx11extras libXtst ]
++ stdenv.lib.optionals stdenv.isDarwin [ bzip2 libiconv ]
++ stdenv.lib.optional withCC opencc
++ stdenv.lib.optional withEpwing libeb
++ stdenv.lib.optional withExtraTiff libtiff
++ stdenv.lib.optionals withFFmpeg [ libao ffmpeg ];

qmakeFlags = [
qmakeFlags = with stdenv.lib; [
"goldendict.pro"
"CONFIG+=zim_support"
"CONFIG+=chinese_conversion_support"
(optional withCC "CONFIG+=chinese_conversion_support")
(optional (!withCC) "CONFIG+=no_chinese_conversion_support")
(optional (!withEpwing) "CONFIG+=no_epwing_support")
(optional (!withExtraTiff) "CONFIG+=no_extra_tiff_handler")
(optional (!withFFmpeg) "CONFIG+=no_ffmpeg_player")
(optional (!withMultimedia)"CONFIG+=no_qtmultimedia_player")
(optional withZim "CONFIG+=zim_support")
];

meta = with lib; {
homepage = http://goldendict.org/;
postInstall = stdenv.lib.optionalString stdenv.isDarwin ''
mkdir -p $out/Applications
mv GoldenDict.app $out/Applications
wrapQtApp $out/Applications/GoldenDict.app/Contents/MacOS/GoldenDict
'';

meta = with stdenv.lib; {
homepage = "http://goldendict.org/";
description = "A feature-rich dictionary lookup program";
platforms = platforms.linux;
maintainers = with maintainers; [ gebner astsmtl ];
platforms = with platforms; linux ++ darwin;
maintainers = with maintainers; [ gebner astsmtl sikmir ];
license = licenses.gpl3Plus;
};
}
2 changes: 1 addition & 1 deletion pkgs/development/libraries/libunique/default.nix
Original file line number Diff line number Diff line change
@@ -32,6 +32,6 @@ stdenv.mkDerivation rec {
homepage = "https://wiki.gnome.org/Attic/LibUnique";
description = "A library for writing single instance applications";
license = stdenv.lib.licenses.lgpl21;
platforms = stdenv.lib.platforms.linux;
platforms = with stdenv.lib.platforms; linux ++ darwin;
};
}
9 changes: 7 additions & 2 deletions pkgs/development/tools/cloudflare-wrangler/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl
{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, curl, darwin
}:

rustPlatform.buildRustPackage rec {
@@ -16,7 +16,12 @@ rustPlatform.buildRustPackage rec {

nativeBuildInputs = [ pkg-config ];

buildInputs = [ openssl ];
buildInputs = [ openssl ] ++ stdenv.lib.optionals stdenv.isDarwin [
curl
darwin.apple_sdk.frameworks.Security
darwin.apple_sdk.frameworks.CoreServices
darwin.apple_sdk.frameworks.CoreFoundation
];

# tries to use "/homeless-shelter" and fails
doCheck = false;
51 changes: 37 additions & 14 deletions pkgs/misc/emulators/higan/default.nix
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
{ stdenv, fetchurl
, p7zip, pkgconfig
, p7zip, pkgconfig, libicns
, libX11, libXv
, udev
, libGLU, libGL, SDL
, Carbon, Cocoa, OpenGL, OpenAL
, libao, openal, libpulseaudio
, gtk2, gtksourceview
, runtimeShell }:
@@ -21,11 +22,24 @@ stdenv.mkDerivation rec {
};

patches = [ ./0001-change-flags.diff ];
postPatch = "sed '1i#include <cmath>' -i higan/fc/ppu/ppu.cpp";
postPatch = ''
sed '1i#include <cmath>' -i higan/fc/ppu/ppu.cpp
for file in icarus/GNUmakefile higan/target-tomoko/GNUmakefile; do
substituteInPlace "$file" \
--replace 'sips -s format icns data/$(name).png --out out/$(name).app/Contents/Resources/$(name).icns' \
'png2icns out/$(name).app/Contents/Resources/$(name).icns data/$(name).png'
done
'';

nativeBuildInputs = [ p7zip pkgconfig ]
++ optional stdenv.isDarwin [ libicns ];

buildInputs =
[ p7zip pkgconfig libX11 libXv udev libGLU libGL
SDL libao openal libpulseaudio gtk2 gtksourceview ];
[ SDL libao ]
++ optionals stdenv.isLinux [ openal libpulseaudio udev libX11 libXv libGLU libGL gtk2 gtksourceview ]
++ optionals stdenv.isDarwin [ Carbon Cocoa OpenGL OpenAL ]
;

unpackPhase = ''
7z x $src
@@ -38,27 +52,36 @@ stdenv.mkDerivation rec {
'';

# Now the cheats file will be distributed separately
installPhase = ''
install -dm 755 $out/bin $out/share/applications $out/share/higan $out/share/pixmaps
install -m 755 icarus/out/icarus $out/bin/
install -m 755 higan/out/higan $out/bin/
install -m 644 higan/data/higan.desktop $out/share/applications/
install -m 644 higan/data/higan.png $out/share/pixmaps/higan-icon.png
install -m 644 higan/resource/logo/higan.png $out/share/pixmaps/higan-logo.png
installPhase = (if !stdenv.isDarwin then ''
mkdir -p "$out"/bin "$out"/share/applications "$out"/share/pixmaps
install -m 755 icarus/out/icarus "$out"/bin/
install -m 755 higan/out/higan "$out"/bin/
install -m 644 higan/data/higan.desktop "$out"/share/applications/
install -m 644 higan/data/higan.png "$out"/share/pixmaps/higan-icon.png
install -m 644 higan/resource/logo/higan.png "$out"/share/pixmaps/higan-logo.png
'' else ''
mkdir "$out"
mv higan/out/higan.app "$out"/
mv icarus/out/icarus.app "$out"/
'') + ''
mkdir -p "$out"/share/higan
cp --recursive --no-dereference --preserve='links' --no-preserve='ownership' \
higan/systems/* $out/share/higan/
higan/systems/* "$out"/share/higan/
'';

fixupPhase = ''
fixupPhase = let
dest = if !stdenv.isDarwin then "\\$HOME/.local/share/higan" else "\\$HOME/Library/Application Support/higan";
in ''
# A dirty workaround, suggested by @cpages:
# we create a first-run script to populate
# the local $HOME with all the auxiliary
# stuff needed by higan at runtime
mkdir -p "$out"/bin
cat <<EOF > $out/bin/higan-init.sh
#!${runtimeShell}
cp --recursive --update $out/share/higan/*.sys \$HOME/.local/share/higan/
cp --recursive --update $out/share/higan/*.sys "${dest}"/
EOF
28 changes: 21 additions & 7 deletions pkgs/misc/emulators/mame/default.nix
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
{ stdenv, mkDerivation, fetchFromGitHub, makeDesktopItem, makeWrapper
, python, pkgconfig, SDL2, SDL2_ttf, alsaLib, which, qtbase, libXinerama
, libpcap, CoreAudioKit, ForceFeedback
, installShellFiles }:

with stdenv;

let
majorVersion = "0";
minorVersion = "217";

desktopItem = makeDesktopItem {
name = "MAME";
exec = "mame${stdenv.lib.optionalString stdenv.is64bit "64"}";
exec = "mame${lib.optionalString stdenv.is64bit "64"}";
desktopName = "MAME";
genericName = "MAME is a multi-purpose emulation framework";
categories = "System;Emulator;";
@@ -27,13 +30,22 @@ in mkDerivation {
};

hardeningDisable = [ "fortify" ];
NIX_CFLAGS_COMPILE = [ "-Wno-error=maybe-uninitialized" ];
NIX_CFLAGS_COMPILE = [ "-Wno-error=maybe-uninitialized" "-Wno-error=missing-braces" ];

makeFlags = [ "TOOLS=1" ];
makeFlags = [
"TOOLS=1"
"USE_LIBSDL=1"
]
++ lib.optionals stdenv.cc.isClang [ "CC=clang" "CXX=clang++" ]
;

dontWrapQtApps = true;

buildInputs = [ SDL2 SDL2_ttf alsaLib qtbase libXinerama ];
buildInputs =
[ SDL2 SDL2_ttf qtbase libXinerama ]
++ lib.optional stdenv.isLinux alsaLib
++ lib.optionals stdenv.isDarwin [ libpcap CoreAudioKit ForceFeedback ]
;
nativeBuildInputs = [ python pkgconfig which makeWrapper installShellFiles ];

# by default MAME assumes that paths with stock resources
@@ -58,16 +70,18 @@ in mkDerivation {
installManPage ${dest}/docs/man/*.1 ${dest}/docs/man/*.6
mv artwork plugins samples ${dest}
'' + lib.optionalString stdenv.isLinux ''
mkdir -p $out/share
ln -s ${desktopItem}/share/applications $out/share
'';

meta = with stdenv.lib; {
meta = with lib; {
description = "Is a multi-purpose emulation framework";
homepage = https://www.mamedev.org/;
license = with licenses; [ bsd3 gpl2Plus ];
platforms = [ "x86_64-linux" "i686-linux" ];
platforms = platforms.unix;
# makefile needs fixes for install target
badPlatforms = [ "aarch64-linux" ];
maintainers = with maintainers; [ gnidorah ];
};
}
Loading