Avoid some dynamic_casts
[LibreOffice.git] / RepositoryExternal.mk
blobfd5c02d29287149971a9c2d40cfb495b15331329
1 # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 # This file incorporates work covered by the following license notice:
11 # Licensed to the Apache Software Foundation (ASF) under one or more
12 # contributor license agreements. See the NOTICE file distributed
13 # with this work for additional information regarding copyright
14 # ownership. The ASF licenses this file to you under the Apache
15 # License, Version 2.0 (the "License"); you may not use this file
16 # except in compliance with the License. You may obtain a copy of
17 # the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 # this file describes all the external libraries
21 # depending on the configure options these may be taken from the system,
22 # or the internal/bundled copy may be built.
24 # for every external, a function gb_LinkTarget__use_FOO is defined,
25 # once for the system case, once for the internal case.
27 # in the system case, no libraries should be registered, but the target-local
28 # variable LIBS should be set to FOO_LIBS, and INCLUDES to FOO_CFLAGS.
31 ifeq ($(CPUNAME),X86_64)
32 wnt_arch_subdir_optional=x64/
33 wnt_arch_subdir_mandatory=x64
34 else ifeq ($(CPUNAME),INTEL)
35 wnt_arch_subdir_mandatory=Win32
36 endif
38 # External headers
40 ifneq ($(SYSTEM_ODBC_HEADERS),)
42 define gb_LinkTarget__use_odbc_headers
43 $(call gb_LinkTarget_add_defs,$(1),\
44 -DSYSTEM_ODBC_HEADERS \
47 endef
49 else # !SYSTEM_ODBC_HEADERS
51 define gb_LinkTarget__use_odbc_headers
52 $(call gb_LinkTarget_set_include,$(1),\
53 -I$(SRCDIR)/external/unixODBC/inc \
54 $$(INCLUDE) \
57 endef
59 endif # SYSTEM_ODBC_HEADERS
61 ifneq ($(SYSTEM_MDDS),)
63 gb_ExternalProject__use_mdds_headers :=
65 define gb_LinkTarget__use_mdds_headers
66 $(call gb_LinkTarget_set_include,$(1),\
67 $(MDDS_CFLAGS) \
68 $$(INCLUDE) \
71 endef
73 else # !SYSTEM_MDDS
75 define gb_ExternalProject__use_mdds_headers
76 $(call gb_ExternalProject_use_unpacked,$(1),mdds)
78 endef
80 define gb_LinkTarget__use_mdds_headers
81 $(call gb_LinkTarget_use_unpacked,$(1),mdds)
82 $(call gb_LinkTarget_set_include,$(1),\
83 $(MDDS_CFLAGS) \
84 $$(INCLUDE) \
87 endef
89 endif # SYSTEM_MDDS
91 ifneq ($(SYSTEM_GLM),)
93 define gb_LinkTarget__use_glm_headers
94 $(call gb_LinkTarget_add_defs,$(1),\
95 -DGLM_FORCE_CTOR_INIT \
98 endef
100 gb_ExternalProject__use_glm_headers :=
102 else
104 define gb_LinkTarget__use_glm_headers
105 $(call gb_LinkTarget_add_defs,$(1),\
106 -DGLM_FORCE_CTOR_INIT \
108 $(call gb_LinkTarget_use_unpacked,$(1),glm)
109 $(call gb_LinkTarget_set_include,$(1),\
110 $(GLM_CFLAGS) \
111 $$(INCLUDE) \
114 endef
116 define gb_ExternalProject__use_glm_headers
117 $(call gb_ExternalProject_use_unpacked,$(1),glm)
119 endef
121 endif
123 ifneq ($(ENABLE_SKIA),)
124 define gb_LinkTarget__use_skia
125 $(call gb_LinkTarget_set_include,$(1),\
126 -I$(gb_UnpackedTarball_workdir)/skia/include/core \
127 -I$(gb_UnpackedTarball_workdir)/skia/include/effects \
128 -I$(gb_UnpackedTarball_workdir)/skia/include/gpu \
129 -I$(gb_UnpackedTarball_workdir)/skia/include/config \
130 -I$(gb_UnpackedTarball_workdir)/skia/include/ports \
131 -I$(gb_UnpackedTarball_workdir)/skia/include/private \
132 -I$(gb_UnpackedTarball_workdir)/skia/include/third_party/vulkan \
133 -I$(gb_UnpackedTarball_workdir)/skia/tools/gpu \
134 -I$(gb_UnpackedTarball_workdir)/skia \
135 -I$(SRCDIR)/external/skia/inc/ \
136 $$(INCLUDE) \
138 $(call gb_LinkTarget_use_libraries,$(1),skia)
139 $(call gb_LinkTarget_add_defs,$(1),\
140 -DSK_USER_CONFIG_HEADER="<$(BUILDDIR)/config_host/config_skia.h>" \
141 -DSKIA_DLL \
143 endef
144 $(eval $(call gb_Helper_register_libraries_for_install,OOOLIBS,ooo,\
145 skia \
147 endif
149 ifeq (SANE,$(filter SANE,$(BUILD_TYPE)))
151 define gb_LinkTarget__use_sane_headers
152 $(call gb_LinkTarget_set_include,$(1),\
153 $(if $(filter WNT,$(OS)), \
154 -I$(gb_UnpackedTarball_workdir)/twain_dsm/pub/include, \
155 -I$(SRCDIR)/external/sane/inc) \
156 $$(INCLUDE) \
159 ifeq ($(OS),WNT)
160 $(call gb_LinkTarget_use_unpacked,$(1),twain_dsm)
161 endif
163 endef
165 else
167 gb_LinkTarget__use_sane_headers :=
169 endif
171 ifneq ($(SYSTEM_BLUEZ),)
173 gb_LinkTarget__use_bluez_bluetooth_headers :=
175 else # !SYSTEM_BLUEZ
177 define gb_LinkTarget__use_bluez_bluetooth_headers
178 $(call gb_LinkTarget_set_include,$(1),\
179 -I$(SRCDIR)/external/bluez_bluetooth/inc \
180 $$(INCLUDE) \
183 endef
185 endif # SYSTEM_BLUEZ
187 # External libraries
189 ifneq ($(SYSTEM_CPPUNIT),)
191 define gb_LinkTarget__use_cppunit
192 $(call gb_LinkTarget_set_include,$(1),\
193 $$(INCLUDE) \
194 $(CPPUNIT_CFLAGS) \
197 $(call gb_LinkTarget_add_libs,$(1),\
198 $(CPPUNIT_LIBS) \
201 endef
203 else # !SYSTEM_CPPUNIT
205 define gb_LinkTarget__use_cppunit
206 $(call gb_LinkTarget_use_external_project,$(1),cppunit, full)
208 $(call gb_LinkTarget_set_include,$(1),\
209 -I$(gb_UnpackedTarball_workdir)/cppunit/include\
210 $$(INCLUDE) \
213 ifeq ($(COM),MSC)
214 $(call gb_LinkTarget_add_libs,$(1),\
215 $(gb_UnpackedTarball_workdir)/cppunit/src/cppunit/$(if $(MSVC_USE_DEBUG_RUNTIME),DebugDll/cppunitd_dll.lib,ReleaseDll/cppunit_dll.lib) \
217 else
218 $(call gb_LinkTarget_add_libs,$(1),\
219 -L$(gb_UnpackedTarball_workdir)/cppunit/src/cppunit/.libs -lcppunit \
221 endif
223 endef
225 endif # SYSTEM_CPPUNIT
228 ifeq ($(ENABLE_EPOXY),TRUE)
229 ifeq ($(SYSTEM_EPOXY),TRUE)
231 define gb_LinkTarget__use_epoxy
232 $(call gb_LinkTarget_set_include,$(1),\
233 $$(INCLUDE) \
234 $(EPOXY_CFLAGS) \
236 $(call gb_LinkTarget_add_libs,$(1),$(EPOXY_LIBS))
238 endef
240 gb_ExternalProject__use_epoxy :=
242 else # !SYSTEM_EPOXY
244 define gb_LinkTarget__use_epoxy
245 $(call gb_LinkTarget_set_include,$(1),\
246 -I$(gb_UnpackedTarball_workdir)/epoxy/include \
247 $$(INCLUDE) \
250 $(call gb_LinkTarget_use_libraries,$(1),\
251 epoxy \
254 endef
256 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
257 epoxy \
260 define gb_ExternalProject__use_epoxy
261 $(call gb_ExternalProject_use_external_project,$(1),epoxy)
263 endef
265 endif # !SYSTEM_EPOXY
266 else # !ENABLE_EPOXY
268 gb_LinkTarget__use_epoxy :=
269 gb_ExternalProject__use_epoxy :=
271 endif # !ENABLE_EPOXY
274 define gb_LinkTarget__use_iconv
275 ifeq ($(COM),MSC)
276 $(call gb_LinkTarget_add_libs,$(1),libiconv.lib)
277 else
278 $(call gb_LinkTarget_add_libs,$(1),-liconv)
279 endif
280 endef
282 ifneq ($(SYSTEM_MARIADB_CONNECTOR_C),)
284 define gb_LinkTarget__use_mariadb-connector-c
285 $(call gb_LinkTarget_set_include,$(1),\
286 $$(INCLUDE) \
287 $(MARIADB_CFLAGS) \
289 $(call gb_LinkTarget_add_libs,$(1),$(MARIADB_LIBS))
291 endef
292 gb_ExternalProject__use_mariadb-connector-c :=
294 else # !SYSTEM_MARIADB_CONNECTOR_C
296 define gb_LinkTarget__use_mariadb-connector-c
297 $(call gb_LinkTarget_set_include,$(1),\
298 $$(INCLUDE) \
299 $(MARIADB_CFLAGS) \
301 $(call gb_LinkTarget_use_static_libraries,$(1),\
302 mariadb-connector-c \
304 ifeq ($(OS),MACOSX)
305 $(call gb_LinkTarget_add_libs,$(1),\
306 -liconv \
308 endif
309 $(call gb_LinkTarget_use_system_win32_libs,$(1),\
310 ws2_32 \
311 advapi32 \
312 kernel32 \
313 shlwapi \
314 crypt32 \
315 bcrypt \
318 endef
319 define gb_ExternalProject__use_mariadb-connector-c
320 $(call gb_ExternalProject_use_static_libraries,$(1),mariadb-connector-c)
322 endef
324 endif # SYSTEM_MARIADB_CONNECTOR_C
327 ifneq ($(SYSTEM_MARIADB_CONNECTOR_C),)
329 define gb_LinkTarget__use_mysql
331 $(call gb_LinkTarget_add_defs,$(1),\
332 -DSYSTEM_MARIADB \
335 $(call gb_LinkTarget_add_libs,$(1),\
336 $(MARIADB_LIBS) \
339 $(call gb_LinkTarget_set_include,$(1),\
340 $(MARIADB_CFLAGS) \
341 $$(INCLUDE) \
343 endef
345 else
347 define gb_LinkTarget__use_mysql
349 $(call gb_LinkTarget_set_include,$(1),\
350 $$(INCLUDE) \
353 endef
355 endif
357 ifneq ($(SYSTEM_ZLIB),)
359 define gb_LinkTarget__use_zlib
360 $(call gb_LinkTarget_add_defs,$(1),\
361 -DSYSTEM_ZLIB \
362 -DZLIB_CONST \
364 $(call gb_LinkTarget_add_libs,$(1),-lz)
366 endef
368 # nothing on system
369 define gb_LinkTarget__use_zlib_x64
371 endef
373 gb_ExternalProject__use_zlib :=
375 else # !SYSTEM_ZLIB
377 define gb_LinkTarget__use_zlib_multiarch
378 $(if $(2),,$(call gb_Output_error,gb_LinkTarget__use_zlib_multiarch needs two arguments))
380 $(call gb_LinkTarget_add_defs,$(1), \
381 -DZLIB_CONST \
384 $(call gb_LinkTarget_set_include,$(1),\
385 $(ZLIB_CFLAGS) \
386 $$(INCLUDE) \
389 $(call gb_LinkTarget_use_static_libraries,$(1),\
390 $(2) \
393 endef
395 define gb_LinkTarget__use_zlib
396 $(call gb_LinkTarget__use_zlib_multiarch,$(1),zlib)
398 endef
400 define gb_LinkTarget__use_zlib_x64
401 $(call gb_LinkTarget__use_zlib_multiarch,$(1),zlib_x64)
403 endef
405 define gb_ExternalProject__use_zlib
406 $(call gb_ExternalProject_use_static_libraries,$(1),zlib)
408 endef
410 endif # SYSTEM_ZLIB
413 ifneq ($(SYSTEM_LIBJPEG),)
415 define gb_LinkTarget__use_libjpeg
416 $(call gb_LinkTarget_set_include,$(1),\
417 $$(INCLUDE) \
418 $(LIBJPEG_CFLAGS) \
420 $(call gb_LinkTarget_add_libs,$(1),$(LIBJPEG_LIBS))
421 $(call gb_LinkTarget_set_ldflags,$(1),\
422 $$(filter-out -L/usr/lib/jvm%,$$(T_LDFLAGS)) \
425 endef
427 gb_ExternalProject__use_libjpeg :=
429 else
431 define gb_LinkTarget__use_libjpeg
432 $(call gb_LinkTarget_set_include,$(1),\
433 -I$(gb_UnpackedTarball_workdir)/libjpeg-turbo \
434 $$(INCLUDE) \
436 $(call gb_LinkTarget_use_static_libraries,$(1),libjpeg-turbo)
438 endef
440 define gb_ExternalProject__use_libjpeg
441 $(call gb_ExternalProject_use_static_libraries,$(1),libjpeg-turbo)
443 endef
445 endif # SYSTEM_LIBJPEG
447 ifneq ($(SYSTEM_MYTHES),)
449 define gb_LinkTarget__use_mythes
450 $(call gb_LinkTarget_set_include,$(1),\
451 $$(INCLUDE) \
452 $(MYTHES_CFLAGS) \
454 $(call gb_LinkTarget_add_libs,$(1),$(MYTHES_LIBS))
456 endef
458 else # !SYSTEM_MYTHES
460 define gb_LinkTarget__use_mythes
461 $(call gb_LinkTarget_set_include,$(1),\
462 -I$(gb_UnpackedTarball_workdir)/mythes \
463 $$(INCLUDE) \
466 ifeq ($(COM),MSC)
467 $(call gb_LinkTarget_use_static_libraries,$(1),\
468 mythes \
470 else
471 $(call gb_LinkTarget_add_libs,$(1),$(MYTHES_LIBS))
472 $(call gb_LinkTarget_use_external_project,$(1),mythes)
473 endif
475 endef
477 endif # SYSTEM_MYTHES
480 ifneq ($(SYSTEM_EXPAT),)
482 define gb_LinkTarget__use_expat_impl
483 $(if $(2),,$(error gb_LinkTarget__use_expat_impl needs additional parameter))
485 $(call gb_LinkTarget_add_defs,$(1),\
486 -DSYSTEM_EXPAT \
489 $(call gb_LinkTarget_add_libs,$(1),-lexpat)
491 endef
493 gb_ExternalProject__use_expat :=
495 else # !SYSTEM_EXPAT
497 define gb_LinkTarget__use_expat_impl
498 $(if $(2),,$(error gb_LinkTarget__use_expat_impl needs additional parameter))
500 $(call gb_LinkTarget_set_include,$(1),\
501 -I$(gb_UnpackedTarball_workdir)/expat/lib \
502 $$(INCLUDE) \
505 $(call gb_LinkTarget_use_static_libraries,$(1),\
506 $(2) \
509 endef
511 define gb_ExternalProject__use_expat
512 $(call gb_ExternalProject_use_static_libraries,$(1),expat)
514 endef
516 endif # SYSTEM_EXPAT
518 define gb_LinkTarget__use_expat
519 $(call gb_LinkTarget__use_expat_impl,$(1),expat)
521 endef
523 define gb_LinkTarget__use_expat_x64
524 $(call gb_LinkTarget__use_expat_impl,$(1),expat_x64)
526 endef
528 ifneq ($(SYSTEM_HYPH),)
530 define gb_LinkTarget__use_hyphen
531 $(call gb_LinkTarget_add_libs,$(1),$(HYPHEN_LIB))
533 endef
535 else # !SYSTEM_HYPH
537 define gb_LinkTarget__use_hyphen
538 $(call gb_LinkTarget_use_unpacked,$(1),hyphen)
539 $(call gb_LinkTarget_set_include,$(1),\
540 -I$(gb_UnpackedTarball_workdir)/hyphen\
541 $$(INCLUDE) \
544 ifeq ($(COM),MSC)
545 $(call gb_LinkTarget_use_static_libraries,$(1),\
546 hyphen \
548 else
549 $(call gb_LinkTarget_add_libs,$(1),$(HYPHEN_LIB))
550 $(call gb_LinkTarget_use_external_project,$(1),hyphen)
551 endif
553 endef
555 endif # SYSTEM_HYPH
557 ifneq ($(SYSTEM_HUNSPELL),)
559 define gb_LinkTarget__use_hunspell
560 $(call gb_LinkTarget_set_include,$(1),\
561 $$(INCLUDE) \
562 $(HUNSPELL_CFLAGS) \
564 $(call gb_LinkTarget_add_libs,$(1),$(HUNSPELL_LIBS))
566 endef
568 gb_ExternalProject__use_hunspell :=
570 else # !SYSTEM_HUNSPELL
571 ifneq ($(ENABLE_WASM_STRIP_HUNSPELL),TRUE)
573 define gb_LinkTarget__use_hunspell
574 $(call gb_LinkTarget_add_defs,$(1),\
575 -DHUNSPELL_STATIC \
577 $(call gb_LinkTarget_use_unpacked,$(1),hunspell)
578 $(call gb_LinkTarget_set_include,$(1),\
579 -I$(gb_UnpackedTarball_workdir)/hunspell/src/hunspell\
580 $$(INCLUDE) \
583 ifeq ($(COM),MSC)
584 $(call gb_LinkTarget_use_static_libraries,$(1),\
585 hunspell \
587 else
588 $(call gb_LinkTarget_add_libs,$(1),$(HUNSPELL_LIBS))
589 $(call gb_LinkTarget_use_external_project,$(1),hunspell)
590 endif
592 endef
594 define gb_ExternalProject__use_hunspell
595 $(call gb_ExternalProject_use_external_project,$(1),hunspell)
597 endef
599 endif # ENABLE_WASM_STRIP_HUNSPELL
600 endif # SYSTEM_HUNSPELL
603 ifneq ($(SYSTEM_BOOST),)
605 define gb_LinkTarget__use_boost_lib
606 $(call gb_LinkTarget_set_include,$(1),\
607 $$(INCLUDE) \
608 $(BOOST_CPPFLAGS) \
611 $(call gb_LinkTarget_add_ldflags,$(1),\
612 $(BOOST_LDFLAGS) \
615 $(call gb_LinkTarget_add_libs,$(1),$(2))
617 endef
619 define gb_LinkTarget__use_boost_locale
620 $(call gb_LinkTarget__use_boost_lib,$(1),$(BOOST_LOCALE_LIB))
622 endef
624 define gb_LinkTarget__use_boost_date_time
625 $(call gb_LinkTarget__use_boost_lib,$(1),$(BOOST_DATE_TIME_LIB))
627 endef
629 define gb_LinkTarget__use_boost_filesystem
630 $(call gb_LinkTarget__use_boost_lib,$(1),$(BOOST_FILESYSTEM_LIB))
632 endef
634 gb_ExternalProject__use_boost_filesystem :=
636 define gb_LinkTarget__use_boost_iostreams
637 $(call gb_LinkTarget__use_boost_lib,$(1),$(BOOST_IOSTREAMS_LIB))
639 endef
641 gb_ExternalProject__use_boost_iostreams :=
643 define gb_LinkTarget__use_boost_system
644 $(call gb_LinkTarget__use_boost_lib,$(1),$(BOOST_SYSTEM_LIB))
646 endef
648 gb_ExternalProject__use_boost_system :=
650 define gb_LinkTarget__use_boost_headers
651 $(call gb_LinkTarget_set_include,$(1),\
652 $$(INCLUDE) \
653 $(BOOST_CPPFLAGS) \
656 endef
658 gb_ExternalProject__use_boost_headers:=
660 else # !SYSTEM_BOOST
662 define gb_LinkTarget__use_boost_lib
663 $(call gb_LinkTarget_add_defs,$(1),\
664 -DBOOST_ALL_NO_LIB \
667 $(call gb_LinkTarget_use_static_libraries,$(1),$(2))
669 endef
671 define gb_LinkTarget__use_boost_locale
672 $(call gb_LinkTarget__use_boost_lib,$(1),boost_locale)
673 $(call gb_LinkTarget_add_libs,$(1),\
674 $(if $(filter $(OS),MACOSX),-liconv) \
677 endef
679 define gb_LinkTarget__use_boost_date_time
680 $(call gb_LinkTarget__use_boost_lib,$(1),boost_date_time)
682 endef
684 define gb_LinkTarget__use_boost_filesystem
685 $(call gb_LinkTarget__use_boost_lib,$(1),boost_filesystem)
687 endef
689 define gb_ExternalProject__use_boost_filesystem
690 $(call gb_ExternalProject_use_static_libraries,$(1),boost_filesystem)
691 endef
693 define gb_LinkTarget__use_boost_iostreams
694 $(call gb_LinkTarget__use_boost_lib,$(1),boost_iostreams)
696 endef
698 define gb_ExternalProject__use_boost_iostreams
699 $(call gb_ExternalProject_use_static_libraries,$(1),boost_iostreams)
700 endef
702 define gb_LinkTarget__use_boost_system
703 $(call gb_LinkTarget__use_boost_lib,$(1),boost_system)
705 endef
707 define gb_ExternalProject__use_boost_system
708 $(call gb_ExternalProject_use_static_libraries,$(1),boost_system)
709 endef
711 define gb_LinkTarget__use_boost_headers
712 $(call gb_LinkTarget_use_unpacked,$(1),boost)
713 $(call gb_LinkTarget_set_include,$(1),\
714 $(BOOST_CPPFLAGS) \
715 $$(INCLUDE) \
718 endef
720 define gb_ExternalProject__use_boost_headers
721 $(call gb_ExternalProject_use_unpacked,$(1),boost)
723 endef
725 endif # SYSTEM_BOOST
728 ifneq ($(SYSTEM_LIBCMIS),)
730 define gb_LinkTarget__use_libcmis
731 $(call gb_LinkTarget_set_include,$(1),\
732 $$(INCLUDE) \
733 $(LIBCMIS_CFLAGS) \
735 $(call gb_LinkTarget_add_libs,$(1),$(LIBCMIS_LIBS))
737 endef
739 else # !SYSTEM_LIBCMIS
741 define gb_LinkTarget__use_libcmis
742 $(call gb_LinkTarget_set_include,$(1),\
743 -I$(gb_UnpackedTarball_workdir)/libcmis/inc \
744 $$(INCLUDE) \
746 $(call gb_LinkTarget_use_static_libraries,$(1),\
747 libcmis \
750 endef
752 endif # SYSTEM_LIBCMIS
754 ifeq ($(ENABLE_JAVA),TRUE)
756 define gb_LinkTarget__use_jawt
757 $(call gb_LinkTarget_add_libs,$(1),\
758 $(JAWTLIB) \
761 endef
763 else # !ENABLE_JAVA
765 gb_LinkTarget__use_jawt :=
767 endif # ENABLE_JAVA
769 ifneq ($(SYSTEM_LIBATOMIC_OPS),)
771 define gb_LinkTarget__use_libatomic_ops
772 $(call gb_LinkTarget_set_include,$(1),\
773 $$(INCLUDE) \
774 $(LIBATOMIC_OPS_CFLAGS) \
776 $(call gb_LinkTarget_add_libs,$(1), $(LIBATOMIC_OPS_LIBS))
778 endef
779 gb_ExternalProject__use_libatomic_ops :=
781 else # !SYSTEM_LIBATOMIC_OPS
783 define gb_LinkTarget__use_libatomic_ops
784 $(call gb_LinkTarget_set_include,$(1),\
785 $(LIBATOMIC_OPS_CFLAGS) \
786 $$(INCLUDE) \
787 $(LIBATOMIC_OPS_CFLAGS) \
789 $(call gb_LinkTarget_use_external_project,$(1),\
790 libatomic_ops \
793 $(call gb_LinkTarget_add_libs,$(1),\
794 -L$(gb_UnpackedTarball_workdir)/libatomic_ops/src/lib -latomic_ops \
797 endef
799 define gb_ExternalProject__use_libatomic_ops
800 $(call gb_ExternalProject_use_external_project,$(1),libatomic_ops)
802 endef
804 endif # SYSTEM_LIBATOMIC_OPS
807 ifneq ($(SYSTEM_LIBEXTTEXTCAT),)
809 define gb_LinkTarget__use_libexttextcat
810 $(call gb_LinkTarget_set_include,$(1),\
811 $$(INCLUDE) \
812 $(LIBEXTTEXTCAT_CFLAGS) \
814 $(call gb_LinkTarget_add_defs,$(1),\
815 -DSYSTEM_LIBEXTTEXTCAT \
817 $(call gb_LinkTarget_add_libs,$(1),$(LIBEXTTEXTCAT_LIBS))
819 endef
821 else # !SYSTEM_LIBEXTTEXTCAT
823 define gb_LinkTarget__use_libexttextcat
824 $(call gb_LinkTarget_set_include,$(1),\
825 -I$(gb_UnpackedTarball_workdir)/libexttextcat/src \
826 $$(INCLUDE) \
829 ifeq ($(COM),MSC)
830 $(call gb_LinkTarget_use_static_libraries,$(1),\
831 libexttextcat \
833 else
834 $(call gb_LinkTarget_add_libs,$(1),\
835 $(gb_UnpackedTarball_workdir)/libexttextcat/src/.libs/libexttextcat-2.0.a\
837 $(call gb_LinkTarget_use_external_project,$(1),libexttextcat)
838 endif
841 endef
843 endif # SYSTEM_LIBEXTTEXTCAT
846 ifneq ($(SYSTEM_LIBNUMBERTEXT),)
848 define gb_LinkTarget__use_libnumbertext
849 $(call gb_LinkTarget_set_include,$(1),\
850 $$(INCLUDE) \
851 $(LIBNUMBERTEXT_CFLAGS) \
853 $(call gb_LinkTarget_add_defs,$(1),\
854 -DSYSTEM_LIBNUMBERTEXT \
856 $(call gb_LinkTarget_add_libs,$(1),$(LIBNUMBERTEXT_LIBS))
858 endef
860 else # !SYSTEM_LIBNUMBERTEXT
862 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
863 libnumbertext_numbertext \
866 define gb_LinkTarget__use_libnumbertext
867 $(call gb_LinkTarget_use_package,$(1),libnumbertext_numbertext)
868 $(call gb_LinkTarget_set_include,$(1),\
869 -I$(gb_UnpackedTarball_workdir)/libnumbertext/src \
870 $$(INCLUDE) \
873 ifeq ($(COM),MSC)
874 $(call gb_LinkTarget_use_static_libraries,$(1),\
875 libnumbertext \
877 else
879 $(call gb_LinkTarget_add_libs,$(1),\
880 $(gb_UnpackedTarball_workdir)/libnumbertext/src/.libs/libnumbertext-1.0.a\
882 $(call gb_LinkTarget_use_external_project,$(1),libnumbertext,full)
884 endif
886 endef
888 endif # SYSTEM_LIBNUMBERTEXT
891 ifneq ($(SYSTEM_LIBXML),)
893 define gb_LinkTarget__use_libxml2
894 $(call gb_LinkTarget_add_defs,$(1),\
895 -DSYSTEM_LIBXML \
897 $(call gb_LinkTarget_set_include,$(1),\
898 $$(INCLUDE) \
899 $(LIBXML_CFLAGS) \
901 $(call gb_LinkTarget_add_libs,$(1),$(LIBXML_LIBS))
903 endef
904 gb_ExternalProject__use_libxml2:=
906 else # !SYSTEM_LIBXML
908 $(eval $(call gb_Helper_register_packages_for_install,ure,\
909 libxml2 \
912 define gb_LinkTarget__use_libxml2
913 $(call gb_LinkTarget_use_package,$(1),libxml2)
914 $(call gb_LinkTarget_set_include,$(1),\
915 $$(INCLUDE) \
916 $(LIBXML_CFLAGS) \
919 $(call gb_LinkTarget_add_libs,$(1),\
920 $(LIBXML_LIBS) \
923 ifeq ($(COM),MSC)
924 $(call gb_LinkTarget_use_external,$(1),icu_headers)
925 endif
927 endef
928 define gb_ExternalProject__use_libxml2
929 $(call gb_ExternalProject_use_package,$(1),libxml2)
931 ifeq ($(COM),MSC)
932 $(call gb_ExternalProject_use_packages,$(1),icu icu_ure)
933 endif
935 endef
937 endif # SYSTEM_LIBXML
940 ifneq ($(SYSTEM_LIBXSLT),)
942 define gb_LinkTarget__use_libxslt
943 $(call gb_LinkTarget_set_include,$(1),\
944 $$(INCLUDE) \
945 $(LIBXSLT_CFLAGS) \
947 $(call gb_LinkTarget_add_libs,$(1),$(LIBXSLT_LIBS))
949 endef
951 define gb_LinkTarget__use_libexslt
952 $(call gb_LinkTarget_set_include,$(1),\
953 $$(INCLUDE) \
954 $(LIBEXSLT_CFLAGS) \
957 $(call gb_LinkTarget_add_libs,$(1),$(LIBEXSLT_LIBS))
959 endef
961 else # !SYSTEM_LIBXSLT
963 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
964 libxslt \
967 define gb_LinkTarget__use_libxslt
968 $(call gb_LinkTarget_use_package,$(1),libxslt)
969 $(call gb_LinkTarget_set_include,$(1),\
970 $$(INCLUDE) \
971 -I$(gb_UnpackedTarball_workdir)/libxslt \
974 ifeq ($(COM),MSC)
975 $(call gb_LinkTarget_add_libs,$(1),\
976 $(gb_UnpackedTarball_workdir)/libxslt/win32/bin.msvc/libxslt.lib \
978 else
979 $(call gb_LinkTarget_add_libs,$(1),\
980 -L$(gb_UnpackedTarball_workdir)/libxslt/libxslt/.libs -lxslt \
982 endif
984 endef
986 define gb_LinkTarget__use_libexslt
987 $(call gb_LinkTarget_use_package,$(1),libxslt)
988 $(call gb_LinkTarget_set_include,$(1),\
989 $$(INCLUDE) \
990 -I$(gb_UnpackedTarball_workdir)/libxslt \
993 ifeq ($(COM),MSC)
994 $(call gb_LinkTarget_add_libs,$(1),\
995 $(gb_UnpackedTarball_workdir)/libxslt/win32/bin.msvc/libexslt.lib \
997 else
998 $(call gb_LinkTarget_add_libs,$(1),\
999 -L$(gb_UnpackedTarball_workdir)/libxslt/libexslt/.libs -lexslt \
1001 endif
1003 endef
1005 endif # SYSTEM_LIBXSLT
1008 ifneq ($(SYSTEM_XMLSEC),)
1010 define gb_LinkTarget__use_xmlsec
1011 $(call gb_LinkTarget_add_defs,$(1),\
1012 -DSYSTEM_XMLSEC \
1014 $(call gb_LinkTarget_set_include,$(1),\
1015 $$(INCLUDE) \
1016 $(XMLSEC_CFLAGS) \
1018 $(call gb_LinkTarget_add_libs,$(1),$(XMLSEC_LIBS))
1020 endef
1022 gb_ExternalProject__use_xmlsec:=
1024 else # !SYSTEM_XMLSEC
1026 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
1027 xmlsec \
1030 define gb_LinkTarget__use_xmlsec
1032 endef
1034 endif # SYSTEM_XMLSEC
1036 ifneq ($(SYSTEM_LIBLANGTAG),)
1038 define gb_LinkTarget__use_liblangtag
1039 $(call gb_LinkTarget_set_include,$(1),\
1040 $$(INCLUDE) \
1041 $(LIBLANGTAG_CFLAGS) \
1044 $(call gb_LinkTarget_add_libs,$(1),$(LIBLANGTAG_LIBS))
1046 endef
1048 gb_ExternalProject__use_liblangtag :=
1050 else # !SYSTEM_LIBLANGTAG
1052 $(eval $(call gb_Helper_register_packages_for_install,ure,\
1053 liblangtag_data \
1056 ifeq ($(COM),MSC)
1058 define gb_LinkTarget__use_liblangtag
1059 $(call gb_LinkTarget_set_include,$(1),\
1060 $(LIBLANGTAG_CFLAGS) \
1061 $$(INCLUDE) \
1063 $(call gb_LinkTarget_add_libs,$(1),$(LIBLANGTAG_LIBS))
1064 $(call gb_LinkTarget_use_external_project,$(1),liblangtag)
1066 endef
1068 else
1070 $(eval $(call gb_Helper_register_packages_for_install,ure,\
1071 liblangtag \
1074 define gb_LinkTarget__use_liblangtag
1075 $(call gb_LinkTarget_set_include,$(1),\
1076 $(LIBLANGTAG_CFLAGS) \
1077 $$(INCLUDE) \
1079 $(call gb_LinkTarget_add_libs,$(1),$(LIBLANGTAG_LIBS))
1080 $(call gb_LinkTarget_use_package,$(1),liblangtag)
1082 endef
1084 endif # MSC
1086 define gb_ExternalProject__use_liblangtag
1087 $(call gb_ExternalProject_use_external_project,$(1),liblangtag)
1089 endef
1091 endif # SYSTEM_LIBLANGTAG
1094 ifneq ($(SYSTEM_REDLAND),)
1096 define gb_LinkTarget__use_librdf
1097 $(call gb_LinkTarget_add_defs,$(1),\
1098 -DSYSTEM_REDLAND \
1100 $(call gb_LinkTarget_set_include,$(1),\
1101 $$(INCLUDE) \
1102 $(REDLAND_CFLAGS) \
1104 $(call gb_LinkTarget_add_libs,$(1),$(REDLAND_LIBS))
1106 endef
1108 gb_LinkTarget__use_redland_headers:=
1110 gb_LinkTarget__use_raptor_headers:=
1112 gb_LinkTarget__use_rasqal_headers:=
1114 else # !SYSTEM_REDLAND
1116 define gb_LinkTarget__use_redland_headers
1117 $(call gb_LinkTarget_set_include,$(1),\
1118 -I$(gb_UnpackedTarball_workdir)/redland/src \
1119 $$(INCLUDE) \
1122 endef
1124 define gb_LinkTarget__use_raptor_headers
1125 $(call gb_LinkTarget_set_include,$(1),\
1126 -I$(gb_UnpackedTarball_workdir)/raptor/src \
1127 $$(INCLUDE) \
1130 endef
1132 define gb_LinkTarget__use_rasqal_headers
1133 $(call gb_LinkTarget_set_include,$(1),\
1134 -I$(gb_UnpackedTarball_workdir)/rasqal/src \
1135 $$(INCLUDE) \
1138 endef
1140 ifneq ($(OS),ANDROID)
1142 ifeq ($(COM),MSC)
1143 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo, \
1144 raptor2 \
1145 rasqal \
1146 rdf \
1148 else
1149 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1150 raptor \
1151 rasqal \
1152 redland \
1154 endif
1156 define gb_LinkTarget__use_librdf
1157 ifeq ($(COM),MSC)
1158 $(call gb_LinkTarget_use_libraries,$(1),\
1159 raptor2 \
1160 rdf \
1162 else
1163 $(call gb_LinkTarget_use_packages,$(1),redland raptor rasqal)
1165 $(call gb_LinkTarget_add_libs,$(1),\
1166 -L$(gb_UnpackedTarball_workdir)/redland/src/.libs -lrdf \
1167 -L$(gb_UnpackedTarball_workdir)/raptor/src/.libs -lraptor2 \
1168 -L$(gb_UnpackedTarball_workdir)/rasqal/src/.libs -lrasqal \
1170 endif
1172 endef
1174 else # ANDROID
1176 define gb_LinkTarget__use_librdf
1177 $(call gb_LinkTarget_use_packages,$(1),redland raptor rasqal)
1179 endef
1181 endif # ANDROID
1183 endif # SYSTEM_REDLAND
1185 ifneq ($(SYSTEM_CAIRO),)
1187 define gb_LinkTarget__use_cairo
1188 $(call gb_LinkTarget_set_include,$(1),\
1189 $$(INCLUDE) \
1190 $(CAIRO_CFLAGS) \
1191 -DSYSTEM_CAIRO \
1193 $(call gb_LinkTarget_use_external,$(1),freetype_headers)
1194 $(call gb_LinkTarget_add_libs,$(1),$(CAIRO_LIBS))
1196 endef
1198 else # !SYSTEM_CAIRO
1200 ifneq ($(filter-out MACOSX WNT,$(OS)),)
1202 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
1203 cairo \
1204 pixman \
1207 define gb_LinkTarget__use_cairo
1208 $(call gb_LinkTarget_use_package,$(1),cairo)
1209 $(call gb_LinkTarget_use_package,$(1),pixman)
1210 $(call gb_LinkTarget_use_external,$(1),freetype_headers)
1211 $(call gb_LinkTarget_set_include,$(1),\
1212 -I$(gb_UnpackedTarball_workdir)/cairo \
1213 -I$(gb_UnpackedTarball_workdir)/cairo/src \
1214 -I$(gb_UnpackedTarball_workdir)/pixman/pixman \
1215 $$(INCLUDE) \
1217 $(call gb_LinkTarget_add_libs,$(1),\
1218 $(if $(filter EMSCRIPTEN,$(OS)), \
1219 $(gb_UnpackedTarball_workdir)/cairo/src/.libs/libcairo.a \
1220 $(gb_UnpackedTarball_workdir)/pixman/pixman/.libs/libpixman-1.a, \
1221 -L$(gb_UnpackedTarball_workdir)/cairo/src/.libs -lcairo \
1222 -L$(gb_UnpackedTarball_workdir)/pixman/pixman/.libs -lpixman-1) \
1225 endef
1227 endif # !MACOSX, !WNT
1229 endif # !SYSTEM_CAIRO
1231 ifneq ($(SYSTEM_FREETYPE),)
1233 define gb_LinkTarget__use_freetype_headers
1234 $(call gb_LinkTarget_set_include,$(1),\
1235 $$(INCLUDE) \
1236 $(FREETYPE_CFLAGS) \
1239 endef
1241 gb_ExternalProject__use_freetype :=
1243 else
1245 define gb_LinkTarget__use_freetype_headers
1246 $(call gb_LinkTarget_use_external_project,$(1),freetype)
1247 $(call gb_LinkTarget_set_include,$(1),\
1248 $(FREETYPE_CFLAGS) \
1249 $$(INCLUDE) \
1252 endef
1254 define gb_ExternalProject__use_freetype
1255 $(call gb_ExternalProject_use_external_project,$(1),freetype)
1257 endef
1259 endif # SYSTEM_FREETYPE
1261 define gb_LinkTarget__use_freetype
1262 $(call gb_LinkTarget_use_external,$(1),freetype_headers)
1263 $(call gb_LinkTarget_add_libs,$(1),$(FREETYPE_LIBS))
1265 endef
1267 ifneq ($(SYSTEM_FONTCONFIG),)
1269 define gb_LinkTarget__use_fontconfig
1270 $(call gb_LinkTarget_set_include,$(1),\
1271 $$(INCLUDE) \
1272 $(FONTCONFIG_CFLAGS) \
1275 $(call gb_LinkTarget_add_libs,$(1),$(FONTCONFIG_LIBS))
1277 endef
1279 ifeq ($(OS),EMSCRIPTEN)
1280 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
1281 libfontconfig_data \
1283 endif
1285 gb_ExternalProject__use_fontconfig :=
1287 else # SYSTEM_FONTCONFIG
1289 ifneq ($(filter-out MACOSX WNT,$(OS)),)
1291 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
1292 fontconfig \
1295 endif
1297 define gb_LinkTarget__use_fontconfig
1298 ifeq ($(OS),LINUX)
1299 $(call gb_LinkTarget_use_package,$(1),fontconfig)
1300 else
1301 $(call gb_LinkTarget_use_external_project,$(1),fontconfig)
1302 endif
1303 $(call gb_LinkTarget_set_include,$(1),\
1304 -I$(gb_UnpackedTarball_workdir)/fontconfig \
1305 $$(INCLUDE) \
1308 $(call gb_LinkTarget_add_libs,$(1),\
1309 -L$(gb_UnpackedTarball_workdir)/fontconfig/src/.libs -lfontconfig \
1312 endef
1314 define gb_ExternalProject__use_fontconfig
1315 $(call gb_ExternalProject_use_external_project,$(1),fontconfig)
1317 endef
1319 endif # SYSTEM_FONTCONFIG
1321 ifneq ($(SYSTEM_GRAPHITE),)
1323 define gb_LinkTarget__use_graphite
1324 $(call gb_LinkTarget_set_include,$(1),\
1325 $$(INCLUDE) \
1326 $(GRAPHITE_CFLAGS) \
1328 $(call gb_LinkTarget_add_libs,$(1),$(GRAPHITE_LIBS))
1330 endef
1332 gb_ExternalProject__use_graphite:=
1334 else # !SYSTEM_GRAPHITE
1336 define gb_LinkTarget__use_graphite
1337 $(call gb_LinkTarget_use_unpacked,$(1),graphite)
1338 $(call gb_LinkTarget_set_include,$(1),\
1339 -I$(gb_UnpackedTarball_workdir)/graphite/include \
1340 $$(INCLUDE) \
1342 $(call gb_LinkTarget_use_static_libraries,$(1),\
1343 graphite \
1346 endef
1348 define gb_ExternalProject__use_graphite
1349 $(call gb_ExternalProject_use_static_libraries,$(1),\
1350 graphite \
1353 endef
1354 endif # SYSTEM_GRAPHITE
1356 ifneq ($(SYSTEM_ICU),)
1358 gb_LinkTarget__use_icu_headers:=
1359 gb_ExternalProject__use_icu:=
1361 define gb_LinkTarget__use_icudata
1362 $(call gb_LinkTarget_add_libs,$(1),-licudata)
1364 endef
1365 define gb_LinkTarget__use_icui18n
1366 $(call gb_LinkTarget_add_libs,$(1),-licui18n)
1368 endef
1369 define gb_LinkTarget__use_icuuc
1370 $(call gb_LinkTarget_add_libs,$(1),-licuuc)
1372 endef
1374 else # !SYSTEM_ICU
1376 $(eval $(call gb_Helper_register_packages_for_install,ure, \
1377 icu_ure \
1380 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1381 icu \
1384 ifeq ($(OS)$(DISABLE_DYNLOADING),ANDROID)
1385 gb_ICU_suffix:=lo
1386 else
1387 gb_ICU_suffix:=
1388 endif
1390 define gb_LinkTarget__use_icu_headers
1391 $(call gb_LinkTarget_use_unpacked,$(1),icu)
1392 $(call gb_LinkTarget_set_include,$(1),\
1393 -I$(gb_UnpackedTarball_workdir)/icu/source \
1394 -I$(gb_UnpackedTarball_workdir)/icu/source/i18n \
1395 -I$(gb_UnpackedTarball_workdir)/icu/source/common \
1396 $$(INCLUDE) \
1399 endef
1401 define gb_ExternalProject__use_icu
1402 $(call gb_ExternalProject_use_package,$(1),icu)
1404 endef
1406 # icudata and icui18n is called icudt and icuin when built with MSVC :-/
1407 define gb_LinkTarget__use_icudata
1408 $(call gb_LinkTarget_use_package,$(1),icu_ure)
1410 ifeq ($(OS),WNT)
1411 $(call gb_LinkTarget_add_libs,$(1),\
1412 $(gb_UnpackedTarball_workdir)/icu/source/lib/icudt$(if $(MSVC_USE_DEBUG_RUNTIME),d).lib \
1414 else
1415 $(call gb_LinkTarget_add_libs,$(1),\
1416 -L$(gb_UnpackedTarball_workdir)/icu/source/lib -licudata$(gb_ICU_suffix) \
1418 endif
1420 endef
1422 define gb_LinkTarget__use_icui18n
1423 $(call gb_LinkTarget_use_package,$(1),icu)
1425 ifeq ($(OS),WNT)
1426 $(call gb_LinkTarget_add_libs,$(1),\
1427 $(gb_UnpackedTarball_workdir)/icu/source/lib/icuin$(if $(MSVC_USE_DEBUG_RUNTIME),d).lib \
1429 else
1430 $(call gb_LinkTarget_add_libs,$(1),\
1431 -L$(gb_UnpackedTarball_workdir)/icu/source/lib -licui18n$(gb_ICU_suffix) \
1433 endif
1435 endef
1437 define gb_LinkTarget__use_icuuc
1438 $(call gb_LinkTarget_use_package,$(1),icu_ure)
1440 ifeq ($(OS),WNT)
1441 $(call gb_LinkTarget_add_libs,$(1),\
1442 $(gb_UnpackedTarball_workdir)/icu/source/lib/icuuc$(if $(MSVC_USE_DEBUG_RUNTIME),d).lib \
1444 else
1445 $(call gb_LinkTarget_add_libs,$(1),\
1446 -L$(gb_UnpackedTarball_workdir)/icu/source/lib -licuuc$(gb_ICU_suffix) \
1448 endif
1450 endef
1452 endif # SYSTEM_ICU
1454 ifneq ($(SYSTEM_HARFBUZZ),)
1456 define gb_LinkTarget__use_harfbuzz
1457 $(call gb_LinkTarget_set_include,$(1),\
1458 $$(INCLUDE) \
1459 $(HARFBUZZ_CFLAGS) \
1461 $(call gb_LinkTarget_add_libs,$(1),$(HARFBUZZ_LIBS))
1463 endef
1465 gb_ExternalProject__use_harfbuzz :=
1467 else # SYSTEM_HARFBUZZ != TRUE
1469 define gb_LinkTarget__use_harfbuzz
1470 $(call gb_LinkTarget_set_include,$(1),\
1471 $(HARFBUZZ_CFLAGS) \
1472 $$(INCLUDE) \
1474 $(call gb_LinkTarget_add_libs,$(1),$(HARFBUZZ_LIBS))
1475 $(call gb_LinkTarget_use_external,$(1),icuuc)
1476 $(call gb_LinkTarget_use_external_project,$(1),harfbuzz)
1478 endef
1480 define gb_ExternalProject__use_harfbuzz
1481 $(call gb_ExternalProject_use_external_project,$(1),harfbuzz)
1483 endef
1485 endif # SYSTEM_HARFBUZZ
1487 ifneq ($(ENABLE_OPENSSL),TRUE)
1489 gb_ExternalProject__use_openssl:=
1490 gb_LinkTarget__use_openssl_headers:=
1491 gb_LinkTarget__use_openssl:=
1493 else # ENABLE_OPENSSL
1495 ifneq ($(SYSTEM_OPENSSL),)
1497 gb_LinkTarget__use_openssl_headers:=
1498 gb_ExternalProject__use_openssl:=
1500 define gb_LinkTarget__use_openssl
1501 $(call gb_LinkTarget_set_include,$(1),\
1502 $$(INCLUDE) \
1503 $(OPENSSL_CFLAGS) \
1505 $(call gb_LinkTarget_add_libs,$(1),$(OPENSSL_LIBS))
1507 endef
1509 else # !SYSTEM_OPENSSL
1511 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1512 openssl \
1515 define gb_ExternalProject__use_openssl
1516 $(call gb_ExternalProject_use_package,$(1),openssl)
1518 endef
1520 define gb_LinkTarget__use_openssl_headers
1521 $(call gb_LinkTarget_use_external_project,$(1),openssl,full)
1522 $(call gb_LinkTarget_set_include,$(1),\
1523 -I$(gb_UnpackedTarball_workdir)/openssl/include \
1524 $$(INCLUDE) \
1527 endef
1529 define gb_LinkTarget__use_openssl
1530 $(call gb_LinkTarget_use_package,$(1),openssl)
1531 ifeq ($(OS),WNT)
1532 $(call gb_LinkTarget_add_libs,$(1),\
1533 $(gb_UnpackedTarball_workdir)/openssl/libcrypto.lib \
1534 $(gb_UnpackedTarball_workdir)/openssl/libssl.lib \
1536 else
1537 $(call gb_LinkTarget_add_libs,$(1),\
1538 $(gb_UnpackedTarball_workdir)/openssl/libssl.a \
1539 $(gb_UnpackedTarball_workdir)/openssl/libcrypto.a \
1540 $(if $(filter $(OS),LINUX),-pthread) \
1542 $(call gb_LinkTarget_use_external_project,$(1),openssl)
1543 ifeq ($(OS),SOLARIS)
1544 $(call gb_LinkTarget_add_libs,$(1),\
1545 -lnsl \
1546 -lsocket \
1548 endif
1549 endif
1551 endef
1553 endif # SYSTEM_OPENSSL
1554 endif # ENABLE_OPENSSL
1557 ifneq ($(SYSTEM_ARGON2),)
1559 define gb_LinkTarget__use_argon2
1560 $(call gb_LinkTarget_set_include,$(1),\
1561 $(ARGON2_CFLAGS) \
1562 $$(INCLUDE) \
1564 $(call gb_LinkTarget_add_libs,$(1),$(ARGON2_LIBS))
1566 endef
1568 else # !SYSTEM_ARGON2
1570 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1571 argon2 \
1574 define gb_LinkTarget__use_argon2
1575 $(call gb_LinkTarget_set_include,$(1),\
1576 $(ARGON2_CFLAGS) \
1577 $$(INCLUDE) \
1579 $(call gb_LinkTarget_add_libs,$(1),$(ARGON2_LIBS))
1580 $(call gb_LinkTarget_use_package,$(1),argon2)
1581 endef
1583 endif # SYSTEM_ARGON2
1586 ifneq ($(SYSTEM_CDR),)
1588 define gb_LinkTarget__use_cdr
1589 $(call gb_LinkTarget_set_include,$(1),\
1590 $$(INCLUDE) \
1591 $(CDR_CFLAGS) \
1593 $(call gb_LinkTarget_add_libs,$(1),$(CDR_LIBS))
1595 endef
1597 else # !SYSTEM_CDR
1599 define gb_LinkTarget__use_cdr
1600 $(call gb_LinkTarget_set_include,$(1),\
1601 -I$(gb_UnpackedTarball_workdir)/libcdr/inc \
1602 $$(INCLUDE) \
1604 $(call gb_LinkTarget_add_libs,$(1),\
1605 $(gb_UnpackedTarball_workdir)/libcdr/src/lib/.libs/libcdr-0.1$(gb_StaticLibrary_PLAINEXT) \
1607 $(call gb_LinkTarget_use_external_project,$(1),libcdr)
1608 endef
1610 endif # SYSTEM_CDR
1613 ifneq ($(SYSTEM_EBOOK),)
1615 define gb_LinkTarget__use_ebook
1616 $(call gb_LinkTarget_set_include,$(1),\
1617 $$(INCLUDE) \
1618 $(EBOOK_CFLAGS) \
1620 $(call gb_LinkTarget_add_libs,$(1),$(EBOOK_LIBS))
1622 endef
1624 gb_ExternalProject__use_ebook :=
1626 else # !SYSTEM_EBOOK
1628 define gb_LinkTarget__use_ebook
1629 $(call gb_LinkTarget_set_include,$(1),\
1630 -I${WORKDIR}/UnpackedTarball/libebook/inc \
1631 $$(INCLUDE) \
1633 $(call gb_LinkTarget_add_libs,$(1),\
1634 $(gb_UnpackedTarball_workdir)/libebook/src/lib/.libs/libe-book-0.1$(gb_StaticLibrary_PLAINEXT) \
1636 $(call gb_LinkTarget_use_external_project,$(1),libebook)
1638 endef
1640 define gb_ExternalProject__use_ebook
1641 $(call gb_ExternalProject_use_external_project,$(1),libebook)
1643 endef
1645 endif # SYSTEM_EBOOK
1648 ifneq ($(SYSTEM_ETONYEK),)
1650 define gb_LinkTarget__use_etonyek
1651 $(call gb_LinkTarget_set_include,$(1),\
1652 $$(INCLUDE) \
1653 $(ETONYEK_CFLAGS) \
1655 $(call gb_LinkTarget_add_libs,$(1),$(ETONYEK_LIBS))
1657 endef
1659 gb_ExternalProject__use_etonyek :=
1661 else # !SYSTEM_ETONYEK
1663 ifeq ($(COM),MSC)
1665 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
1666 etonyek \
1669 define gb_LinkTarget__use_etonyek
1670 $(call gb_LinkTarget_set_include,$(1),\
1671 -I$(gb_UnpackedTarball_workdir)/libetonyek/inc \
1672 $$(INCLUDE) \
1674 $(call gb_LinkTarget_use_libraries,$(1),\
1675 etonyek \
1678 endef
1680 else # !MSC
1682 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1683 libetonyek \
1686 define gb_LinkTarget__use_etonyek
1687 $(call gb_LinkTarget_use_package,$(1),libetonyek)
1689 $(call gb_LinkTarget_set_include,$(1),\
1690 -I${WORKDIR}/UnpackedTarball/libetonyek/inc \
1691 -DLIBETONYEK_VISIBILITY \
1692 $$(INCLUDE) \
1694 $(call gb_LinkTarget_add_libs,$(1),\
1695 -L$(gb_UnpackedTarball_workdir)/libetonyek/src/lib/.libs -letonyek-0.1 \
1697 $(call gb_LinkTarget_use_external_project,$(1),libetonyek)
1699 endef
1701 define gb_ExternalProject__use_etonyek
1702 $(call gb_ExternalProject_use_external_project,$(1),libetonyek)
1704 endef
1706 endif
1708 endif # SYSTEM_ETONYEK
1711 ifneq ($(SYSTEM_FREEHAND),)
1713 define gb_LinkTarget__use_freehand
1714 $(call gb_LinkTarget_set_include,$(1),\
1715 $$(INCLUDE) \
1716 $(FREEHAND_CFLAGS) \
1718 $(call gb_LinkTarget_add_libs,$(1),$(FREEHAND_LIBS))
1720 endef
1722 gb_ExternalProject__use_freehand :=
1724 else # !SYSTEM_FREEHAND
1726 define gb_LinkTarget__use_freehand
1727 $(call gb_LinkTarget_set_include,$(1),\
1728 -I${WORKDIR}/UnpackedTarball/libfreehand/inc \
1729 $$(INCLUDE) \
1731 $(call gb_LinkTarget_add_libs,$(1),\
1732 $(gb_UnpackedTarball_workdir)/libfreehand/src/lib/.libs/libfreehand-0.1$(gb_StaticLibrary_PLAINEXT) \
1734 $(call gb_LinkTarget_use_external_project,$(1),libfreehand)
1736 endef
1738 define gb_ExternalProject__use_freehand
1739 $(call gb_ExternalProject_use_external_project,$(1),libfreehand)
1741 endef
1743 endif # SYSTEM_FREEHAND
1746 ifneq ($(SYSTEM_ODFGEN),)
1748 define gb_LinkTarget__use_odfgen
1749 $(call gb_LinkTarget_set_include,$(1),\
1750 $$(INCLUDE) \
1751 $(ODFGEN_CFLAGS) \
1753 $(call gb_LinkTarget_add_libs,$(1),$(ODFGEN_LIBS))
1755 endef
1757 else # !SYSTEM_ODFGEN
1759 ifeq ($(COM),MSC)
1761 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
1762 odfgen \
1765 define gb_LinkTarget__use_odfgen
1766 $(call gb_LinkTarget_set_include,$(1),\
1767 -I$(gb_UnpackedTarball_workdir)/libodfgen/inc \
1768 $$(INCLUDE) \
1770 $(call gb_LinkTarget_use_libraries,$(1),\
1771 odfgen \
1774 endef
1776 else # !MSC
1778 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1779 libodfgen \
1782 define gb_LinkTarget__use_odfgen
1783 $(call gb_LinkTarget_use_package,$(1),libodfgen)
1785 $(call gb_LinkTarget_set_include,$(1),\
1786 -I$(gb_UnpackedTarball_workdir)/libodfgen/inc \
1787 -DLIBODFGEN_VISIBILITY \
1788 $$(INCLUDE) \
1790 $(call gb_LinkTarget_add_libs,$(1),\
1791 -L$(gb_UnpackedTarball_workdir)/libodfgen/src/.libs -lodfgen-0.1 \
1794 endef
1796 endif
1798 endif # SYSTEM_ODFGEN
1800 ifneq ($(SYSTEM_EPUBGEN),)
1802 define gb_LinkTarget__use_epubgen
1803 $(call gb_LinkTarget_set_include,$(1),\
1804 $$(INCLUDE) \
1805 $(EPUBGEN_CFLAGS) \
1807 $(call gb_LinkTarget_add_libs,$(1),$(EPUBGEN_LIBS))
1809 endef
1810 gb_ExternalProject__use_epubgen :=
1812 else # !SYSTEM_EPUBGEN
1813 ifneq ($(ENABLE_WASM_STRIP_EPUB),TRUE)
1815 define gb_LinkTarget__use_epubgen
1816 $(call gb_LinkTarget_set_include,$(1),\
1817 -I$(gb_UnpackedTarball_workdir)/libepubgen/inc \
1818 $$(INCLUDE) \
1820 $(call gb_LinkTarget_add_libs,$(1),\
1821 $(gb_UnpackedTarball_workdir)/libepubgen/src/lib/.libs/libepubgen-0.1$(gb_StaticLibrary_PLAINEXT) \
1823 $(call gb_LinkTarget_use_external_project,$(1),libepubgen)
1825 endef
1826 define gb_ExternalProject__use_epubgen
1827 $(call gb_ExternalProject_use_external_project,$(1),libepubgen)
1829 endef
1831 endif # ENABLE_WASM_STRIP_EPUB
1832 endif # SYSTEM_EPUBGEN
1834 ifneq ($(SYSTEM_REVENGE),)
1836 define gb_LinkTarget__use_revenge
1837 $(call gb_LinkTarget_set_include,$(1),\
1838 $$(INCLUDE) \
1839 $(REVENGE_CFLAGS) \
1841 $(call gb_LinkTarget_add_libs,$(1),$(REVENGE_LIBS))
1843 endef
1845 gb_ExternalProject__use_revenge :=
1847 else # !SYSTEM_REVENGE
1849 ifeq ($(COM),MSC)
1851 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
1852 revenge \
1855 define gb_LinkTarget__use_revenge
1856 $(call gb_LinkTarget_set_include,$(1),\
1857 $(REVENGE_CFLAGS) \
1858 $$(INCLUDE) \
1860 $(call gb_LinkTarget_use_libraries,$(1),\
1861 revenge \
1864 endef
1866 define gb_ExternalProject__use_revenge
1867 $(call gb_ExternalProject_get_preparation_target,$(1)) : $(call gb_Library_get_target,revenge)
1869 endef
1871 else # !MSC
1873 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
1874 librevenge \
1877 define gb_LinkTarget__use_revenge
1878 $(call gb_LinkTarget_use_package,$(1),librevenge)
1880 $(call gb_LinkTarget_set_include,$(1),\
1881 $(REVENGE_CFLAGS) \
1882 -DLIBREVENGE_VISIBILITY \
1883 $$(INCLUDE) \
1885 $(call gb_LinkTarget_add_libs,$(1),\
1886 $(REVENGE_LIBS) \
1888 endef
1890 define gb_ExternalProject__use_revenge
1891 $(call gb_ExternalProject_use_package,$(1),librevenge)
1893 endef
1895 endif # MSC
1897 endif # SYSTEM_REVENGE
1900 ifneq ($(SYSTEM_ABW),)
1902 define gb_LinkTarget__use_abw
1903 $(call gb_LinkTarget_set_include,$(1),\
1904 $$(INCLUDE) \
1905 $(ABW_CFLAGS) \
1907 $(call gb_LinkTarget_add_libs,$(1),$(ABW_LIBS))
1909 endef
1910 gb_ExternalProject__use_abw :=
1912 else # !SYSTEM_ABW
1914 define gb_LinkTarget__use_abw
1915 $(call gb_LinkTarget_set_include,$(1),\
1916 -I$(gb_UnpackedTarball_workdir)/libabw/inc \
1917 $$(INCLUDE) \
1919 $(call gb_LinkTarget_add_libs,$(1),\
1920 $(gb_UnpackedTarball_workdir)/libabw/src/lib/.libs/libabw-0.1$(gb_StaticLibrary_PLAINEXT) \
1922 $(call gb_LinkTarget_use_external_project,$(1),libabw)
1924 endef
1925 define gb_ExternalProject__use_abw
1926 $(call gb_ExternalProject_use_external_project,$(1),libabw)
1928 endef
1930 endif # SYSTEM_ABW
1933 ifneq ($(SYSTEM_MSPUB),)
1935 define gb_LinkTarget__use_mspub
1936 $(call gb_LinkTarget_set_include,$(1),\
1937 $$(INCLUDE) \
1938 $(MSPUB_CFLAGS) \
1940 $(call gb_LinkTarget_add_libs,$(1),$(MSPUB_LIBS))
1942 endef
1944 else # !SYSTEM_MSPUB
1946 define gb_LinkTarget__use_mspub
1947 $(call gb_LinkTarget_set_include,$(1),\
1948 -I$(gb_UnpackedTarball_workdir)/libmspub/inc \
1949 $$(INCLUDE) \
1951 $(call gb_LinkTarget_add_libs,$(1),\
1952 $(gb_UnpackedTarball_workdir)/libmspub/src/lib/.libs/libmspub-0.1$(gb_StaticLibrary_PLAINEXT) \
1954 $(call gb_LinkTarget_use_external_project,$(1),libmspub)
1956 endef
1958 endif # SYSTEM_MSPUB
1961 ifneq ($(SYSTEM_PAGEMAKER),)
1963 define gb_LinkTarget__use_pagemaker
1964 $(call gb_LinkTarget_set_include,$(1),\
1965 $$(INCLUDE) \
1966 $(PAGEMAKER_CFLAGS) \
1968 $(call gb_LinkTarget_add_libs,$(1),$(PAGEMAKER_LIBS))
1970 endef
1971 gb_ExternalProject__use_pagemaker :=
1973 else # !SYSTEM_PAGEMAKER
1975 define gb_LinkTarget__use_pagemaker
1976 $(call gb_LinkTarget_set_include,$(1),\
1977 -I$(gb_UnpackedTarball_workdir)/libpagemaker/inc \
1978 $$(INCLUDE) \
1980 $(call gb_LinkTarget_add_libs,$(1),\
1981 $(gb_UnpackedTarball_workdir)/libpagemaker/src/lib/.libs/libpagemaker-0.0$(gb_StaticLibrary_PLAINEXT) \
1983 $(call gb_LinkTarget_use_external_project,$(1),libpagemaker)
1985 endef
1986 define gb_ExternalProject__use_pagemaker
1987 $(call gb_ExternalProject_use_external_project,$(1),libpagemaker)
1989 endef
1991 endif # SYSTEM_PAGEMAKER
1994 ifneq ($(SYSTEM_QXP),)
1996 define gb_LinkTarget__use_qxp
1997 $(call gb_LinkTarget_set_include,$(1),\
1998 $$(INCLUDE) \
1999 $(QXP_CFLAGS) \
2001 $(call gb_LinkTarget_add_libs,$(1),$(QXP_LIBS))
2003 endef
2004 gb_ExternalProject__use_qxp :=
2006 else # !SYSTEM_QXP
2008 define gb_LinkTarget__use_qxp
2009 $(call gb_LinkTarget_set_include,$(1),\
2010 -I$(gb_UnpackedTarball_workdir)/libqxp/inc \
2011 $$(INCLUDE) \
2013 $(call gb_LinkTarget_add_libs,$(1),\
2014 $(gb_UnpackedTarball_workdir)/libqxp/src/lib/.libs/libqxp-0.0$(gb_StaticLibrary_PLAINEXT) \
2016 $(call gb_LinkTarget_use_external_project,$(1),libqxp)
2018 endef
2019 define gb_ExternalProject__use_qxp
2020 $(call gb_ExternalProject_use_external_project,$(1),libqxp)
2022 endef
2024 endif # SYSTEM_QXP
2027 ifneq ($(SYSTEM_ZMF),)
2029 define gb_LinkTarget__use_zmf
2030 $(call gb_LinkTarget_set_include,$(1),\
2031 $$(INCLUDE) \
2032 $(ZMF_CFLAGS) \
2034 $(call gb_LinkTarget_add_libs,$(1),$(ZMF_LIBS))
2036 endef
2037 gb_ExternalProject__use_zmf :=
2039 else # !SYSTEM_ZMF
2041 define gb_LinkTarget__use_zmf
2042 $(call gb_LinkTarget_set_include,$(1),\
2043 -I$(gb_UnpackedTarball_workdir)/libzmf/inc \
2044 $$(INCLUDE) \
2046 $(call gb_LinkTarget_add_libs,$(1),\
2047 $(gb_UnpackedTarball_workdir)/libzmf/src/lib/.libs/libzmf-0.0$(gb_StaticLibrary_PLAINEXT) \
2049 $(call gb_LinkTarget_use_external_project,$(1),libzmf)
2051 endef
2052 define gb_ExternalProject__use_zmf
2053 $(call gb_ExternalProject_use_external_project,$(1),libzmf)
2055 endef
2057 endif # SYSTEM_ZMF
2060 ifneq ($(SYSTEM_VISIO),)
2062 define gb_LinkTarget__use_visio
2063 $(call gb_LinkTarget_set_include,$(1),\
2064 $$(INCLUDE) \
2065 $(VISIO_CFLAGS) \
2067 $(call gb_LinkTarget_add_libs,$(1),$(VISIO_LIBS))
2069 endef
2071 else # !SYSTEM_VISIO
2073 define gb_LinkTarget__use_visio
2074 $(call gb_LinkTarget_set_include,$(1),\
2075 -I$(gb_UnpackedTarball_workdir)/libvisio/inc \
2076 $$(INCLUDE) \
2078 $(call gb_LinkTarget_add_libs,$(1),\
2079 $(gb_UnpackedTarball_workdir)/libvisio/src/lib/.libs/libvisio-0.1$(gb_StaticLibrary_PLAINEXT) \
2081 $(call gb_LinkTarget_use_external_project,$(1),libvisio)
2083 endef
2085 endif # SYSTEM_VISIO
2088 ifneq ($(SYSTEM_WPD),)
2090 define gb_LinkTarget__use_wpd
2091 $(call gb_LinkTarget_set_include,$(1),\
2092 $$(INCLUDE) \
2093 $(WPD_CFLAGS) \
2095 $(call gb_LinkTarget_add_libs,$(1),$(WPD_LIBS))
2097 endef
2098 gb_ExternalProject__use_wpd :=
2100 else # !SYSTEM_WPD
2102 ifeq ($(COM),MSC)
2104 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2105 wpd \
2108 define gb_LinkTarget__use_wpd
2109 $(call gb_LinkTarget_set_include,$(1),\
2110 $(WPD_CFLAGS) \
2111 $$(INCLUDE) \
2113 $(call gb_LinkTarget_use_libraries,$(1),\
2114 wpd \
2117 endef
2119 define gb_ExternalProject__use_wpd
2120 $(call gb_ExternalProject_get_preparation_target,$(1)) : $(call gb_Library_get_target,wpd)
2122 endef
2124 else # !MSC
2126 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
2127 libwpd \
2130 define gb_LinkTarget__use_wpd
2131 $(call gb_LinkTarget_use_package,$(1),libwpd)
2133 $(call gb_LinkTarget_set_include,$(1),\
2134 $(WPD_CFLAGS) \
2135 $$(INCLUDE) \
2137 $(call gb_LinkTarget_add_libs,$(1),\
2138 $(WPD_LIBS) \
2141 endef
2143 define gb_ExternalProject__use_wpd
2144 $(call gb_ExternalProject_use_package,$(1),libwpd)
2146 endef
2148 endif # MSC
2150 endif # SYSTEM_WPD
2153 ifneq ($(SYSTEM_WPG),)
2155 define gb_LinkTarget__use_wpg
2156 $(call gb_LinkTarget_set_include,$(1),\
2157 $$(INCLUDE) \
2158 $(WPG_CFLAGS) \
2160 $(call gb_LinkTarget_add_libs,$(1),$(WPG_LIBS))
2162 endef
2163 gb_ExternalProject__use_wpg :=
2165 else # !SYSTEM_WPG
2167 ifeq ($(COM),MSC)
2169 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2170 wpg \
2173 define gb_LinkTarget__use_wpg
2174 $(call gb_LinkTarget_set_include,$(1),\
2175 -I$(gb_UnpackedTarball_workdir)/libwpg/inc \
2176 $$(INCLUDE) \
2178 $(call gb_LinkTarget_use_libraries,$(1),\
2179 wpg \
2182 endef
2184 else # !MSC
2186 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
2187 libwpg \
2190 define gb_LinkTarget__use_wpg
2191 $(call gb_LinkTarget_use_package,$(1),libwpg)
2193 $(call gb_LinkTarget_set_include,$(1),\
2194 -I$(gb_UnpackedTarball_workdir)/libwpg/inc \
2195 $$(INCLUDE) \
2197 $(call gb_LinkTarget_add_libs,$(1),\
2198 -L$(gb_UnpackedTarball_workdir)/libwpg/src/lib/.libs -lwpg-0.3 \
2201 endef
2203 endif # MSC
2205 endif # SYSTEM_WPG
2208 ifneq ($(SYSTEM_WPS),)
2210 define gb_LinkTarget__use_wps
2211 $(call gb_LinkTarget_set_include,$(1),\
2212 $$(INCLUDE) \
2213 $(WPS_CFLAGS) \
2215 $(call gb_LinkTarget_add_libs,$(1),$(WPS_LIBS))
2217 endef
2218 gb_ExternalProject__use_wps :=
2220 else # !SYSTEM_WPS
2222 ifeq ($(COM),MSC)
2224 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2225 wps \
2228 define gb_LinkTarget__use_wps
2229 $(call gb_LinkTarget_set_include,$(1),\
2230 -I$(gb_UnpackedTarball_workdir)/libwps/inc \
2231 $$(INCLUDE) \
2234 $(call gb_LinkTarget_use_libraries,$(1),\
2235 wps \
2238 endef
2240 else # !MSC
2242 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
2243 libwps \
2246 define gb_LinkTarget__use_wps
2247 $(call gb_LinkTarget_use_package,$(1),libwps)
2249 $(call gb_LinkTarget_set_include,$(1),\
2250 -I$(gb_UnpackedTarball_workdir)/libwps/inc \
2251 $$(INCLUDE) \
2253 $(call gb_LinkTarget_add_libs,$(1),\
2254 -L$(gb_UnpackedTarball_workdir)/libwps/src/lib/.libs -lwps-0.4 \
2257 endef
2259 endif # MSC
2261 endif # SYSTEM_WPS
2264 ifneq ($(SYSTEM_MWAW),)
2266 define gb_LinkTarget__use_mwaw
2267 $(call gb_LinkTarget_set_include,$(1),\
2268 $$(INCLUDE) \
2269 $(MWAW_CFLAGS) \
2271 $(call gb_LinkTarget_add_libs,$(1),$(MWAW_LIBS))
2273 endef
2275 else # !SYSTEM_MWAW
2277 ifeq ($(COM),MSC)
2279 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2280 mwaw \
2283 define gb_LinkTarget__use_mwaw
2284 $(call gb_LinkTarget_set_include,$(1),\
2285 -I$(gb_UnpackedTarball_workdir)/libmwaw/inc \
2286 $$(INCLUDE) \
2289 $(call gb_LinkTarget_use_libraries,$(1),\
2290 mwaw \
2293 endef
2295 else # !MSC
2297 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2298 libmwaw \
2301 define gb_LinkTarget__use_mwaw
2302 $(call gb_LinkTarget_use_package,$(1),libmwaw)
2304 $(call gb_LinkTarget_set_include,$(1),\
2305 -I$(gb_UnpackedTarball_workdir)/libmwaw/inc \
2306 $$(INCLUDE) \
2308 $(call gb_LinkTarget_add_libs,$(1),\
2309 -L$(gb_UnpackedTarball_workdir)/libmwaw/src/lib/.libs -lmwaw-0.3 \
2312 endef
2314 endif # MSC
2316 endif # SYSTEM_MWAW
2318 ifneq ($(SYSTEM_STAROFFICE),)
2320 define gb_LinkTarget__use_staroffice
2321 $(call gb_LinkTarget_set_include,$(1),\
2322 $$(INCLUDE) \
2323 $(STAROFFICE_CFLAGS) \
2325 $(call gb_LinkTarget_add_libs,$(1),$(STAROFFICE_LIBS))
2327 endef
2329 else # !SYSTEM_STAROFFICE
2331 ifeq ($(COM),MSC)
2333 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2334 staroffice \
2337 define gb_LinkTarget__use_staroffice
2338 $(call gb_LinkTarget_set_include,$(1),\
2339 -I$(gb_UnpackedTarball_workdir)/libstaroffice/inc \
2340 $$(INCLUDE) \
2343 $(call gb_LinkTarget_use_libraries,$(1),\
2344 staroffice \
2347 endef
2349 else # !MSC
2351 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2352 libstaroffice \
2355 define gb_LinkTarget__use_staroffice
2356 $(call gb_LinkTarget_use_package,$(1),libstaroffice)
2358 $(call gb_LinkTarget_set_include,$(1),\
2359 -I$(gb_UnpackedTarball_workdir)/libstaroffice/inc \
2360 $$(INCLUDE) \
2362 $(call gb_LinkTarget_add_libs,$(1),\
2363 -L$(gb_UnpackedTarball_workdir)/libstaroffice/src/lib/.libs -lstaroffice-0.0 \
2366 endef
2368 endif # MSC
2370 endif # SYSTEM_STAROFFICE
2373 ifneq ($(SYSTEM_LCMS2),)
2375 define gb_LinkTarget__use_lcms2
2376 $(call gb_LinkTarget_set_include,$(1),\
2377 $$(INCLUDE) \
2378 $(LCMS2_CFLAGS) \
2380 $(call gb_LinkTarget_add_libs,$(1),$(LCMS2_LIBS))
2382 endef
2384 gb_ExternalProject__use_lcms2 :=
2386 else # !SYSTEM_LCMS2
2388 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2389 lcms2 \
2392 define gb_ExternalProject__use_lcms2
2393 $(call gb_ExternalProject_use_package,$(1),lcms2)
2395 endef
2397 ifeq ($(OS),ANDROID)
2399 define gb_LinkTarget__use_lcms2
2400 $(call gb_LinkTarget_use_package,$(1),lcms2)
2401 $(call gb_LinkTarget_set_include,$(1),\
2402 -I$(gb_UnpackedTarball_workdir)/lcms2/include \
2403 $$(INCLUDE) \
2406 endef
2408 else
2410 define gb_LinkTarget__use_lcms2
2411 $(call gb_LinkTarget_use_package,$(1),lcms2)
2412 $(call gb_LinkTarget_set_include,$(1),\
2413 -I$(gb_UnpackedTarball_workdir)/lcms2/include \
2414 $$(INCLUDE) \
2416 $(call gb_LinkTarget_add_libs,$(1),$(LCMS2_LIBS))
2418 endef
2420 endif # ANDROID
2421 endif # SYSTEM_LCMS2
2423 ifneq ($(ENABLE_LPSOLVE),)
2425 ifneq ($(SYSTEM_LPSOLVE),)
2427 define gb_LinkTarget__use_lpsolve
2428 $(call gb_LinkTarget_add_libs,$(1),-llpsolve55)
2429 $(call gb_LinkTarget_add_defs,$(1),\
2430 -DSYSTEM_LPSOLVE \
2433 endef
2435 else # !SYSTEM_LPSOLVE
2437 define gb_LinkTarget__use_lpsolve
2438 $(call gb_LinkTarget_use_package,$(1),lpsolve)
2439 ifeq ($(COM),MSC)
2440 $(call gb_LinkTarget_add_libs,$(1),\
2441 $(gb_UnpackedTarball_workdir)/lpsolve/lpsolve55/lpsolve55.lib \
2443 else
2444 $(call gb_LinkTarget_add_libs,$(1),\
2445 -L$(gb_UnpackedTarball_workdir)/lpsolve/lpsolve55 -llpsolve55 \
2447 endif
2448 $(call gb_LinkTarget_set_include,$(1),\
2449 -I$(gb_UnpackedTarball_workdir)/lpsolve \
2450 $$(INCLUDE) \
2453 endef
2455 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2456 lpsolve \
2459 endif # SYSTEM_LPSOLVE
2461 else
2463 gb_LinkTarget__use_lpsolve :=
2465 endif # ENABLE_LPSOLVE
2467 ifneq ($(ENABLE_COINMP),)
2469 ifneq ($(SYSTEM_COINMP),TRUE)
2471 define gb_LinkTarget__use_coinmp
2472 $(call gb_LinkTarget_use_package,$(1),coinmp)
2473 ifeq ($(COM),MSC)
2474 $(call gb_LinkTarget_add_libs,$(1),\
2475 $(gb_UnpackedTarball_workdir)/coinmp/CoinMP/MSVisualStudio/v9/$(wnt_arch_subdir_optional)$(if $(MSVC_USE_DEBUG_RUNTIME),Debug,Release)/CoinMP.lib \
2477 else
2478 $(call gb_LinkTarget_add_libs,$(1),\
2479 -L$(gb_UnpackedTarball_workdir)/coinmp/Cbc/src/.libs -lCbc -lCbcSolver \
2480 -L$(gb_UnpackedTarball_workdir)/coinmp/Cgl/src/.libs -lCgl \
2481 -L$(gb_UnpackedTarball_workdir)/coinmp/Clp/src/.libs -lClp \
2482 -L$(gb_UnpackedTarball_workdir)/coinmp/Clp/src/OsiClp/.libs -lOsiClp \
2483 -L$(gb_UnpackedTarball_workdir)/coinmp/CoinMP/src/.libs -lCoinMP \
2484 -L$(gb_UnpackedTarball_workdir)/coinmp/CoinUtils/src/.libs -lCoinUtils \
2485 -L$(gb_UnpackedTarball_workdir)/coinmp/Osi/src/Osi/.libs -lOsi \
2487 endif
2488 $(call gb_LinkTarget_set_include,$(1),\
2489 -I$(gb_UnpackedTarball_workdir)/coinmp/CoinMP/src \
2490 -I$(gb_UnpackedTarball_workdir)/coinmp/CoinUtils/src \
2491 $$(INCLUDE) \
2494 endef
2496 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2497 coinmp \
2500 else # SYSTEM_COINMP
2502 define gb_LinkTarget__use_coinmp
2503 $(call gb_LinkTarget_set_include,$(1),\
2504 $$(INCLUDE) \
2505 $(COINMP_CFLAGS) \
2507 $(call gb_LinkTarget_add_libs,$(1),$(COINMP_LIBS))
2509 endef
2511 endif
2513 else
2515 gb_LinkTarget__use_coinmp :=
2517 endif # ENABLE_COINMP
2519 ifneq (,$(filter MDNSRESPONDER,$(BUILD_TYPE)))
2521 define gb_LinkTarget__use_mDNSResponder
2522 $(call gb_LinkTarget_set_include,$(1),\
2523 -I$(gb_UnpackedTarball_workdir)/mDNSResponder/mDNSShared \
2524 $$(INCLUDE) \
2526 $(call gb_LinkTarget_use_static_libraries,$(1),mDNSResponder)
2527 endef
2529 endif # MDNSRESPONDER
2531 ifeq ($(ENABLE_GIO),TRUE)
2533 define gb_LinkTarget__use_gio
2534 $(call gb_LinkTarget_set_include,$(1),\
2535 $$(INCLUDE) \
2536 $(GIO_CFLAGS) \
2539 $(call gb_LinkTarget_add_libs,$(1),$(GIO_LIBS))
2541 endef
2543 else # ENABLE_GIO
2545 define gb_LinkTarget__use_gio
2547 endef
2549 endif # ENABLE_GIO
2551 ifeq ($(ENABLE_AVAHI),TRUE)
2553 define gb_LinkTarget__use_avahi
2554 $(call gb_LinkTarget_set_include,$(1),\
2555 $$(INCLUDE) \
2556 $(AVAHI_CFLAGS) \
2559 $(call gb_LinkTarget_add_defs,$(1),\
2560 -DENABLE_AVAHI \
2563 $(call gb_LinkTarget_add_libs,$(1),$(AVAHI_LIBS))
2565 endef
2567 else # ENABLE_AVAHI
2569 gb_LinkTarget__use_avahi :=
2571 endif # ENABLE_AVAHI
2573 ifeq ($(ENABLE_CPDB),TRUE)
2575 define gb_LinkTarget__use_cpdb
2576 $(call gb_LinkTarget_set_include,$(1),\
2577 $$(INCLUDE) \
2578 $(CPDB_CFLAGS) \
2581 $(call gb_LinkTarget_add_libs,$(1),\
2582 $(CPDB_LIBS) \
2585 endef
2587 else # ENABLE_CPDB
2589 define gb_LinkTarget__use_cpdb
2591 endef
2593 endif # ENABLE_CPDB
2595 ifeq ($(ENABLE_CUPS),TRUE)
2597 define gb_LinkTarget__use_cups
2599 $(call gb_LinkTarget_add_libs,$(1),\
2600 -lcups \
2603 endef
2605 else # ENABLE_CUPS
2607 define gb_LinkTarget__use_cups
2609 endef
2611 endif # ENABLE_CUPS
2613 ifeq ($(ENABLE_DBUS),TRUE)
2615 define gb_LinkTarget__use_dbus
2616 $(call gb_LinkTarget_set_include,$(1),\
2617 $$(INCLUDE) \
2618 $(DBUS_CFLAGS) \
2621 $(call gb_LinkTarget_add_libs,$(1),\
2622 $(DBUS_LIBS) \
2625 endef
2627 else # ENABLE_DBUS
2629 define gb_LinkTarget__use_dbus
2631 endef
2633 endif # ENABLE_DBUS
2636 ifneq ($(SYSTEM_LIBPNG),)
2638 define gb_LinkTarget__use_libpng
2639 $(call gb_LinkTarget_set_include,$(1),\
2640 $$(INCLUDE) \
2641 $(LIBPNG_CFLAGS) \
2644 $(call gb_LinkTarget_add_libs,$(1),\
2645 $(LIBPNG_LIBS) \
2648 endef
2650 gb_ExternalProject__use_libpng :=
2652 else # !SYSTEM_LIBPNG
2654 define gb_LinkTarget__use_libpng
2655 $(call gb_LinkTarget_set_include,$(1),\
2656 $(LIBPNG_CFLAGS) \
2657 $$(INCLUDE) \
2659 $(call gb_LinkTarget_use_static_libraries,$(1),\
2660 libpng \
2662 $(call gb_LinkTarget__use_zlib,$(1))
2664 endef
2666 define gb_ExternalProject__use_libpng
2667 $(call gb_ExternalProject_use_static_libraries,$(1),\
2668 libpng \
2671 endef
2673 endif # !SYSTEM_LIBPNG
2675 ifneq ($(SYSTEM_LIBTIFF),)
2677 define gb_LinkTarget__use_libtiff
2678 $(call gb_LinkTarget_set_include,$(1),\
2679 $$(INCLUDE) \
2680 $(LIBTIFF_CFLAGS) \
2683 $(call gb_LinkTarget_add_libs,$(1),\
2684 $(LIBTIFF_LIBS) \
2687 endef
2689 gb_ExternalProject__use_libtiff :=
2691 else # !SYSTEM_LIBTIFF
2693 define gb_LinkTarget__use_libtiff
2694 $(call gb_LinkTarget_set_include,$(1),\
2695 $(LIBTIFF_CFLAGS) \
2696 $$(INCLUDE) \
2699 $(call gb_LinkTarget_set_include,$(1),\
2700 -I$(gb_UnpackedTarball_workdir)/libtiff/libtiff \
2701 $$(INCLUDE) \
2703 ifeq ($(OS),WNT)
2704 $(call gb_LinkTarget_add_libs,$(1),\
2705 $(gb_UnpackedTarball_workdir)/libtiff/libtiff/.libs/libtiff$(gb_StaticLibrary_PLAINEXT) \
2707 else
2708 $(call gb_LinkTarget_add_libs,$(1),\
2709 -L$(gb_UnpackedTarball_workdir)/libtiff/libtiff/.libs -ltiff \
2711 endif
2712 $(call gb_LinkTarget_use_external_project,$(1),libtiff,full)
2714 endef
2716 define gb_ExternalProject__use_libtiff
2717 $(call gb_ExternalProject_use_external_project,$(1),libtiff)
2719 endef
2721 endif # !SYSTEM_LIBTIFF
2723 ifneq ($(SYSTEM_LIBWEBP),)
2725 define gb_LinkTarget__use_libwebp
2726 $(call gb_LinkTarget_set_include,$(1),\
2727 $$(INCLUDE) \
2728 $(LIBWEBP_CFLAGS) \
2731 $(call gb_LinkTarget_add_libs,$(1),\
2732 $(LIBWEBP_LIBS) \
2735 endef
2737 gb_ExternalProject__use_libwebp :=
2739 else # !SYSTEM_LIBWEBP
2741 define gb_LinkTarget__use_libwebp
2742 $(call gb_LinkTarget_set_include,$(1),\
2743 $(LIBWEBP_CFLAGS) \
2744 $$(INCLUDE) \
2747 $(call gb_LinkTarget_set_include,$(1),\
2748 -I$(gb_UnpackedTarball_workdir)/libwebp/src \
2749 $$(INCLUDE) \
2751 ifeq ($(OS),WNT)
2752 $(call gb_LinkTarget_add_libs,$(1),\
2753 $(gb_UnpackedTarball_workdir)/libwebp/output/lib/libwebp$(if $(MSVC_USE_DEBUG_RUNTIME),_debug)$(gb_StaticLibrary_PLAINEXT) \
2755 else
2756 $(call gb_LinkTarget_add_libs,$(1),\
2757 -L$(gb_UnpackedTarball_workdir)/libwebp/src/.libs -lwebp \
2758 -L$(gb_UnpackedTarball_workdir)/libwebp/sharpyuv/.libs -lsharpyuv \
2760 endif
2761 $(call gb_LinkTarget_use_external_project,$(1),libwebp)
2763 endef
2765 define gb_ExternalProject__use_libwebp
2766 $(call gb_ExternalProject_use_external_project,$(1),libwebp)
2768 endef
2770 endif # !SYSTEM_LIBWEBP
2773 ifneq ($(SYSTEM_CURL),)
2775 define gb_LinkTarget__use_curl
2776 $(call gb_LinkTarget_add_defs,$(1),\
2777 -DSYSTEM_CURL \
2779 $(call gb_LinkTarget_set_include,$(1),\
2780 $$(INCLUDE) \
2781 $(CURL_CFLAGS) \
2783 $(call gb_LinkTarget_add_libs,$(1),$(CURL_LIBS))
2785 endef
2787 else # !SYSTEM_CURL
2789 $(if $(ENABLE_CURL),\
2790 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
2791 curl \
2794 define gb_LinkTarget__use_curl
2795 $(call gb_LinkTarget_use_package,$(1),curl)
2796 $(call gb_LinkTarget_set_include,$(1),\
2797 -I$(gb_UnpackedTarball_workdir)/curl/include \
2798 $$(INCLUDE) \
2801 ifeq ($(COM),MSC)
2802 $(call gb_LinkTarget_add_libs,$(1),\
2803 $(gb_UnpackedTarball_workdir)/curl/builds/libcurl-vc12-$(gb_MSBUILD_PLATFORM)-$(gb_MSBUILD_CONFIG)-dll-zlib-static-ipv6-sspi-schannel/lib/libcurl$(if $(MSVC_USE_DEBUG_RUNTIME),_debug).lib \
2805 else
2806 $(call gb_LinkTarget_add_libs,$(1),\
2807 -L$(gb_UnpackedTarball_workdir)/curl/lib/.libs -lcurl \
2809 endif
2811 endef
2813 endif # SYSTEM_CURL
2815 ifeq ($(ENABLE_VALGRIND),TRUE)
2817 define gb_LinkTarget__use_valgrind
2818 $(call gb_LinkTarget_add_defs,$(1),\
2819 -DHAVE_VALGRIND_HEADERS \
2822 $(call gb_LinkTarget_set_include,$(1),\
2823 $$(INCLUDE) \
2824 $(VALGRIND_CFLAGS) \
2827 endef
2829 else # !ENABLE_VALGRIND
2831 define gb_LinkTarget__use_valgrind
2833 endef
2835 endif # ENABLE_VALGRIND
2837 ifeq ($(ENABLE_POPPLER),TRUE)
2839 ifneq ($(SYSTEM_POPPLER),)
2841 define gb_LinkTarget__use_poppler
2842 $(call gb_LinkTarget_set_include,$(1),\
2843 $(POPPLER_CFLAGS) \
2844 $$(INCLUDE) \
2847 $(call gb_LinkTarget_add_libs,$(1),\
2848 $(POPPLER_LIBS) \
2851 endef
2853 else # !SYSTEM_POPPLER
2855 $(eval $(call gb_Helper_register_packages_for_install,pdfimport,\
2856 poppler_data \
2859 define gb_LinkTarget__use_poppler
2860 $(call gb_LinkTarget_use_external_project,$(1),poppler,full)
2861 $(call gb_LinkTarget_use_package,$(1),poppler_data)
2862 $(call gb_LinkTarget_set_include,$(1),\
2863 -I$(gb_UnpackedTarball_workdir)/poppler \
2864 -I$(gb_UnpackedTarball_workdir)/poppler/poppler \
2865 -I$(gb_UnpackedTarball_workdir)/poppler/goo \
2866 $$(INCLUDE) \
2869 $(call gb_LinkTarget_use_static_libraries,$(1),poppler)
2870 $(call gb_LinkTarget_use_external,$(1),libjpeg)
2872 ifeq ($(OS),MACOSX)
2873 $(call gb_LinkTarget_add_libs,$(1),\
2874 -lobjc \
2876 else ifeq ($(OS),LINUX)
2877 $(call gb_LinkTarget_add_libs,$(1),\
2878 -pthread \
2880 else ifeq ($(OS),WNT)
2881 $(call gb_LinkTarget_use_system_win32_libs,$(1),\
2882 advapi32 \
2883 gdi32 \
2885 endif
2887 endef
2889 endif # SYSTEM_POPPLER
2891 endif # ENABLE_POPPLER
2894 ifneq ($(SYSTEM_CLUCENE),)
2896 define gb_LinkTarget__use_clucene
2897 $(call gb_LinkTarget_add_defs,$(1),\
2898 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(CLUCENE_CFLAGS))) \
2899 -DSYSTEM_CLUCENE \
2902 $(call gb_LinkTarget_set_include,$(1),\
2903 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(CLUCENE_CFLAGS)))) \
2904 $$(INCLUDE) \
2907 $(call gb_LinkTarget_add_libs,$(1),\
2908 $(CLUCENE_LIBS) \
2911 endef
2913 else # !SYSTEM_CLUCENE
2915 define gb_LinkTarget__use_clucene
2916 $(call gb_LinkTarget_set_include,$(1),\
2917 -I$(gb_UnpackedTarball_workdir)/clucene/src/core \
2918 -I$(gb_UnpackedTarball_workdir)/clucene/src/shared \
2919 -I$(gb_UnpackedTarball_workdir)/clucene/src/contribs-lib \
2920 $$(INCLUDE) \
2923 $(call gb_LinkTarget_use_libraries,$(1),\
2924 clucene \
2927 endef
2929 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
2930 $(call gb_Helper_optionals_or,HELPTOOLS XMLHELP,clucene) \
2933 endif # SYSTEM_CLUCENE
2935 define gb_LinkTarget__use_gobject
2936 $(call gb_LinkTarget_add_libs,$(1),\
2937 $(GOBJECT_LIBS) \
2940 $(call gb_LinkTarget_set_include,$(1),\
2941 $$(INCLUDE) \
2942 $(GOBJECT_CFLAGS) \
2944 endef
2946 ifneq ($(SYSTEM_HSQLDB),)
2948 define gb_LinkTarget__use_hsqldb
2950 $(call gb_LinkTarget_add_defs,$(1),\
2951 -DSYSTEM_HSQLDB \
2952 -DHSQLDB_JAR=\""file://$(HSQLDB_JAR)"\" \
2955 endef
2957 else # !SYSTEM_HSQLDB
2959 define gb_LinkTarget__use_hsqldb
2961 endef
2963 endif # SYSTEM_HSQLDB
2965 ifeq ($(ENABLE_LDAP),TRUE)
2966 ifneq ($(SYSTEM_OPENLDAP),)
2968 define gb_LinkTarget__use_openldap
2970 $(call gb_LinkTarget_add_libs,$(1),\
2971 -lldap \
2972 -llber \
2975 endef
2977 gb_ExternalProject__use_openldap :=
2979 else # !SYSTEM_OPENLDAP
2981 define gb_LinkTarget__use_openldap
2982 $(call gb_LinkTarget_use_unpacked,$(1),openldap)
2983 $(call gb_LinkTarget_set_include,$(1),\
2984 -I$(gb_UnpackedTarball_workdir)/openldap/include \
2985 $$(INCLUDE) \
2987 $(call gb_LinkTarget_use_external_project,$(1),openldap,full)
2988 $(call gb_LinkTarget_add_libs,$(1), \
2989 $(gb_UnpackedTarball_workdir)/openldap/libraries/libldap/.libs/libldap.a \
2990 $(gb_UnpackedTarball_workdir)/openldap/libraries/liblber/.libs/liblber.a \
2993 endef
2994 endif
2996 define gb_ExternalProject__use_openldap
2997 $(call gb_ExternalProject_use_external_project,$(1),openldap)
2999 endef
3001 endif # SYSTEM_OPENLDAP
3003 ifneq ($(SYSTEM_LIBTOMMATH),)
3005 define gb_LinkTarget__use_libtommath
3006 $(call gb_LinkTarget_set_include,$(1),\
3007 $(LIBTOMMATH_CFLAGS) \
3008 $$(INCLUDE) \
3010 $(call gb_LinkTarget_add_libs,$(1),$(LIBTOMMATH_LIBS))
3012 endef
3014 else # !SYSTEM_LIBTOMMATH
3015 define gb_LinkTarget__use_libtommath
3016 $(call gb_LinkTarget_set_include,$(1),\
3017 -I${WORKDIR}/UnpackedTarball/libtommath \
3018 $$(INCLUDE) \
3020 $(call gb_LinkTarget_add_libs,$(1),\
3021 $(gb_UnpackedTarball_workdir)/libtommath/libtommath$(gb_StaticLibrary_PLAINEXT) \
3023 $(call gb_LinkTarget_use_external_project,$(1),libtommath)
3025 endef
3027 endif # SYSTEM_LIBTOMMATH
3029 define gb_ExternalProject__use_libtommath
3030 $(call gb_ExternalProject_use_external_project,$(1),libtommath)
3032 endef
3034 ifeq ($(ENABLE_FIREBIRD_SDBC),TRUE)
3036 ifneq ($(SYSTEM_FIREBIRD),)
3038 define gb_LinkTarget__use_libfbembed
3039 $(call gb_LinkTarget_set_include,$(1),\
3040 $(FIREBIRD_CFLAGS) \
3041 $$(INCLUDE) \
3043 $(call gb_LinkTarget_add_libs,$(1),$(FIREBIRD_LIBS))
3045 endef
3047 else # !SYSTEM_FIREBIRD
3049 $(eval $(call gb_Helper_register_packages_for_install,firebirdsdbc,\
3050 firebird \
3053 #$(call gb_LinkTarget__use_libatomic_ops,$(1))
3054 #$(call gb_LinkTarget__use_libtommath,$(1))
3056 define gb_LinkTarget__use_libfbembed
3057 $(call gb_LinkTarget_use_package,$(1),firebird)
3058 $(call gb_LinkTarget_set_include,$(1),\
3059 -I$(gb_UnpackedTarball_workdir)/firebird/gen/$(if $(ENABLE_DEBUG),Debug,Release)/firebird/include \
3060 $$(INCLUDE) \
3062 ifeq ($(COM),MSC)
3063 $(call gb_LinkTarget_add_libs,$(1),\
3064 $(gb_UnpackedTarball_workdir)/firebird/gen/$(if $(ENABLE_DEBUG),Debug,Release)/firebird/bin/ifbclient.lib \
3066 else
3067 $(call gb_LinkTarget_add_libs,$(1),\
3068 -L$(gb_UnpackedTarball_workdir)/firebird/gen/$(if $(ENABLE_DEBUG),Debug,Release)/firebird/lib -lfbclient \
3070 endif
3072 endef
3075 # endef
3077 endif # SYSTEM_FIREBIRD
3079 else # !ENABLE_FIREBIRD_SDBC
3081 gb_LinkTarget__use_firebird :=
3082 # gb_LinkTarget__use_atomic_ops :=
3083 # gb_LinkTarget__use_libtommath :=
3085 endif # ENABLE_FIREBIRD_SDBC
3088 ifneq ($(SYSTEM_POSTGRESQL),)
3090 define gb_LinkTarget__use_postgresql
3092 $(call gb_LinkTarget_set_include,$(1),\
3093 $(POSTGRESQL_INC) \
3094 $$(INCLUDE) \
3097 $(call gb_LinkTarget_add_libs,$(1),\
3098 -lpq \
3101 $(call gb_LinkTarget_add_ldflags,$(1),\
3102 $(POSTGRESQL_LIB) \
3105 endef
3107 else # !SYSTEM_POSTGRESQL
3109 ifeq ($(OS),WNT)
3110 $(if $(MPL_SUBSET),,\
3111 $(eval $(call gb_Helper_register_packages_for_install,postgresqlsdbc,\
3112 postgresql \
3114 endif # WNT
3116 define gb_LinkTarget__use_postgresql
3118 $(call gb_LinkTarget_use_external_project,$(1),postgresql,full)
3120 $(call gb_LinkTarget_set_include,$(1),\
3121 -I$(gb_UnpackedTarball_workdir)/postgresql/src/include \
3122 -I$(gb_UnpackedTarball_workdir)/postgresql/src/interfaces/libpq \
3123 $$(INCLUDE) \
3126 ifeq ($(OS),WNT)
3128 $(call gb_LinkTarget_add_libs,$(1),\
3129 $(gb_UnpackedTarball_workdir)/postgresql/$(gb_MSBUILD_CONFIG)/libpq/libpq.lib \
3132 else # !WNT
3134 $(call gb_LinkTarget_add_libs,$(1),\
3135 $(gb_UnpackedTarball_workdir)/postgresql/src/interfaces/libpq/libpq$(gb_StaticLibrary_PLAINEXT) \
3136 $(gb_UnpackedTarball_workdir)/postgresql/src/common/libpgcommon$(gb_StaticLibrary_PLAINEXT) \
3137 $(gb_UnpackedTarball_workdir)/postgresql/src/port/libpgport$(gb_StaticLibrary_PLAINEXT) \
3138 $(if $(WITH_GSSAPI),$(GSSAPI_LIBS)) \
3141 endif # !WNT
3143 endef # gb_LinkTarget__use_postgresql
3145 endif # !SYSTEM_POSTGRESQL
3147 ifneq (,$(filter TRUE,$(ENABLE_KF5) $(ENABLE_GTK3_KDE5)))
3149 define gb_LinkTarget__use_kf5
3150 $(call gb_LinkTarget_set_include,$(1),\
3151 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(KF5_CFLAGS)))) \
3152 $$(INCLUDE) \
3155 $(call gb_LinkTarget_add_cxxflags,$(1),\
3156 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(KF5_CFLAGS))) \
3159 $(call gb_LinkTarget_add_libs,$(1),\
3160 $(KF5_LIBS) \
3163 endef
3165 else # !ENABLE_KF5
3167 define gb_LinkTarget__use_kf5
3169 endef
3171 endif # ENABLE_KF5
3173 ifneq (,$(filter TRUE,$(ENABLE_KF6)))
3175 define gb_LinkTarget__use_kf6
3176 $(call gb_LinkTarget_set_include,$(1),\
3177 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(KF6_CFLAGS)))) \
3178 $$(INCLUDE) \
3181 $(call gb_LinkTarget_add_cxxflags,$(1),\
3182 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(KF6_CFLAGS))) \
3185 $(call gb_LinkTarget_add_libs,$(1),\
3186 $(KF6_LIBS) \
3189 endef
3191 else # !ENABLE_KF6
3193 define gb_LinkTarget__use_kf6
3195 endef
3197 endif # ENABLE_KF6
3199 ifneq (,$(filter TRUE,$(ENABLE_QT5) $(ENABLE_GTK3_KDE5)))
3201 define gb_LinkTarget__use_qt5
3202 $(call gb_LinkTarget_set_include,$(1),\
3203 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(QT5_CFLAGS)))) \
3204 $$(INCLUDE) \
3207 $(call gb_LinkTarget_add_defs,$(1),\
3208 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(QT5_CFLAGS))) \
3211 $(call gb_LinkTarget_add_libs,$(1),\
3212 $(QT5_LIBS) \
3215 endef
3217 else # !ENABLE_QT5
3219 define gb_LinkTarget__use_qt5
3221 endef
3223 endif # ENABLE_QT5
3225 ifeq ($(ENABLE_QT6),TRUE)
3227 define gb_LinkTarget__use_qt6
3228 $(call gb_LinkTarget_set_include,$(1),\
3229 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(QT6_CFLAGS)))) \
3230 $$(INCLUDE) \
3233 $(call gb_LinkTarget_add_defs,$(1),\
3234 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(QT6_CFLAGS))) \
3237 $(call gb_LinkTarget_add_libs,$(1),\
3238 $(QT6_LIBS) \
3241 endef
3243 else # !ENABLE_QT6
3245 define gb_LinkTarget__use_qt6
3247 endef
3249 endif # ENABLE_QT6
3252 # PYTHON
3253 # extra python_headers external because pyuno wrapper must not link python
3254 ifneq ($(SYSTEM_PYTHON),)
3256 define gb_LinkTarget__use_python_headers
3257 $(call gb_LinkTarget_add_defs,$(1),\
3258 $(filter-out -I% -isystem%,$(subst -isystem /,-isystem/,$(PYTHON_CFLAGS)))) \
3261 $(call gb_LinkTarget_set_include,$(1),\
3262 $(subst -isystem/,-isystem /,$(filter -I% -isystem%,$(subst -isystem /,-isystem/,$(PYTHON_CFLAGS)))) \
3263 $$(INCLUDE) \
3266 endef
3268 define gb_LinkTarget__use_python
3269 $(call gb_LinkTarget__use_python_headers,$(1))
3271 $(call gb_LinkTarget_add_libs,$(1),\
3272 $(PYTHON_LIBS) \
3275 endef
3277 else # !SYSTEM_PYTHON
3279 $(eval $(call gb_Helper_register_packages_for_install,python,\
3280 python3 \
3281 $(if $(filter WNT,$(OS)),libffi) \
3284 define gb_LinkTarget__use_python_headers
3285 $(call gb_LinkTarget_use_external_project,$(1),python3,full)
3286 $(call gb_LinkTarget_set_include,$(1),\
3287 -I$(gb_UnpackedTarball_workdir)/python3 \
3288 -I$(gb_UnpackedTarball_workdir)/python3/PC \
3289 -I$(gb_UnpackedTarball_workdir)/python3/Include \
3290 $$(INCLUDE) \
3293 endef
3295 define gb_LinkTarget__use_python
3296 $(call gb_LinkTarget__use_python_headers,$(1))
3297 ifeq ($(OS),MACOSX)
3298 $(call gb_LinkTarget_use_generated_package,$(1),python3)
3299 else
3300 $(call gb_LinkTarget_use_package,$(1),python3)
3301 endif
3303 ifeq ($(OS),WNT)
3304 ifeq ($(CPUNAME),X86_64)
3305 python_arch_subdir=amd64/
3306 else ifeq ($(CPUNAME),AARCH64)
3307 python_arch_subdir=arm64/
3308 else
3309 python_arch_subdir=win32/
3310 endif
3311 $(call gb_LinkTarget_add_libs,$(1),\
3312 $(gb_UnpackedTarball_workdir)/python3/PCbuild/$(python_arch_subdir)python$(PYTHON_VERSION_MAJOR)$(PYTHON_VERSION_MINOR)$(if $(MSVC_USE_DEBUG_RUNTIME),_d).lib \
3314 else ifeq ($(OS),MACOSX)
3315 $(call gb_LinkTarget_add_libs,$(1),\
3316 -F$(gb_UnpackedTarball_workdir)/python3/python-inst/@__________________________________________________OOO -framework LibreOfficePython \
3318 else
3319 $(call gb_LinkTarget_add_libs,$(1),\
3320 -L$(gb_UnpackedTarball_workdir)/python3 \
3321 -lpython$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)$(if $(ENABLE_DBGUTIL),d) \
3323 endif
3325 endef
3327 # this is only used by python currently
3328 define gb_ExternalProject__use_libffi
3329 $(call gb_ExternalProject_use_external_project,$(1),libffi)
3331 endef
3333 endif # SYSTEM_PYTHON
3335 # ORCUS
3336 ifneq ($(SYSTEM_LIBORCUS),)
3338 define gb_LinkTarget__use_orcus
3339 $(call gb_LinkTarget_set_include,$(1),\
3340 $$(INCLUDE) \
3341 $(ORCUS_CFLAGS) \
3343 $(call gb_LinkTarget_add_libs,$(1),$(ORCUS_LIBS))
3344 endef
3346 define gb_LinkTarget__use_orcus-parser
3348 endef
3350 else # !SYSTEM_LIBORCUS
3352 ifeq ($(COM),MSC)
3354 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
3355 orcus \
3356 orcus-parser \
3359 define gb_LinkTarget__use_orcus
3360 $(call gb_LinkTarget_set_include,$(1),\
3361 -I$(gb_UnpackedTarball_workdir)/liborcus/include \
3362 $$(INCLUDE) \
3365 $(call gb_LinkTarget_use_libraries,$(1),\
3366 orcus \
3369 endef
3371 define gb_LinkTarget__use_orcus-parser
3372 $(call gb_LinkTarget_set_include,$(1),\
3373 -I$(gb_UnpackedTarball_workdir)/liborcus/include \
3374 $$(INCLUDE) \
3377 $(call gb_LinkTarget_use_libraries,$(1),\
3378 orcus-parser \
3381 endef
3383 else # !MSC
3385 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
3386 liborcus \
3389 define gb_LinkTarget__use_orcus
3390 $(call gb_LinkTarget_use_package,$(1),liborcus)
3392 $(call gb_LinkTarget_set_include,$(1),\
3393 -I$(gb_UnpackedTarball_workdir)/liborcus/include \
3394 $$(INCLUDE) \
3397 $(call gb_LinkTarget_add_libs,$(1),\
3398 -L$(gb_UnpackedTarball_workdir)/liborcus/src/liborcus/.libs -lorcus-0.18 \
3401 $(if $(SYSTEM_BOOST), \
3402 $(call gb_LinkTarget_add_ldflags,$(1),$(BOOST_LDFLAGS)) \
3403 $(call gb_LinkTarget_add_libs,$(1),$(BOOST_SYSTEM_LIB)) \
3406 endef
3408 define gb_LinkTarget__use_orcus-parser
3409 $(call gb_LinkTarget_use_package,$(1),liborcus)
3411 $(call gb_LinkTarget_set_include,$(1),\
3412 -I$(gb_UnpackedTarball_workdir)/liborcus/include \
3413 $$(INCLUDE) \
3416 $(call gb_LinkTarget_add_libs,$(1),\
3417 -L$(gb_UnpackedTarball_workdir)/liborcus/src/parser/.libs -lorcus-parser-0.18 \
3420 endef
3422 endif # MSC
3424 endif # SYSTEM_LIBORCUS
3426 ifeq ($(ENABLE_EOT),TRUE)
3428 ifneq ($(SYSTEM_LIBEOT),)
3430 define gb_LinkTarget__use_libeot
3431 $(call gb_LinkTarget_set_include,$(1),\
3432 $$(INCLUDE) \
3433 $(LIBEOT_CFLAGS) \
3435 $(call gb_LinkTarget_add_libs,$(1),$(LIBEOT_LIBS))
3437 endef
3439 gb_ExternalProject__use_libeot :=
3441 else # !SYSTEM_LIBEOT
3443 define gb_LinkTarget__use_libeot
3444 $(call gb_LinkTarget_set_include,$(1),\
3445 -I$(gb_UnpackedTarball_workdir)/libeot/inc \
3446 $$(INCLUDE) \
3448 $(call gb_LinkTarget_add_libs,$(1),\
3449 $(gb_UnpackedTarball_workdir)/libeot/.libs/libeot$(gb_StaticLibrary_PLAINEXT) \
3451 $(call gb_LinkTarget_use_external_project,$(1),libeot)
3453 endef
3455 define gb_ExternalProject__use_libeot
3456 $(call gb_ExternalProject_use_external_project,$(1),libeot)
3458 endef
3460 endif # SYSTEM_LIBEOT
3462 else # !ENABLE_EOT
3464 gb_LinkTarget__use_libeot :=
3465 gb_ExternalProject__use_libeot :=
3467 endif # ENABLE_EOT
3469 ### X11 stuff ###
3471 ifeq ($(USING_X11), TRUE)
3473 define gb_LinkTarget__use_Xrandr
3474 $(call gb_LinkTarget_set_include,$(1),\
3475 $$(INCLUDE) \
3476 $(XRANDR_CFLAGS) \
3479 $(call gb_LinkTarget_add_libs,$(1),\
3480 $(XRANDR_LIBS) \
3482 endef
3484 define gb_LinkTarget__use_Xrender
3485 $(call gb_LinkTarget_set_include,$(1),\
3486 $$(INCLUDE) \
3487 $(XRENDER_CFLAGS) \
3490 $(call gb_LinkTarget_add_libs,$(1),\
3491 $(XRENDER_LIBS) \
3493 endef
3495 endif # USING_X11
3498 gb_ExternalProject__use_nss3:=
3501 ifneq ($(SYSTEM_NSS),)
3503 define gb_LinkTarget__use_nss3
3504 $(call gb_LinkTarget_add_defs,$(1),\
3505 -DSYSTEM_NSS \
3508 $(call gb_LinkTarget_set_include,$(1),\
3509 $$(INCLUDE) \
3510 $(NSS_CFLAGS) \
3513 $(call gb_LinkTarget_add_libs,$(1),\
3514 $(NSS_LIBS) \
3517 endef
3519 define gb_LinkTarget__use_nssutil3
3520 $(call gb_LinkTarget__use_nss3,$(1))
3522 endef
3524 define gb_LinkTarget__use_plc4
3525 $(call gb_LinkTarget__use_nss3,$(1))
3527 endef
3529 define gb_LinkTarget__use_ssl3
3530 $(call gb_LinkTarget__use_nss3,$(1))
3532 endef
3534 else # !SYSTEM_NSS
3536 $(eval $(call gb_Helper_register_packages_for_install,ooo, \
3537 nss \
3540 define gb_LinkTarget__use_nss3
3541 $(call gb_LinkTarget_use_package,$(1),nss)
3542 $(call gb_LinkTarget_set_include,$(1),\
3543 $$(INCLUDE) \
3544 -I$(gb_UnpackedTarball_workdir)/nss/dist/public/nss \
3545 -I$(gb_UnpackedTarball_workdir)/nss/dist/out/include \
3548 ifeq ($(COM),MSC)
3549 $(call gb_LinkTarget_add_libs,$(1),\
3550 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/nspr4.lib \
3551 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/nss3.lib \
3552 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/smime3.lib \
3554 else
3555 $(call gb_LinkTarget_add_libs,$(1),\
3556 -L$(gb_UnpackedTarball_workdir)/nss/dist/out/lib \
3557 -lnspr4 \
3558 -lnss3 \
3559 -lsmime3 \
3561 endif
3563 endef
3565 define gb_LinkTarget__use_plc4
3566 $(call gb_LinkTarget_use_package,$(1),nss)
3567 ifeq ($(COM),MSC)
3568 $(call gb_LinkTarget_add_libs,$(1),\
3569 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/plc4.lib \
3571 else
3572 $(call gb_LinkTarget_add_libs,$(1),\
3573 -L$(gb_UnpackedTarball_workdir)/nss/dist/out/lib -lplc4 \
3575 endif
3577 endef
3579 define gb_LinkTarget__use_ssl3
3580 $(call gb_LinkTarget_use_package,$(1),nss)
3581 ifeq ($(COM),MSC)
3582 $(call gb_LinkTarget_add_libs,$(1),\
3583 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/ssl3.lib \
3585 else
3586 $(call gb_LinkTarget_add_libs,$(1),\
3587 -L$(gb_UnpackedTarball_workdir)/nss/dist/out/lib -lssl3 \
3589 endif
3591 endef
3593 define gb_LinkTarget__use_nssutil3
3594 $(call gb_LinkTarget_use_package,$(1),nss)
3595 $(call gb_LinkTarget_set_include,$(1),\
3596 $$(INCLUDE) \
3597 -I$(gb_UnpackedTarball_workdir)/nss/dist/public/nss \
3598 -I$(gb_UnpackedTarball_workdir)/nss/dist/out/include \
3601 ifeq ($(COM),MSC)
3602 $(call gb_LinkTarget_add_libs,$(1),\
3603 $(gb_UnpackedTarball_workdir)/nss/dist/out/lib/nssutil3.lib \
3605 else
3606 $(call gb_LinkTarget_add_libs,$(1),\
3607 -L$(gb_UnpackedTarball_workdir)/nss/dist/out/lib \
3608 -lnssutil3 \
3610 endif
3612 endef
3614 define gb_ExternalProject__use_nss3
3615 $(call gb_ExternalProject_use_package,$(1),nss)
3617 endef
3619 endif # SYSTEM_NSS
3621 ifeq ($(ENABLE_BREAKPAD),TRUE)
3623 define gb_LinkTarget__use_breakpad
3624 $(call gb_LinkTarget_set_include,$(1),\
3625 -I$(gb_UnpackedTarball_workdir)/breakpad/src \
3626 $$(INCLUDE) \
3629 ifeq ($(COM),MSC)
3630 $(call gb_LinkTarget_use_static_libraries,$(1),\
3631 breakpad \
3633 else
3634 $(call gb_LinkTarget_add_libs,$(1),\
3635 $(gb_UnpackedTarball_workdir)/breakpad/src/client/linux/libbreakpad_client.a \
3637 endif
3639 $(call gb_LinkTarget_use_external_project,$(1),breakpad)
3641 endef
3643 endif # ENABLE_BREAKPAD
3645 ifeq ($(ENABLE_GPGMEPP),TRUE)
3647 ifneq ($(SYSTEM_GPGMEPP),)
3649 gb_ExternalProject__use_gpgmepp:=
3650 gb_ExternalProject__use_libassuan:=
3651 gb_ExternalProject__use_libgpg-error:=
3653 define gb_LinkTarget__use_gpgmepp
3654 $(call gb_LinkTarget_set_include,$(1),\
3655 $$(INCLUDE) \
3656 $$(GPGMEPP_CFLAGS) \
3659 $(call gb_LinkTarget_add_libs,$(1),\
3660 $(GPGMEPP_LIBS) \
3663 endef
3665 else ifneq ($(filter GPGMEPP,$(BUILD_TYPE)),) # NON-SYSTEM_GPGME
3667 define gb_ExternalProject__use_gpgmepp
3668 $(call gb_ExternalProject_use_external_project,$(1),gpgmepp)
3670 endef
3671 define gb_ExternalProject__use_libassuan
3672 $(call gb_ExternalProject_use_external_project,$(1),libassuan)
3674 endef
3675 define gb_ExternalProject__use_libgpg-error
3676 $(call gb_ExternalProject_use_external_project,$(1),libgpg-error)
3678 endef
3680 ifneq ($(filter WNT,$(OS)),)
3682 define gb_LinkTarget__use_libgpg-error
3683 $(call gb_LinkTarget_use_package,$(1),libgpg-error)
3685 $(call gb_LinkTarget_set_include,$(1),\
3686 $(GPG_ERROR_CFLAGS) \
3687 $$(INCLUDE) \
3689 $(call gb_LinkTarget_add_libs,$(1),\
3690 -LIBPATH:$(gb_UnpackedTarball_workdir)/libgpg-error/src/.libs libgpg-error.lib \
3693 endef
3695 define gb_LinkTarget__use_libassuan
3696 $(call gb_LinkTarget_use_package,$(1),libassuan)
3698 $(call gb_LinkTarget_set_include,$(1),\
3699 $(LIBASSUAN_CFLAGS) \
3700 $$(INCLUDE) \
3702 $(call gb_LinkTarget_add_libs,$(1),\
3703 -LIBPATH:$(gb_UnpackedTarball_workdir)/libassuan/src/.libs libassuan.lib \
3706 endef
3708 define gb_LinkTarget__use_gpgmepp
3709 $(call gb_LinkTarget_set_include,$(1),\
3710 -I$(gb_UnpackedTarball_workdir)/gpgmepp/lang/cpp/src \
3711 -I$(gb_UnpackedTarball_workdir)/gpgmepp/src \
3712 $$(GPG_ERROR_CFLAGS) \
3713 $$(INCLUDE) \
3715 $(call gb_LinkTarget_use_libraries,$(1),\
3716 gpgmepp \
3719 endef
3721 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
3722 gpgmepp \
3723 libassuan \
3724 libgpg-error \
3727 $(eval $(call gb_Helper_register_libraries_for_install,PLAINLIBS_OOO,ooo,\
3728 gpgmepp \
3731 endif
3733 ifneq ($(filter MACOSX LINUX,$(OS)),)
3735 define gb_LinkTarget__use_gpgmepp
3736 $(call gb_LinkTarget_use_package,$(1),gpgmepp)
3738 $(call gb_LinkTarget_set_include,$(1),\
3739 -I$(gb_UnpackedTarball_workdir)/gpgmepp/lang/cpp/src \
3740 -I$(gb_UnpackedTarball_workdir)/gpgmepp/src \
3741 $$(GPG_ERROR_CFLAGS) \
3742 $$(INCLUDE) \
3744 $(call gb_LinkTarget_add_libs,$(1),\
3745 -L$(gb_UnpackedTarball_workdir)/gpgmepp/lang/cpp/src/.libs/ -lgpgmepp \
3746 $(if $(filter TRUE,$(DISABLE_DYNLOADING)),-L$(gb_UnpackedTarball_workdir)/gpgmepp/src/.libs/ -lgpgme) \
3747 $(if $(filter TRUE,$(DISABLE_DYNLOADING)),$$(GPG_ERROR_LIBS)) \
3748 $(if $(filter TRUE,$(DISABLE_DYNLOADING)),$$(LIBASSUAN_LIBS)) \
3751 endef
3753 $(eval $(call gb_Helper_register_packages_for_install,ooo,\
3754 gpgmepp \
3755 libassuan \
3756 libgpg-error \
3759 endif
3761 endif
3763 else # !ENABLE_GPGMEPP
3765 gb_ExternalProject__use_gpgmepp :=
3766 gb_ExternalProject__use_libassuan :=
3767 gb_ExternalProject__use_libgpg-error :=
3769 gb_LinkTarget__use_gpgmepp :=
3770 gb_LinkTarget__use_libassuan :=
3771 gb_LinkTarget__use_libgpg-error :=
3773 endif # ENABLE_GPGMEPP
3775 define gb_LinkTarget__use_dconf
3776 $(call gb_LinkTarget_set_include,$(1),\
3777 $$(INCLUDE) \
3778 $(DCONF_CFLAGS) \
3781 $(call gb_LinkTarget_add_libs,$(1),$(DCONF_LIBS))
3782 endef
3784 ### Jars ############################################################
3786 ifneq ($(SYSTEM_HSQLDB),)
3788 define gb_Jar__use_hsqldb
3789 $(call gb_Jar_use_system_jar,$(1),$(HSQLDB_JAR))
3790 endef
3791 define gb_JunitTest__use_hsqldb
3792 $(call gb_JunitTest_use_system_jar,$(1),$(HSQLDB_JAR))
3793 endef
3795 else # !SYSTEM_HSQLDB
3797 ifeq ($(ENABLE_JAVA),TRUE)
3798 $(eval $(call gb_Helper_register_jars_for_install,OOO,ooo, \
3799 hsqldb \
3801 endif
3803 define gb_Jar__use_hsqldb
3804 $(call gb_Jar_use_jar,$(1),hsqldb)
3805 endef
3806 define gb_JunitTest__use_hsqldb
3807 $(call gb_JunitTest_use_jar,$(1),hsqldb)
3808 endef
3810 endif # SYSTEM_HSQLDB
3813 ifeq ($(ENABLE_SCRIPTING_BEANSHELL),TRUE)
3815 ifneq ($(SYSTEM_BSH),)
3817 define gb_Jar__use_bsh
3818 $(call gb_Jar_use_system_jar,$(1),$(BSH_JAR))
3819 endef
3821 else # !SYSTEM_BSH
3823 ifeq ($(ENABLE_JAVA),TRUE)
3824 $(eval $(call gb_Helper_register_jars_for_install,OOO,extensions_bsh, \
3825 bsh \
3827 endif
3829 define gb_Jar__use_bsh
3830 $(call gb_Jar_use_jar,$(1),bsh)
3831 endef
3833 endif # SYSTEM_BSH
3835 endif
3837 ifeq ($(ENABLE_SCRIPTING_JAVASCRIPT),TRUE)
3839 ifneq ($(SYSTEM_RHINO),)
3841 define gb_Jar__use_rhino
3842 $(call gb_Jar_use_system_jar,$(1),$(RHINO_JAR))
3843 endef
3845 else # !SYSTEM_RHINO
3847 ifeq ($(ENABLE_JAVA),TRUE)
3848 $(eval $(call gb_Helper_register_jars_for_install,OOO,extensions_rhino, \
3849 js \
3851 endif
3853 define gb_Jar__use_rhino
3854 $(call gb_Jar_use_jar,$(1),js)
3855 endef
3857 endif # SYSTEM_RHINO
3859 endif
3861 ifneq ($(SYSTEM_JFREEREPORT),)
3863 define gb_Jar__use_flow-engine
3864 $(call gb_Jar_use_system_jar,$(1),$(JFREEREPORT_JAR))
3865 endef
3867 define gb_Jar__use_flute
3868 $(call gb_Jar_use_system_jar,$(1),$(FLUTE_JAR))
3869 endef
3871 define gb_Jar__use_libbase
3872 $(call gb_Jar_use_system_jar,$(1),$(LIBBASE_JAR))
3873 endef
3875 define gb_Jar__use_libfonts
3876 $(call gb_Jar_use_system_jar,$(1),$(LIBFONTS_JAR))
3877 endef
3879 define gb_Jar__use_libformula
3880 $(call gb_Jar_use_system_jar,$(1),$(LIBFORMULA_JAR))
3881 endef
3883 define gb_Jar__use_liblayout
3884 $(call gb_Jar_use_system_jar,$(1),$(LIBLAYOUT_JAR))
3885 endef
3887 define gb_Jar__use_libloader
3888 $(call gb_Jar_use_system_jar,$(1),$(LIBLOADER_JAR))
3889 endef
3891 define gb_Jar__use_librepository
3892 $(call gb_Jar_use_system_jar,$(1),$(LIBREPOSITORY_JAR))
3893 endef
3895 define gb_Jar__use_libserializer
3896 $(call gb_Jar_use_system_jar,$(1),$(LIBSERIALIZER_JAR))
3897 endef
3899 define gb_Jar__use_libxml
3900 $(call gb_Jar_use_system_jar,$(1),$(LIBXML_JAR))
3901 endef
3903 define gb_Jar__use_sac
3904 $(call gb_Jar_use_system_jar,$(1),$(SAC_JAR))
3905 endef
3907 else # !SYSTEM_JFREEREPORT
3909 ifeq ($(ENABLE_JAVA),TRUE)
3910 $(eval $(call gb_Helper_register_jars_for_install,OOO,reportbuilder,\
3911 flow-engine \
3912 flute-1.1.6 \
3913 libbase-1.1.6 \
3914 libfonts-1.1.6 \
3915 libformula-1.1.7 \
3916 liblayout \
3917 libloader-1.1.6 \
3918 librepository-1.1.6 \
3919 libserializer-1.1.6 \
3920 libxml-1.1.7 \
3921 sac \
3923 endif
3925 define gb_Jar__use_flow-engine
3926 $(call gb_Jar_use_jar,$(1),flow-engine)
3927 endef
3929 define gb_Jar__use_flute
3930 $(call gb_Jar_use_jar,$(1),flute-1.1.6)
3931 endef
3933 define gb_Jar__use_libbase
3934 $(call gb_Jar_use_jar,$(1),libbase-1.1.6)
3935 endef
3937 define gb_Jar__use_libfonts
3938 $(call gb_Jar_use_jar,$(1),libfonts-1.1.6)
3939 endef
3941 define gb_Jar__use_libformula
3942 $(call gb_Jar_use_jar,$(1),libformula-1.1.7)
3943 endef
3945 define gb_Jar__use_liblayout
3946 $(call gb_Jar_use_jar,$(1),liblayout)
3947 endef
3949 define gb_Jar__use_libloader
3950 $(call gb_Jar_use_jar,$(1),libloader-1.1.6)
3951 endef
3953 define gb_Jar__use_librepository
3954 $(call gb_Jar_use_jar,$(1),librepository-1.1.6)
3955 endef
3957 define gb_Jar__use_libserializer
3958 $(call gb_Jar_use_jar,$(1),libserializer-1.1.6)
3959 endef
3961 define gb_Jar__use_libxml
3962 $(call gb_Jar_use_jar,$(1),libxml-1.1.7)
3963 endef
3965 define gb_Jar__use_sac
3966 $(call gb_Jar_use_jar,$(1),sac)
3967 endef
3969 endif # SYSTEM_JFREEREPORT
3971 # As a guide, Java-Websocket was packaged for Fedora 35
3972 # https://src.fedoraproject.org/rpms/Java-WebSocket/tree/f35
3973 ifneq ($(SYSTEM_JAVA_WEBSOCKET),)
3975 define gb_Jar__use_java_websocket
3976 $(call gb_Jar_use_system_jar,$(1),$(JAVA_WEBSOCKET_JAR))
3977 endef
3979 else # !SYSTEM_JAVA_WEBSOCKET
3981 ifeq ($(ENABLE_JAVA),TRUE)
3982 $(eval $(call gb_Helper_register_jars_for_install,URE,ure, \
3983 java_websocket \
3985 endif
3987 define gb_Jar__use_java_websocket
3988 $(call gb_Jar_use_jar,$(1),java_websocket)
3989 endef
3991 endif # SYSTEM_JAVA_WEBSOCKET
3993 # Executables
3995 define gb_Executable__register_bestreversemap
3996 $(call gb_Executable_add_runtime_dependencies,bestreversemap,\
3997 $(call gb_CondLibSalTextenc,$(call gb_Library_get_target_for_build,sal_textenc)) \
3999 endef
4001 # TODO depending on the whole URE might be overkill, but I do not have a
4002 # Windows machine to debug it...
4003 define gb_Executable__register_climaker
4004 $(call gb_Executable_add_runtime_dependencies,climaker,\
4005 $(call gb_Library_get_target_for_build,$(CPPU_ENV_FOR_BUILD)_uno) \
4006 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_MISC_FOLDER)/services.rdb \
4007 $(call gb_UnoApi_get_target_for_build,udkapi) \
4008 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_ETC_FOLDER)/$(call gb_Helper_get_rcfile,uno)
4010 endef
4012 define gb_Executable__register_cppumaker
4013 $(call gb_Executable_add_runtime_dependencies,cppumaker,\
4014 $(call gb_CondLibSalTextenc,$(call gb_Library_get_target,sal_textenc)) \
4016 endef
4018 # This is used to determine what we need for 'build' platform.
4019 define gb_Executable__register_gengal
4020 $(call gb_Executable_add_runtime_dependencies,gengal,\
4021 $(call gb_Library_get_target_for_build,$(CPPU_ENV_FOR_BUILD)_uno) \
4022 $(call gb_Library_get_target_for_build,localedata_en) \
4023 $(if $(filter MACOSX,$(OS_FOR_BUILD)),$(call gb_Library_get_target_for_build,vclplug_osx)) \
4024 $(if $(filter WNT,$(OS_FOR_BUILD)),$(call gb_Library_get_target_for_build,vclplug_win)) \
4025 $(if $(filter host,$(gb_Side)),$(call gb_Package_get_target,postprocess_images)) \
4026 $(call gb_Package_get_target_for_build,postprocess_registry) \
4027 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_ETC_FOLDER)/$(call gb_Helper_get_rcfile,uno) \
4028 $(INSTROOT_FOR_BUILD)/$(LIBO_ETC_FOLDER)/$(call gb_Helper_get_rcfile,fundamental) \
4029 $(INSTROOT_FOR_BUILD)/$(LIBO_ETC_FOLDER)/$(call gb_Helper_get_rcfile,louno) \
4030 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_MISC_FOLDER)/services.rdb \
4031 $(INSTROOT_FOR_BUILD)/$(LIBO_ETC_FOLDER)/services/services.rdb \
4032 $(call gb_UnoApi_get_target_for_build,offapi) \
4033 $(call gb_UnoApi_get_target_for_build,udkapi) \
4035 endef
4037 ifeq ($(SYSTEM_ICU),)
4039 define gb_Executable__register_gendict
4040 $(call gb_Executable_add_runtime_dependencies,gendict,\
4041 $(call gb_Package_get_target_for_build,icu) \
4042 $(call gb_Package_get_target_for_build,icu_ure) \
4044 endef
4046 endif
4048 define gb_Executable__register_localize
4049 $(call gb_Executable_add_runtime_dependencies,localize,\
4050 $(foreach exec,cfgex helpex propex treex ulfex xrmex,\
4051 $(call gb_Executable_get_runtime_dependencies,$(exec)) \
4054 endef
4056 # FIXME ure/services.rdb needs cleanup
4057 # The dependencies on ure/services.rdb and udkapi.rdb are implicitly required
4058 # due to the settings for URE_SERVICES and URE_TYPES in cppuhelper/source/unorc:
4059 define gb_Executable__register_saxparser
4060 $(call gb_Executable_add_runtime_dependencies,saxparser,\
4061 $(call gb_Library_get_target_for_build,$(CPPU_ENV_FOR_BUILD)_uno) \
4062 $(call gb_Package_get_target_for_build,instsetoo_native_setup_ure) \
4063 $(call gb_Rdb_get_target_for_build,saxparser) \
4064 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_MISC_FOLDER_FOR_BUILD)/services.rdb \
4065 $(call gb_UnoApi_get_target_for_build,udkapi) \
4067 endef
4069 # NOTE: the dependencies on ure/services.rdb and udkapi.rdb are implicitly
4070 # required due to the settings for URE_SERVICES and URE_TYPES in
4071 # cppuhelper/source/unorc
4072 define gb_Executable__register_uno
4073 $(call gb_Executable_add_runtime_dependencies,uno,\
4074 $(call gb_Library_get_target_for_build,$(CPPU_ENV_FOR_BUILD)_uno) \
4075 $(INSTROOT_FOR_BUILD)/$(LIBO_URE_MISC_FOLDER)/services.rdb \
4076 $(call gb_UnoApi_get_target_for_build,udkapi) \
4078 endef
4081 # External executables
4083 ifneq ($(SYSTEM_LIBXML_FOR_BUILD),)
4085 gb_ExternalExecutable__register_xmllint :=
4087 else # ! SYSTEM_LIBXML_FOR_BUILD
4089 define gb_ExternalExecutable__register_xmllint
4090 $(call gb_ExternalExecutable_set_internal,xmllint,$(WORKDIR_FOR_BUILD)/UnpackedTarball/libxml2/$(if $(filter MSC,$(COM)),win32/bin.msvc)/xmllint$(gb_Executable_EXT_for_build),libxml2)
4091 $(call gb_ExternalExecutable_add_dependencies,xmllint,\
4092 $(if $(filter WNT,$(OS)),$(call gb_Package_get_target,icu_ure)) \
4093 $(call gb_Package_get_target,libxml2) \
4096 endef
4098 endif # SYSTEM_LIBXML_FOR_BUILD
4100 ifneq ($(SYSTEM_LIBXSLT_FOR_BUILD),)
4102 gb_ExternalExecutable__register_xsltproc :=
4104 else # ! SYSTEM_LIBXSLT_FOR_BUILD
4106 define gb_ExternalExecutable__register_xsltproc
4107 $(call gb_ExternalExecutable_set_internal,xsltproc,$(WORKDIR_FOR_BUILD)/UnpackedTarball/libxslt/$(if $(filter MSC,$(COM)),win32/bin.msvc,xsltproc)/xsltproc$(gb_Executable_EXT_for_build),libxslt)
4108 $(call gb_ExternalExecutable_add_dependencies,xsltproc,\
4109 $(if $(filter WNT,$(OS)),$(call gb_Package_get_target,icu_ure)) \
4110 $(call gb_Package_get_target,libxml2) \
4111 $(call gb_Package_get_target,libxslt) \
4114 endef
4116 endif # SYSTEM_LIBXSLT_FOR_BUILD
4118 ifeq (,$(PYTHON_FOR_BUILD))
4120 define gb_ExternalExecutable__register_python
4121 ifeq ($(OS),MACOSX)
4123 # use set_external, to avoid having the command added as prerequisite for the
4124 # targets that make use of it. (Otherwise make will choke as it doesn't have a
4125 # matching rule to build that specific file)
4126 $(call gb_ExternalExecutable_set_external,python,$(gb_UnpackedTarball_workdir)/python3/python-inst/@__________________________________________________OOO/LibreOfficePython.framework/Versions/$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR)/bin/python$(PYTHON_VERSION_MAJOR).$(PYTHON_VERSION_MINOR))
4127 # the Zip ensures that internal python has been built (cannot use the Package
4128 # target, as that is not used on Mac)
4129 $(call gb_ExternalExecutable_add_dependencies,python,$(call gb_GeneratedPackage_get_target_for_build,python3))
4131 else
4133 $(call gb_ExternalExecutable_set_internal,python,$(INSTROOT_FOR_BUILD)/$(LIBO_BIN_FOLDER)/$(if $(filter WNT,$(OS)),python-core-$(PYTHON_VERSION)/bin/python.exe,python.bin))
4134 $(call gb_ExternalExecutable_set_precommand,python,$(subst $$,$$$$,$(gb_Python_PRECOMMAND)))
4135 $(call gb_ExternalExecutable_add_dependencies,python,$(call gb_Package_get_target_for_build,python3))
4137 endif
4139 endef
4141 else
4143 define gb_ExternalExecutable__register_python
4144 $(call gb_ExternalExecutable_set_external,python,$(PYTHON_FOR_BUILD))
4146 endef
4148 endif # PYTHON_FOR_BUILD
4150 ifneq ($(SYSTEM_GENBRK),)
4152 define gb_ExternalExecutable__register_genbrk
4153 $(call gb_ExternalExecutable_set_external,genbrk,$(SYSTEM_GENBRK))
4155 endef
4157 else # ! SYSTEM_GENBRK
4159 define gb_ExternalExecutable__register_genbrk
4160 $(call gb_ExternalExecutable_set_internal,genbrk,$(WORKDIR_FOR_BUILD)/UnpackedTarball/icu/source/bin/genbrk$(gb_Executable_EXT_for_build),icu)
4161 $(call gb_ExternalExecutable_set_precommand,genbrk,$(subst $$,$$$$,$(gb_ICU_PRECOMMAND)))
4162 $(call gb_ExternalExecutable_add_dependencies,genbrk,\
4163 $(call gb_Package_get_target_for_build,icu) \
4164 $(call gb_Package_get_target_for_build,icu_ure) \
4167 endef
4169 endif
4171 ifneq ($(SYSTEM_GENCCODE),)
4173 define gb_ExternalExecutable__register_genccode
4174 $(call gb_ExternalExecutable_set_external,genccode,$(SYSTEM_GENCCODE))
4176 endef
4178 else # ! SYSTEM_GENCCODE
4180 define gb_ExternalExecutable__register_genccode
4181 $(call gb_ExternalExecutable_set_internal,genccode,$(WORKDIR_FOR_BUILD)/UnpackedTarball/icu/source/bin/genccode$(gb_Executable_EXT_for_build),icu)
4182 $(call gb_ExternalExecutable_set_precommand,genccode,$(subst $$,$$$$,$(gb_ICU_PRECOMMAND)))
4183 $(call gb_ExternalExecutable_add_dependencies,genccode,\
4184 $(call gb_Package_get_target_for_build,icu) \
4185 $(call gb_Package_get_target_for_build,icu_ure) \
4188 endef
4190 endif
4192 ifneq ($(SYSTEM_GENCMN),)
4194 define gb_ExternalExecutable__register_gencmn
4195 $(call gb_ExternalExecutable_set_external,gencmn,$(SYSTEM_GENCMN))
4197 endef
4199 else # ! SYSTEM_GENCMN
4201 define gb_ExternalExecutable__register_gencmn
4202 $(call gb_ExternalExecutable_set_internal,gencmn,$(WORKDIR_FOR_BUILD)/UnpackedTarball/icu/source/bin/gencmn$(gb_Executable_EXT_for_build),icu)
4203 $(call gb_ExternalExecutable_set_precommand,gencmn,$(subst $$,$$$$,$(gb_ICU_PRECOMMAND)))
4204 $(call gb_ExternalExecutable_add_dependencies,gencmn,\
4205 $(call gb_Package_get_target_for_build,icu) \
4206 $(call gb_Package_get_target_for_build,icu_ure) \
4209 endef
4211 endif
4213 ifneq ($(SYSTEM_BZIP2),)
4215 define gb_LinkTarget__use_bzip2
4216 $(call gb_LinkTarget_set_include,$(1),\
4217 $(BZIP2_CFLAGS) \
4218 $$(INCLUDE) \
4220 $(call gb_LinkTarget_add_libs,$(1),$(BZIP2_LIBS))
4222 endef
4224 gb_ExternalProject__use_bzip2 :=
4226 else # !SYSTEM_BZIP2
4228 define gb_LinkTarget__use_bzip2
4229 $(call gb_LinkTarget_set_include,$(1),\
4230 -I$(gb_UnpackedTarball_workdir)/bzip2 \
4231 $$(INCLUDE) \
4234 ifeq ($(COM),MSC)
4235 $(call gb_LinkTarget_add_libs,$(1),\
4236 $(gb_UnpackedTarball_workdir)/bzip2/libbz2.lib \
4238 else
4239 $(call gb_LinkTarget_add_libs,$(1),\
4240 -L$(gb_UnpackedTarball_workdir)/bzip2 -lbz2 \
4242 endif
4244 $(call gb_LinkTarget_use_external_project,$(1),bzip2)
4245 endef
4247 define gb_ExternalProject__use_bzip2
4248 $(call gb_ExternalProject_use_external_project,$(1),bzip2)
4249 endef
4251 endif # SYSTEM_BZIP2
4253 define gb_LinkTarget__use_clew
4254 $(call gb_LinkTarget_set_include,$(1), \
4255 -I$(SRCDIR)/external/clew/source/include \
4256 $$(INCLUDE) \
4258 $(call gb_LinkTarget_use_libraries,$(1),clew)
4259 endef
4261 ifneq ($(ENABLE_PDFIUM),)
4262 define gb_LinkTarget__use_pdfium
4263 $(call gb_LinkTarget_set_include,$(1),\
4264 -I$(gb_UnpackedTarball_workdir)/pdfium/public \
4265 -DCOMPONENT_BUILD \
4266 $$(INCLUDE) \
4268 $(call gb_LinkTarget_use_libraries,$(1),pdfium)
4269 endef
4270 $(eval $(call gb_Helper_register_libraries_for_install,OOOLIBS,ooo,\
4271 pdfium \
4273 endif
4275 ifneq ($(SYSTEM_DRAGONBOX),)
4277 define gb_LinkTarget__use_dragonbox
4278 $(call gb_LinkTarget_set_include,$(1),\
4279 $$(INCLUDE) \
4280 $$(DRAGONBOX_CFLAGS) \
4282 endef
4284 else
4286 define gb_LinkTarget__use_dragonbox
4287 $(call gb_LinkTarget_use_unpacked,$(1),dragonbox)
4288 $(call gb_LinkTarget_set_include,$(1),\
4289 -I$(gb_UnpackedTarball_workdir)/dragonbox/include/\
4290 $$(INCLUDE) \
4292 endef
4294 endif
4296 define gb_LinkTarget__use_dtoa
4297 $(call gb_LinkTarget_use_unpacked,$(1),dtoa)
4298 $(call gb_LinkTarget_set_include,$(1),\
4299 -I$(gb_UnpackedTarball_workdir)/dtoa/include/\
4300 $$(INCLUDE) \
4302 $(call gb_LinkTarget_use_static_libraries,$(1),\
4303 dtoa \
4306 endef
4308 define gb_ExternalProject__use_dtoa
4309 $(call gb_ExternalProject_use_static_libraries,$(1),dtoa)
4311 endef
4313 ifneq ($(SYSTEM_BOX2D),)
4315 define gb_LinkTarget__use_box2d
4316 $(call gb_LinkTarget_set_include,$(1),\
4317 -DSYSTEM_BOX2D \
4318 $$(INCLUDE) \
4319 $(BOX2D_CFLAGS) \
4321 $(call gb_LinkTarget_add_libs,$(1),$(BOX2D_LIBS))
4323 endef
4325 gb_ExternalProject__use_box2d :=
4327 else # !SYSTEM_BOX2D
4329 define gb_LinkTarget__use_box2d
4330 $(call gb_LinkTarget_use_unpacked,$(1),box2d)
4331 $(call gb_LinkTarget_set_include,$(1),\
4332 -I$(gb_UnpackedTarball_workdir)/box2d/include/\
4333 $$(INCLUDE) \
4335 $(call gb_LinkTarget_use_static_libraries,$(1),\
4336 box2d \
4339 endef
4341 define gb_ExternalProject__use_box2d
4342 $(call gb_ExternalProject_use_static_libraries,$(1),box2d)
4344 endef
4346 endif # SYSTEM_BOX2D
4348 ifneq ($(SYSTEM_ZXCVBN),)
4349 define gb_LinkTarget__use_zxcvbn-c
4350 $(call gb_LinkTarget_set_include,$(1),\
4351 -DSYSTEM_ZXCVBN \
4352 $$(INCLUDE) \
4354 $(call gb_LinkTarget_add_libs,$(1),-lzxcvbn)
4355 endef
4357 else
4359 define gb_LinkTarget__use_zxcvbn-c
4360 $(call gb_LinkTarget_use_unpacked,$(1),zxcvbn-c)
4361 $(call gb_LinkTarget_set_include,$(1),\
4362 -I$(gb_UnpackedTarball_workdir)/zxcvbn-c\
4363 $$(INCLUDE) \
4365 $(call gb_LinkTarget_use_static_libraries,$(1),\
4366 zxcvbn-c \
4368 endef
4369 endif
4372 ifneq ($(SYSTEM_ZXING),)
4374 define gb_LinkTarget__use_zxing
4375 $(call gb_LinkTarget_set_include,$(1),\
4376 -DSYSTEM_ZXING \
4377 $$(INCLUDE) \
4378 $(ZXING_CFLAGS) \
4380 $(call gb_LinkTarget_add_libs,$(1),$(ZXING_LIBS))
4382 endef
4384 gb_ExternalProject__use_zxing :=
4386 else # !SYSTEM_ZXING
4388 ifneq ($(ENABLE_ZXING),)
4390 define gb_LinkTarget__use_zxing
4391 $(call gb_LinkTarget_use_unpacked,$(1),zxing)
4392 $(call gb_LinkTarget_set_include,$(1),\
4393 -I$(gb_UnpackedTarball_workdir)/zxing/core/src/\
4394 $$(INCLUDE) \
4396 $(call gb_LinkTarget_use_static_libraries,$(1),\
4397 zxing \
4400 endef
4402 define gb_ExternalProject__use_zxing
4403 $(call gb_ExternalProject_use_static_libraries,$(1),zxing)
4405 endef
4407 else # !ENABLE_ZXING
4409 define gb_LinkTarget__use_zxing
4410 endef
4412 endif # ENABLE_ZXING
4414 endif # SYSTEM_ZXING
4417 ifneq ($(SYSTEM_FROZEN),)
4418 define gb_LinkTarget__use_frozen
4419 $(call gb_LinkTarget_set_include,$(1),\
4420 $$(INCLUDE) \
4421 $(FROZEN_CFLAGS)
4423 endef
4424 else
4425 define gb_LinkTarget__use_frozen
4426 $(call gb_LinkTarget_use_unpacked,$(1),frozen)
4427 $(call gb_LinkTarget_set_include,$(1),\
4428 -I$(gb_UnpackedTarball_workdir)/frozen/include/\
4429 $$(INCLUDE) \
4431 endef
4432 endif
4434 # vim: set noet sw=4 ts=4: