dll,linker , The linker link, but the executable ask for another dll


The linker link, but the executable ask for another dll

Question:

Tag: dll,linker

I'm using mingw. I have a dll named gtksourceview-3.0-1.dll, my program is compiled without problem, the linker doesn't report any error, but when I lauch the program, it is asking for another dll: gtksourceview-3.0-0.dll.

When I compile with g++, I pass as argument: -lgtksourceview-3.0. Why my program is searching for the wrong dll ? How to tell my program to use the right dll ?


Answer:

The problem is solved, there was a error in Makefile, in LDFLAGS a "-L/directory/lib", refering to a /lib directory that contain libgtksourceview-3.0.dll.a and libgtksourceview-3.0.la corresponding to the wrong dll.


Related:


MinGW-W64 linker skipping incompatible files when searching for third-party static libraries


c++,windows,linker,g++,mingw-w64
I'm on Windows 7 64-bit, and I'm compiling with g++ from MinGW-W64. I'm trying to compile an application that I wrote on a Unix computer. I'm running into problems, however, when I try to link against certain third-party lib<name>.lib files. Specifically, I need to link to ROOT libraries. The linker...

When is it a good idea to make a DLL file


c#,.net,dll
So, I have searched stack for a similar question, without finding anything. So tell me if this is a duplicate. Anyway, What my question is as described in the title. When is it a good idea to make a .dll file. For instance, whenever I start on a new project,...

Converting .so file of linux to a .dll file of windows


c,dll,ctypes
I have some C code (having various header files and a make file) compiled as a .so file in Linux(Ubuntu) and a python program which calls the functions of this shared object using Ctypes. Now, I want to use this program on windows. In windows, Ctypes needs a .dll file...

program linked to SFML dlls wont start, returns 0xC000007B or missing __gxx_personality_v0


c++,dll,sfml
I was trying to compile example from SFML page http://www.sfml-dev.org/tutorials/2.3/start-cb.php (at the bottom) I dowloaded the version for GCC 4.9.2 DW2, set everything needed (linker, directories) and it compiled without errors. When the application starts it says that it needs .dll files so I copied them from SFML/bin directory. Then...

How to unregister Python COM server


python,windows,vba,dll,com
I'm developing a very simple COM server for educational purpose. I can get it to work but every time i have to change anything (code/logic) , i have to delete every instance of the COM Server Name in the regedit.exe under various headings till it disappears from the PythonWin >>...

Win64 - JNI: UnsatisfiedLinkError: Can't find dependent libraries


java,dll,jni,unsatisfiedlinkerror,win64
I have a own JNI dll which depends on a few other dlls (Zero MQ to be precise). I have compiled these dependencies on Windows 7(64bit) via Visual Studio. I defined that I get 64-bit dlls. On the developer machine it works just fine. But if I move those dlls...

Why is a “user breakpoint” called when I run my project with imported .lib, not when code is inline?


c++,visual-c++,dll,runtime-error,breakpoints
The Situation I am writing a wrapper library for GPIB communications for setting up specific instruments according to a clients specifications to automate some of their processes. I have to use C++ and the old '98 compiler in VC++ 6.0 running on a Windows NT machine to maintain compatibility with...

visual studio cannot resolve static functions


c++,visual-studio,linker,singleton,static-functions
Here is the code and the output. win_main.cpp #include <Windows.h> #include <tchar.h> #include "d3d9_object.h" #pragma comment(lib, "d3d9.lib") #pragma comment(lib, "d3dx9.lib") LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM); WNDCLASSEX createWndClassEx(HINSTANCE); HWND createWindow(const wchar_t *caption, HINSTANCE); void exitWithFailure(const wchar_t *message, HINSTANCE); const wchar_t gszWndClassName[] = L"MainWindowClassName"; WNDCLASSEX gWndClassEx; int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE,...

C lib file dependency conflicts


c++,c,dll,shared-libraries
So I'm confused about how lib files work, I would prefer to use all lib files and no dlls but am concerned about potential conflicts of a specific type. Say you have a program that depends on lib files a1 and a2, and lib file a1 depends on lib file...

