Peenoo / javacv

Automatically exported from code.google.com/p/javacv
GNU General Public License v2.0
0 stars 0 forks source link

No simple way to compile and package (with Maven) from source #202

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Can you create instruction?

What I tried to do:

1) git clone https://code.google.com/p/javacpp/
cd javacpp/javacpp && mvn install

2) git clone https://code.google.com/p/javacv/
cd javacv/javacv && mvn package

Seems like missing dependecines:

package com.jogamp.common.os does not exist
package javax.media.opengl does not exist

and a lot of:

cannot find symbol
[ERROR] symbol  : class CLImage2d
[ERROR] location: class com.googlecode.javacv.ProCamTransformerCL

Original issue reported on code.google.com by kuznetsov.alexey on 13 May 2012 at 10:05

GoogleCodeExporter commented 9 years ago
Yes, I should add to the pom.xml file any dependencies that might reasonable be 
available in some Maven repository somewhere, thanks for reporting this. I 
think that is pretty much limited to JogAmp's JOCL and JOGL though, do you see 
any other?

For the rest of the native dependencies, we either need to install them 
manually or remove the source files that depend on them, manually, and then 
"mvn install" or whatever as mentioned in the README.txt file. I haven't 
thought of any better ways at the moment, have you?

Original comment by samuel.a...@gmail.com on 14 May 2012 at 2:36

GoogleCodeExporter commented 9 years ago
package com.jogamp.opencl
package javax.media.opengl.glu
package com.jogamp.opencl.gl
package javax.media.opengl

maven can build c/cpp code and you can build opengl librarys too. i havent did 
it yet, this what i'm going to investigate.

what I did: put all natives to the jar (libtorrent-mac.jar) install it to the 
local maven repo and unpack them with maven-natives-plugin on the package stage 
to be abble to run application without installing librarys to the system folder.

i dont know if it gonna help or not. This project is completely new, and i dont 
know architecture or the way you doing things.

for 'mvn install' (manual makefile, just to reach to goal, better if it done 
with automake and maven cpp)

http://code.google.com/p/mircle/source/browse/bindings/java/libtorrent/Makefile?
repo=libtorrent&name=libtorrent-0.16.0

for 'maven-nativedependencies-plugin'

http://code.google.com/p/mircle/source/browse/bindings/java/pom.xml?repo=libtorr
ent&name=libtorrent-0.16.0

Original comment by kuznetsov.alexey on 14 May 2012 at 7:43

Attachments:

GoogleCodeExporter commented 9 years ago
What you are trying to do is kind of related to issue #146 I guess...

Original comment by samuel.a...@gmail.com on 14 May 2012 at 7:49

GoogleCodeExporter commented 9 years ago
I've added a new sort of Maven repository 
http://maven2.javacv.googlecode.com/git/ that we can use inside pom.xml files.

Is the sufficient for your needs? Or are you actually looking into recompiling 
JavaCV?

Original comment by samuel.a...@gmail.com on 27 May 2012 at 1:22

GoogleCodeExporter commented 9 years ago
the same errors.

im trying to use javacv in the simple way. produce working javacv by running 
mvn package. that is it.

Original comment by kuznetsov.alexey on 28 May 2012 at 8:48

GoogleCodeExporter commented 9 years ago
Well, to rebuild JavaCV you will need to install manually all the dependencies 
or remove source files you do not need, as instructed in the README.txt file. 
So this is not the "simple way".

Original comment by samuel.a...@gmail.com on 28 May 2012 at 1:15

GoogleCodeExporter commented 9 years ago

Original comment by samuel.a...@gmail.com on 1 Jun 2012 at 2:18

GoogleCodeExporter commented 9 years ago
It'd be nice if you put all java cv dependencies that are not in any other 
repository(jogamp+opencl) into your http://maven2.javacv.googlecode.com/git/ so 
every1 could be able to build javacv from clean checkout without removing any 
classes.
Also seems like Pro* classes should be in another maven module may be javacv 
project should have 2 or more modules.. something like that

