diff --git a/server/lib/Makefile.am b/server/lib/Makefile.am
index 566b63d..2825a5c 100644
--- a/server/lib/Makefile.am
+++ b/server/lib/Makefile.am
@@ -1,4 +1,4 @@
-noinst_LTLIBRARIES = \
+noinst_LTLIBRARIES =						\
 	libexchange.la
 
 PROP_GENERATED = e2k-propnames.h e2k-propnames.c e2k-proptags.h
@@ -10,23 +10,23 @@ e2k_proptags_h_in  = $(srcdir)/e2k-proptags.h.in
 
 e2k-propnames.h: $(e2k_propnames_h_in) $(mapi_properties)
 	@echo Building $@
-	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_propnames_h_in); \
-	  awk '/^x/ { printf "#define %-39s E2K_NS_MAPI_PROPTAG  \"%s \" \n", $$2, $$1; }' $(mapi_properties); \
-	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_propnames_h_in) ) \
+	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_propnames_h_in);					\
+	  awk '/^x/ { printf "#define %-39s E2K_NS_MAPI_PROPTAG \"%s\"\n", $$2, $$1; }' $(mapi_properties);	\
+	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_propnames_h_in) )			\
 	> $@
 
 e2k-propnames.c: $(e2k_propnames_c_in) $(mapi_properties)
 	@echo Building $@
-	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_propnames_c_in); \
-	  awk '/^x/ { print " \t{  \"" $$1 " \",  \"" $$2 " \" },"; }' $(mapi_properties); \
-	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_propnames_c_in) ) \
+	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_propnames_c_in);					\
+	  awk '/^x/ { print "\t{ \"" $$1 "\", \"" $$2 "\" },"; }' $(mapi_properties);				\
+	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_propnames_c_in) )			\
 	> $@
 
 e2k-proptags.h: $(e2k_proptags_h_in) $(mapi_properties)
 	@echo Building $@
-	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_proptags_h_in); \
-	  awk '/^x/ { printf "#define E2K_PROPTAG_%-39s 0%s \n", $$2, $$1; }' $(mapi_properties); \
-	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_proptags_h_in) ) \
+	@( awk '/^@AUTOGENERATE@/ {exit;} {print;}' $(e2k_proptags_h_in);					\
+	  awk '/^x/ { printf "#define E2K_PROPTAG_%-39s 0%s\n", $$2, $$1; }' $(mapi_properties);	\
+	  awk '{if (tail) { print; }} /^@AUTOGENERATE@/ {tail=1;}' $(e2k_proptags_h_in) )			\
 	> $@
 
 BUILT_SOURCES = $(PROP_GENERATED)
@@ -36,13 +36,13 @@ CLEANFILES = $(PROP_GENERATED)
 MARSHAL_GENERATED = e2k-marshal.c e2k-marshal.h
 
 e2k-marshal.h: e2k-marshal.list
-	( @GLIB_GENMARSHAL@ --prefix=e2k_marshal $(srcdir)/e2k-marshal.list --header > e2k-marshal.tmp  \
-	&& mv e2k-marshal.tmp e2k-marshal.h )  \
+	( @GLIB_GENMARSHAL@ --prefix=e2k_marshal $(srcdir)/e2k-marshal.list --header > e2k-marshal.tmp \
+	&& mv e2k-marshal.tmp e2k-marshal.h ) \
 	|| ( rm -f e2k-marshal.tmp && exit 1 )
 
 e2k-marshal.c: e2k-marshal.h
-	( (echo '#include "e2k-marshal.h"'; @GLIB_GENMARSHAL@ --prefix=e2k_marshal $(srcdir)/e2k-marshal.list --body) > e2k-marshal.tmp  \
-	&& mv e2k-marshal.tmp e2k-marshal.c )  \
+	( (echo '#include "e2k-marshal.h"'; @GLIB_GENMARSHAL@ --prefix=e2k_marshal $(srcdir)/e2k-marshal.list --body) > e2k-marshal.tmp \
+	&& mv e2k-marshal.tmp e2k-marshal.c ) \
 	|| ( rm -f e2k-marshal.tmp && exit 1 )
 
 BUILT_SOURCES += $(MARSHAL_GENERATED)
