-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gosu.podspec
83 lines (73 loc) · 2.78 KB
/
Gosu.podspec
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# TODO:
# - Gosu Touch subspec for iOS
# - Make the part of Gosu Touch that wraps main() yet another subspec, so users
# can keep their main() function and still use GosuView
# -
Pod::Spec.new do |s|
s.name = "Gosu"
s.version = "0.0.1"
s.summary = "2D game development library."
s.homepage = "http://libgosu.org/"
s.license = { :type => 'MIT', :file => 'COPYING' }
s.author = { "Julian Raschke" => "julian@raschke.de" }
s.source = { :git => "https://github.com/jlnr/gosu.git", :commit => "4b52ee0f70" }
s.subspec 'libogg' do |ss|
ss.header_dir = 'ogg'
ss.public_header_files = 'dependencies/libogg/include/ogg'
ss.source_files = 'dependencies/libogg/include/ogg', 'dependencies/libogg/src'
end
s.subspec 'libvorbis' do |ss|
ss.dependency 'Gosu/libogg'
ss.header_dir = 'vorbis'
ss.public_header_files = 'dependencies/libvorbis/include/vorbis'
ss.source_files = %w(analysis bitrate block codebook envelope floor0 floor1
info lookup lpc lsp mapping0 mdct psy registry res0
sharedbook smallft synthesis vorbisfile window).map do |basename|
"dependencies/libvorbis/lib/#{basename}.c"
end + ['dependencies/libvorbis/include/vorbis', 'dependencies/libvorbis/lib/*.h']
end
s.subspec 'Gosu' do |ss|
ss.dependency 'Gosu/libvorbis'
ss.frameworks = 'OpenGL', 'OpenAL', 'IOKit', 'Carbon', 'Cocoa', 'AudioToolbox', 'ApplicationServices'
ss.library = 'iconv'
# To find libpng headers, TODO use compiler flags for that, does not need to leak into client project
ss.xcconfig = { 'HEADER_SEARCH_PATHS' => '$(SDKROOT)/usr/X11/include', 'CLANG_CXX_LIBRARY' => 'libstdc++' }
ss.public_header_files = 'Gosu/*.hpp'
ss.source_files = ['Gosu/*.hpp', 'GosuImpl/**/*.hpp'] +
# Implementation files for OS X, taken from extconf.rb
# TODO - keep in sync with extconf & project - how?
%w(DirectoriesUnix.cpp
FileUnix.cpp
Graphics/Bitmap.cpp
Graphics/BitmapColorKey.cpp
Graphics/BitmapUtils.cpp
Graphics/BlockAllocator.cpp
Graphics/Color.cpp
Graphics/Font.cpp
Graphics/Graphics.cpp
Graphics/Image.cpp
Graphics/LargeImageData.cpp
Graphics/TexChunk.cpp
Graphics/Text.cpp
Graphics/Texture.cpp
Graphics/Transform.cpp
Inspection.cpp
IO.cpp
Math.cpp
Utility.cpp
Audio/AudioOpenAL.mm
Graphics/BitmapApple.mm
Graphics/TextMac.cpp
Graphics/TextTouch.mm
InputMac.mm
TextInputMac.mm
TimingApple.cpp
UtilityApple.mm
WindowMac.mm).map { |basename| "GosuImpl/#{basename}" } +
# This one is necessary for C++ development, but not Ruby
%w(GosuImpl/DirectoriesMac.mm)
# TODO add sockets too
ss.preserve_paths = 'GosuImpl/Audio/AudioOpenAL.cpp'
ss.platform = :osx, '10.5'
end
end