-
Notifications
You must be signed in to change notification settings - Fork 10
/
MakeHuge
201 lines (190 loc) · 7.52 KB
/
MakeHuge
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
## This document is under CC-3.0 Attribution-Share Alike 3.0
## http://creativecommons.org/licenses/by-sa/3.0/
## Attribution: There is no requirement to attribute the author.
#
# This will build a "huge" library containing all the Alembic .o
# files. It uses the .o files which you build when you build your
# custom version of Alembic.
#
# With the BUILD_DIR set to the proper path, you should be able to
# run:
# make -f MakeHuge
#
# BUILD_DIR: The path to the "lib/Alembic" in the build directory
BUILD_DIR = PATH_TO_ALEMBIC_BUILD/lib/Alembic
# If your version of Alembic doesn't have support for Ogawa, comment
# out the following
OGAWA_SUPPORT = 1
# Convenience variables for the different components
ABC = CMakeFiles/Alembic.dir/Abc
ABCCOLLECTION = CMakeFiles/Alembic.dir/AbcCollection
ABCABSTRACT = CMakeFiles/Alembic.dir/AbcCoreAbstract
ABCFACTORY = CMakeFiles/Alembic.dir/AbcCoreFactory
ABCHDF5 = CMakeFiles/Alembic.dir/AbcCoreHDF5.dir
ABCLAYER = CMakeFiles/Alembic.dir/AbcCoreLayer.dir
ABCOGAWA = CMakeFiles/Alembic.dir/AbcCoreOgawa
ABCGEOM = CMakeFiles/Alembic.dir/AbcGeom
ABCMAT = CMakeFiles/Alembic.dir/AbcMaterial
ABCUTIL = CMakeFiles/Alembic.dir/Util
OGAWA = CMakeFiles/Alembic.dir/Ogawa
# The resulting "huge" library
FULL_LIB = libAbcHuge.so
ifdef OGAWA_SUPPORT
OGAWA_FILES = \
$(BUILD_DIR)/$(ABCFACTORY)/IFactory.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/AprImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/ApwImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/ArImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/AwImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/CprData.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/CprImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/CpwData.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/CpwImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/MetaDataMap.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/OrData.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/OrImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/OwData.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/OwImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/ReadUtil.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/ReadWrite.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/SprImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/SpwImpl.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/StreamManager.cpp.o \
$(BUILD_DIR)/$(ABCOGAWA)/WriteUtil.cpp.o \
$(BUILD_DIR)/$(OGAWA)/IArchive.cpp.o \
$(BUILD_DIR)/$(OGAWA)/IData.cpp.o \
$(BUILD_DIR)/$(OGAWA)/IGroup.cpp.o \
$(BUILD_DIR)/$(OGAWA)/IStreams.cpp.o \
$(BUILD_DIR)/$(OGAWA)/OArchive.cpp.o \
$(BUILD_DIR)/$(OGAWA)/OData.cpp.o \
$(BUILD_DIR)/$(OGAWA)/OGroup.cpp.o \
$(BUILD_DIR)/$(OGAWA)/OStream.cpp.o
endif
OFILES = \
$(BUILD_DIR)/$(ABC)/ArchiveInfo.cpp.o \
$(BUILD_DIR)/$(ABC)/ErrorHandler.cpp.o \
$(BUILD_DIR)/$(ABC)/IArchive.cpp.o \
$(BUILD_DIR)/$(ABC)/IArrayProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/ICompoundProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/IObject.cpp.o \
$(BUILD_DIR)/$(ABC)/ISampleSelector.cpp.o \
$(BUILD_DIR)/$(ABC)/IScalarProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/OArchive.cpp.o \
$(BUILD_DIR)/$(ABC)/OArrayProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/OCompoundProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/OObject.cpp.o \
$(BUILD_DIR)/$(ABC)/OScalarProperty.cpp.o \
$(BUILD_DIR)/$(ABC)/Reference.cpp.o \
$(BUILD_DIR)/$(ABC)/SourceName.cpp.o \
$(BUILD_DIR)/$(ABCCOLLECTION)/ICollections.cpp.o \
$(BUILD_DIR)/$(ABCCOLLECTION)/OCollections.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ArchiveReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ArchiveWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ArrayPropertyReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ArrayPropertyWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ArraySample.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/BasePropertyReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/BasePropertyWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/CompoundPropertyReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/CompoundPropertyWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/Foundation.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ObjectReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ObjectWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ReadArraySampleCache.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ScalarPropertyReader.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ScalarPropertyWriter.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/ScalarSample.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/TimeSampling.cpp.o \
$(BUILD_DIR)/$(ABCABSTRACT)/TimeSamplingType.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/AprImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/ApwImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/ArImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/AwImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/CacheImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/CprData.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/CprImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/CpwData.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/CpwImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/DataTypeRegistry.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/HDF5Hierarchy.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/HDF5HierarchyReader.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/HDF5HierarchyWriter.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/HDF5Util.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/OrData.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/OrImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/OwData.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/OwImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/ReadUtil.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/ReadWrite.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/SprImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/SpwImpl.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/StringReadUtil.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/StringWriteUtil.cpp.o \
$(BUILD_DIR)/$(ABCHDF5)/WriteUtil.cpp.o \
$(BUILD_DIR)/$(ABCLAYER)/ArImpl.cpp.o \
$(BUILD_DIR)/$(ABCLAYER)/CprImpl.cpp.o \
$(BUILD_DIR)/$(ABCLAYER)/OrImpl.cpp.o \
$(BUILD_DIR)/$(ABCLAYER)/Read.cpp.o \
$(BUILD_DIR)/$(ABCLAYER)/Util.cpp.o \
$(OGAWA_FILES) \
$(BUILD_DIR)/$(ABCGEOM)/ArchiveBounds.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/Basis.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/CameraSample.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/FilmBackXformOp.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/GeometryScope.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/ICamera.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/ICurves.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/IFaceSet.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/ILight.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/INuPatch.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/IPoints.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/IPolyMesh.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/ISubD.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/IXform.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OCamera.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OCurves.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OFaceSet.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OLight.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/ONuPatch.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OPoints.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OPolyMesh.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OSubD.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/OXform.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/Visibility.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/XformOp.cpp.o \
$(BUILD_DIR)/$(ABCGEOM)/XformSample.cpp.o \
$(BUILD_DIR)/$(ABCMAT)/IMaterial.cpp.o \
$(BUILD_DIR)/$(ABCMAT)/InternalUtil.cpp.o \
$(BUILD_DIR)/$(ABCMAT)/MaterialAssignment.cpp.o \
$(BUILD_DIR)/$(ABCMAT)/MaterialFlatten.cpp.o \
$(BUILD_DIR)/$(ABCMAT)/OMaterial.cpp.o \
$(BUILD_DIR)/$(ABCUTIL)/Murmur3.cpp.o \
$(BUILD_DIR)/$(ABCUTIL)/Naming.cpp.o \
$(BUILD_DIR)/$(ABCUTIL)/SpookyV2.cpp.o \
$(BUILD_DIR)/$(ABCUTIL)/TokenMap.cpp.o
LIBRARIES = \
-lhdf5 \
-lhdf5_hl \
-lIex \
-lImath \
-lHalf
$(FULL_LIB): $(OFILES)
g++ -shared -fno-strict-aliasing \
-Wl,-soname,$(FULL_LIB) \
-Wl,--exclude-libs,ALL \
-o $@ $(OFILES) $(LIBRARIES)
#---------------------------------------------------------------------
# Testing rule
#
# Build a test application using the installed custom version of the
# Alembic libraries, and the shipped Houdini libraries.
#
ABCINSTALL = /usr/local/alembic-1.8.3
ABCINC = $(ABCINSTALL)/include
ABCLIB = $(ABCINSTALL)/lib
HALFINC = -I$(HFS)/custom/include/OpenEXR
HLIB = -L$(HFS)/dsolib
test: test.C $(FULL_LIB)
g++ -o test test.C -I$(ABCINC) $(HALFINC) \
$(HLIB) -L. -lAbcHuge
install: test