@@ -50,8 +50,8 @@ NODIST_FILES += $(MARSHAL_GENERATED)
 CLEANFILES += $(MARSHAL_GENERATED)
 
 if ENABLE_KRB5
-KERBEROS_FILES = \
-	e2k-kerberos.c \
+KERBEROS_FILES = 	\
+	e2k-kerberos.c	\
 	e2k-kerberos.h
 else
 KERBEROS_FILES =
@@ -60,70 +60,91 @@ endif
 # Fix the code to not use E_DATA_SERVER_UI_CFLAGS
 
 libexchange_la_CPPFLAGS = \
-	$(AM_CPPFLAGS) \
-	-DCONNECTOR_PREFIX=\""$(prefix)"\" \
-	-I$(top_srcdir) \
-	-I$(top_srcdir)/server/xntlm \
-	$(LDAP_CFLAGS) \
-	$(KRB5_CFLAGS) \
-	$(SOUP_CFLAGS) \
-	$(GNOME_PLATFORM_CFLAGS) \
-	$(EVOLUTION_DATA_SERVER_CFLAGS)
-
-libexchange_la_SOURCES = \
-	$(MARSHAL_GENERATED) \
-	e2k-propnames.h \
-	e2k-proptags.h \
-	e2k-action.c \
-	e2k-action.h \
-	e2k-autoconfig.c \
-	e2k-autoconfig.h \
-	e2k-context.c \
-	e2k-context.h \
-	e2k-freebusy.c \
-	e2k-freebusy.h \
-	e2k-global-catalog.c \
-	e2k-global-catalog.h \
-	e2k-global-catalog-ldap.h \
-	e2k-http-utils.c \
-	e2k-http-utils.h \
-	e2k-operation.c \
-	e2k-operation.h \
-	e2k-path.c \
-	e2k-path.h \
-	e2k-properties.c \
-	e2k-properties.h \
-	e2k-restriction.c \
-	e2k-restriction.h \
-	e2k-result.c \
-	e2k-result.h \
-	e2k-rule.c \
-	e2k-rule.h \
-	e2k-rule-xml.c \
-	e2k-rule-xml.h \
-	e2k-security-descriptor.c \
-	e2k-security-descriptor.h \
-	e2k-sid.c \
-	e2k-sid.h \
-	e2k-types.h \
-	e2k-uri.c \
-	e2k-uri.h \
-	e2k-utils.c \
-	e2k-utils.h \
-	e2k-validate.h \
-	e2k-xml-utils.c \
-	e2k-xml-utils.h \
-	$(KERBEROS_FILES) \
+	$(AM_CPPFLAGS)						\
+	-DCONNECTOR_PREFIX=\""$(prefix)"\"			\
+	-I$(top_srcdir)						\
+	-I$(top_srcdir)/servers/exchange/xntlm			\
+	$(LDAP_CFLAGS)						\
+	$(KRB5_CFLAGS)						\
+	$(SOUP_CFLAGS)						\
+	$(E_DATA_SERVER_CFLAGS)					\
+	$(E_DATA_SERVER_UI_CFLAGS)
+
+libexchange_la_SOURCES =					\
+	$(MARSHAL_GENERATED)					\
+	e2k-propnames.h						\
+	e2k-proptags.h						\
+	e2k-action.c						\
+	e2k-action.h						\
+	e2k-autoconfig.c					\
+	e2k-autoconfig.h					\
+	e2k-context.c						\
+	e2k-context.h						\
+	e2k-freebusy.c						\
+	e2k-freebusy.h						\
+	e2k-global-catalog.c					\
+	e2k-global-catalog-ldap.h				\
+	e2k-http-utils.c					\
+	e2k-http-utils.h					\
+	e2k-operation.c						\
+	e2k-operation.h						\
+	e2k-path.c						\
+	e2k-path.h						\
+	e2k-properties.c					\
+	e2k-properties.h					\
+	e2k-restriction.c					\
+	e2k-restriction.h					\
+	e2k-result.c						\
+	e2k-result.h						\
+	e2k-rule.c						\
+	e2k-rule.h						\
+	e2k-rule-xml.c						\
+	e2k-rule-xml.h						\
+	e2k-security-descriptor.c				\
+	e2k-security-descriptor.h				\
+	e2k-sid.c						\
+	e2k-sid.h						\
+	e2k-types.h						\
+	e2k-uri.c						\
+	e2k-uri.h						\
+	e2k-utils.c						\
+	e2k-utils.h						\
+	e2k-validate.h						\
+	e2k-xml-utils.c						\
+	e2k-xml-utils.h						\
+	$(KERBEROS_FILES)					\
 	mapi.h
 
