Skip to main content

compilation error in build HE4RI

10 replies [Last post]
yelin
Offline
Joined: 2010-06-30
Points: 0

Hi,

I followed the link below to build HE4RI, but had error in compile phase.
https://devzone.cablelabs.com/widget/web/ocapri/1/-/wiki/OCAP%20RI%20Pub...

The debug information says:
===================
[javac] /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/build.xml:268: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
[javac] Compiling 60 source files to /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/bin
[javac] /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/src/java/org/cablelabs/ocap/ri/he4ri/agents/EmulationExecutive.java:77: package org.cybergarage.net does not exist
[javac] import org.cybergarage.net.HostInterface;
[javac] ^
[javac] /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/src/java/org/cablelabs/ocap/ri/he4ri/agents/EmulationExecutive.java:78: package org.cybergarage.upnp does not exist
[javac] import org.cybergarage.upnp.Action;
[javac] ^
[javac] /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/src/java/org/cablelabs/ocap/ri/he4ri/agents/EmulationExecutive.java:79: package org.cybergarage.upnp does not exist
[javac] import org.cybergarage.upnp.Device;
[javac] ^
[javac] /home/yelin/CableLabsRI/trunk/emu/HeDri/Emulator/src/java/org/cablelabs/ocap/ri/he4ri/agents/EmulationExecutive.java:80: package org.cybergarage.upnp does not exist
[javac] import org.cybergarage.upnp.StateVariable;
========================

Then it just dumped out all undefined symbol errors. I guess I probably missed some jar packages, but I don't know where they are located. Could anyone here help me with that?

Thanks,

Yenan

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
yelin
Offline
Joined: 2010-06-30
Points: 0

I wrote a simple "hello ocap" xlet (HelloOCAP.java) and try to compile it into .class file.

I put the following line into my shell script:

${JAVA_HOME}/bin/javac -bootclasspath ${OCAPROOT}/jvm/phoneME/phoneME/build/mpe-x86-linuxgcc/btclasses.zip;${OCAP_ENV}/cvm/lib/basis.jar;${OCAPROOT}/bin/($OCAPTC}/sys/*.jar src/*.java -d bin

I've verified that all paths above contains corresponding .jar files. Then I got errors saying "Failed to load Main-Class manifest attribute from ocap-classes.jar"... I unzipped ocap-classes.jar and found manifest.mf did not specify "Main-Class". I wonder how you compiled a qa app into .class file. Could anyone here help me with this question?

greg80303
Offline
Joined: 2008-07-03
Points: 0

When compiling your Xlets, I recommend that you just compile against the OCAP Stubs. The ocap stubs are built are part of the stack build system. You can find the jar in $OCAPROOT/bin/lib/ocap-stub.jar. This jar file contains all of the OCAP/MHP/HAVi/PBP/CDC class definitions that you would need to compile any OCAP application. If you do not build the stack yourself, you can compile against a released version of the stub jar file that you can get from the CableLabs website

[code]
${JAVA_HOME}/bin/javac -bootclasspath ${OCAPROOT}/bin/lib/ocap-stub.jar src/*.java -d bin
[/code]

G

yelin
Offline
Joined: 2010-06-30
Points: 0

I followed steps to compile OCAP-RI platform + stack and successfully launched circlesxlet app. However, when I used circlesxlet.class (compiled by "${JAVA_HOME}/bin/javac -bootclasspath ${OCAPROOT}/bin/lib/ocap-stub.jar src/*.java") the emulator image freezes after displaying
INFO RI.UI - Created Console.
INFO RI.UI.OpenGL.common - opengl_init_environment -- uiInfo->hw_acceleration_disabled:0
INFO RI.UI - window_init returning Window ID: -204
INFO RI.UI.FrontPanel - Creating the Indicator display: power.
INFO RI.UI.FrontPanel - Creating the Indicator display: remote.
INFO RI.UI.FrontPanel - Resetting the Text display: text.
INFO RI.UI.FrontPanel - Creating the Text display: text.

First i got some "FATAL ERROR WARNING INFO" output, then it says
20100804 19:07:33.560 WARN RI.Stack- 5881 [Thread-16] WARN util.Debug -
20100804 19:07:33.561 WARN RI.Stack- org.cybergarage.xml.ParserException: java.net.ConnectException: Unknown error
at org.cybergarage.xml.Parser.parse(Parser.java:58)
at org.cybergarage.upnp.ControlPoint.addDevice(ControlPoint.java:227)
at org.cybergarage.upnp.ControlPoint.notifyReceived(ControlPoint.java:469)
at org.cybergarage.upnp.ssdp.SSDPNotifySocket.run(SSDPNotifySocket.java:112)
at java.lang.Thread.run(Thread.java:715)
at java.lang.Thread.startup(Thread.java:785)
Caused by: java.net.ConnectException: Unknown error
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:337)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:203)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:190)
at java.net.Socket.connect(Socket.java:481)
at java.net.Socket.connect(Socket.java:434)
at sun.net.NetworkClient.doConnect(NetworkClient.java:159)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:428)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:644)
at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:747)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:674)
at org.cybergarage.xml.Parser.parse(Parser.java:48)
... 5 more

Any idea on this error?

sean_k
Offline
Joined: 2010-08-12
Points: 0

Did you got something for the "java.net.ConnectException" ?
I also have same problem on it.
Please let me know that if you already have been done it.
Thank you.

yelin
Offline
Joined: 2010-06-30
Points: 0

I haven't been able to run Circle Xlet compiled by myself. I compiled it as Greg told me, but i still got some errors...

mkorzen
Offline
Joined: 2008-03-05
Points: 0

HE4RI is optional and has actually been deprecated as of June 2010. The PC platform's UPnP Emulator now supplies equivalent functionality and in some areas, extends it (such as the CableCARD emulation).

There are no special steps required to compile or use the PC platform UPnP Emulator. The build and runtime execution environments already use it by default.

yelin
Offline
Joined: 2010-06-30
Points: 0

Thanks mkorzen, so I am not going to compile HE4RI. But how do I know that my fedora core 10 has got UPnP emulator?

Another question is, now that I build the platform and OCAP stack, how can I test them out with the emulator? (Is there something like wiki that can give me some hints.) Many thanks.

Message was edited by: yelin

mkorzen
Offline
Joined: 2008-03-05
Points: 0

UPnP Emulator is part of PC Platform. Source is under $PLATFORMROOT/src/dri. It gets compiled and included with the build by default. Does this answer your question? What kind of tests do you have in mind?
For more architecture/design details, you can refer to our recent training slides from June, available here: https://community.cablelabs.com/svn/OCAPRI/trunk/opensource_documents/Pr...
Specifically for this particular issue, I would reference slides 41, 42, 55 and 56.
Marcin

yelin
Offline
Joined: 2010-06-30
Points: 0

"What kind of tests do you have in mind?" -- Now that I've built the platform + stack +emulator, I guess I can run something like the Circle application. But I don't know how to do that.Could you give me some hints?

csweeney
Offline
Joined: 2009-04-11
Points: 0

I've added some information about how to run the Circles Xlet to the Wiki:
https://devzone.cablelabs.com/widget/web/ocapri/1/-/wiki/OCAP%20RI%20Pub...

Give it a try...