From 01dbbb72fa81334b54df125ca22b3890268cca83 Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Sun, 7 Jun 2015 14:21:07 +0000 Subject: [PATCH 1/3] install: crashdialog_TARGET no longer exists after 307eaec --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 55a0a98dbc..79b973e517 100644 --- a/Makefile +++ b/Makefile @@ -71,7 +71,7 @@ INSTALL_DATA = $(INSTALL) -m644 # program targets CORE = rsdl2 rnull game utility -TOOLS = editor crashdialog +TOOLS = editor gamemonitor VERSION = $(shell git name-rev --name-only --tags --no-undefined HEAD 2>/dev/null || echo git-`git rev-parse --short HEAD`) # dependencies From 5483384e4457d12b62f7d66fbaff7c5dcd7cacb9 Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Sun, 7 Jun 2015 13:52:14 +0000 Subject: [PATCH 2/3] install: work around historical BSD cp(1) behavior Strip ending / (slash) of the source when copying hicolor directory to avoid installing icons under a theme with empty name. This should unbreak expanding Icon in .desktop file by gtk_icon_theme_lookup_icon() on DragonFly and FreeBSD. |cp -R foo/ bar| == |cp -R foo/. bar| was disabled by NetBSD and OpenBSD years ago to match POSIX. Other cp(1) implementations aren't affected. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 79b973e517..f0cc1ba251 100644 --- a/Makefile +++ b/Makefile @@ -391,7 +391,7 @@ install-tools: tools install-linux-icons: @$(INSTALL_DIR) "$(DESTDIR)$(datadir)/icons/" - @$(CP_R) packaging/linux/hicolor/ "$(DESTDIR)$(datadir)/icons" + @$(CP_R) packaging/linux/hicolor "$(DESTDIR)$(datadir)/icons/" install-linux-desktop: @$(INSTALL_DIR) "$(DESTDIR)$(datadir)/applications" From fc7edb536da10cf7cfa1b0c2ed80cc01d44b24df Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Sun, 7 Jun 2015 14:13:00 +0000 Subject: [PATCH 3/3] build/install: fall back to Unix desktop Instead of enumerating every Unix assume Freedesktop-compliant behavior. In future Android may want to define its own flavor like OSX. --- Makefile | 15 ++++----------- OpenRA.Game/Platform.cs | 4 ++-- 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/Makefile b/Makefile index f0cc1ba251..1934ac005d 100644 --- a/Makefile +++ b/Makefile @@ -76,12 +76,10 @@ VERSION = $(shell git name-rev --name-only --tags --no-undefined HEAD 2>/dev # dependencies UNAME_S := $(shell uname -s) -ifeq ($(UNAME_S),Linux) -os-dependencies = linux-dependencies -else ifneq (,$(findstring BSD,$(UNAME_S))) -os-dependencies = bsd-dependencies -else ifeq ($(UNAME_S),Darwin) +ifeq ($(UNAME_S),Darwin) os-dependencies = osx-dependencies +else +os-dependencies = linux-dependencies endif @@ -311,11 +309,6 @@ linux-dependencies: cli-dependencies linux-native-dependencies linux-native-dependencies: @./thirdparty/configure-native-deps.sh -bsd-dependencies: cli-dependencies bsd-native-dependencies - -bsd-native-dependencies: - @./thirdparty/configure-native-deps.sh - windows-dependencies: @./thirdparty/fetch-thirdparty-deps-windows.sh @@ -380,7 +373,7 @@ install-core: default @$(INSTALL_PROGRAM) Newtonsoft.Json.dll "$(DATA_INSTALL_DIR)" @$(INSTALL_PROGRAM) RestSharp.dll "$(DATA_INSTALL_DIR)" -ifeq ($(shell uname),Linux) +ifneq ($(UNAME_S),Darwin) @$(CP) *.sh "$(DATA_INSTALL_DIR)" endif diff --git a/OpenRA.Game/Platform.cs b/OpenRA.Game/Platform.cs index 68d562a07a..62da9a8548 100644 --- a/OpenRA.Game/Platform.cs +++ b/OpenRA.Game/Platform.cs @@ -36,10 +36,10 @@ namespace OpenRA psi.RedirectStandardOutput = true; var p = Process.Start(psi); var kernelName = p.StandardOutput.ReadToEnd(); - if (kernelName.Contains("Linux") || kernelName.Contains("BSD")) - return PlatformType.Linux; if (kernelName.Contains("Darwin")) return PlatformType.OSX; + else + return PlatformType.Linux; } catch { }