-EXTRA_DIST = \
-	e2k-marshal.list \
-	mapi-properties \
-	$(e2k_propnames_h_in) \
-	$(e2k_propnames_c_in) \
+libexchangeincludedir = $(privincludedir)/exchange
+
+libexchangeinclude_HEADERS = 					\
+	e2k-autoconfig.h					\
+	e2k-context.h						\
+	e2k-freebusy.h						\
+	e2k-global-catalog.h					\
+	e2k-global-catalog-ldap.h				\
+	e2k-http-utils.h					\
+	e2k-marshal.h						\
+	e2k-operation.h						\
+	e2k-properties.h					\
+	e2k-propnames.h						\
+	e2k-restriction.h					\
+	e2k-result.h						\
+	e2k-security-descriptor.h				\
+	e2k-sid.h						\
+	e2k-types.h						\
+	e2k-uri.h						\
+	e2k-utils.h						\
+	e2k-validate.h						\
+	e2k-xml-utils.h						\
+	mapi.h
+
+EXTRA_DIST =							\
+	e2k-marshal.list					\
+	mapi-properties						\
+	$(e2k_propnames_h_in)					\
+	$(e2k_propnames_c_in)					\
 	$(e2k_proptags_h_in)
 
 dist-hook:
 	cd $(distdir); rm -f $(NODIST_FILES)
-
--include $(top_srcdir)/git.mk
diff --git a/server/storage/Makefile.am b/server/storage/Makefile.am
index d10cdad..f8f72cc 100644
--- a/server/storage/Makefile.am
+++ b/server/storage/Makefile.am
@@ -1,75 +1,104 @@
 if OS_WIN32
-WIN32_BOOTSTRAP_LIBS = \
+WIN32_BOOTSTRAP_LIBS =					\
 	$(top_builddir)/win32/libedataserverui-1.2.la
 endif
 
-noinst_LTLIBRARIES = \
-	libexchange-storage.la
+lib_LTLIBRARIES =						\
+	libexchange-storage-1.2.la
 
-libexchange_storage_la_CPPFLAGS = \
-	$(AM_CPPFLAGS) \
-	-DG_LOG_DOMAIN=\""evolution-exchange-storage"\" \
-	-DPREFIX=\""$(prefix)"\" \
-	-DSYSCONFDIR=\""$(sysconfdir)"\" \
-	-DDATADIR=\""$(datadir)"\" \
-	-DLIBDIR=\""$(datadir)"\" \
-	-DCONNECTOR_LOCALEDIR=\""$(localedir)"\" \
-	-DCONNECTOR_GLADEDIR=\""$(gladedir)"\" \
-	-I$(top_srcdir) \
-	-I$(top_srcdir)/server/lib \
-	-I$(top_srcdir)/server/xntlm \
-	-I$(top_builddir)/server/lib \
-	$(GNOME_PLATFORM_CFLAGS) \
-	$(EVOLUTION_DATA_SERVER_CFLAGS) \
-	$(KRB5_CFLAGS) \
-	$(LDAP_CFLAGS) \
-	$(SOUP_CFLAGS)
+# Fix the code to not use E_DATA_SERVER_UI_CFLAGS
 
