Building SpamAssassin for Cygwin

Jason Tishler jason@tishler.net
Fri Sep 20 06:32:00 GMT 2002


On Thu, Sep 19, 2002 at 06:59:06PM +0200, news@garydjones.mailshell.com wrote:
> make -f binaries.mk spamd/spamc
> make[1]: Entering directory /home/eye/develop/Mail-SpamAssassin-2.41'
> gcc -g -O2 spamd/spamc.c spamd/libspamc.c spamd/utils.c \
>         -o spamd/spamc  
> make[1]: Leaving directory /home/eye/develop/Mail-SpamAssassin-2.41'
> cp spamd/spamc blib/script/spamc
> /usr/bin/perl -I/usr/lib/perl5/5.6.1/cygwin-multi -I/usr/lib/perl5/5.6.1
> -MExtUtils::MakeMaker -e "MY->fixin(shift)" blib/script/spamc
> Can't process 'blib/script/spamc': No such file or directory at -e line 1
> make: *** [blib/script/spamc] Error 255

I got the exact same error when building 2.31.

> What I think is happening is that the .exe suffix is being added to the
> binary (I'm assuming this is one of the executable files), but something
> then can't find the executable file as a result. The /usr/bin/perl line,
> correct? Can anyone who has got it working give me a few clues please?

I "fixed" problem with the (first hunk of the) first patch.  Since I'm
not a Perl person, I haven't figured out the right way to fix the
problem -- for example, patching Makefile.PL or whatever generates the
offending line in Makefile.  Does anyone know the right way to do this?

BTW, I needed the second patch to stop spamassassin from thinking that
Perl was running under Windows instead of Cygwin.

Jason
-------------- next part --------------
--- Makefile.orig	2002-08-29 08:39:39.000000000 -0400
+++ Makefile	2002-08-29 08:51:21.000000000 -0400
@@ -524,8 +524,8 @@ realclean ::
 $(INST_SCRIPT)/spamc: spamd/spamc Makefile $(INST_SCRIPT)/.exists
 	@rm -f $(INST_SCRIPT)/spamc
 	cp spamd/spamc $(INST_SCRIPT)/spamc
-	$(FIXIN) $(INST_SCRIPT)/spamc
-	-@$(CHMOD) $(PERM_RWX) $(INST_SCRIPT)/spamc
+	$(FIXIN) $(INST_SCRIPT)/spamc$(EXE_EXT)
+	-@$(CHMOD) $(PERM_RWX) $(INST_SCRIPT)/spamc$(EXE_EXT)
 
 $(INST_SCRIPT)/spamd: spamd/spamd Makefile $(INST_SCRIPT)/.exists
 	@rm -f $(INST_SCRIPT)/spamd
@@ -850,7 +850,7 @@ CFLIBS		= -lgdbm -lcrypt
 CFLDFLAGS	=  -s -L/usr/local/lib
 
 DEF_RULES_DIR	= $(PREFIX)/share/spamassassin
-LOCAL_RULES_DIR	= /etc/mail/spamassassin
+LOCAL_RULES_DIR	= $(SYSCONFDIR)/mail/spamassassin
 
 
 
-------------- next part --------------
--- spamassassin.raw.orig	2002-08-29 10:53:34.000000000 -0400
+++ spamassassin.raw	2002-08-29 10:53:45.000000000 -0400
@@ -19,7 +19,7 @@ BEGIN {
 
   if ($^O eq 'MacOS') {
     $slash = ':'; $dirtrailer = ':';
-  } elsif ($^O =~ /(win|os2)/) {
+  } elsif ($^O =~ /(win|os2)/ && $^O ne 'cygwin') {
     $slash = '\\';
   }
 

-------------- next part --------------
--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


More information about the Cygwin mailing list