Hey there, I know it's a neat game. Hope you can help.
$ make
Making all in FeLib
make[1]: Entering directory `/home/qubodup/ivan-0.50/FeLib'
Making all in Source
make[2]: Entering directory `/home/qubodup/ivan-0.50/FeLib/Source'
g++ -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"ivan\" -DVERSION=\"0.50\" -I. -I. -I../../FeLib/Include -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT -DLINUX -DLOCAL_STATE_DIR=\"/usr/local/var/ivan\" -DDATADIR=\"/usr/local/share\" -DUSE_SDL -DGCC -g -O2 -c bitmap.cpp
../../FeLib/Include/fearray.h:37: error: invalid use of constructor as a template
../../FeLib/Include/fearray.h:37: note: use ‘fearray<type>::fearray’ instead of ‘fearray<type>::struct fearray<type>’ to name the constructor in a qualified name
../../FeLib/Include/fearray.h:45: error: invalid use of constructor as a template
../../FeLib/Include/fearray.h:45: note: use ‘fearray<type>::fearray’ instead of ‘fearray<type>::struct fearray<type>’ to name the constructor in a qualified name
make[2]: *** [bitmap.o] Error 1
make[2]: Leaving directory `/home/qubodup/ivan-0.50/FeLib/Source'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/qubodup/ivan-0.50/FeLib'
make: *** [all-recursive] Error 1
Logged In: YES
user_id=2025949
Originator: NO
The problem is that IVAN's source code uses a G++3.x-only syntax for constructors in templates. The following patch does the trick:
To run the patch:
$ tar xzf ivan-0.50.tgz
$ patch -p0 ivan-0.50_gcc-4.3.2.patch
patching file ivan-0.50/FeLib/Include/fearray.h
patching file ivan-0.50/Main/Source/script.cpp
$ cd ivan-0.50/
... # make as normal
Contents of ivan-0.50_gcc-4.3.2.patch:
diff -Naur ivan-0.50/FeLib/Include/fearray.h ivan-0.50p1/FeLib/Include/fearray.h
--- ivan-0.50/FeLib/Include/fearray.h 2004-10-26 15:35:44.000000000 -0400
+++ ivan-0.50p1/FeLib/Include/fearray.h 2008-08-12 11:59:55.000000000 -0400
@@ -34,7 +34,7 @@
};
{
if(Data)
@@ -42,7 +42,7 @@
}
{
char* Ptr = new char[Size * sizeof(type) + sizeof(ulong)];
diff -Naur ivan-0.50/Main/Source/script.cpp ivan-0.50p1/Main/Source/script.cpp
--- ivan-0.50/Main/Source/script.cpp 2004-10-26 15:37:05.000000000 -0400
+++ ivan-0.50p1/Main/Source/script.cpp 2008-08-12 12:00:14.000000000 -0400
@@ -471,7 +471,7 @@
INIT_ENTRY(Flags);
}
INIT(Flags, 0)
{ }
@@ -498,7 +498,7 @@
return Instance;
}
INIT(MinPrice, 0),
INIT(MaxPrice, MAX_PRICE),
@@ -592,7 +592,7 @@
INIT_ENTRY(IsInside);
}
INIT(AttachedArea, DEFAULT_ATTACHED_AREA),
INIT(AttachedEntry, DEFAULT_ATTACHED_ENTRY)
@@ -679,7 +679,7 @@
}
}
-template <class type, class contenttype> contentmap<type, contenttype>::contentmap<type, contenttype>() : ContentMap(0) { }
+template <class type, class contenttype> contentmap<type, contenttype>::contentmap() : ContentMap(0) { }
template <class type, class contenttype> contentmap<type, contenttype>::~contentmap<type, contenttype>()
{
Please read!
./../FeLib/Include/fearray.h:37: note: use ‘fearray<type>::fearray’
instead of ‘fearray<type>::struct fearray<type>’ to name the
constructor in a qualified name
so you have to remove <type> from line 37 and write:
fearray<type>::fearray(