-libexchange_storage_la_SOURCES = \
-	e-folder-exchange.c \
-	e-folder-exchange.h \
-	e-folder-tree.c \
-	e-folder-tree.h \
-	e-folder-type-registry.c \
-	e-folder-type-registry.h \
-	e-folder.c \
-	e-folder.h \
-	e-storage.c \
-	e-storage.h \
-	exchange-account.c \
-	exchange-account.h \
-	exchange-constants.h \
-	exchange-esource.c \
-	exchange-esource.h \
-	exchange-folder-size.c \
-	exchange-folder-size.h \
-	exchange-hierarchy-favorites.c \
-	exchange-hierarchy-favorites.h \
-	exchange-hierarchy-foreign.c \
-	exchange-hierarchy-foreign.h \
-	exchange-hierarchy-gal.c \
-	exchange-hierarchy-gal.h \
-	exchange-hierarchy-somedav.c \
-	exchange-hierarchy-somedav.h \
-	exchange-hierarchy-webdav.c \
-	exchange-hierarchy-webdav.h \
-	exchange-hierarchy.c \
-	exchange-hierarchy.h \
-	exchange-oof.c \
-	exchange-oof.h \
-	exchange-types.h
+libexchange_storage_1_2_la_CPPFLAGS = \
+	$(AM_CPPFLAGS)						\
+	-DG_LOG_DOMAIN=\"evolution-exchange-storage\"		\
+	-DPREFIX=\"$(prefix)\"					\
+	-DSYSCONFDIR=\""$(sysconfdir)"\" 			\
+	-DDATADIR=\""$(datadir)"\"	 			\
+	-DLIBDIR=\""$(datadir)"\"	 			\
+	-DCONNECTOR_LOCALEDIR=\""$(localedir)\""		\
+	-DCONNECTOR_GLADEDIR=\""$(gladedir)"\"			\
+	-I$(top_builddir)/servers/exchange/lib			\
+	-I$(top_srcdir)						\
+	-I$(top_srcdir)/servers/exchange/lib			\
+	-I$(top_srcdir)/servers/exchange/xntlm			\
+	$(KRB5_CFLAGS)						\
+	$(LDAP_CFLAGS)						\
+	$(SOUP_CFLAGS)						\
+	$(E_DATA_SERVER_CFLAGS)					\
+	$(E_DATA_SERVER_UI_CFLAGS)
 
-libexchange_storage_la_LIBADD = \
-	$(WIN32_BOOTSTRAP_LIBS) \
-	$(top_builddir)/server/lib/libexchange.la \
-	$(top_builddir)/server/xntlm/libxntlm.la \
-	$(GNOME_PLATFORM_LIBS) \
-	$(EVOLUTION_DATA_SERVER_LIBS) \
-	$(LDAP_LIBS) \
-	$(SOUP_LIBS) \
+libexchange_storage_1_2_la_SOURCES =				\
+	e-folder.c						\
+	e-folder.h						\
+	e-folder-exchange.c					\
+	e-folder-exchange.h					\
+	e-folder-tree.c						\
+	e-folder-tree.h						\
+	e-folder-type-registry.c				\
+	e-folder-type-registry.h				\
+	e-storage.c						\
+	e-storage.h						\
+	exchange-account.c					\
+	exchange-account.h					\
+	exchange-esource.c					\
+	exchange-esource.h					\
+	exchange-folder-size.c					\
+	exchange-folder-size.h					\
+	exchange-hierarchy-favorites.c				\
+	exchange-hierarchy-favorites.h				\
+	exchange-hierarchy-foreign.c				\
+	exchange-hierarchy-foreign.h				\
+	exchange-hierarchy-gal.c				\
+	exchange-hierarchy-gal.h				\
+	exchange-hierarchy-somedav.c				\
+	exchange-hierarchy-somedav.h				\
+	exchange-hierarchy-webdav.c				\
+	exchange-hierarchy-webdav.h				\
+	exchange-hierarchy.c					\
+	exchange-hierarchy.h					\
+	exchange-oof.c						\
+	exchange-oof.h						\
+	exchange-types.h					
+
+libexchange_storage_1_2_la_LIBADD =				\
+	$(WIN32_BOOTSTRAP_LIBS)					\
+	$(top_builddir)/servers/exchange/lib/libexchange.la	\
+	$(top_builddir)/servers/exchange/xntlm/libxntlm.la	\
+	$(top_builddir)/libedataserver/libedataserver-1.2.la	\
+	$(E_DATA_SERVER_LIBS)					\
+	$(E_DATA_SERVER_UI_LIBS)				\
+	$(LDAP_LIBS)						\
+	$(SOUP_LIBS)						\
 	$(SOCKET_LIBS)
 
