[Solved] [VLC] How change path to a external dll ? lazarus / 39-Graphics ---------------------------------------------------------------------- WimVan · 2018-12-28 09:54 After installing Lazarus 1.8.4 I can find a nice example of how creating  an application using VLC to play video ... However, At runtime when I want to open the video, read, play the video I got a warning the the dll  can't be found style: C:\program files\VIDEOLAN\VLC\xxxx.dll can't be loaded. When installing VLC (32bit) on the PC, it is always installed in c\program files (x86)\VIDEOLAN\VLC .... and we have no choice to put it elsewhere To have a work around I copy only the concerned dll  to c:\program files\VIDEOLAN\VLC and so the application runs ... My question ?  Where can I change the path so the program searches into the correct path ? ---------------------------------------------------------------------- lucamar · 2018-12-28 10:34 Change it in the source code that loads the library. It shouldn't be too difficult. For a more meaningful answer you'll have to tell us which (pascal) binding to VLC you're using, etc. ---------------------------------------------------------------------- WimVan · 2018-12-28 12:29 Sorry, but I didn't find a path at all. I use: Lazarus V: 1.8.4 FPC: 3.0.4 SVN: 57972 I ran the vlc-example that is delivered with that version lazarus\components\vlc\test\testlcl.lpi When compiled, it only runs when all needed VLC-library (dll) are set in the "program files"-folder... VIDEOLAN\VLC, but VLC installs itself under "program files (x86)" VLC-version installed is V 3.0.4 32 bit When checking all files on 'program files'  I found out that libvlc (in lazarus\fpc\3.0.4\source\packages\libvlc\src) has this path that can be modified and I did so. Recompiled all (clean up and build" but no modification in the searchpath ...  Still c:\program files\videolan\vlc I also tried the component from vlc: PasLibVlc_3.0.4, but this does not work at all. Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i Const {$ifdef unix}  libname = 'libvlc.so.5';{$else}{$ifdef windows}  DefaultlibPath = 'C:\Program files (x86)\Videolan\VLC\';  corelibname  = 'libvlccore.dll';  libname        = 'libvlc.dll';{$endif}{$endif} ---------------------------------------------------------------------- Jurassic Pork · 2018-12-28 13:43 hello, i have no problem with vlc and paslibvlc on windows 10 64 bits  - Lazarus 1.8.2  32 bits - vlc 3.0.4 32 bits (exe in program files (x86) folder) so : What is your lazarus version  32 bits or 64 bits ? Friendly, J.P ---------------------------------------------------------------------- lucamar · 2018-12-28 14:07 Quote from: WimVan on December 28, 2018, 01:29:38 pmWhen checking all files on 'program files'  I found out that libvlc (in lazarus\fpc\3.0.4\source\packages\libvlc\src) has this path that can be modified and I did so. Recompiled all (clean up and build" but no modification in the searchpath ...  Still c:\program files\videolan\vlc To make it work you'll have to recompile the libvlc . It's a FPC package so AFAICT it isn't automaticallly recompiled by Lazarus even if you do "Clean+Build". To recompile simply open a terminal, CD to "lazarus\fpc\3.0.4\source\packages\libvlc\" and run make. That should do the trick. Note that it would be better to find the call to Loadlibvlc() elsewhere and set your path in it. However, after looking for it I've been unable to find it and I haven't got much time now. I'm sorry I can't be of more help but this have already eaten quite a chunk of my free time and my own projects have must take precedence now. Lots of luck to you. ---------------------------------------------------------------------- WimVan · 2018-12-30 21:11 Checked and recompiled ... Finally ... I deinstalled VLC completely ... Cleaned up all keys in the register ... Removed all dir and subdir Videolan created ... Removed all info for vlc and videolan from my users-account on the PC. Got VLC 32 bit (version 3.0.4) and reinstalled. There I got the opportunity to change the directory where it will be installed (by default it out it in "\program files (x86)\" because it is a 32bit application. Changed to "\program files\"  and ran the installation ... Now, all is working without any problem. Pitty, it would be nice if the directory where resides the needed dll is a property in the component, so we can install vlc there where we want...