Cherry pick changes from wip-scritchui which should be mainline.
[SquirrelJME.git] / nanocoat / src / CMakeLists.txt
blobd0d7f30412a29c4afcdf70e4bf4eb1c2b1930f2f
1 # ---------------------------------------------------------------------------
2 # SquirrelJME
3 #     Copyright (C) Stephanie Gawroriski <xer@multiphasicapps.net>
4 # ---------------------------------------------------------------------------
5 # SquirrelJME is under the Mozilla Public License Version 2.0.
6 # See license.mkd for licensing and copyright information.
7 # ---------------------------------------------------------------------------
9 list(APPEND coreSources
10         alloc.c
11         allocSizeOf.c
12         atomic.c
13         boot.c
14         bytecode.c
15         classy.c
16         comparator.c
17         debug.c
18         descriptor.c
19         dylib.c
20         error.c
21         except.c
22         gfx.c
23         jdwp.c
24         list.c
25         loop.c
26         modelessStars.c
27         multithread.c
28         native.c
29         nvm.c
30         recycle.c
31         refcount.c
32         rom.c
33         seekable.c
34         stream.c
35         task.c
36         tread.c
37         tree.c
38         util.c
39         vmConfig.c
40         zip.c)
42 # The core library contains the main logic for the virtual machine
43 # For non-PIC:
44 add_library(Core OBJECT
45         ${coreSources})
46 # For PIC:
47 add_library(CorePIC OBJECT
48         ${coreSources})
50 # Needs to be position independent when included in other parts
51 set_property(TARGET CorePIC
52         PROPERTY POSITION_INDEPENDENT_CODE ON)
54 # Include main headers
55 target_include_directories(Core PUBLIC
56         "${CMAKE_SOURCE_DIR}/include")
57 target_include_directories(CorePIC PUBLIC
58         "${CMAKE_SOURCE_DIR}/include")
60 # Doxygen
61 squirreljme_doxygen(Core)
63 # Third party support libraries
64 add_subdirectory(3rdparty)