Original comment by Jkolo...@gmail.com on 2 Jun 2012 at 8:00

GoogleCodeExporter commented 9 years ago
Actually at least javacv/cpp should be separated from everything else.

Original comment by Jkolo...@gmail.com on 2 Jun 2012 at 8:03

GoogleCodeExporter commented 9 years ago
The problem is that none of the dependencies have Maven artifacts. Someone 
would have to make them all. Feel like creating and maintaining them?

Sure, JavaCV could be split and stuff, but it won't save much space. People 
that do care use ProGuard and that takes of that anyway.

Original comment by samuel.a...@gmail.com on 2 Jun 2012 at 9:21

GoogleCodeExporter commented 9 years ago
They don't have to have maven artifacts. You can any groupId and artifactId and 
then import them into your remote repo 
(http://maven2.javacv.googlecode.com/git/)
http://maven.apache.org/guides/mini/guide-3rd-party-jars-remote.html

And then everyone will be able to download the dependencies from here 
automatically

Original comment by Jkolo...@gmail.com on 2 Jun 2012 at 11:26

GoogleCodeExporter commented 9 years ago
None of the source code of these dependencies come in JAR files. Would you 
volunteer to "JARify" everything, and maintain it?

Original comment by samuel.a...@gmail.com on 3 Jun 2012 at 1:12

GoogleCodeExporter commented 9 years ago
Ok. I was able to build gluegen jogl and jocl for mac. Looks like importing is 
going to be a pain in the butt because it produces 20+ jar files only for mac. 
But I'll try)

Original comment by Jkolo...@gmail.com on 3 Jun 2012 at 5:41

GoogleCodeExporter commented 9 years ago
Ok, thanks, but JogAmp should not be our main concern at this moment. If we 
can't do it with OpenCV, the rest is pretty much pointless IMO.

Original comment by samuel.a...@gmail.com on 3 Jun 2012 at 5:48

GoogleCodeExporter commented 9 years ago
Got it. I'll try to do the same with opencv.

Original comment by Jkolo...@gmail.com on 3 Jun 2012 at 6:12

GoogleCodeExporter commented 9 years ago
Hello. I've jarifyed opencv 2.4.1 for mac unix and win. I hope this is what you 
wanted to get. however it still needs some mechanism to extract it at runtime.
Also there are some scripts to build opencv for unix and mac and another one 
that downloads all jogamp.
http://goo.gl/xWOaw
Let me know what you think.

Original comment by Jkolo...@gmail.com on 4 Jun 2012 at 9:56

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
The same in one file http://goo.gl/A4ry6

Original comment by Jkolo...@gmail.com on 4 Jun 2012 at 10:19

GoogleCodeExporter commented 9 years ago
That looks interesting. When you say "Unix" do you mean "Linux"? Obviously we 
would need something that can build for all three platforms, and with Maven, 
since that is the goal here I think.

As for runtime, JavaCPP can do it just fine by itself. We just need to put the 
binaries in the right package as explained on this Wiki page:
http://code.google.com/p/javacv/wiki/HowToMakeAnApplet

Original comment by samuel.a...@gmail.com on 5 Jun 2012 at 1:10

GoogleCodeExporter commented 9 years ago
Yes. I mean linux. 
fixed according to wiki http://goo.gl/xWOaw

Original comment by Jkolo...@gmail.com on 5 Jun 2012 at 7:12

GoogleCodeExporter commented 9 years ago
Great thanks, starting to look good! So, is there a way to get this all 
compiled and packaged with just "mvn package"?

Original comment by samuel.a...@gmail.com on 5 Jun 2012 at 7:16

GoogleCodeExporter commented 9 years ago
yes. maven-exec-plugin http://mojo.codehaus.org/exec-maven-plugin/ allows to 
execute any script.
Actually I don't thik we need to build opencv everytime  we do mvn package. We 
can just put these prebuilt jars into our maven repo set them as dependencies 
and let everyone download it.

Original comment by Jkolo...@gmail.com on 5 Jun 2012 at 7:21