| Takeshi Abe | b2bd33e | 2011-08-10 02:12:48 +0900 | [diff] [blame] | 1 | # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 2 | #************************************************************************* |
| 3 | # |
| 4 | # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
| 5 | # |
| 6 | # Copyright 2009 by Sun Microsystems, Inc. |
| 7 | # |
| 8 | # OpenOffice.org - a multi-platform office productivity suite |
| 9 | # |
| 10 | # This file is part of OpenOffice.org. |
| 11 | # |
| 12 | # OpenOffice.org is free software: you can redistribute it and/or modify |
| 13 | # it under the terms of the GNU Lesser General Public License version 3 |
| 14 | # only, as published by the Free Software Foundation. |
| 15 | # |
| 16 | # OpenOffice.org is distributed in the hope that it will be useful, |
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 19 | # GNU Lesser General Public License version 3 for more details |
| 20 | # (a copy is included in the LICENSE file that accompanied this code). |
| 21 | # |
| 22 | # You should have received a copy of the GNU Lesser General Public License |
| 23 | # version 3 along with OpenOffice.org. If not, see |
| 24 | # <http://www.openoffice.org/license.html> |
| 25 | # for a copy of the LGPLv3 License. |
| 26 | # |
| 27 | #************************************************************************* |
| 28 | |
| 29 | # this file describes all the external libraries |
| 30 | # depending on the configure options these may be taken from the system, |
| 31 | # or the internal/bundled copy may be built. |
| 32 | |
| 33 | # for every external, a function gb_LinkTarget_use__FOO is defined, |
| 34 | # once for the system case, once for the internal case. |
| 35 | |
| 36 | # in the system case, no libraries should be registered, but the target-local |
| 37 | # variable LIBS should be set to FOO_LIBS, and INCLUDES to FOO_CFLAGS. |
| 38 | |
| Peter Foley | 1bd2884 | 2011-09-09 17:42:24 -0400 | [diff] [blame] | 39 | ifeq ($(SYSTEM_MESA_HEADERS),YES) |
| 40 | |
| 41 | gb_LinkTarget__use_Mesa:= |
| 42 | |
| 43 | else |
| 44 | |
| 45 | define gb_LinkTarget__use_Mesa |
| 46 | $(eval $(call gb_LinkTarget_add_external_headers,$(1),Mesa_inc)) |
| 47 | endef |
| 48 | |
| 49 | endif |
| 50 | |
| David Tardon | 785e1d9 | 2011-07-25 10:34:22 +0200 | [diff] [blame] | 51 | ifeq ($(SYSTEM_CPPUNIT),YES) |
| 52 | |
| 53 | define gb_LinkTarget__use_cppunit |
| 54 | $(call gb_LinkTarget_set_include,$(1),\ |
| 55 | $$(INCLUDE) \ |
| 56 | $(CPPUNIT_CFLAGS) \ |
| 57 | ) |
| 58 | |
| 59 | $(call gb_LinkTarget_add_libs,$(1),\ |
| 60 | $(CPPUNIT_LIBS) \ |
| 61 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 62 | |
| David Tardon | 785e1d9 | 2011-07-25 10:34:22 +0200 | [diff] [blame] | 63 | endef |
| 64 | |
| 65 | else |
| 66 | |
| 67 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ |
| 68 | cppunit \ |
| 69 | )) |
| 70 | |
| 71 | define gb_LinkTarget__use_cppunit |
| 72 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 73 | cppunit \ |
| 74 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 75 | |
| David Tardon | 785e1d9 | 2011-07-25 10:34:22 +0200 | [diff] [blame] | 76 | endef |
| 77 | |
| 78 | endif |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 79 | |
| 80 | ifeq ($(SYSTEM_ZLIB),YES) |
| 81 | |
| 82 | define gb_LinkTarget__use_zlib |
| Michael Stahl | a88ef23 | 2011-04-13 16:11:41 +0000 | [diff] [blame] | 83 | $(call gb_LinkTarget_add_defs,$(1),\ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 84 | -DSYSTEM_ZLIB \ |
| 85 | ) |
| 86 | $(call gb_LinkTarget_add_libs,$(1),-lz) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 87 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 88 | endef |
| 89 | |
| 90 | else # !SYSTEM_ZLIB |
| 91 | |
| 92 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 93 | zlib \ |
| 94 | )) |
| 95 | |
| 96 | define gb_LinkTarget__use_zlib |
| 97 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 98 | zlib \ |
| 99 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 100 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 101 | endef |
| 102 | |
| 103 | endif # SYSTEM_ZLIB |
| 104 | |
| 105 | |
| 106 | ifeq ($(SYSTEM_JPEG),YES) |
| 107 | |
| 108 | define gb_LinkTarget__use_jpeg |
| 109 | $(call gb_LinkTarget_add_libs,$(1),-ljpeg) |
| 110 | $(call gb_LinkTarget_set_ldflags,$(1),\ |
| Michael Stahl | 73d2fe9 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 111 | $$(filter-out -L/usr/lib/jvm%,$$(T_LDFLAGS)) \ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 112 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 113 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 114 | endef |
| 115 | |
| 116 | else # !SYSTEM_JPEG |
| 117 | |
| 118 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 119 | jpeglib \ |
| 120 | )) |
| 121 | |
| 122 | define gb_LinkTarget__use_jpeg |
| 123 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 124 | jpeglib \ |
| 125 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 126 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 127 | endef |
| 128 | |
| 129 | endif # SYSTEM_JPEG |
| 130 | |
| 131 | |
| 132 | ifeq ($(SYSTEM_EXPAT),YES) |
| 133 | |
| 134 | define gb_LinkTarget__use_expat |
| 135 | $(if $(2),,$(error gb_LinkTarget__use_expat needs additional parameter)) |
| 136 | |
| Michael Stahl | a88ef23 | 2011-04-13 16:11:41 +0000 | [diff] [blame] | 137 | $(call gb_LinkTarget_add_defs,$(1),\ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 138 | -DSYSTEM_EXPAT \ |
| 139 | ) |
| 140 | |
| 141 | $(call gb_LinkTarget_add_libs,$(1),-lexpat) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 142 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 143 | endef |
| 144 | |
| 145 | else # !SYSTEM_EXPAT |
| 146 | |
| 147 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 148 | ascii_expat_xmlparse \ |
| 149 | expat_xmlparse \ |
| 150 | expat_xmltok \ |
| 151 | )) |
| 152 | |
| 153 | define gb_LinkTarget__use_expat |
| 154 | $(if $(2),,$(error gb_LinkTarget__use_expat needs additional parameter)) |
| 155 | |
| 156 | $(if $(filter-out ascii_expat_xmlparse,$(2)),\ |
| Michael Stahl | a88ef23 | 2011-04-13 16:11:41 +0000 | [diff] [blame] | 157 | $(call gb_LinkTarget_add_defs,$(1),\ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 158 | -DXML_UNICODE \ |
| 159 | )) |
| 160 | |
| 161 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 162 | $(2) \ |
| 163 | expat_xmltok \ |
| 164 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 165 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 166 | endef |
| 167 | |
| 168 | endif # SYSTEM_EXPAT |
| 169 | |
| 170 | # now define 2 wrappers that select which internal static library to use... |
| 171 | define gb_LinkTarget__use_expat_utf8 |
| 172 | $(call gb_LinkTarget__use_expat,$(1),ascii_expat_xmlparse) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 173 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 174 | endef |
| 175 | |
| 176 | define gb_LinkTarget__use_expat_utf16 |
| 177 | $(call gb_LinkTarget__use_expat,$(1),expat_xmlparse) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 178 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 179 | endef |
| 180 | |
| 181 | |
| 182 | ifeq ($(SYSTEM_LIBXML),YES) |
| 183 | |
| 184 | define gb_LinkTarget__use_libxml2 |
| Michael Stahl | a88ef23 | 2011-04-13 16:11:41 +0000 | [diff] [blame] | 185 | $(call gb_LinkTarget_add_defs,$(1),\ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 186 | -DSYSTEM_LIBXML \ |
| 187 | ) |
| 188 | $(call gb_LinkTarget_set_include,$(1),\ |
| 189 | $$(INCLUDE) \ |
| 190 | $(LIBXML_CFLAGS) \ |
| 191 | ) |
| 192 | $(call gb_LinkTarget_add_libs,$(1),$(LIBXML_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 193 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 194 | endef |
| 195 | |
| 196 | else # !SYSTEM_LIBXML |
| 197 | |
| 198 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_URE, \ |
| 199 | xml2 \ |
| 200 | )) |
| 201 | |
| 202 | define gb_LinkTarget__use_libxml2 |
| 203 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 204 | xml2 \ |
| 205 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 206 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 207 | endef |
| 208 | |
| 209 | endif # SYSTEM_LIBXML |
| 210 | |
| 211 | |
| 212 | ifeq ($(SYSTEM_LIBXSLT),YES) |
| 213 | |
| 214 | define gb_LinkTarget__use_libxslt |
| 215 | $(call gb_LinkTarget_set_include,$(1),\ |
| 216 | $$(INCLUDE) \ |
| 217 | $(LIBXSLT_CFLAGS) \ |
| 218 | ) |
| 219 | $(call gb_LinkTarget_add_libs,$(1),$(LIBXSLT_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 220 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 221 | endef |
| 222 | |
| 223 | else # !SYSTEM_LIBXSLT |
| 224 | |
| 225 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 226 | xslt \ |
| 227 | )) |
| 228 | |
| 229 | define gb_LinkTarget__use_libxslt |
| 230 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 231 | xslt \ |
| 232 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 233 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 234 | endef |
| 235 | |
| 236 | endif # SYSTEM_LIBXSLT |
| 237 | |
| 238 | |
| 239 | ifeq ($(SYSTEM_REDLAND),YES) |
| 240 | |
| 241 | define gb_LinkTarget__use_librdf |
| Michael Stahl | a88ef23 | 2011-04-13 16:11:41 +0000 | [diff] [blame] | 242 | $(call gb_LinkTarget_add_defs,$(1),\ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 243 | -DSYSTEM_REDLAND \ |
| 244 | ) |
| 245 | $(call gb_LinkTarget_set_include,$(1),\ |
| 246 | $$(INCLUDE) \ |
| 247 | $(REDLAND_CFLAGS) \ |
| 248 | ) |
| 249 | $(call gb_LinkTarget_add_libs,$(1),$(REDLAND_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 250 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 251 | endef |
| 252 | |
| 253 | else # !SYSTEM_REDLAND |
| 254 | |
| 255 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 256 | rdf \ |
| 257 | )) |
| 258 | |
| 259 | define gb_LinkTarget__use_librdf |
| 260 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 261 | rdf \ |
| 262 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 263 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 264 | endef |
| 265 | |
| 266 | endif # SYSTEM_REDLAND |
| 267 | |
| 268 | |
| 269 | ifeq ($(SYSTEM_CAIRO),YES) |
| 270 | |
| 271 | # FREETYPE_CLAGS from environment if ENABLE_CAIRO is used |
| 272 | define gb_LinkTarget__use_cairo |
| 273 | $(call gb_LinkTarget_set_include,$(1),\ |
| 274 | $$(INCLUDE) \ |
| 275 | $(FREETYPE_CFLAGS) \ |
| 276 | $(CAIRO_CFLAGS) \ |
| 277 | ) |
| 278 | $(call gb_LinkTarget_add_libs,$(1),$(CAIRO_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 279 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 280 | endef |
| 281 | |
| 282 | else # !SYSTEM_CAIRO |
| 283 | |
| 284 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 285 | cairo \ |
| 286 | )) |
| 287 | ifneq ($(OS),WNT) |
| 288 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 289 | pixman-1 \ |
| 290 | )) |
| 291 | endif # WNT |
| 292 | |
| 293 | define gb_LinkTarget__use_cairo |
| 294 | $(call gb_LinkTarget_set_include,$(1),\ |
| 295 | $$(INCLUDE) \ |
| 296 | -I$(OUTDIR)/inc/cairo \ |
| 297 | $(FREETYPE_CFLAGS) \ |
| 298 | ) |
| 299 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 300 | cairo \ |
| 301 | ) |
| 302 | ifneq ($(OS),WNT) |
| Norbert Thiebaud | ae70a17 | 2011-07-24 16:00:24 -0500 | [diff] [blame] | 303 | ifeq ($(OS),MACOSX) |
| 304 | $(call gb_LinkTarget_add_static_libs,$(1),\ |
| 305 | pixman-1 \ |
| 306 | ) |
| 307 | else |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 308 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 309 | pixman-1 \ |
| 310 | ) |
| 311 | endif |
| Norbert Thiebaud | ae70a17 | 2011-07-24 16:00:24 -0500 | [diff] [blame] | 312 | endif |
| Caolán McNamara | 5bb76f6 | 2011-07-25 21:50:34 +0100 | [diff] [blame] | 313 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 314 | endef |
| 315 | |
| 316 | endif # SYSTEM_CAIRO |
| 317 | |
| Caolán McNamara | b41ae46 | 2011-07-25 22:24:27 +0100 | [diff] [blame] | 318 | define gb_LinkTarget__use_freetype |
| 319 | $(call gb_LinkTarget_set_include,$(1),\ |
| 320 | $$(INCLUDE) \ |
| 321 | $(FREETYPE_CFLAGS) \ |
| 322 | ) |
| 323 | $(call gb_LinkTarget_add_libs,$(1),$(FREETYPE_LIBS)) |
| 324 | |
| 325 | endef |
| 326 | |
| 327 | define gb_LinkTarget__use_fontconfig |
| 328 | $(call gb_LinkTarget_set_include,$(1),\ |
| 329 | $$(INCLUDE) \ |
| 330 | $(FONTCONFIG_CFLAGS) \ |
| 331 | ) |
| 332 | $(call gb_LinkTarget_add_libs,$(1),$(FONTCONFIG_LIBS)) |
| 333 | |
| 334 | endef |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 335 | |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 336 | ifeq ($(SYSTEM_GRAPHITE),YES) |
| 337 | |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 338 | define gb_LinkTarget__use_graphite |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 339 | $(call gb_LinkTarget_set_include,$(1),\ |
| 340 | $$(INCLUDE) \ |
| 341 | $(GRAPHITE_CFLAGS) \ |
| 342 | ) |
| 343 | $(call gb_LinkTarget_add_libs,$(1),$(GRAPHITE_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 344 | |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 345 | endef |
| 346 | |
| 347 | else # !SYSTEM_GRAPHITE |
| 348 | |
| 349 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| Bjoern Michaelsen | 902f9da | 2011-06-20 13:24:08 +0200 | [diff] [blame] | 350 | graphite2_off \ |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 351 | )) |
| 352 | define gb_LinkTarget__use_graphite |
| 353 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| Bjoern Michaelsen | 902f9da | 2011-06-20 13:24:08 +0200 | [diff] [blame] | 354 | graphite2_off \ |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 355 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 356 | |
| Michael Stahl | 87e4433 | 2011-04-13 16:11:39 +0000 | [diff] [blame] | 357 | endef |
| 358 | |
| 359 | endif # SYSTEM_GRAPHITE |
| 360 | |
| 361 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 362 | ifeq ($(SYSTEM_ICU),YES) |
| 363 | |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 364 | define gb_LinkTarget__use_icudata |
| 365 | $(call gb_LinkTarget_add_libs,$(1),-licudata) |
| 366 | |
| 367 | endef |
| David Tardon | 1a85239 | 2011-07-26 09:58:54 +0200 | [diff] [blame] | 368 | define gb_LinkTarget__use_icui18n |
| 369 | $(call gb_LinkTarget_add_libs,$(1),-licui18n) |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 370 | |
| David Tardon | 1a85239 | 2011-07-26 09:58:54 +0200 | [diff] [blame] | 371 | endef |
| Michael Stahl | e199938 | 2011-04-13 16:11:40 +0000 | [diff] [blame] | 372 | define gb_LinkTarget__use_icule |
| 373 | $(call gb_LinkTarget_add_libs,$(1),-licule) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 374 | |
| Michael Stahl | e199938 | 2011-04-13 16:11:40 +0000 | [diff] [blame] | 375 | endef |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 376 | define gb_LinkTarget__use_icutu |
| 377 | $(call gb_LinkTarget_add_libs,$(1),-licutu) |
| 378 | |
| 379 | endef |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 380 | define gb_LinkTarget__use_icuuc |
| 381 | $(call gb_LinkTarget_add_libs,$(1),-licuuc) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 382 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 383 | endef |
| 384 | |
| 385 | else # !SYSTEM_ICU |
| 386 | |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 387 | ifeq ($(OS),ANDROID) |
| 388 | gb_ICU_suffix:=lo |
| 389 | else |
| 390 | gb_ICU_suffix:= |
| 391 | endif |
| 392 | |
| Tor Lillqvist | bdfca5e | 2011-08-19 12:38:09 +0300 | [diff] [blame] | 393 | # icudata and icui18n is called icudt and icuin when built with MSVC :-( |
| 394 | ifeq ($(OS)$(COM),WNTMSC) |
| Jan Holesovsky | 534b3bc | 2011-08-19 09:32:18 +0200 | [diff] [blame] | 395 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 396 | icudt \ |
| 397 | icuin \ |
| 398 | icule \ |
| 399 | icutu \ |
| 400 | icuuc \ |
| 401 | )) |
| 402 | |
| 403 | define gb_LinkTarget__use_icudt |
| 404 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 405 | icudt \ |
| 406 | ) |
| 407 | |
| 408 | endef |
| 409 | define gb_LinkTarget__use_icuin |
| 410 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 411 | icuin \ |
| 412 | ) |
| 413 | |
| 414 | endef |
| 415 | else |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 416 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 417 | icudata$(gb_ICU_suffix) \ |
| 418 | icui18n$(gb_ICU_suffix) \ |
| 419 | icule$(gb_ICU_suffix) \ |
| 420 | icutu$(gb_ICU_suffix) \ |
| 421 | icuuc$(gb_ICU_suffix) \ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 422 | )) |
| 423 | |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 424 | define gb_LinkTarget__use_icudata |
| 425 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 426 | icudata$(gb_ICU_suffix) \ |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 427 | ) |
| 428 | |
| 429 | endef |
| David Tardon | 1a85239 | 2011-07-26 09:58:54 +0200 | [diff] [blame] | 430 | define gb_LinkTarget__use_icui18n |
| 431 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 432 | icui18n$(gb_ICU_suffix) \ |
| David Tardon | 1a85239 | 2011-07-26 09:58:54 +0200 | [diff] [blame] | 433 | ) |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 434 | |
| David Tardon | 1a85239 | 2011-07-26 09:58:54 +0200 | [diff] [blame] | 435 | endef |
| Jan Holesovsky | 534b3bc | 2011-08-19 09:32:18 +0200 | [diff] [blame] | 436 | endif |
| 437 | |
| Michael Stahl | e199938 | 2011-04-13 16:11:40 +0000 | [diff] [blame] | 438 | define gb_LinkTarget__use_icule |
| 439 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 440 | icule$(gb_ICU_suffix) \ |
| Michael Stahl | e199938 | 2011-04-13 16:11:40 +0000 | [diff] [blame] | 441 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 442 | |
| Michael Stahl | e199938 | 2011-04-13 16:11:40 +0000 | [diff] [blame] | 443 | endef |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 444 | define gb_LinkTarget__use_icutu |
| 445 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 446 | icutu$(gb_ICU_suffix) \ |
| Matúš Kukan | 6fad175 | 2011-08-11 12:42:39 +0200 | [diff] [blame] | 447 | ) |
| 448 | |
| 449 | endef |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 450 | define gb_LinkTarget__use_icuuc |
| 451 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Tor Lillqvist | 8a3ea75 | 2011-11-21 14:25:37 +0200 | [diff] [blame] | 452 | icuuc$(gb_ICU_suffix) \ |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 453 | ) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 454 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 455 | endef |
| 456 | |
| 457 | endif # SYSTEM_ICU |
| 458 | |
| Michael Stahl | 4a8919f | 2011-04-18 11:13:57 +0000 | [diff] [blame] | 459 | |
| 460 | ifeq ($(SYSTEM_OPENSSL),YES) |
| 461 | |
| 462 | define gb_LinkTarget__use_openssl |
| 463 | $(call gb_LinkTarget_set_include,$(1),\ |
| 464 | $$(INCLUDE) \ |
| 465 | $(OPENSSL_CFLAGS) \ |
| 466 | ) |
| 467 | $(call gb_LinkTarget_add_libs,$(1),$(OPENSSL_LIBS)) |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 468 | |
| Michael Stahl | 4a8919f | 2011-04-18 11:13:57 +0000 | [diff] [blame] | 469 | endef |
| 470 | |
| 471 | else # !SYSTEM_OPENSSL |
| 472 | |
| 473 | ifeq ($(OS),WNT) |
| 474 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 475 | crypto \ |
| 476 | ssl \ |
| 477 | )) |
| 478 | else |
| 479 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 480 | crypto \ |
| 481 | ssl \ |
| 482 | )) |
| 483 | endif |
| 484 | |
| 485 | define gb_LinkTarget__use_openssl |
| 486 | ifeq ($(OS),WNT) |
| 487 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 488 | crypto \ |
| 489 | ssl \ |
| 490 | ) |
| 491 | else |
| 492 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 493 | crypto \ |
| 494 | ssl \ |
| 495 | ) |
| 496 | ifeq ($(OS),SOLARIS) |
| 497 | $(call gb_LinkTarget_add_libs,$(1),\ |
| 498 | -lnsl \ |
| 499 | -lsocket \ |
| 500 | ) |
| 501 | endif |
| 502 | endif |
| Caolán McNamara | 6bccd20 | 2011-07-25 22:10:33 +0100 | [diff] [blame] | 503 | |
| Michael Stahl | 4a8919f | 2011-04-18 11:13:57 +0000 | [diff] [blame] | 504 | endef |
| 505 | |
| 506 | endif # SYSTEM_OPENSSL |
| 507 | |
| Matúš Kukan | c456048 | 2011-07-28 01:03:23 +0200 | [diff] [blame] | 508 | |
| Matúš Kukan | c6a6395 | 2011-07-28 17:29:44 +0200 | [diff] [blame] | 509 | ifeq ($(SYSTEM_LIBVISIO),YES) |
| 510 | |
| 511 | define gb_LinkTarget__use_visio |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 512 | $(call gb_LinkTarget_set_include,$(1),\ |
| 513 | $$(INCLUDE) \ |
| Fridrich Štrba | e531e8a | 2011-10-05 10:21:08 +0200 | [diff] [blame] | 514 | $(VISIO_CFLAGS) \ |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 515 | ) |
| Fridrich Štrba | e531e8a | 2011-10-05 10:21:08 +0200 | [diff] [blame] | 516 | $(call gb_LinkTarget_add_libs,$(1),$(VISIO_LIBS)) |
| Matúš Kukan | c6a6395 | 2011-07-28 17:29:44 +0200 | [diff] [blame] | 517 | |
| 518 | endef |
| 519 | |
| 520 | else # !SYSTEM_LIBVISIO |
| 521 | |
| 522 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 523 | visiolib \ |
| 524 | )) |
| 525 | |
| 526 | define gb_LinkTarget__use_visio |
| 527 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 528 | visiolib \ |
| 529 | ) |
| 530 | |
| 531 | endef |
| 532 | |
| 533 | endif # SYSTEM_LIBVISIO |
| 534 | |
| 535 | |
| 536 | ifeq ($(SYSTEM_LIBWPD),YES) |
| 537 | |
| 538 | define gb_LinkTarget__use_wpd |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 539 | $(call gb_LinkTarget_set_include,$(1),\ |
| 540 | $$(INCLUDE) \ |
| Fridrich Štrba | 8703f3e | 2011-10-05 10:04:04 +0200 | [diff] [blame] | 541 | $(WPD_CFLAGS) \ |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 542 | ) |
| Fridrich Štrba | 8703f3e | 2011-10-05 10:04:04 +0200 | [diff] [blame] | 543 | $(call gb_LinkTarget_add_libs,$(1),$(WPD_LIBS)) |
| Matúš Kukan | c6a6395 | 2011-07-28 17:29:44 +0200 | [diff] [blame] | 544 | |
| 545 | endef |
| 546 | |
| 547 | else # !SYSTEM_LIBWPD |
| 548 | |
| 549 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 550 | wpdlib \ |
| 551 | )) |
| 552 | |
| 553 | define gb_LinkTarget__use_wpd |
| 554 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 555 | wpdlib \ |
| 556 | ) |
| 557 | |
| 558 | endef |
| 559 | |
| 560 | endif # SYSTEM_LIBWPD |
| 561 | |
| 562 | |
| 563 | ifeq ($(SYSTEM_LIBWPG),YES) |
| 564 | |
| 565 | define gb_LinkTarget__use_wpg |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 566 | $(call gb_LinkTarget_set_include,$(1),\ |
| 567 | $$(INCLUDE) \ |
| Fridrich Štrba | 62c43b4 | 2011-10-05 10:15:40 +0200 | [diff] [blame] | 568 | $(WPG_CFLAGS) \ |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 569 | ) |
| Fridrich Štrba | 62c43b4 | 2011-10-05 10:15:40 +0200 | [diff] [blame] | 570 | $(call gb_LinkTarget_add_libs,$(1),$(WPG_LIBS)) |
| Matúš Kukan | c6a6395 | 2011-07-28 17:29:44 +0200 | [diff] [blame] | 571 | |
| 572 | endef |
| 573 | |
| 574 | else # !SYSTEM_LIBWPG |
| 575 | |
| 576 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 577 | wpglib \ |
| 578 | )) |
| 579 | |
| 580 | define gb_LinkTarget__use_wpg |
| 581 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 582 | wpglib \ |
| 583 | ) |
| 584 | |
| 585 | endef |
| 586 | |
| 587 | endif # SYSTEM_LIBWPG |
| 588 | |
| 589 | |
| 590 | ifeq ($(SYSTEM_LIBWPS),YES) |
| 591 | |
| 592 | define gb_LinkTarget__use_wps |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 593 | $(call gb_LinkTarget_set_include,$(1),\ |
| 594 | $$(INCLUDE) \ |
| Fridrich Štrba | e991bba | 2011-10-05 10:18:53 +0200 | [diff] [blame] | 595 | $(WPS_CFLAGS) \ |
| Lionel Elie Mamane | e4a1779 | 2011-08-02 07:10:30 +0200 | [diff] [blame] | 596 | ) |
| Fridrich Štrba | e991bba | 2011-10-05 10:18:53 +0200 | [diff] [blame] | 597 | $(call gb_LinkTarget_add_libs,$(1),$(WPS_LIBS)) |
| Matúš Kukan | c6a6395 | 2011-07-28 17:29:44 +0200 | [diff] [blame] | 598 | |
| 599 | endef |
| 600 | |
| 601 | else # !SYSTEM_LIBWPS |
| 602 | |
| 603 | $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ |
| 604 | wpslib \ |
| 605 | )) |
| 606 | |
| 607 | define gb_LinkTarget__use_wps |
| 608 | $(call gb_LinkTarget_add_linked_static_libs,$(1),\ |
| 609 | wpslib \ |
| 610 | ) |
| 611 | |
| 612 | endef |
| 613 | |
| 614 | endif # SYSTEM_LIBWPS |
| 615 | |
| 616 | |
| Matúš Kukan | c456048 | 2011-07-28 01:03:23 +0200 | [diff] [blame] | 617 | ifeq ($(SYSTEM_LPSOLVE),YES) |
| 618 | |
| 619 | define gb_LinkTarget__use_lpsolve55 |
| 620 | $(call gb_LinkTarget_add_libs,$(1),-llpsolve55) |
| 621 | |
| 622 | endef |
| 623 | |
| 624 | else # !SYSTEM_LPSOLVE |
| 625 | |
| 626 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \ |
| 627 | lpsolve55 \ |
| 628 | )) |
| 629 | |
| 630 | define gb_LinkTarget__use_lpsolve55 |
| 631 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 632 | lpsolve55 \ |
| 633 | ) |
| 634 | |
| 635 | endef |
| 636 | |
| 637 | endif # SYSTEM_LPSOLVE |
| 638 | |
| 639 | |
| Bjoern Michaelsen | e7cc9e0 | 2011-07-26 14:51:35 +0200 | [diff] [blame] | 640 | define gb_LinkTarget__use_gtk |
| 641 | $(call gb_LinkTarget_set_include,$(1),\ |
| 642 | $$(INCLUDE) \ |
| 643 | $(GTK_CFLAGS) \ |
| 644 | ) |
| 645 | |
| 646 | $(call gb_LinkTarget_add_libs,$(1),$(GTK_LIBS)) |
| 647 | |
| David Tardon | adb1105 | 2011-12-01 13:39:09 +0100 | [diff] [blame] | 648 | ifeq ($(ENABLE_GTK_PRINT),TRUE) |
| 649 | |
| 650 | $(call gb_LinkTarget_add_defs,$(1),-DENABLE_GTK_PRINT) |
| 651 | |
| 652 | $(call gb_LinkTarget_set_include,$(1),\ |
| 653 | $$(INCLUDE) \ |
| 654 | $(GTK_PRINT_CFLAGS) \ |
| 655 | ) |
| 656 | |
| 657 | $(call gb_LinkTarget_add_libs,$(1),$(GTK_PRINT_LIBS)) |
| 658 | |
| 659 | endif |
| 660 | |
| Bjoern Michaelsen | e7cc9e0 | 2011-07-26 14:51:35 +0200 | [diff] [blame] | 661 | endef |
| Michael Stahl | 4a8919f | 2011-04-18 11:13:57 +0000 | [diff] [blame] | 662 | |
| Bjoern Michaelsen | 54dd307 | 2011-07-26 15:15:41 +0200 | [diff] [blame] | 663 | define gb_LinkTarget__use_gthread |
| 664 | $(call gb_LinkTarget_add_libs,$(1),$(GTHREAD_LIBS)) |
| 665 | |
| 666 | endef |
| 667 | |
| David Tardon | 1b717ce | 2011-11-02 13:00:48 +0100 | [diff] [blame] | 668 | |
| 669 | ifeq ($(ENABLE_DBUS),YES) |
| 670 | |
| 671 | define gb_LinkTarget__use_dbus |
| 672 | $(call gb_LinkTarget_set_include,$(1),\ |
| 673 | $$(INCLUDE) \ |
| 674 | $(DBUS_CFLAGS) \ |
| 675 | ) |
| 676 | |
| 677 | $(call gb_Library_add_defs,$(1),\ |
| 678 | -DENABLE_DBUS \ |
| 679 | ) |
| 680 | |
| 681 | $(call gb_LinkTarget_add_libs,$(1),\ |
| 682 | $(DBUS_LIBS) \ |
| 683 | ) |
| 684 | |
| 685 | endef |
| 686 | |
| 687 | else # ENABLE_DBUS |
| 688 | |
| 689 | define gb_LinkTarget__use_dbus |
| 690 | |
| 691 | endef |
| 692 | |
| 693 | endif # ENABLE_DBUS |
| 694 | |
| 695 | |
| Bjoern Michaelsen | dd32106 | 2011-07-26 16:04:15 +0200 | [diff] [blame] | 696 | define gb_LinkTarget__use_dbusmenugtk |
| 697 | $(call gb_LinkTarget_set_include,$(1),\ |
| 698 | $$(INCLUDE) \ |
| 699 | $(DBUSMENUGTK_CFLAGS) \ |
| 700 | ) |
| 701 | |
| 702 | $(call gb_LinkTarget_add_libs,$(1),$(DBUSMENUGTK_LIBS)) |
| 703 | |
| 704 | endef |
| 705 | |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 706 | ifeq ($(SYSTEM_DB),YES) |
| 707 | |
| 708 | define gb_LinkTarget__use_berkeleydb |
| 709 | $(call gb_LinkTarget_set_include,$(1),\ |
| 710 | $$(INCLUDE) \ |
| 711 | $(filter -I%,$(SYSTEM_DB_CFLAGS)) \ |
| 712 | ) |
| 713 | |
| 714 | $(call gb_LinkTarget_add_defs,$(1),\ |
| 715 | $(filter -D%,$(SYSTEM_DB_CFLAGS)) \ |
| 716 | ) |
| 717 | |
| 718 | $(call gb_LinkTarget_add_libs,$(1),\ |
| 719 | -l$(DB_LIB) \ |
| 720 | ) |
| 721 | |
| 722 | endef |
| 723 | |
| 724 | else # !SYSTEM_DB |
| 725 | |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 726 | ifneq ($(OS),WNT) |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 727 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 728 | db-4.7 \ |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 729 | )) |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 730 | else |
| 731 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ |
| 732 | db47 \ |
| 733 | )) |
| 734 | endif |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 735 | |
| 736 | define gb_LinkTarget__use_berkeleydb |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 737 | ifneq ($(OS),WNT) |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 738 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 739 | db-4.7 \ |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 740 | ) |
| Caolán McNamara | a0831a17 | 2011-09-15 21:27:13 +0100 | [diff] [blame] | 741 | else |
| 742 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 743 | db47 \ |
| 744 | ) |
| 745 | endif |
| David Tardon | 6df9c47 | 2011-09-15 14:44:34 +0200 | [diff] [blame] | 746 | |
| 747 | endef |
| 748 | |
| 749 | endif # SYSTEM_DB |
| 750 | |
| 751 | ifeq ($(SYSTEM_LIBPNG),YES) |
| 752 | |
| 753 | define gb_LinkTarget__use_png |
| 754 | $(call gb_LinkTarget_set_include,$(1),\ |
| 755 | $$(INCLUDE) \ |
| 756 | $(LIBPNG_CFLAGS) \ |
| 757 | ) |
| 758 | |
| 759 | $(call gb_LinkTarget_add_libs,$(1),\ |
| 760 | $(LIBPNG_LIBS) \ |
| 761 | ) |
| 762 | |
| 763 | endef |
| 764 | |
| 765 | else # !SYSTEM_LIBPNG |
| 766 | |
| 767 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ |
| 768 | png \ |
| 769 | )) |
| 770 | |
| 771 | define gb_LinkTarget__use_png |
| 772 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 773 | png \ |
| 774 | ) |
| 775 | |
| 776 | endef |
| 777 | |
| 778 | endif # !SYSTEM_LIBPNG |
| 779 | |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 780 | # MacOSX-only frameworks |
| 781 | # (in alphabetical order) |
| Bjoern Michaelsen | 92ac3ae | 2011-07-26 16:32:29 +0200 | [diff] [blame] | 782 | |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 783 | define gb_LinkTarget__use_carbon |
| Bjoern Michaelsen | fe1efb9 | 2011-07-26 18:07:15 +0200 | [diff] [blame] | 784 | $(call gb_LinkTarget_add_libs,$(1), \ |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 785 | -framework Carbon \ |
| Tor Lillqvist | ff88a5f | 2011-07-26 22:44:10 +0300 | [diff] [blame] | 786 | ) |
| 787 | |
| 788 | endef |
| 789 | |
| Bjoern Michaelsen | 92ac3ae | 2011-07-26 16:32:29 +0200 | [diff] [blame] | 790 | define gb_LinkTarget__use_cocoa |
| Bjoern Michaelsen | fe1efb9 | 2011-07-26 18:07:15 +0200 | [diff] [blame] | 791 | $(call gb_LinkTarget_add_libs,$(1), \ |
| Bjoern Michaelsen | 92ac3ae | 2011-07-26 16:32:29 +0200 | [diff] [blame] | 792 | -framework Cocoa \ |
| 793 | ) |
| 794 | |
| 795 | endef |
| 796 | |
| Matúš Kukan | e85875b | 2011-08-03 15:08:56 +0200 | [diff] [blame] | 797 | define gb_LinkTarget__use_qtkit |
| 798 | $(call gb_LinkTarget_add_libs,$(1), \ |
| 799 | -framework QTKit \ |
| 800 | ) |
| 801 | |
| 802 | endef |
| 803 | |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 804 | define gb_LinkTarget__use_quicktime |
| Bjoern Michaelsen | fe1efb9 | 2011-07-26 18:07:15 +0200 | [diff] [blame] | 805 | $(call gb_LinkTarget_add_libs,$(1), \ |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 806 | -framework QuickTime \ |
| Bjoern Michaelsen | 92ac3ae | 2011-07-26 16:32:29 +0200 | [diff] [blame] | 807 | ) |
| 808 | |
| 809 | endef |
| 810 | |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 811 | # Common MacOSX and iOS frameworks |
| 812 | |
| 813 | define gb_LinkTarget__use_corefoundation |
| Bjoern Michaelsen | fe1efb9 | 2011-07-26 18:07:15 +0200 | [diff] [blame] | 814 | $(call gb_LinkTarget_add_libs,$(1), \ |
| Tor Lillqvist | 2a96158 | 2011-08-02 22:19:35 +0300 | [diff] [blame] | 815 | -framework CoreFoundation \ |
| 816 | ) |
| 817 | |
| 818 | endef |
| 819 | |
| 820 | define gb_LinkTarget__use_coregraphics |
| 821 | $(call gb_Library_add_libs,$(1), \ |
| 822 | -framework CoreGraphics \ |
| 823 | ) |
| 824 | |
| 825 | endef |
| 826 | |
| 827 | define gb_LinkTarget__use_coretext |
| 828 | $(call gb_Library_add_libs,$(1), \ |
| 829 | -framework CoreText \ |
| 830 | ) |
| 831 | |
| 832 | endef |
| 833 | |
| 834 | define gb_LinkTarget__use_foundation |
| 835 | $(call gb_LinkTarget_add_libs,$(1), \ |
| 836 | -framework Foundation \ |
| 837 | ) |
| 838 | |
| 839 | endef |
| 840 | |
| 841 | # iOS-only frameworks |
| 842 | |
| 843 | define gb_LinkTarget__use_uikit |
| 844 | $(call gb_LinkTarget_add_libs,$(1), \ |
| 845 | -framework UIKit \ |
| Bjoern Michaelsen | 92ac3ae | 2011-07-26 16:32:29 +0200 | [diff] [blame] | 846 | ) |
| 847 | |
| 848 | endef |
| Tor Lillqvist | 3549107 | 2011-08-02 21:22:35 +0300 | [diff] [blame] | 849 | |
| Tomas Chvatal | 75f77e6 | 2011-11-02 21:16:53 +0100 | [diff] [blame] | 850 | ifeq ($(SYSTEM_NSS),YES) |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 851 | |
| 852 | define gb_LinkTarget__use_plc4 |
| 853 | $(call gb_LinkTarget_set_include,$(1),\ |
| 854 | $$(INCLUDE) \ |
| Tomas Chvatal | 75f77e6 | 2011-11-02 21:16:53 +0100 | [diff] [blame] | 855 | $(NSS_CFLAGS) \ |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 856 | ) |
| 857 | |
| 858 | $(call gb_LinkTarget_add_libs,$(1),\ |
| Tomas Chvatal | 75f77e6 | 2011-11-02 21:16:53 +0100 | [diff] [blame] | 859 | $(NSS_LIBS) \ |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 860 | ) |
| Caolán McNamara | 24ae3ab | 2011-08-11 12:47:00 +0100 | [diff] [blame] | 861 | |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 862 | endef |
| 863 | |
| 864 | else |
| 865 | |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 866 | $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO,\ |
| 867 | nspr4 \ |
| 868 | nss3 \ |
| 869 | plc4 \ |
| 870 | )) |
| 871 | |
| Caolán McNamara | 24ae3ab | 2011-08-11 12:47:00 +0100 | [diff] [blame] | 872 | define gb_LinkTarget__use_plc4 |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 873 | $(call gb_LinkTarget_add_linked_libs,$(1),\ |
| 874 | plc4 \ |
| 875 | ) |
| Caolán McNamara | 24ae3ab | 2011-08-11 12:47:00 +0100 | [diff] [blame] | 876 | |
| David Tardon | b6aa484 | 2011-08-11 13:10:14 +0200 | [diff] [blame] | 877 | endef |
| 878 | |
| 879 | endif |
| 880 | |
| Michael Stahl | 2ee5f24 | 2011-09-15 14:01:27 +0200 | [diff] [blame] | 881 | ### Jars ############################################################ |
| 882 | |
| 883 | ifeq ($(SYSTEM_SAXON),YES) |
| 884 | |
| 885 | define gb_JavaClassSet__use_saxon |
| 886 | $(call gb_JavaClassSet_add_system_jar,$(1),$(SAXON_JAR)) |
| 887 | endef |
| 888 | |
| 889 | else # !SYSTEM_SAXON |
| 890 | |
| 891 | define gb_JavaClassSet__use_saxon |
| 892 | $(call gb_JavaClassSet_add_jar,$(1),$(OUTDIR)/bin/saxon9.jar) |
| 893 | endef |
| 894 | |
| 895 | endif # SYSTEM_SAXON |
| 896 | |
| David Tardon | 3bcf910 | 2011-10-04 09:44:48 +0200 | [diff] [blame] | 897 | ifeq ($(SYSTEM_BSH),YES) |
| 898 | |
| 899 | define gb_JavaClassSet__use_bsh |
| 900 | $(call gb_JavaClassSet_add_system_jar,$(1),$(BSH_JAR)) |
| 901 | endef |
| 902 | |
| 903 | else # !SYSTEM_BSH |
| 904 | |
| 905 | define gb_JavaClassSet__use_bsh |
| 906 | $(call gb_JavaClassSet_add_jar,$(1),$(OUTDIR)/bin/bsh.jar) |
| 907 | endef |
| 908 | |
| 909 | endif # SYSTEM_BSH |
| 910 | |
| Michael Stahl | 2ee5f24 | 2011-09-15 14:01:27 +0200 | [diff] [blame] | 911 | |
| Michael Stahl | c74af0d | 2011-04-01 20:49:35 +0000 | [diff] [blame] | 912 | # vim: set noet sw=4 ts=4: |