Mercurial > fife-parpg
annotate build/openbsd4-config.py @ 542:67f6f3538e88
Refactored the Quest class a bit. Made it a base class for other possible quest types. Added the RETURN_ITEM quest type.
author | prock@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Tue, 01 Jun 2010 21:38:14 +0000 |
parents | be291458d9b5 |
children | be625cdff350 |
rev | line source |
---|---|
429
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
1 # Install the following packages: libvorbis python py-yaml swig png openal sdl |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
2 # sdl-image sdl-ttf guichan boost |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
3 # |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
4 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
5 import sys |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
6 import os |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
7 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
8 def initEnvironment(env): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
9 # Vorbisfile |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
10 env.Append(CPPPATH = [ |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
11 os.path.join('/', 'usr', 'local', 'include'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
12 os.path.join('/', 'usr', 'local', 'include', 'vorbis') |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
13 ]) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
14 env.Append(LIBPATH = [os.path.join('/', 'usr', 'local', 'lib')]) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
15 env.Append(LIBS = ['ogg', 'vorbis']) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
16 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
17 # PNG |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
18 env.Append(CPPPATH = [os.path.join('/', 'usr', 'local', 'include', 'libpng')]) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
19 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
20 # Python library |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
21 pythonversion = 'python' + str(os.sys.version_info[0]) + '.' + str(os.sys.version_info[1]) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
22 env.Append(CPPPATH = os.path.join('/', 'usr', 'local', 'include', pythonversion)) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
23 env.Append(LIBS = [pythonversion, 'util']) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
24 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
25 # OpenBSD specific pthreads option |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
26 env.Append(LINKFLAGS = ['-pthread']) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
27 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
28 return env |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
29 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
30 def addExtras(env, opengl): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
31 if opengl: |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
32 env.Append(LIBS = ['stdc++', 'GL', 'GLU']) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
33 env.Append(LIBPATH = os.path.join('/', 'usr', 'X11R6', 'lib')) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
34 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
35 return env |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
36 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
37 def getRequiredHeaders(opengl): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
38 return None |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
39 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
40 def getRequiredLibs(opengl): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
41 libs = [ |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
42 ('vorbisfile', 'vorbisfile.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
43 ('openal', 'AL/al.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
44 ('SDL', 'SDL.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
45 ('SDL_ttf', 'SDL_ttf.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
46 ('SDL_image', 'SDL_image.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
47 ('guichan', 'guichan.hpp'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
48 ('guichan_sdl', ''), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
49 (('boost_filesystem', 'boost_filesystem-gcc', 'boost_filesystem-gcc41', 'boost_filesystem-mt'), 'boost/filesystem.hpp'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
50 (('boost_regex', 'boost_regex-gcc', 'boost_regex-gcc41', 'boost_regex-mt'), 'boost/regex.hpp'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
51 ('png', 'png.h'), |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
52 ('Xcursor', 'X11/Xcursor/Xcursor.h')] |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
53 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
54 if (opengl): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
55 libs.append(('guichan_opengl', '')) |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
56 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
57 return libs |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
58 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
59 def getOptionalLibs(opengl): |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
60 return None |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
61 |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
62 # vim: ft=python: |
be291458d9b5
Adding OpenBSD support. Thanks to tobiasu.
prock@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff
changeset
|
63 |