
--- kdegraphics-3.5.3/kcoloredit/Makefile.am	Sat Sep 10 04:18:59 2005
+++ kdegraphics-3.5.3-new/kcoloredit/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,21 +1,24 @@
 INCLUDES = $(all_includes)
 
-kcoloredit_SOURCES = kzcolorselector.cpp imageselection.cpp \
+kcoloredit_la_SOURCES = kzcolorselector.cpp imageselection.cpp \
 	texteditselection.cpp gradientselection.cpp colorselector.cpp \
 	kxycolorselector.cpp paletteview.cpp paletteviewscrolledarea.cpp \
 	editablestreamhistory.cpp color.cpp palette.cpp loadpalettedlg.cpp \
 	kcoloreditview.cpp kcoloreditdoc.cpp kcoloredit.cpp main.cpp 
-kcoloredit_METASOURCES = AUTO
-kcoloredit_LDADD = $(LIB_KDEUI) $(LIB_KFILE)
-kcoloredit_LDFLAGS = $(all_libraries) $(KDE_RPATH)
+kcoloredit_la_METASOURCES = AUTO
+kcoloredit_la_LIBADD = $(LIB_KDEUI) $(LIB_KFILE)
+kcoloredit_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
 
 rcdir = $(kde_datadir)/kcoloredit
 rc_DATA = kcoloreditui.rc
 
-bin_PROGRAMS = kcoloredit kcolorchooser
-kcolorchooser_SOURCES = kcolorchooser.cpp
-kcolorchooser_LDADD = $(LIB_KDEUI)
-kcolorchooser_LDFLAGS = $(all_libraries) $(KDE_RPATH)
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kcoloredit.la kcolorchooser.la
+
+kcolorchooser_la_SOURCES = kcolorchooser.cpp
+kcolorchooser_la_LIBADD = $(LIB_KDEUI)
+kcolorchooser_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
 
 noinst_HEADERS = color.h colorselector.h editablestreamhistory.h \
 	gradientselection.h imageselection.h kcoloredit.h kcoloreditdoc.h \
--- kdegraphics-3.5.3/kcoloredit/kcolorchooser.cpp	Sat Sep 10 04:18:59 2005
+++ kdegraphics-3.5.3-new/kcoloredit/kcolorchooser.cpp	Fri May 26 10:18:23 2006
@@ -41,7 +41,7 @@
    KCmdLineLastOption
 };
 	
