ares: 131 -> 132

This commit is contained in:
Anderson Torres 2023-07-08 17:14:34 -03:00
parent a6a17138c1
commit 8dc06ce8e9
5 changed files with 49 additions and 68 deletions

View file

@ -1,21 +1,43 @@
diff --git a/desktop-ui/GNUmakefile b/desktop-ui/GNUmakefile diff -Naur source-old/desktop-ui/GNUmakefile source-new/desktop-ui/GNUmakefile
index 4515610d3..916c8fcd8 100644 --- source-old/desktop-ui/GNUmakefile 1969-12-31 21:00:01.000000000 -0300
--- a/desktop-ui/GNUmakefile +++ source-new/desktop-ui/GNUmakefile 2023-07-08 12:20:08.206582916 -0300
+++ b/desktop-ui/GNUmakefile @@ -91,8 +91,7 @@
@@ -91,7 +91,7 @@ endif
cp resource/$(name).plist $(output.path)/$(name).app/Contents/Info.plist cp resource/$(name).plist $(output.path)/$(name).app/Contents/Info.plist
cp -R $(ares.path)/Shaders $(output.path)/$(name).app/Contents/Resources/ cp -R $(ares.path)/Shaders $(output.path)/$(name).app/Contents/Resources/
cp -R $(mia.path)/Database $(output.path)/$(name).app/Contents/Resources/ cp -R $(mia.path)/Database $(output.path)/$(name).app/Contents/Resources/
- sips -s format icns resource/$(name).png --out $(output.path)/$(name).app/Contents/Resources/$(name).icns - sips -s format icns resource/$(name).png --out $(output.path)/$(name).app/Contents/Resources/$(name).icns
- codesign --force --deep --options runtime --entitlements resource/$(name).selfsigned.entitlements --sign - $(output.path)/$(name).app
+ png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns resource/$(name).png + png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns resource/$(name).png
codesign --force --deep --options runtime --entitlements resource/$(name).selfsigned.entitlements --sign - $(output.path)/$(name).app
else ifeq ($(platform),windows) else ifeq ($(platform),windows)
$(call mkdir,$(output.path)/Shaders/) $(call mkdir,$(output.path)/Shaders/)
diff --git a/genius/GNUmakefile b/genius/GNUmakefile $(call mkdir,$(output.path)/Database/)
index 5287309a8..8d80f9306 100644 @@ -115,8 +114,8 @@
--- a/genius/GNUmakefile else ifeq ($(shell id -un),root)
+++ b/genius/GNUmakefile $(error "make install should not be run as root")
@@ -24,7 +24,7 @@ ifeq ($(platform),macos) else ifeq ($(platform),macos)
- mkdir -p ~/Library/Application\ Support/$(name)/
- cp -R $(output.path)/$(name).app /Applications/$(name).app
+ mkdir -p $(prefix)/Applications/
+ cp -R $(output.path)/$(name).app $(prefix)/Applications/$(name).app
else ifneq ($(filter $(platform),linux bsd),)
mkdir -p $(prefix)/bin/
mkdir -p $(prefix)/share/applications/
diff -Naur source-old/mia/GNUmakefile source-new/mia/GNUmakefile
--- source-old/mia/GNUmakefile 1969-12-31 21:00:01.000000000 -0300
+++ source-new/mia/GNUmakefile 2023-07-08 12:16:55.991517276 -0300
@@ -39,7 +39,7 @@
mkdir -p $(output.path)/$(name).app/Contents/Resources/
mv $(output.path)/$(name) $(output.path)/$(name).app/Contents/MacOS/$(name)
cp resource/$(name).plist $(output.path)/$(name).app/Contents/Info.plist
- sips -s format icns resource/$(name).png --out $(output.path)/$(name).app/Contents/Resources/$(name).icns
+ png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns resource/$(name).png
endif
verbose: hiro.verbose nall.verbose all;
diff -Naur source-old/tools/genius/GNUmakefile source-new/tools/genius/GNUmakefile
--- source-old/tools/genius/GNUmakefile 1969-12-31 21:00:01.000000000 -0300
+++ source-new/tools/genius/GNUmakefile 2023-07-08 12:16:16.273503940 -0300
@@ -26,7 +26,7 @@
mkdir -p $(output.path)/$(name).app/Contents/Resources/ mkdir -p $(output.path)/$(name).app/Contents/Resources/
mv $(output.path)/$(name) $(output.path)/$(name).app/Contents/MacOS/$(name) mv $(output.path)/$(name) $(output.path)/$(name).app/Contents/MacOS/$(name)
cp data/$(name).plist $(output.path)/$(name).app/Contents/Info.plist cp data/$(name).plist $(output.path)/$(name).app/Contents/Info.plist
@ -23,17 +45,4 @@ index 5287309a8..8d80f9306 100644
+ png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns data/$(name).png + png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns data/$(name).png
endif endif
verbose: hiro.verbose nall.verbose all;
diff --git a/mia/GNUmakefile b/mia/GNUmakefile
index b6930b6df..7a51b5028 100644
--- a/mia/GNUmakefile
+++ b/mia/GNUmakefile
@@ -32,7 +32,7 @@ ifeq ($(platform),macos)
mkdir -p $(output.path)/$(name).app/Contents/Resources/
mv $(output.path)/$(name) $(output.path)/$(name).app/Contents/MacOS/$(name)
cp resource/$(name).plist $(output.path)/$(name).app/Contents/Info.plist
- sips -s format icns resource/$(name).png --out $(output.path)/$(name).app/Contents/Resources/$(name).icns
+ png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns resource/$(name).png
endif
verbose: hiro.verbose nall.verbose all; verbose: hiro.verbose nall.verbose all;

