Mercurial > octave
annotate liboctave/system/oct-syscalls.h @ 30564:796f54d4ddbf stable
update Octave Project Developers copyright for the new year
In files that have the "Octave Project Developers" copyright notice,
update for 2021.
In all .txi and .texi files except gpl.txi and gpl.texi in the
doc/liboctave and doc/interpreter directories, change the copyright
to "Octave Project Developers", the same as used for other source
files. Update copyright notices for 2022 (not done since 2019). For
gpl.txi and gpl.texi, change the copyright notice to be "Free Software
Foundation, Inc." and leave the date at 2007 only because this file
only contains the text of the GPL, not anything created by the Octave
Project Developers.
Add Paul Thomas to contributors.in.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Tue, 28 Dec 2021 18:22:40 -0500 |
parents | 0a5b15007766 |
children | e88a07dec498 |
rev | line source |
---|---|
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
1 //////////////////////////////////////////////////////////////////////// |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
2 // |
30564
796f54d4ddbf
update Octave Project Developers copyright for the new year
John W. Eaton <jwe@octave.org>
parents:
29358
diff
changeset
|
3 // Copyright (C) 1996-2022 The Octave Project Developers |
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
4 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
5 // See the file COPYRIGHT.md in the top-level directory of this |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
6 // distribution or <https://octave.org/copyright/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
7 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
8 // This file is part of Octave. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
9 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
10 // Octave is free software: you can redistribute it and/or modify it |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
11 // under the terms of the GNU General Public License as published by |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
12 // the Free Software Foundation, either version 3 of the License, or |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
13 // (at your option) any later version. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
14 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
15 // Octave is distributed in the hope that it will be useful, but |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
16 // WITHOUT ANY WARRANTY; without even the implied warranty of |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
18 // GNU General Public License for more details. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
19 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
20 // You should have received a copy of the GNU General Public License |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
21 // along with Octave; see the file COPYING. If not, see |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
22 // <https://www.gnu.org/licenses/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
23 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
24 //////////////////////////////////////////////////////////////////////// |
2941 | 25 |
20791
f7084eae3318
maint: Use Octave coding conventions for #if statements.
Rik <rik@octave.org>
parents:
19697
diff
changeset
|
26 #if ! defined (octave_oct_syscalls_h) |
17822
ebb3ef964372
maint: Use common #define syntax "octave_filename_h" in h_files.
Rik <rik@octave.org>
parents:
17769
diff
changeset
|
27 #define octave_oct_syscalls_h 1 |
2941 | 28 |
21244
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
20791
diff
changeset
|
29 #include "octave-config.h" |
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
20791
diff
changeset
|
30 |
2941 | 31 #include <string> |
32 | |
33 class string_vector; | |
34 | |
35 #include <sys/types.h> | |
36 | |
21734
11af9c03400c
write namespace keyword and name on same line in C++ files
John W. Eaton <jwe@octave.org>
parents:
21727
diff
changeset
|
37 namespace octave |
2941 | 38 { |
21734
11af9c03400c
write namespace keyword and name on same line in C++ files
John W. Eaton <jwe@octave.org>
parents:
21727
diff
changeset
|
39 namespace sys |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
40 { |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
41 extern OCTAVE_API int dup2 (int, int); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
42 extern OCTAVE_API int dup2 (int, int, std::string&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
43 |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
44 extern OCTAVE_API int execvp (const std::string&, const string_vector&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
45 extern OCTAVE_API int execvp (const std::string&, const string_vector&, |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
46 std::string&); |
2941 | 47 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
48 extern OCTAVE_API pid_t fork (std::string&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
49 |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
50 extern OCTAVE_API pid_t vfork (std::string&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
51 |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
52 extern OCTAVE_API pid_t getpgrp (std::string&); |
2941 | 53 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
54 extern OCTAVE_API pid_t getpid (void); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
55 |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
56 extern OCTAVE_API pid_t getppid (void); |
2941 | 57 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
58 extern OCTAVE_API gid_t getgid (void); |
2941 | 59 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
60 extern OCTAVE_API gid_t getegid (void); |
2941 | 61 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
62 extern OCTAVE_API uid_t getuid (void); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
63 |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
64 extern OCTAVE_API uid_t geteuid (void); |
2941 | 65 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
66 extern OCTAVE_API int pipe (int *); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
67 extern OCTAVE_API int pipe (int *, std::string&); |
2941 | 68 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
69 extern OCTAVE_API pid_t waitpid (pid_t, int *status, int); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
70 extern OCTAVE_API pid_t waitpid (pid_t, int *status, int, std::string&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
71 |
21921
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
72 extern OCTAVE_API int wcontinue (void); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
73 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
74 extern OCTAVE_API int wcoredump (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
75 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
76 extern OCTAVE_API bool wifcontinued (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
77 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
78 extern OCTAVE_API bool wifexited (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
79 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
80 extern OCTAVE_API bool wifsignaled (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
81 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
82 extern OCTAVE_API bool wifstopped (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
83 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
84 extern OCTAVE_API int wexitstatus (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
85 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
86 extern OCTAVE_API int wnohang (void); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
87 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
88 extern OCTAVE_API int wstopsig (int status); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
89 |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
90 extern OCTAVE_API int wtermsig (int status); |
21937
55f7de37b618
maint: Strip trailing whitespace from source files.
John W. Eaton <jwe@octave.org>
parents:
21921
diff
changeset
|
91 |
21921
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
92 extern OCTAVE_API int wuntraced (void); |
ecfcc8527661
hide sys/wait.h header and provide wrappers for waitpid macros
John W. Eaton <jwe@octave.org>
parents:
21734
diff
changeset
|
93 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
94 extern OCTAVE_API int kill (pid_t, int); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
95 extern OCTAVE_API int kill (pid_t, int, std::string&); |
2941 | 96 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
97 extern OCTAVE_API pid_t |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
98 popen2 (const std::string&, const string_vector&, bool, int *); |
4294 | 99 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
100 extern OCTAVE_API pid_t |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
101 popen2 (const std::string&, const string_vector&, bool, int *, |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
102 std::string&); |
6321 | 103 |
21609
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
104 extern OCTAVE_API int fcntl (int, int, long); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
105 extern OCTAVE_API int fcntl (int, int, long, std::string&); |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
106 } |
46f059de4dce
use namespace instead of struct with static members for system call wrappers
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
107 } |
2941 | 108 |
109 #endif |