os.h revision b4c8a80f7dbfc9b56dbe03bdc28f0b5eb5f23697
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#ifndef APACHE_OS_H
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#define APACHE_OS_H
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#define PLATFORM "BS2000"
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt/*
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt * This file in included in all Apache source code. It contains definitions
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt * of facilities available on _this_ operating system (HAVE_* macros),
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt * and prototypes of OS specific functions defined in os.c or os ap_context_t nline.c
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt */
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#if !defined(INLINE) && defined(USE_GNU_INLINE)
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt/* Compiler supports inline, so include the inlineable functions as
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt * part of the header
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt */
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#define INLINE extern ap_inline
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik FlyktINLINE int ap_os_is_path_absolute(const char *file);
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#include "os ap_context_t nline.c"
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#endif
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#ifndef INLINE
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt/* Compiler does not support inline, so prototype the inlineable functions
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt * as normal
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt */
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flyktextern int ap_os_is_path_absolute(const char *file);
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt#endif
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt
5c79bd79839f1e50bd3c34a0670037f7965ca5a4Patrik Flykt/* Other ap_os_ routines not used by this platform */
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flykt
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flykt#define ap_os_is_filename_valid(f) (1)
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt#define ap_os_kill(pid, sig) kill(pid, sig)
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt#if !defined(_POSIX_SOURCE) && !defined(_XOPEN_SOURCE)
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykttypedef struct {
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt char *username;
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt char *account;
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt char *processor_name;
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt} _rini_struct;
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flyktextern int _rini(_rini_struct *);
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt#endif /* !defined(_POSIX_SOURCE) && !defined(_XOPEN_SOURCE) */
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt/* Sorry if this is ugly, but the include order doesn't allow me
c62c4628d9dbc27effd36143c75abe528f561867Patrik Flykt * to use request_rec here... */
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flyktstruct request_rec;
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flyktextern int ap_checkconv(struct request_rec *r);
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flyktextern pid_t os_fork(const char *user);
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flykt
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flykt#endif /*! APACHE_OS_H*/
be3a09b7ffe62b52658e77ae4d6638d1b0dae654Patrik Flykt