Fix build
[folly.git] / folly / Makefile.am
1 SUBDIRS = . test
2
3 ACLOCAL_AMFLAGS = -I m4
4
5 CLEANFILES =
6
7 noinst_PROGRAMS = generate_fingerprint_tables
8 generate_fingerprint_tables_SOURCES = build/GenerateFingerprintTables.cpp
9 generate_fingerprint_tables_LDADD = libfollybase.la
10
11 noinst_LTLIBRARIES = \
12         libfollybase.la
13
14 lib_LTLIBRARIES = \
15         libfolly.la \
16         libfollybenchmark.la
17
18 follyincludedir = $(includedir)/folly
19
20 nobase_follyinclude_HEADERS = \
21         ApplyTuple.h \
22         Arena.h \
23         Arena-inl.h \
24         Assume.h \
25         AtomicBitSet.h \
26         AtomicHashArray.h \
27         AtomicHashArray-inl.h \
28         AtomicHashMap.h \
29         AtomicHashMap-inl.h \
30         AtomicLinkedList.h \
31         AtomicStruct.h \
32         AtomicUnorderedMap.h \
33         Baton.h \
34         Benchmark.h \
35         Bits.h \
36         Checksum.h \
37         ConcurrentSkipList.h \
38         ConcurrentSkipList-inl.h \
39         ContainerTraits.h \
40         Conv.h \
41         CpuId.h \
42         CPortability.h \
43         detail/AtomicHashUtils.h \
44         detail/AtomicUnorderedMapUtils.h \
45         detail/BitIteratorDetail.h \
46         detail/BitsDetail.h \
47         detail/CacheLocality.h \
48         detail/ChecksumDetail.h \
49         detail/Clock.h \
50         detail/DiscriminatedPtrDetail.h \
51         detail/ExceptionWrapper.h \
52         detail/FileUtilDetail.h \
53         detail/FingerprintPolynomial.h \
54         detail/FunctionalExcept.h \
55         detail/Futex.h \
56         detail/GroupVarintDetail.h \
57         detail/IPAddress.h \
58         detail/Malloc.h \
59         detail/MemoryIdler.h \
60         detail/MPMCPipelineDetail.h \
61         detail/RangeCommon.h \
62         detail/RangeSse42.h \
63         detail/Sleeper.h \
64         detail/SlowFingerprint.h \
65         detail/SpinLockImpl.h \
66         detail/Stats.h \
67         detail/ThreadLocalDetail.h \
68         detail/TurnSequencer.h \
69         detail/UncaughtExceptionCounter.h \
70         Demangle.h \
71         DiscriminatedPtr.h \
72         DynamicConverter.h \
73         dynamic.h \
74         dynamic-inl.h \
75         Exception.h \
76         ExceptionWrapper.h \
77         Executor.h \
78         EvictingCacheMap.h \
79         experimental/AutoTimer.h \
80         experimental/Bits.h \
81         experimental/BitVectorCoding.h \
82         experimental/ExecutionObserver.h \
83         experimental/EliasFanoCoding.h \
84         experimental/EventCount.h \
85         experimental/Instructions.h \
86         experimental/fibers/AddTasks.h \
87         experimental/fibers/AddTasks-inl.h \
88         experimental/fibers/Baton.h \
89         experimental/fibers/Baton-inl.h \
90         experimental/fibers/BoostContextCompatibility.h \
91         experimental/fibers/EventBaseLoopController.h \
92         experimental/fibers/EventBaseLoopController-inl.h \
93         experimental/fibers/Fiber.h \
94         experimental/fibers/Fiber-inl.h \
95         experimental/fibers/FiberManager.h \
96         experimental/fibers/FiberManager-inl.h \
97         experimental/fibers/FiberManagerMap.h \
98         experimental/fibers/ForEach.h \
99         experimental/fibers/ForEach-inl.h \
100         experimental/fibers/GenericBaton.h \
101         experimental/fibers/GuardPageAllocator.h \
102         experimental/fibers/LoopController.h \
103         experimental/fibers/Promise.h \
104         experimental/fibers/Promise-inl.h \
105         experimental/fibers/SimpleLoopController.h \
106         experimental/fibers/TimedMutex.h \
107         experimental/fibers/TimedMutex-inl.h \
108         experimental/fibers/TimeoutController.h \
109         experimental/fibers/traits.h \
110         experimental/fibers/WhenN.h \
111         experimental/fibers/WhenN-inl.h \
112         experimental/FunctionScheduler.h \
113         experimental/FutureDAG.h \
114         experimental/io/FsUtil.h \
115         experimental/JSONSchema.h \
116         experimental/LockFreeRingBuffer.h \
117         experimental/NestedCommandLineApp.h \
118         experimental/ProgramOptions.h \
119         experimental/Select64.h \
120         experimental/StringKeyedCommon.h \
121         experimental/StringKeyedUnorderedMap.h \
122         experimental/StringKeyedUnorderedSet.h \
123         experimental/TestUtil.h \
124         experimental/TupleOps.h \
125         SparseByteSet.h \
126         FBString.h \
127         FBVector.h \
128         File.h \
129         FileUtil.h \
130         Fingerprint.h \
131         folly-config.h \
132         Foreach.h \
133         FormatArg.h \
134         FormatTraits.h \
135         Format.h \
136         Format-inl.h \
137         futures/Barrier.h \
138         futures/ThreadedExecutor.h \
139         futures/DrivableExecutor.h \
140         futures/Future-pre.h \
141         futures/helpers.h \
142         futures/Future.h \
143         futures/Future-inl.h \
144         futures/FutureException.h \
145         futures/InlineExecutor.h \
146         futures/ManualExecutor.h \
147         futures/OpaqueCallbackShunt.h \
148         futures/Promise-inl.h \
149         futures/Promise.h \
150         futures/QueuedImmediateExecutor.h \
151         futures/ScheduledExecutor.h \
152         futures/SharedPromise.h \
153         futures/SharedPromise-inl.h \
154         futures/ThreadWheelTimekeeper.h \
155         futures/Timekeeper.h \
156         futures/Try-inl.h \
157         futures/Try.h \
158         futures/Unit.h \
159         futures/detail/Core.h \
160         futures/detail/FSM.h \
161         futures/detail/Types.h \
162         gen/Base.h \
163         gen/Base-inl.h \
164         gen/Combine.h \
165         gen/Combine-inl.h \
166         gen/Core.h \
167         gen/Core-inl.h \
168         gen/File.h \
169         gen/File-inl.h \
170         gen/Parallel.h \
171         gen/Parallel-inl.h \
172         gen/ParallelMap.h \
173         gen/ParallelMap-inl.h \
174         gen/String.h \
175         gen/String-inl.h \
176         GroupVarint.h \
177         Hash.h \
178         IPAddress.h \
179         IPAddressV4.h \
180         IPAddressV6.h \
181         IPAddressException.h \
182         IndexedMemPool.h \
183         IntrusiveList.h \
184         io/Compression.h \
185         io/Cursor.h \
186         io/IOBuf.h \
187         io/IOBufQueue.h \
188         io/RecordIO.h \
189         io/RecordIO-inl.h \
190         io/TypedIOBuf.h \
191         io/ShutdownSocketSet.h \
192         io/async/AsyncPipe.h \
193         io/async/AsyncTimeout.h \
194         io/async/AsyncTransport.h \
195         io/async/AsyncUDPServerSocket.h \
196         io/async/AsyncUDPSocket.h \
197         io/async/AsyncServerSocket.h \
198         io/async/AsyncSignalHandler.h \
199         io/async/AsyncSocket.h \
200         io/async/AsyncSocketBase.h \
201         io/async/AsyncSSLSocket.h \
202         io/async/AsyncSocketException.h \
203         io/async/DelayedDestructionBase.h \
204         io/async/DelayedDestruction.h \
205         io/async/EventBase.h \
206         io/async/EventBaseLocal.h \
207         io/async/EventBaseManager.h \
208         io/async/EventFDWrapper.h \
209         io/async/EventHandler.h \
210         io/async/EventUtil.h \
211         io/async/NotificationQueue.h \
212         io/async/HHWheelTimer.h \
213         io/async/Request.h \
214         io/async/SSLContext.h \
215         io/async/ScopedEventBaseThread.h \
216         io/async/TimeoutManager.h \
217         io/async/test/AsyncSSLSocketTest.h \
218         io/async/test/BlockingSocket.h \
219         io/async/test/MockAsyncSocket.h \
220         io/async/test/MockAsyncServerSocket.h \
221         io/async/test/MockAsyncSSLSocket.h \
222         io/async/test/MockAsyncTransport.h \
223         io/async/test/MockAsyncUDPSocket.h \
224         io/async/test/SocketPair.h \
225         io/async/test/TimeUtil.h \
226         io/async/test/UndelayedDestruction.h \
227         io/async/test/Util.h \
228         json.h \
229         Lazy.h \
230         LifoSem.h \
231         Likely.h \
232         Logging.h \
233         MacAddress.h \
234         Malloc.h \
235         MapUtil.h \
236         Memory.h \
237         MemoryMapping.h \
238         MicroSpinLock.h \
239         MoveWrapper.h \
240         MPMCPipeline.h \
241         MPMCQueue.h \
242         Optional.h \
243         PackedSyncPtr.h \
244         Padded.h \
245         PicoSpinLock.h \
246         Portability.h \
247         Preprocessor.h \
248         ProducerConsumerQueue.h \
249         Random.h \
250         Random-inl.h \
251         Range.h \
252         ReadMostlySharedPtr.h \
253         RWSpinLock.h \
254         ScopeGuard.h \
255         SharedMutex.h \
256         Singleton.h \
257         Singleton-inl.h \
258         SmallLocks.h \
259         small_vector.h \
260         SocketAddress.h \
261         sorted_vector_types.h \
262         SpinLock.h \
263         SpookyHashV1.h \
264         SpookyHashV2.h \
265         stats/BucketedTimeSeries-defs.h \
266         stats/BucketedTimeSeries.h \
267         stats/Histogram-defs.h \
268         stats/Histogram.h \
269         stats/MultiLevelTimeSeries-defs.h \
270         stats/MultiLevelTimeSeries.h \
271         String.h \
272         String-inl.h \
273         Subprocess.h \
274         Synchronized.h \
275         test/FBStringTestBenchmarks.cpp.h \
276         test/FBVectorTestBenchmarks.cpp.h \
277         test/function_benchmark/benchmark_impl.h \
278         test/function_benchmark/test_functions.h \
279         test/SynchronizedTestLib.h \
280         test/SynchronizedTestLib-inl.h \
281         ThreadCachedArena.h \
282         ThreadCachedInt.h \
283         ThreadLocal.h \
284         ThreadName.h \
285         TimeoutQueue.h \
286         Traits.h \
287         Unicode.h \
288         Uri.h \
289         Uri-inl.h \
290         Varint.h \
291         VersionCheck.h
292
293 FormatTables.cpp: build/generate_format_tables.py
294         $(PYTHON) build/generate_format_tables.py
295 CLEANFILES += FormatTables.cpp
296
297 EscapeTables.cpp: build/generate_escape_tables.py
298         $(PYTHON) build/generate_escape_tables.py
299 CLEANFILES += EscapeTables.cpp
300
301 GroupVarintTables.cpp: build/generate_varint_tables.py
302         $(PYTHON) build/generate_varint_tables.py
303 CLEANFILES += GroupVarintTables.cpp
304
305 libfollybase_la_SOURCES = \
306         Conv.cpp \
307         Demangle.cpp \
308         detail/RangeCommon.cpp \
309         detail/RangeSse42.cpp \
310         EscapeTables.cpp \
311         Format.cpp \
312         FormatTables.cpp \
313         Malloc.cpp \
314         StringBase.cpp \
315         String.cpp \
316         Unicode.cpp
317
318 libfolly_la_SOURCES = \
319         Bits.cpp \
320         Checksum.cpp \
321         detail/CacheLocality.cpp \
322         dynamic.cpp \
323         File.cpp \
324         FileUtil.cpp \
325         FingerprintTables.cpp \
326         futures/Barrier.cpp \
327         futures/ThreadedExecutor.cpp \
328         futures/Future.cpp \
329         futures/InlineExecutor.cpp \
330         futures/ManualExecutor.cpp \
331         futures/QueuedImmediateExecutor.cpp \
332         futures/ThreadWheelTimekeeper.cpp \
333         detail/Futex.cpp \
334         GroupVarint.cpp \
335         GroupVarintTables.cpp \
336         IPAddress.cpp \
337         IPAddressV4.cpp \
338         IPAddressV6.cpp \
339         LifoSem.cpp \
340         io/Compression.cpp \
341         io/IOBuf.cpp \
342         io/IOBufQueue.cpp \
343         io/RecordIO.cpp \
344         io/ShutdownSocketSet.cpp \
345         io/async/AsyncPipe.cpp \
346         io/async/AsyncTimeout.cpp \
347         io/async/AsyncUDPSocket.cpp \
348         io/async/AsyncServerSocket.cpp \
349         io/async/AsyncSignalHandler.cpp \
350         io/async/AsyncSocket.cpp \
351         io/async/AsyncSSLSocket.cpp \
352         io/async/EventBase.cpp \
353         io/async/EventBaseLocal.cpp \
354         io/async/EventBaseManager.cpp \
355         io/async/EventHandler.cpp \
356         io/async/SSLContext.cpp \
357         io/async/ScopedEventBaseThread.cpp \
358         io/async/HHWheelTimer.cpp \
359         io/async/test/SocketPair.cpp \
360         io/async/test/TimeUtil.cpp \
361         json.cpp \
362         detail/MemoryIdler.cpp \
363         MacAddress.cpp \
364         MemoryMapping.cpp \
365         Random.cpp \
366         SafeAssert.cpp \
367         SharedMutex.cpp \
368         Singleton.cpp \
369         SocketAddress.cpp \
370         SpookyHashV1.cpp \
371         SpookyHashV2.cpp \
372         stats/Instantiations.cpp \
373         Subprocess.cpp \
374         ThreadCachedArena.cpp \
375         TimeoutQueue.cpp \
376         Uri.cpp \
377         Version.cpp \
378         experimental/fibers/Baton.cpp \
379         experimental/fibers/Fiber.cpp \
380         experimental/fibers/FiberManager.cpp \
381         experimental/fibers/FiberManagerMap.cpp \
382         experimental/fibers/GuardPageAllocator.cpp \
383         experimental/fibers/TimeoutController.cpp \
384         experimental/FunctionScheduler.cpp \
385         experimental/io/FsUtil.cpp \
386         experimental/JSONSchema.cpp \
387         experimental/NestedCommandLineApp.cpp \
388         experimental/ProgramOptions.cpp \
389         experimental/Select64.cpp \
390         experimental/TestUtil.cpp
391
392 if HAVE_LINUX
393 nobase_follyinclude_HEADERS += \
394         experimental/io/HugePages.h
395 libfolly_la_SOURCES += \
396         experimental/io/HugePages.cpp
397 endif
398
399 if !HAVE_LINUX
400 libfollybase_la_SOURCES += detail/Clock.cpp
401 endif
402
403 if !HAVE_WEAK_SYMBOLS
404 libfollybase_la_SOURCES += detail/MallocImpl.cpp
405 endif
406
407 if !HAVE_BITS_FUNCTEXCEPT
408 libfollybase_la_SOURCES += detail/FunctionalExcept.cpp
409 endif
410
411 libfollybase_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LT_VERSION)
412
413 libfolly_la_LIBADD = libfollybase.la
414 libfolly_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LT_VERSION) -lssl
415
416 FingerprintTables.cpp: generate_fingerprint_tables
417         ./generate_fingerprint_tables
418 CLEANFILES += FingerprintTables.cpp
419
420 libfollybenchmark_la_SOURCES = Benchmark.cpp
421 libfollybenchmark_la_LIBADD = libfolly.la
422 libfollybenchmark_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LT_VERSION)