VirtualBox

source: vbox/trunk/src/VBox/Main/webservice/Makefile.webtest@ 61572

Last change on this file since 61572 was 61379, checked in by vboxsync, 9 years ago

Main/webservice: don't ship webtest any longer (to save space) and create a new SDK cpp example instead

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.4 KB
Line 
1#
2# Copyright (C) 2016 Oracle Corporation
3#
4# This file is part of VirtualBox Open Source Edition (OSE), as
5# available from http://www.virtualbox.org. This file is free software;
6# you can redistribute it and/or modify it under the terms of the GNU
7# General Public License (GPL) as published by the Free Software
8# Foundation, in version 2 as it comes in the "COPYING" file of the
9# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
10# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
11#
12
13XSLTPROC = xsltproc
14ifeq ($(PATH_GSOAP),)
15 PATH_GSOAP = $(lastword $(sort $(wildcard $(KBUILD_DEVTOOLS)/common/gsoap/*)))
16endif
17PATH_GSOAP_BIN := $(strip $(PATH_GSOAP))
18ifeq ($(PATH_GSOAP_BIN),)
19 PATH_GSOAP_BIN = /usr/bin
20endif
21SOAPCPP2 = $(PATH_GSOAP_BIN)/soapcpp2
22
23ifneq ($(MAKECMDGOALS),clean)
24 ifeq ($(wildcard $(PATH_GSOAP)/stdsoap2.cpp),)
25 $(error Fix PATH_GSOAP!)
26 endif
27endif
28
29WEBSRVWSDL2GSOAPH = ../../../xsl/websrv-wsdl2gsoapH.xsl
30WEBSRVNSMAPXSL = ../../../xsl/websrv-nsmap.xsl
31VBOXWEBIDLSRC = ../../../../VirtualBox.xidl
32VBOXWEBWSDL = ../../../vboxweb.wsdl
33SPLITSOAPCCPP = ../../../tools/split-soapC.cpp
34SOAPCCPP = $(foreach num,1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20,soapC-$(num).cpp)
35SOAPCO = $(patsubst %.cpp,%.o,$(SOAPCCPP))
36
37webtest: webtest.o soapClient.o $(SOAPCO) stdsoap2.o
38 $(CXX) -O2 -o $@ $^ -lssl -lcrypto
39
40webtest.o: webtest.cpp soapC.cpp vboxwebsrv.nsmap
41 $(CXX) -O2 -DWITH_OPENSSL -c -o $@ $< -I$(PATH_GSOAP)
42
43soapClient.o: soapC.cpp
44 $(CXX) -O2 -c -o $@ soapClient.cpp -I$(PATH_GSOAP)
45
46$(SOAPCO): soapC-%.o: soapC-%.cpp
47 $(CXX) -O0 -c -o $@ $< -I$(PATH_GSOAP)
48
49soapC.cpp: gsoapH_from_xslt.h
50 $(SOAPCPP2) -x -L -2 -w -I$(PATH_GSOAP)/import $^
51
52stdsoap2.o: $(PATH_GSOAP)/stdsoap2.cpp
53 $(CXX) -O2 -DWITH_OPENSSL -c -o $@ $<
54
55gsoapH_from_xslt.h:
56 $(XSLTPROC) -o $@ $(WEBSRVWSDL2GSOAPH) $(VBOXWEBWSDL)
57
58vboxwebsrv.nsmap:
59 $(XSLTPROC) -o $@ $(WEBSRVNSMAPXSL) $(VBOXWEBIDLSRC)
60
61$(subst soapC,%,$(SOAPCCPP)): split-soapC %.cpp
62 ./split-soapC soapC.cpp . 20
63
64split-soapC: $(SPLITSOAPCCPP)
65 $(CXX) -O2 -o $@ $<
66
67.PHONY: clean
68clean:
69 rm -f gsoapH_from_xslt.h
70 rm -f soapStub.h soapServer.cpp soapC.cpp soapClient.cpp
71 rm -f soapH.h soapvboxBindingObject.h soapvboxBindingProxy.h
72 rm -f vboxBinding.nsmap
73 rm -f vboxwebsrv.nsmap
74 rm -f split-soapC
75 rm -f $(SOAPCCPP) $(SOAPCO)
76 rm -f soapClient.o stdsoap2.o
77 rm -f webtest.o webtest
78 rm -f soapC-split-done
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette