17871dc3eSAndrew Rist#************************************************************** 27871dc3eSAndrew Rist# 37871dc3eSAndrew Rist# Licensed to the Apache Software Foundation (ASF) under one 47871dc3eSAndrew Rist# or more contributor license agreements. See the NOTICE file 57871dc3eSAndrew Rist# distributed with this work for additional information 67871dc3eSAndrew Rist# regarding copyright ownership. The ASF licenses this file 77871dc3eSAndrew Rist# to you under the Apache License, Version 2.0 (the 87871dc3eSAndrew Rist# "License"); you may not use this file except in compliance 97871dc3eSAndrew Rist# with the License. You may obtain a copy of the License at 107871dc3eSAndrew Rist# 117871dc3eSAndrew Rist# http://www.apache.org/licenses/LICENSE-2.0 127871dc3eSAndrew Rist# 137871dc3eSAndrew Rist# Unless required by applicable law or agreed to in writing, 147871dc3eSAndrew Rist# software distributed under the License is distributed on an 157871dc3eSAndrew Rist# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 167871dc3eSAndrew Rist# KIND, either express or implied. See the License for the 177871dc3eSAndrew Rist# specific language governing permissions and limitations 187871dc3eSAndrew Rist# under the License. 197871dc3eSAndrew Rist# 207871dc3eSAndrew Rist#************************************************************** 217871dc3eSAndrew Rist 227871dc3eSAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweirPRJ=. 25cdf0e10cSrcweir 26cdf0e10cSrcweirPRJNAME=libxml2 27cdf0e10cSrcweirTARGET=so_libxml2 28cdf0e10cSrcweir 29cdf0e10cSrcweir# --- Settings ----------------------------------------------------- 30cdf0e10cSrcweir 31cdf0e10cSrcweir.INCLUDE : settings.mk 32cdf0e10cSrcweir 33cdf0e10cSrcweir.IF "$(SYSTEM_LIBXML)" == "YES" 34c6c5eebaSJian Fang Zhangall: 35c6c5eebaSJian Fang Zhang @echo "An already available installation of libxml should exist on your system." 36c6c5eebaSJian Fang Zhang @echo "Therefore the version provided here does not need to be built in addition." 37cdf0e10cSrcweir.ENDIF 38cdf0e10cSrcweir 39cdf0e10cSrcweir# --- Files -------------------------------------------------------- 40cdf0e10cSrcweir 4134f44591SDon LewisLIBXML2VERSION=2.9.10 42cdf0e10cSrcweir 43cdf0e10cSrcweirTARFILE_NAME=$(PRJNAME)-$(LIBXML2VERSION) 4434f44591SDon LewisTARFILE_MD5=10942a1dc23137a8aa07f0639cbfece5 452d019523SJim Jagielski 46*2a621114SDon LewisPATCH_FILES=libxml2-configure.patch \ 47*2a621114SDon Lewis 0e1a49c8907645d2e155f0d89d4d9895ac5112b5.patch \ 48*2a621114SDon Lewis 50f06b3efb638efb0abd95dc62dca05ae67882c2.patch \ 49*2a621114SDon Lewis 7ffcd44d7e6c46704f8af0321d9314cd26e0e18a.patch 50cdf0e10cSrcweir 51cdf0e10cSrcweir# libxml2-global-symbols: #i112480#: Solaris ld won't export non-listed symbols 522d019523SJim Jagielski# libxml2-global-symbols.patch 53cdf0e10cSrcweir 54cdf0e10cSrcweir# This is only for UNX environment now 55cdf0e10cSrcweir 56cdf0e10cSrcweir.IF "$(OS)"=="WNT" 57cdf0e10cSrcweir.IF "$(COM)"=="GCC" 58cdf0e10cSrcweirxml2_CC=$(CC) -mthreads 59cdf0e10cSrcweir.IF "$(MINGW_SHARED_GCCLIB)"=="YES" 60cdf0e10cSrcweirxml2_CC+=-shared-libgcc 61cdf0e10cSrcweir.ENDIF 62cdf0e10cSrcweirxml2_LIBS=-lws2_32 63cdf0e10cSrcweir.IF "$(MINGW_SHARED_GXXLIB)"=="YES" 64cdf0e10cSrcweirxml2_LIBS+=$(MINGW_SHARED_LIBSTDCPP) 65cdf0e10cSrcweir.ENDIF 66cdf0e10cSrcweirCONFIGURE_DIR= 67cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure 6834f44591SDon LewisCONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-lzma --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 69cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE) 70cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 71cdf0e10cSrcweir.ELSE 72cdf0e10cSrcweirCONFIGURE_DIR=win32 73cdf0e10cSrcweirCONFIGURE_ACTION=cscript configure.js 7434f44591SDon LewisCONFIGURE_FLAGS=iconv=no sax1=yes lzma=no 75cdf0e10cSrcweir.IF "$(debug)"!="" 76cdf0e10cSrcweirCONFIGURE_FLAGS+=debug=yes 77cdf0e10cSrcweir.ENDIF 78cdf0e10cSrcweirBUILD_ACTION=nmake 79cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 80cdf0e10cSrcweir.ENDIF 81cdf0e10cSrcweir.ELSE 82cdf0e10cSrcweir.IF "$(SYSBASE)"!="" 83cdf0e10cSrcweirxml2_CFLAGS+=-I$(SYSBASE)$/usr$/include 84cdf0e10cSrcweir.IF "$(COMNAME)"=="sunpro5" 85cdf0e10cSrcweirxml2_CFLAGS+=$(ARCH_FLAGS) $(C_RESTRICTIONFLAGS) 86cdf0e10cSrcweir.ENDIF # "$(COMNAME)"=="sunpro5" 87cdf0e10cSrcweirxml2_LDFLAGS+=-L$(SYSBASE)$/usr$/lib 88cdf0e10cSrcweir.ENDIF # "$(SYSBASE)"!="" 89cdf0e10cSrcweir 90cdf0e10cSrcweirCONFIGURE_DIR= 91cdf0e10cSrcweir.IF "$(OS)"=="OS2" 92cdf0e10cSrcweirCONFIGURE_ACTION=sh .$/configure 9334f44591SDon LewisCONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-zlib --without-lzma --enable-static=yes --with-sax1=yes ADDCFLAGS="$(xml2_CFLAGS)" CFLAGS="$(EXTRA_CFLAGS)" LDFLAGS="$(xml2_LDFLAGS) $(EXTRA_LINKFLAGS)" 94cdf0e10cSrcweir.ELSE 95cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure 9634f44591SDon LewisCONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-zlib --without-lzma --enable-static=no --with-sax1=yes ADDCFLAGS="$(xml2_CFLAGS) $(EXTRA_CFLAGS)" LDFLAGS="$(xml2_LDFLAGS) $(EXTRA_LINKFLAGS)" 97cdf0e10cSrcweir.ENDIF 98cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE) 99cdf0e10cSrcweirBUILD_FLAGS+= -j$(EXTMAXPROCESS) 100cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR) 101cdf0e10cSrcweir.ENDIF 102cdf0e10cSrcweir 103cdf0e10cSrcweir 104cdf0e10cSrcweirOUTDIR2INC=include$/libxml 105cdf0e10cSrcweir 106cdf0e10cSrcweir.IF "$(OS)"=="MACOSX" 107cdf0e10cSrcweirEXTRPATH=URELIB 108cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2.*.dylib 109cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint 110cdf0e10cSrcweirOUT2BIN+=xml2-config 111cdf0e10cSrcweir.ELIF "$(OS)"=="WNT" 112cdf0e10cSrcweir.IF "$(COM)"=="GCC" 113cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2*.a 114cdf0e10cSrcweirOUT2BIN+=.libs$/libxml2*.dll 115cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint.exe 116cdf0e10cSrcweirOUT2BIN+=xml2-config 117cdf0e10cSrcweir.ELSE 118cdf0e10cSrcweirOUT2LIB+=win32$/bin.msvc$/*.lib 119cdf0e10cSrcweirOUT2BIN+=win32$/bin.msvc$/*.dll 120cdf0e10cSrcweirOUT2BIN+=win32$/bin.msvc$/xmllint.exe 121cdf0e10cSrcweir.ENDIF 122cdf0e10cSrcweir.ELSE 123cdf0e10cSrcweirOUT2LIB+=.libs$/libxml2.so* 124cdf0e10cSrcweirOUT2BIN+=.libs$/xmllint 125cdf0e10cSrcweirOUT2BIN+=xml2-config 126cdf0e10cSrcweir.ENDIF 127cdf0e10cSrcweir 128cdf0e10cSrcweir# --- Targets ------------------------------------------------------ 129cdf0e10cSrcweir 130cdf0e10cSrcweir.INCLUDE : set_ext.mk 131cdf0e10cSrcweir.INCLUDE : target.mk 132cdf0e10cSrcweir.INCLUDE : tg_ext.mk 133cdf0e10cSrcweir 134