-libexchange_storage_la_LDFLAGS = \
-	$(KRB5_LIBS) -avoid-version $(NO_UNDEFINED)
+libexchange_storage_1_2_la_LDFLAGS =				\
+	$(KRB5_LIBS)						\
+	$(NO_UNDEFINED)						\
+	-version-info $(LIBEXCHANGE_STORAGE_CURRENT):$(LIBEXCHANGE_STORAGE_REVISION):$(LIBEXCHANGE_STORAGE_AGE)
+
+libexchange_storageincludedir = $(privincludedir)/exchange
+
+libexchange_storageinclude_HEADERS = 				\
+	e-folder.h						\
+	e-folder-exchange.h					\
+	e-storage.h						\
+	exchange-account.h					\
+	exchange-constants.h					\
+	exchange-folder-size.h					\
+	exchange-hierarchy.h					\
+	exchange-hierarchy-somedav.h				\
+	exchange-hierarchy-webdav.h				\
+	exchange-hierarchy-foreign.h				\
+	exchange-oof.h						\
+	exchange-types.h					\
+	exchange-esource.h
+
+%-$(API_VERSION).pc: %.pc
+	cp $< $@
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = libexchange-storage-$(API_VERSION).pc
+
+EXTRA_DIST = $(pkgconfig_DATA:-$(API_VERSION).pc=.pc.in)
 
--include $(top_srcdir)/git.mk
+DISTCLEANFILES = $(pkgconfig_DATA)
diff --git a/server/storage/exchange-constants.h b/server/storage/exchange-constants.h
index b9dd618..4a928ab 100644
--- a/server/storage/exchange-constants.h
+++ b/server/storage/exchange-constants.h
@@ -21,4 +21,10 @@ typedef enum {
    avoid ABI/API break. */
 #define FORIEGN_FOLDER_FLAG 0x0100
 
+#define EXCHANGE_COMPONENT_FACTORY_IID  "OAFIID:GNOME_Evolution_Exchange_Component_Factory:" BASE_VERSION
+#define EXCHANGE_COMPONENT_IID		"OAFIID:GNOME_Evolution_Exchange_Component:" BASE_VERSION
+#define EXCHANGE_CALENDAR_FACTORY_ID	"OAFIID:GNOME_Evolution_Exchange_Connector_CalFactory:" API_VERSION
+#define EXCHANGE_ADDRESSBOOK_FACTORY_ID	"OAFIID:GNOME_Evolution_Exchange_Connector_BookFactory:" API_VERSION
+#define EXCHANGE_AUTOCONFIG_WIZARD_ID	"OAFIID:GNOME_Evolution_Exchange_Connector_Startup_Wizard:" BASE_VERSION
+
 #endif
diff --git a/server/xntlm/Makefile.am b/server/xntlm/Makefile.am
index 9d68a04..3d41096 100644
--- a/server/xntlm/Makefile.am
+++ b/server/xntlm/Makefile.am
@@ -1,16 +1,14 @@
 noinst_LTLIBRARIES = libxntlm.la
 
-libxntlm_la_SOURCES = \
-	xntlm.c \
-	xntlm.h \
-	xntlm-des.c \
-	xntlm-des.h \
-	xntlm-md4.c \
+libxntlm_la_SOURCES =	\
+	xntlm.c		\
+	xntlm.h		\
+	xntlm-des.c	\
+	xntlm-des.h	\
+	xntlm-md4.c	\
 	xntlm-md4.h
 
-libxntlm_la_CPPFLAGS = \
-	$(AM_CPPFLAGS) \
-	-I$(top_srcdir) \
+libxntlm_la_CPPFLAGS =	\
+	$(AM_CPPFLAGS)	\
+	-I$(top_srcdir)	\
 	$(GLIB_CFLAGS)
-
--include $(top_srcdir)/git.mk
