Then changed to the toolshed-code directory and did :
make -C build/unix 2>&1 | tee mk.out
To capture the output of the make. The make fails with warnings in
several places. I also tried with CC=gcc, but that did not make a differnce.
Problem 1:
Several build errors of this type (array subscript has type ‘char’):
In file included from ../../../include/util.h:18,
from ../../../os9/os9dir.c:6:
../../../os9/os9dir.c: In function ‘do_dir’:
../../../os9/os9dir.c:270:61: error: array subscript has type ‘char’ [-Werror=char-subscripts]
270 | if (isprint(filename[i]))
| ~~~~~~~~^~~
cc1: all warnings being treated as errors
make[1]: *** [<builtin>: os9dir.o]</builtin> Error 1
Oddly I don't get the errors on Ubuntu 22.04, which is odd as they are
both using the same version of gcc
Hi all,
I've tried this under both cygwin and under Ubuntu 20.04 running on wsl,
and then with native Ubuntu 22.04.
These problems only seem to manifest compiling unger cygwin.
So I checked out the current code with :
hg clone http://hg.code.sf.net/p/toolshed/code toolshed-code
Then changed to the toolshed-code directory and did :
make -C build/unix 2>&1 | tee mk.out
To capture the output of the make. The make fails with warnings in
several places. I also tried with CC=gcc, but that did not make a differnce.
Problem 1:
Several build errors of this type (array subscript has type ‘char’):
In file included from ../../../include/util.h:18,
from ../../../os9/os9dir.c:6:
../../../os9/os9dir.c: In function ‘do_dir’:
../../../os9/os9dir.c:270:61: error: array subscript has type ‘char’
[-Werror=char-subscripts]
270 | if (isprint(filename[i]))
| ~~~~~~~~^~~
cc1: all warnings being treated as errors
make[1]: *** [<builtin>: os9dir.o]</builtin> Error 1
Oddly I don't get the errors on Ubuntu 22.04, which is odd as they are
both using the same version of gcc
Cygwin:
$ gcc --version
gcc (GCC) 11.2.0
Copyright (C) 2021 Free Software Foundation, Inc.
Ubuntu 22.04:
phill@htpc:~$ gcc --version
gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0
Copyright (C) 2021 Free Software Foundation, Inc.
Problem 2:
This is an easy fix
in makewav/makewav.c
the line :
if defined(CYGWIN32) || defined(linux) || defined(WIN32)
needs changing to :
if defined(CYGWIN32) || defined(CYGWIN) || defined(linux)
|| defined(WIN32)
Cheers.
Phill.
--
Phill Harvey-Smith, Programmer, Hardware hacker, and general eccentric !
"You can twist perceptions, but reality won't budge" -- Rush.
Oh this post was stuck in the moderation queue. These issues are also discussed in https://sourceforge.net/p/toolshed/discussion/22367
I think __CYGWIN__ is also defined on 32-bit Cygwin, so that one is enough.
Last edit: Tormod Volden 2023-03-05