1*cdf0e10cSrcweir#************************************************************************* 2*cdf0e10cSrcweir# 3*cdf0e10cSrcweir# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir# 5*cdf0e10cSrcweir# Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir# 7*cdf0e10cSrcweir# OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir# 9*cdf0e10cSrcweir# This file is part of OpenOffice.org. 10*cdf0e10cSrcweir# 11*cdf0e10cSrcweir# OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir# it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir# only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir# 15*cdf0e10cSrcweir# OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir# but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir# GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir# (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir# 21*cdf0e10cSrcweir# You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir# version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir# <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir# for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir# 26*cdf0e10cSrcweir#************************************************************************* 27*cdf0e10cSrcweir 28*cdf0e10cSrcweirPRJ=. 29*cdf0e10cSrcweir 30*cdf0e10cSrcweirPRJNAME=libxml2 31*cdf0e10cSrcweirTARGET=so_libxml2 32*cdf0e10cSrcweir 33*cdf0e10cSrcweir# --- Settings ----------------------------------------------------- 34*cdf0e10cSrcweir 35*cdf0e10cSrcweir.INCLUDE : settings.mk 36*cdf0e10cSrcweir 37*cdf0e10cSrcweir.IF "$(SYSTEM_LIBXML)" == "YES" 38*cdf0e10cSrcweirall: 39*cdf0e10cSrcweir @echo "An already available installation of libxml should exist on your system." 40*cdf0e10cSrcweir @echo "Therefore the version provided here does not need to be built in addition." 41*cdf0e10cSrcweir.ENDIF 42*cdf0e10cSrcweir 43*cdf0e10cSrcweir# --- Files -------------------------------------------------------- 44*cdf0e10cSrcweir 45*cdf0e10cSrcweirLIBXML2VERSION=2.7.6 46*cdf0e10cSrcweir 47*cdf0e10cSrcweirTARFILE_NAME=$(PRJNAME)-$(LIBXML2VERSION) 48*cdf0e10cSrcweirTARFILE_MD5=7740a8ec23878a2f50120e1faa2730f2 49*cdf0e10cSrcweir 50*cdf0e10cSrcweir# libxml2-global-symbols: #i112480#: Solaris ld won't export non-listed symbols 51*cdf0e10cSrcweirPATCH_FILES=libxml2-configure.patch \ 52*cdf0e10cSrcweir libxml2-mingw.patch \ 53*cdf0e10cSrcweir libxml2-gnome599717.patch \ 54*cdf0e10cSrcweir libxml2-xpath.patch \ 55*cdf0e10cSrcweir libxml2-global-symbols.patch \ 56*cdf0e10cSrcweir 57*cdf0e10cSrcweir.IF "$(OS)" == "WNT" 58*cdf0e10cSrcweirPATCH_FILES+= libxml2-long-path.patch 59*cdf0e10cSrcweir.ENDIF 60*cdf0e10cSrcweir 61*cdf0e10cSrcweir# This is only for UNX environment now 62*cdf0e10cSrcweir 63*cdf0e10cSrcweir.IF "$(OS)"=="WNT" 64*cdf0e10cSrcweir.IF "$(COM)"=="GCC" 65*cdf0e10cSrcweirxml2_CC=$(CC) -mthreads 66*cdf0e10cSrcweir.IF "$(MINGW_SHARED_GCCLIB)"=="YES" 67*cdf0e10cSrcweirxml2_CC+=-shared-libgcc 68*cdf0e10cSrcweir.ENDIF 69*cdf0e10cSrcweirxml2_LIBS=-lws2_32 70*cdf0e10cSrcweir.IF "$(MINGW_SHARED_GXXLIB)"=="YES" 71*cdf0e10cSrcweirxml2_LIBS+=$(MINGW_SHARED_LIBSTDCPP) 72*cdf0e10cSrcweir.ENDIF 73*cdf0e10cSrcweirCONFIGURE_DIR= 74*cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure 75*cdf0e10cSrcweirCONFIGURE_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)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2 -L$(ILIB:s/;/ -L/)" LIBS="$(xml2_LIBS)" OBJDUMP=objdump 76*cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE) 77*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 78*cdf0e10cSrcweir.ELSE 79*cdf0e10cSrcweirCONFIGURE_DIR=win32 80*cdf0e10cSrcweirCONFIGURE_ACTION=cscript configure.js 81*cdf0e10cSrcweirCONFIGURE_FLAGS=iconv=no sax1=yes 82*cdf0e10cSrcweir.IF "$(debug)"!="" 83*cdf0e10cSrcweirCONFIGURE_FLAGS+=debug=yes 84*cdf0e10cSrcweir.ENDIF 85*cdf0e10cSrcweirBUILD_ACTION=nmake 86*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 87*cdf0e10cSrcweir.ENDIF 88*cdf0e10cSrcweir.ELSE 89*cdf0e10cSrcweir.IF "$(SYSBASE)"!="" 90*cdf0e10cSrcweirxml2_CFLAGS+=-I$(SYSBASE)$/usr$/include 91*cdf0e10cSrcweir.IF "$(COMNAME)"=="sunpro5" 92*cdf0e10cSrcweirxml2_CFLAGS+=$(ARCH_FLAGS) $(C_RESTRICTIONFLAGS) 93*cdf0e10cSrcweir.ENDIF # "$(COMNAME)"=="sunpro5" 94*cdf0e10cSrcweirxml2_LDFLAGS+=-L$(SYSBASE)$/usr$/lib 95*cdf0e10cSrcweir.ENDIF # "$(SYSBASE)"!="" 96*cdf0e10cSrcweir 97*cdf0e10cSrcweirCONFIGURE_DIR= 98*cdf0e10cSrcweir.IF "$(OS)"=="OS2" 99*cdf0e10cSrcweirCONFIGURE_ACTION=sh .$/configure 100*cdf0e10cSrcweirCONFIGURE_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)" 101*cdf0e10cSrcweir.ELSE 102*cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure 103*cdf0e10cSrcweirCONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-zlib --enable-static=no --with-sax1=yes ADDCFLAGS="$(xml2_CFLAGS) $(EXTRA_CFLAGS)" LDFLAGS="$(xml2_LDFLAGS) $(EXTRA_LINKFLAGS)" 104*cdf0e10cSrcweir.ENDIF 105*cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE) 106*cdf0e10cSrcweirBUILD_FLAGS+= -j$(EXTMAXPROCESS) 107*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 108*cdf0e10cSrcweir.ENDIF 109*cdf0e10cSrcweir 110*cdf0e10cSrcweir 111*cdf0e10cSrcweirOUTDIR2INC=include$/libxml 112*cdf0e10cSrcweir 113*cdf0e10cSrcweir.IF "$(OS)"=="MACOSX" 114*cdf0e10cSrcweirEXTRPATH=URELIB 115*cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2.*.dylib 116*cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint 117*cdf0e10cSrcweirOUT2BIN+=xml2-config 118*cdf0e10cSrcweir.ELIF "$(OS)"=="WNT" 119*cdf0e10cSrcweir.IF "$(COM)"=="GCC" 120*cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2*.a 121*cdf0e10cSrcweirOUT2BIN+=.libs$/libxml2*.dll 122*cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint.exe 123*cdf0e10cSrcweirOUT2BIN+=xml2-config 124*cdf0e10cSrcweir.ELSE 125*cdf0e10cSrcweirOUT2LIB+=win32$/bin.msvc$/*.lib 126*cdf0e10cSrcweirOUT2BIN+=win32$/bin.msvc$/*.dll 127*cdf0e10cSrcweirOUT2BIN+=win32$/bin.msvc$/xmllint.exe 128*cdf0e10cSrcweir.ENDIF 129*cdf0e10cSrcweir.ELSE 130*cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2.so* 131*cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint 132*cdf0e10cSrcweirOUT2BIN+=xml2-config 133*cdf0e10cSrcweir.ENDIF 134*cdf0e10cSrcweir 135*cdf0e10cSrcweir# --- Targets ------------------------------------------------------ 136*cdf0e10cSrcweir 137*cdf0e10cSrcweir.INCLUDE : set_ext.mk 138*cdf0e10cSrcweir.INCLUDE : target.mk 139*cdf0e10cSrcweir.INCLUDE : tg_ext.mk 140*cdf0e10cSrcweir 141