2 # Copyright 2012 LibreOffice contributors.
4 # This Source Code Form is subject to the terms of the Mozilla Public
5 # License, v. 2.0. If a copy of the MPL was not distributed with this
6 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
17 # Currently liblangtag.so.0.1.0 is generated instead of 0.2.0, presumably a bug?
18 # For new versions adapt symlink in prj/d.lst
20 # --- Settings -----------------------------------------------------
22 .INCLUDE
: settings.mk
24 # --- Files --------------------------------------------------------
26 .IF
"$(SYSTEM_LIBLANGTAG)" == "YES"
28 @echo
"Using system liblangtag."
31 TARFILE_NAME
=liblangtag-
$(LIBLANGTAG_MAJOR
).
$(LIBLANGTAG_MINOR
)
32 TARFILE_MD5
=fa6a2f85bd28baab035b2c95e722713f
34 # liblangtag 132170753ea9cbd63cda8f3a80498c144f75b8ba
35 PATCH_FILES
=liblangtag-0.2
-0001-Fix-a-memory-leak.patch
36 # liblangtag cf8dfcf1604e534f4c9eccbd9a05571c8a9dc74d
37 PATCH_FILES
+=liblangtag-0.2
-0002-Fix-invalid-memory-access.patch
38 PATCH_FILES
+=liblangtag-0.2
-configure.patch
39 PATCH_FILES
+=liblangtag-0.2
-datadir.patch
40 PATCH_FILES
+=liblangtag-0.2
-xmlCleanupParser.patch
43 BUILD_DIR
=$(CONFIGURE_DIR
)
45 CONFIGURE_FLAGS
+= --prefix=$(SRC_ROOT
)$/$(PRJNAME
)$/$(MISC
)$/install
47 .IF
"$(SYSTEM_LIBXML)"!="YES"
48 CONFIGURE_FLAGS
+= LIBXML2_CFLAGS
='-I$(SOLARINCDIR)$/external$/libxml'
49 .IF
"$(GUI)"=="WNT" && "$(COM)"!="GCC"
50 CONFIGURE_FLAGS
+= LIBXML2_LIBS
='$(SOLARLIBDIR)$/libxml2.lib'
52 CONFIGURE_FLAGS
+= LIBXML2_LIBS
='-L$(SOLARLIBDIR) -lxml2'
56 .IF
"$(SYSTEM_GLIB)"!="YES"
57 # we're cheating here.. pkg-config wouldn't find anything useful, see configure patch
58 CONFIGURE_FLAGS
+= LIBO_GLIB_CHEAT
=YES
59 CONFIGURE_FLAGS
+= GLIB_CFLAGS
='-I$(SOLARINCDIR)/external/glib-2.0'
60 .IF
"$(GUI)"=="WNT" && "$(COM)"!="GCC"
61 CONFIGURE_FLAGS
+= GLIB_LIBS
='$(SOLARLIBDIR)$/gio-2.0.lib $(SOLARLIBDIR)$/gobject-2.0.lib $(SOLARLIBDIR)$/gthread-2.0.lib $(SOLARLIBDIR)$/gmodule-2.0.lib $(SOLARLIBDIR)$/glib-2.0.lib'
63 CONFIGURE_FLAGS
+= GLIB_LIBS
='-L$(SOLARLIBDIR) -lgio-2.0 -lgobject-2.0 -lgthread-2.0 -lgmodule-2.0 -lglib-2.0'
65 CONFIGURE_FLAGS
+= GLIB_GENMARSHAL
=glib-genmarshal
66 CONFIGURE_FLAGS
+= GLIB_MKENUMS
=glib-mkenums
67 CONFIGURE_FLAGS
+= GOBJECT_QUERY
=gobject-query
68 CONFIGURE_FLAGS
+= --disable-glibtest
71 CONFIGURE_ACTION
=$(AUGMENT_LIBRARY_PATH
) .
$/configure
73 BUILD_ACTION
=$(AUGMENT_LIBRARY_PATH
) $(GNUMAKE
) -j
$(EXTMAXPROCESS
) && \
74 $(AUGMENT_LIBRARY_PATH
) $(GNUMAKE
) install
76 .IF
"$(SYSTEM_LIBXML)"!="YES" ||
"$(SYSTEM_GLIB)"!="YES"
77 .IF
"$(OS)"=="FREEBSD" ||
"$(OS)"=="LINUX"
79 LDFLAGS
=-Wl
,-z
,origin\
-Wl
,-rpath
,\'\
$$\
$$ORIGIN:\
$$\
$$ORIGIN/..
/ure-link
/lib
\'
80 .ELIF
"$(OS)"=="SOLARIS"
81 CONFIGURE_FLAGS
+= LDFLAGS
=-Wl
,-R
\'\
$$\
$$ORIGIN:\
$$\
$$ORIGIN/..
/ure-link
/lib
\'
88 CONFIGURE_FLAGS
+= LDFLAGS
=-Wl
,--enable-runtime-pseudo-reloc-v2
90 .IF
"$(CROSS_COMPILING)"=="YES"
91 CONFIGURE_FLAGS
+= --build
=$(BUILD_PLATFORM
) --host
=$(HOST_PLATFORM
)
94 .ELSE
# "$(COM)"=="GCC"
96 PATCH_FILES
+=liblangtag-0.2
-msc-configure.patch
98 .ENDIF
# "$(COM)"=="GCC"
99 .ENDIF
# "$(GUI)"=="WNT"
102 # --- Targets ------------------------------------------------------
104 .INCLUDE
: set_ext.mk