1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 # Copyright 2008 by Sun Microsystems, Inc.
7 # OpenOffice.org - a multi-platform office productivity suite
9 # $RCSfile: makefile.mk,v $
13 # This file is part of OpenOffice.org.
15 # OpenOffice.org is free software: you can redistribute it and/or modify
16 # it under the terms of the GNU Lesser General Public License version 3
17 # only, as published by the Free Software Foundation.
19 # OpenOffice.org is distributed in the hope that it will be useful,
20 # but WITHOUT ANY WARRANTY; without even the implied warranty of
21 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 # GNU Lesser General Public License version 3 for more details
23 # (a copy is included in the LICENSE file that accompanied this code).
25 # You should have received a copy of the GNU Lesser General Public License
26 # version 3 along with OpenOffice.org. If not, see
27 # <http://www.openoffice.org/license.html>
28 # for a copy of the LGPLv3 License.
30 #*************************************************************************
37 # --- Settings -----------------------------------------------------
39 .INCLUDE
: settings.mk
41 .IF
"$(SYSTEM_LIBXML)" == "YES"
43 @echo
"An already available installation of libxml should exist on your system."
44 @echo
"Therefore the version provided here does not need to be built in addition."
47 # --- Files --------------------------------------------------------
51 TARFILE_NAME
=$(PRJNAME
)-$(LIBXML2VERSION
)
52 #.IF "$(OS)$(COM)"=="WNTGCC"
53 #PATCH_FILES=$(TARFILE_NAME)-mingw.patch
55 PATCH_FILES
=$(TARFILE_NAME
).patch
58 # This is only for UNX environment now
62 PATCH_FILES
+=$(TARFILE_NAME
)-mingw.patch
64 .IF
"$(MINGW_SHARED_GCCLIB)"=="YES"
65 xml2_CC
+=-shared-libgcc
67 xml2_LIBS
=-lws2_32
-lmingwthrd
68 .IF
"$(MINGW_SHARED_GXXLIB)"=="YES"
72 CONFIGURE_ACTION
=.
$/configure
73 CONFIGURE_FLAGS
=--enable-ipv6
=no
--without-python
--without-zlib
--enable-static
=no
--without-debug
--build
=i586-pc-mingw32
--host
=i586-pc-mingw32 lt_cv_cc_dll_switch
="-shared" CC
="$(xml2_CC)" CFLAGS
=-D_MT LDFLAGS
="-no-undefined -Wl,--enable-runtime-pseudo-reloc -L$(ILIB:s/;/ -L/)" LIBS
="$(xml2_LIBS)" OBJDUMP
="$(WRAPCMD) objdump"
74 BUILD_ACTION
=$(GNUMAKE
)
75 BUILD_DIR
=$(CONFIGURE_DIR
)
78 CONFIGURE_ACTION
=cscript configure.js
79 CONFIGURE_FLAGS
=iconv
=no sax1
=yes
81 CONFIGURE_FLAGS
+=debug
=yes
84 BUILD_DIR
=$(CONFIGURE_DIR
)
88 xml2_CFLAGS
+=-I
$(SYSBASE
)$/usr
$/include
89 .IF
"$(COMNAME)"=="sunpro5"
90 xml2_CFLAGS
+=$(ARCH_FLAGS
) $(C_RESTRICTIONFLAGS
)
91 .ENDIF
# "$(COMNAME)"=="sunpro5"
92 xml2_LDFLAGS
+=-L
$(SYSBASE
)$/usr
$/lib
93 .ENDIF
# "$(SYSBASE)"!=""
95 .IF
"$(OS)$(COM)"=="LINUXGCC"
96 xml2_LDFLAGS
+=-Wl
,-z
,noexecstack
101 CONFIGURE_ACTION
=sh .
$/configure
102 CONFIGURE_FLAGS
=--enable-ipv6
=no
--without-python
--without-zlib
--enable-static
=yes
--with-sax1
=yes ADDCFLAGS
="$(xml2_CFLAGS)" CFLAGS
="$(EXTRA_CFLAGS)" LDFLAGS
="$(xml2_LDFLAGS) $(EXTRA_LINKFLAGS)"
104 CONFIGURE_ACTION
=.
$/configure
105 CONFIGURE_FLAGS
=--enable-ipv6
=no
--without-python
--without-zlib
--enable-static
=no
--with-sax1
=yes ADDCFLAGS
="$(xml2_CFLAGS) $(EXTRA_CFLAGS)" LDFLAGS
="$(xml2_LDFLAGS) $(EXTRA_LINKFLAGS)"
107 BUILD_ACTION
=$(GNUMAKE
)
108 BUILD_FLAGS
+= -j
$(EXTMAXPROCESS
)
109 BUILD_DIR
=$(CONFIGURE_DIR
)
113 OUTDIR2INC
=include$/libxml
115 .IF
"$(OS)"=="MACOSX"
117 OUT2LIB
+=.libs
$/libxml2.
*.dylib
118 OUT2BIN
+=.libs
$/xmllint
122 OUT2LIB
+=.libs
$/libxml2
*.a
123 OUT2BIN
+=.libs
$/libxml2
*.dll
124 OUT2BIN
+=.libs
$/xmllint.exe
127 OUT2LIB
+=win32
$/bin.msvc
$/*.lib
128 OUT2BIN
+=win32
$/bin.msvc
$/*.dll
129 OUT2BIN
+=win32
$/bin.msvc
$/xmllint.exe
132 OUT2LIB
+=.libs
$/libxml2.so
*
133 OUT2BIN
+=.libs
$/xmllint
137 # --- Targets ------------------------------------------------------
139 .INCLUDE
: set_ext.mk