···1+diff --git a/SConstruct b/SConstruct
2+index 48fd080..419b40d 100644
3+--- a/SConstruct
4++++ b/SConstruct
5+@@ -1,7 +1,7 @@
6+ import os
7+8+ # Load any environment variables that alter the build.
9+-env = Environment()
10++env = Environment(ENV = os.environ)
11+ if 'CCFLAGS' in os.environ:
12+ env.Append(CCFLAGS = os.environ['CCFLAGS'])
13+ if 'CXXFLAGS' in os.environ:
14+@@ -55,7 +55,7 @@ sky = env.Program("endless-sky", Glob("build/" + env["mode"] + "/*.cpp"))
15+16+17+ # Install the binary:
18+-env.Install("$DESTDIR$PREFIX/games", sky)
19++env.Install("$DESTDIR$PREFIX/bin", sky)
20+21+ # Install the desktop file:
22+ env.Install("$DESTDIR$PREFIX/share/applications", "endless-sky.desktop")
23+diff --git a/source/Files.cpp b/source/Files.cpp
24+index c8c8957..d196459 100644
25+--- a/source/Files.cpp
26++++ b/source/Files.cpp
27+@@ -114,15 +114,9 @@ void Files::Init(const char * const *argv)
28+ if(resources.back() != '/')
29+ resources += '/';
30+ #if defined __linux__ || defined __FreeBSD__ || defined __DragonFly__
31+- // Special case, for Linux: the resource files are not in the same place as
32+- // the executable, but are under the same prefix (/usr or /usr/local).
33+- static const string LOCAL_PATH = "/usr/local/";
34+- static const string STANDARD_PATH = "/usr/";
35+- static const string RESOURCE_PATH = "share/games/endless-sky/";
36+- if(!resources.compare(0, LOCAL_PATH.length(), LOCAL_PATH))
37+- resources = LOCAL_PATH + RESOURCE_PATH;
38+- else if(!resources.compare(0, STANDARD_PATH.length(), STANDARD_PATH))
39+- resources = STANDARD_PATH + RESOURCE_PATH;
40++ // Workaround for NixOS. Not sure how to proceed with other OSes, feedback
41++ // is welcome.
42++ resources += "../share/games/endless-sky/";
43+ #elif defined __APPLE__
44+ // Special case for Mac OS X: the resources are in ../Resources relative to
45+ // the folder the binary is in.