User Tools

Site Tools


build:devel_2.6_msvc

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
build:devel_2.6_msvc [2018/01/01 12:09]
mean
build:devel_2.6_msvc [2018/01/01 12:29]
mean
Line 3: Line 3:
 You dont need to compile avidemux yourself to write your  own plugins.\\ You dont need to compile avidemux yourself to write your  own plugins.\\
 What you need is : What you need is :
-  * Avidemux installed on your system +  * Avidemux installed on your system ​, the version built with visual c++
-  * SDK component activated+
   * CMake > 3.x    * CMake > 3.x 
-  * A demo/sample video filter, available here {{ :build:videofilter.zip |}} +  ​* Optionnaly MSys installed, it's just simpler 
- +  * Visual c++ 2015 or 2017, Community edition is fine 
-== SDK === +  ​* A demo/sample video filter, available here {{ :build:videofilterdemo_2.7.zip |}}
-Make sure you have selected the SDK component during install +
- +
-{{:​build:​sdk1r.png?​200|}} +
  
  
Line 23: Line 18:
 ---- ----
  
-====== ​Cli : Compile the sample using MSYS2/​MinGW ​======+====== ​Let's go ======
  
-It is best to start here to make sure you have working environment+Start command prompt 
 +Call the vcvars64.bat from visual c++ binary dir, that will set up things 
 +Then start msys bash.exe shell
  
-Start a MSYS2 shell, go where you unzipped ​the demo code (i.e. c:​\tmp\videoFilterDemo for example )\\ +Go to the source folder of the demo and create the sln file 
-Create a build folder +  ​mkdir ​build 
-   mkdir build && ​cd build +  cd build 
-then generate the makefile +  cmake  -G "Visual Studio 14 2015 Win64" -DCMAKE_INSTALL_PREFIX="​c:​/Program Files/Avidemux 2.64bits" ​ ​-DVERBOSE=True -DCMAKE_BUILD_TYPE=Release ​..
-   cmake -G "MSYS Makefiles" ​-DCMAKE_MAKE_PROGRAM=mingw32-make ​-DCMAKE_INSTALL_PREFIX="​c:​\Program Files\Avidemux 2.64 bits" .. +
-    +
-__The CMAKE_INSTALL_PREFIX should point to the place where avidemux is__+
  
-Look for error, it should go without problem.\\ +If you just unzipped ​the files in a folder, use that folder
-   ​make +For example if you unzipped avidemux ​in Z:/​avidemux 
-Upon success, copy the dll in    ​c:​\Program Files\Avidemux 2.6 - 64 bits\plugins\videoFilters\ \\ +the command becomes 
-Start avidemux and you should see a logo_sample filter ​in the menu list+  cmake  -G "​Visual Studio 14 2015 Win64" -DCMAKE_INSTALL_PREFIX="​z:/​avidemux" ​ -DVERBOSE=True -DCMAKE_BUILD_TYPE=Release ..
  
-**Important/​Common ​problem** +Look for error, it should go without ​problem.
-----+
  
-If the C++ library used by mingw is more recent than the one used by avidemux itself ​you'll run into two problem :+If you dont want to use visual ​C++ ide , you can just 
 +     
 +  cmake --build . --target INSTALL
  
-  * If you have error undefined symbol _imp_xxxxstdcxx11xxxxbasic_stringxxx when compiling , add one line at the very top of CMakeLists.txt +If you want ot use the visual C++ ideyou can also load the generated ​.sln into visual ​c++
-   ​ADD_DEFINITIONS(-D_GLIBCXX_USE_CXX11_ABI=0) +
-  * If you have error at startup "​Cannot locate xyz in libsdtc+++"Overwrite ​the libstdc++-6.dll in the avidemux folder with the one from mingw, e.g. c:​\Mingw64\mingw64\bin\libstdc++-6.dll+
  
-Do the fixes above, erase the build folder (build/*) and do it all over again (it takes 5 sec)+When the build is over, either copy the resulting dll file into the plugin subfolder of avidemux install or, alternatively,​ run the install target in Visual C++
  
 +**Important/​Common problem**
  
----- 
-====== Using Netbeans ====== 
- 
-You'll need the same requirement as above (i.e. cmake, msys,...)\\ 
-You *MUST* add msys make, mingw make will not work with netbeans\\ 
-Open a msys2 shell, and enter\\ 
-   ​pacman -S make  ​ 
-    
- 
-== Configure Netbeans == 
- 
- 
-There are two parts : 
-  * Configure the toolchain 
-  * Configure the project 
- 
-The toolchain should be configured as follow :\\ 
-{{:​build:​netbeans_toolchain.png?​200|Toolchain}}\\ 
-The important part is to select the make from msys64/​usr/​bin 
- 
- 
-Everything is coming from msys, the screenshot is a bit old 
- 
-Last step is to setup the project :\\  
-{{:​build:​netbeans_project1.png?​200|Step 1}} \\ 
-{{:​build:​nb_2.png?​200| Step2}} \\ 
-{{:​build:​nb_5.png?​200|Step 3}} \\ 
- 
-The important part are : 
-  * At step2 select custom 
-  * At step3, add \\ 
- 
- 
- -G "MSYS Makefiles"​ -DCMAKE_INSTALL_PREFIX="​c:/​Program Files/​Avidemux 2.6 - 64 bits""​ 
- 
-Note that the path separator are "/"​ and not "​\"​! 
- 
-{{:​build:​sdk_netbeans_cmake_option.png?​200|}} 
  
-You can build the sample now.+You cannot mix binaries built with Visual C++ and built with Mingw/g++ 
 +It will *NOT* work. Don't even try.
  
-In case you made a mistake, dont forget to delete the CMakeCache.txt file before retrying 
  
        
build/devel_2.6_msvc.txt · Last modified: 2018/01/01 12:29 by mean