<URL: http://bugs.freeciv.org/Ticket/Display.html?id=18651 >

> [EMAIL PROTECTED] - Do 05. Okt 2006, 20:14:48]:
> 
> Okay but why is BUILT_SOURCES needed?
> 
> -jason
> 

Well, I couldn't get the generated Makefile to build anything until
Google found me a page about this "BUILT_SOURCES" variable which finally
did the trick ;-)
But now you were asking I did some more research and hopefully found the 
right variables in a Makefile.am from FileZilla:
http://filezilla.cvs.sourceforge.net/filezilla/FileZilla3/src/interface/resources/Makefile.am?revision=1.34&view=markup

Updated patches attached.

Index: client/Makefile.am
===================================================================
--- client/Makefile.am	(revision 12328)
+++ client/Makefile.am	(working copy)
@@ -49,6 +49,10 @@
 WINMM_FILES=$(ALL_WINMM_FILES)
 endif
 
+if MINGW32
+CLIENTICON=../win32/clienticon.o
+endif
+
 EXTRA_DIST= 	gui-mui/autogroupclass.c         \
 		gui-mui/autogroupclass.h         \
 		gui-mui/chatline.c               \
@@ -201,7 +205,7 @@
 		 	@gui_sources@/libguiclient.a
 civclient_DEPENDENCIES = $(fc_civclient_libs)
 civclient_LDADD        = $(fc_civclient_libs) $(fc_civclient_libs) \
-	@INTLLIBS@ @CLIENT_LIBS@ @SOUND_LIBS@
+	@INTLLIBS@ @CLIENT_LIBS@ @SOUND_LIBS@ $(CLIENTICON)
 desktopfiledir = $(prefix)/share/applications
 desktopfile_DATA = \
 	freeciv.desktop
Index: configure.ac
===================================================================
--- configure.ac	(revision 12328)
+++ configure.ac	(working copy)
@@ -448,6 +448,7 @@
 AM_CONDITIONAL(FTWL, test "$ftwl" != "no")
 AM_CONDITIONAL(FTWL_X11, test "$ftwl" = "x11")
 AM_CONDITIONAL(FTWL_SDL, test "$ftwl" = "sdl")
+AM_CONDITIONAL(MINGW32, test x"$MINGW32" = "xyes")
 
 dnl Checks for additional server libraries:
 if test x$server = xtrue; then
@@ -673,6 +674,7 @@
 	  common/aicore/Makefile
 	  ai/Makefile
 	  tests/Makefile
+  	  win32/Makefile
 	  client/Makefile
 	  client/agents/Makefile
 	  client/include/Makefile
Index: Makefile.am
===================================================================
--- Makefile.am	(revision 12328)
+++ Makefile.am	(working copy)
@@ -29,7 +29,7 @@
 endif
 
 
-SUBDIRS=	$(DSUBDIRS) intl utility common tests $(SSUBDIRS) $(CSUBDIRS) po doc $(MSUBDIRS)
+SUBDIRS=	$(DSUBDIRS) intl utility common tests win32 $(SSUBDIRS) $(CSUBDIRS) po doc $(MSUBDIRS)
 
 EXTRA_DIST=	acconfig.old			\
 		autogen.sh 			\
Index: server/Makefile.am
===================================================================
--- server/Makefile.am	(revision 12328)
+++ server/Makefile.am	(working copy)
@@ -9,6 +9,10 @@
 
 ## Above, note -I../intl instead of -I$(top_srdir/intl) is deliberate.
 
+if MINGW32
+SERVERICON=../win32/servericon.o
+endif
+
 civserver_SOURCES = \
 		civserver.c	\
 		civserver.h
@@ -91,5 +95,5 @@
       ../utility/libcivutility.a ../common/libcivcommon.a ../ai/libcivai.a \
       ../utility/libcivutility.a ./libcivserver.a ../utility/libcivutility.a \
       ../common/aicore/libaicore.a ./generator/libgenerator.a \
-      $(AUTH_LIBS) $(SERVER_LIBS)
+      $(AUTH_LIBS) $(SERVER_LIBS) $(SERVERICON)
 
Index: win32/clienticon.rc
===================================================================
--- win32/clienticon.rc	(revision 0)
+++ win32/clienticon.rc	(revision 0)
@@ -0,0 +1,3 @@
+#include <windows.h>
+
+client_icon ICON "client.ico"
Index: win32/Makefile.am
===================================================================
--- win32/Makefile.am	(revision 0)
+++ win32/Makefile.am	(revision 0)
@@ -0,0 +1,22 @@
+## Process this file with automake to produce Makefile.in
+
+dist_noinst_DATA = \
+		client.ico \
+		server.ico \
+		clienticon.rc \
+		servericon.rc
+
+if MINGW32
+nodist_noinst_DATA = \
+		clienticon.o \
+		servericon.o
+
+CLEANFILES = $(nodist_noinst_DATA)
+
+clienticon.o: clienticon.rc
+	windres -i clienticon.rc -o clienticon.o
+
+servericon.o: servericon.rc
+	windres -i servericon.rc -o servericon.o
+endif
+
Index: win32/servericon.rc
===================================================================
--- win32/servericon.rc	(revision 0)
+++ win32/servericon.rc	(revision 0)
@@ -0,0 +1,3 @@
+#include <windows.h>
+
+server_icon ICON "server.ico"
Index: client/Makefile.am
===================================================================
--- client/Makefile.am	(revision 12328)
+++ client/Makefile.am	(working copy)
@@ -33,6 +33,10 @@
 SDL_FILES=$(ALL_SDL_FILES)
 endif
 
+if MINGW32
+CLIENTICON=../win32/clienticon.o
+endif
+
 EXTRA_DIST= 	gui-mui/autogroupclass.c         \
 		gui-mui/autogroupclass.h         \
 		gui-mui/chatline.c               \
@@ -193,7 +197,7 @@
 		 	$(gui_sources)/libguiclient.a
 civclient_DEPENDENCIES = $(fc_civclient_libs)
 civclient_LDADD        = $(fc_civclient_libs) $(fc_civclient_libs) \
-	$(INTLLIBS) $(CLIENT_LIBS) $(SOUND_LIBS) $(LIB_GGZMOD)
+	$(INTLLIBS) $(CLIENT_LIBS) $(SOUND_LIBS) $(LIB_GGZMOD) $(CLIENTICON)
 desktopfiledir = $(prefix)/share/applications
 desktopfile_DATA = \
 	freeciv.desktop
Index: configure.ac
===================================================================
--- configure.ac	(revision 12328)
+++ configure.ac	(working copy)
@@ -488,6 +488,7 @@
 AM_CONDITIONAL(FTWL_X11, test "$ftwl" = "x11")
 AM_CONDITIONAL(FTWL_SDL, test "$ftwl" = "sdl")
 AM_CONDITIONAL(FTWL_OPENGL, test "$ftwl" = "opengl")
+AM_CONDITIONAL(MINGW32, test x"$MINGW32" = "xyes")
 
 dnl Checks for additional server libraries:
 if test x$server = xtrue; then
@@ -725,6 +726,7 @@
 	  common/aicore/Makefile
 	  ai/Makefile
 	  tests/Makefile
+  	  win32/Makefile
 	  client/Makefile
 	  client/agents/Makefile
 	  client/include/Makefile
Index: Makefile.am
===================================================================
--- Makefile.am	(revision 12328)
+++ Makefile.am	(working copy)
@@ -29,7 +29,7 @@
 endif
 
 
-SUBDIRS=	$(DSUBDIRS) intl utility common tests $(SSUBDIRS) $(CSUBDIRS) po doc $(MSUBDIRS)
+SUBDIRS=	$(DSUBDIRS) intl utility common tests win32 $(SSUBDIRS) $(CSUBDIRS) po doc $(MSUBDIRS)
 
 EXTRA_DIST=	autogen.sh 			\
 		config.mac.h			\
Index: server/Makefile.am
===================================================================
--- server/Makefile.am	(revision 12328)
+++ server/Makefile.am	(working copy)
@@ -12,6 +12,10 @@
 
 ## Above, note -I../intl instead of -I$(top_srdir/intl) is deliberate.
 
+if MINGW32
+SERVERICON=../win32/servericon.o
+endif
+
 civserver_SOURCES = \
 		civserver.c	\
 		civserver.h
@@ -102,7 +106,7 @@
       ../dependencies/lua/src/liblua.a \
       ../dependencies/lua/src/lib/liblualib.a \
       ../dependencies/tolua/libtolua.a \
-      $(AUTH_LIBS) $(SERVER_LIBS) $(LIB_GGZDMOD)
+      $(AUTH_LIBS) $(SERVER_LIBS) $(LIB_GGZDMOD) $(SERVERICON)
 
 
 
Index: win32/clienticon.rc
===================================================================
--- win32/clienticon.rc	(revision 0)
+++ win32/clienticon.rc	(revision 0)
@@ -0,0 +1,3 @@
+#include <windows.h>
+
+client_icon ICON "client.ico"
Index: win32/Makefile.am
===================================================================
--- win32/Makefile.am	(revision 0)
+++ win32/Makefile.am	(revision 0)
@@ -0,0 +1,22 @@
+## Process this file with automake to produce Makefile.in
+
+dist_noinst_DATA = \
+		client.ico \
+		server.ico \
+		clienticon.rc \
+		servericon.rc
+
+if MINGW32
+nodist_noinst_DATA = \
+		clienticon.o \
+		servericon.o
+
+CLEANFILES = $(nodist_noinst_DATA)
+
+clienticon.o: clienticon.rc
+	windres -i clienticon.rc -o clienticon.o
+
+servericon.o: servericon.rc
+	windres -i servericon.rc -o servericon.o
+endif
+
Index: win32/servericon.rc
===================================================================
--- win32/servericon.rc	(revision 0)
+++ win32/servericon.rc	(revision 0)
@@ -0,0 +1,3 @@
+#include <windows.h>
+
+server_icon ICON "server.ico"
_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to