[racket-dev] Compile issue in src/racket/gc2/sighand.c

2012-07-20 Thread crdueck

Hello all,

Recently, I tried to compile the unix source for racket-textual found 
here: 
http://download.racket-lang.org/racket-textual-5-2-1-src-unix-tgz.html 
using GCC 4.7.1 and kernel Linux 3.4.4-3 x86_64.


cd src  ./configure=/opt  make returned the following errors:

In file included from ./newgc.c:2436:0,
from ./gc2.c:15:
./sighand.c:63:35: warning: ‘struct siginfo’ declared inside parameter 
list [enabled by default]
./sighand.c:63:35: warning: its scope is only this definition or 
declaration, which is probably not what you want [enabled by default]

./sighand.c: In function ‘fault_handler’:
./sighand.c:65:15: error: dereferencing pointer to incomplete type
./sighand.c:67:13: error: dereferencing pointer to incomplete type
./sighand.c:71:9: error: dereferencing pointer to incomplete type
./sighand.c:87:46: error: dereferencing pointer to incomplete type
./sighand.c:87:74: error: dereferencing pointer to incomplete type
./sighand.c:103:11: error: dereferencing pointer to incomplete type
In file included from ./newgc.c:2436:0,
from ./gc2.c:15:
./sighand.c: In function ‘initialize_signal_handler’:
./sighand.c:227:42: warning: assignment from incompatible pointer type 
[enabled by default]

make[4]: *** [gc2.o] Error 1

i opened src/racket/gc2/sighand.c and looked at the offending line 63, 
where struct siginfo doesnt seem to be an actual struct. Scrolling down 
a bit more to line 131, i see that siginfo_t is a valid typedef so on 
line 63 i did s/struct siginfo/siginfo_t/ and the syntax errors 
disappeared.


make  sudo make install then ran fine and I used the racket executable 
to run a .rkt source file with no problems.


seems like a typedef might have been changed somewhere along the road?
_
 Racket Developers list:
 http://lists.racket-lang.org/dev


Re: [racket-dev] Compile issue in src/racket/gc2/sighand.c

2012-07-20 Thread Eli Barzilay
10 minutes ago, crdueck wrote:
 
 i opened src/racket/gc2/sighand.c and looked at the offending line
 63, where struct siginfo doesnt seem to be an actual
 struct. Scrolling down a bit more to line 131, i see that siginfo_t
 is a valid typedef so on line 63 i did s/struct siginfo/siginfo_t/
 and the syntax errors disappeared.

This looks like it confirms this fix:

  http://sourceware.org/ml/libc-alpha/2012-03/msg00414.html

-- 
  ((lambda (x) (x x)) (lambda (x) (x x)))  Eli Barzilay:
http://barzilay.org/   Maze is Life!
_
  Racket Developers list:
  http://lists.racket-lang.org/dev