| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- # A project header for using the DFPSR library.
- # Backends:
- # * Give the Graphics flag if the application should be able to create a window.
- # * Give the Sound flag if the application should be able to generate sounds.
- # Systems:
- # * Give the Linux flag when compiling on Linux or similar Posix systems having the same dependencies installed.
- # * Give the Windows flag when compiling on Microsoft Windows.
- # Features:
- # * Give the ReuseMemory flag to enable memory recycling using allocator.cpp.
- # This can cause crashes if you have more than one memory recycler linked,
- # because you don't want one implementation allocating and another freeing.
- # Strings use a subset of the C standard for mangling, so \\ is used to write \.
- # You can also use / and let the file abstraction layer convert it into \ automatically when running on Windows.
- if ReuseMemory
- Crawl "base/allocator.cpp"
- end if
- if Linux
- Message "Building for Linux\n"
- end if
- if Windows
- Message "Building for Windows\n"
- end if
- # Standard math library
- Link "m"
- # Standard threading library
- Link "pthread"
- # Paths are relative to the current script, even if imported somewhere else
- # so we use .. to leave the Source/DFPSR folder and then go into the windowManagers folder.
- WindowManager = "../windowManagers/NoWindow.cpp"
- if Graphics
- Message "Building with graphics enabled"
- if Linux
- Message " Using X11\n"
- Link "X11"
- WindowManager = "../windowManagers/X11Window.cpp"
- end if
- if Windows
- Message " Using Win32\n"
- Link "gdi32"
- Link "user32"
- Link "kernel32"
- Link "comctl32"
- WindowManager = "../windowManagers/Win32Window.cpp"
- end if
- end if
- Crawl WindowManager
- SoundManager = "../soundManagers/NoSound.cpp"
- if Sound
- Message "Building with sound enabled"
- if Linux
- Message " Using Alsa\n"
- Link "asound"
- SoundManager = "../soundManagers/AlsaSound.cpp"
- end if
- if Windows
- Message " Using WinMM\n"
- Link "winmm"
- SoundManager = "../soundManagers/WinMMSound.cpp"
- end if
- end if
- Crawl SoundManager
|