Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to compile 'asmrun/signals_asm.c'. #6772

Closed
vicuna opened this issue Feb 5, 2015 · 2 comments

Comments

Projects
None yet
2 participants
@vicuna
Copy link

commented Feb 5, 2015

Original bug ID: 6772
Reporter: pocarist
Assigned to: @mshinwell
Status: closed (set by @xavierleroy on 2016-12-07T10:49:13Z)
Resolution: fixed
Priority: normal
Severity: major
Platform: i386
OS: NetBSD/i386
OS Version: 6.1.4
Version: 4.02.0
Target version: 4.02.2+dev / +rc1
Fixed in version: 4.02.2+dev / +rc1
Category: configure and build/install
Tags: patch
Monitored by: @gasche

Bug description

I can not compile 'asmrun/signals_asm.c' on NetBSD/i386 from version 4.02.

Direct cause is that is not in the NetBSD definition of sigcontext by configure target has been added that SYS_bsd_elf.
Therefore, it was changed to use the ucontext in the POSIX standard instead of sigcontext.

So, I'll send to bug report and fix patch.

Steps to reproduce

% gmake [~/src/ocaml/ocaml-4.02.1_fix/asmrun]
gcc -I../byterun -DCAML_NAME_SPACE -DNATIVE_CODE -DTARGET_i386 -DSYS_bsd_elf -O -Wall -D_FILE_OFFSET_BITS=64 -D_REENTRANT -c -o signals_asm.o signals_asm.c
signals_asm.c:75:1: warning: 'struct sigcontext' declared inside parameter list
signals_asm.c:75:1: warning: its scope is only this definition or declaration, which is probably not what you want
signals_asm.c:195:1: warning: 'struct sigcontext' declared inside parameter list
signals_asm.c: In function 'segv_handler':
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
signals_asm.c:211:10: error: dereferencing pointer to incomplete type
gmake: *** [signals_asm.o] Error 1

Additional information

Fix patch

(Gist) https://gist.github.com/pocarist/96aa47c4529131392355

File attachments

@vicuna

This comment has been minimized.

Copy link
Author

commented Feb 5, 2015

Comment author: @mshinwell

I investigated this a little. I think the patch is reasonable and correct. I will merge it unless anyone objects soon.

@vicuna

This comment has been minimized.

Copy link
Author

commented May 6, 2015

Comment author: @mshinwell

Committed to 4.02

@vicuna vicuna closed this Dec 7, 2016

@vicuna vicuna added this to the 4.02.2 milestone Mar 14, 2019

@vicuna vicuna added the bug label Mar 20, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.