summaryrefslogtreecommitdiffstats
path: root/src/libnrtype/CMakeLists.txt
blob: 4a46bd0db17ccbadc587a0631fb7d5b1423928dc (plain)
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
# SPDX-License-Identifier: GPL-2.0-or-later

set(nrtype_SRC
	FontFactory.cpp
	FontInstance.cpp
	font-lister.cpp
	Layout-TNG.cpp
	Layout-TNG-Compute.cpp
	Layout-TNG-Input.cpp
	Layout-TNG-OutIter.cpp
	Layout-TNG-Output.cpp
	Layout-TNG-Scanline-Makers.cpp
        OpenTypeUtil.cpp

	# -------
	# Headers
	font-glyph.h
	font-instance.h
	font-lister.h
	font-style.h
	FontFactory.h
	Layout-TNG-Scanline-Maker.h
	Layout-TNG.h
        OpenTypeUtil.cpp
)

add_inkscape_lib(nrtype_LIB "${nrtype_SRC}")

# we have circular references between nrtype_LIB and inkscape_base!
# this workaround prevents undefined references in nrtype_LIB when building static libraries (likely link order problem)
if(NOT BUILD_SHARED_LIBS)
	if( WIN32 )
		target_link_libraries(nrtype_LIB PRIVATE inkscape_base -lGdi32)
	else()
		target_link_libraries(nrtype_LIB PRIVATE inkscape_base)
	endif()
else()
	if( WIN32 )
		target_link_libraries(nrtype_LIB PUBLIC 2Geom::2geom -lGdi32)
	else()
		target_link_libraries(nrtype_LIB PUBLIC 2Geom::2geom)
	endif()
endif()