Reference Two DLLs with the same namespaces and types


.net,vb.net,dll
I have two versions of the same DLL, i.e. LibV1.dll and LibV2.dll. Both libraries have the same namespaces and types, but are not compatible. I need to be able to reference both at the same time in a VB.Net project in order to upgrade data from the old version to...

Running two versions of same Dll parallel in Asp.Net


c#,asp.net,.net,dll
I need to run two versions of same Dll to be run on my website simultaneously. So i have created a folder inside Bin and shown the second Dll path like this <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity name="AWSSDK" culture="neutral" publicKeyToken="9f476d3089b52be3"/> <codeBase version="2.3.40.0" href="FILE://E://Live /bin/V-2/AWSSDK.dll"/> </dependentAssembly> </assemblyBinding> and added my first...

How does using -L affect the linker?


linux,ubuntu,gcc,linker,ld
I'm rather new on Linux, so maybe this is a simple question. The question is: How does adding a -L/path affect the linker when there are no libraries attached? my issue: I'm trying to set up a cross-compilation toolchain featuring two pieces of third-party libraries¹. I'm using the linaro arm-linux-gnueabihf-raspbian...

Can't link wxWidgets app with Code::Blocks / MinGW


c++,linker,mingw,codeblocks,wxwidgets
I have an already working c++ + wxWidgets app built in Eclipse, with wxWidgets built using MSYS. Now i'd like to try different IDEs, like CodeLite and Code::Blocks, but when i tried them they did'nt work 'cause i was lacking a build.cfg file they wants. So i tried a "clean"...

Adding Armadillo to Qt project [SOLVED]


c++,qt,gcc,linker,armadillo
I am trying to run a test for the Armadillo library (5.2) which I have downloaded and I have uncommented the lines ARMA_USE_LAPACK and ARMA_USE_BLAS in the config.hpp file as recommended for Windows here . I have set the .pro file as such QT += core QT -= gui TARGET...

'The command line is too long' when linking .obj files in Windows command prompt


windows,maven,dll,cmd,linker
As a last step to my maven build on Windows, it tries to create a dll file by linking around 1500 object files. Looks something like this: cl.exe foo.dll (around 1500 .obj files) (couple of other statically linked libraries) The build fails with just one statement: The command line is...

link.exe returns error LNK1181: cannot open input file 'C:\Program.obj'


c++,windows,visual-c++,linker,linker-error
I'm compiling with a Batch file containing @echo off set link=C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\link "%link%" external_input.obj periodic_dinger.obj flagger.obj monitor.obj main.obj libGui.lib libCore.lib libCint.lib libRIO.lib libNet.lib libHist.lib libGraf.lib libGraf3D.lib libGpad.lib libTree.lib libRint.lib libPostscript.lib libMatrix.lib libPhysics.lib libMathCore.lib libThread.lib All the objects and libraries are in the same directory, which is...

Running msi causes “module failed to register” in 32bit win7,but works in 64bit win7


c++,windows,dll,windows-installer
I'm trying to deploy my project and create an installer. I've created a msi file in vs2005. When running the .msi setup wizard, i'm getting the error: "Module abc failed to register. HRESULT -2147010895. Contact your support personnel." The module that failed to register is a C++ com dll.But in...

Linker error compiling DX10 program in Visual Studio 2015


visual-studio,visual-c++,linker,directx
I am trying to compile old program which works with DirectX 10. Full list of libraries used: #pragma comment(lib, "d3d10.lib") #pragma comment(lib, "d3dx10.lib") #pragma comment(lib, "dxgi.lib") #pragma comment(lib, "dxerr.lib") #pragma comment( lib, "dxguid.lib" ) Linker error: dxerr.lib(dxerrw.obj) : error LNK2019: unresolved external symbol _vsnwprintf referenced in function "long __cdecl StringVPrintfWorkerW(unsigned...

Protobuf cannot be linked on ubuntu


