aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorEli Zaretskii2012-06-23 13:22:59 +0300
committerEli Zaretskii2012-06-23 13:22:59 +0300
commit388cdec072a52e1b647dec159433fd0ffe240be4 (patch)
treeefd6a04f97a631114fd093b4414a9242486e04a5 /lib
parentf199cab1a97da8c46b719bb73af58acdcb6243c1 (diff)
downloademacs-388cdec072a52e1b647dec159433fd0ffe240be4.tar.gz
emacs-388cdec072a52e1b647dec159433fd0ffe240be4.zip
Fix the MS-Windows build broken by 2012-06-22T21:17:42Z!eggert@cs.ucla.edu.
nt/inc/sys/time.h (struct timespec): Define. lib/makefile.w32-in (GNULIBOBJS): Add $(BLD)/dtotimespec.$(O), $(BLD)/gettime.$(O), $(BLD)/timespec-add.$(O), and $(BLD)/timespec-sub.$(O). ($(BLD)/dtotimespec.$(O)): ($(BLD)/gettime.$(O)): ($(BLD)/timespec-add.$(O)): ($(BLD)/timespec-sub.$(O)): New dependencies. lib/stat-time.h: lib/timespec.h: lib/utimens.h: Include sys/time.h src/w32.c (fdutimens): New function. src/w32proc.c (sys_select): Adapt to change in the EMACS_TIME type. src/s/ms-w32.h (pselect): Redirect to sys_select. src/sysselect.h [WINDOWSNT]: Don't include sys/select.h. Fixes: debbugs:9000
Diffstat (limited to 'lib')
-rw-r--r--lib/makefile.w32-in39
-rw-r--r--lib/stat-time.h1
-rw-r--r--lib/timespec.h1
-rw-r--r--lib/utimens.h1
4 files changed, 42 insertions, 0 deletions
diff --git a/lib/makefile.w32-in b/lib/makefile.w32-in
index 62808f73a74..35745f647b2 100644
--- a/lib/makefile.w32-in
+++ b/lib/makefile.w32-in
@@ -24,10 +24,14 @@ LOCAL_FLAGS = -DHAVE_CONFIG_H=1 -I. -I../nt/inc -I../src
24LIBS = 24LIBS =
25 25
26GNULIBOBJS = $(BLD)/dtoastr.$(O) \ 26GNULIBOBJS = $(BLD)/dtoastr.$(O) \
27 $(BLD)/dtotimespec.$(O) \
27 $(BLD)/getopt.$(O) \ 28 $(BLD)/getopt.$(O) \
28 $(BLD)/getopt1.$(O) \ 29 $(BLD)/getopt1.$(O) \
30 $(BLD)/gettime.$(O) \
29 $(BLD)/strftime.$(O) \ 31 $(BLD)/strftime.$(O) \
30 $(BLD)/time_r.$(O) \ 32 $(BLD)/time_r.$(O) \
33 $(BLD)/timespec-add.$(O) \
34 $(BLD)/timespec-sub.$(O) \
31 $(BLD)/md5.$(O) \ 35 $(BLD)/md5.$(O) \
32 $(BLD)/sha1.$(O) \ 36 $(BLD)/sha1.$(O) \
33 $(BLD)/sha256.$(O) \ 37 $(BLD)/sha256.$(O) \
@@ -69,6 +73,15 @@ $(BLD)/dtoastr.$(O) : \
69 $(EMACS_ROOT)/src/s/ms-w32.h \ 73 $(EMACS_ROOT)/src/s/ms-w32.h \
70 $(EMACS_ROOT)/src/config.h 74 $(EMACS_ROOT)/src/config.h
71 75
76$(BLD)/dtotimespec.$(O) : \
77 $(SRC)/dtotimespec.c \
78 $(SRC)/intprops.h \
79 $(SRC)/timespec.h \
80 $(EMACS_ROOT)/nt/inc/sys/time.h \
81 $(EMACS_ROOT)/nt/inc/sys/stat.h \
82 $(EMACS_ROOT)/src/s/ms-w32.h \
83 $(EMACS_ROOT)/src/config.h
84
72$(BLD)/getopt.$(O) : \ 85$(BLD)/getopt.$(O) : \
73 $(SRC)/getopt.c \ 86 $(SRC)/getopt.c \
74 $(SRC)/getopt.h \ 87 $(SRC)/getopt.h \
@@ -87,6 +100,14 @@ $(BLD)/getopt1.$(O) : \
87 $(EMACS_ROOT)/src/s/ms-w32.h \ 100 $(EMACS_ROOT)/src/s/ms-w32.h \
88 $(EMACS_ROOT)/src/config.h 101 $(EMACS_ROOT)/src/config.h
89 102
103$(BLD)/gettime.$(O) : \
104 $(SRC)/gettime.c \
105 $(SRC)/timespec.h \
106 $(EMACS_ROOT)/nt/inc/sys/time.h \
107 $(EMACS_ROOT)/nt/inc/sys/stat.h \
108 $(EMACS_ROOT)/src/s/ms-w32.h \
109 $(EMACS_ROOT)/src/config.h
110
90$(BLD)/strftime.$(O) : \ 111$(BLD)/strftime.$(O) : \
91 $(SRC)/strftime.c \ 112 $(SRC)/strftime.c \
92 $(SRC)/strftime.h \ 113 $(SRC)/strftime.h \
@@ -101,6 +122,24 @@ $(BLD)/time_r.$(O) : \
101 $(EMACS_ROOT)/src/s/ms-w32.h \ 122 $(EMACS_ROOT)/src/s/ms-w32.h \
102 $(EMACS_ROOT)/src/config.h 123 $(EMACS_ROOT)/src/config.h
103 124
125$(BLD)/timespec-add.$(O) : \
126 $(SRC)/timespec-add.c \
127 $(SRC)/intprops.h \
128 $(SRC)/timespec.h \
129 $(EMACS_ROOT)/nt/inc/sys/time.h \
130 $(EMACS_ROOT)/nt/inc/sys/stat.h \
131 $(EMACS_ROOT)/src/s/ms-w32.h \
132 $(EMACS_ROOT)/src/config.h
133
134$(BLD)/timespec-sub.$(O) : \
135 $(SRC)/timespec-sub.c \
136 $(SRC)/intprops.h \
137 $(SRC)/timespec.h \
138 $(EMACS_ROOT)/nt/inc/sys/time.h \
139 $(EMACS_ROOT)/nt/inc/sys/stat.h \
140 $(EMACS_ROOT)/src/s/ms-w32.h \
141 $(EMACS_ROOT)/src/config.h
142
104$(BLD)/md5.$(O) : \ 143$(BLD)/md5.$(O) : \
105 $(SRC)/md5.c \ 144 $(SRC)/md5.c \
106 $(SRC)/md5.h \ 145 $(SRC)/md5.h \
diff --git a/lib/stat-time.h b/lib/stat-time.h
index 30c2acdab63..03d49977945 100644
--- a/lib/stat-time.h
+++ b/lib/stat-time.h
@@ -22,6 +22,7 @@
22 22
23#include <sys/stat.h> 23#include <sys/stat.h>
24#include <time.h> 24#include <time.h>
25#include <sys/time.h>
25 26
26/* STAT_TIMESPEC (ST, ST_XTIM) is the ST_XTIM member for *ST of type 27/* STAT_TIMESPEC (ST, ST_XTIM) is the ST_XTIM member for *ST of type
27 struct timespec, if available. If not, then STAT_TIMESPEC_NS (ST, 28 struct timespec, if available. If not, then STAT_TIMESPEC_NS (ST,
diff --git a/lib/timespec.h b/lib/timespec.h
index 388ddb83a76..51b85d050da 100644
--- a/lib/timespec.h
+++ b/lib/timespec.h
@@ -20,6 +20,7 @@
20# define TIMESPEC_H 20# define TIMESPEC_H
21 21
22# include <time.h> 22# include <time.h>
23# include <sys/time.h>
23 24
24/* Return negative, zero, positive if A < B, A == B, A > B, respectively. 25/* Return negative, zero, positive if A < B, A == B, A > B, respectively.
25 26
diff --git a/lib/utimens.h b/lib/utimens.h
index 8c47cf93f88..dfcbae1909d 100644
--- a/lib/utimens.h
+++ b/lib/utimens.h
@@ -1,4 +1,5 @@
1#include <time.h> 1#include <time.h>
2#include <sys/time.h>
2int fdutimens (int, char const *, struct timespec const [2]); 3int fdutimens (int, char const *, struct timespec const [2]);
3int utimens (char const *, struct timespec const [2]); 4int utimens (char const *, struct timespec const [2]);
4int lutimens (char const *, struct timespec const [2]); 5int lutimens (char const *, struct timespec const [2]);