]> git.ipfire.org Git - people/ms/gcc.git/blame - libphobos/libdruntime/core/sys/posix/utime.d
d: Merge upstream dmd, druntime 4ca4140e58, phobos 454dff14d.
[people/ms/gcc.git] / libphobos / libdruntime / core / sys / posix / utime.d
CommitLineData
b4c522fa
IB
1/**
2 * D header file for POSIX.
3 *
4 * Copyright: Copyright Sean Kelly 2005 - 2009.
5 * License: $(HTTP www.boost.org/LICENSE_1_0.txt, Boost License 1.0).
6 * Authors: Sean Kelly
7 * Standards: The Open Group Base Specifications Issue 6, IEEE Std 1003.1, 2004 Edition
8 */
9
10/* Copyright Sean Kelly 2005 - 2009.
11 * Distributed under the Boost Software License, Version 1.0.
12 * (See accompanying file LICENSE or copy at
13 * http://www.boost.org/LICENSE_1_0.txt)
14 */
15module core.sys.posix.utime;
16
92dd3e71 17import core.sys.posix.config;
b4c522fa
IB
18public import core.sys.posix.sys.types; // for time_t
19
20version (OSX)
21 version = Darwin;
22else version (iOS)
23 version = Darwin;
24else version (TVOS)
25 version = Darwin;
26else version (WatchOS)
27 version = Darwin;
28
29version (Posix):
30extern (C):
31nothrow:
32@nogc:
33
34//
35// Required
36//
37/*
38struct utimbuf
39{
40 time_t actime;
41 time_t modtime;
42}
43
92dd3e71 44int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
45*/
46
47version (CRuntime_Glibc)
48{
49 struct utimbuf
50 {
51 time_t actime;
52 time_t modtime;
53 }
54
92dd3e71 55 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
56}
57else version (CRuntime_Musl)
58{
59 struct utimbuf
60 {
61 time_t actime;
62 time_t modtime;
63 }
64
8da8c7d3 65 pragma(mangle, muslRedirTime64Mangle!("utime", "__utime64"))
92dd3e71 66 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
67}
68else version (Darwin)
69{
70 struct utimbuf
71 {
72 time_t actime;
73 time_t modtime;
74 }
75
92dd3e71 76 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
77}
78else version (FreeBSD)
79{
80 struct utimbuf
81 {
82 time_t actime;
83 time_t modtime;
84 }
85
92dd3e71 86 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
87}
88else version (NetBSD)
89{
90 struct utimbuf
91 {
92 time_t actime;
93 time_t modtime;
94 }
95
92dd3e71 96 int utime(const scope char*, const scope utimbuf*);
b4c522fa 97}
0234a917
IB
98else version (OpenBSD)
99{
100 struct utimbuf
101 {
102 time_t actime;
103 time_t modtime;
104 }
105
92dd3e71 106 int utime(const scope char*, const scope utimbuf*);
0234a917 107}
b4c522fa
IB
108else version (DragonFlyBSD)
109{
110 struct utimbuf
111 {
112 time_t actime;
113 time_t modtime;
114 }
115
92dd3e71 116 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
117}
118else version (Solaris)
119{
120 struct utimbuf
121 {
122 time_t actime;
123 time_t modtime;
124 }
125
92dd3e71 126 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
127}
128else version (CRuntime_Bionic)
129{
130 struct utimbuf
131 {
132 time_t actime;
133 time_t modtime;
134 }
135
92dd3e71 136 int utime(const scope char*, const scope utimbuf*);
b4c522fa
IB
137}
138else version (CRuntime_UClibc)
139{
140 struct utimbuf
141 {
142 time_t actime;
143 time_t modtime;
144 }
145
92dd3e71 146 int utime(const scope char*, const scope utimbuf*);
b4c522fa 147}