Start a fresh cygwin installation from http://www.cygwin.com/ Choose install everything. Grab the source from cvs.
#cat /proc/version
CYGWIN_NT-5.1 1.5.7(0.109/3/2) 2004-01-30 19:32
#export CVS_RSH="ssh"
#cvs -z3 -d:ext:address@hidden:/cvsroot/gift co gift
#./bootstrap-cvs.sh
#./configure
This error message was generated at gift-check-perl-config.pl line 43.
configure: error: There are some modules missing from your perl configuration. Please see the output above.
perl -MCPAN -e 'install XML::DOM'
perl -MCPAN -e 'install XML::Parser'
perl -MCPAN -e 'install Text::Iconv'
perl -MCPAN -e 'install XML::XQL::DOM'
perl -MCPAN -e 'install XML::XQL'
perl -MCPAN -e 'install XML::Writer'
If there is some error on testing and cannot do success instal, try:
#cd ~/.cpan/build/
In each directory, do the following command:
#perl Makefile.PL
#make
#make install
The following url is to solve iconv compile problem under cygwin.
http://www.cygwin.com/ml/cygwin/2002-08/msg01384.html
do ./configure again.
config.status: linking ./lib/gnugetopt.h to lib/getopt.h
config.status: error: ./lib/gnugetopt.h: file not found
comment out " ac_config_links="$ac_config_links lib/getopt.h:lib/gnugetopt.h " in configure
Finally, the ./configure finish without any error.
Let's go to make.
#make
g++ -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -o libMRML-config.exe libMRML-config.o -ldl /usr/lib/libexpat.dll.a
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.1/../../../../i686-pc-cygwin/bin/ld: cannot find -ldl
collect2: ld returned 1 exit status
MAKE[3]: *** [libMRML-config.exe] Error 1
MAKE[3]: Leaving directory `/home/s7n/gift/libMRML/cc'
MAKE[2]: *** [all-recursive] Error 1
MAKE[2]: Leaving directory `/home/s7n/gift/libMRML'
MAKE[1]: *** [all-recursive] Error 1
MAKE[1]: Leaving directory `/home/s7n/gift'
MAKE: *** [all] Error 2
It claims that cannot find ldl, which means the /lib/libdl.a is missing.
According to the following URL:
http://www.cygwin.com/ml/cygwin/2003-07/msg00731.html
So we just create a link to libdl.a to libcygwin.a
#cd /lib ; ln -s libcygwin.a libdl.a
Go make again!
#make
make[3]: Entering directory `/home/s7n/gift/libGIFTAcInvertedFile/cc'
if /bin/bash ../../libtool --mode=compile g++ -DHAVE_CONFIG_H -I. -I. -I../.. -DHAS_BOOL -I../../libMRML/include -I../../libGIFTAcInvertedFile/include -II../../libGIFTAcURL2FTS/include -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -MT CAcIFFileSystem.lo -MD -MP -MF ".deps/CAcIFFileSystem.Tpo" \
-c -o CAcIFFileSystem.lo `test -f 'CAcIFFileSystem.cc' || echo './'`CAcIFFileSystem.cc; \
then mv -f ".deps/CAcIFFileSystem.Tpo" ".deps/CAcIFFileSystem.Plo"; \
else rm -f ".deps/CAcIFFileSystem.Tpo"; exit 1; \
fi
rm -f .libs/CAcIFFileSystem.lo
g++ -DHAVE_CONFIG_H -I. -I. -I../.. -DHAS_BOOL -I../../libMRML/include -I../../libGIFTAcInvertedFile/include -I../../libGIFTAcURL2FTS/include -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -MT CAcIFFileSystem.lo -MD -MP -MF .deps/CAcIFFileSystem.Tpo -c CAcIFFileSystem.cc -DPIC -DPIC -o CAcIFFileSystem.o
../../libGIFTAcInvertedFile/include/merge_sort_streams.h: In function `char*
merge_sort_streams(const char*, const char*, int) [with T =
CIFBuilderTriplet]':
CAcIFFileSystem.cc:557: instantiated from here
../../libGIFTAcInvertedFile/include/merge_sort_streams.h:361: error: `assert'
undeclared (first use this function)
../../libGIFTAcInvertedFile/include/merge_sort_streams.h:361: error: (Each
undeclared identifier is reported only once for each function it appears
in.)
../../libGIFTAcInvertedFile/include/merge_sort_streams.h: In function `void
merge_streams(std::istream&, CStreamPos<std::streampos>, std::istream&,
CStreamPos<std::streampos>, std::ostream&, int) [with T = CIFBuilderTriplet]
':
../../libGIFTAcInvertedFile/include/merge_sort_streams.h:396: instantiated from `char* merge_sort_streams(const char*, const char*, int) [with T = CIFBuilderTriplet]'
CAcIFFileSystem.cc:557: instantiated from here
../../libGIFTAcInvertedFile/include/merge_sort_streams.h:127: error: `assert'
undeclared (first use this function)
make[3]: *** [CAcIFFileSystem.lo] Error 1
make[3]: Leaving directory `/home/s7n/gift/libGIFTAcInvertedFile/cc'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/s7n/gift/libGIFTAcInvertedFile'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/s7n/gift'
make: *** [all] Error 2
Error again!
#cd libGIFTAcInvertedFile/cc
#vi CAcIFFileSystem.cc
Add one line in the include area.
#include <assert.h>
#make
Will produce lots of MySQL error.
#vi Makefile
Remove anything releated MySQL
#make
#cd libSquirePPM
ppm_normalize.c:5:20: values.h: No such file or directory
make: *** [ppm_normalize.o] Error 1
So we copy values.h from a linux box. /usr/include/values.h
The the compile is ok.
#cd GIFTServer
make[1]: Entering directory `/home/s7n/gift/GIFTServer'
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I../libMRML/include -I../libGIFTAcInvertedFile/include -I../libGIFTAcURL2FTS/include -I. -I. -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -MT CDomainSocket.o -MD -MP -MF ".deps/CDomainSocket.Tpo" \
-c -o CDomainSocket.o `test -f 'CDomainSocket.cc' || echo './'`CDomainSocket.cc; \
then mv -f ".deps/CDomainSocket.Tpo" ".deps/CDomainSocket.Po"; \
else rm -f ".deps/CDomainSocket.Tpo"; exit 1; \
fi
CDomainSocket.cc: In member function `virtual bool
CDomainSocket::acceptAndServe()':
CDomainSocket.cc:93: error: invalid conversion from `unsigned int*' to `int*'
CDomainSocket.cc:98: error: aggregate `ucred lCredentials' has incomplete type
and cannot be defined
CDomainSocket.cc:102: error: `SO_PEERCRED' undeclared (first use this function)
CDomainSocket.cc:102: error: (Each undeclared identifier is reported only once
for each function it appears in.)
make[1]: *** [CDomainSocket.o] Error 1
make[1]: Leaving directory `/home/s7n/gift/GIFTServer'
make: *** [all-recursive] Error 1
Edit Makefile, modify the following lines, take out all releated to CDomainSocket
gift_SOURCES = Server.cc CSocket.cc CDomainSocket.cc CTCPSocket.cc processMessage.cc CProcessMessageParameters.cc CMultiServer.cc
noinst_HEADERS = CSocket.h CDomainSocket.h CTCPSocket.h CMultiServer.h processMessage.h CProcessMessageParameters.h
am_gift_OBJECTS = Server.$(OBJEXT) CSocket.$(OBJEXT) \
CDomainSocket.$(OBJEXT) CTCPSocket.$(OBJEXT) \
processMessage.$(OBJEXT) CProcessMessageParameters.$(OBJEXT) \
CMultiServer.$(OBJEXT)
DEP_FILES = ./$(DEPDIR)/CDomainSocket.Po \
include ./$(DEPDIR)/CDomainSocket.Po
# make
make[1]: Entering directory `/home/s7n/gift/GIFTServer'
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I../libMRML/include -I../libGIFTAcInvertedFile/include -I../libGIFTAcURL2FTS/include -I. -I. -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -MT CTCPSocket.o -MD -MP -MF ".deps/CTCPSocket.Tpo" \
-c -o CTCPSocket.o `test -f 'CTCPSocket.cc' || echo './'`CTCPSocket.cc; \
then mv -f ".deps/CTCPSocket.Tpo" ".deps/CTCPSocket.Po"; \
else rm -f ".deps/CTCPSocket.Tpo"; exit 1; \
fi
CTCPSocket.cc: In member function `virtual bool CTCPSocket::acceptAndServe()':
CTCPSocket.cc:96: error: invalid conversion from `unsigned int*' to `int*'
make[1]: *** [CTCPSocket.o] Error 1
make[1]: Leaving directory `/home/s7n/gift/GIFTServer'
make: *** [all-recursive] Error 1
#vi CTCPSocket.cc
In line 94, change
unsigned int lSize = sizeof(lAcceptedSocket);
into
int lSize = sizeof(lAcceptedSocket);
#make
if g++ -DHAVE_CONFIG_H -I. -I. -I.. -I../libMRML/include -I../libGIFTAcInvertedFile/include -I../libGIFTAcURL2FTS/include -I. -I. -g -O2 -DEF_PROTECT_BELOW=1 -DEF_PROTECT_FREE -DEF_PROTECT_ALIGNMENT=8 -DEF_FILL=42 -MT processMessage.o -MD -MP -MF ".deps/processMessage.Tpo" \
-c -o processMessage.o `test -f 'processMessage.cc' || echo './'`processMessage.cc; \
then mv -f ".deps/processMessage.Tpo" ".deps/processMessage.Po"; \
else rm -f ".deps/processMessage.Tpo"; exit 1; \
fi
processMessage.cc: In function `void* processMessage(void*)':
processMessage.cc:72: error: `MSG_WAITALL' undeclared (first use this function)
processMessage.cc:72: error: (Each undeclared identifier is reported only once
for each function it appears in.)
make[1]: *** [processMessage.o] Error 1
make[1]: Leaving directory `/home/s7n/gift/GIFTServer'
make: *** [all-recursive] Error 1
#vi processMessage.cc
In line 72, change
while(recv(lParameters->mSocket,&lBuf,1,MSG_WAITALL)>0){
into
while(recv(lParameters->mSocket,&lBuf,1,1)>0){
#vi modifyDistanceMatrix.cc
Add one line in the include area.
#include <assert.h>
#make
#make install
# gift-add-collection.pl --help
Parameterless "use IO" deprecated at /usr/lib/perl5/site_perl/5.8.2/XML/Writer.pm line 16
Can't exec "locale": No such file or directory at /usr/local/bin/gift-add-collection.pl line 664.
No such file or directory at /usr/local/bin/gift-add-collection.pl line 664.
vi /usr/local/bin/gift-add-collection.pl
Comment out
open LOCALELIST, "locale -m |" or die "$!";
open LOCALELIST, "locale LC_MONETARY |" or die "$!";
#gift-add-collection.pl /image/path
#gift
Fiannly make gift running under windows on top of cygwin!
|