Subject: pkg/23359: gforth emits MS-DOS style characters in "CR" word
To: None <>
From: None <>
List: netbsd-bugs
Date: 11/03/2003 18:52:10
>Number:         23359
>Category:       pkg
>Synopsis:       gforth emits MS-DOS style characters in "CR" word
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Nov 03 17:53:00 UTC 2003
>Originator:     Jorge Acereda
>Release:        NetBSD 1.6.1
System: NetBSD 1.6.1 NetBSD 1.6.1 (GENERIC) #0: Tue Apr 8 12:05:52 UTC 2003 i386
Architecture: i386
Machine: i386

	gforth checks in the sources the "unix" preprocessor symbol to
	determine which type of carriage return codes should emit. As the
	symbol is undefined, it compiles the wrong code, and it can lead
	to errors in scripts using gforth.

	cd /usr/pkgsrc/lang/gforth && make install
	gforth -e "cr bye" | wc -c

	The number of characters emitted by the "cr" word should be 1.


	The following patch fixes the problem using the ugly way. 

cvs server: Diffing .
Index: Makefile
RCS file: /cvsroot/pkgsrc/lang/gforth/Makefile,v
retrieving revision 1.14
diff -r1.14 Makefile
> CFLAGS+= -Dunix