#DPATCHLEVEL=0
Index: directfb-config.in
===================================================================
--- directfb-config.in.orig	2007-06-07 05:05:11.000000000 +0300
+++ directfb-config.in	2007-06-07 05:15:48.000000000 +0300
@@ -86,7 +86,7 @@ while test $# -gt 0; do
       fi
         
       for i in `echo $optarg | sed 's/,/ /g'`; do
-        echo_input="$echo_input $moduledir/inputdrivers/libdirectfb_$i.a"
+        echo_input="$echo_input -Wl,-udirectfb_$i $moduledir/inputdrivers/libdirectfb_$i.a"
       done
 
       echo_static=yes
@@ -97,7 +97,7 @@ while test $# -gt 0; do
       fi
         
       for i in `echo $optarg | sed 's/,/ /g'`; do
-        echo_graphics="$echo_graphics $moduledir/gfxdrivers/libdirectfb_$i.a"
+        echo_graphics="$echo_graphics -Wl,-udirectfb_$i $moduledir/gfxdrivers/libdirectfb_$i.a"
         case $i in
           matrox)
             echo_graphics="$echo_graphics @SYSFS_LIBS@"
@@ -116,7 +116,10 @@ while test $# -gt 0; do
         echo_font="$echo_font $moduledir/interfaces/IDirectFBFont/libidirectfbfont_$i.a"
         case $i in
           ft2)
-            echo_font="$echo_font -lfreetype"
+            echo_font="$echo_font -Wl,-uIDirectFBFont_FT2 -lfreetype"
+            ;;
+          default)
+            echo_font="$echo_font -Wl,-uIDirectFBFont_Default"
             ;;
         esac
       done
@@ -129,7 +132,7 @@ while test $# -gt 0; do
       fi
         
       for i in `echo $optarg | sed 's/,/ /g'`; do
-        echo_system="$echo_system $moduledir/systems/libdirectfb_$i.a"
+        echo_system="$echo_system -Wl,-udirectfb_$i $moduledir/systems/libdirectfb_$i.a"
         case $i in
           fbdev)
             echo_system="$echo_system @SYSFS_LIBS@"
@@ -148,10 +151,10 @@ while test $# -gt 0; do
       fi
         
       for i in `echo $optarg | sed 's/,/ /g'`; do
-        echo_wm="$echo_wm $moduledir/wm/libidirectfb_$i.a"
+        echo_wm="$echo_wm -Wl,-udirectfbwm_$i $moduledir/wm/libdirectfbwm_$i.a"
         case $i in
           unique)
-            echo_wm="$echo_wm -luniquewm"
+            echo_wm="$echo_wm -Wl,-uuniquewm -luniquewm"
             ;;
         esac
       done
@@ -167,18 +170,19 @@ while test $# -gt 0; do
         echo_imageprovider="$echo_imageprovider $moduledir/interfaces/IDirectFBImageProvider/libidirectfbimageprovider_$i.a"
         case $i in
           imlib2)
-            echo_imageprovider="$echo_imageprovider -lImlib2 -lttf -lm -L/usr/X11R6/lib -lXext -lX11"
+            echo_imageprovider="$echo_imageprovider -Wl,-uIDirectFBImageProvider_IMLIB2 -lImlib2 -lttf -lm -L/usr/X11R6/lib -lXext -lX11"
             ;;
           jpeg)
-            echo_imageprovider="$echo_imageprovider -ljpeg"
+            echo_imageprovider="$echo_imageprovider -Wl,-uIDirectFBImageProvider_JPEG -ljpeg"
             ;;
           png)
-            echo_imageprovider="$echo_imageprovider -lpng -lz -lm"
+            echo_imageprovider="$echo_imageprovider -Wl,-uIDirectFBImageProvider_PNG -lpng -lz -lm"
             ;;
           gif)
+            echo_imageprovider="$echo_imageprovider -Wl,-uIDirectFBImageProvider_GIF -lm"
             ;;
           mpeg2)
-            echo_imageprovider="$echo_imageprovider -lm"
+            echo_imageprovider="$echo_imageprovider -Wl,-uIDirectFBImageProvider_MPEG2 -lm"
             ;;
         esac
       done
@@ -193,14 +197,17 @@ while test $# -gt 0; do
       for i in `echo $optarg | sed 's/,/ /g'`; do
         echo_videoprovider="$echo_videoprovider $moduledir/interfaces/IDirectFBVideoProvider/libidirectfbvideoprovider_$i.a"
         case $i in
+          v4l)
+            echo_videoprovider="$echo_videoprovider -Wl,-uIDirectFBVideoProvider_V4L"
+            ;;
           libmpeg3)
-            echo_videoprovider="$echo_videoprovider -lmpeg3"
+            echo_videoprovider="$echo_videoprovider -Wl,-uIDirectFBVideoProvider_LIBMPEG3 -lmpeg3"
             ;;
           swf)
-            echo_videoprovider="$echo_videoprovider -ljpeg -lz"
+            echo_videoprovider="$echo_videoprovider -Wl,-uIDirectFBVideoProvider_SWF -ljpeg -lz"
             ;;
           openquicktime)
-            echo_videoprovider="$echo_videoprovider -lopenquicktime -lz -lglib -lm"
+            echo_videoprovider="$echo_videoprovider -Wl,-uIDirectFBVideoProvider_OPENQUICKTIME -lopenquicktime -lz -lglib -lm"
             ;;
         esac
       done
@@ -241,11 +248,11 @@ if test -n "$echo_static"; then
 	echo -static
 
 	if test -z "$echo_system"; then
-		echo $moduledir/systems/libdirectfb_fbdev.a @SYSFS_LIBS@
+		echo -Wl,-udirectfb_fbdev $moduledir/systems/libdirectfb_fbdev.a @SYSFS_LIBS@
 	fi
 
 	if test -z "$echo_wm"; then
-		echo $moduledir/wm/libdirectfbwm_default.a
+		echo -Wl,-udirectfbwm_default $moduledir/wm/libdirectfbwm_default.a
 	fi
 fi
 
@@ -286,7 +293,7 @@ fi
 
 print_voodoo ()
 {
-	echo $moduledir/interfaces/$1/lib$2_dispatcher.a $moduledir/interfaces/$1/lib$2_requestor.a
+	echo -Wl,-u$2_dispatcher $moduledir/interfaces/$1/lib$2_dispatcher.a -Wl,-u$2_requestor $moduledir/interfaces/$1/lib$2_requestor.a
 }
 
 if test -n "$echo_voodoo"; then

