aboutsummaryrefslogtreecommitdiff
path: root/file_io
diff options
context:
space:
mode:
authorBrian Havard <bjh@apache.org>2000-11-14 06:40:07 +0000
committerBrian Havard <bjh@apache.org>2000-11-14 06:40:07 +0000
commit12d2674e20b7d2d849f570a07cd0967839b3822b (patch)
treed4f70b5ae7a2241e1bfff696ec914f241741062a /file_io
parent56aa150bfb90f3a8c9bf1c89d9610fb083aa5581 (diff)
downloadapr-12d2674e20b7d2d849f570a07cd0967839b3822b.tar.gz
apr-12d2674e20b7d2d849f570a07cd0967839b3822b.zip
Fix OS/2 build after the move of private APR headers to the include/arch/
area. This also messes with some unix stuff where it's shared with OS/2. The strategy used to get the right platform specific include files is: - Every Makefile.in contains something like OSDIR=$(INCDIR)/arch/@OSDIR@ DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@ INCLUDES=-I$(INCDIR) -I$(OSDIR) -I$(DEFOSDIR) - all APR private includes look like #include "fileio.h", ie no leading arch directory so no #ifdef'ing needed in shared .c files. This ensures that the include file for the target platform is always used if it exists, otherwise the default is used. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@60720 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'file_io')
-rw-r--r--file_io/os2/Makefile.in122
-rw-r--r--file_io/os2/dir.c2
-rw-r--r--file_io/os2/filedup.c2
-rw-r--r--file_io/os2/filestat.c2
-rw-r--r--file_io/os2/maperrorcode.c2
-rw-r--r--file_io/os2/open.c2
-rw-r--r--file_io/os2/pipe.c2
-rw-r--r--file_io/os2/readwrite.c2
-rw-r--r--file_io/os2/seek.c2
-rw-r--r--file_io/unix/Makefile.in4
-rw-r--r--file_io/unix/dir.c2
-rw-r--r--file_io/unix/fileacc.c16
-rw-r--r--file_io/unix/filedup.c2
-rw-r--r--file_io/unix/filestat.c2
-rw-r--r--file_io/unix/open.c2
-rw-r--r--file_io/unix/pipe.c2
-rw-r--r--file_io/unix/readwrite.c2
-rw-r--r--file_io/unix/seek.c2
18 files changed, 92 insertions, 80 deletions
diff --git a/file_io/os2/Makefile.in b/file_io/os2/Makefile.in
index 2d43b5b8a..2b19e3a66 100644
--- a/file_io/os2/Makefile.in
+++ b/file_io/os2/Makefile.in
@@ -9,7 +9,9 @@ CFLAGS=@CFLAGS@ @OPTIM@
LIBS=@LIBS@
LDFLAGS=@LDFLAGS@ $(LIBS)
INCDIR=../../include
-INCLUDES=-I$(INCDIR) -I$(INCDIR)/arch
+OSDIR=$(INCDIR)/arch/@OSDIR@
+DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@
+INCLUDES=-I$(INCDIR) -I$(OSDIR) -I$(DEFOSDIR)
LIB=file.a
@@ -49,55 +51,77 @@ depend:
cp Makefile.in Makefile.in.bak \
&& sed -ne '1,/^# DO NOT REMOVE/p' Makefile.in > Makefile.new \
&& gcc -MM $(INCLUDES) $(CFLAGS) *.c | sed -e "s%\\\\\(.\)%/\\1%g" >> Makefile.new \
- && sed -e '1,$$s: $(INCDIR)/: $$(INCDIR)/:g' \
- -e '1,$$s: $(INCDIR1)/: $$(INCDIR1)/:g' \
- -e '1,$$s: $(OSDIR)/: $$(OSDIR)/:g' Makefile.new \
+ && sed -e '1,$$s: $(OSDIR)/: $$(OSDIR)/:g' \
+ -e '1,$$s: $(DEFOSDIR)/: $$(DEFOSDIR)/:g' \
+ -e '1,$$s: $(INCDIR)/: $$(INCDIR)/:g' Makefile.new \
> Makefile.in \
&& rm Makefile.new
# DO NOT REMOVE
-dir.o: dir.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-fileacc.o: fileacc.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-filedup.o: filedup.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-filestat.o: filestat.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-maperrorcode.o: maperrorcode.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h ../../network_io/os2/os2calls.h
-open.o: open.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h $(INCDIR1)/apr_portable.h \
- $(INCDIR1)/apr_network_io.h $(INCDIR1)/apr_lock.h
-pipe.o: pipe.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-readwrite.o: readwrite.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
-seek.o: seek.c fileio.h $(INCDIR1)/apr_private.h \
- $(INCDIR1)/apr_general.h $(INCDIR1)/apr.h \
- $(INCDIR1)/apr_errno.h $(INCDIR1)/apr_file_io.h \
- $(INCDIR1)/apr_time.h $(INCDIR1)/apr_lib.h \
- $(INCDIR1)/apr_thread_proc.h
+common.o: common.c ../unix/fileacc.c $(INCDIR)/apr_strings.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_file_io.h \
+ $(INCDIR)/apr_general.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_tables.h $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_lock.h
+dir.o: dir.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h \
+ $(INCDIR)/apr_strings.h
+filedup.o: filedup.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h \
+ $(INCDIR)/apr_strings.h
+filestat.o: filestat.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h
+maperrorcode.o: maperrorcode.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ ../../network_io/os2/os2calls.h ../../network_io/os2/os2nerrno.h
+open.o: open.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h \
+ $(INCDIR)/apr_portable.h $(INCDIR)/apr_network_io.h \
+ $(INCDIR)/apr_dso.h $(INCDIR)/apr_strings.h
+pipe.o: pipe.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h \
+ $(INCDIR)/apr_strings.h
+readwrite.o: readwrite.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h
+seek.o: seek.c $(OSDIR)/fileio.h \
+ $(INCDIR)/apr_private.h $(INCDIR)/apr_general.h \
+ $(INCDIR)/apr.h $(INCDIR)/apr_errno.h \
+ $(INCDIR)/../network_io/os2/os2nerrno.h $(INCDIR)/apr_lock.h \
+ $(INCDIR)/apr_file_io.h $(INCDIR)/apr_time.h \
+ $(INCDIR)/apr_lib.h $(INCDIR)/apr_pools.h \
+ $(INCDIR)/apr_thread_proc.h $(INCDIR)/apr_tables.h
diff --git a/file_io/os2/dir.c b/file_io/os2/dir.c
index 16a23c2de..299a70c1e 100644
--- a/file_io/os2/dir.c
+++ b/file_io/os2/dir.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
#include "apr_strings.h"
diff --git a/file_io/os2/filedup.c b/file_io/os2/filedup.c
index 4ceed46c0..ee52fcddb 100644
--- a/file_io/os2/filedup.c
+++ b/file_io/os2/filedup.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
#include "apr_strings.h"
diff --git a/file_io/os2/filestat.c b/file_io/os2/filestat.c
index 908a24d1c..1410cdb91 100644
--- a/file_io/os2/filestat.c
+++ b/file_io/os2/filestat.c
@@ -54,7 +54,7 @@
#define INCL_DOS
#define INCL_DOSERRORS
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
#include <sys/time.h>
diff --git a/file_io/os2/maperrorcode.c b/file_io/os2/maperrorcode.c
index fd32052ac..5fa398151 100644
--- a/file_io/os2/maperrorcode.c
+++ b/file_io/os2/maperrorcode.c
@@ -53,7 +53,7 @@
*/
#define INCL_DOSERRORS
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include <errno.h>
#include <string.h>
diff --git a/file_io/os2/open.c b/file_io/os2/open.c
index b36b8b9bf..53c772e0a 100644
--- a/file_io/os2/open.c
+++ b/file_io/os2/open.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
#include "apr_portable.h"
diff --git a/file_io/os2/pipe.c b/file_io/os2/pipe.c
index 161d5ef38..87421bd8a 100644
--- a/file_io/os2/pipe.c
+++ b/file_io/os2/pipe.c
@@ -53,7 +53,7 @@
*/
#define INCL_DOSERRORS
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_general.h"
#include "apr_lib.h"
diff --git a/file_io/os2/readwrite.c b/file_io/os2/readwrite.c
index f5bcbb75c..282766a43 100644
--- a/file_io/os2/readwrite.c
+++ b/file_io/os2/readwrite.c
@@ -55,7 +55,7 @@
#define INCL_DOS
#define INCL_DOSERRORS
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
diff --git a/file_io/os2/seek.c b/file_io/os2/seek.c
index 521649c49..948f423f6 100644
--- a/file_io/os2/seek.c
+++ b/file_io/os2/seek.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "os2/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_lib.h"
#include <string.h>
diff --git a/file_io/unix/Makefile.in b/file_io/unix/Makefile.in
index f4e91328b..282ff7e4f 100644
--- a/file_io/unix/Makefile.in
+++ b/file_io/unix/Makefile.in
@@ -10,7 +10,9 @@ CFLAGS=@CFLAGS@ @OPTIM@
LIBS=@LIBS@
LDFLAGS=@LDFLAGS@ $(LIBS)
INCDIR=../../include
-INCLUDES=-I$(INCDIR) -I$(INCDIR)/arch
+OSDIR=$(INCDIR)/arch/@OSDIR@
+DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@
+INCLUDES=-I$(INCDIR) -I$(OSDIR) -I$(DEFOSDIR)
#LIB=libfile.a
diff --git a/file_io/unix/dir.c b/file_io/unix/dir.c
index 12b0d6209..419c2f881 100644
--- a/file_io/unix/dir.c
+++ b/file_io/unix/dir.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_strings.h"
#include "apr_portable.h"
diff --git a/file_io/unix/fileacc.c b/file_io/unix/fileacc.c
index ef0676e7d..6bb9241c9 100644
--- a/file_io/unix/fileacc.c
+++ b/file_io/unix/fileacc.c
@@ -53,21 +53,7 @@
*/
#include "apr_strings.h"
-#ifdef OS2
-#include "os2/fileio.h"
-#elif defined(WIN32)
-#include "win32/fileio.h"
-#endif
-#if defined(OS2) || defined(WIN32)
-#include "apr_file_io.h"
-#include "apr_general.h"
-#include "apr_lib.h"
-#include <errno.h>
-#include <string.h>
-#include <sys/types.h>
-#else
-#include "unix/fileio.h"
-#endif
+#include "fileio.h"
/* A file to put ALL of the accessor functions for apr_file_t types. */
diff --git a/file_io/unix/filedup.c b/file_io/unix/filedup.c
index 27aad60f0..06956fac5 100644
--- a/file_io/unix/filedup.c
+++ b/file_io/unix/filedup.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_strings.h"
#include "apr_portable.h"
diff --git a/file_io/unix/filestat.c b/file_io/unix/filestat.c
index ed860fb75..96f8b68c8 100644
--- a/file_io/unix/filestat.c
+++ b/file_io/unix/filestat.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_file_io.h"
#include "apr_general.h"
#include "apr_errno.h"
diff --git a/file_io/unix/open.c b/file_io/unix/open.c
index 5a6201b5b..dab768f4d 100644
--- a/file_io/unix/open.c
+++ b/file_io/unix/open.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_strings.h"
#include "apr_portable.h"
diff --git a/file_io/unix/pipe.c b/file_io/unix/pipe.c
index e7e6d4e10..f5bf550fd 100644
--- a/file_io/unix/pipe.c
+++ b/file_io/unix/pipe.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_strings.h"
static apr_status_t pipeblock(apr_file_t *thepipe)
diff --git a/file_io/unix/readwrite.c b/file_io/unix/readwrite.c
index 1ef083198..57a950d25 100644
--- a/file_io/unix/readwrite.c
+++ b/file_io/unix/readwrite.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
#include "apr_lock.h"
/* The only case where we don't use wait_for_io_or_timeout is on
diff --git a/file_io/unix/seek.c b/file_io/unix/seek.c
index c30811bd6..3ab2aca93 100644
--- a/file_io/unix/seek.c
+++ b/file_io/unix/seek.c
@@ -52,7 +52,7 @@
* <http://www.apache.org/>.
*/
-#include "unix/fileio.h"
+#include "fileio.h"
static apr_status_t setptr(apr_file_t *thefile, unsigned long pos )
{