I've been told to move my code from MFC to linux platform, and so I did, trying to keep as much as I can on the way, now, I had a dll and application, the application I rewrote all anew while the dll I only made changes so it'll be an ".so" file, now, when I try to link using "dlopen", I get the message "undefined symbol: _ZN5ImageC1EiiPh", now, Image is a class in the DLL, which even makes its own ".o" file for the DLL itself. I just can't understand why it happens. I use Image in functions which are not in Extern "C", but the functions I want to use don't use it. Also, I have many globals in the DLL, (because that's how the DLL was written in the past) but none of them is Image...
Is the problem with the fact I include a c++ class in the DLL? How can I solve such a problem? I tried messing with how I link it, but I think that's not the issue here.
I use g++ and -rdynamic --export-dynamic -ldl -lrt for the application
and for the dll I use -shared -Wl,-soname, and -lm, and for the .o files of the dll -Wall -fPIC (although for some reason it doesn't let me do it through the makefile and I needed to do that by hand, which was a little weird. I put it in tag, I put it in line, but it still did nothing...
I am building a queue system (in C on CentOS 5) where each directory queue has a number of process instances 'watching' it. I have a root-permission queue supervisor process which does all the forking, and the instance processes give up root as their first action. For max security each queue is accessible to a different set of users and groups.
I need to keep the RAM requirements as low as possible, so I am relying heavily on copy-on-write (since all memory writes are to shmget() shared memory)
Each process presently dlopen's the libraries it requires after fork, but I'm wondering if I would gain by performing the dlopen before forking a number of instances which all require the same libraries.
Any pointers to mid-level tutorials on dlopen and fork internals would be most appreciated: this is about my third post anywhere since I converted to Linux, but I just can't find the answer to this anywhere online.
The game is quite old (2002!) and I'm trying to mod the old version of it (1.02a), the jk2ded server linux binary.The game engine loads my mod's .so file which I compiled using:
Code:
gcc -shared -static -g -fPIC g_syscalls.c common.c main.c -o out/jk2mpgamei386.so So whilst launching the server for the first time, it loads the .so file using dlopen() without problems and the output is:
Code:
Loading dll file jk2mpgame. Sys_LoadDll(/web/web11/jk2/base/jk2mpgamei386.so)... Sys_LoadDll(jk2mpgame) found **vmMain** at 0xb2ed9413 Sys_LoadDll(jk2mpgame) succeeded! [ NT's Fix ] GAME_INIT
and then it works correctly until I try to change the map the server is on currently.When a map changes on the server,the .so file has to be unloaded.After unloading with dlclose() without errors, when the new map is launched the engine tries to reload the .so into the memory with dlopen() but fails:
I am trying to install NOX which is a openflow controller and it needs Xerces-C++ this. I installed it successfully on the Debian. The output of the xerces after running the "make install" command is as follows which shows that is successfully installed on the machine.
I was having an issue with dlopen(),dlsym(),dlclose() in my program. it is giving an error: undefined reference to dlopen,dlsym,dlclose
I know till here that this error occurs when we do not include the required header file or if it does not find the definiton.
But i included the required headerfile #include <dlfcn.h> even then i could not get rid of these errors. i wrote a new c-code t check its functionality, it worked there but when I'm using those functions in another program, which is a part of a makefile, it is giving this undefined reference error.
I'm trying to create a program from 2 files - main.cpp that contains the main function, and modules.c that contains the definitions of the functions that are called in main(). modules.c only contain function definitions, no main function.
My Makefile is as follows:
Code:
I have included "modules.h", which contains all the function declarations, in my main.cpp.
When I try to make using this Makefile, I get the error
Code:
If I switch the order of modules.o and main.o in my $(TARGET) line, then I get errors that say "undefined reference to" the functions I have defined in modules.c, in main.cpp.
I am slowly getting accustomed with linux issues and its different programming compilation stuffs. and i must say am truly liking it. Now i am facing this typical error , "undefined reference to `clock_gettime'" while i am compiling a code, which is not mine as it required to install a simulator. Now i have read about this type for the last 2 days and i have included "-lrt" in the make file and included <time.h> in the header files which was missing but still i am getting that error.
Now matter how many times i run the make file with the required changes its still giving me this error, which i have comprehended as mainly linking problem rather than a compilation issue.
I am facing some problems when i am trying to link using g++. The linker error text is "undefined reference to `std::vector<std::string, std::allocator<std::string> >::end()'"
I am facing the problem of calling cfitsio library from C program in linux. when i am givingthe option "gcc -o CreateLevel1DataFitsFile CreateLevel1DataFitsFile.c -lm -lcfitsio "i am getting following error
/usr/lib/../lib/gcc/i386-redhat-linux/3.4.4/../../../libcfitsio.a(getcolj.o)(.text+0x7065):/backup/Astrosat/learning/cfits/cfitsio/getcolj.c:3098: more undefined references to `__xtoll' follow
When I compile my code in Linux (ATCA machine), I am getting the following error: /vobs/ims_do/lib/rhlinux/debug/libnem-dummy_td2.so: undefined reference to `__isoc99_sscanf'
The same code is being compiled in Solaris without any problems.
I am trying to add some function to the c++ project (calling function) and the called function are in C. And i am getting error "undefined reference to "Hello(int,int)" " while linking. It is compiling correctly. It is linking to header file mention in the calling function. This header file has definition to the c - called function. Do you thinking having c files into C++ project will be a problem? Should I remove <stdio.h> in c files?
Do you have any ideas why does wxHyperlinkCtrl doesn't work on Linux?It has an error which says..."/usr/include/wx-2.8/wx/gdicmn.h:215: undefined reference to 'vtable for wxHyperlinkCtrl'"Do I have to include a certain library so that it will work in Linux? I try to compile it in windows and its succesful.'m having a problem on Linux guysinitialize the wxHyperlinkCtrl like this... wxHyperlinkCtrl* hyperlink1 = new wxHyperlinkCtrl();and included #include <wx/hyperlink.h> Is there something missing on it?... I already had tried supplying parameters on the constructor but same thing it gives me an error
I'm writing a binary search tree class to insert records and I'm stuck on the following error:
Code: /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/crt1.o: In function `_start': (.text+0x20): undefined reference to `main' collect2: ld returned 1 exit status Here is the code for my class:
[Code]...
I really don't know how to approach this, I thought that everything was working fine but I have no idea what is wrong. Also, for clarification, main() is in a different .cpp file that #includes "tree.h"
I am using Centos 5.4 with gcc v4.1.2. If I take a bunch of .o files and I then link with my main.o to form an executable then this links and executes just fine. If however, I try to create an archive file (.a) using 'ar rus xxx.o yyy.o etc' and then try to link the resulting .a with my main.o then I get 'undefined symbol' linker errors and I don't understand why.
Anyone else having problems installing Skype beta (direct from Skype) on 11.3 x86_64? Error is:
Code: skype: symbol lookup error: /usr/lib/libQtNetwork.so.4: undefined symbol: _ZN14QObjectPrivate15checkWindowRoleEv I've been through the forums and Google and made sure I have all the 32-bit libs required by skype. For example: Code: 6930p:~ # rpm -qa | grep -i libqt4
I am using Ubuntu 10.10 I get the following massage. Admin@Ubuntu21:~$ skype: symbol lookup error: /usr/lib/libQtDBus.so.4: undefined symbol: _ZN14QObjectPrivate15checkWindowRoleEv I have tried reinstalling it but still the same problem.
When the following little C program is compiled with gcc it does not get a compile error even though the function atof is undefined. If I change it to xatof then it goes get an "undefined reference" error. (I knowthat atof is a library function, and I know that it resides in stdlib.h But since I did not include stdlib.h I would think that it would give me an error). What am I missing here?
While compiling one of my programs I am getting this error: Undefined symbol:_gfortran_internal_malloc64My program actually gets completely compiles and linked and this error is shown in run time.Does anybody have any experience about getting around this ? May be using some different version of GFortran ?I am using Centos 5.4 64 bit and GFortran 4.4