-int main(int argc, char *argv[])
+extern "C" KDE_EXPORT int kdemain(int argc, char *argv[])
 {
   KLocale::setMainCatalogue("kdelibs"); 
   KAboutData aboutData( "kcolorchooser", I18N_NOOP("KColorChooser"),
--- kdegraphics-3.5.3/kcoloredit/main.cpp	Sat Sep 10 04:18:59 2005
+++ kdegraphics-3.5.3-new/kcoloredit/main.cpp	Fri May 26 10:18:23 2006
@@ -34,7 +34,7 @@
   // INSERT YOUR COMMANDLINE OPTIONS HERE
 };
 
-int main(int argc, char *argv[])
+extern "C" KDE_EXPORT int kdemain(int argc, char *argv[])
 {
 
 	KAboutData aboutData( "kcoloredit", I18N_NOOP("KColorEdit"),
--- kdegraphics-3.5.3/kdvi/Makefile.am	Sat Sep 10 04:18:58 2005
+++ kdegraphics-3.5.3-new/kdvi/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,11 +1,13 @@
 # set the include path for X, qt and KDE
 INCLUDES= -I$(top_srcdir)/kviewshell \
 	-I$(top_builddir)/kviewshell \
-	$(all_includes) $(LIBFREETYPE_CFLAGS)
+	$(LIBFREETYPE_CFLAGS) $(all_includes)
 # claim, which subdirectories you want to install
 SUBDIRS = . pix
 
-bin_PROGRAMS = kdvi
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kdvi.la
 
 # you can add here more. This one gets installed
 kde_module_LTLIBRARIES= kdvipart.la
@@ -38,9 +40,9 @@
 
 KDE_OPTIONS = nofinal
 
-kdvi_SOURCES = main.cpp 
-kdvi_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kdvi_LDADD = ../kviewshell/libifaces.la ../kviewshell/libkviewshell.la -lkparts
+kdvi_la_SOURCES = main.cpp 
+kdvi_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kdvi_la_LIBADD = ../kviewshell/libifaces.la ../kviewshell/libkviewshell.la -lkparts
 
 ## this option you can leave out. Just, if you use "make dist", you need it
 noinst_HEADERS = dvi.h dviRenderer.h xdvi.h
--- kdegraphics-3.5.3/kdvi/main.cpp	Tue Nov  8 17:25:52 2005
+++ kdegraphics-3.5.3-new/kdvi/main.cpp	Fri May 26 10:18:23 2006
@@ -29,7 +29,7 @@
 static const char description[] = I18N_NOOP("A previewer for Device Independent files (DVI files) produced by the TeX typesetting system.");
 
 
-int main(int argc, char** argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char** argv)
 {
   KAboutData about ("kdvi", I18N_NOOP("KDVI"), "1.4",
                     description, KAboutData::License_GPL,
--- kdegraphics-3.5.3/kfax/Makefile.am	Mon Oct 10 10:56:54 2005
+++ kdegraphics-3.5.3-new/kfax/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,16 +1,18 @@
-AM_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-LDADD      = $(LIB_KFILE) $(LIB_KDEPRINT) -lm
 INCLUDES   = $(all_includes)
 
 ####### Files
 noinst_HEADERS = kfax.h faxexpand.h options.h
 
-kfax_SOURCES   = options.cpp kfax.cpp faxexpand.cpp faxinit.cpp faxinput.cpp \
+kfax_la_SOURCES   = options.cpp kfax.cpp faxexpand.cpp faxinit.cpp faxinput.cpp \
 		 viewfax.cpp kfax_printsettings.cpp
+kfax_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kfax_la_LIBADD  = $(LIB_KFILE) $(LIB_KDEPRINT) -lm
 
 METASOURCES    = AUTO
 
-bin_PROGRAMS   = kfax
+bin_PROGRAMS   = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kfax.la
 
 xdg_apps_DATA = kfax.desktop
 
--- kdegraphics-3.5.3/kfax/kfax.cpp	Mon Oct 10 10:56:54 2005
+++ kdegraphics-3.5.3-new/kfax/kfax.cpp	Fri May 26 10:18:23 2006
@@ -1682,7 +1682,7 @@
    KCmdLineLastOption
 };
 
-int main (int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain (int argc, char **argv)
 {
   KAboutData aboutData( "kfax", I18N_NOOP("KFax"),
       KFAXVERSION, description, KAboutData::License_GPL,
--- kdegraphics-3.5.3/kfaxview/libkfaximage/Makefile.am	Sat Sep 10 04:18:44 2005
+++ kdegraphics-3.5.3-new/kfaxview/libkfaximage/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,7 +1,7 @@
 INCLUDES = -I$(top_srcdir) $(all_includes)
 
 lib_LTLIBRARIES = libkfaximage.la
-libkfaximage_la_LDFLAGS = $(all_libraries) -no-undefined -avoid-version
+libkfaximage_la_LDFLAGS = $(all_libraries) -no-undefined
 libkfaximage_la_LIBADD  = $(LIB_KDECORE)
 libkfaximage_la_SOURCES = kfaximage.cpp faxexpand.cpp faxinit.cpp
 
--- kdegraphics-3.5.3/kfile-plugins/png/Makefile.am	Sat Sep 10 04:19:24 2005
+++ kdegraphics-3.5.3-new/kfile-plugins/png/Makefile.am	Fri May 26 10:18:23 2006
@@ -10,7 +10,7 @@
 
 kfile_png_la_SOURCES = kfile_png.cpp
 kfile_png_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
-kfile_png_la_LIBADD = $(LIB_KIO)
+kfile_png_la_LIBADD = $(LIB_KIO) $(LIBPNG)
 
 # let automoc handle all of the meta source files (moc)
 METASOURCES = AUTO
--- kdegraphics-3.5.3/kghostview/Makefile.am	Mon May 22 14:05:40 2006
+++ kdegraphics-3.5.3-new/kghostview/Makefile.am	Fri May 26 10:18:23 2006
@@ -4,7 +4,8 @@
 
 ####### Files
 
-bin_PROGRAMS = 	kghostview
+kdeinit_LTLIBRARIES = kghostview.la
+bin_PROGRAMS = 	
 lib_LTLIBRARIES = libkghostviewlib.la
 kde_module_LTLIBRARIES = libkghostviewpart.la
 noinst_LTLIBRARIES = libdscparse.la
@@ -27,9 +28,9 @@
 
 libkghostviewpart_la_SOURCES = part_init.cpp
 
-kghostview_SOURCES = main.cpp
-kghostview_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kghostview_LDADD = libkghostviewlib.la
+kghostview_la_SOURCES = main.cpp
+kghostview_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kghostview_la_LIBADD = libkghostviewlib.la
 
 libdscparse_la_LDFLAGS = $(all_libraries) -no-undefined
 libdscparse_la_LIBADD = $(LIB_QT)
--- kdegraphics-3.5.3/kghostview/main.cpp	Mon Oct 10 10:56:55 2005
+++ kdegraphics-3.5.3-new/kghostview/main.cpp	Fri May 26 10:18:23 2006
@@ -43,7 +43,7 @@
     KCmdLineLastOption
 };
 
-int main( int argc, char** argv )
+extern "C" KDE_EXPORT int kdemain( int argc, char** argv )
 {
     KCmdLineArgs::init( argc, argv, KGVPart::createAboutData() );
     KCmdLineArgs::addCmdLineOptions( options );
--- kdegraphics-3.5.3/kiconedit/Makefile.am	Fri Mar 17 05:11:23 2006
+++ kdegraphics-3.5.3-new/kiconedit/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,18 +1,20 @@
 INCLUDES = $(all_includes)
 SUBDIRS = pics
 
-bin_PROGRAMS = kiconedit
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kiconedit.la
 
-kiconedit_SOURCES = utils.cpp main.cpp kiconedit.cpp kicongrid.cpp \
+kiconedit_la_SOURCES = utils.cpp main.cpp kiconedit.cpp kicongrid.cpp \
     kiconcolors.cpp kcolorgrid.cpp palettetoolbar.cpp\
     kicon.cpp kresize.cpp knew.cpp properties.cpp \
     kiconeditslots.cpp kiconconfig.cpp 
 
-kiconedit_METASOURCES = AUTO
+kiconedit_la_METASOURCES = AUTO
 
 # the library search path. 
-kiconedit_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kiconedit_LDADD = $(LIB_KFILE) -lkdeprint
+kiconedit_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kiconedit_la_LIBADD = $(LIB_KFILE) -lkdeprint
 
 DISTCLEANFILES = *~ .deps/* .libs/*
 
--- kdegraphics-3.5.3/kiconedit/main.cpp	Mon Oct 10 10:56:55 2005
+++ kdegraphics-3.5.3-new/kiconedit/main.cpp	Fri May 26 10:18:23 2006
@@ -40,7 +40,7 @@
   KCmdLineLastOption
 };
 
-int main(int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char **argv)
 {
   KAboutData aboutData( "kiconedit", I18N_NOOP("KIconEdit"),
     VERSION, description, KAboutData::License_GPL,
--- kdegraphics-3.5.3/kooka/Makefile.am	Sat Sep 10 04:19:00 2005
+++ kdegraphics-3.5.3-new/kooka/Makefile.am	Fri May 26 10:18:23 2006
@@ -2,10 +2,13 @@
 
 SUBDIRS = pics
 
-bin_PROGRAMS = kooka
+bin_PROGRAMS =
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kooka.la
+
 METASOURCES = AUTO
 
-kooka_SOURCES =	main.cpp kooka.cpp kookaview.cpp kookapref.cpp 		\
+kooka_la_SOURCES =	main.cpp kooka.cpp kookaview.cpp kookapref.cpp 		\
 		img_saver.cpp ksaneocr.cpp \
 		kookaimage.cpp kookaimagemeta.cpp scanpackager.cpp 	\
 		imgnamecombo.cpp imageselectline.cpp      \
@@ -16,8 +19,8 @@
 		kocrocrad.cpp
 # 		pagesetup.cpp 
 
-kooka_LDADD   = $(LIB_KFILE) -lkdeprint -lktexteditor $(LIBTIFF) $(top_builddir)/libkscan/libkscan.la $(KADMOS_LIB) $(LIB_KSPELL)
-kooka_LDFLAGS = $(KDE_RPATH) $(all_libraries)
+kooka_la_LIBADD   = $(LIB_KFILE) -lkdeprint -lktexteditor $(LIBTIFF) $(top_builddir)/libkscan/libkscan.la $(KADMOS_LIB) $(LIB_KSPELL)
+kooka_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries) -module
 
 INCLUDES         = -I$(top_srcdir)/libkscan $(all_includes) $(LIBSANE_INCLUDES) $(KADMOS_INC)
 
--- kdegraphics-3.5.3/kooka/main.cpp	Sat Sep 10 04:19:00 2005
+++ kdegraphics-3.5.3-new/kooka/main.cpp	Fri May 26 10:18:23 2006
@@ -71,7 +71,7 @@
 
 
 
-int main( int argc, char *argv[] )
+extern "C" KDE_EXPORT int kdemain( int argc, char *argv[] )
 {
    KAboutData about("kooka", I18N_NOOP("Kooka"), KOOKA_VERSION, I18N_NOOP(description),
 		    KAboutData::License_GPL_V2, "(C) 2000 Klaas Freitag", 0,
--- kdegraphics-3.5.3/kpdf/Makefile.am	Sat Sep 10 04:18:43 2005
+++ kdegraphics-3.5.3-new/kpdf/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,6 +1,6 @@
 SUBDIRS = xpdf conf core ui shell
 
-INCLUDES = -I$(srcdir)/xpdf -I$(srcdir)/xpdf/goo -I$(top_builddir)/kpdf $(all_includes) $(FREETYPE_CFLAGS)
+INCLUDES = -I$(srcdir)/xpdf -I$(srcdir)/xpdf/goo -I$(top_builddir)/kpdf $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) $(all_includes)
 
 METASOURCES = AUTO
 
--- kdegraphics-3.5.3/kpdf/shell/Makefile.am	Sat Sep 10 04:18:43 2005
+++ kdegraphics-3.5.3-new/kpdf/shell/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,12 +1,15 @@
-INCLUDES = -I$(srcdir)/xpdf -I$(srcdir)/xpdf/goo -I$(top_builddir)/kpdf $(all_includes) $(FREETYPE_CFLAGS)
+INCLUDES = -I$(srcdir)/xpdf -I$(srcdir)/xpdf/goo -I$(top_builddir)/kpdf $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) $(all_includes)
+LDFLAGS  = $(FREETYPE_LDFLAGS) $(FONTCONFIG_LDFLAGS)
 
 METASOURCES = AUTO
 
-bin_PROGRAMS = kpdf
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kpdf.la
 
-kpdf_SOURCES = main.cpp shell.cpp
-kpdf_LDFLAGS = $(KDE_RPATH) $(all_libraries)
-kpdf_LDADD   = $(LIB_KPARTS)
+kpdf_la_SOURCES = main.cpp shell.cpp
+kpdf_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries) -module
+kpdf_la_LIBADD  = $(LIB_KPARTS)
 
 EXTRA_DIST = kpdf.desktop
 xdg_apps_DATA = kpdf.desktop
--- kdegraphics-3.5.3/kpdf/shell/main.cpp	Mon May 22 14:05:33 2006
+++ kdegraphics-3.5.3-new/kpdf/shell/main.cpp	Fri May 26 10:18:23 2006
@@ -29,7 +29,7 @@
     KCmdLineLastOption
 };
 
-int main(int argc, char** argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char** argv)
 {
     KAboutData about(
         "kpdf",
--- kdegraphics-3.5.3/kpdf/xpdf/xpdf/GlobalParams.cc	Tue Nov  8 17:25:47 2005
+++ kdegraphics-3.5.3-new/kpdf/xpdf/xpdf/GlobalParams.cc	Fri May 26 10:18:23 2006
@@ -1315,7 +1315,7 @@
   if (type.contains("Italic")) slant=FC_SLANT_ITALIC;
   if (type.contains("Bold")) weight=FC_WEIGHT_BOLD;
   if (type.contains("Light")) weight=FC_WEIGHT_LIGHT;
-  if (type.contains("Condensed")) width=FC_WIDTH_CONDENSED;
+  // if (type.contains("Condensed")) width=FC_WIDTH_CONDENSED;
 }
 
 DisplayFontParam *GlobalParams::getDisplayFont(GString *fontName) {
@@ -1329,13 +1329,14 @@
   dfp = (DisplayFontParam *)displayFonts->lookup(fontName);
   // KPDF: try to find font using Xft
   if (!dfp) {
-  	int weight=FC_WEIGHT_MEDIUM, slant=FC_SLANT_ROMAN, width=FC_WIDTH_NORMAL;
+  	int weight=FC_WEIGHT_MEDIUM, slant=FC_SLANT_ROMAN, width=0;
 	QString name(fontName->getCString());
 	
 	parseStyle(name,weight,slant,width);
 	p = FcPatternBuild(0,FC_FAMILY,FcTypeString, name.ascii(), 
 		FC_SLANT, FcTypeInteger, slant, FC_WEIGHT, FcTypeInteger, weight,
-		FC_WIDTH, FcTypeInteger, width, FC_LANG, FcTypeString, "xx", (char*)0);
+		// FC_WIDTH, FcTypeInteger, width, FC_LANG, FcTypeString, "xx", (char*)0);
+		FC_LANG, FcTypeString, "xx", (char*)0);
 	if (!p) goto fin;
 	m = XftFontMatch(qt_xdisplay(),qt_xscreen(),p,&res);
 	if (!m) goto fin;
--- kdegraphics-3.5.3/kpdf/xpdf/xpdf/Makefile.am	Mon May 22 14:05:33 2006
+++ kdegraphics-3.5.3-new/kpdf/xpdf/xpdf/Makefile.am	Fri May 26 10:21:48 2006
@@ -1,7 +1,7 @@
 INCLUDES = -I$(srcdir)/.. -I$(srcdir)/../fofi -I$(srcdir)/../splash -I$(srcdir)/../goo $(LIBFREETYPE_CFLAGS) $(XFT_CFLAGS) $(all_includes)
 
 libxpdf_la_LDFLAGS = $(all_libraries)
-libxpdf_la_LIBADD = $(LIB_X11) $(LIBFREETYPE_LIBS) $(LIBPAPER_LIBS) $(XFT_LIBS) $(LIBJPEG) ../goo/libgoo.la ../fofi/libfofi.la ../splash/libsplash.la 
+libxpdf_la_LIBADD = $(LIBFREETYPE_LIBS) $(XFT_LIBS) $(LIB_X11) $(LIBPAPER_LIBS) $(LIBJPEG) ../goo/libgoo.la ../fofi/libfofi.la ../splash/libsplash.la 
 libxpdf_la_SOURCES = Annot.cc Array.cc BuiltinFont.cc BuiltinFontTables.cc \
      Catalog.cc CharCodeToUnicode.cc CMap.cc Decrypt.cc Dict.cc DCTStream.cc \
      FontEncodingTables.cc Function.cc Gfx.cc \
--- kdegraphics-3.5.3/kpovmodeler/Makefile.am	Sat Sep 10 04:18:54 2005
+++ kdegraphics-3.5.3-new/kpovmodeler/Makefile.am	Fri May 26 10:18:23 2006
@@ -224,11 +224,12 @@
 ####
 # the executable
 
-bin_PROGRAMS = kpovmodeler
+bin_PROGRAMS = 
+kdeinit_LTLIBRARIES = kpovmodeler.la
 
-kpovmodeler_SOURCES = main.cpp
-kpovmodeler_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kpovmodeler_LDADD = libkpovmodeler.la
+kpovmodeler_la_SOURCES = main.cpp
+kpovmodeler_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kpovmodeler_la_LIBADD  = libkpovmodeler.la
 
 dummy.cpp:
 	echo > dummy.cpp
--- kdegraphics-3.5.3/kpovmodeler/main.cpp	Sat Sep 10 04:18:54 2005
+++ kdegraphics-3.5.3-new/kpovmodeler/main.cpp	Fri May 26 10:18:23 2006
@@ -35,7 +35,7 @@
   KCmdLineLastOption
 };
 
-int main( int argc, char* argv[] )
+extern "C" KDE_EXPORT int kdemain( int argc, char* argv[] )
 {
    PMShell* shell = 0;
 
--- kdegraphics-3.5.3/kruler/Makefile.am	Sat Sep 10 04:19:23 2005
+++ kdegraphics-3.5.3-new/kruler/Makefile.am	Fri May 26 10:18:23 2006
@@ -2,11 +2,14 @@
 
 INCLUDES= $(all_includes)
 
-bin_PROGRAMS = kruler
-kruler_METASOURCES = AUTO
-kruler_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kruler_LDADD   = $(LIB_KDEUI)
-kruler_SOURCES = klineal.cpp main.cpp 
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = kruler.la
+
+kruler_la_METASOURCES = AUTO
+kruler_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kruler_la_LIBADD  = $(LIB_KDEUI)
+kruler_la_SOURCES = klineal.cpp main.cpp 
 
 xdg_apps_DATA = kruler.desktop
 
--- kdegraphics-3.5.3/kruler/main.cpp	Sat Sep 10 04:19:23 2005
+++ kdegraphics-3.5.3-new/kruler/main.cpp	Fri May 26 10:18:23 2006
@@ -22,7 +22,7 @@
   // INSERT YOUR COMMANDLINE OPTIONS HERE
 };
 
-int main(int argc, char *argv[])
+extern "C" KDE_EXPORT int kdemain(int argc, char *argv[])
 {
 
 
--- kdegraphics-3.5.3/ksnapshot/Makefile.am	Sat Sep 10 04:19:19 2005
+++ kdegraphics-3.5.3-new/ksnapshot/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,14 +1,16 @@
-bin_PROGRAMS= ksnapshot
+bin_PROGRAMS= 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = ksnapshot.la
 
 INCLUDES = -DKSNAPVERSION="\"0.7\"" $(all_includes)
 
-ksnapshot_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-ksnapshot_LDADD = $(LIB_KDEPRINT)
+ksnapshot_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module
+ksnapshot_la_LIBADD = $(LIB_KDEPRINT)
 
-ksnapshot_SOURCES = ksnapshotiface.skel main.cpp ksnapshot.cpp \
+ksnapshot_la_SOURCES = ksnapshotiface.skel main.cpp ksnapshot.cpp \
     regiongrabber.cpp windowgrabber.cpp ksnapshotwidget.ui
 
-ksnapshot_METASOURCES = AUTO
+ksnapshot_la_METASOURCES = AUTO
 
 xdg_apps_DATA = ksnapshot.desktop
 
--- kdegraphics-3.5.3/ksnapshot/main.cpp	Mon Oct 10 10:56:53 2005
+++ kdegraphics-3.5.3-new/ksnapshot/main.cpp	Fri May 26 10:18:23 2006
@@ -40,7 +40,7 @@
     { 0, 0, 0 }
 };
 
-int main(int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char **argv)
 {
   KAboutData aboutData( "ksnapshot", I18N_NOOP("KSnapshot"),
     KSNAPVERSION, description, KAboutData::License_GPL,
--- kdegraphics-3.5.3/ksvg/Makefile.am	Sat Sep 10 04:19:19 2005
+++ kdegraphics-3.5.3-new/ksvg/Makefile.am	Fri May 26 10:18:23 2006
@@ -4,9 +4,9 @@
 libksvg_la_SOURCES = dummy.cc
 libksvg_la_METASOURCES = AUTO
 libksvg_la_LDFLAGS = -version-info 0:1:0 -no-undefined $(all_libraries)
-libksvg_la_LIBADD  = dom/libksvgdom.la impl/libksvgdomimpl.la core/libksvgcore.la ecma/libksvgecma.la \
+libksvg_la_LIBADD  = $(FREETYPE_LIBS) $(FONTCONFIG_LIBS) dom/libksvgdom.la impl/libksvgdomimpl.la core/libksvgcore.la ecma/libksvgecma.la \
 		     $(LCMS_LIBS) impl/libs/xrgbrender/libksvgxrgbrender.la impl/libs/libtext2path/src/libtext2path.la \
-			 impl/libs/art_support/libksvgart.la -lkjs $(LIB_KHTML) $(LIBART_LIBS) $(FREETYPE_LIBS) $(FONTCONFIG_LIBS)
+			 impl/libs/art_support/libksvgart.la -lkjs $(LIB_KHTML)
 
 INCLUDES = -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl $(all_includes)
 
--- kdegraphics-3.5.3/ksvg/impl/libs/libtext2path/src/Makefile.am	Sat Sep 10 04:19:14 2005
+++ kdegraphics-3.5.3-new/ksvg/impl/libs/libtext2path/src/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,10 +1,10 @@
 lib_LTLIBRARIES = libtext2path.la
 
 KDE_CXXFLAGS = $(USE_EXCEPTIONS)
-INCLUDES = $(FRIBIDI_CFLAGS) $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) $(all_includes)
+INCLUDES = $(FREETYPE_CFLAGS) $(FRIBIDI_CFLAGS) $(FONTCONFIG_CFLAGS) $(all_includes)
 
 libtext2path_includedir=$(includedir)/libtext2path-0.1
 libtext2path_include_HEADERS = BezierPath.h Glyph.h GlyphTracer.h
 
 libtext2path_la_SOURCES = Affine.cpp Rectangle.cpp Font.cpp Glyph.cpp GlyphTracer.cpp Converter.cpp QtUnicode.cpp
-libtext2path_la_LDFLAGS = $(FRIBIDI_LIBS) $(FONTCONFIG_LIBS)
+libtext2path_la_LDFLAGS = $(FREETYPE_LIBS) $(FONTCONFIG_LIBS) $(FRIBIDI_LIBS)
--- kdegraphics-3.5.3/ksvg/plugin/backends/agg/Makefile.am	Sat Sep 10 04:19:12 2005
+++ kdegraphics-3.5.3-new/ksvg/plugin/backends/agg/Makefile.am	Fri May 26 10:18:23 2006
@@ -12,4 +12,4 @@
 kde_services_DATA = ksvgaggcanvas.desktop
 
 KDE_CXXFLAGS = $(USE_EXCEPTIONS)
-INCLUDES = $(KDE_INCLUDES) $(AGG_CFLAGS) $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl -I$(top_srcdir)/ksvg/ecma -I$(top_srcdir)/ksvg/core -I$(top_srcdir)/ksvg/impl/libs/art_support -I$(top_srcdir)/ksvg/impl/libs/libtext2path/src $(all_includes)
+INCLUDES = $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) $(KDE_INCLUDES) $(AGG_CFLAGS) -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl -I$(top_srcdir)/ksvg/ecma -I$(top_srcdir)/ksvg/core -I$(top_srcdir)/ksvg/impl/libs/art_support -I$(top_srcdir)/ksvg/impl/libs/libtext2path/src $(all_includes)
--- kdegraphics-3.5.3/ksvg/plugin/backends/libart/Makefile.am	Sat Sep 10 04:19:11 2005
+++ kdegraphics-3.5.3-new/ksvg/plugin/backends/libart/Makefile.am	Fri May 26 10:18:23 2006
@@ -8,4 +8,4 @@
 kde_services_DATA = ksvglibartcanvas.desktop
 
 KDE_CXXFLAGS = $(USE_EXCEPTIONS)
-INCLUDES = $(LIBART_CFLAGS) $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl -I$(top_srcdir)/ksvg/ecma -I$(top_srcdir)/ksvg/core -I$(top_srcdir)/ksvg/impl/libs/art_support -I$(top_srcdir)/ksvg/impl/libs/libtext2path/src $(KDE_INCLUDES) $(all_includes)
+INCLUDES = $(FREETYPE_CFLAGS) $(LIBART_CFLAGS) $(FONTCONFIG_CFLAGS) -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl -I$(top_srcdir)/ksvg/ecma -I$(top_srcdir)/ksvg/core -I$(top_srcdir)/ksvg/impl/libs/art_support -I$(top_srcdir)/ksvg/impl/libs/libtext2path/src $(KDE_INCLUDES) $(all_includes)
--- kdegraphics-3.5.3/ksvg/test/external/Makefile.am	Sat Sep 10 04:19:09 2005
+++ kdegraphics-3.5.3-new/ksvg/test/external/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,13 +1,16 @@
 INCLUDES = $(FREETYPE_CFLAGS) -I$(top_srcdir)/ksvg -I$(top_srcdir)/ksvg/dom -I$(top_srcdir)/ksvg/impl -I$(top_srcdir)/ksvg/ecma -I$(top_srcdir)/ksvg/core -I$(top_srcdir)/ksvg/impl/libs/libtext2path/src $(all_includes)
+LDFLAGS = $(FREETYPE_LDFLAGS)
 METASOURCES = AUTO
 KDE_CXXFLAGS = $(USE_EXCEPTIONS)
 
-bin_PROGRAMS = svgdisplay printnodetest
+bin_PROGRAMS = 
+lib_LTLIBRARIES =
+kdeinit_LTLIBRARIES = svgdisplay.la printnodetest.la
 
-svgdisplay_SOURCES = SVGTestWidget.cc svgdisplay.cc
-svgdisplay_LDADD =  $(LIB_KDECORE) ../../libksvg.la
-svgdisplay_LDFLAGS = $(KDE_RPATH) $(all_libraries)
+svgdisplay_la_SOURCES = SVGTestWidget.cc svgdisplay.cc
+svgdisplay_la_LIBADD =  $(LIB_KDECORE) ../../libksvg.la
+svgdisplay_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries) -module
 
-printnodetest_SOURCES = printnodetest.cpp
-printnodetest_LDADD =  $(LIB_KDECORE) ../../libksvg.la
-printnodetest_LDFLAGS = $(KDE_RPATH) $(all_libraries)
+printnodetest_la_SOURCES = printnodetest.cpp
+printnodetest_la_LIBADD =  $(LIB_KDECORE) ../../libksvg.la
+printnodetest_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries) -module
--- kdegraphics-3.5.3/ksvg/test/external/printnodetest.cpp	Mon Oct 10 10:56:46 2005
+++ kdegraphics-3.5.3-new/ksvg/test/external/printnodetest.cpp	Fri May 26 10:18:23 2006
@@ -44,7 +44,7 @@
 	exit(0);
 }
 
-int main(int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char **argv)
 {
 	KAboutData *about = new KAboutData("KSVG printNode test app", I18N_NOOP("KSVG test"), "0.1", I18N_NOOP("KSVG printNode test app"));
 	KCmdLineArgs::init(argc, argv, about);
--- kdegraphics-3.5.3/ksvg/test/external/svgdisplay.cc	Sat Sep 10 04:19:09 2005
+++ kdegraphics-3.5.3-new/ksvg/test/external/svgdisplay.cc	Fri May 26 10:18:23 2006
@@ -10,7 +10,7 @@
 	KCmdLineLastOption
 };
 
-int main(int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char **argv)
 {
 
 	KAboutData *about = new KAboutData( "KSVG test app", I18N_NOOP("KSVG test"), "0.1", I18N_NOOP("KSVG standalone test app") );
--- kdegraphics-3.5.3/kviewshell/Makefile.am	Sat Sep 10 04:19:21 2005
+++ kdegraphics-3.5.3-new/kviewshell/Makefile.am	Fri May 26 10:18:23 2006
@@ -5,8 +5,9 @@
 
 ####### Files
 
-bin_PROGRAMS = 	kviewshell
+bin_PROGRAMS = 	
 lib_LTLIBRARIES = libkmultipage.la
+kdeinit_LTLIBRARIES = kviewshell.la
 kde_module_LTLIBRARIES = kviewerpart.la emptymultipagepart.la
 noinst_LTLIBRARIES = libifaces.la libkviewshell.la
 
@@ -38,9 +39,9 @@
 
 libkviewshell_la_SOURCES = kviewshell.cpp
 
-kviewshell_SOURCES = main.cpp
-kviewshell_LDFLAGS = $(all_libraries) $(KDE_RPATH)
-kviewshell_LDADD = libkviewshell.la ./libifaces.la -lkparts
+kviewshell_la_SOURCES = main.cpp
+kviewshell_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
+kviewshell_la_LIBADD = libkviewshell.la ./libifaces.la -lkparts
 
 kviewshellinclude_HEADERS = anchor.h bookmark.h pageView.h documentPageCache.h documentRenderer.h documentWidget.h \
 	history.h hyperlink.h kmultipage.h length.h pageNumber.h pageSize.h renderedDocumentPage.h renderedDocumentPagePixmap.h \
--- kdegraphics-3.5.3/kviewshell/main.cpp	Tue Nov  8 17:25:45 2005
+++ kdegraphics-3.5.3-new/kviewshell/main.cpp	Fri May 26 10:18:23 2006
@@ -32,7 +32,7 @@
 static const char description[] = I18N_NOOP("Generic framework for viewer applications");
 
 
-int main(int argc, char **argv)
+extern "C" KDE_EXPORT int kdemain(int argc, char **argv)
 {
   KAboutData about ("kviewshell", I18N_NOOP("KViewShell"), "0.6",
 		    description, KAboutData::License_GPL,
--- kdegraphics-3.5.3/kviewshell/plugins/djvu/libdjvu/Makefile.am	Tue Nov  8 17:25:45 2005
+++ kdegraphics-3.5.3-new/kviewshell/plugins/djvu/libdjvu/Makefile.am	Fri May 26 10:18:23 2006
@@ -1,7 +1,7 @@
 INCLUDES = -I$(top_srcdir) $(all_includes)
 
-kde_module_LTLIBRARIES = libdjvu.la
-libdjvu_la_LDFLAGS = -avoid-version $(all_libraries)
+lib_LTLIBRARIES = libdjvu.la
+libdjvu_la_LDFLAGS = $(all_libraries)
 libdjvu_la_LIBADD = $(LIBJPEG)
 libdjvu_la_SOURCES = Arrays.cpp DjVuDocEditor.cpp DjVuMessageLite.cpp GOS.cpp IW44Image.cpp \
 	BSByteStream.cpp DjVuDocument.cpp DjVuNavDir.cpp GPixmap.cpp JB2EncodeCodec.cpp \
--- kdegraphics-3.5.3/libkscan/img_canvas.cpp	Mon May 22 14:05:37 2006
+++ kdegraphics-3.5.3-new/libkscan/img_canvas.cpp	Fri May 26 10:18:23 2006
@@ -701,7 +701,7 @@
                            double(image->width());
             kdDebug(29000) << "FIT WIDTH scrollbar to substract: " << sbWidth << endl;
         }
-        scale_factor = 100*used_xscaler;
+        scale_factor = (int)(100*used_xscaler);
         break;
     case FIT_HEIGHT:
         used_yscaler = used_xscaler = double(noSBSize.height())/double(image->height());
@@ -716,12 +716,12 @@
             kdDebug(29000) << "FIT HEIGHT scrollbar to substract: " << sbWidth << endl;
             // scale = int(100.0*(noSBSize.height() -sbWidth) / image->height());
         }
-        scale_factor = 100*used_xscaler;
+        scale_factor = (int)(100*used_xscaler);
 
         break;
     case ZOOM:
         used_xscaler = used_yscaler = double(getScaleFactor())/100.0;
-        scale_factor = 100*used_xscaler;
+        scale_factor = (int)(100*used_xscaler);
         break;
     default:
         break;
