blob: 4c38e878914c16960bb7502cfa171ebf5ac5c81c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
--- lightyears.old 2008-11-03 20:16:40.000000000 +0100
+++ lightyears 2008-11-03 20:18:40.000000000 +0100
@@ -1,28 +1,16 @@
#!/usr/bin/python
# Set the location of the LightYears .py files here:
-LIGHTYEARS_DIR = "/usr/share/games/lightyears"
# Save games and configuration files are stored in the user's
# home directory.
-
if ( __name__ == "__main__" ):
import sys, os
- if (( LIGHTYEARS_DIR == None )
- or ( not os.path.exists(LIGHTYEARS_DIR) )):
- # Try current directory
- LIGHTYEARS_DIR = os.path.abspath(
- os.path.dirname(sys.argv[ 0 ]))
-
- sys.path.insert(0, os.path.join(LIGHTYEARS_DIR, 'code'))
-
- try:
- import startup
- except:
- print "Unable to find LightYears code in", LIGHTYEARS_DIR
- sys.exit(1)
+ sys.path.insert(0, "@GENTOO_LIBDIR@")
+
+ import startup
- startup.Main(os.path.join(LIGHTYEARS_DIR, 'data'))
+ startup.Main("@GENTOO_DATADIR@/data")
|