huanganhen / javacv

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

How to build javacv with it's FFMEG components on Windows #431

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Download the latest JavaCV source
2. Download ffmpeg2.1.1 shared & dev builds from http://ffmpeg.zeranoe.com/
3. modify avutil.java (add include & linkpath)
4. mvn clean install -Pplatform.name=windows-x86_64 -Pffmpeg

What version of the product are you using? On what operating system?
The latest version of the source code on windows 7 64 bit

Please provide any additional information below.

This is the output of mvn

jniavutil.cpp
C:\JavaCV\javacv\target\classes\com\googlecode\javacv\cpp\jniavutil.cpp(1252) :
warning C4800: 'jboolean': Variable wird auf booleschen Wert ('True' oder 'False
') gesetzt (Auswirkungen auf Leistungsverhalten möglich)
C:\JavaCV\javacv\target\classes\com\googlecode\javacv\cpp\jniavutil.cpp(6406) :
warning C4244: 'Initialisierung': Konvertierung von 'float' in 'int', möglicher
Datenverlust
C:\JavaCV\javacv\target\classes\com\googlecode\javacv\cpp\jniavutil.cpp(6412) :
warning C4244: 'Initialisierung': Konvertierung von 'float' in 'int', möglicher
Datenverlust
Microsoft (R) Incremental Linker Version 12.00.21005.1
Copyright (C) Microsoft Corporation.  All rights reserved.

/out:jniavutil.dll
/ltcg
/dll
/implib:jniavutil.lib
/OUT:C:\JavaCV\javacv\target\classes\com\googlecode\javacv\cpp\windows-x86_64\jn
iavutil.dll
/LIBPATH:C:/JavaCV/ffmpeg/lib
avutil.lib
jniavutil.obj
   Bibliothek "jniavutil.lib" und Objekt "jniavutil.exp" werden erstellt.
jniavutil.obj : error LNK2001: Nicht aufgel÷stes externes Symbol 
"av_pix_fmt_des
criptors".
C:\JavaCV\javacv\target\classes\com\googlecode\javacv\cpp\windows-x86_64\jniavut
il.dll : fatal error LNK1120: 1 nicht aufgel÷ste Externe
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 36.141s
[INFO] Finished at: Wed Feb 12 18:18:05 CET 2014
[INFO] Final Memory: 21M/263M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:exec (jav
acpp) on project javacv: Command execution failed. Process exited with an error:
 2(Exit value: 2) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
ch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please rea
d the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionE
xception
C:\JavaCV\javacv>

Original issue reported on code.google.com by chris.we...@gmail.com on 12 Feb 2014 at 5:23

GoogleCodeExporter commented 9 years ago
Right, that's another small thing we need to modify. Here's a patch that never 
made it into FFmpeg:
http://ffmpeg.org/pipermail/ffmpeg-devel/2012-May/124142.html
And we need to do the same thing for pp_help, too.

I should document that somewhere, but I'm probably going to include that in 
future build scripts for the JavaCPP Presets anyway:
http://code.google.com/p/javacpp/wiki/Presets

At the very least, I'll keep this issue up as a reminder, thanks!

Original comment by samuel.a...@gmail.com on 15 Feb 2014 at 6:26

GoogleCodeExporter commented 9 years ago
I've added everything in the cppbuild.sh scripts of the presets. Check it out:
http://code.google.com/p/javacpp/wiki/Presets
and let me know if you encounter anything missing, thanks!

Original comment by samuel.a...@gmail.com on 1 Apr 2014 at 12:23

GoogleCodeExporter commented 9 years ago
All the nitty-gritty about how to build the native libraries has been included 
as scripts in the latest release of JavaCPP and JavaCV 0.8. A lot of other 
things have changed with this new version, so please make sure to read the news 
release here:
    http://bytedeco.org/release/2014/04/28/first-release.html

Incidentally, the project is now hosted on GitHub:
    https://github.com/bytedeco/javacv

Enjoy!

Original comment by samuel.a...@gmail.com on 29 Apr 2014 at 1:24