c++,ubuntu,linker,cmake,protocol-buffers
I try to use protobuf but somehow the linking fails (here just snippet): Linking CXX executable app CMakeFiles/app.dir/msg.pb.cc.o: In function `evoswarm::protobuf_AssignDesc_a_5fto_5fb_2eproto()': msg.pb.cc:(.text+0x133): undefined reference to `google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(google::protobuf::Descriptor const*, google::protobuf::Message const*, int const*, int, int, int, int, int, int)' msg.pb.cc:(.text+0x190): undefined reference to...

C: linker command failed with exit code 1


c,linker
I'm having a problem when I compile my code. I'm not getting any error messages. However, I am getting the following message: Undefined symbols for architecture x86_64: "_lookup", referenced from: _main in sixteen2-85c27c.o ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use...

Linking to a static lib compiled with MSVC


dll,rust
I'm trying to link with a simple C lib on windows against Rust library My lib is .h extern "C" { void say_hello(const char* s); } .cpp #include <stdio.h> void say_hello(const char* s) { printf("hello world"); } My Rust file #[link(name="CDbax", kind="static")] extern "C" { fn say_hello(s: *const libc::c_char) ->...

Where is Microsoft.Build.Tasks.Core.dll located?


.net,dll
I'm trying to sign a ClickOnce application using a method overload that was specifically added in VS 2013 Update 3. (per this suggestion) The class he is using is described by MSDN here, and it says the class comes from Microsoft.Build.Tasks.Core.dll. Notice that the usual "Other Versions" dropdown is missing,...

Embarcadero C++Builder: Separate debug/release DLL references possible?


c++,dll,c++builder
Depending on the build type (debug, release) of my main executable, I want to link against the matching builds of my DLLs. What is the correct way to accomplish this using the C++Builder IDE? Details: I am using Embarcadero C++Builder XE8 (trial, BCC64). My software consists of one executable and...

Linking a shared library in executable vs. another shared lib


c++,linux,linker,g++,clang++
tl;dr Are there any differences in the way linux loads and links a shared library if the library is linked by an executable or by another shared library? Background Suppose I have a shared library (e.g. libA.so) containing a class with a static std::map and a set of singleton classes....

php: loading oracle driver gives error “Unable to load dynamic library - The specified procedure could not be found.”


php,oracle,dll,pdo
I seem to have a strange problem with PHP. I've migrated a bunch of software from one server to another. On the server some scripts make a connection to Oracle, so to be able to make a connection the oracle client is installed and a tnsnames file is in place....

Boost unit test link error — abi mismatch?


c++,unit-testing,boost,linker,abi
I'm trying to build a unit test with boost, but the linker complains about a missing function. Take this skeleton code #define BOOST_TEST_DYN_LINK #define BOOST_TEST_MAIN #include <boost/test/unit_test.hpp> BOOST_AUTO_TEST_SUITE(TestFuncOps); BOOST_AUTO_TEST_CASE(CopyConstructor) { } BOOST_AUTO_TEST_SUITE_END(); But it fails with Undefined symbols for architecture x86_64: "boost::unit_test::ut_detail::normalize_test_case_name[abi:cxx11](boost::unit_test::basic_cstring<char const>)", referenced from:...

Link static library with static library


c,linker,autotools,automake
I have a Makefile.am with two noinst_LIBRARIES, and one of them needs to link with the other. Adding it to the CFLAGS throws a compiler warning, but as far as I know, automake likes to freak out about using LDADD with libraries, since they are not complete programs. How can...

Link error when using AES256 example with OpenSSL


c,linker,openssl
Using gcc 4.8.2 on Ubuntu 14.04 to compile openssl example. gcc SSLsample.c -lssl3 The linker gives undefined symbols: SSLsample.c:(.text+0x25d): undefined reference to `EVP_CIPHER_CTX_new' SSLsample.c:(.text+0x272): undefined reference to `EVP_aes_256_cbc' SSLsample.c:(.text+0x294): undefined reference to `EVP_DecryptInit_ex' SSLsample.c:(.text+0x2bc): undefined reference to `EVP_DecryptUpdate' SSLsample.c:(.text+0x2ed): undefined reference to `EVP_DecryptFinal_ex' SSLsample.c:(.text+0x309): undefined reference to `EVP_CIPHER_CTX_free'...

