1*cdf0e10cSrcweir#************************************************************************* 2*cdf0e10cSrcweir# 3*cdf0e10cSrcweir# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir# 5*cdf0e10cSrcweir# Copyright 2008 by Sun Microsystems, Inc. 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*cdf0e10cSrcweirPRJNAME=mysqlc 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir.INCLUDE : $(PRJ)$/version.mk 32*cdf0e10cSrcweir 33*cdf0e10cSrcweirTARGET=mysqlc 34*cdf0e10cSrcweirENABLE_EXCEPTIONS=TRUE 35*cdf0e10cSrcweirLIBTARGET=NO 36*cdf0e10cSrcweirEXTENSIONNAME:=mysql-connector-ooo 37*cdf0e10cSrcweir 38*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL)" == "YES" 39*cdf0e10cSrcweirEXTERNAL_WARNINGS_NOT_ERRORS = TRUE 40*cdf0e10cSrcweir.ENDIF 41*cdf0e10cSrcweir 42*cdf0e10cSrcweir# --- Settings ----------------------------------------------------- 43*cdf0e10cSrcweir 44*cdf0e10cSrcweir.INCLUDE : settings.mk 45*cdf0e10cSrcweir 46*cdf0e10cSrcweir#------------------------------------------------------------------- 47*cdf0e10cSrcweir 48*cdf0e10cSrcweir#---- extension version 49*cdf0e10cSrcweirEXTENSION_VERSION_BASE=$(MYSQLC_VERSION_MAJOR).$(MYSQLC_VERSION_MINOR).$(MYSQLC_VERSION_MICRO) 50*cdf0e10cSrcweir.IF ( "$(CWS_WORK_STAMP)" == "" ) || ( "$(UPDATER)" == "YES" ) 51*cdf0e10cSrcweir EXTENSION_VERSION=$(EXTENSION_VERSION_BASE) 52*cdf0e10cSrcweir.ELSE 53*cdf0e10cSrcweir EXTENSION_VERSION=$(EXTENSION_VERSION_BASE).cws.$(CWS_WORK_STAMP) 54*cdf0e10cSrcweir.ENDIF 55*cdf0e10cSrcweir 56*cdf0e10cSrcweir#---- extension title package name 57*cdf0e10cSrcweir.IF "$(MYSQLC_STATUS)" == "final" 58*cdf0e10cSrcweir EXTENSION_TITLE:=$(MYSQLC_TITLE) 59*cdf0e10cSrcweir EXTENSION_ZIPNAME:=$(EXTENSIONNAME) 60*cdf0e10cSrcweir.ELSE 61*cdf0e10cSrcweir EXTENSION_TITLE:=$(MYSQLC_TITLE) ($(MYSQLC_STATUS)) 62*cdf0e10cSrcweir EXTENSION_ZIPNAME:=$(EXTENSIONNAME) 63*cdf0e10cSrcweir.ENDIF 64*cdf0e10cSrcweir 65*cdf0e10cSrcweir#------------------------------------------------------------------- 66*cdf0e10cSrcweir 67*cdf0e10cSrcweir# set default symbol visibility / scope to hidden 68*cdf0e10cSrcweir.IF "$(COMNAME)" == "gcc3" 69*cdf0e10cSrcweir.IF "$(HAVE_GCC_VISIBILITY_FEATURE)" == "TRUE" 70*cdf0e10cSrcweir CFLAGS += -fvisibility=hidden 71*cdf0e10cSrcweir.ENDIF # HAVE_GCC_VISIBILITY_FEATURE 72*cdf0e10cSrcweir.ENDIF # gcc3 73*cdf0e10cSrcweir 74*cdf0e10cSrcweir.IF "$(COMNAME)" == "sunpro5" 75*cdf0e10cSrcweir.IF "$(CCNUMVER)" >= "00050005" 76*cdf0e10cSrcweir CFLAGS += -xldscope=hidden 77*cdf0e10cSrcweir.ENDIF # 5.5 78*cdf0e10cSrcweir.ENDIF # sunpro5 79*cdf0e10cSrcweir 80*cdf0e10cSrcweir#------------------------------------------------------------------- 81*cdf0e10cSrcweir 82*cdf0e10cSrcweir# The headers delivered from C/C++ have a habit of putting a ";" after the closing bracked of a namespace, which 83*cdf0e10cSrcweir# yields a warning with Solaris' compiler. Until this is fixed in C/C++, silence this warning 84*cdf0e10cSrcweir.IF "$(OS)" == "SOLARIS" 85*cdf0e10cSrcweir CFLAGSWARNCXX+=,wemptydecl 86*cdf0e10cSrcweir CFLAGSWARNCXX:=$(CFLAGSWARNCXX:s/ ,/,/) 87*cdf0e10cSrcweir.ENDIF 88*cdf0e10cSrcweir 89*cdf0e10cSrcweir#------------------------------------------------------------------- 90*cdf0e10cSrcweir.IF "$(ENABLE_MYSQLC)" != "YES" 91*cdf0e10cSrcweir@all: 92*cdf0e10cSrcweir @echo "Mysql native driver extension build disabled." 93*cdf0e10cSrcweir.ENDIF 94*cdf0e10cSrcweir 95*cdf0e10cSrcweir# use the static version 96*cdf0e10cSrcweir.IF "$(GUI)"=="WNT" 97*cdf0e10cSrcweir MYSQL_LIBDIR=$(LIBMYSQL_PATH)$/lib 98*cdf0e10cSrcweir MYSQL_INCDIR=$(LIBMYSQL_PATH)$/include 99*cdf0e10cSrcweir.ELSE 100*cdf0e10cSrcweir .IF "$(SYSTEM_MYSQL)" != "YES" 101*cdf0e10cSrcweir MYSQL_LIBDIR=$(LIBMYSQL_PATH)$/lib 102*cdf0e10cSrcweir MYSQL_INCDIR=$(LIBMYSQL_PATH)$/include 103*cdf0e10cSrcweir .ENDIF 104*cdf0e10cSrcweir.ENDIF 105*cdf0e10cSrcweir 106*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL)" == "YES" 107*cdf0e10cSrcweirCFLAGS+=-DSYSTEM_MYSQL 108*cdf0e10cSrcweir.ENDIF 109*cdf0e10cSrcweir 110*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL_CPPCONN)" == "YES" 111*cdf0e10cSrcweirCFLAGS+=-DSYSTEM_MYSQL_CPPCONN 112*cdf0e10cSrcweir.ENDIF 113*cdf0e10cSrcweir 114*cdf0e10cSrcweirCDEFS+=-DCPPDBC_EXPORTS -DCPPCONN_LIB_BUILD 115*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL_CPPCONN)" != "YES" 116*cdf0e10cSrcweirCDEFS += -DCPPCONN_LIB=\"$(DLLPRE)mysqlcppconn$(DLLPOST)\" 117*cdf0e10cSrcweir.ELSE 118*cdf0e10cSrcweirCDEFS += -DCPPCONN_LIB=\"$(shell readlink /usr/lib/libmysqlcppconn.so)\" 119*cdf0e10cSrcweir.IF "$(USE_SYSTEM_STL)"!="YES" 120*cdf0e10cSrcweirCDEFS += -DADAPT_EXT_STL 121*cdf0e10cSrcweir.ENDIF 122*cdf0e10cSrcweir.ENDIF 123*cdf0e10cSrcweir 124*cdf0e10cSrcweir# --------------- MySQL settings ------------------ 125*cdf0e10cSrcweir.IF "$(GUI)"=="WNT" 126*cdf0e10cSrcweir MYSQL_INC=-I$(SOLARINCDIR)$/mysqlcppconn -I$(SOLARINCDIR)$/mysqlcppconn/cppconn -I$(MYSQL_INCDIR) 127*cdf0e10cSrcweir MYSQL_LIB=$(MYSQL_LIBDIR)$/libmysql.lib 128*cdf0e10cSrcweir MYSQL_LIBFILE=$(MYSQL_LIBDIR)$/libmysql.dll 129*cdf0e10cSrcweir MYSQL_CPPCONNFILE=$(SOLARBINDIR)$/$(DLLPRE)mysqlcppconn$(DLLPOST) 130*cdf0e10cSrcweir.ELSE 131*cdf0e10cSrcweir .IF "$(SYSTEM_MYSQL)" != "YES" 132*cdf0e10cSrcweir MYSQL_INC+=-I$(MYSQL_INCDIR) 133*cdf0e10cSrcweir .IF "$(OS)"=="MACOSX" 134*cdf0e10cSrcweir MYSQL_LIBFILE=$(MYSQL_LIBDIR)$/$(DLLPRE)mysql.16$(DLLPOST) 135*cdf0e10cSrcweir .ELSE 136*cdf0e10cSrcweir MYSQL_LIBFILE=$(MYSQL_LIBDIR)$/$(DLLPRE)mysql$(DLLPOST).16 137*cdf0e10cSrcweir .ENDIF 138*cdf0e10cSrcweir 139*cdf0e10cSrcweir # checkdll will complain if we do not point it to the libmysql lib 140*cdf0e10cSrcweir EXTRALIBPATHS=-L$(MYSQL_LIBDIR) 141*cdf0e10cSrcweir .ENDIF 142*cdf0e10cSrcweir 143*cdf0e10cSrcweir .IF "$(SYSTEM_MYSQL_CPPCONN)" != "YES" 144*cdf0e10cSrcweir .IF "$(OS)"=="MACOSX" || "$(OS)" == "SOLARIS" 145*cdf0e10cSrcweir MYSQL_LIB+=-lz -lm 146*cdf0e10cSrcweir .ELSE 147*cdf0e10cSrcweir MYSQL_LIB+=-rdynamic -lz -lcrypt -lnsl -lm 148*cdf0e10cSrcweir .ENDIF 149*cdf0e10cSrcweir MYSQL_CPPCONNFILE=$(SOLARLIBDIR)$/$(DLLPRE)mysqlcppconn$(DLLPOST) 150*cdf0e10cSrcweir .ELSE 151*cdf0e10cSrcweir MYSQL_CPPCONN_LIB+=-lmysqlcppconn 152*cdf0e10cSrcweir .ENDIF 153*cdf0e10cSrcweir.ENDIF 154*cdf0e10cSrcweir 155*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL_CPPCONN)" != "YES" 156*cdf0e10cSrcweir MYSQL_INC+=-I$(SOLARINCDIR)$/mysqlcppconn -I$(SOLARINCDIR)$/mysqlcppconn/cppconn 157*cdf0e10cSrcweir.ENDIF 158*cdf0e10cSrcweir 159*cdf0e10cSrcweirCFLAGS+=-I..$/..$/inc $(MYSQL_INC) \ 160*cdf0e10cSrcweir -DMYSQLC_VERSION_MAJOR=$(MYSQLC_VERSION_MAJOR) \ 161*cdf0e10cSrcweir -DMYSQLC_VERSION_MINOR=$(MYSQLC_VERSION_MINOR) \ 162*cdf0e10cSrcweir -DMYSQLC_VERSION_MICRO=$(MYSQLC_VERSION_MICRO) \ 163*cdf0e10cSrcweir $(MYSQL_DEFINES) 164*cdf0e10cSrcweir 165*cdf0e10cSrcweir# provide the name of the MySQL client lib to the C++ code 166*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL)" != "YES" 167*cdf0e10cSrcweirCDEFS += -DMYSQL_LIB=\"$(MYSQL_LIBFILE:f)\" 168*cdf0e10cSrcweir.ENDIF 169*cdf0e10cSrcweir 170*cdf0e10cSrcweir#-------------------------------------------------- 171*cdf0e10cSrcweir 172*cdf0e10cSrcweirSHL1DLLPRE= 173*cdf0e10cSrcweirSHL1TARGET=$(TARGET).uno 174*cdf0e10cSrcweirLIB1TARGET=$(SLB)$/$(SHL1TARGET).lib 175*cdf0e10cSrcweirLIB1OBJFILES= \ 176*cdf0e10cSrcweir $(SLO)$/mysqlc_driver.obj \ 177*cdf0e10cSrcweir $(SLO)$/mysqlc_services.obj \ 178*cdf0e10cSrcweir $(SLO)$/mysqlc_connection.obj \ 179*cdf0e10cSrcweir $(SLO)$/mysqlc_resultset.obj \ 180*cdf0e10cSrcweir $(SLO)$/mysqlc_resultsetmetadata.obj \ 181*cdf0e10cSrcweir $(SLO)$/mysqlc_statement.obj \ 182*cdf0e10cSrcweir $(SLO)$/mysqlc_preparedstatement.obj \ 183*cdf0e10cSrcweir $(SLO)$/mysqlc_databasemetadata.obj \ 184*cdf0e10cSrcweir $(SLO)$/mysqlc_types.obj \ 185*cdf0e10cSrcweir $(SLO)$/mysqlc_general.obj \ 186*cdf0e10cSrcweir $(SLO)$/mysqlc_propertyids.obj 187*cdf0e10cSrcweir 188*cdf0e10cSrcweirSHL1STDLIBS= \ 189*cdf0e10cSrcweir $(MYSQL_LIB) \ 190*cdf0e10cSrcweir $(MYSQL_CPPCONN_LIB) \ 191*cdf0e10cSrcweir $(CPPULIB) \ 192*cdf0e10cSrcweir $(SALLIB) \ 193*cdf0e10cSrcweir $(SALHELPERLIB) \ 194*cdf0e10cSrcweir $(CPPUHELPERLIB) 195*cdf0e10cSrcweir 196*cdf0e10cSrcweirSHL1VERSIONMAP=$(TARGET).map 197*cdf0e10cSrcweirSHL1LIBS= $(LIB1TARGET) 198*cdf0e10cSrcweirSHL1DEF= $(MISC)$/$(SHL1TARGET).def 199*cdf0e10cSrcweirSHL1RPATH=OXT 200*cdf0e10cSrcweirDEF1NAME= $(SHL1TARGET) 201*cdf0e10cSrcweir 202*cdf0e10cSrcweir# create Extension ----------------------------- 203*cdf0e10cSrcweir 204*cdf0e10cSrcweir# DESCRIPTION_SRC is the source file which is copied into the extension 205*cdf0e10cSrcweir# It is defaulted to "description.xml", but we want to pre-process it, so we use an intermediate 206*cdf0e10cSrcweir# file 207*cdf0e10cSrcweirDESCRIPTION_SRC = $(MISC)$/description.xml 208*cdf0e10cSrcweir 209*cdf0e10cSrcweirCOMPONENT_XCU=\ 210*cdf0e10cSrcweir registry$/data$/org$/openoffice$/Office$/DataAccess$/Drivers.xcu 211*cdf0e10cSrcweir 212*cdf0e10cSrcweirCOMPONENT_MERGED_XCU= \ 213*cdf0e10cSrcweir $(foreach,i,$(COMPONENT_XCU) $(EXTENSIONDIR)$/$i) 214*cdf0e10cSrcweir 215*cdf0e10cSrcweirCOMPONENT_LIBRARY = \ 216*cdf0e10cSrcweir $(EXTENSIONDIR)$/$(SHL1TARGET)$(DLLPOST) 217*cdf0e10cSrcweir 218*cdf0e10cSrcweirCOMPONENT_MYSQL_LIBFILE = \ 219*cdf0e10cSrcweir $(EXTENSIONDIR)$/$(MYSQL_LIBFILE:f) 220*cdf0e10cSrcweir 221*cdf0e10cSrcweirCOMPONENT_MYSQL_CPPCONN_FILE=\ 222*cdf0e10cSrcweir $(EXTENSIONDIR)$/$(MYSQL_CPPCONNFILE:f) 223*cdf0e10cSrcweir 224*cdf0e10cSrcweirCOMPONENT_LIBRARIES=\ 225*cdf0e10cSrcweir $(COMPONENT_LIBRARY) 226*cdf0e10cSrcweir 227*cdf0e10cSrcweirCOMPONENT_IMAGES= \ 228*cdf0e10cSrcweir $(EXTENSIONDIR)$/images$/extension_32.png \ 229*cdf0e10cSrcweir $(EXTENSIONDIR)$/images$/extension_32_h.png 230*cdf0e10cSrcweir 231*cdf0e10cSrcweir 232*cdf0e10cSrcweir# ........ component description ........ 233*cdf0e10cSrcweir# one file for each WITH_LANG token 234*cdf0e10cSrcweirDESC_LANGS=$(WITH_LANG) 235*cdf0e10cSrcweir.IF "$(DESC_LANGS)" == "" 236*cdf0e10cSrcweir DESC_LANGS=en-US 237*cdf0e10cSrcweir.ENDIF 238*cdf0e10cSrcweirCOMPONENT_DESCRIPTIONS=$/$(foreach,lang,$(DESC_LANGS) description$/description_$(lang).txt) 239*cdf0e10cSrcweirCOMPONENT_DESCRIPTIONS_PACKDEP= \ 240*cdf0e10cSrcweir $(foreach,i,$(COMPONENT_DESCRIPTIONS) $(EXTENSIONDIR)$/$i) 241*cdf0e10cSrcweir 242*cdf0e10cSrcweir# WITH_LANG might contain languages which we actually do not have a description for (yet) 243*cdf0e10cSrcweir# Find those, and treat the specially 244*cdf0e10cSrcweir 245*cdf0e10cSrcweir# first, find those locales which we actually have a description file for 246*cdf0e10cSrcweirEXISTING_DESCRIPTIONS=$(foreach,i,$(shell $(FIND) .$/description -name "description_*.txt") $(i:f)) 247*cdf0e10cSrcweirEXISTING_LANGS=$(foreach,i,$(EXISTING_DESCRIPTIONS) $(i:s,description_,,:s,.txt,,)) 248*cdf0e10cSrcweir 249*cdf0e10cSrcweir# then, create a version of WITH_LANG where we stripped all those locales 250*cdf0e10cSrcweirEXISTING_LANGS_NORMALIZED=$(strip $(EXISTING_LANGS)) 251*cdf0e10cSrcweirEXISTING_LANGS_NORMALIZED:=+$(EXISTING_LANGS_NORMALIZED:s/ /+/)+ 252*cdf0e10cSrcweirMISSING_LANGS=$(foreach,lang,$(WITH_LANG) $(eq,$(EXISTING_LANGS_NORMALIZED:s/+$(lang)+//),$(EXISTING_LANGS_NORMALIZED) $(lang) )) 253*cdf0e10cSrcweir 254*cdf0e10cSrcweir# ........ dependencies for packaging the extension ........ 255*cdf0e10cSrcweirEXTENSION_PACKDEPS=makefile.mk $(COMPONENT_IMAGES) $(COMPONENT_DESCRIPTIONS_PACKDEP) $(COMPONENT_MERGED_XCU) 256*cdf0e10cSrcweir 257*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL)" != "YES" 258*cdf0e10cSrcweirEXTENSION_PACKDEPS+=$(COMPONENT_MYSQL_LIBFILE) 259*cdf0e10cSrcweir.ENDIF 260*cdf0e10cSrcweir 261*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL_CPPCONN)" != "YES" 262*cdf0e10cSrcweirEXTENSION_PACKDEPS+=$(COMPONENT_MYSQL_CPPCONN_FILE) 263*cdf0e10cSrcweir.ENDIF 264*cdf0e10cSrcweir 265*cdf0e10cSrcweir# --- Targets ------------------------------------------------------ 266*cdf0e10cSrcweir.INCLUDE : extension_pre.mk 267*cdf0e10cSrcweir.INCLUDE : target.mk 268*cdf0e10cSrcweir.INCLUDE : extension_post.mk 269*cdf0e10cSrcweir 270*cdf0e10cSrcweir$(COMPONENT_IMAGES) : $(SOLARSRC)$/$(RSCDEFIMG)$/desktop$/res$/$$(@:f) 271*cdf0e10cSrcweir @@-$(MKDIRHIER) $(@:d) 272*cdf0e10cSrcweir $(COPY) $< $@ 273*cdf0e10cSrcweir 274*cdf0e10cSrcweir# existing descriptions: just copy 275*cdf0e10cSrcweir$(EXTENSIONDIR)$/description$/%.txt: .$/description$/%.txt 276*cdf0e10cSrcweir @@-$(MKDIRHIER) $(@:d) 277*cdf0e10cSrcweir @$(COPY) $< $@ > $(NULLDEV) 278*cdf0e10cSrcweir 279*cdf0e10cSrcweir# xcu files: copy 280*cdf0e10cSrcweir# the following is a hack for now - need to find out the generic mechanism later 281*cdf0e10cSrcweir 282*cdf0e10cSrcweir$(EXTENSIONDIR)$/registry$/data$/org$/openoffice$/Office$/DataAccess$/Drivers.xcu : .$/registry$/data$/org$/openoffice$/Office$/DataAccess$/Drivers.xcu 283*cdf0e10cSrcweir @@-$(MKDIRHIER) $(EXTENSIONDIR)$/registry$/data$/org$/openoffice$/Office$/DataAccess 284*cdf0e10cSrcweir @$(COPY) $< $(EXTENSIONDIR)$/registry$/data$/org$/openoffice$/Office$/DataAccess$/Drivers.xcu > $(NULLDEV) 285*cdf0e10cSrcweir 286*cdf0e10cSrcweir# The below doesn't work - it's completely beyond me .... $@ is some strange path when echoed, so the whole construct 287*cdf0e10cSrcweir# doesn't work .... :( 288*cdf0e10cSrcweir 289*cdf0e10cSrcweir#$(foreach,i,$(COMPONENT_XCU) $(EXTENSIONDIR)$/$i : $i) 290*cdf0e10cSrcweir# @echo ----------------- 291*cdf0e10cSrcweir# @echo $@ 292*cdf0e10cSrcweir# @echo $< 293*cdf0e10cSrcweir# @echo ----------------- 294*cdf0e10cSrcweir# -$(MKDIRHIER) $(@:d) 295*cdf0e10cSrcweir# (COPY) $< $@ 296*cdf0e10cSrcweir# @echo ----------------- 297*cdf0e10cSrcweir 298*cdf0e10cSrcweir# non-existing descriptions: copy from the English version 299*cdf0e10cSrcweir.IF "$(strip $(MISSING_LANGS))" != "" 300*cdf0e10cSrcweir$(foreach,i,$(MISSING_LANGS) $(EXTENSIONDIR)$/description$/description_$i.txt): .$/description$/description_en-US.txt 301*cdf0e10cSrcweir @echo ------ WARNING: .$/description$/$(@:f) not found, falling back to English description 302*cdf0e10cSrcweir @@-$(MKDIRHIER) $(@:d) 303*cdf0e10cSrcweir @$(COPY) $< $@ > $(NULLDEV) 304*cdf0e10cSrcweir.ENDIF 305*cdf0e10cSrcweir 306*cdf0e10cSrcweir$(DESCRIPTION_SRC): description.xml 307*cdf0e10cSrcweir +-$(RM) $@ 308*cdf0e10cSrcweir $(TYPE) description.xml | $(SED) "s/#VERSION#/$(EXTENSION_VERSION)/" | $(SED) "s,#TITLE#,$(EXTENSION_TITLE)," > $@ 309*cdf0e10cSrcweir 310*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL)" != "YES" 311*cdf0e10cSrcweir# --- the MySQL client lib needs to be copied 312*cdf0e10cSrcweir$(COMPONENT_MYSQL_LIBFILE): $(MYSQL_LIBFILE) 313*cdf0e10cSrcweir @@-$(MKDIRHIER) $(@:d) 314*cdf0e10cSrcweir @$(COPY) $< $@ > $(NULLDEV) 315*cdf0e10cSrcweir .IF "$(OS)" == "MACOSX" 316*cdf0e10cSrcweir install_name_tool -id @__________________________________________________OOO/$(MYSQL_LIBFILE:f) $@ 317*cdf0e10cSrcweir .ENDIF 318*cdf0e10cSrcweir.ENDIF 319*cdf0e10cSrcweir 320*cdf0e10cSrcweir.IF "$(SYSTEM_MYSQL_CPPCONN)" != "YES" 321*cdf0e10cSrcweir# --- the MySQL cppconn lib needs to be copied 322*cdf0e10cSrcweir$(COMPONENT_MYSQL_CPPCONN_FILE): $(MYSQL_CPPCONNFILE) 323*cdf0e10cSrcweir @@-$(MKDIRHIER) $(@:d) 324*cdf0e10cSrcweir @$(COPY) $< $@ > $(NULLDEV) 325*cdf0e10cSrcweir .IF "$(OS)" == "MACOSX" 326*cdf0e10cSrcweir install_name_tool -change $(MYSQL_LIBFILE:f) @loader_path/$(MYSQL_LIBFILE:f) $@ 327*cdf0e10cSrcweir .ENDIF 328*cdf0e10cSrcweir.ENDIF 329*cdf0e10cSrcweir 330*cdf0e10cSrcweir.IF "$(OS)" == "MACOSX" 331*cdf0e10cSrcweir$(EXTENSION_TARGET): adjust_libmysql_path 332*cdf0e10cSrcweir 333*cdf0e10cSrcweiradjust_libmysql_path: $(EXTENSIONDIR)$/$(SHL1TARGET)$(DLLPOST) 334*cdf0e10cSrcweir install_name_tool -change $(MYSQL_LIBFILE:f) @loader_path/$(MYSQL_LIBFILE:f) $(EXTENSIONDIR)$/$(SHL1TARGET)$(DLLPOST) 335*cdf0e10cSrcweir.ENDIF 336