# I have problem using DirectFB



## rudykeram (Nov 26, 2004)

Hi,
I need to use "DirectFB".
this is their website: http://www.directfb.org
I have downloaded their main files which is in the following website:
http://www.directfb.org/index.php?path=Main/Downloads

and the main file that I needed I guess is "DirectFB-0.9.20.tar.gz"
and then "README" tells you about how to install it (it is really easy)
and then I tried to download one of thier simple examples that they
have, which can be found in the following website:
http://www.directfb.org/docs/DirectFB_Tutorials/simple.html

However, I cannot change the paths in the way that I want to (permission issue). So, by using an alternative approach, I included the whole path for the header files( eg. #include "/ee180d/2004f/ee180d-02/include/directfb/dfb_types.h"). It seems that now it can recognize the file, but the code in the tutorial does not work properly. It cannot yet recognize some of the member funcitons defined in the header file. it only recognizes some of the member functions of "directfb.h" ( which are included in this simple example.)
it does not understand the followings (even though they are
in"directfb.h" header file) :
DirectFBInit (&argc, &argv));
DirectFBCreate (&dfb));
the followings are the errors that I got after compiling the file:

/tmp/cc6YfyKM.o(.text+0x1c): In function `main':
: undefined reference to `DirectFBInit'
/tmp/cc6YfyKM.o(.text+0x52): In function `main':
: undefined reference to `DirectFBErrorFatal'
/tmp/cc6YfyKM.o(.text+0x62): In function `main':
: undefined reference to `DirectFBCreate'

Any Idea what is going on here? does somebody have some clue?

thanks,
Rudykeram


----------



## Whiteskin (Nov 16, 2002)

your compiler needs to be able to see the library location, and should be added to the list of standard library locations. This will vary per compiler. Why are you going to be using DFB? (It will help in debugging)


----------



## rudykeram (Nov 26, 2004)

I am using DFB to display multiple layers on top of the Linux Framebuffer Device. we are doing this live video capturing project, and it needs to detect a special color using OpenCV (I already have that preapered and the code works properly). So, I can display the results (Screenshot). 
the library path (after configuring and making them) is in "/usr/local/lib". So, I think it is fine.If I had installed the required libraries someplace other than "/usr/local/lib" then I think I would need to add the bin directory for those libraries to the front of your 'PATH'. (some idea?)


----------



## Whiteskin (Nov 16, 2002)

I don't do much programming, but all I can suggest is to clean out the installed library, and go back and rebuild and reinstall it.


----------



## dandel (Apr 4, 2006)

I face the same problem. And I reinstalled the library already, but the problem is still being there. Can anyone give further guide? Thanks


----------

