Hi,
I'm currently trying to implement a factory as a singleton. I practically used the textbook example of the Singleton pattern. Here's the .h file:
namespace oxygen{
class ImpFactory{
public:
static boost::shared_ptr<ImpFactory> GetInstance();
private:
static boost::shared_ptr<ImpFactory> mInstance;
};
and here's the .cp...
how can i resolve a linker error in c?
this is the error message:
undefined reference to HPDF_Page_SetRGBStroke
...
I am building my application in Visual Studio 2005, using project properties ->c/c++->CodeGeneration->RuntimeLib: MTd (using static CRT library-LIBCMTD). The application is using 3rd party dlls and libs which are built in MDd(using dynamic CRT lib- MSVCRTD).
I'm getting linker errors as:
MSVCRTD.lib(MSVCR80D.dll) : error LNK2005: __mkti...
If I compile and link an executable with the -export-dynamic flag, it doesn't apply to symbols stored in archives that are linked. The flag only on exports symbols for objects that are linked that aren't in archives. Can someone explain why this would be?
...
I have a small piece of code that depends on many static libraries (a_1-a_n). I'd like to package up that code in a static library and make it available to other people.
My static library, lets call it X, compiles fine.
I've created a simple sample program that uses a function from X, but when I try to link it to X, I get many errors...
I'm using code::blocks on a linux system with the gcc compiler, and I want to be able to use the shared library template to make a shared library with classes, then make another project that accesses that shared library(at compile time, not dynamically) and classes. I'm sure that code::blocks has simple way of doing this without making c...
Hello,
I was just wondering if it is possible to replace Loader (executable program loader not the boot loader) of an Operating System (Windows is my choice). Are there any third party loaders available that would patch the default one.
Is there any way through which I can obtain the control over the OS Loader? I mean, I want things it...
Hello.
This seems to be sort of what I want, except I want to make an instance of a C PyObject in another C module.
http://stackoverflow.com/questions/1147452/create-instance-of-a-python-class-declared-in-python-with-c-api
But I am not able to find the documentation for using a Python module from C. I can't seem to find the relevent d...
A file that is given as input to the linker is called Object File.
The linker produces an Image file, which in turn is used as input by the loader.
A blurb from Microsoft Portable Executable "and Common Object File Format Specification"
RVA (relative virtual address). In an image file, the address of an item
after it is lo...
I never clearly understood what is an ABI. I'm sorry for such a lengthy question. I just want to clearly understand things. Please don't point me to wiki article, If could understand it, I wouldn't be here posting such a lengthy post.
This is my mindset about different interfaces:
TV remote is an interface between user and TV. It is an...
I'm trying to test if standard library (kernel32.dll) have one of the function.
Code snippet for test:
extern void CreateProcessA (void);
int
main (void)
{
CreateProcessA ();
return 0;
}
The code compiles and links as follow:
cl /c test.c
link test.obj kernel32.lib
This code can be compiled well with Visual C++, but cannot lin...
HI,
I am getting the following linker error on linux:
My guess is it is missing '-lpthread' in the linker thread. My question is if there is a way for me to set my environment on linux such that it will add '-lpthread' when it links?
/usr/bin/ld: out/host/linux-x86/obj/STATIC_LIBRARIES/libutils_intermediates/libutils.a(Threads.o): in ...
Hi
I'm trying to link with the static libc.a and a dynamic lib .so unsuccessfully.
I've already tryied the following:
Firstly I test with all dynamic:
gcc -shared libtest.c -o libtest.so
gcc -c main.c -o main.o
gcc main.o -o test -L. -ltest
It's working (compile and execute)
Secondly I test what I want (dynamic lib and static lib...
Now and then when using GCC I get cryptic errors like this:
undefined reference to 'vtable for classname'
When it's not caused by a missing library, this not-very-descriptive error message always causes me to dig through code files line by line to find the missing implementation for a virtual function. Is there a way to make the linke...
Scenario:
I have MSVC2005 with the Qt Visual Studio AddIn installed. In my solution there is a project A consisting of multiple plain C++ code modules, which is built to an executable A.exe. Project A does not contain a .cpp file with a main(), but has a dependency on a project B.
B is a Qt project built as a static lib. It consists o...
I have a make file of, more or less, the following structure that compiles C++ source code:
.PHONY: all
all: compile_obj_files my_binary
# This rule generates the object files. It works fine afaik.
.PHONY: compile_obj_files
compile_obj_files:
$(MAKE) --file=child.makefile
# my_binary is a real binary file that I wish to build.
my_...
Got Link error (Fatal: Access violation. Link terminated) in Borland 6.0.
How do I know what is the cause of it ?
Is there any output file that I can open and get more informative message ?
...
Hi,
I am getting this linker error:
system/core/libacc/tests/main.cpp:42: error: undefined reference to 'dlsym'
Can you please tell me where is the library on ubuntu 9.10 which contains the library for 'dlsym'?
Thank you.
...
how to resolve undefined references [linker error] in dev cpp?
...
I'm trying to make a simple application for calendar and it doesn't seem to link properly.
Platform: WinXP, Qt: 4.5.3 with MinGW
The application is trying to use a predeveloped qt plugin "worldtimeclockplugin" from C:\Qt\4.5.3\plugins\designer. I dragged and dropped this widget in Qt designer on a dialog and then tried to build the app....