How to remove error of incompatible variable types in LoadLibrary() function?


c++,dll,types,loadlibrary
I have one line in my C++ program HINSTANCE hInstLibrary = LoadLibrary("DLL_tut.dll"); Here I'm getting error saying that error C2664: 'LoadLibraryW' : cannot convert parameter 1 from 'const char [12]' to 'LPCWSTR' I'm trying to implement program given in link http://www.codeguru.com/cpp/cpp/cpp_mfc/tutorials/article.php/c9855/DLL-Tutorial-For-Beginners.htm Tried finding some solutions and found this one closest...

Access C# method in DLL from Java


java,c#,dll,dllimport
I'm having trouble trying to call a function writed in C# from Java. I have already loaded the dll that contains the function. Error message: java.lang.UnsatisfiedLinkError: app.clsValidation.validate(Ljava/lang/String;)Ljava/lang/String; C# code compiled into a 64-bit dll: namespace library { public class clsValidation { public string validate(string txt) { return txt; } }...

Makefiile with many flags


c++,linux,makefile,linker,intel-mkl
I am trying to learn how a Makefile should look like, when it comes to the flags, especially the linking ones. Here is my Makefile: OBJS = n.o SOURCE = n.cpp # HEADER = there are no header files, so I commented that OUT = test CXX = ../mpich-install/bin/mpic++ FLAGS...

(solaris) ld: fatal: … version 'GCC_4.2.0' does not exist


c++,gcc,linker
I'm trying to compile a c++ program for the first time on this machine (which is not mine), so I've written a simple hello world. My command to compile gets an error, >g++ testing.cpp -L/usr/local/lib ld: fatal: file /usr/local/lib/libgcc_s.so: version 'GCC_4.2.0' does not exist: required by file /usr/local/lib/libstdc++.so but I...

How to find the dll which causes a memory leak and not directly referenced by application


c#,wpf,dll,memory-leaks,msvcrt
I am writing a WPF application which uses a number of unmanaged DLL's. Something in the program is causing memory leak and I monitored the application using Redgate ANTS 8 Memory Profiler. ANTS shows that the memory usage of MSVCR110.dll is constantly increasing. The question is that can managed code...

Prism 5.0 External 3rd party dll


c#,dll,prism-5
so I am a bit confused on how to word this... The program we are using utilizes a third party DLL developed by a vendor. This DLL is not a prism module its a basic DLL. When adding this regularly as c# requires it fails to initialize the module that...

MPIR gcc compilation - cannot find -lmpir


c++,c,compilation,linker,mpir
I am trying to compile a simple C program using GCC with MPIR under MinGW on my Windows 7 machine. I installed MPIR successfully (I guess) with configure, make, make check and make install (did not use "sudo" - what is this?). The program is called "mytest.cpp", sits in the...

Should GHC be linking different versions of the same libraries?