View file

@ -1,23 +0,0 @@
diff --git a/desktop-ui/GNUmakefile b/desktop-ui/GNUmakefile
index 916c8fcd8..b767c1335 100644
--- a/desktop-ui/GNUmakefile
+++ b/desktop-ui/GNUmakefile
@@ -92,7 +92,6 @@ endif
cp -R $(ares.path)/Shaders $(output.path)/$(name).app/Contents/Resources/
cp -R $(mia.path)/Database $(output.path)/$(name).app/Contents/Resources/
png2icns $(output.path)/$(name).app/Contents/Resources/$(name).icns resource/$(name).png
- codesign --force --deep --options runtime --entitlements resource/$(name).selfsigned.entitlements --sign - $(output.path)/$(name).app
else ifeq ($(platform),windows)
$(call mkdir,$(output.path)/Shaders/)
$(call mkdir,$(output.path)/Database/)
@@ -115,8 +114,8 @@ ifeq ($(platform),windows)
else ifeq ($(shell id -un),root)
$(error "make install should not be run as root")
else ifeq ($(platform),macos)
- mkdir -p ~/Library/Application\ Support/$(name)/
- cp -R $(output.path)/$(name).app /Applications/$(name).app
+ mkdir -p $(prefix)/Applications/
+ cp -R $(output.path)/$(name).app $(prefix)/Applications/$(name).app
else ifneq ($(filter $(platform),linux bsd),)
mkdir -p $(prefix)/bin/
mkdir -p $(prefix)/share/applications/

View file

@ -1,10 +1,6 @@
{ lib { lib
, stdenv , stdenv
, fetchFromGitHub , fetchFromGitHub
, pkg-config
, which
, wrapGAppsHook
, libicns
, SDL2 , SDL2
, alsa-lib , alsa-lib
, gtk3 , gtk3
@ -14,31 +10,31 @@
, libX11 , libX11
, libXv , libXv
, libao , libao
, libicns
, libpulseaudio , libpulseaudio
, openal , openal
, pkg-config
, udev , udev
, which
, wrapGAppsHook
, darwin , darwin
}: }:
let
inherit (darwin.apple_sdk_11_0.frameworks) Cocoa OpenAL;
in
stdenv.mkDerivation (finalAttrs: { stdenv.mkDerivation (finalAttrs: {
pname = "ares"; pname = "ares";
version = "131"; version = "132";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "ares-emulator"; owner = "ares-emulator";
repo = "ares"; repo = "ares";
rev = "v${finalAttrs.version}"; rev = "v${finalAttrs.version}";
hash = "sha256-gex53bh/175/i0cMimcPO26C6cxqQGPo4sp2bxh1sAw="; hash = "sha256-0D7bOv934k1cuP6qNxo0uLp5tSEstI8wm0FEwu6TuUw=";
}; };
patches = [ patches = [
./000-dont-rebuild-on-install.patch ./001-dont-rebuild-on-install.patch
./001-fix-ruby.patch ./002-fix-ruby.diff
./002-sips-to-png2icns.patch ./003-darwin-specific.patch
./003-fix-darwin-install.patch
]; ];
nativeBuildInputs = [ nativeBuildInputs = [
@ -64,8 +60,8 @@ stdenv.mkDerivation (finalAttrs: {
openal openal
udev udev
] ++ lib.optionals stdenv.isDarwin [ ] ++ lib.optionals stdenv.isDarwin [
Cocoa darwin.apple_sdk_11_0.frameworks.Cocoa
OpenAL darwin.apple_sdk_11_0.frameworks.OpenAL
]; ];
enableParallelBuilding = true; enableParallelBuilding = true;
@ -80,17 +76,16 @@ stdenv.mkDerivation (finalAttrs: {
"local=false" "local=false"
"openmp=true" "openmp=true"
"prefix=$(out)" "prefix=$(out)"
"-C desktop-ui"
]; ];
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isDarwin "-mmacosx-version-min=10.14"; env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isDarwin "-mmacosx-version-min=10.14";
meta = with lib; { meta = {
homepage = "https://ares-emu.net"; homepage = "https://ares-emu.net";
description = "Open-source multi-system emulator with a focus on accuracy and preservation"; description = "Open-source multi-system emulator with a focus on accuracy and preservation";
license = licenses.isc; license = lib.licenses.isc;
maintainers = with maintainers; [ Madouura AndersonTorres ]; maintainers = with lib.maintainers; [ Madouura AndersonTorres ];
platforms = platforms.unix; platforms = lib.platforms.unix;
}; };
}) })
# TODO: select between Qt, GTK2 and GTK3 # TODO: select between Qt and GTK3