Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
relibc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
redox-os
relibc
Commits
cfe98ab3
Commit
cfe98ab3
authored
7 years ago
by
Jeremy Soller
Browse files
Options
Downloads
Patches
Plain Diff
Fix constants in signal.h
parent
d6e210b1
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/signal/src/lib.rs
+172
-6
172 additions, 6 deletions
src/signal/src/lib.rs
src/signal/src/linux.rs
+0
-48
0 additions, 48 deletions
src/signal/src/linux.rs
src/signal/src/redox.rs
+0
-44
0 additions, 44 deletions
src/signal/src/redox.rs
with
172 additions
and
98 deletions
src/signal/src/lib.rs
+
172
−
6
View file @
cfe98ab3
...
...
@@ -4,17 +4,183 @@
extern
crate
platform
;
use
platform
::
types
::
*
;
#[cfg(target_os
=
"linux"
)]
#[path
=
"linux.rs"
]
pub
mod
sys
;
#[repr(C)]
pub
struct
sigset_t
{
pub
bits
:
[
u64
;
16
],
}
#[cfg(target_os
=
"linux"
)]
pub
const
SIGHUP
:
usize
=
1
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGINT
:
usize
=
2
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGQUIT
:
usize
=
3
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGILL
:
usize
=
4
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGTRAP
:
usize
=
5
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGABRT
:
usize
=
6
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGIOT
:
usize
=
SIGABRT
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGBUS
:
usize
=
7
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGFPE
:
usize
=
8
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGKILL
:
usize
=
9
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGUSR1
:
usize
=
10
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGSEGV
:
usize
=
11
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGUSR2
:
usize
=
12
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGPIPE
:
usize
=
13
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGALRM
:
usize
=
14
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGTERM
:
usize
=
15
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGSTKFLT
:
usize
=
16
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGCHLD
:
usize
=
17
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGCONT
:
usize
=
18
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGSTOP
:
usize
=
19
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGTSTP
:
usize
=
20
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGTTIN
:
usize
=
21
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGTTOU
:
usize
=
22
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGURG
:
usize
=
23
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGXCPU
:
usize
=
24
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGXFSZ
:
usize
=
25
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGVTALRM
:
usize
=
26
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGPROF
:
usize
=
27
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGWINCH
:
usize
=
28
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGIO
:
usize
=
29
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGPOLL
:
usize
=
29
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGPWR
:
usize
=
30
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGSYS
:
usize
=
31
;
#[cfg(target_os
=
"linux"
)]
pub
const
SIGUNUSED
:
usize
=
SIGSYS
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_NOCLDSTOP
:
usize
=
1
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_NOCLDWAIT
:
usize
=
2
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_SIGINFO
:
usize
=
4
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_ONSTACK
:
usize
=
0x08000000
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_RESTART
:
usize
=
0x10000000
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_NODEFER
:
usize
=
0x40000000
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_RESETHAND
:
usize
=
0x80000000
;
#[cfg(target_os
=
"linux"
)]
pub
const
SA_RESTORER
:
usize
=
0x04000000
;
#[cfg(target_os
=
"redox"
)]
#[path
=
"redox.rs"
]
pub
mod
sys
;
#[repr(C)]
pub
struct
sigset_t
{
pub
bits
:
[
u64
;
2
],
}
pub
use
sys
::
*
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGHUP
:
usize
=
1
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGINT
:
usize
=
2
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGQUIT
:
usize
=
3
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGILL
:
usize
=
4
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGTRAP
:
usize
=
5
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGBUS
:
usize
=
7
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGFPE
:
usize
=
8
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGKILL
:
usize
=
9
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGUSR1
:
usize
=
10
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGSEGV
:
usize
=
11
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGUSR2
:
usize
=
12
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGPIPE
:
usize
=
13
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGALRM
:
usize
=
14
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGTERM
:
usize
=
15
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGSTKFLT
:
usize
=
16
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGCHLD
:
usize
=
17
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGCONT
:
usize
=
18
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGSTOP
:
usize
=
19
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGTSTP
:
usize
=
20
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGTTIN
:
usize
=
21
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGTTOU
:
usize
=
22
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGURG
:
usize
=
23
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGXCPU
:
usize
=
24
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGXFSZ
:
usize
=
25
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGVTALRM
:
usize
=
26
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGPROF
:
usize
=
27
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGWINCH
:
usize
=
28
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGIO
:
usize
=
29
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGPWR
:
usize
=
30
;
#[cfg(target_os
=
"redox"
)]
pub
const
SIGSYS
:
usize
=
31
;
use
platform
::
types
::
*
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_NOCLDSTOP
:
usize
=
0x00000001
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_NOCLDWAIT
:
usize
=
0x00000002
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_SIGINFO
:
usize
=
0x00000004
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_RESTORER
:
usize
=
0x04000000
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_ONSTACK
:
usize
=
0x08000000
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_RESTART
:
usize
=
0x10000000
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_NODEFER
:
usize
=
0x40000000
;
#[cfg(target_os
=
"redox"
)]
pub
const
SA_RESETHAND
:
usize
=
0x80000000
;
#[repr(C)]
pub
struct
sigaction
{
...
...
This diff is collapsed.
Click to expand it.
src/signal/src/linux.rs
deleted
100644 → 0
+
0
−
48
View file @
d6e210b1
#[repr(C)]
pub
struct
sigset_t
{
pub
bits
:
[
u64
;
16
],
}
pub
const
SIGHUP
:
usize
=
1
;
pub
const
SIGINT
:
usize
=
2
;
pub
const
SIGQUIT
:
usize
=
3
;
pub
const
SIGILL
:
usize
=
4
;
pub
const
SIGTRAP
:
usize
=
5
;
pub
const
SIGABRT
:
usize
=
6
;
pub
const
SIGIOT
:
usize
=
SIGABRT
;
pub
const
SIGBUS
:
usize
=
7
;
pub
const
SIGFPE
:
usize
=
8
;
pub
const
SIGKILL
:
usize
=
9
;
pub
const
SIGUSR1
:
usize
=
10
;
pub
const
SIGSEGV
:
usize
=
11
;
pub
const
SIGUSR2
:
usize
=
12
;
pub
const
SIGPIPE
:
usize
=
13
;
pub
const
SIGALRM
:
usize
=
14
;
pub
const
SIGTERM
:
usize
=
15
;
pub
const
SIGSTKFLT
:
usize
=
16
;
pub
const
SIGCHLD
:
usize
=
17
;
pub
const
SIGCONT
:
usize
=
18
;
pub
const
SIGSTOP
:
usize
=
19
;
pub
const
SIGTSTP
:
usize
=
20
;
pub
const
SIGTTIN
:
usize
=
21
;
pub
const
SIGTTOU
:
usize
=
22
;
pub
const
SIGURG
:
usize
=
23
;
pub
const
SIGXCPU
:
usize
=
24
;
pub
const
SIGXFSZ
:
usize
=
25
;
pub
const
SIGVTALRM
:
usize
=
26
;
pub
const
SIGPROF
:
usize
=
27
;
pub
const
SIGWINCH
:
usize
=
28
;
pub
const
SIGIO
:
usize
=
29
;
pub
const
SIGPOLL
:
usize
=
29
;
pub
const
SIGPWR
:
usize
=
30
;
pub
const
SIGSYS
:
usize
=
31
;
pub
const
SIGUNUSED
:
usize
=
SIGSYS
;
pub
const
SA_NOCLDSTOP
:
usize
=
1
;
pub
const
SA_NOCLDWAIT
:
usize
=
2
;
pub
const
SA_SIGINFO
:
usize
=
4
;
pub
const
SA_ONSTACK
:
usize
=
0x08000000
;
pub
const
SA_RESTART
:
usize
=
0x10000000
;
pub
const
SA_NODEFER
:
usize
=
0x40000000
;
pub
const
SA_RESETHAND
:
usize
=
0x80000000
;
pub
const
SA_RESTORER
:
usize
=
0x04000000
;
This diff is collapsed.
Click to expand it.
src/signal/src/redox.rs
deleted
100644 → 0
+
0
−
44
View file @
d6e210b1
#[repr(C)]
pub
struct
sigset_t
{
pub
bits
:
[
u64
;
2
],
}
pub
const
SIGHUP
:
usize
=
1
;
pub
const
SIGINT
:
usize
=
2
;
pub
const
SIGQUIT
:
usize
=
3
;
pub
const
SIGILL
:
usize
=
4
;
pub
const
SIGTRAP
:
usize
=
5
;
pub
const
SIGBUS
:
usize
=
7
;
pub
const
SIGFPE
:
usize
=
8
;
pub
const
SIGKILL
:
usize
=
9
;
pub
const
SIGUSR1
:
usize
=
10
;
pub
const
SIGSEGV
:
usize
=
11
;
pub
const
SIGUSR2
:
usize
=
12
;
pub
const
SIGPIPE
:
usize
=
13
;
pub
const
SIGALRM
:
usize
=
14
;
pub
const
SIGTERM
:
usize
=
15
;
pub
const
SIGSTKFLT
:
usize
=
16
;
pub
const
SIGCHLD
:
usize
=
17
;
pub
const
SIGCONT
:
usize
=
18
;
pub
const
SIGSTOP
:
usize
=
19
;
pub
const
SIGTSTP
:
usize
=
20
;
pub
const
SIGTTIN
:
usize
=
21
;
pub
const
SIGTTOU
:
usize
=
22
;
pub
const
SIGURG
:
usize
=
23
;
pub
const
SIGXCPU
:
usize
=
24
;
pub
const
SIGXFSZ
:
usize
=
25
;
pub
const
SIGVTALRM
:
usize
=
26
;
pub
const
SIGPROF
:
usize
=
27
;
pub
const
SIGWINCH
:
usize
=
28
;
pub
const
SIGIO
:
usize
=
29
;
pub
const
SIGPWR
:
usize
=
30
;
pub
const
SIGSYS
:
usize
=
31
;
pub
const
SA_NOCLDSTOP
:
usize
=
0x00000001
;
pub
const
SA_NOCLDWAIT
:
usize
=
0x00000002
;
pub
const
SA_SIGINFO
:
usize
=
0x00000004
;
pub
const
SA_RESTORER
:
usize
=
0x04000000
;
pub
const
SA_ONSTACK
:
usize
=
0x08000000
;
pub
const
SA_RESTART
:
usize
=
0x10000000
;
pub
const
SA_NODEFER
:
usize
=
0x40000000
;
pub
const
SA_RESETHAND
:
usize
=
0x80000000
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment