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=canvas 31*cdf0e10cSrcweirTARGET=directx9canvas 32*cdf0e10cSrcweirTARGET2=directx5canvas 33*cdf0e10cSrcweirTARGET3=gdipluscanvas 34*cdf0e10cSrcweirENABLE_EXCEPTIONS=TRUE 35*cdf0e10cSrcweir 36*cdf0e10cSrcweir 37*cdf0e10cSrcweir# --- Settings ----------------------------------------------------------- 38*cdf0e10cSrcweir 39*cdf0e10cSrcweir.INCLUDE : settings.mk 40*cdf0e10cSrcweirDLLPRE = 41*cdf0e10cSrcweir 42*cdf0e10cSrcweir# --- Nothing to do if we're compiling with --disable-directx ----------- 43*cdf0e10cSrcweir.IF "$(ENABLE_DIRECTX)" == "" 44*cdf0e10cSrcweir@all: 45*cdf0e10cSrcweir @echo "Building without DirectX support..." 46*cdf0e10cSrcweir.ENDIF 47*cdf0e10cSrcweir 48*cdf0e10cSrcweir 49*cdf0e10cSrcweir# --- Common ---------------------------------------------------------- 50*cdf0e10cSrcweir 51*cdf0e10cSrcweir.IF "$(verbose)"!="" || "$(VERBOSE)"!="" 52*cdf0e10cSrcweirCDEFS+= -DVERBOSE 53*cdf0e10cSrcweir.ENDIF 54*cdf0e10cSrcweir 55*cdf0e10cSrcweir.IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!="" 56*cdf0e10cSrcweirCDEFS+= -DDX_DEBUG_IMAGES 57*cdf0e10cSrcweir.ENDIF 58*cdf0e10cSrcweir 59*cdf0e10cSrcweir# --- This is Windows only! { ---------------------------------------------------------------- 60*cdf0e10cSrcweir 61*cdf0e10cSrcweir.IF "$(GUI)" == "WNT" 62*cdf0e10cSrcweir 63*cdf0e10cSrcweirSHARED_SLOFILES = \ 64*cdf0e10cSrcweir $(SLO)$/dx_bitmap.obj \ 65*cdf0e10cSrcweir $(SLO)$/dx_bitmapcanvashelper.obj \ 66*cdf0e10cSrcweir $(SLO)$/dx_canvasbitmap.obj \ 67*cdf0e10cSrcweir $(SLO)$/dx_canvasfont.obj \ 68*cdf0e10cSrcweir $(SLO)$/dx_canvashelper.obj \ 69*cdf0e10cSrcweir $(SLO)$/dx_canvashelper_texturefill.obj \ 70*cdf0e10cSrcweir $(SLO)$/dx_devicehelper.obj \ 71*cdf0e10cSrcweir $(SLO)$/dx_gdiplususer.obj \ 72*cdf0e10cSrcweir $(SLO)$/dx_impltools.obj \ 73*cdf0e10cSrcweir $(SLO)$/dx_linepolypolygon.obj \ 74*cdf0e10cSrcweir $(SLO)$/dx_textlayout.obj \ 75*cdf0e10cSrcweir $(SLO)$/dx_textlayout_drawhelper.obj \ 76*cdf0e10cSrcweir $(SLO)$/dx_vcltools.obj 77*cdf0e10cSrcweir 78*cdf0e10cSrcweirDX_SLOFILES = \ 79*cdf0e10cSrcweir $(SLO)$/dx_5rm.obj \ 80*cdf0e10cSrcweir $(SLO)$/dx_9rm.obj \ 81*cdf0e10cSrcweir $(SLO)$/dx_canvascustomsprite.obj \ 82*cdf0e10cSrcweir $(SLO)$/dx_config.obj \ 83*cdf0e10cSrcweir $(SLO)$/dx_spritecanvas.obj \ 84*cdf0e10cSrcweir $(SLO)$/dx_spritecanvashelper.obj \ 85*cdf0e10cSrcweir $(SLO)$/dx_spritedevicehelper.obj \ 86*cdf0e10cSrcweir $(SLO)$/dx_spritehelper.obj \ 87*cdf0e10cSrcweir $(SLO)$/dx_surfacebitmap.obj \ 88*cdf0e10cSrcweir $(SLO)$/dx_surfacegraphics.obj 89*cdf0e10cSrcweirDX_SLOFILES += $(SHARED_SLOFILES) 90*cdf0e10cSrcweir 91*cdf0e10cSrcweirGDIPLUS_SLOFILES = \ 92*cdf0e10cSrcweir $(SLO)$/dx_canvas.obj 93*cdf0e10cSrcweirGDIPLUS_SLOFILES += $(SHARED_SLOFILES) 94*cdf0e10cSrcweir 95*cdf0e10cSrcweirSTDLIBS= $(CPPULIB) $(TKLIB) $(SALLIB) $(COMPHELPERLIB) $(CPPUHELPERLIB) $(BASEGFXLIB) $(CANVASTOOLSLIB) $(VCLLIB) $(TOOLSLIB) $(UNOTOOLSLIB) $(I18NISOLANGLIB) 96*cdf0e10cSrcweir 97*cdf0e10cSrcweir 98*cdf0e10cSrcweir######################################################## 99*cdf0e10cSrcweir# DX9 100*cdf0e10cSrcweir######################################################## 101*cdf0e10cSrcweir 102*cdf0e10cSrcweir# Indicates the source obj files for the dx5 lib 103*cdf0e10cSrcweirLIB1TARGET= $(SLB)$/$(TARGET).lib 104*cdf0e10cSrcweirLIB1OBJFILES = $(DX_SLOFILES) 105*cdf0e10cSrcweir 106*cdf0e10cSrcweir# Indicates the filename of the shared library. 107*cdf0e10cSrcweirSHL1TARGET=$(TARGET).uno 108*cdf0e10cSrcweir 109*cdf0e10cSrcweir# Links import libraries. 110*cdf0e10cSrcweirSHL1STDLIBS= $(STDLIBS) 111*cdf0e10cSrcweir 112*cdf0e10cSrcweir# Specifies an import library to create. For Win32 only. 113*cdf0e10cSrcweirSHL1IMPLIB=i$(TARGET) 114*cdf0e10cSrcweir 115*cdf0e10cSrcweir# Specifies libraries from the same module to put into the shared library. 116*cdf0e10cSrcweirSHL1LIBS=$(SLB)$/$(TARGET).lib 117*cdf0e10cSrcweir 118*cdf0e10cSrcweirSHL1DEF=$(MISC)$/$(SHL1TARGET).def 119*cdf0e10cSrcweir 120*cdf0e10cSrcweirDEF1NAME=$(SHL1TARGET) 121*cdf0e10cSrcweirDEF1EXPORTFILE=exports.dxp 122*cdf0e10cSrcweir 123*cdf0e10cSrcweirCDEFS+=-DDIRECTX_VERSION=0x0900 124*cdf0e10cSrcweir 125*cdf0e10cSrcweirSHL1STDLIBS += $(GDI32LIB) 126*cdf0e10cSrcweir.IF "$(COM)" == "GCC" 127*cdf0e10cSrcweirSHL1STDLIBS += $(DIRECTXSDK_LIB)/d3d9.lib 128*cdf0e10cSrcweir.ELSE 129*cdf0e10cSrcweirSHL1STDLIBS += d3d9.lib 130*cdf0e10cSrcweir.ENDIF 131*cdf0e10cSrcweirSHL1STDLIBS += $(GDIPLUSLIB) 132*cdf0e10cSrcweir 133*cdf0e10cSrcweir.IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!="" 134*cdf0e10cSrcweirSHL1STDLIBS += imdebug.lib 135*cdf0e10cSrcweir.ENDIF 136*cdf0e10cSrcweir 137*cdf0e10cSrcweir 138*cdf0e10cSrcweir######################################################## 139*cdf0e10cSrcweir# DX5 140*cdf0e10cSrcweir######################################################## 141*cdf0e10cSrcweir 142*cdf0e10cSrcweir.IF "$(USE_DIRECTX5)" != "" 143*cdf0e10cSrcweirSECOND_BUILD=DX5 144*cdf0e10cSrcweirDX5_SLOFILES=$(DX_SLOFILES) 145*cdf0e10cSrcweirDX5CDEFS += -DDIRECTX_VERSION=0x0500 146*cdf0e10cSrcweir 147*cdf0e10cSrcweirLIB2TARGET= $(SLB)$/$(TARGET2).lib 148*cdf0e10cSrcweirLIB2OBJFILES = $(REAL_DX5_SLOFILES) 149*cdf0e10cSrcweir 150*cdf0e10cSrcweir# Indicates the filename of the shared library. 151*cdf0e10cSrcweirSHL2TARGET=$(TARGET2).uno 152*cdf0e10cSrcweir 153*cdf0e10cSrcweir# Links import libraries. 154*cdf0e10cSrcweirSHL2STDLIBS= $(STDLIBS) 155*cdf0e10cSrcweir 156*cdf0e10cSrcweir# Specifies an import library to create. For Win32 only. 157*cdf0e10cSrcweirSHL2IMPLIB=i$(TARGET2).lib 158*cdf0e10cSrcweir 159*cdf0e10cSrcweir# Specifies libraries from the same module to put into the shared library. 160*cdf0e10cSrcweirSHL2LIBS=$(SLB)$/$(TARGET2).lib 161*cdf0e10cSrcweirSHL2DEF=$(MISC)$/$(SHL2TARGET).def 162*cdf0e10cSrcweir 163*cdf0e10cSrcweirDEF2NAME=$(SHL2TARGET) 164*cdf0e10cSrcweirDEF2EXPORTFILE=exports.dxp 165*cdf0e10cSrcweir 166*cdf0e10cSrcweirSHL2STDLIBS += $(GDI32LIB) 167*cdf0e10cSrcweirSHL2STDLIBS += $(DDRAWLIB) 168*cdf0e10cSrcweirSHL2STDLIBS += $(GDIPLUSLIB) 169*cdf0e10cSrcweir 170*cdf0e10cSrcweir.IF "$(COM)" == "GCC" 171*cdf0e10cSrcweirSHL2STDLIBS += $(DIRECTXSDK_LIB)/d3dx.lib 172*cdf0e10cSrcweir.ELSE 173*cdf0e10cSrcweirSHL2STDLIBS += d3dx.lib 174*cdf0e10cSrcweir.ENDIF 175*cdf0e10cSrcweir 176*cdf0e10cSrcweir.IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!="" 177*cdf0e10cSrcweirSHL2STDLIBS += imdebug.lib 178*cdf0e10cSrcweir.ENDIF 179*cdf0e10cSrcweir.ENDIF # IF "$(USE_DIRECTX5)" != "" 180*cdf0e10cSrcweir 181*cdf0e10cSrcweir 182*cdf0e10cSrcweir######################################################## 183*cdf0e10cSrcweir# GDI+ 184*cdf0e10cSrcweir######################################################## 185*cdf0e10cSrcweir 186*cdf0e10cSrcweirLIB3TARGET= $(SLB)$/$(TARGET3).lib 187*cdf0e10cSrcweirLIB3OBJFILES = $(GDIPLUS_SLOFILES) 188*cdf0e10cSrcweir 189*cdf0e10cSrcweir# Indicates the filename of the shared library. 190*cdf0e10cSrcweirSHL3TARGET=$(TARGET3).uno 191*cdf0e10cSrcweir 192*cdf0e10cSrcweir# Links import libraries. 193*cdf0e10cSrcweirSHL3STDLIBS= $(CPPULIB) $(TKLIB) $(SALLIB) $(COMPHELPERLIB) $(CPPUHELPERLIB) $(BASEGFXLIB) $(CANVASTOOLSLIB) $(VCLLIB) $(TOOLSLIB) $(UNOTOOLSLIB) $(I18NISOLANGLIB) 194*cdf0e10cSrcweir 195*cdf0e10cSrcweir# Specifies an import library to create. For Win32 only. 196*cdf0e10cSrcweirSHL3IMPLIB=i$(TARGET3).lib 197*cdf0e10cSrcweir 198*cdf0e10cSrcweir# Specifies libraries from the same module to put into the shared library. 199*cdf0e10cSrcweirSHL3LIBS=$(SLB)$/$(TARGET3).lib 200*cdf0e10cSrcweirSHL3DEF=$(MISC)$/$(SHL3TARGET).def 201*cdf0e10cSrcweir 202*cdf0e10cSrcweirDEF3NAME=$(SHL3TARGET) 203*cdf0e10cSrcweirDEF3EXPORTFILE=exports.dxp 204*cdf0e10cSrcweir 205*cdf0e10cSrcweirSHL3STDLIBS += $(GDI32LIB) 206*cdf0e10cSrcweirSHL3STDLIBS += $(GDIPLUSLIB) 207*cdf0e10cSrcweir 208*cdf0e10cSrcweir.IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!="" 209*cdf0e10cSrcweirSHL3STDLIBS += imdebug.lib 210*cdf0e10cSrcweir.ENDIF 211*cdf0e10cSrcweir 212*cdf0e10cSrcweir.ENDIF # IF "$(GUI)" == "WNT" 213*cdf0e10cSrcweir 214*cdf0e10cSrcweir# --- This is Windows only! } ---------------------------------------------------------------- 215*cdf0e10cSrcweir 216*cdf0e10cSrcweir# ========================================================================== 217*cdf0e10cSrcweir 218*cdf0e10cSrcweir.INCLUDE : target.mk 219*cdf0e10cSrcweir 220*cdf0e10cSrcweirALLTAR : \ 221*cdf0e10cSrcweir $(MISC)/directx5canvas.component \ 222*cdf0e10cSrcweir $(MISC)/directx9canvas.component \ 223*cdf0e10cSrcweir $(MISC)/gdipluscanvas.component 224*cdf0e10cSrcweir 225*cdf0e10cSrcweir$(MISC)/directx5canvas.component .ERRREMOVE : \ 226*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt directx5canvas.component 227*cdf0e10cSrcweir $(XSLTPROC) --nonet --stringparam uri \ 228*cdf0e10cSrcweir '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL2TARGETN:f)' -o $@ \ 229*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt directx5canvas.component 230*cdf0e10cSrcweir 231*cdf0e10cSrcweir$(MISC)/directx9canvas.component .ERRREMOVE : \ 232*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt directx9canvas.component 233*cdf0e10cSrcweir $(XSLTPROC) --nonet --stringparam uri \ 234*cdf0e10cSrcweir '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \ 235*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt directx9canvas.component 236*cdf0e10cSrcweir 237*cdf0e10cSrcweir$(MISC)/gdipluscanvas.component .ERRREMOVE : \ 238*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt gdipluscanvas.component 239*cdf0e10cSrcweir $(XSLTPROC) --nonet --stringparam uri \ 240*cdf0e10cSrcweir '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL3TARGETN:f)' -o $@ \ 241*cdf0e10cSrcweir $(SOLARENV)/bin/createcomponent.xslt gdipluscanvas.component 242