haskell,linker,ghc
I'm trying to compile a program with GHC 7.6.3 and I get the error /usr/lib/ghc/unix-2.6.0.1/libHSunix-2.6.0.1.a(execvpe.o): In function `pPrPr_disableITimers': (.text+0x300): multiple definition of `pPrPr_disableITimers' /home/tom/.cabal/lib/i386-linux-ghc-7.6.3/unix-2.7.1.0/libHSunix-2.7.1.0.a(ghcrts.o):ghcrts.c:(.text+0x0): first defined here collect2: error: ld returned 1 exit status (The problem ultimately derives from a usage of readProcessWithExitCode but I don't think that's especially relevant)...

Linker error with variable templates


c++,templates,linker,c++14,template-variables
Consider the code below: #include <iostream> template<typename T> T n; int main() { n<int> = 42; std::cout << n<int> << std::endl; } It compiles and links with g++5.1, and it displays 42. However, clang++ fails to link it: undefined reference to n<int> If I initialize the template variable like template<typename...

C++ Access violation write to 0x00000000 in dll in mql4


c++,dll,mql4
First, I am new to C++ (nearly a week into it), so forgive me if this is obvious. Also, I have hunted through many posts with similar issues. Either my understanding is just not developed enough, or none had relevant info to help me understand this issue. In Metatrader 4,...

Including library in AIR Native Extension causes the error, “The extension context does not have a method with the name…” for all methods


c++,c,actionscript-3,dll,air
I am working on an AIR Native Extension (ANE) for Windows desktop. The point of this extension is to be able to call out to a third-party C library, which consists of two .h files defining the method signatures/typedefs, and a .lib file. Before including the third party library in...

Linux - process killed when linking section into lowest 2 MB of memory?


linux,linker,ld,virtual-memory,linker-scripts
I'm learning about LD linker scripts, and I noticed that if I link the .text section (or any section) at an address lower than than 2 MB, my process gets instantly killed by Linux as soon as I run it. Here's an example script I'm using: SECTIONS { . =...

how to connect and read values from kepware using OPCAutomation.dll


dll,plc,opc
I am creating a small c# program to connect and read value from kepware server using OPCAutomation.dll, but unable to get its syntax? OPCAutomation.OPCServer _OPCServer = new OPCAutomation.OPCServer(); _OPCServer.connect("", ""......); what values will come inside these brackets?...

gcc compilation with linker - differences


c,gcc,linker
This will compile main.c and link created .o file statically with with abc library and dynamically with xyz gcc main.c -Wl,-Bstatic -labc -Wl,-Bdynamic -lxyz -o main But I am not sure about some other combinations: This will compile main.c to main - but what -lm will do in this case?...

System.Windows.Interactivity must be referenced in the main project


c#,wpf,dll,reference
So I have a WPF project and my interface in a different project than the main one. I went to reference System.Windows.Interactivity, but it would not work. Not until I added it as a reference to the main project as well... This is the first time this has ever happened...

VC++ .net: Functionality from managed DLL is not exported


c#,c++,visual-c++,dll
I am very new to the .NET platform (coming from the JVM and having some limited C/C++ experience) and trying my first managed C++ class library. This is to serve as a bridge to a third-party DLL I got and I have to interface. I tried it with BridJ and...

Returning into object from Assembly.LoadFrom() in C#


c#,dll
I'm trying to make an expansion setup for this game I'm developing, (not going to go into detail about), but all a single expansion will need is the 1 .dll file added into the Expansions folder I have added. I have figured out how to access these .dll added into...

Microsoft Band and WPF


.net,wpf,dll,microsoft-band,.net-core
I have downloaded the sample code for Band SDK for Windows. Then I added a new WPF project and grabbed the latest SDK through Nuget (Version 1.3.10518.1). Now under packages\Microsoft.Band.1.3.10518\lib, the following folders are contained: netcore451 portable-net45+win+wpa81 portable-win81+wpa81 wpa81 Now as I need .NET 4.5 support I have referenced the...

Call Delphi XE6 unicode dll from C# asp.net


c#,delphi,dll
before opening the topic searched any more responses served me, my error remains, have created a dll in Delphi XE6 64x which is as follows: function GeraChave(Action : PAnsiChar; StrCrip : PAnsiChar; Cnpj : PAnsiChar; idPC: PAnsiChar): PAnsiChar; stdcall; var KeyLen : Integer; KeyPos : Integer; OffSet : Integer; Dest,...

VS2012 Identifer not found when part of static lib


c,visual-studio-2012,linker,static-libraries
Using VS2012 C/C++: I created and linked a static lib called "libtools" to my project. Calls to functions in the libtools lib worked as expected. I created and linked a second static lib called "shunt" to my project. But when I incorporate a call to a function in shunt, I...

Using different versions of the same DLL in a project


c#,.net,dll
In my project I have to use different versions of AWSSDK dll's, in order to make this i took help of this post . and added one of my dll in to a folder named V-1 inside bin folder. Then made config changes like this <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity...