Index: widelands-15/src/logic/widelands.h
===================================================================
--- widelands-15.orig/src/logic/widelands.h	2010-04-16 17:41:22.000000000 +0200
+++ widelands-15/src/logic/widelands.h	2010-05-10 18:25:33.000000000 +0200
@@ -79,6 +79,13 @@
 	{
 		assert(I < std::numeric_limits<value_t>::max());
 	}
+#if defined(__s390__)
+	explicit _Index(uintptr_t  const I)
+		: i(static_cast<value_t>(I))
+	{
+		assert(I < std::numeric_limits<value_t>::max());
+	}
+#endif
 
 	/// For compatibility with old code that use int32_t for building index
 	/// and use -1 to indicate invalidity.
@@ -117,6 +124,17 @@
 	value_t i;
 };
 
+#if defined(__s390__)                                                        
+#define DEFINE_INDEX(NAME)                                                    \
+   struct NAME : public _Index<NAME> {                                        \
+      NAME(NAME const & other = Null()) : _Index<NAME>(other) {}              \
+      explicit NAME(value_t const I) : _Index<NAME>(I) {}                     \
+      explicit NAME(size_t  const I) : _Index<NAME>(I) {}                     \
+      explicit NAME(int32_t const I) __attribute__((deprecated));             \
+      explicit NAME(uintptr_t  const I) : _Index<NAME>(I) {}                  \
+   };                                                                         \
+
+#else
 #define DEFINE_INDEX(NAME)                                                    \
    struct NAME : public _Index<NAME> {                                        \
       NAME(NAME const & other = Null()) : _Index<NAME>(other) {}              \
@@ -125,6 +143,8 @@
       explicit NAME(int32_t const I) __attribute__((deprecated));             \
    };                                                                         \
 
+#endif
+
 DEFINE_INDEX(Building_Index)
 DEFINE_INDEX(Ware_Index)
 
