1*7871dc3eSAndrew Rist#************************************************************** 2*7871dc3eSAndrew Rist# 3*7871dc3eSAndrew Rist# Licensed to the Apache Software Foundation (ASF) under one 4*7871dc3eSAndrew Rist# or more contributor license agreements. See the NOTICE file 5*7871dc3eSAndrew Rist# distributed with this work for additional information 6*7871dc3eSAndrew Rist# regarding copyright ownership. The ASF licenses this file 7*7871dc3eSAndrew Rist# to you under the Apache License, Version 2.0 (the 8*7871dc3eSAndrew Rist# "License"); you may not use this file except in compliance 9*7871dc3eSAndrew Rist# with the License. You may obtain a copy of the License at 10*7871dc3eSAndrew Rist# 11*7871dc3eSAndrew Rist# http://www.apache.org/licenses/LICENSE-2.0 12*7871dc3eSAndrew Rist# 13*7871dc3eSAndrew Rist# Unless required by applicable law or agreed to in writing, 14*7871dc3eSAndrew Rist# software distributed under the License is distributed on an 15*7871dc3eSAndrew Rist# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*7871dc3eSAndrew Rist# KIND, either express or implied. See the License for the 17*7871dc3eSAndrew Rist# specific language governing permissions and limitations 18*7871dc3eSAndrew Rist# under the License. 19*7871dc3eSAndrew Rist# 20*7871dc3eSAndrew Rist#************************************************************** 21*7871dc3eSAndrew Rist 22*7871dc3eSAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweirPRJ := ..$/.. 25cdf0e10cSrcweirPRJNAME := cli_ure 26cdf0e10cSrcweirTARGET := test_climaker 27cdf0e10cSrcweirPACKAGE = climaker 28cdf0e10cSrcweir 29cdf0e10cSrcweir#we use the climaker which is build by this project 30cdf0e10cSrcweirCLIMAKER*=$(WRAPCMD) $(BIN)$/climaker 31cdf0e10cSrcweir.INCLUDE: settings.mk 32cdf0e10cSrcweir 33cdf0e10cSrcweir 34cdf0e10cSrcweir#----- compile .java files ----------------------------------------- 35cdf0e10cSrcweir 36cdf0e10cSrcweirJARFILES = ridl.jar unoil.jar jurt.jar juh.jar java_uno.jar OOoRunner.jar 37cdf0e10cSrcweirJAVAFILES = ClimakerTestCase.java 38cdf0e10cSrcweirJAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) 39cdf0e10cSrcweir 40cdf0e10cSrcweir#----- make a jar from compiled files ------------------------------ 41cdf0e10cSrcweir 42cdf0e10cSrcweirMAXLINELENGTH = 100000 43cdf0e10cSrcweir 44cdf0e10cSrcweirJARCLASSDIRS = $(PACKAGE) 45cdf0e10cSrcweirJARTARGET = $(TARGET).jar 46cdf0e10cSrcweirJARCOMPRESS = TRUE 47cdf0e10cSrcweir 48cdf0e10cSrcweir 49cdf0e10cSrcweir 50cdf0e10cSrcweirCSCFLAGS = -incr 51cdf0e10cSrcweir.IF "$(debug)" != "" 52cdf0e10cSrcweirCSCFLAGS += -checked+ -define:DEBUG -define:TRACE -debug+ 53cdf0e10cSrcweir.ELSE 54cdf0e10cSrcweirCSCFLAGS += -optimize+ 55cdf0e10cSrcweir.ENDIF 56cdf0e10cSrcweir 57cdf0e10cSrcweir 58cdf0e10cSrcweirOUTDIR=$(BIN)$/qa$/climaker 59cdf0e10cSrcweirEXETARGET=$(OUTDIR)$/test_climaker.exe 60cdf0e10cSrcweir 61cdf0e10cSrcweirALLTAR: $(EXETARGET) 62cdf0e10cSrcweir 63cdf0e10cSrcweirCSFILES = climaker.cs testobjects.cs 64cdf0e10cSrcweir 65cdf0e10cSrcweir 66cdf0e10cSrcweir$(EXETARGET): $(CSFILES) $(OUTDIR)$/cli_test_types.dll 67cdf0e10cSrcweir $(GNUCOPY) -p $(BIN)$/cli_cppuhelper.dll $(OUTDIR)$/cli_cppuhelper.dll 68cdf0e10cSrcweir $(GNUCOPY) -p $(BIN)$/cli_uretypes.dll $(OUTDIR)$/cli_uretypes.dll 69cdf0e10cSrcweir $(GNUCOPY) -p $(BIN)$/cli_basetypes.dll $(OUTDIR)$/cli_basetypes.dll 70cdf0e10cSrcweir $(GNUCOPY) -p $(BIN)$/cli_ure.dll $(OUTDIR)$/cli_ure.dll 71cdf0e10cSrcweir $(GNUCOPY) -p $(BIN)$/climaker.exe $(OUTDIR) 72cdf0e10cSrcweir $(CSC) $(CSCFLAGS) -target:exe -out:$(EXETARGET) \ 73cdf0e10cSrcweir -reference:$(BIN)$/cli_ure.dll \ 74cdf0e10cSrcweir -reference:$(BIN)$/cli_uretypes.dll \ 75cdf0e10cSrcweir -reference:$(BIN)$/cli_basetypes.dll \ 76cdf0e10cSrcweir -reference:$(OUTDIR)$/cli_test_types.dll \ 77cdf0e10cSrcweir $(CSFILES) 78cdf0e10cSrcweir 79cdf0e10cSrcweir 80cdf0e10cSrcweir 81cdf0e10cSrcweir#----------------------------------------------------------------------------- 82cdf0e10cSrcweirCLIMAKERFLAGS = 83cdf0e10cSrcweir.IF "$(debug)" != "" 84cdf0e10cSrcweirCLIMAKERFLAGS += --verbose 85cdf0e10cSrcweir.ENDIF 86cdf0e10cSrcweir 87cdf0e10cSrcweir 88cdf0e10cSrcweir 89cdf0e10cSrcweir 90cdf0e10cSrcweir$(OUTDIR)$/types.urd: types.idl 91cdf0e10cSrcweir - $(MKDIR) $(OUTDIR) 92cdf0e10cSrcweir $(IDLC) -O$(OUTDIR) -I$(SOLARIDLDIR) -cid -we $< 93cdf0e10cSrcweir 94cdf0e10cSrcweir$(OUTDIR)$/types.rdb: $(OUTDIR)$/types.urd 95cdf0e10cSrcweir - rm $@ 96cdf0e10cSrcweir $(REGMERGE) $@ /UCR $< 97cdf0e10cSrcweir 98cdf0e10cSrcweir$(OUTDIR)$/cli_test_types.dll: $(OUTDIR)$/types.rdb $(BIN)$/climaker.exe $(BIN)$/cli_uretypes.dll 99cdf0e10cSrcweir $(CLIMAKER) $(CLIMAKERFLAGS) --out $@ \ 100cdf0e10cSrcweir -r $(BIN)$/cli_uretypes.dll \ 101cdf0e10cSrcweir -X $(SOLARBINDIR)$/types.rdb \ 102cdf0e10cSrcweir $(OUTDIR)$/types.rdb 103cdf0e10cSrcweir 104cdf0e10cSrcweir 105cdf0e10cSrcweir 106cdf0e10cSrcweir.IF "$(depend)" == "" 107cdf0e10cSrcweirALL: ALLTAR 108cdf0e10cSrcweir.ELSE 109cdf0e10cSrcweirALL: ALLDEP 110cdf0e10cSrcweir.ENDIF 111cdf0e10cSrcweir 112cdf0e10cSrcweir.INCLUDE: target.mk 113cdf0e10cSrcweir 114cdf0e10cSrcweir# --- Parameters for the test -------------------------------------- 115cdf0e10cSrcweir 116cdf0e10cSrcweir# test base is java complex 117cdf0e10cSrcweirCT_TESTBASE = -TestBase java_complex 118cdf0e10cSrcweir 119cdf0e10cSrcweir# test looks something like the.full.package.TestName 120cdf0e10cSrcweirCT_TEST = -o $(PACKAGE:s\$/\.\).$(JAVAFILES:b) 121cdf0e10cSrcweir 122cdf0e10cSrcweir# start the runner application 123cdf0e10cSrcweirCT_APP = org.openoffice.Runner 124cdf0e10cSrcweir 125cdf0e10cSrcweirCT_NOOFFICE = -NoOffice 126cdf0e10cSrcweir# --- Targets ------------------------------------------------------ 127cdf0e10cSrcweir 128cdf0e10cSrcweirRUN: 129cdf0e10cSrcweir java -cp $(CLASSPATH) -Dcli_ure_test=$(EXETARGET) $(CT_APP) $(CT_NOOFFICE) $(CT_TESTBASE) $(CT_TEST) 130cdf0e10cSrcweir 131cdf0e10cSrcweirrun: RUN 132