File fix-data-path.patch of Package endless-sky

diff -Nur endless-sky-0.9.14/endless-sky.6 new/endless-sky.6
--- endless-sky-0.9.14/endless-sky.6	2021-07-11 22:56:35.000000000 +0200
+++ new/endless-sky.6	2021-12-04 14:40:42.589146795 +0100
@@ -17,7 +17,7 @@
 
 For a manual and other information, visit https://endless\-sky.github.io
 
-When run from the command line, if a resource directory is not specified, the program will check to see if the current directory contains directories named "data" and "images" and files named "keys.txt" and "credits.txt"; if so it will read resources from the current directory. Otherwise it will use /usr/local/share/games/endless\-sky if it exists, or /usr/share/games/endless\-sky/ otherwise.
+When run from the command line, if a resource directory is not specified, the program will check to see if the current directory contains directories named "data" and "images" and files named "keys.txt" and "credits.txt"; if so it will read resources from the current directory. Otherwise it will use /usr/local/share/endless\-sky if it exists, or /usr/share/endless\-sky/ otherwise.
 
 .SH OPTIONS
 .IP \fB\-h,\ \-\-help
diff -Nur endless-sky-0.9.14/SConstruct new/SConstruct
--- endless-sky-0.9.14/SConstruct	2021-07-11 22:56:35.000000000 +0200
+++ new/SConstruct	2021-12-04 14:40:42.589146795 +0100
@@ -198,11 +198,11 @@
 			RecursiveInstall(env, pathjoin(target, name), node.abspath)
 		else:
 			env.Install(target, node)
-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/data", "data")
-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/images", "images")
-RecursiveInstall(env, "$DESTDIR$PREFIX/share/games/endless-sky/sounds", "sounds")
-env.Install("$DESTDIR$PREFIX/share/games/endless-sky", "credits.txt")
-env.Install("$DESTDIR$PREFIX/share/games/endless-sky", "keys.txt")
+RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/data", "data")
+RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/images", "images")
+RecursiveInstall(env, "$DESTDIR$PREFIX/share/endless-sky/sounds", "sounds")
+env.Install("$DESTDIR$PREFIX/share/endless-sky", "credits.txt")
+env.Install("$DESTDIR$PREFIX/share/endless-sky", "keys.txt")
 
 # Make the word "install" in the command line do an installation.
 env.Alias("install", "$DESTDIR$PREFIX")
diff -Nur endless-sky-0.9.14/source/Files.cpp new/source/Files.cpp
--- endless-sky-0.9.14/source/Files.cpp	2021-07-11 22:56:35.000000000 +0200
+++ new/source/Files.cpp	2021-12-04 14:40:42.589146795 +0100
@@ -119,7 +119,7 @@
 	// the executable, but are under the same prefix (/usr or /usr/local).
 	static const string LOCAL_PATH = "/usr/local/";
 	static const string STANDARD_PATH = "/usr/";
-	static const string RESOURCE_PATH = "share/games/endless-sky/";
+	static const string RESOURCE_PATH = "share/endless-sky/";
 	if(!resources.compare(0, LOCAL_PATH.length(), LOCAL_PATH))
 		resources = LOCAL_PATH + RESOURCE_PATH;
 	else if(!resources.compare(0, STANDARD_PATH.length(), STANDARD_PATH))
openSUSE Build Service is sponsored by