Adding upstream version 2.4.63.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
This commit is contained in:
parent
93c6f9029a
commit
7263481e48
3104 changed files with 900776 additions and 0 deletions
0
.deps
Normal file
0
.deps
Normal file
598
.gdbinit
Normal file
598
.gdbinit
Normal file
|
@ -0,0 +1,598 @@
|
|||
# gdb macros which may be useful for folks using gdb to debug
|
||||
# apache. Delete it if it bothers you.
|
||||
|
||||
define dump_table
|
||||
set $t = (apr_table_entry_t *)((apr_array_header_t *)$arg0)->elts
|
||||
set $n = ((apr_array_header_t *)$arg0)->nelts
|
||||
set $i = 0
|
||||
while $i < $n
|
||||
if $t[$i].val == (void *)0L
|
||||
printf "[%u] '%s'=>NULL\n", $i, $t[$i].key
|
||||
else
|
||||
printf "[%u] '%s'='%s' [%p]\n", $i, $t[$i].key, $t[$i].val, $t[$i].val
|
||||
end
|
||||
set $i = $i + 1
|
||||
end
|
||||
end
|
||||
document dump_table
|
||||
Print the key/value pairs in a table.
|
||||
end
|
||||
|
||||
define dump_skiplist
|
||||
set $sl = (apr_skiplist *)$arg0
|
||||
set $m = $sl->bottom
|
||||
printf "skiplist@%p: size=%lu: height=%d\n", $sl, $sl->size, $sl->height
|
||||
while ($m)
|
||||
printf "(%p,%.12lx)", $m, $m->data
|
||||
set $u = $m->up
|
||||
while ($u)
|
||||
printf " (%p,%.12lx)", $u, $u->data
|
||||
set $u = $u->up
|
||||
end
|
||||
printf "\n"
|
||||
set $m = $m->next
|
||||
end
|
||||
end
|
||||
document dump_skiplist
|
||||
Print the nodes/values in a skiplist
|
||||
end
|
||||
|
||||
define dump_string_hash
|
||||
set $h = $arg0->array
|
||||
set $n = $arg0->max
|
||||
set $i = 0
|
||||
while $i < $n
|
||||
set $ent = $h[$i]
|
||||
while $ent != (void *)0L
|
||||
printf "'%s' => '%p'\n", $ent->key, $ent->val
|
||||
set $ent = $ent->next
|
||||
end
|
||||
set $i = $i + 1
|
||||
end
|
||||
end
|
||||
document dump_string_hash
|
||||
Print the entries in a hash table indexed by strings
|
||||
end
|
||||
|
||||
define dump_string_shash
|
||||
set $h = $arg0->array
|
||||
set $n = $arg0->max
|
||||
set $i = 0
|
||||
while $i < $n
|
||||
set $ent = $h[$i]
|
||||
while $ent != (void *)0L
|
||||
printf "'%s' => '%s'\n", $ent->key, $ent->val
|
||||
set $ent = $ent->next
|
||||
end
|
||||
set $i = $i + 1
|
||||
end
|
||||
end
|
||||
document dump_string_shash
|
||||
Print the entries in a hash table indexed by strings with string values
|
||||
end
|
||||
|
||||
define ro
|
||||
run -DONE_PROCESS
|
||||
end
|
||||
|
||||
define dump_string_array
|
||||
set $a = (char **)((apr_array_header_t *)$arg0)->elts
|
||||
set $n = (int)((apr_array_header_t *)$arg0)->nelts
|
||||
set $i = 0
|
||||
while $i < $n
|
||||
printf "[%u] '%s'\n", $i, $a[$i]
|
||||
set $i = $i + 1
|
||||
end
|
||||
end
|
||||
document dump_string_array
|
||||
Print all of the elements in an array of strings.
|
||||
end
|
||||
|
||||
define printmemn
|
||||
set $i = 0
|
||||
while $i < $arg1
|
||||
if $arg0[$i] < 0x20 || $arg0[$i] > 0x7e
|
||||
printf "~"
|
||||
else
|
||||
printf "%c", $arg0[$i]
|
||||
end
|
||||
set $i = $i + 1
|
||||
end
|
||||
end
|
||||
|
||||
define print_bkt_datacol
|
||||
# arg0 == column name
|
||||
# arg1 == format
|
||||
# arg2 == value
|
||||
# arg3 == suppress header?
|
||||
set $suppressheader = $arg3
|
||||
|
||||
if !$suppressheader
|
||||
printf " "
|
||||
printf $arg0
|
||||
printf "="
|
||||
else
|
||||
printf " | "
|
||||
end
|
||||
printf $arg1, $arg2
|
||||
end
|
||||
|
||||
define dump_bucket_ex
|
||||
# arg0 == bucket
|
||||
# arg1 == suppress header?
|
||||
set $bucket = (struct apr_bucket *)$arg0
|
||||
set $sh = $arg1
|
||||
set $refcount = -1
|
||||
|
||||
print_bkt_datacol "bucket" "%-9s" $bucket->type->name $sh
|
||||
printf "(%12lx)", (unsigned long)$bucket
|
||||
print_bkt_datacol "length" "%-6ld" (long)($bucket->length) $sh
|
||||
print_bkt_datacol "data" "%12lx" $bucket->data $sh
|
||||
|
||||
if !$sh
|
||||
printf "\n "
|
||||
end
|
||||
|
||||
if (($bucket->type == &apr_bucket_type_eos) || \
|
||||
($bucket->type == &apr_bucket_type_flush))
|
||||
|
||||
# metadata buckets, no content
|
||||
print_bkt_datacol "contents" "%c" ' ' $sh
|
||||
printf " "
|
||||
print_bkt_datacol "rc" "n/%c" 'a' $sh
|
||||
|
||||
else
|
||||
if ($bucket->type == &ap_bucket_type_error)
|
||||
|
||||
# metadata bucket, no content but it does have an error code in it
|
||||
print_bkt_datacol "contents" "%c" ' ' $sh
|
||||
set $status = ((ap_bucket_error *)$bucket->data)->status
|
||||
printf " (status=%3d) ", $status
|
||||
print_bkt_datacol "rc" "n/%c" 'a' $sh
|
||||
|
||||
else
|
||||
if ($bucket->type == &apr_bucket_type_file)
|
||||
|
||||
# file bucket, can show fd and refcount
|
||||
set $fd = ((apr_bucket_file*)$bucket->data)->fd->filedes
|
||||
print_bkt_datacol "contents" "[***file***] fd=%-6ld" (long)$fd $sh
|
||||
set $refcount = ((apr_bucket_refcount *)$bucket->data)->refcount
|
||||
print_bkt_datacol "rc" "%-3d" $refcount $sh
|
||||
|
||||
else
|
||||
if (($bucket->type == &apr_bucket_type_heap) || \
|
||||
($bucket->type == &apr_bucket_type_pool) || \
|
||||
($bucket->type == &apr_bucket_type_mmap) || \
|
||||
($bucket->type == &apr_bucket_type_transient) || \
|
||||
($bucket->type == &apr_bucket_type_immortal))
|
||||
|
||||
# in-memory buckets
|
||||
|
||||
if $bucket->type == &apr_bucket_type_heap
|
||||
set $refcount = ((apr_bucket_refcount *)$bucket->data)->refcount
|
||||
set $p = (apr_bucket_heap *)$bucket->data
|
||||
set $data = $p->base+$bucket->start
|
||||
|
||||
else
|
||||
if $bucket->type == &apr_bucket_type_pool
|
||||
set $refcount = ((apr_bucket_refcount *)$bucket->data)->refcount
|
||||
set $p = (apr_bucket_pool *)$bucket->data
|
||||
if !$p->pool
|
||||
set $p = (apr_bucket_heap *)$bucket->data
|
||||
end
|
||||
set $data = $p->base+$bucket->start
|
||||
|
||||
else
|
||||
if $bucket->type == &apr_bucket_type_mmap
|
||||
# is this safe if not APR_HAS_MMAP?
|
||||
set $refcount = ((apr_bucket_refcount *)$bucket->data)->refcount
|
||||
set $p = (apr_bucket_mmap *)$bucket->data
|
||||
set $data = ((char *)$p->mmap->mm)+$bucket->start
|
||||
|
||||
else
|
||||
if (($bucket->type == &apr_bucket_type_transient) || \
|
||||
($bucket->type == &apr_bucket_type_immortal))
|
||||
set $data = ((char *)$bucket->data)+$bucket->start
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
if $sh
|
||||
printf " | ["
|
||||
else
|
||||
printf " contents=["
|
||||
end
|
||||
set $datalen = $bucket->length
|
||||
if $isValidAddress($data) == 1
|
||||
if $datalen > 17
|
||||
printmem $data 17
|
||||
printf "..."
|
||||
set $datalen = 20
|
||||
else
|
||||
printmemn $data $datalen
|
||||
end
|
||||
printf "]"
|
||||
while $datalen < 20
|
||||
printf " "
|
||||
set $datalen = $datalen + 1
|
||||
end
|
||||
else
|
||||
printf "Iv addr %12lx]", $data
|
||||
end
|
||||
|
||||
if $refcount != -1
|
||||
print_bkt_datacol "rc" "%-3d" $refcount $sh
|
||||
else
|
||||
print_bkt_datacol "rc" "n/%c" 'a' $sh
|
||||
end
|
||||
|
||||
else
|
||||
if ($bucket->type == &apr_bucket_type_pipe)
|
||||
|
||||
# pipe bucket, can show fd
|
||||
set $fd = ((apr_file_t*)$bucket->data)->filedes
|
||||
print_bkt_datacol "contents" "[***pipe***] fd=%-3ld" (long)$fd $sh
|
||||
|
||||
else
|
||||
if ($bucket->type == &apr_bucket_type_socket)
|
||||
|
||||
# file bucket, can show fd
|
||||
set $fd = ((apr_socket_t*)$bucket->data)->socketdes
|
||||
print_bkt_datacol "contents" "[**socket**] fd=%-3ld" (long)$fd $sh
|
||||
|
||||
else
|
||||
|
||||
# 3rd-party bucket type
|
||||
print_bkt_datacol "contents" "[**opaque**]%-7c" ' ' $sh
|
||||
end
|
||||
end
|
||||
|
||||
# no refcount
|
||||
printf " "
|
||||
print_bkt_datacol "rc" "n/%c" 'a' $sh
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
printf "\n"
|
||||
|
||||
end
|
||||
|
||||
define dump_bucket
|
||||
dump_bucket_ex $arg0 0
|
||||
end
|
||||
document dump_bucket
|
||||
Print bucket info
|
||||
end
|
||||
|
||||
define dump_brigade
|
||||
set $bb = (apr_bucket_brigade *)$arg0
|
||||
set $bucket = $bb->list.next
|
||||
set $sentinel = ((char *)((&($bb->list)) \
|
||||
- ((size_t) &((struct apr_bucket *)0)->link)))
|
||||
printf "dump of brigade 0x%lx\n", (unsigned long)$bb
|
||||
|
||||
printf " | type (address) | length | "
|
||||
printf "data address | contents | rc\n"
|
||||
printf "-------------------------------------------"
|
||||
printf "----------------------------------------\n"
|
||||
|
||||
if $bucket == $sentinel
|
||||
printf "brigade is empty\n"
|
||||
end
|
||||
|
||||
set $j = 0
|
||||
set $brigade_length = 0
|
||||
while $bucket != $sentinel
|
||||
printf "%2d", $j
|
||||
dump_bucket_ex $bucket 1
|
||||
set $j = $j + 1
|
||||
if $bucket->length > 0
|
||||
set $brigade_length = $brigade_length + $bucket->length
|
||||
end
|
||||
set $bucket = $bucket->link.next
|
||||
end
|
||||
printf "end of brigade\n"
|
||||
printf "Length of brigade (excluding buckets of unknown length): %u\n", $brigade_length
|
||||
end
|
||||
document dump_brigade
|
||||
Print bucket brigade info
|
||||
end
|
||||
|
||||
define dump_filters
|
||||
set $f = $arg0
|
||||
while $f
|
||||
printf "%s(0x%lx): ctx=0x%lx, r=0x%lx, c=0x%lx\n", \
|
||||
$f->frec->name, (unsigned long)$f, (unsigned long)$f->ctx, \
|
||||
$f->r, $f->c
|
||||
set $f = $f->next
|
||||
end
|
||||
end
|
||||
document dump_filters
|
||||
Print filter chain info
|
||||
end
|
||||
|
||||
define dump_filter_chain
|
||||
set $r = $arg0
|
||||
set $f = $r->output_filters
|
||||
while $f
|
||||
if $f == $r->output_filters
|
||||
printf "r->output_filters =>\n"
|
||||
end
|
||||
if $f == $r->proto_output_filters
|
||||
printf "r->proto_output_filters =>\n"
|
||||
end
|
||||
if $f == $r->connection->output_filters
|
||||
printf "r->connection->output_filters =>\n"
|
||||
end
|
||||
|
||||
printf " %s(0x%lx): type=%d, ctx=0x%lx, r=%s(0x%lx), c=0x%lx\n", \
|
||||
$f->frec->name, (unsigned long)$f, $f->frec->ftype, (unsigned long)$f->ctx, \
|
||||
$f->r == $r ? "r" : ($f->r == 0L ? "null" : \
|
||||
($f->r == $r->main ? "r->main" : \
|
||||
($r->main && $f->r == $r->main->main ? "r->main->main" : "????"))), \
|
||||
$f->r, $f->c
|
||||
|
||||
set $f = $f->next
|
||||
end
|
||||
end
|
||||
document dump_filter_chain
|
||||
Print filter chain info given a request_rec pointer
|
||||
end
|
||||
|
||||
define dump_process_rec
|
||||
set $p = $arg0
|
||||
printf "process_rec=0x%lx:\n", (unsigned long)$p
|
||||
printf " pool=0x%lx, pconf=0x%lx\n", \
|
||||
(unsigned long)$p->pool, (unsigned long)$p->pconf
|
||||
end
|
||||
document dump_process_rec
|
||||
Print process_rec info
|
||||
end
|
||||
|
||||
define dump_server_addr_recs
|
||||
set $sa_ = $arg0
|
||||
set $san_ = 0
|
||||
while $sa_
|
||||
### need to call apr_sockaddr_info_getbuf to print ->host_addr properly
|
||||
### which is a PITA since we need a buffer :(
|
||||
printf " addr#%d: vhost=%s -> :%d\n", $san_++, $sa_->virthost, $sa_->host_port
|
||||
set $sa_ = $sa_->next
|
||||
end
|
||||
end
|
||||
document dump_server_addr_recs
|
||||
Print server_addr_rec info
|
||||
end
|
||||
|
||||
|
||||
define dump_server_rec
|
||||
set $s = $arg0
|
||||
printf "name=%s:%d (0x%lx)\n", \
|
||||
$s->server_hostname, $s->port, $s
|
||||
dump_server_addr_recs $s->addrs
|
||||
dump_process_rec($s->process)
|
||||
end
|
||||
document dump_server_rec
|
||||
Print server_rec info
|
||||
end
|
||||
|
||||
define dump_servers
|
||||
set $s = $arg0
|
||||
while $s
|
||||
dump_server_rec($s)
|
||||
printf "\n"
|
||||
set $s = $s->next
|
||||
end
|
||||
end
|
||||
document dump_servers
|
||||
Print server_rec list info
|
||||
end
|
||||
|
||||
define dump_request_tree
|
||||
set $r = $arg0
|
||||
set $i
|
||||
while $r
|
||||
printf "r=(0x%lx): uri=%s, handler=%s, r->main=0x%lx\n", \
|
||||
$r, $r->unparsed_uri, $r->handler ? $r->handler : "(none)", $r->main
|
||||
set $r = $r->main
|
||||
end
|
||||
end
|
||||
|
||||
define dump_scoreboard
|
||||
# Need to reserve size of array first before string literals could be
|
||||
# put in
|
||||
set $status = {0, 1, 2, 3, 4 ,5 ,6 ,7 ,8 ,9 ,10}
|
||||
set $status = {"DEAD", "STARTING", "READY", "BUSY_READ", "BUSY_WRITE", "BUSY_KEEPALIVE", "BUSY_LOG", "BUSY_DNS", "CLOSING", "GRACEFUL", "IDLE_KILL"}
|
||||
set $i = 0
|
||||
while ($i < server_limit)
|
||||
if ap_scoreboard_image->servers[$i][0].pid != 0
|
||||
set $j = 0
|
||||
while ($j < threads_per_child)
|
||||
set $ws = ap_scoreboard_image->servers[$i][$j]
|
||||
printf "pid: %d, tid: 0x%lx, status: %s\n", $ws.pid, $ws.tid, $status[$ws.status]
|
||||
set $j = $j +1
|
||||
end
|
||||
end
|
||||
set $i = $i +1
|
||||
end
|
||||
end
|
||||
document dump_scoreboard
|
||||
Dump the scoreboard
|
||||
end
|
||||
|
||||
define dump_allocator
|
||||
printf "Allocator current_free_index = %d, max_free_index = %d\n", \
|
||||
($arg0)->current_free_index, ($arg0)->max_free_index
|
||||
printf "Allocator free list:\n"
|
||||
set $i = 0
|
||||
set $max =(sizeof $arg0->free)/(sizeof $arg0->free[0])
|
||||
set $kb = 0
|
||||
while $i < $max
|
||||
set $node = $arg0->free[$i]
|
||||
if $node != 0
|
||||
printf " #%2d: ", $i
|
||||
while $node != 0
|
||||
printf "%d, ", ($node->index + 1) << 12
|
||||
set $kb = $kb + (($node->index + 1) << 2)
|
||||
set $node = $node->next
|
||||
end
|
||||
printf "ends.\n"
|
||||
end
|
||||
set $i = $i + 1
|
||||
end
|
||||
printf "Sum of free blocks: %dkiB\n", $kb
|
||||
end
|
||||
document dump_allocator
|
||||
Print status of an allocator and its freelists.
|
||||
end
|
||||
|
||||
define dump_one_pool
|
||||
set $p = $arg0
|
||||
set $size = 0
|
||||
set $free = 0
|
||||
set $nodes = 0
|
||||
set $node = $arg0->active
|
||||
set $done = 0
|
||||
while $done == 0
|
||||
set $size = $size + (($node->index + 1) << 12)
|
||||
set $free = $free + ($node->endp - $node->first_avail)
|
||||
set $nodes = $nodes + 1
|
||||
set $node = $node->next
|
||||
if $node == $arg0->active
|
||||
set $done = 1
|
||||
end
|
||||
end
|
||||
printf "Pool '"
|
||||
if $p->tag
|
||||
printf "%s", $p->tag
|
||||
else
|
||||
printf "no tag"
|
||||
end
|
||||
printf "' [%p]: %d/%d free (%d blocks)\n", $p, $free, $size, $nodes
|
||||
end
|
||||
|
||||
define dump_all_pools
|
||||
if $argc > 0
|
||||
set $root = $arg0
|
||||
else
|
||||
set $root = ap_pglobal
|
||||
end
|
||||
while $root->parent
|
||||
set $root = $root->parent
|
||||
end
|
||||
dump_pool_and_children $root
|
||||
end
|
||||
document dump_all_pools
|
||||
Dump the whole pool hierarchy starting from apr_global_pool. Optionally takes an arbitrary pool as starting parameter.
|
||||
end
|
||||
|
||||
python
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
class DumpPoolAndChilds (gdb.Command):
|
||||
"""Dump the whole pool hierarchy starting from the given pool."""
|
||||
|
||||
def __init__ (self):
|
||||
super (DumpPoolAndChilds, self).__init__ ("dump_pool_and_children", gdb.COMMAND_USER)
|
||||
|
||||
def _allocator_free_blocks(self, alloc):
|
||||
salloc = "%s" % (alloc)
|
||||
if self.total_free_blocks.get(salloc) != None:
|
||||
return self.total_free_blocks[salloc]
|
||||
i = 0
|
||||
dalloc = alloc.dereference()
|
||||
max =(dalloc['free'].type.sizeof)/(dalloc['free'][0].type.sizeof)
|
||||
kb = 0
|
||||
while i < max:
|
||||
node = dalloc['free'][i]
|
||||
if node != 0:
|
||||
while node != 0:
|
||||
noded = node.dereference()
|
||||
kb = kb + ((int(noded['index']) + 1) << 2)
|
||||
node = noded['next']
|
||||
i = i + 1
|
||||
self.total_free_blocks[salloc] = kb
|
||||
return kb
|
||||
|
||||
|
||||
def _dump_one_pool(self, arg):
|
||||
size = 0
|
||||
free = 0
|
||||
nodes = 0
|
||||
darg = arg.dereference()
|
||||
active = darg['active']
|
||||
node = active
|
||||
done = 0
|
||||
while done == 0:
|
||||
noded = node.dereference()
|
||||
size = size + ((int(noded['index']) + 1) << 12)
|
||||
free = free + (noded['endp'] - noded['first_avail'])
|
||||
nodes = nodes + 1
|
||||
node = noded['next']
|
||||
if node == active:
|
||||
done = 1
|
||||
if darg['tag'] != 0:
|
||||
tag = darg['tag'].string()
|
||||
else:
|
||||
tag = "No tag"
|
||||
print("Pool '%s' [%s]: %d/%d free (%d blocks) allocator: %s free blocks in allocator: %i kiB" % (tag, arg, free, size, nodes, darg['allocator'], self._allocator_free_blocks(darg['allocator'])))
|
||||
self.free = self.free + free
|
||||
self.size = self.size + size
|
||||
self.nodes = self.nodes + nodes
|
||||
|
||||
def _dump(self, arg, depth):
|
||||
pool = arg
|
||||
while pool:
|
||||
print("%*c" % (depth * 4 + 1, " "), end="")
|
||||
self._dump_one_pool(pool)
|
||||
if pool['child'] != 0:
|
||||
self._dump(pool['child'], depth + 1)
|
||||
pool = pool['sibling']
|
||||
|
||||
def invoke (self, arg, from_tty):
|
||||
pool = gdb.parse_and_eval(arg)
|
||||
self.free = 0
|
||||
self.size = 0
|
||||
self.nodes = 0
|
||||
self.total_free_blocks = {}
|
||||
self._dump(pool, 0)
|
||||
print("Total %d/%d free (%d blocks)" % (self.free, self.size, self.nodes))
|
||||
sum = 0
|
||||
for key in self.total_free_blocks:
|
||||
sum = sum + self.total_free_blocks[key]
|
||||
print("Total free allocator blocks: %i kiB" % (sum))
|
||||
|
||||
DumpPoolAndChilds ()
|
||||
end
|
||||
document dump_pool_and_children
|
||||
Dump the whole pool hierarchy starting from the given pool.
|
||||
end
|
||||
|
||||
python
|
||||
|
||||
class isValidAddress (gdb.Function):
|
||||
"""Determines if the argument is a valid address."""
|
||||
|
||||
def __init__(self):
|
||||
super(isValidAddress, self).__init__("isValidAddress")
|
||||
|
||||
def invoke(self, address):
|
||||
inf = gdb.inferiors()[0]
|
||||
result = 1
|
||||
try:
|
||||
inf.read_memory(address, 8)
|
||||
except:
|
||||
result = 0
|
||||
return result
|
||||
|
||||
isValidAddress()
|
||||
|
||||
end
|
||||
|
||||
# Set sane defaults for common signals:
|
||||
handle SIGPIPE noprint pass nostop
|
||||
handle SIGUSR1 print pass nostop
|
297
.github/workflows/linux.yml
vendored
Normal file
297
.github/workflows/linux.yml
vendored
Normal file
|
@ -0,0 +1,297 @@
|
|||
name: Linux
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "*" ]
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- STATUS
|
||||
- CHANGES
|
||||
- changes-entries/*
|
||||
tags:
|
||||
- 2.*
|
||||
pull_request:
|
||||
branches: [ "trunk", "2.4.x" ]
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- STATUS
|
||||
- CHANGES
|
||||
- changes-entries/*
|
||||
|
||||
env:
|
||||
MARGS: "-j2"
|
||||
CFLAGS: "-g"
|
||||
# This will need updating as the ubuntu-latest image changes:
|
||||
PHP_FPM: "/usr/sbin/php-fpm8.1"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Empty APLOGNO() test
|
||||
env: |
|
||||
SKIP_TESTING=1
|
||||
TEST_LOGNO=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Default
|
||||
# -------------------------------------------------------------------------
|
||||
- name: All-static modules
|
||||
config: --enable-mods-static=reallyall
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Prefork MPM, all-modules (except cgid)
|
||||
config: --enable-mods-shared=reallyall --with-mpm=prefork --disable-cgid
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Worker MPM, all-modules
|
||||
config: --enable-mods-shared=reallyall --with-mpm=worker
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Shared MPMs, all-modules
|
||||
config: --enable-mods-shared=reallyall --enable-mpms-shared=all
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Event MPM, all-modules, mod_cgid fdpassing
|
||||
config: --enable-mods-shared=reallyall --with-mpm=event --disable-cgi --enable-cgid-fdpassing
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Event MPM, all-modules, mod_cgid w/o fdpassing
|
||||
config: --enable-mods-shared=reallyall --with-mpm=event --disable-cgi
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Default, all-modules + install
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
TEST_INSTALL=1
|
||||
APACHE_TEST_EXTRA_ARGS=-v
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Default, all-modules, random test order
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
TEST_ARGS=-order=random
|
||||
# -------------------------------------------------------------------------
|
||||
- name: GCC 12 maintainer-mode w/-Werror, install + VPATH
|
||||
config: --enable-mods-shared=reallyall --enable-maintainer-mode
|
||||
notest-cflags: -Werror -O2
|
||||
env: |
|
||||
CC=gcc-12
|
||||
TEST_VPATH=1
|
||||
TEST_INSTALL=1
|
||||
SKIP_TESTING=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: All-modules, APR 1.7.4, APR-util 1.6.3
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
APR_VERSION=1.7.4
|
||||
APU_VERSION=1.6.3
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
# -------------------------------------------------------------------------
|
||||
- name: APR 1.8.x, APR-util 1.7.x
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
APR_VERSION=1.8.x
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Pool-debug
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APR_CONFIG="--enable-pool-debug"
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Shared MPMs (event), pool-debug, SSL/TLS variants
|
||||
config: --enable-mods-shared=reallyall --enable-mpms-shared=all --with-mpm=event
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APR_CONFIG="--enable-pool-debug"
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
TEST_SSL=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Shared MPMs (worker), pool-debug, SSL/TLS variants
|
||||
config: --enable-mods-shared=reallyall --enable-mpms-shared=all --with-mpm=worker
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APR_CONFIG="--enable-pool-debug"
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
TEST_SSL=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: Shared MPMs (prefork), pool-debug, SSL/TLS variants
|
||||
config: --enable-mods-shared=reallyall --enable-mpms-shared=all --with-mpm=prefork
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APR_CONFIG="--enable-pool-debug"
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
TEST_SSL=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: litmus WebDAV tests
|
||||
config: --enable-dav --enable-dav-fs
|
||||
env: |
|
||||
LITMUS=1
|
||||
TESTS="t/modules/dav.t"
|
||||
pkgs: litmus
|
||||
# -------------------------------------------------------------------------
|
||||
- name: APR 1.7.4, APR-util 1.6.3, LDAP
|
||||
config: --enable-mods-shared=reallyall
|
||||
pkgs: ldap-utils
|
||||
env: |
|
||||
APR_VERSION=1.7.4
|
||||
APU_VERSION=1.6.3
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
TEST_LDAP=1
|
||||
TEST_ARGS="-defines LDAP"
|
||||
TESTS="t/modules/"
|
||||
# -------------------------------------------------------------------------
|
||||
- name: APR 1.7.x, APR-util 1.7.x, LDAP
|
||||
config: --enable-mods-shared=reallyall
|
||||
pkgs: ldap-utils
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_MALLOC=1
|
||||
TEST_LDAP=1
|
||||
TEST_ARGS="-defines LDAP"
|
||||
TESTS="t/modules/"
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
### TODO: if: *condition_not_24x
|
||||
- name: APR trunk thread debugging
|
||||
config: --enable-mods-shared=reallyall --with-mpm=event
|
||||
env: |
|
||||
APR_VERSION=trunk
|
||||
APR_CONFIG="--with-crypto --enable-thread-debug"
|
||||
# -------------------------------------------------------------------------
|
||||
- name: ASan
|
||||
notest-cflags: -ggdb -fsanitize=address -fno-sanitize-recover=address -fno-omit-frame-pointer
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_ASAN=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: ASan, pool-debug
|
||||
notest-cflags: -ggdb -fsanitize=address -fno-sanitize-recover=address -fno-omit-frame-pointer
|
||||
config: --enable-mods-shared=reallyall
|
||||
env: |
|
||||
APR_VERSION=1.7.x
|
||||
APR_CONFIG="--enable-pool-debug"
|
||||
APU_VERSION=1.7.x
|
||||
APU_CONFIG="--with-crypto --with-ldap"
|
||||
TEST_ASAN=1
|
||||
CLEAR_CACHE=1
|
||||
# -------------------------------------------------------------------------
|
||||
- name: HTTP/2 test suite
|
||||
config: --enable-mods-shared=reallyall --with-mpm=event --enable-mpms-shared=all
|
||||
pkgs: curl python3-pytest nghttp2-client python3-cryptography python3-requests python3-multipart python3-filelock python3-websockets
|
||||
env: |
|
||||
APR_VERSION=1.7.4
|
||||
APU_VERSION=1.6.3
|
||||
APU_CONFIG="--with-crypto"
|
||||
NO_TEST_FRAMEWORK=1
|
||||
TEST_INSTALL=1
|
||||
TEST_H2=1
|
||||
TEST_CORE=1
|
||||
TEST_PROXY=1
|
||||
# -------------------------------------------------------------------------
|
||||
### TODO: if: *condition_not_24x
|
||||
### TODO: pebble install is broken.
|
||||
# - name: ACME test suite
|
||||
# config: --enable-mods-shared=reallyall --with-mpm=event --enable-mpms-shared=event
|
||||
# pkgs: >-
|
||||
# python3-pytest nghttp2-client python3-cryptography python3-requests python3-filelock
|
||||
# golang-1.17 curl
|
||||
# env: |
|
||||
# APR_VERSION=1.7.4
|
||||
# APU_VERSION=1.6.3
|
||||
# APU_CONFIG="--with-crypto"
|
||||
# GOROOT=/usr/lib/go-1.17
|
||||
# NO_TEST_FRAMEWORK=1
|
||||
# TEST_INSTALL=1
|
||||
# TEST_MD=1
|
||||
# -------------------------------------------------------------------------
|
||||
### TODO: if: *condition_not_24x
|
||||
# -------------------------------------------------------------------------
|
||||
### TODO if: *condition_not_24x
|
||||
### TODO: Fails because :i386 packages are not being found.
|
||||
# - name: i386 Shared MPMs, most modules, maintainer-mode w/-Werror
|
||||
# config: --enable-mods-shared=reallyall --disable-xml2enc --disable-proxy-html --enable-mpms-shared=all --enable-maintainer-mode
|
||||
# pkgs: >-
|
||||
# cpanminus libc6-dev-i386 gcc-multilib libexpat1-dev:i386 libssl-dev:i386
|
||||
# lib32z1-dev libbrotli-dev:i386 libpcre2-dev:i386 libldap2-dev:i386 libtool-bin
|
||||
# perl-doc libapr1-dev libbrotli-dev:i386
|
||||
# env: |
|
||||
# PKG_CONFIG_PATH="/usr/lib/i386-linux-gnu/pkgconfig"
|
||||
# NOTEST_CFLAGS="-Werror"
|
||||
# CC="gcc -m32"
|
||||
# APR_VERSION=1.7.3
|
||||
# APU_VERSION=1.6.3
|
||||
# APU_CONFIG="--with-crypto --with-ldap"
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
NOTEST_CFLAGS: ${{ matrix.notest-cflags }}
|
||||
CONFIG: ${{ matrix.config }}
|
||||
name: ${{ matrix.name }}
|
||||
steps:
|
||||
# JOBID is used in the cache keys, created here as a hash of all
|
||||
# properties of the environment, including the image OS version,
|
||||
# compiler flags and any job-specific properties.
|
||||
- name: Set environment variables
|
||||
run: |
|
||||
echo "${{ matrix.env }}" >> $GITHUB_ENV
|
||||
echo JOBID=`echo "OS=$ImageOS ${{ matrix.notest-cflags }} ${{ matrix.env }} ${{ matrix.config }}" \
|
||||
| md5sum - | sed 's/ .*//'` >> $GITHUB_ENV
|
||||
# https://github.com/actions/runner-images/issues/9491#issuecomment-1989718917
|
||||
- name: Workaround ASAN issue in Ubuntu 22.04
|
||||
run: sudo sysctl vm.mmap_rnd_bits=28
|
||||
- name: apt refresh
|
||||
run: sudo apt-get -o Acquire::Retries=5 update
|
||||
- name: Install prerequisites
|
||||
run: sudo apt-get install -o Acquire::Retries=5
|
||||
cpanminus libtool-bin libapr1-dev libaprutil1-dev
|
||||
liblua5.3-dev libbrotli-dev libcurl4-openssl-dev
|
||||
libnghttp2-dev libjansson-dev libpcre2-dev gdb
|
||||
perl-doc libsasl2-dev ${{ matrix.pkgs }}
|
||||
- uses: actions/checkout@v4
|
||||
- name: Cache installed libraries
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/root
|
||||
key: cache-libs-${{ env.JOBID }}
|
||||
- name: Cache CPAN modules
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/perl5
|
||||
key: cache-cpan-${{ env.JOBID }}
|
||||
- name: Configure environment
|
||||
run: ./test/travis_before_linux.sh
|
||||
timeout-minutes: 15
|
||||
- uses: actions/upload-artifact@v4
|
||||
if: failure()
|
||||
with:
|
||||
name: config.log-${{ env.JOBID }}
|
||||
path: |
|
||||
/home/runner/build/**/config.log
|
||||
- name: Build and test
|
||||
run: ./test/travis_run_linux.sh
|
||||
- uses: actions/upload-artifact@v4
|
||||
if: failure()
|
||||
with:
|
||||
name: error_log-${{ env.JOBID }}
|
||||
path: |
|
||||
**/config.log
|
||||
test/perl-framework/t/logs/error_log
|
63
.github/workflows/windows.yml
vendored
Normal file
63
.github/workflows/windows.yml
vendored
Normal file
|
@ -0,0 +1,63 @@
|
|||
name: Windows
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "*" ]
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- STATUS
|
||||
- CHANGES
|
||||
- changes-entries/*
|
||||
pull_request:
|
||||
branches: [ "trunk", "2.4.x" ]
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- STATUS
|
||||
- CHANGES
|
||||
- changes-entries/*
|
||||
|
||||
jobs:
|
||||
build:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- name: Default
|
||||
triplet: x64-windows
|
||||
arch: x64
|
||||
build-type: Debug
|
||||
generator: "Ninja"
|
||||
|
||||
runs-on: windows-latest
|
||||
timeout-minutes: 30
|
||||
name: ${{ matrix.name }}
|
||||
env:
|
||||
VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite"
|
||||
steps:
|
||||
- name: Export GitHub Actions cache environment variables
|
||||
uses: actions/github-script@v7
|
||||
with:
|
||||
script: |
|
||||
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
|
||||
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
|
||||
|
||||
- name: Install dependencies
|
||||
run: vcpkg install --triplet ${{ matrix.triplet }} apr[private-headers] apr-util pcre2 openssl
|
||||
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Configure CMake
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -arch=${{ matrix.arch }}
|
||||
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{ matrix.build-type }} ^
|
||||
-G "${{ matrix.generator }}" ^
|
||||
-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake ^
|
||||
-DAPR_INCLUDE_DIR=C:/vcpkg/installed/${{ matrix.triplet }}/include ^
|
||||
"-DAPR_LIBRARIES=C:/vcpkg/installed/${{ matrix.triplet }}/lib/libapr-1.lib;C:/vcpkg/installed/${{ matrix.triplet }}/lib/libaprutil-1.lib"
|
||||
|
||||
- name: Build
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -arch=${{ matrix.arch }}
|
||||
cmake --build ${{github.workspace}}/build --config ${{ matrix.build-type }}
|
370
.gitignore
vendored
Normal file
370
.gitignore
vendored
Normal file
|
@ -0,0 +1,370 @@
|
|||
# global
|
||||
.deps
|
||||
.libs
|
||||
*.swp
|
||||
*.o
|
||||
*.a
|
||||
*.lo
|
||||
*.la
|
||||
*.slo
|
||||
*.so
|
||||
*.vcproj
|
||||
*.vcproj.*
|
||||
*.x
|
||||
*.aps
|
||||
*.plg
|
||||
*.dep
|
||||
*.rc
|
||||
*.stc
|
||||
*.stt
|
||||
*.sto
|
||||
*.mak
|
||||
Makefile
|
||||
modules.mk
|
||||
BuildLog.htm
|
||||
Debug
|
||||
Release
|
||||
|
||||
# /
|
||||
/config.nice
|
||||
/configure
|
||||
/missing
|
||||
/install-sh
|
||||
/mkinstalldirs
|
||||
/aclocal.m4
|
||||
/generated_lists
|
||||
/buildmk.stamp
|
||||
/config.log
|
||||
/libtool
|
||||
/shlibtool
|
||||
/config.status
|
||||
/modules.c
|
||||
/config.cache
|
||||
/httpd
|
||||
/httpd.exe
|
||||
/LibD
|
||||
/LibR
|
||||
/Apache.suo
|
||||
/Apache.ncb
|
||||
/Apache.opt
|
||||
/apachecore.dll
|
||||
/Apache.sln
|
||||
/autom4te.cache
|
||||
/httpd.spec
|
||||
/tags
|
||||
/TAGS
|
||||
/*.kdev4
|
||||
/.kdev_include_paths
|
||||
/.cproject
|
||||
/.project
|
||||
|
||||
# /built/
|
||||
/built/
|
||||
|
||||
# /cmake-build-debug/
|
||||
/cmake-build-debug/
|
||||
|
||||
# /build/
|
||||
/build/rules.mk
|
||||
/build/config_vars.mk
|
||||
/build/apr_common.m4
|
||||
/build/find_apr.m4
|
||||
/build/find_apu.m4
|
||||
/build/ltconfig
|
||||
/build/ltmain.sh
|
||||
/build/PrintPath
|
||||
/build/config.sub
|
||||
/build/config.guess
|
||||
/build/config_vars.sh
|
||||
|
||||
# /build/pkg/
|
||||
/build/pkg/pkginfo
|
||||
|
||||
# /build/win32/
|
||||
!/build/win32/httpd.rc
|
||||
|
||||
# /docs/
|
||||
/docs/dox
|
||||
|
||||
# /docs/conf/
|
||||
/docs/conf/httpd-std.conf
|
||||
/docs/conf/ssl-std.conf
|
||||
/docs/conf/httpd.conf
|
||||
|
||||
# /docs/conf/extra/
|
||||
/docs/conf/extra/*.conf
|
||||
|
||||
# /docs/log-message-tags/
|
||||
/docs/log-message-tags/list
|
||||
|
||||
# /docs/manual/
|
||||
/docs/manual/_chm
|
||||
/docs/manual/_off
|
||||
/docs/manual/_tools
|
||||
/docs/manual/_dist
|
||||
/docs/manual/build
|
||||
/docs/manual/*.tex
|
||||
/docs/manual/*.aux
|
||||
/docs/manual/*.out
|
||||
/docs/manual/*.log
|
||||
/docs/manual/*.pdf
|
||||
/docs/manual/*.toc
|
||||
/docs/manual/.outdated*
|
||||
|
||||
# /docs/manual/developer/
|
||||
/docs/manual/developer/*.tex
|
||||
/docs/manual/developer/*.aux
|
||||
|
||||
# /docs/manual/faq/
|
||||
/docs/manual/faq/*.tex
|
||||
/docs/manual/faq/*.aux
|
||||
|
||||
# /docs/manual/howto/
|
||||
/docs/manual/howto/*.aux
|
||||
/docs/manual/howto/*.tex
|
||||
/docs/manual/howto/Working-Copy.txt
|
||||
|
||||
# /docs/manual/misc/
|
||||
/docs/manual/misc/*.tex
|
||||
/docs/manual/misc/*.aux
|
||||
|
||||
# /docs/manual/mod/
|
||||
/docs/manual/mod/*.tex
|
||||
/docs/manual/mod/*.aux
|
||||
/docs/manual/mod/.translated.*
|
||||
|
||||
# /docs/manual/platform/
|
||||
/docs/manual/platform/*.tex
|
||||
/docs/manual/platform/*.aux
|
||||
|
||||
# /docs/manual/programs/
|
||||
/docs/manual/programs/*.tex
|
||||
/docs/manual/programs/*.aux
|
||||
|
||||
# /docs/manual/rewrite/
|
||||
/docs/manual/rewrite/_chm
|
||||
/docs/manual/rewrite/_off
|
||||
/docs/manual/rewrite/_tools
|
||||
/docs/manual/rewrite/_dist
|
||||
/docs/manual/rewrite/build
|
||||
/docs/manual/rewrite/*.tex
|
||||
/docs/manual/rewrite/*.aux
|
||||
/docs/manual/rewrite/*.out
|
||||
/docs/manual/rewrite/*.log
|
||||
/docs/manual/rewrite/*.pdf
|
||||
/docs/manual/rewrite/*.toc
|
||||
/docs/manual/rewrite/.outdated*
|
||||
|
||||
# /docs/manual/ssl/
|
||||
/docs/manual/ssl/*.tex
|
||||
/docs/manual/ssl/*.aux
|
||||
|
||||
# /docs/manual/style/
|
||||
/docs/manual/style/_generated
|
||||
|
||||
# /docs/manual/vhosts/
|
||||
/docs/manual/vhosts/*.tex
|
||||
/docs/manual/vhosts/*.aux
|
||||
|
||||
# /include/
|
||||
/include/ap_config_auto.h
|
||||
/include/ap_config_auto.h.in
|
||||
/include/ap_config_layout.h
|
||||
/include/ap_ldap.h
|
||||
/include/mod_cgi.h
|
||||
/include/mod_dav.h
|
||||
/include/mod_include.h
|
||||
/include/mod_proxy.h
|
||||
/include/mod_so.h
|
||||
/include/mpm.h
|
||||
/include/mpm_default.h
|
||||
/include/os.h
|
||||
|
||||
# /modules/aaa/
|
||||
|
||||
# /modules/apreq/
|
||||
|
||||
# /modules/arch/
|
||||
|
||||
# /modules/arch/unix/
|
||||
|
||||
# /modules/arch/win32/
|
||||
|
||||
# /modules/cache/
|
||||
|
||||
# /modules/cluster/
|
||||
|
||||
# /modules/core/
|
||||
|
||||
# /modules/core/test/
|
||||
/modules/core/test/out
|
||||
|
||||
# /modules/database/
|
||||
|
||||
# /modules/dav/
|
||||
|
||||
# /modules/dav/fs/
|
||||
|
||||
# /modules/dav/lock/
|
||||
|
||||
# /modules/dav/main/
|
||||
|
||||
# /modules/debugging/
|
||||
|
||||
# /modules/echo/
|
||||
|
||||
# /modules/examples/
|
||||
|
||||
# /modules/experimental/
|
||||
|
||||
# /modules/filters/
|
||||
|
||||
# /modules/generators/
|
||||
|
||||
# /modules/http/
|
||||
|
||||
# /modules/http2/
|
||||
|
||||
# /modules/ldap/
|
||||
|
||||
# /modules/loggers/
|
||||
|
||||
# /modules/lua/
|
||||
|
||||
# /modules/lua/test/
|
||||
/modules/lua/test/cycle
|
||||
/modules/lua/test/httpd.conf
|
||||
|
||||
# /modules/mappers/
|
||||
|
||||
# /modules/md/
|
||||
/modules/md/a2md
|
||||
|
||||
# /modules/metadata/
|
||||
|
||||
# /modules/proxy/
|
||||
|
||||
# /modules/proxy/balancers/
|
||||
|
||||
# /modules/proxy/examples/
|
||||
|
||||
# /modules/session/
|
||||
|
||||
# /modules/slotmem/
|
||||
|
||||
# /modules/ssl/
|
||||
|
||||
# /modules/test/
|
||||
|
||||
# /os/
|
||||
|
||||
# /os/bs2000/
|
||||
|
||||
# /os/os2/
|
||||
|
||||
# /os/unix/
|
||||
|
||||
# /os/win32/
|
||||
/os/win32/*.mdp
|
||||
/os/win32/*.ncb
|
||||
/os/win32/*.opt
|
||||
/os/win32/*.dsw
|
||||
/os/win32/mod_*D
|
||||
/os/win32/mod_*R
|
||||
|
||||
# /server/
|
||||
/server/test_char.h
|
||||
/server/gen_test_char
|
||||
/server/gen_test_char.exe
|
||||
/server/gen_test_char.exe.manifest
|
||||
/server/export_files
|
||||
/server/exports.c
|
||||
/server/export_vars.h
|
||||
/server/ApacheCoreOS2.def
|
||||
/server/httpd.exp
|
||||
/server/buildmarked.c
|
||||
|
||||
# /server/mpm/
|
||||
|
||||
# /server/mpm/event/
|
||||
|
||||
# /server/mpm/motorz/
|
||||
|
||||
# /server/mpm/mpmt_os2/
|
||||
|
||||
# /server/mpm/prefork/
|
||||
|
||||
# /server/mpm/simple/
|
||||
|
||||
# /server/mpm/winnt/
|
||||
|
||||
# /server/mpm/worker/
|
||||
|
||||
# /srclib/
|
||||
/srclib/pth
|
||||
/srclib/apr
|
||||
/srclib/apr-util
|
||||
/srclib/apr-iconv
|
||||
/srclib/distcache
|
||||
/srclib/lua
|
||||
/srclib/pcre
|
||||
/srclib/openssl
|
||||
/srclib/zlib
|
||||
|
||||
# /support/
|
||||
/support/rotatelogs
|
||||
/support/htpasswd
|
||||
/support/htdbm
|
||||
/support/htdigest
|
||||
/support/htcacheclean
|
||||
/support/unescape
|
||||
/support/inc2shtml
|
||||
/support/httpd_monitor
|
||||
/support/suexec
|
||||
/support/logresolve
|
||||
/support/ab
|
||||
/support/apxs
|
||||
/support/apachectl
|
||||
/support/checkgid
|
||||
/support/dbmmanage
|
||||
/support/envvars-std
|
||||
/support/log_server_status
|
||||
/support/logresolve.pl
|
||||
/support/split-logfile
|
||||
/support/phf_abuse_log.cgi
|
||||
/support/httxt2dbm
|
||||
/support/fcgistarter
|
||||
/support/firehose
|
||||
/support/*.exe
|
||||
|
||||
# /support/win32/
|
||||
!/support/win32/ApacheMonitor.rc
|
||||
/support/win32/ApacheMonitorVer.rc
|
||||
|
||||
# /test/
|
||||
/test/a.out
|
||||
/test/time-FCNTL
|
||||
/test/time-FLOCK
|
||||
/test/time-SYSVSEM
|
||||
/test/time-SYSVSEM2
|
||||
/test/time-PTHREAD
|
||||
/test/time-USLOCK
|
||||
/test/zb
|
||||
/test/test-writev
|
||||
/test/test_date
|
||||
/test/test_select
|
||||
/test/dbu
|
||||
/test/sni
|
||||
/test/httpdunit
|
||||
/test/httpdunit.cases
|
||||
|
||||
# /test/unit/
|
||||
/test/unit/*.tests
|
||||
|
||||
# Intellij
|
||||
/.idea/
|
||||
|
||||
test/gen
|
||||
test/pyhttpd/config.ini
|
||||
__pycache__
|
||||
|
244
ABOUT_APACHE
Normal file
244
ABOUT_APACHE
Normal file
|
@ -0,0 +1,244 @@
|
|||
|
||||
The Apache HTTP Server Project
|
||||
|
||||
http://httpd.apache.org/
|
||||
|
||||
The Apache HTTP Server Project is a collaborative software development effort
|
||||
aimed at creating a robust, commercial-grade, featureful, and freely-available
|
||||
source code implementation of an HTTP (Web) server. The project is jointly
|
||||
managed by a group of volunteers located around the world, using the Internet
|
||||
and the Web to communicate, plan, and develop the server and its related
|
||||
documentation. In addition, hundreds of users have contributed ideas, code,
|
||||
and documentation to the project.
|
||||
|
||||
This file is intended to briefly describe the history of the Apache Group (as
|
||||
it was called in the early days), recognize the many contributors, and explain
|
||||
how you can join the fun too.
|
||||
|
||||
In February of 1995, the most popular server software on the Web was the
|
||||
public domain HTTP daemon developed by Rob McCool at the National Center
|
||||
for Supercomputing Applications, University of Illinois, Urbana-Champaign.
|
||||
However, development of that httpd had stalled after Rob left NCSA in
|
||||
mid-1994, and many webmasters had developed their own extensions and bug
|
||||
fixes that were in need of a common distribution. A small group of these
|
||||
webmasters, contacted via private e-mail, gathered together for the purpose
|
||||
of coordinating their changes (in the form of "patches"). Brian Behlendorf
|
||||
and Cliff Skolnick put together a mailing list, shared information space,
|
||||
and logins for the core developers on a machine in the California Bay Area,
|
||||
with bandwidth and diskspace donated by HotWired and Organic Online.
|
||||
By the end of February, eight core contributors formed the foundation
|
||||
of the original Apache Group:
|
||||
|
||||
Brian Behlendorf Roy T. Fielding Rob Hartill
|
||||
David Robinson Cliff Skolnick Randy Terbush
|
||||
Robert S. Thau Andrew Wilson
|
||||
|
||||
with additional contributions from
|
||||
|
||||
Eric Hagberg Frank Peters Nicolas Pioch
|
||||
|
||||
Using NCSA httpd 1.3 as a base, we added all of the published bug fixes
|
||||
and worthwhile enhancements we could find, tested the result on our own
|
||||
servers, and made the first official public release (0.6.2) of the Apache
|
||||
server in April 1995. By coincidence, NCSA restarted their own development
|
||||
during the same period, and Brandon Long and Beth Frank of the NCSA Server
|
||||
Development Team joined the list in March as honorary members so that the
|
||||
two projects could share ideas and fixes.
|
||||
|
||||
The early Apache server was a big hit, but we all knew that the codebase
|
||||
needed a general overhaul and redesign. During May-June 1995, while
|
||||
Rob Hartill and the rest of the group focused on implementing new features
|
||||
for 0.7.x (like pre-forked child processes) and supporting the rapidly growing
|
||||
Apache user community, Robert Thau designed a new server architecture
|
||||
(code-named Shambhala) which included a modular structure and API for better
|
||||
extensibility, pool-based memory allocation, and an adaptive pre-forking
|
||||
process model. The group switched to this new server base in July and added
|
||||
the features from 0.7.x, resulting in Apache 0.8.8 (and its brethren)
|
||||
in August.
|
||||
|
||||
After extensive beta testing, many ports to obscure platforms, a new set
|
||||
of documentation (by David Robinson), and the addition of many features
|
||||
in the form of our standard modules, Apache 1.0 was released on
|
||||
December 1, 1995.
|
||||
|
||||
Less than a year after the group was formed, the Apache server passed
|
||||
NCSA's httpd as the #1 server on the Internet.
|
||||
|
||||
The survey by Netcraft (http://www.netcraft.com/survey/) shows that Apache
|
||||
is today more widely used than all other web servers combined.
|
||||
|
||||
============================================================================
|
||||
|
||||
The current project management committee of the Apache HTTP Server
|
||||
project (as of March, 2011) is:
|
||||
|
||||
Aaron Bannert André Malo Astrid Stolper
|
||||
Ben Laurie Bojan Smojver Brad Nicholes
|
||||
Brian Havard Brian McCallister Chris Darroch
|
||||
Chuck Murcko Colm MacCárthaigh Dan Poirier
|
||||
Dirk-Willem van Gulik Doug MacEachern
|
||||
Eric Covener Erik Abele Graham Dumpleton
|
||||
Graham Leggett Greg Ames Greg Stein
|
||||
Gregory Trubetskoy Guenter Knauf Issac Goldstand
|
||||
Jeff Trawick Jim Gallacher Jim Jagielski
|
||||
Joe Orton Joe Schaefer Joshua Slive
|
||||
Justin Erenkrantz Ken Coar Lars Eilebrecht
|
||||
Manoj Kasichainula Marc Slemko Mark J. Cox
|
||||
Martin Kraemer Maxime Petazzoni Nick Kew
|
||||
Nicolas Lehuen Noirin Shirley Paul Querna
|
||||
Philip M. Gollucci Ralf S. Engelschall Randy Kobes
|
||||
Rasmus Lerdorf Rich Bowen Roy T. Fielding
|
||||
Rüdiger Plüm Sander Striker Sander Temm
|
||||
Stefan Fritsch Tony Stevenson Victor J. Orlikowski
|
||||
Wilfredo Sanchez William A. Rowe Jr. Yoshiki Hayashi
|
||||
|
||||
Other major contributors
|
||||
|
||||
Howard Fear (mod_include), Florent Guillaume (language negotiation),
|
||||
Koen Holtman (rewrite of mod_negotiation),
|
||||
Kevin Hughes (creator of all those nifty icons),
|
||||
Brandon Long and Beth Frank (NCSA Server Development Team, post-1.3),
|
||||
Ambarish Malpani (Beginning of the NT port),
|
||||
Rob McCool (original author of the NCSA httpd 1.3),
|
||||
Paul Richards (convinced the group to use remote CVS after 1.0),
|
||||
Garey Smiley (OS/2 port), Henry Spencer (author of the regex library).
|
||||
|
||||
Many 3rd-party modules, frequently used and recommended, are also
|
||||
freely-available and linked from the related projects page:
|
||||
<http://modules.apache.org/>, and their authors frequently
|
||||
contribute ideas, patches, and testing.
|
||||
|
||||
Hundreds of people have made individual contributions to the Apache
|
||||
project. Patch contributors are listed in the CHANGES file.
|
||||
|
||||
============================================================================
|
||||
|
||||
How to become involved in the Apache project
|
||||
|
||||
There are several levels of contributing. If you just want to send
|
||||
in an occasional suggestion/fix, then you can just use the bug reporting
|
||||
form at <http://httpd.apache.org/bug_report.html>. You can also subscribe
|
||||
to the announcements mailing list (announce-subscribe@httpd.apache.org) which
|
||||
we use to broadcast information about new releases, bugfixes, and upcoming
|
||||
events. There's a lot of information about the development process (much of
|
||||
it in serious need of updating) to be found at <http://httpd.apache.org/dev/>.
|
||||
|
||||
If you'd like to become an active contributor to the Apache project (the
|
||||
group of volunteers who vote on changes to the distributed server), then
|
||||
you need to start by subscribing to the dev@httpd.apache.org mailing list.
|
||||
One warning though: traffic is high, 1000 to 1500 messages/month.
|
||||
To subscribe to the list, send an email to dev-subscribe@httpd.apache.org.
|
||||
We recommend reading the list for a while before trying to jump in to
|
||||
development.
|
||||
|
||||
NOTE: The developer mailing list (dev@httpd.apache.org) is not
|
||||
a user support forum; it is for people actively working on development
|
||||
of the server code and documentation, and for planning future
|
||||
directions. If you have user/configuration questions, send them
|
||||
to users list <http://httpd.apache.org/userslist> or to the USENET
|
||||
newsgroup "comp.infosystems.www.servers.unix".or for windows users,
|
||||
the newsgroup "comp.infosystems.www.servers.ms-windows".
|
||||
|
||||
There is a core group of contributors (informally called the "core")
|
||||
which was formed from the project founders and is augmented from time
|
||||
to time when core members nominate outstanding contributors and the
|
||||
rest of the core members agree. The core group focus is more on
|
||||
"business" issues and limited-circulation things like security problems
|
||||
than on mainstream code development. The term "The Apache Group"
|
||||
technically refers to this core of project contributors.
|
||||
|
||||
The Apache project is a meritocracy--the more work you have done, the more
|
||||
you are allowed to do. The group founders set the original rules, but
|
||||
they can be changed by vote of the active members. There is a group
|
||||
of people who have logins on our server (apache.org) and access to the
|
||||
svn repository. Everyone has access to the svn snapshots. Changes to
|
||||
the code are proposed on the mailing list and usually voted on by active
|
||||
members--three +1 (yes votes) and no -1 (no votes, or vetoes) are needed
|
||||
to commit a code change during a release cycle; docs are usually committed
|
||||
first and then changed as needed, with conflicts resolved by majority vote.
|
||||
|
||||
Our primary method of communication is our mailing list. Approximately 40
|
||||
messages a day flow over the list, and are typically very conversational in
|
||||
tone. We discuss new features to add, bug fixes, user problems, developments
|
||||
in the web server community, release dates, etc. The actual code development
|
||||
takes place on the developers' local machines, with proposed changes
|
||||
communicated using a patch (output of a unified "diff -u oldfile newfile"
|
||||
command), and committed to the source repository by one of the core
|
||||
developers using remote svn. Anyone on the mailing list can vote on a
|
||||
particular issue, but we only count those made by active members or people
|
||||
who are known to be experts on that part of the server. Vetoes must be
|
||||
accompanied by a convincing explanation.
|
||||
|
||||
New members of the Apache Group are added when a frequent contributor is
|
||||
nominated by one member and unanimously approved by the voting members.
|
||||
In most cases, this "new" member has been actively contributing to the
|
||||
group's work for over six months, so it's usually an easy decision.
|
||||
|
||||
The above describes our past and current (as of July 2000) guidelines,
|
||||
which will probably change over time as the membership of the group
|
||||
changes and our development/coordination tools improve.
|
||||
|
||||
============================================================================
|
||||
|
||||
The Apache Software Foundation (www.apache.org)
|
||||
|
||||
The Apache Software Foundation exists to provide organizational, legal,
|
||||
and financial support for the Apache open-source software projects.
|
||||
Founded in June 1999 by the Apache Group, the Foundation has been
|
||||
incorporated as a membership-based, not-for-profit corporation in order
|
||||
to ensure that the Apache projects continue to exist beyond the participation
|
||||
of individual volunteers, to enable contributions of intellectual property
|
||||
and funds on a sound basis, and to provide a vehicle for limiting legal
|
||||
exposure while participating in open-source software projects.
|
||||
|
||||
You are invited to participate in The Apache Software Foundation. We welcome
|
||||
contributions in many forms. Our membership consists of those individuals
|
||||
who have demonstrated a commitment to collaborative open-source software
|
||||
development through sustained participation and contributions within the
|
||||
Foundation's projects. Many people and companies have contributed towards
|
||||
the success of the Apache projects.
|
||||
|
||||
============================================================================
|
||||
|
||||
Why The Apache HTTP Server Is Free
|
||||
|
||||
Apache HTTP Server exists to provide a robust and commercial-grade reference
|
||||
implementation of the HTTP protocol. It must remain a platform upon which
|
||||
individuals and institutions can build reliable systems, both for
|
||||
experimental purposes and for mission-critical purposes. We believe the
|
||||
tools of online publishing should be in the hands of everyone, and
|
||||
software companies should make their money providing value-added services
|
||||
such as specialized modules and support, amongst other things. We realize
|
||||
that it is often seen as an economic advantage for one company to "own" a
|
||||
market - in the software industry that means to control tightly a
|
||||
particular conduit such that all others must pay. This is typically done
|
||||
by "owning" the protocols through which companies conduct business, at the
|
||||
expense of all those other companies. To the extent that the protocols of
|
||||
the World Wide Web remain "unowned" by a single company, the Web will
|
||||
remain a level playing field for companies large and small. Thus,
|
||||
"ownership" of the protocol must be prevented, and the existence of a
|
||||
robust reference implementation of the protocol, available absolutely for
|
||||
free to all companies, is a tremendously good thing.
|
||||
|
||||
Furthermore, Apache httpd is an organic entity; those who benefit from it
|
||||
by using it often contribute back to it by providing feature enhancements,
|
||||
bug fixes, and support for others in public newsgroups. The amount of
|
||||
effort expended by any particular individual is usually fairly light, but
|
||||
the resulting product is made very strong. This kind of community can
|
||||
only happen with freeware--when someone pays for software, they usually
|
||||
aren't willing to fix its bugs. One can argue, then, that Apache's
|
||||
strength comes from the fact that it's free, and if it were made "not
|
||||
free" it would suffer tremendously, even if that money were spent on a
|
||||
real development team.
|
||||
|
||||
We want to see Apache httpd used very widely--by large companies, small
|
||||
companies, research institutions, schools, individuals, in the intranet
|
||||
environment, everywhere--even though this may mean that companies who
|
||||
could afford commercial software, and would pay for it without blinking,
|
||||
might get a "free ride" by using Apache httpd. We would even be happy if
|
||||
some commercial software companies completely dropped their own HTTP server
|
||||
development plans and used Apache httpd as a base, with the proper attributions
|
||||
as described in the LICENSE file.
|
||||
|
||||
Thanks for using Apache HTTP Server!
|
||||
|
3052
Apache-apr2.dsw
Normal file
3052
Apache-apr2.dsw
Normal file
File diff suppressed because it is too large
Load diff
3601
Apache.dsw
Normal file
3601
Apache.dsw
Normal file
File diff suppressed because it is too large
Load diff
97
BuildAll.dsp
Normal file
97
BuildAll.dsp
Normal file
|
@ -0,0 +1,97 @@
|
|||
# Microsoft Developer Studio Project File - Name="BuildAll" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) External Target" 0x0106
|
||||
|
||||
CFG=BuildAll - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "BuildAll.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "BuildAll.mak" CFG="BuildAll - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "BuildAll - Win32 Release" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE "BuildAll - Win32 Debug" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
|
||||
!IF "$(CFG)" == "BuildAll - Win32 Release"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir ""
|
||||
# PROP BASE Intermediate_Dir ""
|
||||
# PROP BASE Cmd_Line "NMAKE /f makefile.win"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name ".\Browse\BuildAll.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir ""
|
||||
# PROP Intermediate_Dir ""
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache2" LONG=Release _dummy"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP Bsc_Name ".\Browse\httpd.bsc"
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ELSEIF "$(CFG)" == "BuildAll - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir ""
|
||||
# PROP BASE Intermediate_Dir ""
|
||||
# PROP BASE Cmd_Line "NMAKE /f makefile.win"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name ".\Browse\BuildAll.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir ""
|
||||
# PROP Intermediate_Dir ""
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache2" LONG=Debug _dummy"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP Bsc_Name ".\Browse\httpd.bsc"
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "BuildAll - Win32 Release"
|
||||
# Name "BuildAll - Win32 Debug"
|
||||
|
||||
!IF "$(CFG)" == "BuildAll - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "BuildAll - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\os\win32\BaseAddr.ref
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CHANGES
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\Makefile.win
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\STATUS
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
97
BuildBin.dsp
Normal file
97
BuildBin.dsp
Normal file
|
@ -0,0 +1,97 @@
|
|||
# Microsoft Developer Studio Project File - Name="BuildBin" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) External Target" 0x0106
|
||||
|
||||
CFG=BuildBin - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "BuildBin.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "BuildBin.mak" CFG="BuildBin - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "BuildBin - Win32 Release" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE "BuildBin - Win32 Debug" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
|
||||
!IF "$(CFG)" == "BuildBin - Win32 Release"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir ""
|
||||
# PROP BASE Intermediate_Dir ""
|
||||
# PROP BASE Cmd_Line "NMAKE /f makefile.win"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name ".\Browse\BuildBin.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir ""
|
||||
# PROP Intermediate_Dir ""
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache2" LONG=Release _trydb _trylua _tryxml _tryssl _tryzlib _trynghttp2 _trybrotli _trymd _dummy"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP Bsc_Name ".\Browse\httpd.bsc"
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ELSEIF "$(CFG)" == "BuildBin - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir ""
|
||||
# PROP BASE Intermediate_Dir ""
|
||||
# PROP BASE Cmd_Line "NMAKE /f makefile.win"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name ".\Browse\BuildBin.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir ""
|
||||
# PROP Intermediate_Dir ""
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache2" LONG=Debug _trydb _trylua _tryxml _tryssl _tryzlib _trynghttp2 _trybrotli _trymd _dummy"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache2\bin\httpd.exe"
|
||||
# PROP Bsc_Name ".\Browse\httpd.bsc"
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "BuildBin - Win32 Release"
|
||||
# Name "BuildBin - Win32 Debug"
|
||||
|
||||
!IF "$(CFG)" == "BuildBin - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "BuildBin - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\os\win32\BaseAddr.ref
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CHANGES
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\Makefile.win
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\STATUS
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
1047
CMakeLists.txt
Normal file
1047
CMakeLists.txt
Normal file
File diff suppressed because it is too large
Load diff
87
INSTALL
Normal file
87
INSTALL
Normal file
|
@ -0,0 +1,87 @@
|
|||
|
||||
APACHE INSTALLATION OVERVIEW
|
||||
|
||||
Quick Start - Unix
|
||||
------------------
|
||||
|
||||
For complete installation documentation, see [ht]docs/manual/install.html or
|
||||
http://httpd.apache.org/docs/2.4/install.html
|
||||
|
||||
$ ./configure --prefix=PREFIX
|
||||
$ make
|
||||
$ make install
|
||||
$ PREFIX/bin/apachectl start
|
||||
|
||||
NOTES: * Replace PREFIX with the filesystem path under which
|
||||
Apache should be installed. A typical installation
|
||||
might use "/usr/local/apache2" for PREFIX (without the
|
||||
quotes).
|
||||
|
||||
* Consider if you want to use a previously installed APR and
|
||||
APR-Util (such as those provided with many OSes) or if you
|
||||
need to use the APR and APR-Util from the apr.apache.org
|
||||
project. If the latter, download the latest versions and
|
||||
unpack them to ./srclib/apr and ./srclib/apr-util (no
|
||||
version numbers in the directory names) and use
|
||||
./configure's --with-included-apr option. This is required
|
||||
if you don't have the compiler which the system APR was
|
||||
built with. It can also be advantageous if you are a
|
||||
developer who will be linking your code with Apache or using
|
||||
a debugger to step through server code, as it removes the
|
||||
possibility of version or compile-option mismatches with APR
|
||||
and APR-Util code. As a convenience, prepackaged source-code
|
||||
bundles of APR and APR-Util are occasionally also provided
|
||||
as a httpd-2.X.X-deps.tar.gz download.
|
||||
|
||||
* If you are a developer building Apache directly from
|
||||
Subversion, you will need to run ./buildconf before running
|
||||
configure. This script bootstraps the build environment and
|
||||
requires Python as well as GNU autoconf and libtool. If you
|
||||
build Apache from a release tarball, you don't have to run
|
||||
buildconf.
|
||||
|
||||
* If you want to build a threaded MPM (for instance worker)
|
||||
on FreeBSD, be aware that threads do not work well with
|
||||
Apache on FreeBSD versions before 5.4-RELEASE. If you wish
|
||||
to try a threaded Apache on an earlier version of FreeBSD,
|
||||
use the --enable-threads parameter to ./configure in
|
||||
addition to the --with-mpm parameter.
|
||||
|
||||
* If you are building directly from Subversion on Mac OS X
|
||||
(Darwin), make sure to use GNU Libtool 1.4.2 or newer. All
|
||||
recent versions of the developer tools on this platform
|
||||
include a sufficiently recent version of GNU Libtool (named
|
||||
glibtool, but buildconf knows where to find it).
|
||||
|
||||
For a short impression of what possibilities you have, here is a
|
||||
typical example which configures Apache for the installation tree
|
||||
/sw/pkg/apache with a particular compiler and flags plus the two
|
||||
additional modules mod_rewrite and mod_speling for later loading
|
||||
through the DSO mechanism:
|
||||
|
||||
$ CC="pgcc" CFLAGS="-O2" \
|
||||
./configure --prefix=/sw/pkg/apache \
|
||||
--enable-rewrite=shared \
|
||||
--enable-speling=shared
|
||||
|
||||
The easiest way to find all of the configuration flags for Apache 2.4
|
||||
is to run ./configure --help.
|
||||
|
||||
|
||||
Quick Start - Windows
|
||||
---------------------
|
||||
|
||||
For complete documentation, see manual/platform/windows.html.en or
|
||||
<http://httpd.apache.org/docs/2.4/platform/windows.html>
|
||||
|
||||
|
||||
Postscript
|
||||
----------
|
||||
|
||||
To obtain help with installation problems, please see the resources at
|
||||
<http://httpd.apache.org/support.html>
|
||||
|
||||
Thanks for using the Apache HTTP Server, version 2.4.
|
||||
|
||||
The Apache Software Foundation
|
||||
http://www.apache.org/
|
109
InstallBin.dsp
Normal file
109
InstallBin.dsp
Normal file
|
@ -0,0 +1,109 @@
|
|||
# Microsoft Developer Studio Project File - Name="InstallBin" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) External Target" 0x0106
|
||||
|
||||
CFG=InstallBin - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "InstallBin.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "InstallBin.mak" CFG="InstallBin - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "InstallBin - Win32 Release" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE "InstallBin - Win32 Debug" (based on "Win32 (x86) External Target")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
|
||||
!IF "$(CFG)" == "InstallBin - Win32 Release"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Cmd_Line "NMAKE /f InstallBin.mak"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache24\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name "InstallBin.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache24" SHORT=R LONG=Release _install"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache24\bin\httpd.exe"
|
||||
# PROP Bsc_Name "Browse\httpd.bsc"
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ELSEIF "$(CFG)" == "InstallBin - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Cmd_Line "NMAKE /f InstallBin.mak"
|
||||
# PROP BASE Rebuild_Opt "/a"
|
||||
# PROP BASE Target_File "\Apache24\bin\httpd.exe"
|
||||
# PROP BASE Bsc_Name "InstallBin.bsc"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Cmd_Line "NMAKE /f makefile.win INSTDIR="\Apache24" SHORT=D LONG=Debug _install"
|
||||
# PROP Rebuild_Opt ""
|
||||
# PROP Target_File "\Apache24\bin\httpd.exe"
|
||||
# PROP Bsc_Name ""
|
||||
# PROP Target_Dir ""
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "InstallBin - Win32 Release"
|
||||
# Name "InstallBin - Win32 Debug"
|
||||
|
||||
!IF "$(CFG)" == "InstallBin - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "InstallBin - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\logs\access.log
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\os\win32\BaseAddr.ref
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CHANGES
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\logs\error.log
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\conf\httpd.conf
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\Makefile.win
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\STATUS
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
173
LAYOUT
Normal file
173
LAYOUT
Normal file
|
@ -0,0 +1,173 @@
|
|||
The httpd-2.1 Source Tree LAYOUT
|
||||
--------------------------------
|
||||
|
||||
./ .................... Top-Level httpd-2.1 Root Directory
|
||||
|
||||
ABOUT_APACHE .......... Overview of the Apache HTTP Server
|
||||
LAYOUT ................ This file describing the source tree
|
||||
README ................ Overview of this distribution
|
||||
STATUS ................ Current project activity and commentary
|
||||
|
||||
build/ ................ Supporting tools for buildconf/configure
|
||||
|
||||
win32/ ................ Supporting tools for Win32 MSVC builds
|
||||
|
||||
docs/ ................. Documentation and Examples
|
||||
|
||||
cgi-examples/ .........
|
||||
|
||||
conf/ .................
|
||||
|
||||
docroot/ ..............
|
||||
|
||||
error/ ................
|
||||
|
||||
include/ ..............
|
||||
|
||||
icons/ ................
|
||||
|
||||
small/ ................
|
||||
|
||||
man/ ..................
|
||||
|
||||
manual/ ...............
|
||||
|
||||
developer/ ............
|
||||
|
||||
faq/ ..................
|
||||
|
||||
howto/ ................
|
||||
|
||||
images/ ...............
|
||||
|
||||
misc/ .................
|
||||
|
||||
mod/ ..................
|
||||
|
||||
platform/ .............
|
||||
|
||||
programs/ .............
|
||||
|
||||
search/ ...............
|
||||
|
||||
ssl/ ..................
|
||||
|
||||
style/ ................
|
||||
|
||||
vhosts/ ...............
|
||||
|
||||
include/ ................
|
||||
|
||||
modules/ ................ Manditory and Add-In Apache stock modules
|
||||
|
||||
aaa/ ....................
|
||||
|
||||
arch/ ...................
|
||||
|
||||
netware/ ................
|
||||
|
||||
win32/ ..................
|
||||
|
||||
cache/ ..................
|
||||
|
||||
dav/ ....................
|
||||
|
||||
fs/ .....................
|
||||
|
||||
main/ ...................
|
||||
|
||||
echo/ ...................
|
||||
|
||||
experimental/ ...........
|
||||
|
||||
filters/ ................
|
||||
|
||||
generators/ .............
|
||||
|
||||
http/ ................... HTTP: protocol module
|
||||
|
||||
loggers/ ................
|
||||
|
||||
mappers/ ................
|
||||
|
||||
metadata/ ...............
|
||||
|
||||
pop3/ ...................
|
||||
|
||||
private/ ................
|
||||
|
||||
proxy/ ..................
|
||||
|
||||
ssl/ .................... HTTPS: SSL v2/v3 and TLS v1 protocol module
|
||||
|
||||
README .................. Overview of mod_ssl
|
||||
README.dsov.fig ......... Overview diagram of mod_ssl design
|
||||
README.dsov.ps .......... Overview diagram of mod_ssl design
|
||||
Makefile.in ............. Makefile template for Unix platform
|
||||
config.m4 ............... Autoconf stub for the Apache config mechanism
|
||||
mod_ssl.c ............... main source file containing API structures
|
||||
mod_ssl.h ............... common header file of mod_ssl
|
||||
ssl_engine_config.c ..... module configuration handling
|
||||
ssl_engine_init.c ....... module initialization
|
||||
ssl_engine_io.c ......... I/O support
|
||||
ssl_engine_kernel.c ..... SSL engine kernel
|
||||
ssl_engine_log.c ........ logfile support
|
||||
ssl_engine_mutex.c ...... mutual exclusion support
|
||||
ssl_engine_pphrase.c .... pass-phrase handling
|
||||
ssl_engine_rand.c ....... PRNG support
|
||||
ssl_engine_vars.c ....... Variable Expansion support
|
||||
ssl_scache.c ............ session cache abstraction layer
|
||||
ssl_util.c .............. utility functions
|
||||
ssl_util_ssl.c .......... the OpenSSL companion source
|
||||
ssl_util_ssl.h .......... the OpenSSL companion header
|
||||
|
||||
test/ ................... not distributed with released source tarballs
|
||||
|
||||
os/ .....................
|
||||
|
||||
bs2000/ .................
|
||||
|
||||
netware/ ................
|
||||
|
||||
os2/ ....................
|
||||
|
||||
unix/ ...................
|
||||
|
||||
win32/ ..................
|
||||
|
||||
server/ .................
|
||||
|
||||
mpm/ ....................
|
||||
|
||||
event/ ..................
|
||||
|
||||
mpmt_os2/ ...............
|
||||
|
||||
netware/ ................
|
||||
|
||||
prefork/ ................
|
||||
|
||||
winnt/ ..................
|
||||
|
||||
worker/ .................
|
||||
|
||||
srclib/ ................... Additional Libraries
|
||||
|
||||
apr/ ...................... SEE srclib/apr/LAYOUT
|
||||
|
||||
apr-util/ ................. SEE srclib/apr/LAYOUT
|
||||
|
||||
pcre/ .....................
|
||||
|
||||
doc/ ......................
|
||||
|
||||
testdata/ .................
|
||||
|
||||
support/ ................ Sources for Support Binaries
|
||||
|
||||
SHA1/ .................. Ancient SHA1 password conversion utilities
|
||||
|
||||
win32/ ................. Win32-only Support Applications
|
||||
|
||||
test/ ................... not distributed with released source tarballs
|
||||
|
537
LICENSE
Normal file
537
LICENSE
Normal file
|
@ -0,0 +1,537 @@
|
|||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
|
||||
|
||||
|
||||
APACHE HTTP SERVER SUBCOMPONENTS:
|
||||
|
||||
The Apache HTTP Server includes a number of subcomponents with
|
||||
separate copyright notices and license terms. Your use of the source
|
||||
code for the these subcomponents is subject to the terms and
|
||||
conditions of the following licenses.
|
||||
|
||||
For the mod_mime_magic component:
|
||||
|
||||
/*
|
||||
* mod_mime_magic: MIME type lookup via file magic numbers
|
||||
* Copyright (c) 1996-1997 Cisco Systems, Inc.
|
||||
*
|
||||
* This software was submitted by Cisco Systems to the Apache Group in July
|
||||
* 1997. Future revisions and derivatives of this source code must
|
||||
* acknowledge Cisco Systems as the original contributor of this module.
|
||||
* All other licensing and usage conditions are those of the Apache Group.
|
||||
*
|
||||
* Some of this code is derived from the free version of the file command
|
||||
* originally posted to comp.sources.unix. Copyright info for that program
|
||||
* is included below as required.
|
||||
* ---------------------------------------------------------------------------
|
||||
* - Copyright (c) Ian F. Darwin, 1987. Written by Ian F. Darwin.
|
||||
*
|
||||
* This software is not subject to any license of the American Telephone and
|
||||
* Telegraph Company or of the Regents of the University of California.
|
||||
*
|
||||
* Permission is granted to anyone to use this software for any purpose on any
|
||||
* computer system, and to alter it and redistribute it freely, subject to
|
||||
* the following restrictions:
|
||||
*
|
||||
* 1. The author is not responsible for the consequences of use of this
|
||||
* software, no matter how awful, even if they arise from flaws in it.
|
||||
*
|
||||
* 2. The origin of this software must not be misrepresented, either by
|
||||
* explicit claim or by omission. Since few users ever read sources, credits
|
||||
* must appear in the documentation.
|
||||
*
|
||||
* 3. Altered versions must be plainly marked as such, and must not be
|
||||
* misrepresented as being the original software. Since few users ever read
|
||||
* sources, credits must appear in the documentation.
|
||||
*
|
||||
* 4. This notice may not be removed or altered.
|
||||
* -------------------------------------------------------------------------
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
For the modules\mappers\mod_imagemap.c component:
|
||||
|
||||
"macmartinized" polygon code copyright 1992 by Eric Haines, erich@eye.com
|
||||
|
||||
For the server\util_md5.c component:
|
||||
|
||||
/************************************************************************
|
||||
* NCSA HTTPd Server
|
||||
* Software Development Group
|
||||
* National Center for Supercomputing Applications
|
||||
* University of Illinois at Urbana-Champaign
|
||||
* 605 E. Springfield, Champaign, IL 61820
|
||||
* httpd@ncsa.uiuc.edu
|
||||
*
|
||||
* Copyright (C) 1995, Board of Trustees of the University of Illinois
|
||||
*
|
||||
************************************************************************
|
||||
*
|
||||
* md5.c: NCSA HTTPd code which uses the md5c.c RSA Code
|
||||
*
|
||||
* Original Code Copyright (C) 1994, Jeff Hostetler, Spyglass, Inc.
|
||||
* Portions of Content-MD5 code Copyright (C) 1993, 1994 by Carnegie Mellon
|
||||
* University (see Copyright below).
|
||||
* Portions of Content-MD5 code Copyright (C) 1991 Bell Communications
|
||||
* Research, Inc. (Bellcore) (see Copyright below).
|
||||
* Portions extracted from mpack, John G. Myers - jgm+@cmu.edu
|
||||
* Content-MD5 Code contributed by Martin Hamilton (martin@net.lut.ac.uk)
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/* these portions extracted from mpack, John G. Myers - jgm+@cmu.edu */
|
||||
/* (C) Copyright 1993,1994 by Carnegie Mellon University
|
||||
* All Rights Reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software
|
||||
* and its documentation for any purpose is hereby granted without
|
||||
* fee, provided that the above copyright notice appear in all copies
|
||||
* and that both that copyright notice and this permission notice
|
||||
* appear in supporting documentation, and that the name of Carnegie
|
||||
* Mellon University not be used in advertising or publicity
|
||||
* pertaining to distribution of the software without specific,
|
||||
* written prior permission. Carnegie Mellon University makes no
|
||||
* representations about the suitability of this software for any
|
||||
* purpose. It is provided "as is" without express or implied
|
||||
* warranty.
|
||||
*
|
||||
* CARNEGIE MELLON UNIVERSITY DISCLAIMS ALL WARRANTIES WITH REGARD TO
|
||||
* THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
* AND FITNESS, IN NO EVENT SHALL CARNEGIE MELLON UNIVERSITY BE LIABLE
|
||||
* FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
|
||||
* AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
|
||||
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
|
||||
* SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (c) 1991 Bell Communications Research, Inc. (Bellcore)
|
||||
*
|
||||
* Permission to use, copy, modify, and distribute this material
|
||||
* for any purpose and without fee is hereby granted, provided
|
||||
* that the above copyright notice and this permission notice
|
||||
* appear in all copies, and that the name of Bellcore not be
|
||||
* used in advertising or publicity pertaining to this
|
||||
* material without the specific, prior written permission
|
||||
* of an authorized representative of Bellcore. BELLCORE
|
||||
* MAKES NO REPRESENTATIONS ABOUT THE ACCURACY OR SUITABILITY
|
||||
* OF THIS MATERIAL FOR ANY PURPOSE. IT IS PROVIDED "AS IS",
|
||||
* WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
|
||||
*/
|
||||
|
||||
|
||||
For the util_pcre.c and ap_regex.h components:
|
||||
|
||||
Copyright (c) 1997-2004 University of Cambridge
|
||||
|
||||
-----------------------------------------------------------------------------
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
* Neither the name of the University of Cambridge nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGE.
|
||||
-----------------------------------------------------------------------------
|
||||
|
||||
|
||||
For the srclib\apr\include\apr_md5.h component:
|
||||
/*
|
||||
* This is work is derived from material Copyright RSA Data Security, Inc.
|
||||
*
|
||||
* The RSA copyright statement and Licence for that original material is
|
||||
* included below. This is followed by the Apache copyright statement and
|
||||
* licence for the modifications made to that material.
|
||||
*/
|
||||
|
||||
/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All
|
||||
rights reserved.
|
||||
|
||||
License to copy and use this software is granted provided that it
|
||||
is identified as the "RSA Data Security, Inc. MD5 Message-Digest
|
||||
Algorithm" in all material mentioning or referencing this software
|
||||
or this function.
|
||||
|
||||
License is also granted to make and use derivative works provided
|
||||
that such works are identified as "derived from the RSA Data
|
||||
Security, Inc. MD5 Message-Digest Algorithm" in all material
|
||||
mentioning or referencing the derived work.
|
||||
|
||||
RSA Data Security, Inc. makes no representations concerning either
|
||||
the merchantability of this software or the suitability of this
|
||||
software for any particular purpose. It is provided "as is"
|
||||
without express or implied warranty of any kind.
|
||||
|
||||
These notices must be retained in any copies of any part of this
|
||||
documentation and/or software.
|
||||
*/
|
||||
|
||||
For the srclib\apr\passwd\apr_md5.c component:
|
||||
|
||||
/*
|
||||
* This is work is derived from material Copyright RSA Data Security, Inc.
|
||||
*
|
||||
* The RSA copyright statement and Licence for that original material is
|
||||
* included below. This is followed by the Apache copyright statement and
|
||||
* licence for the modifications made to that material.
|
||||
*/
|
||||
|
||||
/* MD5C.C - RSA Data Security, Inc., MD5 message-digest algorithm
|
||||
*/
|
||||
|
||||
/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All
|
||||
rights reserved.
|
||||
|
||||
License to copy and use this software is granted provided that it
|
||||
is identified as the "RSA Data Security, Inc. MD5 Message-Digest
|
||||
Algorithm" in all material mentioning or referencing this software
|
||||
or this function.
|
||||
|
||||
License is also granted to make and use derivative works provided
|
||||
that such works are identified as "derived from the RSA Data
|
||||
Security, Inc. MD5 Message-Digest Algorithm" in all material
|
||||
mentioning or referencing the derived work.
|
||||
|
||||
RSA Data Security, Inc. makes no representations concerning either
|
||||
the merchantability of this software or the suitability of this
|
||||
software for any particular purpose. It is provided "as is"
|
||||
without express or implied warranty of any kind.
|
||||
|
||||
These notices must be retained in any copies of any part of this
|
||||
documentation and/or software.
|
||||
*/
|
||||
/*
|
||||
* The apr_md5_encode() routine uses much code obtained from the FreeBSD 3.0
|
||||
* MD5 crypt() function, which is licenced as follows:
|
||||
* ----------------------------------------------------------------------------
|
||||
* "THE BEER-WARE LICENSE" (Revision 42):
|
||||
* <phk@login.dknet.dk> wrote this file. As long as you retain this notice you
|
||||
* can do whatever you want with this stuff. If we meet some day, and you think
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
For the srclib\apr-util\crypto\apr_md4.c component:
|
||||
|
||||
* This is derived from material copyright RSA Data Security, Inc.
|
||||
* Their notice is reproduced below in its entirety.
|
||||
*
|
||||
* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All
|
||||
* rights reserved.
|
||||
*
|
||||
* License to copy and use this software is granted provided that it
|
||||
* is identified as the "RSA Data Security, Inc. MD4 Message-Digest
|
||||
* Algorithm" in all material mentioning or referencing this software
|
||||
* or this function.
|
||||
*
|
||||
* License is also granted to make and use derivative works provided
|
||||
* that such works are identified as "derived from the RSA Data
|
||||
* Security, Inc. MD4 Message-Digest Algorithm" in all material
|
||||
* mentioning or referencing the derived work.
|
||||
*
|
||||
* RSA Data Security, Inc. makes no representations concerning either
|
||||
* the merchantability of this software or the suitability of this
|
||||
* software for any particular purpose. It is provided "as is"
|
||||
* without express or implied warranty of any kind.
|
||||
*
|
||||
* These notices must be retained in any copies of any part of this
|
||||
* documentation and/or software.
|
||||
*/
|
||||
|
||||
For the srclib\apr-util\include\apr_md4.h component:
|
||||
|
||||
*
|
||||
* This is derived from material copyright RSA Data Security, Inc.
|
||||
* Their notice is reproduced below in its entirety.
|
||||
*
|
||||
* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All
|
||||
* rights reserved.
|
||||
*
|
||||
* License to copy and use this software is granted provided that it
|
||||
* is identified as the "RSA Data Security, Inc. MD4 Message-Digest
|
||||
* Algorithm" in all material mentioning or referencing this software
|
||||
* or this function.
|
||||
*
|
||||
* License is also granted to make and use derivative works provided
|
||||
* that such works are identified as "derived from the RSA Data
|
||||
* Security, Inc. MD4 Message-Digest Algorithm" in all material
|
||||
* mentioning or referencing the derived work.
|
||||
*
|
||||
* RSA Data Security, Inc. makes no representations concerning either
|
||||
* the merchantability of this software or the suitability of this
|
||||
* software for any particular purpose. It is provided "as is"
|
||||
* without express or implied warranty of any kind.
|
||||
*
|
||||
* These notices must be retained in any copies of any part of this
|
||||
* documentation and/or software.
|
||||
*/
|
||||
|
||||
|
||||
For the srclib\apr-util\test\testmd4.c component:
|
||||
|
||||
*
|
||||
* This is derived from material copyright RSA Data Security, Inc.
|
||||
* Their notice is reproduced below in its entirety.
|
||||
*
|
||||
* Copyright (C) 1990-2, RSA Data Security, Inc. Created 1990. All
|
||||
* rights reserved.
|
||||
*
|
||||
* RSA Data Security, Inc. makes no representations concerning either
|
||||
* the merchantability of this software or the suitability of this
|
||||
* software for any particular purpose. It is provided "as is"
|
||||
* without express or implied warranty of any kind.
|
||||
*
|
||||
* These notices must be retained in any copies of any part of this
|
||||
* documentation and/or software.
|
||||
*/
|
||||
|
||||
For the test\zb.c component:
|
||||
|
||||
/* ZeusBench V1.01
|
||||
===============
|
||||
|
||||
This program is Copyright (C) Zeus Technology Limited 1996.
|
||||
|
||||
This program may be used and copied freely providing this copyright notice
|
||||
is not removed.
|
||||
|
||||
This software is provided "as is" and any express or implied warranties,
|
||||
including but not limited to, the implied warranties of merchantability and
|
||||
fitness for a particular purpose are disclaimed. In no event shall
|
||||
Zeus Technology Ltd. be liable for any direct, indirect, incidental, special,
|
||||
exemplary, or consequential damaged (including, but not limited to,
|
||||
procurement of substitute good or services; loss of use, data, or profits;
|
||||
or business interruption) however caused and on theory of liability. Whether
|
||||
in contract, strict liability or tort (including negligence or otherwise)
|
||||
arising in any way out of the use of this software, even if advised of the
|
||||
possibility of such damage.
|
||||
|
||||
Written by Adam Twiss (adam@zeus.co.uk). March 1996
|
||||
|
||||
Thanks to the following people for their input:
|
||||
Mike Belshe (mbelshe@netscape.com)
|
||||
Michael Campanella (campanella@stevms.enet.dec.com)
|
||||
|
||||
*/
|
||||
|
318
Makefile.in
Normal file
318
Makefile.in
Normal file
|
@ -0,0 +1,318 @@
|
|||
|
||||
SUBDIRS = srclib os server modules support
|
||||
CLEAN_SUBDIRS = test
|
||||
|
||||
PROGRAM_NAME = $(progname)
|
||||
PROGRAM_SOURCES = modules.c
|
||||
PROGRAM_LDADD = buildmark.o $(HTTPD_LDFLAGS) $(PROGRAM_DEPENDENCIES) $(PCRE_LIBS) $(EXTRA_LIBS) $(AP_LIBS) $(LIBS)
|
||||
PROGRAM_PRELINK = $(COMPILE) -c $(top_srcdir)/server/buildmark.c
|
||||
PROGRAM_DEPENDENCIES = \
|
||||
server/libmain.la \
|
||||
$(BUILTIN_LIBS) \
|
||||
$(MPM_LIB) \
|
||||
os/$(OS_DIR)/libos.la
|
||||
|
||||
sbin_PROGRAMS = $(PROGRAM_NAME)
|
||||
TARGETS = $(sbin_PROGRAMS) $(shared_build) $(other_targets)
|
||||
INSTALL_TARGETS = install-conf install-htdocs install-error install-icons \
|
||||
install-other install-cgi install-include install-suexec install-build \
|
||||
install-man
|
||||
|
||||
DISTCLEAN_TARGETS = include/ap_config_auto.h include/ap_config_layout.h \
|
||||
include/apache_probes.h \
|
||||
modules.c config.cache config.log config.status build/config_vars.mk \
|
||||
build/rules.mk docs/conf/httpd.conf docs/conf/extra/*.conf shlibtool \
|
||||
build/pkg/pkginfo build/config_vars.sh
|
||||
EXTRACLEAN_TARGETS = configure include/ap_config_auto.h.in generated_lists \
|
||||
httpd.spec
|
||||
|
||||
include $(top_builddir)/build/rules.mk
|
||||
include $(top_srcdir)/build/program.mk
|
||||
|
||||
install-conf:
|
||||
@echo Installing configuration files
|
||||
@$(MKINSTALLDIRS) $(DESTDIR)$(sysconfdir) $(DESTDIR)$(sysconfdir)/extra
|
||||
@$(MKINSTALLDIRS) $(DESTDIR)$(sysconfdir)/original/extra
|
||||
@cd $(top_srcdir)/docs/conf; \
|
||||
for i in mime.types magic; do \
|
||||
if test ! -f $(DESTDIR)$(sysconfdir)/$$i; then \
|
||||
$(INSTALL_DATA) $$i $(DESTDIR)$(sysconfdir); \
|
||||
fi; \
|
||||
done; \
|
||||
for j in $(top_srcdir)/docs/conf $(top_builddir)/docs/conf ; do \
|
||||
cd $$j ; \
|
||||
for i in httpd.conf extra/*.conf; do \
|
||||
if [ -f $$i ] ; then \
|
||||
( \
|
||||
n_lm=`awk 'BEGIN {n=0} /@@LoadModule@@/ {n+=1} END {print n}' < $$i`; \
|
||||
if test $$n_lm -eq 0 -o "x$(MPM_MODULES)$(DSO_MODULES)" = "x"; then \
|
||||
sed -e 's#@@ServerRoot@@#$(prefix)#g' \
|
||||
-e 's#@@Port@@#$(PORT)#g' \
|
||||
-e 's#@@SSLPort@@#$(SSLPORT)#g' \
|
||||
-e '/@@LoadModule@@/d' \
|
||||
< $$i; \
|
||||
else \
|
||||
sed -n -e '/@@LoadModule@@/q' \
|
||||
-e 's#@@ServerRoot@@#$(prefix)#g' \
|
||||
-e 's#@@Port@@#$(PORT)#g' \
|
||||
-e 's#@@SSLPort@@#$(SSLPORT)#g' \
|
||||
-e 'p' \
|
||||
< $$i; \
|
||||
if echo " $(DSO_MODULES) "|$(EGREP) " cgi " > /dev/null ; then \
|
||||
have_cgi="1"; \
|
||||
else \
|
||||
have_cgi="0"; \
|
||||
fi; \
|
||||
if echo " $(DSO_MODULES) "|$(EGREP) " cgid " > /dev/null ; then \
|
||||
have_cgid="1"; \
|
||||
else \
|
||||
have_cgid="0"; \
|
||||
fi; \
|
||||
for j in $(MPM_MODULES) "^EOL^"; do \
|
||||
if test $$j != "^EOL^"; then \
|
||||
if echo ",$(ENABLED_MPM_MODULE),"|$(EGREP) ",$$j," > /dev/null ; then \
|
||||
loading_disabled=""; \
|
||||
else \
|
||||
loading_disabled="#"; \
|
||||
fi; \
|
||||
echo "$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
|
||||
fi; \
|
||||
done; \
|
||||
for j in $(DSO_MODULES) "^EOL^"; do \
|
||||
if test $$j != "^EOL^"; then \
|
||||
if echo ",$(ENABLED_DSO_MODULES),"|$(EGREP) ",$$j," > /dev/null ; then \
|
||||
loading_disabled=""; \
|
||||
else \
|
||||
loading_disabled="#"; \
|
||||
if test "$(LOAD_ALL_MODULES)" = "yes"; then \
|
||||
loading_disabled=""; \
|
||||
fi; \
|
||||
fi; \
|
||||
if test $$j = "cgid" -a "$$have_cgi" = "1"; then \
|
||||
echo "<IfModule !mpm_prefork_module>"; \
|
||||
echo " $${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
|
||||
echo "</IfModule>"; \
|
||||
elif test $$j = "cgi" -a "$$have_cgid" = "1"; then \
|
||||
echo "<IfModule mpm_prefork_module>"; \
|
||||
echo " $${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
|
||||
echo "</IfModule>"; \
|
||||
else \
|
||||
echo "$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
|
||||
fi; \
|
||||
fi; \
|
||||
done; \
|
||||
sed -e '1,/@@LoadModule@@/d' \
|
||||
-e '/@@LoadModule@@/d' \
|
||||
-e 's#@@ServerRoot@@#$(prefix)#g' \
|
||||
-e 's#@@Port@@#$(PORT)#g' \
|
||||
-e 's#@@SSLPort@@#$(SSLPORT)#g' \
|
||||
< $$i; \
|
||||
fi \
|
||||
) > $(DESTDIR)$(sysconfdir)/original/$$i; \
|
||||
chmod 0644 $(DESTDIR)$(sysconfdir)/original/$$i; \
|
||||
file=$$i; \
|
||||
if [ "$$i" = "httpd.conf" ]; then \
|
||||
file=`echo $$i|sed s/.*.conf/$(PROGRAM_NAME).conf/`; \
|
||||
fi; \
|
||||
if test ! -f $(DESTDIR)$(sysconfdir)/$$file; then \
|
||||
$(INSTALL_DATA) $(DESTDIR)$(sysconfdir)/original/$$i $(DESTDIR)$(sysconfdir)/$$file; \
|
||||
fi; \
|
||||
fi; \
|
||||
done ; \
|
||||
done ; \
|
||||
if test -f "$(builddir)/envvars-std"; then \
|
||||
cp -p envvars-std $(DESTDIR)$(sbindir); \
|
||||
if test ! -f $(DESTDIR)$(sbindir)/envvars; then \
|
||||
cp -p envvars-std $(DESTDIR)$(sbindir)/envvars ; \
|
||||
fi ; \
|
||||
fi
|
||||
|
||||
# Create a sanitized config_vars.mk
|
||||
build/config_vars.out: build/config_vars.mk build/config_vars.sh
|
||||
@$(SHELL) build/config_vars.sh < build/config_vars.mk > build/config_vars.out
|
||||
|
||||
install-build: build/config_vars.out
|
||||
@echo Installing build system files
|
||||
@$(MKINSTALLDIRS) $(DESTDIR)$(installbuilddir)
|
||||
@for f in $(top_srcdir)/build/*.mk build/*.mk; do \
|
||||
$(INSTALL_DATA) $$f $(DESTDIR)$(installbuilddir); \
|
||||
done
|
||||
@for f in $(top_builddir)/config.nice \
|
||||
$(top_srcdir)/build/mkdir.sh \
|
||||
$(top_srcdir)/build/instdso.sh; do \
|
||||
$(INSTALL_PROGRAM) $$f $(DESTDIR)$(installbuilddir); \
|
||||
done
|
||||
@$(INSTALL_DATA) build/config_vars.out $(DESTDIR)$(installbuilddir)/config_vars.mk
|
||||
@rm build/config_vars.out
|
||||
|
||||
htdocs-srcdir = $(top_srcdir)/docs/docroot
|
||||
|
||||
docs:
|
||||
@if test -d $(top_srcdir)/docs/manual/build; then \
|
||||
cd $(top_srcdir)/docs/manual/build && ./build.sh all; \
|
||||
else \
|
||||
echo 'For details on generating the docs, please read:'; \
|
||||
echo ' http://httpd.apache.org/docs-project/docsformat.html'; \
|
||||
fi
|
||||
|
||||
update-changes:
|
||||
@for i in `find changes-entries -type f`; do \
|
||||
cp CHANGES CHANGES.tmp ; \
|
||||
awk -v fname=$$i 'BEGIN{done = 0; active = 0} \
|
||||
done == 0 && active == 0 && /^Changes with Apache /{ active = 1; print; next}; \
|
||||
/^( *\*|Changes with Apache )/ && active == 1 && done == 0{rec=$$0; while(getline<fname){if (! ($$0 ~ /^ *$$/)){print}}printf "\n";print rec; active = 0; done = 1; next} //;' \
|
||||
CHANGES.tmp > CHANGES ; \
|
||||
rm CHANGES.tmp ; \
|
||||
if [ -n "$(SVN)" ] ; then \
|
||||
if ! $(SVN) rm $$i 2>/dev/null ; then \
|
||||
$(RM) $$i ; \
|
||||
fi ; \
|
||||
else \
|
||||
$(RM) $$i ; \
|
||||
fi ; \
|
||||
done ; \
|
||||
if [ -n "$(SVN)" ] ; then \
|
||||
$(SVN) diff CHANGES ; \
|
||||
fi
|
||||
|
||||
validate-xml:
|
||||
@if test -d $(top_srcdir)/docs/manual/build; then \
|
||||
cd $(top_srcdir)/docs/manual/build && ./build.sh validate-xml; \
|
||||
else \
|
||||
echo 'For details on generating the docs, please read:'; \
|
||||
echo ' http://httpd.apache.org/docs-project/docsformat.html'; \
|
||||
fi
|
||||
|
||||
dox:
|
||||
doxygen $(top_srcdir)/docs/doxygen.conf
|
||||
|
||||
install-htdocs:
|
||||
-@if [ -d $(DESTDIR)$(htdocsdir) ]; then \
|
||||
echo "[PRESERVING EXISTING HTDOCS SUBDIR: $(DESTDIR)$(htdocsdir)]"; \
|
||||
else \
|
||||
echo Installing HTML documents ; \
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(htdocsdir) ; \
|
||||
if test -d $(htdocs-srcdir) && test "x$(RSYNC)" != "x" && test -x $(RSYNC) ; then \
|
||||
$(RSYNC) --exclude .svn -rlpt --numeric-ids $(htdocs-srcdir)/ $(DESTDIR)$(htdocsdir)/; \
|
||||
else \
|
||||
test -d $(htdocs-srcdir) && (cd $(htdocs-srcdir) && cp -rp * $(DESTDIR)$(htdocsdir)) ; \
|
||||
cd $(DESTDIR)$(htdocsdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \
|
||||
fi; \
|
||||
fi
|
||||
|
||||
install-error:
|
||||
-@if [ -d $(DESTDIR)$(errordir) ]; then \
|
||||
echo "[PRESERVING EXISTING ERROR SUBDIR: $(DESTDIR)$(errordir)]"; \
|
||||
else \
|
||||
echo Installing error documents ; \
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(errordir) ; \
|
||||
cd $(top_srcdir)/docs/error && cp -rp * $(DESTDIR)$(errordir) ; \
|
||||
test "x$(errordir)" != "x" && cd $(DESTDIR)$(errordir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \
|
||||
fi
|
||||
|
||||
install-icons:
|
||||
-@if [ -d $(DESTDIR)$(iconsdir) ]; then \
|
||||
echo "[PRESERVING EXISTING ICONS SUBDIR: $(DESTDIR)$(iconsdir)]"; \
|
||||
else \
|
||||
echo Installing icons ; \
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(iconsdir) ; \
|
||||
cd $(top_srcdir)/docs/icons && cp -rp * $(DESTDIR)$(iconsdir) ; \
|
||||
test "x$(iconsdir)" != "x" && cd $(DESTDIR)$(iconsdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \
|
||||
fi
|
||||
|
||||
install-cgi:
|
||||
-@if [ -d $(DESTDIR)$(cgidir) ];then \
|
||||
echo "[PRESERVING EXISTING CGI SUBDIR: $(DESTDIR)$(cgidir)]"; \
|
||||
else \
|
||||
echo Installing CGIs ; \
|
||||
$(MKINSTALLDIRS) $(DESTDIR)$(cgidir) ; \
|
||||
cd $(top_srcdir)/docs/cgi-examples && cp -rp * $(DESTDIR)$(cgidir) ; \
|
||||
test "x$(cgidir)" != "x" && cd $(DESTDIR)$(cgidir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \
|
||||
fi
|
||||
|
||||
install-other:
|
||||
@test -d $(DESTDIR)$(logfiledir) || $(MKINSTALLDIRS) $(DESTDIR)$(logfiledir)
|
||||
@test -d $(DESTDIR)$(runtimedir) || $(MKINSTALLDIRS) $(DESTDIR)$(runtimedir)
|
||||
@for ext in dll x; do \
|
||||
file=apachecore.$$ext; \
|
||||
if test -f $$file; then \
|
||||
cp -p $$file $(DESTDIR)$(libdir); \
|
||||
fi; \
|
||||
done; \
|
||||
file=httpd.dll; \
|
||||
if test -f $$file; then \
|
||||
cp -p $$file $(DESTDIR)$(bindir); \
|
||||
fi;
|
||||
|
||||
INSTALL_HEADERS = \
|
||||
include/*.h \
|
||||
$(srcdir)/include/*.h \
|
||||
$(srcdir)/os/$(OS_DIR)/os.h \
|
||||
$(srcdir)/modules/arch/unix/mod_unixd.h \
|
||||
$(srcdir)/modules/core/mod_so.h \
|
||||
$(srcdir)/modules/core/mod_watchdog.h \
|
||||
$(srcdir)/modules/cache/mod_cache.h \
|
||||
$(srcdir)/modules/cache/cache_common.h \
|
||||
$(srcdir)/modules/database/mod_dbd.h \
|
||||
$(srcdir)/modules/dav/main/mod_dav.h \
|
||||
$(srcdir)/modules/http2/mod_http2.h \
|
||||
$(srcdir)/modules/filters/mod_include.h \
|
||||
$(srcdir)/modules/filters/mod_xml2enc.h \
|
||||
$(srcdir)/modules/generators/mod_cgi.h \
|
||||
$(srcdir)/modules/generators/mod_status.h \
|
||||
$(srcdir)/modules/loggers/mod_log_config.h \
|
||||
$(srcdir)/modules/mappers/mod_rewrite.h \
|
||||
$(srcdir)/modules/proxy/mod_proxy.h \
|
||||
$(srcdir)/modules/session/mod_session.h \
|
||||
$(srcdir)/modules/ssl/mod_ssl.h \
|
||||
$(srcdir)/modules/ssl/mod_ssl_openssl.h \
|
||||
$(srcdir)/os/$(OS_DIR)/*.h
|
||||
|
||||
install-include:
|
||||
@echo Installing header files
|
||||
@$(MKINSTALLDIRS) $(DESTDIR)$(includedir)
|
||||
@for hdr in $(INSTALL_HEADERS); do \
|
||||
$(INSTALL_DATA) $$hdr $(DESTDIR)$(includedir); \
|
||||
done
|
||||
|
||||
install-man:
|
||||
@echo Installing man pages and online manual
|
||||
@test -d $(DESTDIR)$(mandir) || $(MKINSTALLDIRS) $(DESTDIR)$(mandir)
|
||||
@test -d $(DESTDIR)$(mandir)/man1 || $(MKINSTALLDIRS) $(DESTDIR)$(mandir)/man1
|
||||
@test -d $(DESTDIR)$(mandir)/man8 || $(MKINSTALLDIRS) $(DESTDIR)$(mandir)/man8
|
||||
@test -d $(DESTDIR)$(manualdir) || $(MKINSTALLDIRS) $(DESTDIR)$(manualdir)
|
||||
@cp -p $(top_srcdir)/docs/man/*.1 $(DESTDIR)$(mandir)/man1
|
||||
@cp -p $(top_srcdir)/docs/man/*.8 $(DESTDIR)$(mandir)/man8
|
||||
@if test "x$(RSYNC)" != "x" && test -x $(RSYNC) ; then \
|
||||
$(RSYNC) --exclude .svn -rlpt --numeric-ids $(top_srcdir)/docs/manual/ $(DESTDIR)$(manualdir)/; \
|
||||
else \
|
||||
cd $(top_srcdir)/docs/manual && cp -rp * $(DESTDIR)$(manualdir); \
|
||||
cd $(DESTDIR)$(manualdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \
|
||||
fi
|
||||
|
||||
install-suexec: install-suexec-$(INSTALL_SUEXEC)
|
||||
|
||||
install-suexec-binary:
|
||||
@if test -f $(builddir)/support/suexec; then \
|
||||
test -d $(DESTDIR)$(sbindir) || $(MKINSTALLDIRS) $(DESTDIR)$(sbindir); \
|
||||
$(INSTALL_PROGRAM) $(top_builddir)/support/suexec $(DESTDIR)$(sbindir); \
|
||||
fi
|
||||
|
||||
install-suexec-setuid: install-suexec-binary
|
||||
@if test -f $(builddir)/support/suexec; then \
|
||||
chmod 4755 $(DESTDIR)$(sbindir)/suexec; \
|
||||
fi
|
||||
|
||||
install-suexec-caps: install-suexec-binary
|
||||
@if test -f $(builddir)/support/suexec; then \
|
||||
setcap 'cap_setuid,cap_setgid+pe' $(DESTDIR)$(sbindir)/suexec; \
|
||||
fi
|
||||
|
||||
suexec:
|
||||
cd support && $(MAKE) suexec
|
||||
|
||||
x-local-distclean:
|
||||
@rm -rf autom4te.cache
|
||||
|
||||
# XXX: This looks awfully platform-specific [read: bad form and style]
|
||||
include $(top_srcdir)/os/os2/core.mk
|
1297
Makefile.win
Normal file
1297
Makefile.win
Normal file
File diff suppressed because it is too large
Load diff
18
NOTICE
Normal file
18
NOTICE
Normal file
|
@ -0,0 +1,18 @@
|
|||
Apache HTTP Server
|
||||
Copyright 2025 The Apache Software Foundation.
|
||||
|
||||
This product includes software developed at
|
||||
The Apache Software Foundation (https://www.apache.org/).
|
||||
|
||||
Portions of this software were developed at the National Center
|
||||
for Supercomputing Applications (NCSA) at the University of
|
||||
Illinois at Urbana-Champaign.
|
||||
|
||||
This software contains code derived from the RSA Data Security
|
||||
Inc. MD5 Message-Digest Algorithm, including various
|
||||
modifications by Spyglass Inc., Carnegie Mellon University, and
|
||||
Bell Communications Research, Inc (Bellcore).
|
||||
|
||||
This software contains code derived from the PCRE library pcreposix.c
|
||||
source code, written by Philip Hazel, Copyright 1997-2004
|
||||
by the University of Cambridge, England.
|
481
NWGNUmakefile
Normal file
481
NWGNUmakefile
Normal file
|
@ -0,0 +1,481 @@
|
|||
#
|
||||
# Define our required macro's if not already done.
|
||||
#
|
||||
|
||||
ifndef AP_WORK
|
||||
export AP_WORK = $(CURDIR)
|
||||
endif
|
||||
|
||||
ifndef APR_WORK
|
||||
ifeq "$(wildcard $(AP_WORK)/srclib/apr)" "$(AP_WORK)/srclib/apr"
|
||||
export APR_WORK = $(AP_WORK)/srclib/apr
|
||||
endif
|
||||
endif
|
||||
ifneq "$(wildcard $(APR_WORK)/include/apr_version.h)" "$(APR_WORK)/include/apr_version.h"
|
||||
$(error APR_WORK does not point to a valid APR source tree)
|
||||
endif
|
||||
|
||||
ifndef APU_WORK
|
||||
ifeq "$(wildcard $(AP_WORK)/srclib/apr-util)" "$(AP_WORK)/srclib/apr-util"
|
||||
export APU_WORK = $(AP_WORK)/srclib/apr-util
|
||||
endif
|
||||
endif
|
||||
ifndef APU_WORK
|
||||
ifeq "$(wildcard $(APR_WORK)/include/apu_version.h)" "$(APR_WORK)/include/apu_version.h"
|
||||
export APU_WORK = $(APR_WORK)
|
||||
endif
|
||||
endif
|
||||
ifneq "$(wildcard $(APU_WORK)/include/apu_version.h)" "$(APU_WORK)/include/apu_version.h"
|
||||
$(error APU_WORK does not point to a valid APU source tree)
|
||||
endif
|
||||
|
||||
#
|
||||
# Declare the sub-directories to be built here
|
||||
#
|
||||
|
||||
SUBDIRS = \
|
||||
$(APR_WORK) \
|
||||
build \
|
||||
support \
|
||||
modules \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# Get the 'head' of the build environment. This includes default targets and
|
||||
# paths to tools
|
||||
#
|
||||
|
||||
include $(AP_WORK)/build/NWGNUhead.inc
|
||||
|
||||
#
|
||||
# build this level's files
|
||||
|
||||
#
|
||||
# Make sure all needed macro's are defined
|
||||
#
|
||||
|
||||
#
|
||||
# These directories will be at the beginning of the include list, followed by
|
||||
# INCDIRS
|
||||
#
|
||||
XINCDIRS += \
|
||||
$(APR)/include \
|
||||
$(APRUTIL)/include \
|
||||
$(SRC)/include \
|
||||
$(STDMOD)/aaa \
|
||||
$(STDMOD)/core \
|
||||
$(STDMOD)/filters \
|
||||
$(STDMOD)/generators \
|
||||
$(STDMOD)/http \
|
||||
$(STDMOD)/loggers \
|
||||
$(STDMOD)/mappers \
|
||||
$(STDMOD)/proxy \
|
||||
$(STDMOD)/ssl \
|
||||
$(SERVER) \
|
||||
$(SERVER)/mpm/netware \
|
||||
$(PCRE) \
|
||||
$(NWOS) \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These flags will come after CFLAGS
|
||||
#
|
||||
XCFLAGS += \
|
||||
-DHAVE_CONFIG_H \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These defines will come after DEFINES
|
||||
#
|
||||
XDEFINES += \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These flags will be added to the link.opt file
|
||||
#
|
||||
XLFLAGS += \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These values will be appended to the correct variables based on the value of
|
||||
# RELEASE
|
||||
#
|
||||
ifeq "$(RELEASE)" "debug"
|
||||
XINCDIRS += \
|
||||
$(EOLIST)
|
||||
|
||||
XCFLAGS += \
|
||||
$(EOLIST)
|
||||
|
||||
XDEFINES += \
|
||||
$(EOLIST)
|
||||
|
||||
XLFLAGS += \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
ifeq "$(RELEASE)" "noopt"
|
||||
XINCDIRS += \
|
||||
$(EOLIST)
|
||||
|
||||
XCFLAGS += \
|
||||
$(EOLIST)
|
||||
|
||||
XDEFINES += \
|
||||
$(EOLIST)
|
||||
|
||||
XLFLAGS += \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
ifeq "$(RELEASE)" "release"
|
||||
XINCDIRS += \
|
||||
$(EOLIST)
|
||||
|
||||
XCFLAGS += \
|
||||
$(EOLIST)
|
||||
|
||||
XDEFINES += \
|
||||
$(EOLIST)
|
||||
|
||||
XLFLAGS += \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
#
|
||||
# These are used by the link target if an NLM is being generated
|
||||
# This is used by the link 'name' directive to name the nlm. If left blank
|
||||
# TARGET_nlm (see below) will be used.
|
||||
#
|
||||
NLM_NAME = Apache2
|
||||
|
||||
#
|
||||
# This is used by the link '-desc ' directive.
|
||||
# If left blank, NLM_NAME will be used.
|
||||
#
|
||||
NLM_DESCRIPTION = Apache Web Server $(VERSION_STR) $(VERSION_SKT)
|
||||
|
||||
#
|
||||
# This is used by the '-threadname' directive. If left blank,
|
||||
# NLM_NAME Thread will be used.
|
||||
#
|
||||
NLM_THREAD_NAME = $(NLM_NAME)
|
||||
|
||||
#
|
||||
# This is used by the '-screenname' directive. If left blank,
|
||||
# 'Apache for NetWare' Thread will be used.
|
||||
#
|
||||
NLM_SCREEN_NAME = Apache $(VERSION_STR) for NetWare
|
||||
|
||||
|
||||
#
|
||||
# If this is specified, it will override VERSION value in
|
||||
# $(AP_WORK)/build/NWGNUenvironment.inc
|
||||
#
|
||||
NLM_VERSION =
|
||||
|
||||
#
|
||||
# If this is specified, it will override the default of 64K
|
||||
#
|
||||
NLM_STACK_SIZE = 65536
|
||||
|
||||
|
||||
#
|
||||
# If this is specified it will be used by the link '-entry' directive
|
||||
#
|
||||
NLM_ENTRY_SYM =
|
||||
|
||||
#
|
||||
# If this is specified it will be used by the link '-exit' directive
|
||||
#
|
||||
NLM_EXIT_SYM =
|
||||
|
||||
#
|
||||
# If this is specified it will be used by the link '-check' directive
|
||||
#
|
||||
NLM_CHECK_SYM = _LibCCheckUnload
|
||||
|
||||
#
|
||||
# If these are specified it will be used by the link '-flags' directive
|
||||
#
|
||||
NLM_FLAGS = PSEUDOPREEMPTION
|
||||
|
||||
#
|
||||
# If this is specified it will be linked in with the XDCData option in the def
|
||||
# file instead of the default of $(NWOS)/apache.xdc. XDCData can be disabled
|
||||
# by setting APACHE_UNIPROC in the environment
|
||||
#
|
||||
XDCDATA =
|
||||
|
||||
#
|
||||
# If there is an NLM target, put it here
|
||||
#
|
||||
TARGET_nlm = \
|
||||
$(OBJDIR)/$(NLM_NAME).nlm \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# If there is an LIB target, put it here
|
||||
#
|
||||
TARGET_lib = \
|
||||
$(PCRELIB) \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These are the OBJ files needed to create the NLM target above.
|
||||
# Paths must all use the '/' character
|
||||
#
|
||||
FILES_nlm_objs = \
|
||||
$(OBJDIR)/buildmark.o \
|
||||
$(OBJDIR)/config.o \
|
||||
$(OBJDIR)/connection.o \
|
||||
$(OBJDIR)/core.o \
|
||||
$(OBJDIR)/core_filters.o \
|
||||
$(OBJDIR)/eoc_bucket.o \
|
||||
$(OBJDIR)/eor_bucket.o \
|
||||
$(OBJDIR)/error_bucket.o \
|
||||
$(OBJDIR)/http_core.o \
|
||||
$(OBJDIR)/http_protocol.o \
|
||||
$(OBJDIR)/http_request.o \
|
||||
$(OBJDIR)/byterange_filter.o \
|
||||
$(OBJDIR)/chunk_filter.o \
|
||||
$(OBJDIR)/http_etag.o \
|
||||
$(OBJDIR)/http_filters.o \
|
||||
$(OBJDIR)/listen.o \
|
||||
$(OBJDIR)/log.o \
|
||||
$(OBJDIR)/main.o \
|
||||
$(OBJDIR)/mod_authn_core.o \
|
||||
$(OBJDIR)/mod_authz_core.o \
|
||||
$(OBJDIR)/mod_authz_host.o \
|
||||
$(OBJDIR)/mod_alias.o \
|
||||
$(OBJDIR)/mod_dir.o \
|
||||
$(OBJDIR)/mod_env.o \
|
||||
$(OBJDIR)/mod_include.o \
|
||||
$(OBJDIR)/mod_log_config.o \
|
||||
$(OBJDIR)/mod_mime.o \
|
||||
$(OBJDIR)/mod_negotiation.o \
|
||||
$(OBJDIR)/mod_netware.o \
|
||||
$(OBJDIR)/mod_setenvif.o \
|
||||
$(OBJDIR)/mod_so.o \
|
||||
$(OBJDIR)/mod_watchdog.o \
|
||||
$(OBJDIR)/modules.o \
|
||||
$(OBJDIR)/mpm_common.o \
|
||||
$(OBJDIR)/mpm_netware.o \
|
||||
$(OBJDIR)/protocol.o \
|
||||
$(OBJDIR)/provider.o \
|
||||
$(OBJDIR)/request.o \
|
||||
$(OBJDIR)/scoreboard.o \
|
||||
$(OBJDIR)/util.o \
|
||||
$(OBJDIR)/util_cfgtree.o \
|
||||
$(OBJDIR)/util_charset.o \
|
||||
$(OBJDIR)/util_cookies.o \
|
||||
$(OBJDIR)/util_debug.o \
|
||||
$(OBJDIR)/util_expr_eval.o \
|
||||
$(OBJDIR)/util_expr_parse.o \
|
||||
$(OBJDIR)/util_expr_scan.o \
|
||||
$(OBJDIR)/util_fcgi.o \
|
||||
$(OBJDIR)/util_filter.o \
|
||||
$(OBJDIR)/util_md5.o \
|
||||
$(OBJDIR)/util_mutex.o \
|
||||
$(OBJDIR)/util_nw.o \
|
||||
$(OBJDIR)/util_pcre.o \
|
||||
$(OBJDIR)/util_regex.o \
|
||||
$(OBJDIR)/util_script.o \
|
||||
$(OBJDIR)/util_time.o \
|
||||
$(OBJDIR)/util_xml.o \
|
||||
$(OBJDIR)/vhost.o \
|
||||
$(EOLIST)
|
||||
|
||||
# Build in mod_nw_ssl if Winsock is being used
|
||||
ifndef USE_STDSOCKETS
|
||||
FILES_nlm_objs += $(OBJDIR)/mod_nw_ssl.o \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
#
|
||||
# These are the LIB files needed to create the NLM target above.
|
||||
# These will be added as a library command in the link.opt file.
|
||||
#
|
||||
FILES_nlm_libs = \
|
||||
$(PCRELIB) \
|
||||
$(PRELUDE) \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These are the modules that the above NLM target depends on to load.
|
||||
# These will be added as a module command in the link.opt file.
|
||||
#
|
||||
FILES_nlm_modules = \
|
||||
aprlib \
|
||||
Libc \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# If the nlm has a msg file, put it's path here
|
||||
#
|
||||
FILE_nlm_msg =
|
||||
|
||||
#
|
||||
# If the nlm has a hlp file put it's path here
|
||||
#
|
||||
FILE_nlm_hlp =
|
||||
|
||||
#
|
||||
# If this is specified, it will override $(NWOS)\copyright.txt.
|
||||
#
|
||||
FILE_nlm_copyright =
|
||||
|
||||
#
|
||||
# Any additional imports go here
|
||||
#
|
||||
FILES_nlm_Ximports = \
|
||||
@aprlib.imp \
|
||||
@libc.imp \
|
||||
@netware.imp \
|
||||
GetCurrentAddressSpace \
|
||||
$(EOLIST)
|
||||
|
||||
# Don't link with Winsock if standard sockets are being used
|
||||
ifndef USE_STDSOCKETS
|
||||
FILES_nlm_Ximports += @ws2nlm.imp \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
#
|
||||
# Any symbols exported to here
|
||||
#
|
||||
FILES_nlm_exports = \
|
||||
@httpd.imp \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# These are the OBJ files needed to create the LIB target above.
|
||||
# Paths must all use the '/' character
|
||||
#
|
||||
ifeq "$(wildcard $(PCRE)/pcre.c)" "$(PCRE)/pcre.c"
|
||||
|
||||
FILES_lib_objs = \
|
||||
$(OBJDIR)/pcre.o \
|
||||
$(EOLIST)
|
||||
|
||||
else
|
||||
|
||||
FILES_lib_objs = \
|
||||
$(OBJDIR)/chartables.o \
|
||||
$(OBJDIR)/pcre_compile.o \
|
||||
$(OBJDIR)/pcre_exec.o \
|
||||
$(OBJDIR)/pcre_fullinfo.o \
|
||||
$(OBJDIR)/pcre_globals.o \
|
||||
$(OBJDIR)/pcre_newline.o \
|
||||
$(OBJDIR)/pcre_tables.o \
|
||||
$(OBJDIR)/pcre_version.o \
|
||||
$(EOLIST)
|
||||
ifeq "$(wildcard $(PCRE)/pcre_try_flipped.c)" "$(PCRE)/pcre_try_flipped.c"
|
||||
FILES_lib_objs += \
|
||||
$(OBJDIR)/pcre_try_flipped.o \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
#
|
||||
# implement targets and dependancies (leave this section alone)
|
||||
#
|
||||
|
||||
libs :: $(OBJDIR) $(TARGET_lib)
|
||||
|
||||
nlms :: libs $(TARGET_nlm)
|
||||
|
||||
#
|
||||
# Updated this target to create necessary directories and copy files to the
|
||||
# correct place. (See $(AP_WORK)/build/NWGNUhead.inc for examples)
|
||||
#
|
||||
MKCNF = $(AWK) -v BDIR=$(BASEDIR) -v PORT=$(PORT) -v SSLPORT=$(SSLPORT) -v MODSSL=$(WITH_SSL) -v BSDSKT=$(USE_STDSOCKETS) -f build/mkconfNW.awk $1 > $2
|
||||
|
||||
install :: nlms instscripts FORCE
|
||||
$(call COPY,$(OBJDIR)/$(NLM_NAME).nlm, $(INSTALLBASE)/)
|
||||
$(call COPY,ABOUT_APACHE, $(INSTALLBASE)/)
|
||||
$(call COPY,CHANGES, $(INSTALLBASE)/)
|
||||
$(call COPY,LICENSE, $(INSTALLBASE)/)
|
||||
$(call COPY,README, $(INSTALLBASE)/)
|
||||
$(call COPY,VERSIONING, $(INSTALLBASE)/)
|
||||
$(call COPY,STATUS, $(INSTALLBASE)/)
|
||||
$(call COPY,support/dbmmanage.in, $(INSTALLBASE)/bin/dbmmanage.pl)
|
||||
$(call COPY,support/logresolve.pl.in, $(INSTALLBASE)/bin/logresolve.pl)
|
||||
$(call COPY,support/split-logfile.in, $(INSTALLBASE)/bin/split-logfile.pl)
|
||||
$(call COPY,support/check_forensic, $(INSTALLBASE)/bin/check_forensic.sh)
|
||||
$(call COPY,docs/conf/magic, $(INSTALLBASE)/conf/)
|
||||
$(call COPY,docs/conf/mime.types, $(INSTALLBASE)/conf/)
|
||||
$(call COPY,docs/conf/charset.conv, $(INSTALLBASE)/conf/)
|
||||
$(call COPY,docs/cgi-examples/printenv, $(INSTALLBASE)/cgi-bin/printenv.pl)
|
||||
$(call MKCNF,docs/conf/httpd.conf.in, $(INSTALLBASE)/conf/httpd.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-autoindex.conf.in, $(INSTALLBASE)/conf/extra/httpd-autoindex.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-dav.conf.in, $(INSTALLBASE)/conf/extra/httpd-dav.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-default.conf.in, $(INSTALLBASE)/conf/extra/httpd-default.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-info.conf.in, $(INSTALLBASE)/conf/extra/httpd-info.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-languages.conf.in, $(INSTALLBASE)/conf/extra/httpd-languages.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-manual.conf.in, $(INSTALLBASE)/conf/extra/httpd-manual.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-mpm.conf.in, $(INSTALLBASE)/conf/extra/httpd-mpm.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-multilang-errordoc.conf.in, $(INSTALLBASE)/conf/extra/httpd-multilang-errordoc.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-userdir.conf.in, $(INSTALLBASE)/conf/extra/httpd-userdir.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-vhosts.conf.in, $(INSTALLBASE)/conf/extra/httpd-vhosts.conf)
|
||||
$(call MKCNF,docs/conf/extra/httpd-ssl.conf.in, $(INSTALLBASE)/conf/extra/httpd-ssl.conf)
|
||||
$(call MKCNF,docs/conf/extra/proxy-html.conf.in, $(INSTALLBASE)/conf/extra/proxy-html.conf)
|
||||
$(call COPYR,docs/docroot, $(INSTALLBASE)/htdocs)
|
||||
$(call COPYR,docs/error, $(INSTALLBASE)/error)
|
||||
$(call COPYR,docs/icons, $(INSTALLBASE)/icons)
|
||||
$(call COPYR,docs/man, $(INSTALLBASE)/man)
|
||||
$(call COPYR,docs/manual, $(INSTALLBASE)/manual)
|
||||
|
||||
installdev :: FORCE
|
||||
$(call COPY,$(SRC)/include/*.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(NWOS)/*.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(APR)/include/*.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(APRUTIL)/include/*.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/core/mod_so.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/core/mod_watchdog.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/cache/mod_cache.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/cache/cache_common.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/database/mod_dbd.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/dav/main/mod_dav.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/filters/mod_include.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/generators/mod_cgi.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/generators/mod_status.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/loggers/mod_log_config.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/mappers/mod_rewrite.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/proxy/mod_proxy.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/session/mod_session.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/ssl/mod_ssl.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(STDMOD)/ssl/mod_ssl_openssl.h, $(INSTALLBASE)/include/)
|
||||
$(call COPY,$(APR)/*.imp, $(INSTALLBASE)/lib/)
|
||||
$(call COPY,$(NWOS)/*.imp, $(INSTALLBASE)/lib/)
|
||||
$(call COPY,$(NWOS)/*.xdc, $(INSTALLBASE)/lib/)
|
||||
$(call COPY,$(APBUILD)/NWGNU*.inc, $(INSTALLBASE)/build/)
|
||||
|
||||
prebuild :: FORCE
|
||||
$(MAKE) -C $(SERVER) -f NWGNUmakefile
|
||||
$(MAKE) -C $(PCRE) -f NWGNUmakefile
|
||||
$(call MKDIR,$(PREBUILD_INST))
|
||||
$(call COPY,$(SERVER)/$(OBJDIR)/*.nlm, $(PREBUILD_INST)/)
|
||||
$(call COPY,$(PCRE)/$(OBJDIR)/*.nlm, $(PREBUILD_INST)/)
|
||||
|
||||
#
|
||||
# Any specialized rules here
|
||||
#
|
||||
|
||||
vpath %.c server:modules/arch/netware:modules/http:modules/aaa:modules/mappers
|
||||
vpath %.c modules/generators:modules/metadata:modules/filters:modules/loggers
|
||||
vpath %.c modules/core:os/netware:server/mpm/netware:$(PCRE)
|
||||
|
||||
$(OBJDIR)/chartables.o: os/netware/chartables.c
|
||||
|
||||
#
|
||||
# Include the 'tail' makefile that has targets that depend on variables defined
|
||||
# in this makefile
|
||||
#
|
||||
|
||||
include $(APBUILD)/NWGNUtail.inc
|
||||
|
||||
include $(APBUILD)/NWGNUscripts.inc
|
||||
|
||||
|
110
README
Normal file
110
README
Normal file
|
@ -0,0 +1,110 @@
|
|||
|
||||
Apache HTTP Server
|
||||
|
||||
What is it?
|
||||
-----------
|
||||
|
||||
The Apache HTTP Server is a powerful and flexible HTTP/1.1 compliant
|
||||
web server. Originally designed as a replacement for the NCSA HTTP
|
||||
Server, it has grown to be the most popular web server on the
|
||||
Internet. As a project of the Apache Software Foundation, the
|
||||
developers aim to collaboratively develop and maintain a robust,
|
||||
commercial-grade, standards-based server with freely available
|
||||
source code.
|
||||
|
||||
The Latest Version
|
||||
------------------
|
||||
|
||||
Details of the latest version can be found on the Apache HTTP
|
||||
server project page under https://httpd.apache.org/.
|
||||
|
||||
Documentation
|
||||
-------------
|
||||
|
||||
The documentation available as of the date of this release is
|
||||
included in HTML format in the docs/manual/ directory. The most
|
||||
up-to-date documentation can be found at
|
||||
https://httpd.apache.org/docs/2.4/.
|
||||
|
||||
Installation
|
||||
------------
|
||||
|
||||
Please see the file called INSTALL. Platform specific notes can be
|
||||
found in README.platforms.
|
||||
|
||||
Licensing
|
||||
---------
|
||||
|
||||
Please see the file called LICENSE.
|
||||
|
||||
Cryptographic Software Notice
|
||||
-----------------------------
|
||||
|
||||
This distribution may include software that has been designed for use
|
||||
with cryptographic software. The country in which you currently reside
|
||||
may have restrictions on the import, possession, use, and/or re-export
|
||||
to another country, of encryption software. BEFORE using any encryption
|
||||
software, please check your country's laws, regulations and policies
|
||||
concerning the import, possession, or use, and re-export of encryption
|
||||
software, to see if this is permitted. See <https://www.wassenaar.org/>
|
||||
for more information.
|
||||
|
||||
The U.S. Government Department of Commerce, Bureau of Industry and
|
||||
Security (BIS), has classified this software as Export Commodity
|
||||
Control Number (ECCN) 5D002.C.1, which includes information security
|
||||
software using or performing cryptographic functions with asymmetric
|
||||
algorithms. The form and manner of this Apache Software Foundation
|
||||
distribution makes it eligible for export under the License Exception
|
||||
ENC Technology Software Unrestricted (TSU) exception (see the BIS
|
||||
Export Administration Regulations, Section 740.13) for both object
|
||||
code and source code.
|
||||
|
||||
The following provides more details on the included files that
|
||||
may be subject to export controls on cryptographic software:
|
||||
|
||||
Apache httpd 2.0 and later versions include the mod_ssl module under
|
||||
modules/ssl/
|
||||
for configuring and listening to connections over SSL encrypted
|
||||
network sockets by performing calls to a general-purpose encryption
|
||||
library, such as OpenSSL or the operating system's platform-specific
|
||||
SSL facilities.
|
||||
|
||||
In addition, some versions of apr-util provide an abstract interface
|
||||
for symmetrical cryptographic functions that make use of a
|
||||
general-purpose encryption library, such as OpenSSL, NSS, or the
|
||||
operating system's platform-specific facilities. This interface is
|
||||
known as the apr_crypto interface, with implementation beneath the
|
||||
/crypto directory. The apr_crypto interface is used by the
|
||||
mod_session_crypto module available under
|
||||
modules/session
|
||||
for optional encryption of session information.
|
||||
|
||||
Some object code distributions of Apache httpd, indicated with the
|
||||
word "crypto" in the package name, may include object code for the
|
||||
OpenSSL encryption library as distributed in open source form from
|
||||
<https://www.openssl.org/source/>.
|
||||
|
||||
The above files are optional and may be removed if the cryptographic
|
||||
functionality is not desired or needs to be excluded from redistribution.
|
||||
Distribution packages of Apache httpd that include the word "nossl"
|
||||
in the package name have been created without the above files and are
|
||||
therefore not subject to this notice.
|
||||
|
||||
Contacts
|
||||
--------
|
||||
|
||||
o If you want to be informed about new code releases, bug fixes,
|
||||
security fixes, general news and information about the Apache server
|
||||
subscribe to the apache-announce mailing list as described under
|
||||
<https://httpd.apache.org/lists.html#http-announce>
|
||||
|
||||
o If you want freely available support for running Apache please see the
|
||||
resources at <https://httpd.apache.org/support.html>
|
||||
|
||||
o If you have a concrete bug report for Apache please see the instructions
|
||||
for bug reporting at <https://httpd.apache.org/bug_report.html>
|
||||
|
||||
o If you want to participate in actively developing Apache please
|
||||
subscribe to the `dev@httpd.apache.org' mailing list as described at
|
||||
<https://httpd.apache.org/lists.html#http-dev>
|
||||
|
19
README.CHANGES
Normal file
19
README.CHANGES
Normal file
|
@ -0,0 +1,19 @@
|
|||
Changes can be documented in two ways now: Either by directly editing the
|
||||
CHANGES file like it was done until now or by storing each entry for the
|
||||
CHANGES file correctly formated in a separate file in the changes-entries
|
||||
directory.
|
||||
|
||||
The benefit of the single file per change approach is that it eases backporting
|
||||
the CHANGES entry to a stable branch as it avoids the frequent merge conflicts
|
||||
as changes are merged in different orders or not at all in the stable branch.
|
||||
|
||||
In order to keep the current CHANGES file for the users as is there is a new
|
||||
make target called 'update-changes'. It merges all change files in the
|
||||
changes-entries directory to the top of the CHANGES file and removes them
|
||||
afterwards.
|
||||
|
||||
This make target can be seen in a similar way as the scripts to update the
|
||||
documentation files from its xml sources. It can be executed immediately
|
||||
after the new file in the changes-entries directory has been created / merged
|
||||
and committed or it can be executed later. It should be executed at least before
|
||||
a release gets tagged.
|
329
README.cmake
Normal file
329
README.cmake
Normal file
|
@ -0,0 +1,329 @@
|
|||
Experimental cmake-based build support for Apache httpd on Microsoft Windows
|
||||
|
||||
Status
|
||||
------
|
||||
|
||||
This build support is currently intended only for Microsoft Windows.
|
||||
|
||||
This build support is experimental. Specifically,
|
||||
|
||||
* It does not support all features of Apache httpd.
|
||||
* Some components may not be built correctly and/or in a manner
|
||||
compatible with the previous Windows build support.
|
||||
* Build interfaces, such as the mechanisms which are used to enable
|
||||
optional functionality or specify prerequisites, may change from
|
||||
release to release as feedback is received from users and bugs and
|
||||
limitations are resolved.
|
||||
|
||||
Important: Refer to the "Known Bugs and Limitations" section for further
|
||||
information.
|
||||
|
||||
It is beyond the scope of this document to document or explain
|
||||
how to utilize the various cmake features, such as different
|
||||
build backends or provisions for finding support libraries.
|
||||
|
||||
Please refer to the cmake documentation for additional information
|
||||
that applies to building any project with cmake.
|
||||
|
||||
Prerequisites
|
||||
-------------
|
||||
|
||||
The following tools must be in PATH:
|
||||
|
||||
* cmake, version 2.8 or later
|
||||
cmake version 3.1.3 or later is required to work with current OpenSSL
|
||||
releases. (OpenSSL is an optional prerequisite of httpd.)
|
||||
* Perl
|
||||
* If the WITH_MODULES feature is used: awk
|
||||
* If using a command-line compiler: compiler and linker and related tools
|
||||
(Refer to the cmake documentation for more information.)
|
||||
|
||||
The following support libraries are mandatory:
|
||||
|
||||
* APR, built with cmake
|
||||
+ Either APR 2.0-dev (trunk) or APR 1.5.x and APR-Util 1.5.x.
|
||||
+ When building APR (but not APR-Util), specify the build option
|
||||
APR_INSTALL_PRIVATE_H so that non-standard files required for building
|
||||
Apache httpd are installed.
|
||||
+ Additional APR settings affect httpd but are not mandatory, such as
|
||||
APR_HAVE_IPV6.
|
||||
* PCRE
|
||||
|
||||
Certain optional features of APR 2.0-dev (trunk) or APR-Util 1.5.x
|
||||
allow some optional features of httpd to be enabled. For example,
|
||||
APU_HAVE_CRYPTO is required for mod_session_crypto.
|
||||
|
||||
Additional support libraries allow some optional features of httpd to be
|
||||
enabled:
|
||||
|
||||
* libxml2 (e.g., mod_proxy_html)
|
||||
* lua 5.1 (mod_lua)
|
||||
* nghttp2 (mod_http2)
|
||||
* openssl (mod_ssl and https support for ab)
|
||||
* zlib (mod_deflate)
|
||||
|
||||
OpenSSL
|
||||
-------
|
||||
|
||||
If you have a binary install of OpenSSL in a well-known directory (e.g.,
|
||||
%HOME%\OpenSSL-Win64) and you wish to build httpd against a different
|
||||
install of OpenSSL, the cmake build may unexpectedly select OpenSSL
|
||||
libraries in the well-known directory even if the expected include files
|
||||
are used. Check the cmake output from your httpd build to confirm that
|
||||
the expected OpenSSL libraries and include files are used.
|
||||
|
||||
The cmake FindOpenSSL module searches for OpenSSL libraries in a "VC"
|
||||
subdirectory of the OpenSSL install with filenames that indicate the build
|
||||
type (e.g., "<PREFIX>/lib/VC/ssleay32MD.lib"); defining CMAKE_PREFIX_PATH
|
||||
or OPENSSL_ROOT_DIR or even OPENSSL_LIBRARIES does not circumvent finding
|
||||
these libraries.
|
||||
|
||||
To work around this issue, rename the well-known OpenSSL directory while
|
||||
building httpd. Let us know if you find a better solution.
|
||||
|
||||
nghttp2
|
||||
-------
|
||||
|
||||
This is required for mod_http2.
|
||||
|
||||
cmake-based build support for nghttp2 for Windows can be found at
|
||||
https://github.com/trawick/nghttp2-minimal-cmake. That easily fits into
|
||||
a build system that already uses cmake for httpd, apr, and perhaps other
|
||||
packages. A dynamic build of nghttp2 using its normal Windows build
|
||||
system should also be usable by nghttp2.
|
||||
|
||||
How to build
|
||||
------------
|
||||
|
||||
1. cd to a clean directory for building (i.e., don't build in your
|
||||
source tree)
|
||||
|
||||
2. Make sure cmake and Perl are in PATH. Additionally, some backends
|
||||
require compile tools in PATH. (Hint: "Visual Studio Command Prompt")
|
||||
In the unlikely event that you use -DWITH_MODULES, described below, make
|
||||
sure awk is in PATH.
|
||||
|
||||
3. cmake -G "some backend, like 'NMake Makefiles'"
|
||||
-DCMAKE_INSTALL_PREFIX=d:/path/to/httpdinst
|
||||
-DENABLE_foo=A|I|O|a|i
|
||||
-DENABLE_MODULES=A|I|O|a|i
|
||||
d:/path/to/httpdsource
|
||||
|
||||
Alternately, you can use the cmake-gui and update settings in the GUI.
|
||||
|
||||
PCRE_INCLUDE_DIR, PCRE_LIBRARIES, APR_INCLUDE_DIR, APR_LIBRARIES,
|
||||
NGHTTP2_INCLUDE_DIR, NGHTTP2_LIBRARIES:
|
||||
|
||||
cmake doesn't bundle FindXXX for these packages, so the crucial
|
||||
information has to be specified in this manner if they aren't found
|
||||
in their default location.
|
||||
|
||||
-DPCRE_INCLUDE_DIR=d:/path/to/pcreinst/include
|
||||
-DPCRE_LIBRARIES=d:/path/to/pcreinst/lib/pcre[d].lib
|
||||
|
||||
These will have to be specified only if PCRE is installed to a different
|
||||
directory than httpd, or if debug *and* release builds of PCRE were
|
||||
installed there and you want to control which is used. (Currently the
|
||||
build will use pcred.lib (debug) if it is found in the default location
|
||||
and not overridden with -DPCRE_LIBRARIES.)
|
||||
|
||||
-DAPR_INCLUDE_DIR=d:/path/to/aprinst/include
|
||||
-DAPR_LIBRARIES="d:/path/to/aprinst/lib/libapr-1.lib;d:/path/to/aprinst/lib/libaprutil-1.lib"
|
||||
|
||||
These will have to be specified if APR[-Util] was installed to a
|
||||
different directory than httpd.
|
||||
|
||||
When building with APR trunk (future APR 2.x, with integrated APR-Util),
|
||||
specify just the path to libapr-2.lib:
|
||||
|
||||
-DAPR_LIBRARIES=d:/path/to/aprinst/lib/libapr-2.lib
|
||||
|
||||
APR+APR-Util 1.x vs. APR trunk will be detected automatically if they
|
||||
are installed to the same location as httpd.
|
||||
|
||||
APR-Util 1.x has an optional LDAP library. If APR-Util has LDAP enabled
|
||||
and httpd's mod_ldap and mod_authnz_ldap are being used, include the
|
||||
path to the LDAP library in the APR_LIBRARIES setting. (If APR and
|
||||
APR-Util are found in the default location, the LDAP library will be
|
||||
included if it is present.
|
||||
|
||||
-DNGHTTP2_INCLUDE_DIR=d:/path/to/nghttp2inst/include (which has nghttp2/*.h)
|
||||
-DNGHTTP2_LIBRARIES="d:/path/to/nghttp2inst/lib/nghttp2.lib"
|
||||
|
||||
These will have to be specified if nghttp2 was installed to a different
|
||||
directory than httpd.
|
||||
|
||||
LIBXML2_ICONV_INCLUDE_DIR, LIBXML2_ICONV_LIBRARIES
|
||||
|
||||
If using a module that requires libxml2 *and* the build of libxml2 requires
|
||||
iconv, set these variables to allow iconv includes and libraries to be
|
||||
used. For example:
|
||||
|
||||
-DLIBXML2_ICONV_INCLUDE_DIR=c:\iconv-1.9.2.win32\include
|
||||
-DLIBXML2_ICONV_LIBRARIES=c:\iconv-1.9.2.win32\lib\iconv.lib
|
||||
|
||||
CMAKE_C_FLAGS_RELEASE, _DEBUG, _RELWITHDEBINFO, _MINSIZEREL
|
||||
CMAKE_BUILD_TYPE
|
||||
|
||||
For NMake Makefiles the choices are at least DEBUG, RELEASE,
|
||||
RELWITHDEBINFO, and MINSIZEREL
|
||||
Other backends may have other selections.
|
||||
|
||||
ENABLE_foo:
|
||||
|
||||
Each module has a default setting which can be overridden with one of
|
||||
the following values:
|
||||
A build and Activate module
|
||||
a build and Activate module IFF prereqs are available; if
|
||||
prereqs are unavailable, don't build it
|
||||
I build module but leave it Inactive (commented-out
|
||||
LoadModule directive)
|
||||
i build module but leave it Inactive IFF prereqs are
|
||||
available; if prereqs are unavailable, don't build it
|
||||
O Omit module completely
|
||||
|
||||
Examples: -DENABLE_ACCESS_COMPAT=O
|
||||
-DENABLE_PROXY_HTML=i
|
||||
|
||||
ENABLE_MODULES:
|
||||
|
||||
This changes the *minimum* enablement of all modules to the specified
|
||||
value (one of A, a, I, i, O, as described under ENABLE_foo above).
|
||||
|
||||
The ranking of enablement from lowest to highest is O, i, I, a, A.
|
||||
If a specific module has a higher rank enablement setting, either from
|
||||
a built-in default or from -DENABLE_foo, ENABLE_MODULES won't affect
|
||||
that module. However, if a specific module has a lower-rank enablement
|
||||
setting, presumably from a built-in default, the value of ENABLE_MODULES
|
||||
will be used for that module.
|
||||
|
||||
Explanations for possible values:
|
||||
|
||||
-DENABLE_MODULES=a build and activate all possible modules,
|
||||
ignoring any with missing prereqs
|
||||
(doesn't affect modules with A for ENABLE_foo)
|
||||
|
||||
-DENABLE_MODULES=i build but leave inactive all possible
|
||||
modules, ignoring any with missing
|
||||
prereqs
|
||||
(doesn't affect modules with A, a, or I for
|
||||
ENABLE_foo)
|
||||
|
||||
-DENABLE_MODULES=O no impact, since all modules are either
|
||||
already disabled or have a higher setting
|
||||
|
||||
-DENABLE_MODULES=A build and activate all possible modules,
|
||||
failing the build if any module is missing
|
||||
a prereq
|
||||
|
||||
-DENABLE_MODULES=I similar to -DENABLE_MODULES=A
|
||||
(doesn't affect modules with A or a for
|
||||
ENABLE_foo)
|
||||
|
||||
WITH_MODULES:
|
||||
|
||||
Comma-separated paths to single file modules to statically linked into
|
||||
the server, like the --with-module=modpath:/path/to/mod_foo.c with
|
||||
the autoconf-based build. Key differences: The modpath (e.g.,
|
||||
"generators") isn't provided or used, and the copy of the module
|
||||
source being built is automatically updated when it changes.
|
||||
See also EXTRA_COMPILE_FLAGS, EXTRA_INCLUDES, and EXTRA_LIBS.
|
||||
|
||||
EXTRA_COMPILE_FLAGS:
|
||||
|
||||
Space-delimited compile flags to define with the build.
|
||||
|
||||
EXTRA_INCLUDES:
|
||||
|
||||
List of additional directories to search for .h files. This may
|
||||
be necessary when including third-party modules in the httpd build
|
||||
via WITH_MODULES.
|
||||
|
||||
EXTRA_LIBS:
|
||||
|
||||
List of additional libraries to link with. This may be necessary when
|
||||
including third-party modules in the httpd build via WITH_MODULES.
|
||||
|
||||
Port and SSLPort:
|
||||
|
||||
Port numbers for substitution into default .conf files. (The defaults
|
||||
are 80 and 443.)
|
||||
|
||||
INSTALL_PDB:
|
||||
|
||||
If .pdb files are generated for debugging, install them.
|
||||
Default: ON
|
||||
|
||||
The .pdb files are generally needed for debugging low-level code
|
||||
problems. If they aren't installed, they are still available in the
|
||||
build directory for use by alternate packaging implementations or when
|
||||
debugging on the build machine.
|
||||
|
||||
INSTALL_MANUAL:
|
||||
|
||||
Install the Apache HTTP Server manual.
|
||||
Default: ON
|
||||
|
||||
This could be turned off when developing changes in order to speed up
|
||||
installation time.
|
||||
|
||||
4. Build using the chosen generator (e.g., "nmake install" for cmake's "NMake
|
||||
Makefiles" generator).
|
||||
|
||||
Running the server and support programs
|
||||
---------------------------------------
|
||||
|
||||
This build system does not copy binaries such as dlls from other projects
|
||||
into the httpd install location. Without taking some precautions, httpd
|
||||
and support programs can fail to start or modules can fail to load because
|
||||
a support library can't be found in PATH or in the directory of the httpd
|
||||
binary.
|
||||
|
||||
This can be resolved in several different ways:
|
||||
|
||||
* Install httpd and the various support libraries to a common install
|
||||
prefix so that support libraries and httpd programs are installed in
|
||||
the same bin directory and are found without setting PATH.
|
||||
|
||||
* Update PATH to include the bin directories of all necessary support
|
||||
libraries.
|
||||
|
||||
Depending on where PATH is set, it may not affect starting httpd as
|
||||
a service.
|
||||
|
||||
* Maintain a script which combines required binaries into a common
|
||||
location, such as the httpd installion bin directory, and use that
|
||||
script after building or otherwise installing or updating support
|
||||
libraries.
|
||||
|
||||
* AVOID THE USE of any unrepeatable process of copying dll files around
|
||||
from different install locations until something starts working. The
|
||||
result is that when you later update a support library to pick up a
|
||||
security fix, httpd will likely continue to use the old, vulnerable
|
||||
library file.
|
||||
|
||||
Known Bugs and Limitations
|
||||
--------------------------
|
||||
|
||||
* no standard script or makefile is provided to tie together the builds
|
||||
of httpd and support libraries in a manner suitable for typical users
|
||||
* no logic to find support libraries or otherwise build these modules:
|
||||
+ mod_socache_dc (requires distcache), mod_serf (requires serf)
|
||||
+ additionally, mod_firehose doesn't compile on Windows anyway
|
||||
* buildmark.c isn't necessarily rebuilt when httpd.exe is regenerated
|
||||
* ApacheMonitor has a build error and is disabled
|
||||
* CGI examples aren't installed
|
||||
* dbmmanage.pl and wintty aren't built/installed
|
||||
* module enablement defaults are not in sync with the autoconf-based build
|
||||
* no support for static support library builds; unclear if that is a
|
||||
requirement; if so: taking PCRE as an example, we'd need to detect that it
|
||||
is static and then turn on PCRE_STATIC for the libhttpd build
|
||||
|
||||
Generally:
|
||||
|
||||
* Many httpd features have not been tested with this build.
|
||||
* Developers need to examine the existing Windows build in great detail and see
|
||||
what is missing from the cmake-based build, whether a feature or some build
|
||||
nuance.
|
||||
* Any feedback you can provide on your experiences with this build will be
|
||||
helpful.
|
112
README.platforms
Normal file
112
README.platforms
Normal file
|
@ -0,0 +1,112 @@
|
|||
|
||||
Apache HTTP Server
|
||||
|
||||
Platform specific notes:
|
||||
------------------------
|
||||
|
||||
================
|
||||
Darwin (OS X):
|
||||
Apache 2 relies heavily on the use of autoconf and libtool to
|
||||
provide a build environment. Darwin provides these tools as part
|
||||
of the Developers Tools package. Under Darwin, however, GNUlibtool
|
||||
is installed as 'glibtool' to avoid conflicting with the Darwin
|
||||
'libtool' program. Apache 2 knows about this so that's not a
|
||||
problem.
|
||||
|
||||
As of OS X 10.2 (Jaguar), the bundled versions work perfectly. Partly
|
||||
this is due to the fact that /bin/sh is now 'bash' and not 'zsh' as
|
||||
well as the fact that the bundled versions are up-to-date:
|
||||
autoconf 2.52 and (g)libtool 1.4.2.
|
||||
|
||||
You will note that GNU libtool should actually be installed as
|
||||
glibtool, to avoid conflict with a Darwin program of the same
|
||||
name.
|
||||
|
||||
There have been some reports that autoconf 2.52 prevents Apache's
|
||||
build system from correctly handling passing multi-value envvars
|
||||
to the build system (eg: CFLAGS="-g -O3" ./configure), causing
|
||||
errors. Use of bash does not seem to help in this situation. If
|
||||
this affects you, downgrading to autoconf 2.13 (which is installed
|
||||
on Darwin) will help.
|
||||
|
||||
With Leopard (at least up to 10.5.2), when running configure
|
||||
you will likely see errors such as:
|
||||
|
||||
rm: conftest.dSYM: is a directory
|
||||
|
||||
This is a known issue and will be fixed in a later version of the
|
||||
autoconf suite. These errors can be safely ignored.
|
||||
|
||||
For later versions of OS X, (10.8 and 10.9), be sure to have Xcode
|
||||
AND Xcode Command Line Tools installed. httpd will built both with
|
||||
gcc and clang.
|
||||
|
||||
==========
|
||||
FreeBSD:
|
||||
autoconf 2.52 creates scripts that are incompatible with the Posix
|
||||
shell implementation (/bin/sh) on FreeBSD. Be sure to use v2.13
|
||||
of autoconf.
|
||||
|
||||
Threaded MPMs are not supported on FreeBSD 4.x. Current releases of
|
||||
FreeBSD 5.x (5.2 or later) support threaded MPMs correctly. You must pass
|
||||
'--enable-threads=yes' to APR's configure in order to enable threads.
|
||||
Additionally, you must use libthr or libkse via libmap.conf as the default
|
||||
libc_r is still broken as of this writing. Please consult the man page for
|
||||
libmap.conf for more details about configuring libthr or libkse.
|
||||
================
|
||||
HP-UX:
|
||||
The dlopen() system call in HP-UX has problems when loading/unloading
|
||||
C++ modules. The problem can be resolved by using shl_load() instead
|
||||
of dlopen(). This is fixed in the Apache 2.0.44 release.
|
||||
To enable loading of C++ modules, the httpd binary has to be linked with
|
||||
the following libraries :
|
||||
|
||||
HP-UX (11.0 / 11i):
|
||||
When using shl_load : "cpprt0_stub.s -lcl"
|
||||
When using dlopen : "cpprt0_stub.s -lcl -lCsup"
|
||||
|
||||
HP-UX (11i version 1.5 and greater):
|
||||
When using dlopen/shl_load : "cpprt0_stub.s -lcl -lunwind"
|
||||
|
||||
The cpprt0_stub.s can be downloaded from the web site :
|
||||
http://h21007.www2.hp.com/hpux-devtools/CXX/hpux-devtools.0107/0083.html
|
||||
|
||||
Compile cpprt0_stub.s with the PIC option
|
||||
cc -c +z cpprt0_stub.s
|
||||
- OR -
|
||||
gcc -c -fPIC cpprt0_stub.s
|
||||
================
|
||||
AIX, using the vendor C compiler with optimization:
|
||||
There is an issue with compiling server/core.c with optimization enabled
|
||||
which has been seen with C for AIX 5.0.2.3 and above. (5.0.2.0, 5.0.2.1,
|
||||
and 5.0.2.2 have an additional problem with Apache 2.0.x, so either upgrade
|
||||
the compiler or don't use optimization in order to avoid it.)
|
||||
|
||||
cc_r works fine with -O2 but xlc_r does not. In order to use xlc_r with
|
||||
-O2, apply the patch at
|
||||
|
||||
http://www.apache.org/dist/httpd/patches/apply_to_2.0.49/aix_xlc_optimization.patch
|
||||
|
||||
(That patch works with many recent levels of Apache 2+.)
|
||||
|
||||
================
|
||||
Solaris:
|
||||
|
||||
On Solaris, better performance may be achieved by using the Sun Studio
|
||||
compiler instead of gcc. As of version 11, it is now free (registration
|
||||
required). Download the compiler from:
|
||||
|
||||
http://developers.sun.com/prodtech/cc/downloads/index.jsp
|
||||
|
||||
If you use Sun Studio, the following compiler flags (CFLAGS) are
|
||||
recommended:
|
||||
|
||||
-XO4 -xchip=generic
|
||||
|
||||
================
|
||||
Ubuntu:
|
||||
|
||||
You will need to ensure that you have either libtool 1.5.6
|
||||
or 2.2.6b, or later. Expat 2.0.1 and PCRE 8.02 are also
|
||||
recommended to be installed. If building PCRE from source,
|
||||
you'll also need g++.
|
229
ROADMAP
Normal file
229
ROADMAP
Normal file
|
@ -0,0 +1,229 @@
|
|||
APACHE 2.x ROADMAP
|
||||
==================
|
||||
Last modified at [$Date: 2020-02-20 19:33:40 -0500 (Thu, 20 Feb 2020) $]
|
||||
|
||||
|
||||
WORKS IN PROGRESS
|
||||
-----------------
|
||||
|
||||
* Source code should follow style guidelines.
|
||||
OK, we all agree pretty code is good. Probably best to clean this
|
||||
up by hand immediately upon branching a 2.1 tree.
|
||||
Status: Justin volunteers to hand-edit the entire source tree ;)
|
||||
|
||||
Justin says:
|
||||
Recall when the release plan for 2.0 was written:
|
||||
Absolute Enforcement of an "Apache Style" for code.
|
||||
Watch this slip into 3.0.
|
||||
|
||||
David says:
|
||||
The style guide needs to be reviewed before this can be done.
|
||||
http://httpd.apache.org/dev/styleguide.html
|
||||
The current file is dated April 20th 1998!
|
||||
|
||||
OtherBill offers:
|
||||
It's survived since '98 because it's welldone :-) Suggest we
|
||||
simply follow whatever is documented in styleguide.html as we
|
||||
branch the next tree. Really sort of straightforward, if you
|
||||
dislike a bit within that doc, bring it up on the dev@httpd
|
||||
list prior to the next branch.
|
||||
|
||||
So Bill sums up ... let's get the code cleaned up in CVS head.
|
||||
Remember, it just takes cvs diff -b (that is, --ignore-space-change)
|
||||
to see the code changes and ignore that cruft. Get editing Justin :)
|
||||
|
||||
* Replace stat [deferred open] with open/fstat in directory_walk.
|
||||
Justin, Ian, OtherBill all interested in this. Implies setting up
|
||||
the apr_file_t member in request_rec, and having all modules use
|
||||
that file, and allow the cleanup to close it [if it isn't a shared,
|
||||
cached file handle.]
|
||||
|
||||
* The Async Apache Server implemented in terms of APR.
|
||||
[Bill Stoddard's pet project.]
|
||||
Message-ID: <008301c17d42$9b446970$01000100@sashimi> (dev@apr)
|
||||
|
||||
OtherBill notes that this can proceed in two parts...
|
||||
|
||||
Async accept, setup, and tear-down of the request
|
||||
e.g. dealing with the incoming request headers, prior to
|
||||
dispatching the request to a thread for processing.
|
||||
This doesn't need to wait for a 2.x/3.0 bump.
|
||||
|
||||
Async delegation of the entire request processing chain
|
||||
Too many handlers use stack storage and presume it is
|
||||
available for the life of the request, so a complete
|
||||
async implementation would need to happen 3.0 release.
|
||||
|
||||
Brian notes that async writes will provide a bigger
|
||||
scalability win than async reads for most servers.
|
||||
We may want to try a hybrid sync-read/async-write MPM
|
||||
as a next step. This should be relatively easy to
|
||||
build: start with the current worker or leader/followers
|
||||
model, but hand off each response brigade to a "completion
|
||||
thread" that multiplexes writes on many connections, so
|
||||
that the worker thread doesn't have to wait around for
|
||||
the sendfile to complete.
|
||||
|
||||
|
||||
MAKING APACHE REPOSITORY-AGNOSTIC
|
||||
(or: remove knowledge of the filesystem)
|
||||
|
||||
[ 2002/10/01: discussion in progress on items below; this isn't
|
||||
planned yet ]
|
||||
|
||||
* dav_resource concept for an HTTP resource ("ap_resource")
|
||||
|
||||
* r->filename, r->canonical_filename, r->finfo need to
|
||||
disappear. All users need to use new APIs on the ap_resource
|
||||
object.
|
||||
|
||||
(backwards compat: today, when this occurs with mod_dav and a
|
||||
custom backend, the above items refer to the topmost directory
|
||||
mapped by a location; e.g. docroot)
|
||||
|
||||
Need to preserve a 'filename'-like string for mime-by-name
|
||||
sorts of operations. But this only needs to be the name itself
|
||||
and not a full path.
|
||||
|
||||
Justin: Can we leverage the path info, or do we not trust the
|
||||
user?
|
||||
|
||||
gstein: well, it isn't the "path info", but the actual URI of
|
||||
the resource. And of course we trust the user... that is
|
||||
the resource they requested.
|
||||
|
||||
dav_resource->uri is the field you want. path_info might
|
||||
still exist, but that portion might be related to the
|
||||
CGI concept of "path translated" or some other further
|
||||
resolution.
|
||||
|
||||
To continue, I would suggest that "path translated" and
|
||||
having *any* path info is Badness. It means that you did
|
||||
not fully resolve a resource for the given URI. The
|
||||
"abs_path" in a URI identifies a resource, and that
|
||||
should get fully resolved. None of this "resolve to
|
||||
<here> and then we have a magical second resolution
|
||||
(inside the CGI script)" or somesuch.
|
||||
|
||||
Justin: Well, let's consider mod_mbox for a second. It is sort of
|
||||
a virtual filesystem in its own right - as it introduces
|
||||
it's own notion of a URI space, but it is intrinsically
|
||||
tied to the filesystem to do the lookups. But, for the
|
||||
portion that isn't resolved on the file system, it has
|
||||
its own addressing scheme. Do we need the ability to
|
||||
layer resolution?
|
||||
|
||||
* The translate_name hook goes away
|
||||
|
||||
Wrowe altogether disagrees. translate_name today even operates
|
||||
on URIs ... this mechanism needs to be preserved.
|
||||
|
||||
* The doc for map_to_storage is totally opaque to me. It has
|
||||
something to do with filesystems, but it also talks about
|
||||
security and per_dir_config and other stuff. I presume something
|
||||
needs to happen there -- at least better doc.
|
||||
|
||||
Wrowe agrees and will write it up.
|
||||
|
||||
* The directory_walk concept disappears. All configuration is
|
||||
tagged to Locations. The "mod_filesystem" module might have some
|
||||
internal concept of the same config appearing in multiple
|
||||
places, but that is handled internally rather than by Apache
|
||||
core.
|
||||
|
||||
Wrowe suggests this is wrong, instead it's private to filesystem
|
||||
requests, and is already invoked from map_to_storage, not the core
|
||||
handler. <Directory > and <Files > blocks are preserved as-is,
|
||||
but <Directory > sections become specific to the filesystem handler
|
||||
alone. Because alternate filesystem schemes could be loaded, this
|
||||
should be exposed, from the core, for other file-based stores to
|
||||
share. Consider an archive store where the layers become
|
||||
<Directory path> -> <Archive store> -> <File name>
|
||||
|
||||
Justin: How do we map Directory entries to Locations?
|
||||
|
||||
* The "Location tree" is an in-memory representation of the URL
|
||||
namespace. Nodes of the tree have configuration specific to that
|
||||
location in the namespace.
|
||||
|
||||
Something like:
|
||||
|
||||
typedef struct {
|
||||
const char *name; /* name of this node relative to parent */
|
||||
|
||||
struct ap_conf_vector_t *locn_config;
|
||||
|
||||
apr_hash_t *children; /* NULL if no child configs */
|
||||
} ap_locn_node;
|
||||
|
||||
The following config:
|
||||
|
||||
<Location /server-status>
|
||||
SetHandler server-status
|
||||
Order deny,allow
|
||||
Deny from all
|
||||
Allow from 127.0.0.1
|
||||
</Location>
|
||||
|
||||
Creates a node with name=="server_status", and the node is a
|
||||
child of the "/" node. (hmm. node->name is redundant with the
|
||||
hash key; maybe drop node->name)
|
||||
|
||||
In the config vector, mod_access has stored its Order, Deny, and
|
||||
Allow configs. mod_core has stored the SetHandler.
|
||||
|
||||
During the Location walk, we merge the config vectors normally.
|
||||
|
||||
Note that an Alias simply associates a filesystem path (in
|
||||
mod_filesystem) with that Location in the tree. Merging
|
||||
continues with child locations, but a merge is never done
|
||||
through filesystem locations. Config on a specific subdir needs
|
||||
to be mapped back into the corresponding point in the Location
|
||||
tree for proper merging.
|
||||
|
||||
* Config is parsed into a tree, as we did for the 2.0 timeframe,
|
||||
but that tree is just a representation of the config (for
|
||||
multiple runs and for in-memory manipulation and usage). It is
|
||||
unrelated to the "Location tree".
|
||||
|
||||
* Calls to apr_file_io functions generally need to be replaced
|
||||
with operations against the ap_resource. For example, rather
|
||||
than calling apr_dir_open/read/close(), a caller uses
|
||||
resource->repos->get_children() or somesuch.
|
||||
|
||||
Note that things like mod_dir, mod_autoindex, and mod_negotiation
|
||||
need to be converted to use these mechanisms so that their
|
||||
functions will work on logical repositories rather than just
|
||||
filesystems.
|
||||
|
||||
* How do we handle CGI scripts? Especially when the resource may
|
||||
not be backed by a file? Ideally, we should be able to come up
|
||||
with some mechanism to allow CGIs to work in a
|
||||
repository-independent manner.
|
||||
|
||||
- Writing the virtual data as a file and then executing it?
|
||||
- Can a shell be executed in a streamy manner? (Portably?)
|
||||
- Have an 'execute_resource' hook/func that allows the
|
||||
repository to choose its manner - be it exec() or whatever.
|
||||
- Won't this approach lead to duplication of code? Helper fns?
|
||||
|
||||
gstein: PHP, Perl, and Python scripts are nominally executed by
|
||||
a filter inserted by mod_php/perl/python. I'd suggest
|
||||
that shell/batch scripts are similar.
|
||||
|
||||
But to ask further: what if it is an executable
|
||||
*program* rather than just a script? Do we yank that out
|
||||
of the repository, drop it onto the filesystem, and run
|
||||
it? eeewwwww...
|
||||
|
||||
I'll vote -0.9 for CGIs as a filter. Keep 'em handlers.
|
||||
|
||||
Justin: So, do we give up executing CGIs from virtual repositories?
|
||||
That seems like a sad tradeoff to make. I'd like to have
|
||||
my CGI scripts under DAV (SVN) control.
|
||||
|
||||
* How do we handle overlaying of Location and Directory entries?
|
||||
Right now, we have a problem when /cgi-bin/ is ScriptAlias'd and
|
||||
mod_dav has control over /. Some people believe that /cgi-bin/
|
||||
shouldn't be under DAV control, while others do believe it
|
||||
should be. What's the right strategy?
|
154
VERSIONING
Normal file
154
VERSIONING
Normal file
|
@ -0,0 +1,154 @@
|
|||
APACHE 2.x VERSIONING
|
||||
=====================
|
||||
[$LastChangedDate: 2020-02-20 19:33:40 -0500 (Thu, 20 Feb 2020) $]
|
||||
|
||||
|
||||
INTRODUCTION
|
||||
------------
|
||||
The Apache HTTP Server project must balance two competing and disjoint
|
||||
objectives: maintain stable code for third party authors, distributors and
|
||||
most importantly users so that bug and security fixes can be quickly adopted
|
||||
without significant hardship due to user-visible changes; and continue the
|
||||
development process that requires ongoing redesign to correct earlier
|
||||
oversights and to add additional features.
|
||||
|
||||
The Apache HTTP Server, through version 2.0, used the Module Magic Number (MMN)
|
||||
to reflect API changes. This had the shortcoming of often leaving users
|
||||
hunting to replace binary third party modules that were now incompatible.
|
||||
This also left module authors searching through the API change histories to
|
||||
determine the exact cause for the MMN change and whether their module was
|
||||
affected.
|
||||
|
||||
With the simultaneous release of Apache 2.2-stable and Apache 2.3-development,
|
||||
the Apache HTTP Server project is moving towards a more predictable stable
|
||||
release cycle, while allowing forward progress to occur without concern
|
||||
for breaking the stable branch. This document explains the rationale between
|
||||
the two versions and their behavior.
|
||||
|
||||
|
||||
STABLE RELEASES, 2.{even}.{revision}
|
||||
------------------------------------
|
||||
|
||||
All even numbered releases will be considered stable revisions.
|
||||
|
||||
Stable revisions will retain forward compatibility to the maximum
|
||||
possible extent. Features may be added during minor revisions, and
|
||||
features may be deprecated by making appropriate notations in the
|
||||
documentation, but no features may be removed.
|
||||
|
||||
In essence, that implies that you can upgrade from one minor revision
|
||||
to the next with a minimum of trouble. In particular, this means:
|
||||
|
||||
* The Module API will retain forward compatibility.
|
||||
It will not be necessary to update modules to work with new
|
||||
revisions of the stable tree.
|
||||
|
||||
* The run-time configuration will be forward compatible.
|
||||
No configuration changes will be necessary to work with new
|
||||
revisions of the stable tree.
|
||||
|
||||
* Compile-time configuration will be forward compatible.
|
||||
The configure command line options that work in one release
|
||||
of the stable tree will also work in the next release.
|
||||
|
||||
As always, it will be necessary to test any new release to assure
|
||||
that it works correctly with a particular configuration and a
|
||||
particular set of modules, but every effort will be made to assure
|
||||
that upgrades are as smooth as possible.
|
||||
|
||||
In addition, the following development restrictions will aid in
|
||||
keeping the stable tree as safe as possible:
|
||||
|
||||
* No 'Experimental' modules; while it may be possible (based on API changes
|
||||
required to support a given module) to load a 2.3-development module into
|
||||
a 2.2-stable build of Apache, there are no guarantees. Experimental
|
||||
modules will be introduced to the 2.3-development versions and either
|
||||
added to 2.2-stable once they are proven and compatible, or deferred
|
||||
to the 2.4-stable release if they cannot be incorporated in the current
|
||||
stable release due to API change requirements.
|
||||
|
||||
* The stable subversion tree should not remain unstable at any time. Atomic
|
||||
commits ought be used to introduce code from the development version to the
|
||||
stable tree. At any given time a security release may be in preparation,
|
||||
unbeknownst to other contributors. At any given time, testers may be
|
||||
checking out SVN trunk to confirm that a bug has been corrected. And as
|
||||
all code was well-tested in development prior to committing to the stable
|
||||
tree, there is really no reason for this tree to be broken for more than
|
||||
a few minutes during a lengthy commit.
|
||||
|
||||
In order to avoid 'skipped' release numbers in the stable releases, the
|
||||
Release Manager will generally roll a release candidate (APACHE_#_#_#_RC#)
|
||||
tag. Release Candidate tarballs will be announced to the
|
||||
stable-testers@httpd.apache.org for the stable tree. Then, the participants
|
||||
will vote on the quality of the proposed release tarball.
|
||||
|
||||
The final APACHE_#_#_# tag will not exist until the APACHE_#_#_#_RC# candidate
|
||||
has passed the usual votes to release that version. Only then is the final
|
||||
tarball packaged, removing all -rc# designations from the version number, and
|
||||
tagging the tree with the release number.
|
||||
|
||||
DEVELOPMENT RELEASES, 2.{odd}.{revision}
|
||||
-----------------------------------------
|
||||
|
||||
All odd numbered releases designate the 'next' possible stable release,
|
||||
therefore the current development version will always be one greater than
|
||||
the current stable release. Work proceeds on development releases, permitting
|
||||
the modification of the MMN at any time in order to correct deficiencies
|
||||
or shortcomings in the API. This means that modules from one development
|
||||
release to another may not be binary compatible, or may not successfully
|
||||
compile without modification to accommodate the API changes.
|
||||
|
||||
The only 'supported' development release at any time will be the most
|
||||
recently released version. Developers will not be answering bug reports
|
||||
of older development releases once a new release is available. It becomes
|
||||
the responsibility of the reporter to use the latest development version
|
||||
to confirm that any issue still exists.
|
||||
|
||||
Any new code, new API features or new ('experimental') modules may be
|
||||
promoted at any time to the next stable release, by a vote of the project
|
||||
contributors. This vote is based on the technical stability of the new
|
||||
code and the stability of the interface. Once moved to stable, that feature
|
||||
cannot change for the remainder of that stable release cycle, so the vote must
|
||||
reflect that the final decisions on the behavior and naming of that new
|
||||
feature were reached. Vetos continue to apply to this choice of introducing
|
||||
the new work to the stable version.
|
||||
|
||||
At any given time, when the quality of changes to the development branch
|
||||
is considered release quality, that version may become a candidate for the
|
||||
next stable release. This includes some or all of the API changes, promoting
|
||||
experimental modules to stable or deprecating and eliminating older modules
|
||||
from the last stable release. All of these choices are considered by the
|
||||
project as a group in the interests of promoting the stable release, so that
|
||||
any given change may be 'deferred' for a future release by the group, rather
|
||||
than introduce unacceptable risks to adopting the next stable release.
|
||||
|
||||
Third party module authors are strongly encouraged to test with the latest
|
||||
development version. This assures that the module will be ready for the next
|
||||
stable release, but more importantly, the author can react to shortcomings
|
||||
in the API early enough to warn the dev@httpd.apache.org community of the
|
||||
shortcomings so that they can be addressed before the stable release. The
|
||||
entire burden is on the module author to anticipate the needs of their module
|
||||
before the stable release is created. Once a new stable release cycle has
|
||||
begun, that API will be present for the lifetime of the stable release. Any
|
||||
desired changes in the stable versions must wait for inclusion into the next
|
||||
release cycle.
|
||||
|
||||
When deciding to promote a development tree to being stable, a determination
|
||||
should be made whether the changes since the last stable version warrant a
|
||||
major version bump. That is, if 2.2 is the current stable version and 2.3 is
|
||||
'ready' to become stable, the group needs to decide if the next stable
|
||||
version is 2.4 or 3.0. One suggested rule of thumb is that if it requires
|
||||
too much effort to port a module from 2.2 to 2.4, then the stable version
|
||||
should be labeled 3.0.
|
||||
|
||||
In order to ease the burden of creating development releases, the process
|
||||
for packaging a development releases is less formal than for the stable
|
||||
release. This strategy reflects the fact that while in development, versions
|
||||
are cheap. Development releases may be classified as alpha, beta, or GA
|
||||
to reflect the group's perceived stability of the tree. Development releases
|
||||
may be made at any time by any committer.
|
||||
|
||||
Please read the following link for a more detailed description of the
|
||||
development release strategy:
|
||||
|
||||
http://httpd.apache.org/dev/release.html
|
783
acinclude.m4
Normal file
783
acinclude.m4
Normal file
|
@ -0,0 +1,783 @@
|
|||
|
||||
dnl APACHE_HELP_STRING(LHS, RHS)
|
||||
dnl Autoconf 2.50 can not handle substr correctly. It does have
|
||||
dnl AC_HELP_STRING, so let's try to call it if we can.
|
||||
dnl Note: this define must be on one line so that it can be properly returned
|
||||
dnl as the help string.
|
||||
AC_DEFUN([APACHE_HELP_STRING],[ifelse(regexp(AC_ACVERSION, 2\.1), -1, AC_HELP_STRING($1,$2),[ ]$1 substr([ ],len($1))$2)])dnl
|
||||
|
||||
dnl APACHE_SUBST(VARIABLE)
|
||||
dnl Makes VARIABLE available in generated files
|
||||
dnl (do not use @variable@ in Makefiles, but $(variable))
|
||||
AC_DEFUN([APACHE_SUBST],[
|
||||
APACHE_VAR_SUBST="$APACHE_VAR_SUBST $1"
|
||||
AC_SUBST($1)
|
||||
])
|
||||
|
||||
dnl APACHE_FAST_OUTPUT(FILENAME)
|
||||
dnl Perform substitutions on FILENAME (Makefiles only)
|
||||
AC_DEFUN([APACHE_FAST_OUTPUT],[
|
||||
APACHE_FAST_OUTPUT_FILES="$APACHE_FAST_OUTPUT_FILES $1"
|
||||
])
|
||||
|
||||
dnl APACHE_GEN_CONFIG_VARS
|
||||
dnl Creates config_vars.mk
|
||||
AC_DEFUN([APACHE_GEN_CONFIG_VARS],[
|
||||
APACHE_SUBST(HTTPD_VERSION)
|
||||
APACHE_SUBST(HTTPD_MMN)
|
||||
APACHE_SUBST(abs_srcdir)
|
||||
APACHE_SUBST(bindir)
|
||||
APACHE_SUBST(sbindir)
|
||||
APACHE_SUBST(cgidir)
|
||||
APACHE_SUBST(logfiledir)
|
||||
APACHE_SUBST(exec_prefix)
|
||||
APACHE_SUBST(datadir)
|
||||
APACHE_SUBST(localstatedir)
|
||||
APACHE_SUBST(mandir)
|
||||
APACHE_SUBST(libdir)
|
||||
APACHE_SUBST(libexecdir)
|
||||
APACHE_SUBST(htdocsdir)
|
||||
APACHE_SUBST(manualdir)
|
||||
APACHE_SUBST(includedir)
|
||||
APACHE_SUBST(errordir)
|
||||
APACHE_SUBST(iconsdir)
|
||||
APACHE_SUBST(sysconfdir)
|
||||
APACHE_SUBST(installbuilddir)
|
||||
APACHE_SUBST(runtimedir)
|
||||
APACHE_SUBST(proxycachedir)
|
||||
APACHE_SUBST(other_targets)
|
||||
APACHE_SUBST(progname)
|
||||
APACHE_SUBST(prefix)
|
||||
APACHE_SUBST(AWK)
|
||||
APACHE_SUBST(CC)
|
||||
APACHE_SUBST(CPP)
|
||||
APACHE_SUBST(CXX)
|
||||
APACHE_SUBST(CPPFLAGS)
|
||||
APACHE_SUBST(CFLAGS)
|
||||
APACHE_SUBST(CXXFLAGS)
|
||||
APACHE_SUBST(LTFLAGS)
|
||||
APACHE_SUBST(LDFLAGS)
|
||||
APACHE_SUBST(LT_LDFLAGS)
|
||||
APACHE_SUBST(SH_LDFLAGS)
|
||||
APACHE_SUBST(HTTPD_LDFLAGS)
|
||||
APACHE_SUBST(UTIL_LDFLAGS)
|
||||
APACHE_SUBST(LIBS)
|
||||
APACHE_SUBST(DEFS)
|
||||
APACHE_SUBST(INCLUDES)
|
||||
APACHE_SUBST(NOTEST_CPPFLAGS)
|
||||
APACHE_SUBST(NOTEST_CFLAGS)
|
||||
APACHE_SUBST(NOTEST_CXXFLAGS)
|
||||
APACHE_SUBST(NOTEST_LDFLAGS)
|
||||
APACHE_SUBST(NOTEST_LIBS)
|
||||
APACHE_SUBST(EXTRA_CPPFLAGS)
|
||||
APACHE_SUBST(EXTRA_CFLAGS)
|
||||
APACHE_SUBST(EXTRA_CXXFLAGS)
|
||||
APACHE_SUBST(EXTRA_LDFLAGS)
|
||||
APACHE_SUBST(EXTRA_LIBS)
|
||||
APACHE_SUBST(EXTRA_INCLUDES)
|
||||
APACHE_SUBST(INTERNAL_CPPFLAGS)
|
||||
APACHE_SUBST(LIBTOOL)
|
||||
APACHE_SUBST(SHELL)
|
||||
APACHE_SUBST(RSYNC)
|
||||
APACHE_SUBST(SVN)
|
||||
APACHE_SUBST(MODULE_DIRS)
|
||||
APACHE_SUBST(MODULE_CLEANDIRS)
|
||||
APACHE_SUBST(PORT)
|
||||
APACHE_SUBST(SSLPORT)
|
||||
APACHE_SUBST(CORE_IMPLIB_FILE)
|
||||
APACHE_SUBST(CORE_IMPLIB)
|
||||
APACHE_SUBST(SH_LIBS)
|
||||
APACHE_SUBST(SH_LIBTOOL)
|
||||
APACHE_SUBST(MK_IMPLIB)
|
||||
APACHE_SUBST(MKDEP)
|
||||
APACHE_SUBST(INSTALL_PROG_FLAGS)
|
||||
APACHE_SUBST(MPM_MODULES)
|
||||
APACHE_SUBST(ENABLED_MPM_MODULE)
|
||||
APACHE_SUBST(DSO_MODULES)
|
||||
APACHE_SUBST(ENABLED_DSO_MODULES)
|
||||
APACHE_SUBST(LOAD_ALL_MODULES)
|
||||
APACHE_SUBST(APR_BINDIR)
|
||||
APACHE_SUBST(APR_INCLUDEDIR)
|
||||
APACHE_SUBST(APR_VERSION)
|
||||
APACHE_SUBST(APR_CONFIG)
|
||||
APACHE_SUBST(APU_BINDIR)
|
||||
APACHE_SUBST(APU_INCLUDEDIR)
|
||||
APACHE_SUBST(APU_VERSION)
|
||||
APACHE_SUBST(APU_CONFIG)
|
||||
|
||||
abs_srcdir="`(cd $srcdir && pwd)`"
|
||||
|
||||
AC_MSG_NOTICE([creating config_vars.mk])
|
||||
test -d build || $mkdir_p build
|
||||
> build/config_vars.mk
|
||||
for i in $APACHE_VAR_SUBST; do
|
||||
eval echo "$i = \$$i" >> build/config_vars.mk
|
||||
done
|
||||
])
|
||||
|
||||
dnl APACHE_GEN_MAKEFILES
|
||||
dnl Creates Makefiles
|
||||
AC_DEFUN([APACHE_GEN_MAKEFILES],[
|
||||
$SHELL $srcdir/build/fastgen.sh $srcdir $ac_cv_mkdir_p $BSD_MAKEFILE $APACHE_FAST_OUTPUT_FILES
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_TYPE_RLIM_T
|
||||
dnl
|
||||
dnl If rlim_t is not defined, define it to int
|
||||
dnl
|
||||
AC_DEFUN([APACHE_TYPE_RLIM_T], [
|
||||
AC_CACHE_CHECK([for rlim_t], ac_cv_type_rlim_t, [
|
||||
AC_TRY_COMPILE([
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/resource.h>
|
||||
], [rlim_t spoon;], [
|
||||
ac_cv_type_rlim_t=yes
|
||||
],[ac_cv_type_rlim_t=no
|
||||
])
|
||||
])
|
||||
if test "$ac_cv_type_rlim_t" = "no" ; then
|
||||
AC_DEFINE(rlim_t, int,
|
||||
[Define to 'int' if <sys/resource.h> doesn't define it for us])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl the list of build variables which are available for customization on a
|
||||
dnl per module subdir basis (to be inserted into modules.mk with a "MOD_"
|
||||
dnl prefix, i.e. MOD_CFLAGS etc.). Used in APACHE_MODPATH_{INIT,FINISH}.
|
||||
define(mod_buildvars, [CFLAGS CXXFLAGS CPPFLAGS LDFLAGS LIBS INCLUDES])
|
||||
dnl
|
||||
dnl APACHE_MODPATH_INIT(modpath)
|
||||
AC_DEFUN([APACHE_MODPATH_INIT],[
|
||||
current_dir=$1
|
||||
modpath_current=modules/$1
|
||||
modpath_static=
|
||||
modpath_shared=
|
||||
for var in mod_buildvars; do
|
||||
eval MOD_$var=
|
||||
done
|
||||
test -d $1 || $srcdir/build/mkdir.sh $modpath_current
|
||||
> $modpath_current/modules.mk
|
||||
])dnl
|
||||
dnl
|
||||
AC_DEFUN([APACHE_MODPATH_FINISH],[
|
||||
echo "DISTCLEAN_TARGETS = modules.mk" >> $modpath_current/modules.mk
|
||||
echo "static = $modpath_static" >> $modpath_current/modules.mk
|
||||
echo "shared = $modpath_shared" >> $modpath_current/modules.mk
|
||||
for var in mod_buildvars; do
|
||||
if eval val=\"\$MOD_$var\"; test -n "$val"; then
|
||||
echo "MOD_$var = $val" >> $modpath_current/modules.mk
|
||||
fi
|
||||
done
|
||||
if test ! -z "$modpath_static" -o ! -z "$modpath_shared"; then
|
||||
MODULE_DIRS="$MODULE_DIRS $current_dir"
|
||||
else
|
||||
MODULE_CLEANDIRS="$MODULE_CLEANDIRS $current_dir"
|
||||
fi
|
||||
APACHE_FAST_OUTPUT($modpath_current/Makefile)
|
||||
])dnl
|
||||
dnl
|
||||
dnl APACHE_MODPATH_ADD(name[, shared[, objects [, ldflags[, libs]]]])
|
||||
AC_DEFUN([APACHE_MODPATH_ADD],[
|
||||
if test -z "$3"; then
|
||||
objects="mod_$1.lo"
|
||||
else
|
||||
objects="$3"
|
||||
fi
|
||||
|
||||
if test -z "$module_standalone"; then
|
||||
if test -z "$2"; then
|
||||
# The filename of a convenience library must have a "lib" prefix:
|
||||
libname="libmod_$1.la"
|
||||
BUILTIN_LIBS="$BUILTIN_LIBS $modpath_current/$libname"
|
||||
modpath_static="$modpath_static $libname"
|
||||
cat >>$modpath_current/modules.mk<<EOF
|
||||
$libname: $objects
|
||||
\$(MOD_LINK) $objects $5
|
||||
EOF
|
||||
if test ! -z "$5"; then
|
||||
APR_ADDTO(AP_LIBS, [$5])
|
||||
fi
|
||||
else
|
||||
apache_need_shared=yes
|
||||
libname="mod_$1.la"
|
||||
shobjects=`echo $objects | sed 's/\.lo/.slo/g'`
|
||||
modpath_shared="$modpath_shared $libname"
|
||||
cat >>$modpath_current/modules.mk<<EOF
|
||||
$libname: $shobjects
|
||||
\$(SH_LINK) -rpath \$(libexecdir) -module -avoid-version $4 $objects $5
|
||||
EOF
|
||||
fi
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APACHE_MPM_MODULE(name[, shared[, objects[, config[, path[, libs]]]]])
|
||||
dnl
|
||||
dnl Provide information for building the MPM. (Enablement is handled using
|
||||
dnl --with-mpm/--enable-mpms-shared.)
|
||||
dnl
|
||||
dnl name -- name of MPM, same as MPM directory name
|
||||
dnl shared -- "shared" to indicate shared module build, empty string otherwise
|
||||
dnl objects -- one or more .lo files to link into the MPM module (default: mpmname.lo)
|
||||
dnl config -- configuration logic to run if the MPM is enabled
|
||||
dnl path -- relative path to MPM (default: server/mpm/mpmname)
|
||||
dnl libs -- libs needed by this MPM
|
||||
dnl
|
||||
AC_DEFUN([APACHE_MPM_MODULE],[
|
||||
if ap_mpm_is_enabled $1; then
|
||||
if test -z "$3"; then
|
||||
objects="$1.lo"
|
||||
else
|
||||
objects="$3"
|
||||
fi
|
||||
|
||||
if test -z "$5"; then
|
||||
mpmpath="server/mpm/$1"
|
||||
else
|
||||
mpmpath=$5
|
||||
fi
|
||||
|
||||
dnl VPATH support
|
||||
test -d $mpmpath || $srcdir/build/mkdir.sh $mpmpath
|
||||
|
||||
APACHE_FAST_OUTPUT($mpmpath/Makefile)
|
||||
|
||||
if test -z "$2"; then
|
||||
APR_ADDTO(AP_LIBS, [$6])
|
||||
libname="lib$1.la"
|
||||
cat >$mpmpath/modules.mk<<EOF
|
||||
$libname: $objects
|
||||
\$(MOD_LINK) $objects
|
||||
DISTCLEAN_TARGETS = modules.mk
|
||||
static = $libname
|
||||
shared =
|
||||
EOF
|
||||
else
|
||||
apache_need_shared=yes
|
||||
libname="mod_mpm_$1.la"
|
||||
shobjects=`echo $objects | sed 's/\.lo/.slo/g'`
|
||||
cat >$mpmpath/modules.mk<<EOF
|
||||
$libname: $shobjects
|
||||
\$(SH_LINK) -rpath \$(libexecdir) -module -avoid-version $objects $6
|
||||
DISTCLEAN_TARGETS = modules.mk
|
||||
static =
|
||||
shared = $libname
|
||||
EOF
|
||||
MPM_MODULES="$MPM_MODULES mpm_$1"
|
||||
# add default MPM to LoadModule list
|
||||
if test $1 = $default_mpm; then
|
||||
ENABLED_MPM_MODULE="mpm_$1"
|
||||
fi
|
||||
fi
|
||||
$4
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APACHE_MODULE(name, helptext[, objects[, structname[, default[, config[, prereq_module]]]]])
|
||||
dnl
|
||||
dnl default is one of:
|
||||
dnl yes -- enabled by default. user must explicitly disable.
|
||||
dnl no -- disabled under default, most, all. user must explicitly enable.
|
||||
dnl most -- disabled by default. enabled explicitly or with most or all.
|
||||
dnl static -- enabled as static by default, must be explicitly changed.
|
||||
dnl "" -- disabled under default, most. enabled explicitly or with all.
|
||||
dnl XXX: The arg must really be empty here. Passing an empty shell
|
||||
dnl XXX: variable doesn't work for some reason. This should be
|
||||
dnl XXX: fixed.
|
||||
dnl
|
||||
dnl basically: yes/no is a hard setting. "most" means follow the "most"
|
||||
dnl setting. otherwise, fall under the "all" setting.
|
||||
dnl explicit yes/no always overrides, except if the user selects
|
||||
dnl "reallyall".
|
||||
dnl
|
||||
dnl prereq_module is a module (without the "mod_" prefix) that must be enabled
|
||||
dnl if the current module is enabled. If the current module is built
|
||||
dnl statically, prereq_module must be built statically, too. If these
|
||||
dnl conditions are not fulfilled, configure will abort if the current module
|
||||
dnl has been enabled explicitly. Otherwise, configure will disable the
|
||||
dnl current module.
|
||||
dnl prereq_module's APACHE_MODULE() statement must have been processed
|
||||
dnl before the current APACHE_MODULE() statement.
|
||||
dnl
|
||||
AC_DEFUN([APACHE_MODULE],[
|
||||
AC_MSG_CHECKING(whether to enable mod_$1)
|
||||
define([optname],[--]ifelse($5,yes,disable,enable)[-]translit($1,_,-))dnl
|
||||
AC_ARG_ENABLE(translit($1,_,-),APACHE_HELP_STRING(optname(),$2),force_$1=$enableval,enable_$1=ifelse($5,,maybe-all,$5))
|
||||
undefine([optname])dnl
|
||||
_apmod_extra_msg=""
|
||||
dnl If the module was not explicitly requested, allow it to disable itself if
|
||||
dnl its pre-reqs fail.
|
||||
case "$enable_$1" in
|
||||
yes|static|shared)
|
||||
_apmod_required="yes"
|
||||
;;
|
||||
*)
|
||||
_apmod_required="no"
|
||||
;;
|
||||
esac
|
||||
if test "$enable_$1" = "static" -o "$enable_$1" = "shared"; then
|
||||
:
|
||||
elif test "$enable_$1" = "yes"; then
|
||||
enable_$1=$module_default
|
||||
elif test "$enable_$1" = "few"; then
|
||||
if test "$module_selection" = "few" -o "$module_selection" = "most" -o \
|
||||
"$module_selection" = "all" -o "$module_selection" = "reallyall"
|
||||
then
|
||||
enable_$1=$module_default
|
||||
else
|
||||
enable_$1=no
|
||||
fi
|
||||
_apmod_extra_msg=" ($module_selection)"
|
||||
elif test "$enable_$1" = "most"; then
|
||||
if test "$module_selection" = "most" -o "$module_selection" = "all" -o \
|
||||
"$module_selection" = "reallyall"
|
||||
then
|
||||
enable_$1=$module_default
|
||||
else
|
||||
enable_$1=no
|
||||
fi
|
||||
_apmod_extra_msg=" ($module_selection)"
|
||||
elif test "$enable_$1" = "all" -o "$enable_$1" = "maybe-all"; then
|
||||
if test "$module_selection" = "all" -o "$module_selection" = "reallyall"
|
||||
then
|
||||
enable_$1=$module_default
|
||||
_apmod_extra_msg=" ($module_selection)"
|
||||
else
|
||||
enable_$1=no
|
||||
fi
|
||||
elif test "$enable_$1" = "reallyall" -o "$enable_$1" = "no" ; then
|
||||
if test "$module_selection" = "reallyall" -a "$force_$1" != "no" ; then
|
||||
enable_$1=$module_default
|
||||
_apmod_extra_msg=" ($module_selection)"
|
||||
else
|
||||
enable_$1=no
|
||||
fi
|
||||
else
|
||||
enable_$1=no
|
||||
fi
|
||||
if test "$enable_$1" != "no"; then
|
||||
dnl If we plan to enable it, allow the module to run some autoconf magic
|
||||
dnl that may disable it because of missing dependencies.
|
||||
ifelse([$6$7],,:,
|
||||
[AC_MSG_RESULT([checking dependencies])
|
||||
ifelse([$7],,:,[m4_foreach([prereq],[$7],
|
||||
[if test "$enable_[]prereq" = "no" ; then
|
||||
enable_$1=no
|
||||
AC_MSG_WARN("mod_[]prereq is disabled but required for mod_$1")
|
||||
elif test "$enable_$1" = "static" && test "$enable_[]prereq" != "static" ; then
|
||||
enable_$1=$enable_[]prereq
|
||||
AC_MSG_WARN("building mod_$1 shared because mod_[]prereq is built shared")
|
||||
el])se])
|
||||
ifelse([$6],,:,[ $6])
|
||||
ifelse([$7],,:,[fi])
|
||||
AC_MSG_CHECKING(whether to enable mod_$1)
|
||||
if test "$enable_$1" = "no"; then
|
||||
if test "$_apmod_required" = "no"; then
|
||||
_apmod_extra_msg=" (disabled)"
|
||||
else
|
||||
AC_MSG_ERROR([mod_$1 has been requested but can not be built due to prerequisite failures])
|
||||
fi
|
||||
fi])
|
||||
fi
|
||||
AC_MSG_RESULT($enable_$1$_apmod_extra_msg)
|
||||
if test "$enable_$1" != "no"; then
|
||||
case "$enable_$1" in
|
||||
static*)
|
||||
MODLIST="$MODLIST ifelse($4,,$1,$4)"
|
||||
if test "$1" = "so"; then
|
||||
sharedobjs=yes
|
||||
fi
|
||||
shared="";;
|
||||
*)
|
||||
sharedobjs=yes
|
||||
shared=yes
|
||||
DSO_MODULES="$DSO_MODULES $1"
|
||||
if test "$5" = "yes" ; then
|
||||
ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},$1"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
define([modprefix], [MOD_]translit($1, [a-z-], [A-Z_]))
|
||||
APACHE_MODPATH_ADD($1, $shared, $3,, [\$(]modprefix[_LDADD)])
|
||||
APACHE_SUBST(modprefix[_LDADD])
|
||||
undefine([modprefix])
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APACHE_ENABLE_MODULES
|
||||
dnl
|
||||
AC_DEFUN([APACHE_ENABLE_MODULES],[
|
||||
module_selection=most
|
||||
module_default=shared
|
||||
|
||||
dnl Check whether we have DSO support.
|
||||
dnl If "yes", we build shared modules by default.
|
||||
APR_CHECK_APR_DEFINE(APR_HAS_DSO)
|
||||
|
||||
if test $ac_cv_define_APR_HAS_DSO = "no"; then
|
||||
AC_MSG_WARN([Missing DSO support - building static modules by default.])
|
||||
module_default=static
|
||||
fi
|
||||
|
||||
|
||||
AC_ARG_ENABLE(modules,
|
||||
APACHE_HELP_STRING(--enable-modules=MODULE-LIST,Space-separated list of modules to enable | "all" | "most" | "few" | "none" | "reallyall"),[
|
||||
if test "$enableval" = "none"; then
|
||||
module_default=no
|
||||
module_selection=none
|
||||
else
|
||||
for i in $enableval; do
|
||||
if test "$i" = "all" -o "$i" = "most" -o "$i" = "few" -o "$i" = "reallyall"
|
||||
then
|
||||
module_selection=$i
|
||||
else
|
||||
i=`echo $i | sed 's/-/_/g'`
|
||||
eval "enable_$i=shared"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(mods-shared,
|
||||
APACHE_HELP_STRING(--enable-mods-shared=MODULE-LIST,Space-separated list of shared modules to enable | "all" | "most" | "few" | "reallyall"),[
|
||||
for i in $enableval; do
|
||||
if test "$i" = "all" -o "$i" = "most" -o "$i" = "few" -o "$i" = "reallyall"
|
||||
then
|
||||
module_selection=$i
|
||||
module_default=shared
|
||||
else
|
||||
i=`echo $i | sed 's/-/_/g'`
|
||||
eval "enable_$i=shared"
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(mods-static,
|
||||
APACHE_HELP_STRING(--enable-mods-static=MODULE-LIST,Space-separated list of static modules to enable | "all" | "most" | "few" | "reallyall"),[
|
||||
for i in $enableval; do
|
||||
if test "$i" = "all" -o "$i" = "most" -o "$i" = "few" -o "$i" = "reallyall"; then
|
||||
module_selection=$i
|
||||
module_default=static
|
||||
else
|
||||
i=`echo $i | sed 's/-/_/g'`
|
||||
eval "enable_$i=static"
|
||||
fi
|
||||
done
|
||||
])
|
||||
])
|
||||
|
||||
AC_DEFUN([APACHE_REQUIRE_CXX],[
|
||||
if test -z "$apache_cxx_done"; then
|
||||
AC_PROG_CXX
|
||||
AC_PROG_CXXCPP
|
||||
apache_cxx_done=yes
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_CHECK_OPENSSL
|
||||
dnl
|
||||
dnl Configure for OpenSSL, giving preference to
|
||||
dnl "--with-ssl=<path>" if it was specified.
|
||||
dnl
|
||||
AC_DEFUN([APACHE_CHECK_OPENSSL],[
|
||||
AC_CACHE_CHECK([for OpenSSL], [ac_cv_openssl], [
|
||||
dnl initialise the variables we use
|
||||
ac_cv_openssl=no
|
||||
ap_openssl_found=""
|
||||
ap_openssl_base=""
|
||||
ap_openssl_libs=""
|
||||
ap_openssl_mod_cflags=""
|
||||
ap_openssl_mod_ldflags=""
|
||||
|
||||
dnl Determine the OpenSSL base directory, if any
|
||||
AC_MSG_CHECKING([for user-provided OpenSSL base directory])
|
||||
AC_ARG_WITH(ssl, APACHE_HELP_STRING(--with-ssl=PATH,OpenSSL installation directory), [
|
||||
dnl If --with-ssl specifies a directory, we use that directory
|
||||
if test "x$withval" != "xyes" -a "x$withval" != "x"; then
|
||||
dnl This ensures $withval is actually a directory and that it is absolute
|
||||
ap_openssl_base="`cd $withval ; pwd`"
|
||||
fi
|
||||
])
|
||||
if test "x$ap_openssl_base" = "x"; then
|
||||
AC_MSG_RESULT(none)
|
||||
else
|
||||
AC_MSG_RESULT($ap_openssl_base)
|
||||
fi
|
||||
|
||||
dnl Run header and version checks
|
||||
saved_CPPFLAGS="$CPPFLAGS"
|
||||
saved_LIBS="$LIBS"
|
||||
saved_LDFLAGS="$LDFLAGS"
|
||||
|
||||
dnl Before doing anything else, load in pkg-config variables
|
||||
if test -n "$PKGCONFIG"; then
|
||||
saved_PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
|
||||
if test "x$ap_openssl_base" != "x"; then
|
||||
if test -f "${ap_openssl_base}/lib/pkgconfig/openssl.pc"; then
|
||||
dnl Ensure that the given path is used by pkg-config too, otherwise
|
||||
dnl the system openssl.pc might be picked up instead.
|
||||
PKG_CONFIG_PATH="${ap_openssl_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
|
||||
export PKG_CONFIG_PATH
|
||||
elif test -f "${ap_openssl_base}/lib64/pkgconfig/openssl.pc"; then
|
||||
dnl Ensure that the given path is used by pkg-config too, otherwise
|
||||
dnl the system openssl.pc might be picked up instead.
|
||||
PKG_CONFIG_PATH="${ap_openssl_base}/lib64/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
|
||||
export PKG_CONFIG_PATH
|
||||
fi
|
||||
fi
|
||||
AC_ARG_ENABLE(ssl-staticlib-deps,APACHE_HELP_STRING(--enable-ssl-staticlib-deps,[link mod_ssl with dependencies of OpenSSL's static libraries (as indicated by "pkg-config --static"). Must be specified in addition to --enable-ssl.]), [
|
||||
if test "$enableval" = "yes"; then
|
||||
PKGCONFIG_LIBOPTS="--static"
|
||||
fi
|
||||
])
|
||||
ap_openssl_libs="`$PKGCONFIG $PKGCONFIG_LIBOPTS --libs-only-l --silence-errors openssl`"
|
||||
if test $? -eq 0; then
|
||||
ap_openssl_found="yes"
|
||||
pkglookup="`$PKGCONFIG --cflags-only-I openssl`"
|
||||
APR_ADDTO(CPPFLAGS, [$pkglookup])
|
||||
APR_ADDTO(MOD_CFLAGS, [$pkglookup])
|
||||
APR_ADDTO(ab_CFLAGS, [$pkglookup])
|
||||
pkglookup="`$PKGCONFIG $PKGCONFIG_LIBOPTS --libs-only-L openssl`"
|
||||
APR_ADDTO(LDFLAGS, [$pkglookup])
|
||||
APR_ADDTO(MOD_LDFLAGS, [$pkglookup])
|
||||
pkglookup="`$PKGCONFIG $PKGCONFIG_LIBOPTS --libs-only-other openssl`"
|
||||
APR_ADDTO(LDFLAGS, [$pkglookup])
|
||||
APR_ADDTO(MOD_LDFLAGS, [$pkglookup])
|
||||
fi
|
||||
PKG_CONFIG_PATH="$saved_PKG_CONFIG_PATH"
|
||||
fi
|
||||
|
||||
dnl fall back to the user-supplied directory if not found via pkg-config
|
||||
if test "x$ap_openssl_base" != "x" -a "x$ap_openssl_found" = "x"; then
|
||||
APR_ADDTO(CPPFLAGS, [-I$ap_openssl_base/include])
|
||||
APR_ADDTO(MOD_CFLAGS, [-I$ap_openssl_base/include])
|
||||
APR_ADDTO(ab_CFLAGS, [-I$ap_openssl_base/include])
|
||||
APR_ADDTO(LDFLAGS, [-L$ap_openssl_base/lib])
|
||||
APR_ADDTO(MOD_LDFLAGS, [-L$ap_openssl_base/lib])
|
||||
if test "x$ap_platform_runtime_link_flag" != "x"; then
|
||||
APR_ADDTO(LDFLAGS, [$ap_platform_runtime_link_flag$ap_openssl_base/lib])
|
||||
APR_ADDTO(MOD_LDFLAGS, [$ap_platform_runtime_link_flag$ap_openssl_base/lib])
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING([for OpenSSL version >= 0.9.8a])
|
||||
AC_TRY_COMPILE([#include <openssl/opensslv.h>],[
|
||||
#if !defined(OPENSSL_VERSION_NUMBER)
|
||||
#error "Missing OpenSSL version"
|
||||
#endif
|
||||
#if OPENSSL_VERSION_NUMBER < 0x0090801f
|
||||
#error "Unsupported OpenSSL version " OPENSSL_VERSION_TEXT
|
||||
#endif],
|
||||
[AC_MSG_RESULT(OK)
|
||||
ac_cv_openssl=yes],
|
||||
[AC_MSG_RESULT(FAILED)])
|
||||
|
||||
if test "x$ac_cv_openssl" = "xyes"; then
|
||||
ap_openssl_libs="${ap_openssl_libs:--lssl -lcrypto} `$apr_config --libs`"
|
||||
APR_ADDTO(MOD_LDFLAGS, [$ap_openssl_libs])
|
||||
APR_ADDTO(LIBS, [$ap_openssl_libs])
|
||||
APR_SETVAR(ab_LIBS, [$MOD_LDFLAGS])
|
||||
APACHE_SUBST(ab_CFLAGS)
|
||||
APACHE_SUBST(ab_LIBS)
|
||||
|
||||
dnl Run library and function checks
|
||||
liberrors=""
|
||||
AC_CHECK_HEADERS([openssl/engine.h])
|
||||
AC_CHECK_FUNCS([SSL_CTX_new], [], [liberrors="yes"])
|
||||
AC_CHECK_FUNCS([OPENSSL_init_ssl])
|
||||
AC_CHECK_FUNCS([ENGINE_init ENGINE_load_builtin_engines RAND_egd])
|
||||
if test "x$liberrors" != "x"; then
|
||||
AC_MSG_WARN([OpenSSL libraries are unusable])
|
||||
fi
|
||||
else
|
||||
AC_MSG_WARN([OpenSSL version is too old])
|
||||
fi
|
||||
|
||||
dnl restore
|
||||
CPPFLAGS="$saved_CPPFLAGS"
|
||||
LIBS="$saved_LIBS"
|
||||
LDFLAGS="$saved_LDFLAGS"
|
||||
|
||||
dnl cache MOD_LDFLAGS, MOD_CFLAGS
|
||||
ap_openssl_mod_cflags=$MOD_CFLAGS
|
||||
ap_openssl_mod_ldflags=$MOD_LDFLAGS
|
||||
])
|
||||
if test "x$ac_cv_openssl" = "xyes"; then
|
||||
AC_DEFINE(HAVE_OPENSSL, 1, [Define if OpenSSL is available])
|
||||
APR_ADDTO(MOD_LDFLAGS, [$ap_openssl_mod_ldflags])
|
||||
APR_ADDTO(MOD_CFLAGS, [$ap_openssl_mod_cflags])
|
||||
fi
|
||||
])
|
||||
|
||||
AC_DEFUN([APACHE_CHECK_SYSTEMD], [
|
||||
dnl Check for systemd support for listen.c's socket activation.
|
||||
case $host in
|
||||
*-linux-*)
|
||||
if test -n "$PKGCONFIG" && $PKGCONFIG --exists libsystemd; then
|
||||
SYSTEMD_LIBS=`$PKGCONFIG --libs libsystemd`
|
||||
elif test -n "$PKGCONFIG" && $PKGCONFIG --exists libsystemd-daemon; then
|
||||
SYSTEMD_LIBS=`$PKGCONFIG --libs libsystemd-daemon`
|
||||
else
|
||||
AC_CHECK_LIB(systemd-daemon, sd_notify, SYSTEMD_LIBS="-lsystemd-daemon")
|
||||
fi
|
||||
if test -n "$SYSTEMD_LIBS"; then
|
||||
AC_CHECK_HEADERS(systemd/sd-daemon.h)
|
||||
if test "${ac_cv_header_systemd_sd_daemon_h}" = "no" || test -z "${SYSTEMD_LIBS}"; then
|
||||
AC_MSG_WARN([Your system does not support systemd.])
|
||||
else
|
||||
AC_DEFINE(HAVE_SYSTEMD, 1, [Define if systemd is supported])
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_EXPORT_ARGUMENTS
|
||||
dnl Export (via APACHE_SUBST) the various path-related variables that
|
||||
dnl apache will use while generating scripts like autoconf and apxs and
|
||||
dnl the default config file.
|
||||
|
||||
AC_DEFUN([APACHE_SUBST_EXPANDED_ARG],[
|
||||
APR_EXPAND_VAR(exp_$1, [$]$1)
|
||||
APACHE_SUBST(exp_$1)
|
||||
APR_PATH_RELATIVE(rel_$1, [$]exp_$1, ${prefix})
|
||||
APACHE_SUBST(rel_$1)
|
||||
])
|
||||
|
||||
AC_DEFUN([APACHE_EXPORT_ARGUMENTS],[
|
||||
APACHE_SUBST_EXPANDED_ARG(exec_prefix)
|
||||
APACHE_SUBST_EXPANDED_ARG(bindir)
|
||||
APACHE_SUBST_EXPANDED_ARG(sbindir)
|
||||
APACHE_SUBST_EXPANDED_ARG(libdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(libexecdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(mandir)
|
||||
APACHE_SUBST_EXPANDED_ARG(sysconfdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(datadir)
|
||||
APACHE_SUBST_EXPANDED_ARG(installbuilddir)
|
||||
APACHE_SUBST_EXPANDED_ARG(errordir)
|
||||
APACHE_SUBST_EXPANDED_ARG(iconsdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(htdocsdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(manualdir)
|
||||
APACHE_SUBST_EXPANDED_ARG(cgidir)
|
||||
APACHE_SUBST_EXPANDED_ARG(includedir)
|
||||
APACHE_SUBST_EXPANDED_ARG(localstatedir)
|
||||
APACHE_SUBST_EXPANDED_ARG(runtimedir)
|
||||
APACHE_SUBST_EXPANDED_ARG(logfiledir)
|
||||
APACHE_SUBST_EXPANDED_ARG(proxycachedir)
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_CHECK_APxVER({apr|apu}, major, minor,
|
||||
dnl [actions-if-ok], [actions-if-not-ok])
|
||||
dnl
|
||||
dnl Checks for APR or APR-util of given major/minor version or later;
|
||||
dnl if so, runs actions-if-ok; otherwise runs actions-if-not-ok if given.
|
||||
dnl If the version is not satisfactory and actions-if-not-ok is not
|
||||
dnl given, then an error is printed and the configure script is aborted.
|
||||
dnl
|
||||
dnl The first argument must be [apr] or [apu].
|
||||
dnl
|
||||
AC_DEFUN([APACHE_CHECK_APxVER], [
|
||||
define(ap_ckver_major, translit($1, [apru], [APRU])[_MAJOR_VERSION])
|
||||
define(ap_ckver_minor, translit($1, [apru], [APRU])[_MINOR_VERSION])
|
||||
define(ap_ckver_cvar, [ap_cv_$1ver$2$3])
|
||||
define(ap_ckver_name, ifelse([$1],[apr],[APR],[APR-util]))
|
||||
|
||||
ap_ckver_CPPFLAGS="$CPPFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS `$[$1]_config --includes`"
|
||||
|
||||
AC_CACHE_CHECK([for ap_ckver_name version $2.$3.0 or later], ap_ckver_cvar, [
|
||||
AC_EGREP_CPP([good], [
|
||||
#include <$1_version.h>
|
||||
#if ]ap_ckver_major[ > $2 || (]ap_ckver_major[ == $2 && ]ap_ckver_minor[ >= $3)
|
||||
good
|
||||
#endif
|
||||
], [ap_ckver_cvar=yes], [ap_ckver_cvar=no])])
|
||||
|
||||
if test "$ap_ckver_cvar" = "yes"; then
|
||||
ifelse([$4],[],[:],[$4])
|
||||
else
|
||||
ifelse([$5],[],[AC_MSG_ERROR([ap_ckver_name version $2.$3.0 or later is required])], [$5])
|
||||
fi
|
||||
|
||||
CPPFLAGS="$ap_ckver_CPPFLAGS"
|
||||
|
||||
undefine([ap_ckver_major])
|
||||
undefine([ap_ckver_minor])
|
||||
undefine([ap_ckver_cvar])
|
||||
undefine([ap_ckver_name])
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_CHECK_VOID_PTR_LEN
|
||||
dnl
|
||||
dnl Checks if the size of a void pointer is at least as big as a "long"
|
||||
dnl integer type.
|
||||
dnl
|
||||
AC_DEFUN([APACHE_CHECK_VOID_PTR_LEN], [
|
||||
|
||||
AC_CACHE_CHECK([for void pointer length], [ap_cv_void_ptr_lt_long],
|
||||
[AC_TRY_RUN([
|
||||
int main(void)
|
||||
{
|
||||
return sizeof(void *) < sizeof(long);
|
||||
}], [ap_cv_void_ptr_lt_long=no], [ap_cv_void_ptr_lt_long=yes],
|
||||
[ap_cv_void_ptr_lt_long=yes])])
|
||||
|
||||
if test "$ap_cv_void_ptr_lt_long" = "yes"; then
|
||||
AC_MSG_ERROR([Size of "void *" is less than size of "long"])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_CHECK_APR_HAS_LDAP
|
||||
dnl
|
||||
dnl Check if APR_HAS_LDAP is 1
|
||||
dnl Unfortunately, we can't use APR_CHECK_APR_DEFINE (because it only includes apr.h)
|
||||
dnl or APR_CHECK_DEFINE (because it only checks for defined'ness and not for 0/1).
|
||||
dnl
|
||||
AC_DEFUN([APACHE_CHECK_APR_HAS_LDAP], [
|
||||
AC_CACHE_CHECK([for ldap support in apr/apr-util],ac_cv_APR_HAS_LDAP,[
|
||||
apache_old_cppflags="$CPPFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS $INCLUDES"
|
||||
AC_EGREP_CPP(YES_IS_DEFINED, [
|
||||
#include <apr_ldap.h>
|
||||
#if APR_HAS_LDAP
|
||||
YES_IS_DEFINED
|
||||
#endif
|
||||
], ac_cv_APR_HAS_LDAP=yes, ac_cv_APR_HAS_LDAP=no)
|
||||
CPPFLAGS="$apache_old_cppflags"
|
||||
])
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APACHE_ADD_GCC_CFLAG
|
||||
dnl
|
||||
dnl Check if compiler is gcc and supports flag. If yes, add to NOTEST_CFLAGS.
|
||||
dnl NOTEST_CFLAGS is merged lately, thus it won't accumulate in CFLAGS here.
|
||||
dnl Also, AC_LANG_PROGRAM() itself is known to trigger [-Wstrict-prototypes]
|
||||
dnl with some autoconf versions, so we force -Wno-strict-prototypes for the
|
||||
dnl check to avoid spurious failures when adding flags like -Werror.
|
||||
dnl
|
||||
AC_DEFUN([APACHE_ADD_GCC_CFLAG], [
|
||||
define([ap_gcc_ckvar], [ac_cv_gcc_]translit($1, [-:.=], [____]))
|
||||
if test "$GCC" = "yes"; then
|
||||
AC_CACHE_CHECK([whether gcc accepts $1], ap_gcc_ckvar, [
|
||||
save_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $1 -Wno-strict-prototypes"
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
|
||||
[ap_gcc_ckvar=yes], [ap_gcc_ckvar=no])
|
||||
CFLAGS="$save_CFLAGS"
|
||||
])
|
||||
if test "$]ap_gcc_ckvar[" = "yes" ; then
|
||||
APR_ADDTO(NOTEST_CFLAGS,[$1])
|
||||
fi
|
||||
fi
|
||||
undefine([ap_gcc_ckvar])
|
||||
])
|
102
ap.d
Normal file
102
ap.d
Normal file
|
@ -0,0 +1,102 @@
|
|||
#pragma D depends_on provider io
|
||||
typedef struct request_rec {
|
||||
uintptr_t pool;
|
||||
uintptr_t connection;
|
||||
uintptr_t server;
|
||||
uintptr_t next;
|
||||
uintptr_t prev;
|
||||
uintptr_t main;
|
||||
char *the_request;
|
||||
int assbackwards;
|
||||
int proxyreq;
|
||||
int header_only;
|
||||
char *protocol;
|
||||
int proto_num;
|
||||
char *hostname;
|
||||
int64_t request_time;
|
||||
char *status_line;
|
||||
int status;
|
||||
const char *method;
|
||||
int method_number;
|
||||
int64_t allowed;
|
||||
uintptr_t allowed_xmethods;
|
||||
uintptr_t allowed_methods;
|
||||
offset_t sent_bodyct;
|
||||
offset_t bytes_sent;
|
||||
int64_t mtime;
|
||||
int chunked;
|
||||
char *range;
|
||||
offset_t clength;
|
||||
offset_t remaining;
|
||||
offset_t read_length;
|
||||
int read_body;
|
||||
int read_chunked;
|
||||
unsigned expecting_100;
|
||||
uintptr_t headers_in;
|
||||
uintptr_t headers_out;
|
||||
uintptr_t err_headers_out;
|
||||
uintptr_t subprocess_env;
|
||||
uintptr_t notes;
|
||||
char *content_type; /* Break these out --- we dispatch on 'em */
|
||||
char *handler; /* What we *really* dispatch on */
|
||||
char *content_encoding;
|
||||
uintptr_t content_languages;
|
||||
char *vlist_validator;
|
||||
char *user;
|
||||
char *ap_auth_type;
|
||||
int no_cache;
|
||||
int no_local_copy;
|
||||
char *unparsed_uri;
|
||||
char *uri;
|
||||
char *filename;
|
||||
char *canonical_filename;
|
||||
char *path_info;
|
||||
char *args;
|
||||
/* finfo */
|
||||
uintptr_t finfo_pool;
|
||||
int32_t finfo_valid;
|
||||
int32_t finfo_protection;
|
||||
int32_t finfo_filetype;
|
||||
int finfo_user;
|
||||
int finfo_group;
|
||||
uint64_t finfo_inode;
|
||||
uint64_t finfo_device;
|
||||
int32_t finfo_nlink;
|
||||
offset_t finfo_size;
|
||||
offset_t finfo_csize;
|
||||
int64_t finfo_atime;
|
||||
int64_t finfo_mtime;
|
||||
int64_t finfo_ctime;
|
||||
char *finfo_fname;
|
||||
char *finfo_name;
|
||||
uintptr_t finfo_ffilehand;
|
||||
/* parsed_uri */
|
||||
char *uri_scheme;
|
||||
char *uri_hostinfo;
|
||||
char *uri_user;
|
||||
char *uri_password;
|
||||
char *uri_hostname;
|
||||
char *uri_port_str;
|
||||
char *uri_path;
|
||||
char *uri_query;
|
||||
char *uri_fragment;
|
||||
uintptr_t uri_hostent;
|
||||
uint16_t uri_port;
|
||||
unsigned uri_is_initialized:1;
|
||||
unsigned uri_dns_looked_up:1;
|
||||
unsigned uri_dns_resolved:1;
|
||||
|
||||
/* back to request_rec */
|
||||
int used_path_info;
|
||||
uintptr_t per_dir_config;
|
||||
uintptr_t request_config;
|
||||
uintptr_t htaccess;
|
||||
uintptr_t output_filters;
|
||||
uintptr_t input_filters;
|
||||
uintptr_t proto_output_filters;
|
||||
uintptr_t proto_input_filters;
|
||||
int eos_sent;
|
||||
uintptr_t kept_body;
|
||||
uintptr_t invoke_mtx;
|
||||
} request_rec;
|
||||
|
222
apache_probes.d
Normal file
222
apache_probes.d
Normal file
|
@ -0,0 +1,222 @@
|
|||
provider ap {
|
||||
/* Explicit, core */
|
||||
probe internal__redirect(char *, char *);
|
||||
probe process__request__entry(uintptr_t, char *);
|
||||
probe process__request__return(uintptr_t, char *, uint32_t);
|
||||
probe read__request__entry(uintptr_t, uintptr_t);
|
||||
probe read__request__success(uintptr_t, char *, char *, char *, uint32_t);
|
||||
probe read__request__failure(uintptr_t);
|
||||
|
||||
/* Explicit, modules */
|
||||
probe proxy__run(uintptr_t, uintptr_t, uintptr_t, char *, int);
|
||||
probe proxy__run__finished(uintptr_t, int, int);
|
||||
probe rewrite__log(uintptr_t, int, int, char *, char *);
|
||||
|
||||
/* Implicit, APR hooks */
|
||||
probe access_checker__entry();
|
||||
probe access_checker__dispatch__invoke(char *);
|
||||
probe access_checker__dispatch__complete(char *, uint32_t);
|
||||
probe access_checker__return(uint32_t);
|
||||
probe auth_checker__entry();
|
||||
probe auth_checker__dispatch__invoke(char *);
|
||||
probe auth_checker__dispatch__complete(char *, uint32_t);
|
||||
probe auth_checker__return(uint32_t);
|
||||
probe check_config__entry();
|
||||
probe check_config__dispatch__invoke(char *);
|
||||
probe check_config__dispatch__complete(char *, uint32_t);
|
||||
probe check_config__return(uint32_t);
|
||||
probe check_user_id__entry();
|
||||
probe check_user_id__dispatch__invoke(char *);
|
||||
probe check_user_id__dispatch__complete(char *, uint32_t);
|
||||
probe check_user_id__return(uint32_t);
|
||||
probe child_init__entry();
|
||||
probe child_init__dispatch__invoke(char *);
|
||||
probe child_init__dispatch__complete(char *, uint32_t);
|
||||
probe child_init__return(uint32_t);
|
||||
probe create_connection__entry();
|
||||
probe create_connection__dispatch__invoke(char *);
|
||||
probe create_connection__dispatch__complete(char *, uint32_t);
|
||||
probe create_connection__return(uint32_t);
|
||||
probe create_request__entry();
|
||||
probe create_request__dispatch__invoke(char *);
|
||||
probe create_request__dispatch__complete(char *, uint32_t);
|
||||
probe create_request__return(uint32_t);
|
||||
probe default_port__entry();
|
||||
probe default_port__dispatch__invoke(char *);
|
||||
probe default_port__dispatch__complete(char *, uint32_t);
|
||||
probe default_port__return(uint32_t);
|
||||
probe drop_privileges__entry();
|
||||
probe drop_privileges__dispatch__invoke(char *);
|
||||
probe drop_privileges__dispatch__complete(char *, uint32_t);
|
||||
probe drop_privileges__return(uint32_t);
|
||||
probe error_log__entry();
|
||||
probe error_log__dispatch__invoke(char *);
|
||||
probe error_log__dispatch__complete(char *, uint32_t);
|
||||
probe error_log__return(uint32_t);
|
||||
probe fatal_exception__entry();
|
||||
probe fatal_exception__dispatch__invoke(char *);
|
||||
probe fatal_exception__dispatch__complete(char *, uint32_t);
|
||||
probe fatal_exception__return(uint32_t);
|
||||
probe fixups__entry();
|
||||
probe fixups__dispatch__invoke(char *);
|
||||
probe fixups__dispatch__complete(char *, uint32_t);
|
||||
probe fixups__return(uint32_t);
|
||||
probe get_mgmt_items__entry();
|
||||
probe get_mgmt_items__dispatch__invoke(char *);
|
||||
probe get_mgmt_items__dispatch__complete(char *, uint32_t);
|
||||
probe get_mgmt_items__return(uint32_t);
|
||||
probe get_suexec_identity__entry();
|
||||
probe get_suexec_identity__dispatch__invoke(char *);
|
||||
probe get_suexec_identity__dispatch__complete(char *, uint32_t);
|
||||
probe get_suexec_identity__return(uint32_t);
|
||||
probe handler__entry();
|
||||
probe handler__dispatch__invoke(char *);
|
||||
probe handler__dispatch__complete(char *, uint32_t);
|
||||
probe handler__return(uint32_t);
|
||||
probe header_parser__entry();
|
||||
probe header_parser__dispatch__invoke(char *);
|
||||
probe header_parser__dispatch__complete(char *, uint32_t);
|
||||
probe header_parser__return(uint32_t);
|
||||
probe http_scheme__entry();
|
||||
probe http_scheme__dispatch__invoke(char *);
|
||||
probe http_scheme__dispatch__complete(char *, uint32_t);
|
||||
probe http_scheme__return(uint32_t);
|
||||
probe insert_error_filter__entry();
|
||||
probe insert_error_filter__dispatch__invoke(char *);
|
||||
probe insert_error_filter__dispatch__complete(char *, uint32_t);
|
||||
probe insert_error_filter__return(uint32_t);
|
||||
probe insert_filter__entry();
|
||||
probe insert_filter__dispatch__invoke(char *);
|
||||
probe insert_filter__dispatch__complete(char *, uint32_t);
|
||||
probe insert_filter__return(uint32_t);
|
||||
probe log_transaction__entry();
|
||||
probe log_transaction__dispatch__invoke(char *);
|
||||
probe log_transaction__dispatch__complete(char *, uint32_t);
|
||||
probe log_transaction__return(uint32_t);
|
||||
probe map_to_storage__entry();
|
||||
probe map_to_storage__dispatch__invoke(char *);
|
||||
probe map_to_storage__dispatch__complete(char *, uint32_t);
|
||||
probe map_to_storage__return(uint32_t);
|
||||
probe monitor__entry();
|
||||
probe monitor__dispatch__invoke(char *);
|
||||
probe monitor__dispatch__complete(char *, uint32_t);
|
||||
probe monitor__return(uint32_t);
|
||||
probe mpm__entry();
|
||||
probe mpm__dispatch__invoke(char *);
|
||||
probe mpm__dispatch__complete(char *, uint32_t);
|
||||
probe mpm__return(uint32_t);
|
||||
probe mpm_get_name__entry();
|
||||
probe mpm_get_name__dispatch__invoke(char *);
|
||||
probe mpm_get_name__dispatch__complete(char *, uint32_t);
|
||||
probe mpm_get_name__return(uint32_t);
|
||||
probe mpm_note_child_killed__entry();
|
||||
probe mpm_note_child_killed__dispatch__invoke(char *);
|
||||
probe mpm_note_child_killed__dispatch__complete(char *, uint32_t);
|
||||
probe mpm_note_child_killed__return(uint32_t);
|
||||
probe mpm_register_timed_callback__entry();
|
||||
probe mpm_register_timed_callback__dispatch__invoke(char *);
|
||||
probe mpm_register_timed_callback__dispatch__complete(char *, uint32_t);
|
||||
probe mpm_register_timed_callback__return(uint32_t);
|
||||
probe mpm_query__entry();
|
||||
probe mpm_query__dispatch__invoke(char *);
|
||||
probe mpm_query__dispatch__complete(char *, uint32_t);
|
||||
probe mpm_query__return(uint32_t);
|
||||
probe open_logs__entry();
|
||||
probe open_logs__dispatch__invoke(char *);
|
||||
probe open_logs__dispatch__complete(char *, uint32_t);
|
||||
probe open_logs__return(uint32_t);
|
||||
probe optional_fn_retrieve__entry();
|
||||
probe optional_fn_retrieve__dispatch__invoke(char *);
|
||||
probe optional_fn_retrieve__dispatch__complete(char *, uint32_t);
|
||||
probe optional_fn_retrieve__return(uint32_t);
|
||||
probe post_config__entry();
|
||||
probe post_config__dispatch__invoke(char *);
|
||||
probe post_config__dispatch__complete(char *, uint32_t);
|
||||
probe post_config__return(uint32_t);
|
||||
probe post_read_request__entry();
|
||||
probe post_read_request__dispatch__invoke(char *);
|
||||
probe post_read_request__dispatch__complete(char *, uint32_t);
|
||||
probe post_read_request__return(uint32_t);
|
||||
probe pre_config__entry();
|
||||
probe pre_config__dispatch__invoke(char *);
|
||||
probe pre_config__dispatch__complete(char *, uint32_t);
|
||||
probe pre_config__return(uint32_t);
|
||||
probe pre_connection__entry();
|
||||
probe pre_connection__dispatch__invoke(char *);
|
||||
probe pre_connection__dispatch__complete(char *, uint32_t);
|
||||
probe pre_connection__return(uint32_t);
|
||||
probe pre_mpm__entry();
|
||||
probe pre_mpm__dispatch__invoke(char *);
|
||||
probe pre_mpm__dispatch__complete(char *, uint32_t);
|
||||
probe pre_mpm__return(uint32_t);
|
||||
probe process_connection__entry();
|
||||
probe process_connection__dispatch__invoke(char *);
|
||||
probe process_connection__dispatch__complete(char *, uint32_t);
|
||||
probe process_connection__return(uint32_t);
|
||||
probe quick_handler__entry();
|
||||
probe quick_handler__dispatch__invoke(char *);
|
||||
probe quick_handler__dispatch__complete(char *, uint32_t);
|
||||
probe quick_handler__return(uint32_t);
|
||||
probe test_config__entry();
|
||||
probe test_config__dispatch__invoke(char *);
|
||||
probe test_config__dispatch__complete(char *, uint32_t);
|
||||
probe test_config__return(uint32_t);
|
||||
probe translate_name__entry();
|
||||
probe translate_name__dispatch__invoke(char *);
|
||||
probe translate_name__dispatch__complete(char *, uint32_t);
|
||||
probe translate_name__return(uint32_t);
|
||||
probe type_checker__entry();
|
||||
probe type_checker__dispatch__invoke(char *);
|
||||
probe type_checker__dispatch__complete(char *, uint32_t);
|
||||
probe type_checker__return(uint32_t);
|
||||
|
||||
/* Implicit, APR hooks for proxy */
|
||||
probe canon_handler__entry();
|
||||
probe canon_handler__dispatch__invoke(char *);
|
||||
probe canon_handler__dispatch__complete(char *, uint32_t);
|
||||
probe canon_handler__return(uint32_t);
|
||||
probe post_request__entry();
|
||||
probe post_request__dispatch__invoke(char *);
|
||||
probe post_request__dispatch__complete(char *, uint32_t);
|
||||
probe post_request__return(uint32_t);
|
||||
probe pre_request__entry();
|
||||
probe pre_request__dispatch__invoke(char *);
|
||||
probe pre_request__dispatch__complete(char *, uint32_t);
|
||||
probe pre_request__return(uint32_t);
|
||||
probe scheme_handler__entry();
|
||||
probe scheme_handler__dispatch__invoke(char *);
|
||||
probe scheme_handler__dispatch__complete(char *, uint32_t);
|
||||
probe scheme_handler__return(uint32_t);
|
||||
|
||||
/* Implicit, APR hooks for dav */
|
||||
probe find_liveprop__entry();
|
||||
probe find_liveprop__dispatch__invoke(char *);
|
||||
probe find_liveprop__dispatch__complete(char *, uint32_t);
|
||||
probe find_liveprop__return(uint32_t);
|
||||
probe gather_propsets__entry();
|
||||
probe gather_propsets__dispatch__invoke(char *);
|
||||
probe gather_propsets__dispatch__complete(char *, uint32_t);
|
||||
probe gather_propsets__return(uint32_t);
|
||||
probe insert_all_liveprops__entry();
|
||||
probe insert_all_liveprops__dispatch__invoke(char *);
|
||||
probe insert_all_liveprops__dispatch__complete(char *, uint32_t);
|
||||
probe insert_all_liveprops__return(uint32_t);
|
||||
|
||||
/* Implicit, APR hooks for watchdog */
|
||||
probe watchdog_exit__entry();
|
||||
probe watchdog_exit__dispatch__invoke(char *);
|
||||
probe watchdog_exit__dispatch__complete(char *, uint32_t);
|
||||
probe watchdog_exit__return(uint32_t);
|
||||
probe watchdog_init__entry();
|
||||
probe watchdog_init__dispatch__invoke(char *);
|
||||
probe watchdog_init__dispatch__complete(char *, uint32_t);
|
||||
probe watchdog_init__return(uint32_t);
|
||||
probe watchdog_need__entry();
|
||||
probe watchdog_need__dispatch__invoke(char *);
|
||||
probe watchdog_need__dispatch__complete(char *, uint32_t);
|
||||
probe watchdog_need__return(uint32_t);
|
||||
probe watchdog_step__entry();
|
||||
probe watchdog_step__dispatch__invoke(char *);
|
||||
probe watchdog_step__dispatch__complete(char *, uint32_t);
|
||||
probe watchdog_step__return(uint32_t);
|
||||
};
|
410
build/NWGNUenvironment.inc
Normal file
410
build/NWGNUenvironment.inc
Normal file
|
@ -0,0 +1,410 @@
|
|||
#
|
||||
# Setup needed Tools and Libraries
|
||||
#
|
||||
|
||||
ifeq "$(wildcard $(AP_WORK)/NWGNUcustom.ini)" "$(AP_WORK)/NWGNUcustom.ini"
|
||||
include $(AP_WORK)/NWGNUcustom.ini
|
||||
CUSTOM_INI = $(AP_WORK)/NWGNUcustom.ini
|
||||
endif
|
||||
|
||||
ifndef VERBOSE
|
||||
.SILENT:
|
||||
endif
|
||||
|
||||
#
|
||||
# Treat like an include
|
||||
#
|
||||
ifndef EnvironmentDefined
|
||||
|
||||
#
|
||||
# simple macros for parsing makefiles
|
||||
#
|
||||
EOLIST:=
|
||||
EMPTY :=
|
||||
COMMA := ,
|
||||
SPACE := $(EMPTY) $(EMPTY)
|
||||
|
||||
#
|
||||
# Base environment
|
||||
#
|
||||
|
||||
# Try and handle case issues
|
||||
ifndef NOVELLLIBC
|
||||
ifdef NovellLibC
|
||||
NOVELLLIBC = $(NovellLibC)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifndef NOVELLLIBC
|
||||
NOVELLLIBC = C:/novell/ndk/libc
|
||||
endif
|
||||
ifneq "$(wildcard $(NOVELLLIBC)/include/ndkvers.h)" "$(NOVELLLIBC)/include/ndkvers.h"
|
||||
$(error NOVELLLIBC does not point to a valid Novell LIBC SDK)
|
||||
endif
|
||||
|
||||
ifndef LDAPSDK
|
||||
LDAPSDK = C:/novell/ndk/cldapsdk/NetWare/libc
|
||||
endif
|
||||
ifneq "$(wildcard $(LDAPSDK)/inc/ldap.h)" "$(LDAPSDK)/inc/ldap.h"
|
||||
$(error LDAPSDK does not point to a valid Novell CLDAP SDK)
|
||||
endif
|
||||
|
||||
ifdef WITH_HTTP2
|
||||
ifneq "$(wildcard $(NGH2SRC)/lib/nghttp2_hd.h)" "$(NGH2SRC)/lib/nghttp2_hd.h"
|
||||
$(error NGH2SRC does not point to a valid NGHTTP2 source tree)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifndef PCRESRC
|
||||
PCRESRC = $(AP_WORK)/srclib/pcre
|
||||
endif
|
||||
ifneq "$(wildcard $(PCRESRC)/pcre-config.in)" "$(PCRESRC)/pcre-config.in"
|
||||
$(error PCRESRC does not point to a valid PCRE source tree)
|
||||
endif
|
||||
|
||||
# This is a placeholder
|
||||
# ifndef ZLIBSDK
|
||||
# ZLIBSDK = C:/novell/ndk/zlibsdk
|
||||
# endif
|
||||
|
||||
ifndef METROWERKS
|
||||
METROWERKS = $(ProgramFiles)\Metrowerks\CodeWarrior
|
||||
endif
|
||||
|
||||
# If LM_LICENSE_FILE isn't defined, define a variable that can be used to
|
||||
# restart make with it defined
|
||||
ifndef LM_LICENSE_FILE
|
||||
NO_LICENSE_FILE = NO_LICENSE_FILE
|
||||
endif
|
||||
|
||||
#
|
||||
# Set the Release type that you want to build, possible values are:
|
||||
#
|
||||
# debug - full debug switches are set
|
||||
# noopt - normal switches are set
|
||||
# release - optimization switches are set (default)
|
||||
|
||||
ifdef reltype
|
||||
RELEASE = $(reltype)
|
||||
endif
|
||||
|
||||
ifdef RELTYPE
|
||||
RELEASE = $(RELTYPE)
|
||||
endif
|
||||
|
||||
ifdef debug
|
||||
RELEASE = debug
|
||||
endif
|
||||
|
||||
ifdef DEBUG
|
||||
RELEASE = debug
|
||||
endif
|
||||
|
||||
ifdef noopt
|
||||
RELEASE = noopt
|
||||
endif
|
||||
|
||||
ifdef NOOPT
|
||||
RELEASE = noopt
|
||||
endif
|
||||
|
||||
ifdef optimized
|
||||
RELEASE = release
|
||||
endif
|
||||
|
||||
ifdef OPTIMIZED
|
||||
RELEASE = release
|
||||
endif
|
||||
|
||||
ifndef RELEASE
|
||||
RELEASE = release
|
||||
endif
|
||||
|
||||
OBJDIR = obj_$(RELEASE)
|
||||
|
||||
# Define minimum APR version to check for
|
||||
APR_WANTED = 1004000
|
||||
|
||||
#
|
||||
# Setup compiler information
|
||||
#
|
||||
|
||||
# MetroWerks NLM tools
|
||||
CC = mwccnlm
|
||||
CPP = mwccnlm
|
||||
LINK = mwldnlm
|
||||
LIB = mwldnlm -type library -w nocmdline
|
||||
WIN_CC = mwcc
|
||||
|
||||
# Setup build tools
|
||||
AWK = awk
|
||||
|
||||
# Setup distribution tools
|
||||
ZIP = zip -qr9
|
||||
7ZA = 7za >NUL a
|
||||
|
||||
#
|
||||
# Declare Command and tool macros here
|
||||
#
|
||||
|
||||
ifeq ($(findstring /sh,$(SHELL)),/sh)
|
||||
DEL = rm -f $1
|
||||
RMDIR = rm -fr $1
|
||||
MKDIR = mkdir -p $1
|
||||
COPY = -cp -afv $1 $2
|
||||
#COPYR = -cp -afr $1/* $2
|
||||
COPYR = -rsync -aC $1/* $2
|
||||
TOUCH = -touch $1
|
||||
ECHONL = echo ""
|
||||
DL = '
|
||||
CAT = cat
|
||||
else
|
||||
ifeq "$(OS)" "Windows_NT"
|
||||
DEL = $(shell if exist $(subst /,\,$1) del /q /f 2>NUL $(subst /,\,$1))
|
||||
RMDIR = $(shell if exist $(subst /,\,$1)\NUL rd /q /s 2>NUL $(subst /,\,$1))
|
||||
else
|
||||
DEL = $(shell if exist $(subst /,\,$1) del 2>NUL $(subst /,\,$1))
|
||||
RMDIR = $(shell if exist $(subst /,\,$1)\NUL deltree /y 2>NUL $(subst /,\,$1))
|
||||
endif
|
||||
ECHONL = $(ComSpec) /c echo.
|
||||
MKDIR = $(shell if not exist $(subst /,\,$1)\NUL md 2>NUL $(subst /,\,$1))
|
||||
COPY = -copy /y 2>NUL $(subst /,\,$1) $(subst /,\,$2)
|
||||
COPYR = -xcopy /q /y /e 2>NUL $(subst /,\,$1) $(subst /,\,$2)
|
||||
TOUCH = -copy /b 2>&1>NUL $(subst /,\,$1) +,,
|
||||
CAT = type
|
||||
endif
|
||||
|
||||
ifdef IPV6
|
||||
ifndef USE_STDSOCKETS
|
||||
USE_STDSOCKETS=1
|
||||
endif
|
||||
endif
|
||||
|
||||
NOVI = $(NOVELLLIBC)/imports
|
||||
PRELUDE = $(NOVI)/libcpre.o
|
||||
|
||||
INCDIRS = $(NOVELLLIBC)/include;
|
||||
ifndef USE_STDSOCKETS
|
||||
INCDIRS += $(NOVELLLIBC)/include/winsock;
|
||||
endif
|
||||
ifneq "$(LDAPSDK)" ""
|
||||
INCDIRS += $(LDAPSDK)/inc;
|
||||
endif
|
||||
ifneq "$(ZLIBSDK)" ""
|
||||
INCDIRS += $(ZLIBSDK);
|
||||
endif
|
||||
ifneq "$(PCRESRC)" ""
|
||||
INCDIRS += $(PCRESRC);
|
||||
endif
|
||||
|
||||
DEFINES = -DNETWARE
|
||||
ifndef USE_STDSOCKETS
|
||||
DEFINES += -DUSE_WINSOCK
|
||||
endif
|
||||
ifndef DEBUG
|
||||
DEFINES += -DNDEBUG
|
||||
endif
|
||||
|
||||
ifdef USE_STDSOCKETS
|
||||
VERSION_SKT = (BSDSOCK)
|
||||
else
|
||||
VERSION_SKT = (WINSOCK)
|
||||
endif
|
||||
|
||||
# MetroWerks static Libraries
|
||||
CLIB3S = $(METROWERKS)/Novell Support/Metrowerks Support/Libraries/Runtime/mwcrtl.lib
|
||||
MATH3S =
|
||||
PLIB3S = $(METROWERKS)/Novell Support/Metrowerks Support/Libraries/MSL C++/MWCPP.lib
|
||||
|
||||
ifeq "$(OS)" "Windows_NT"
|
||||
# MetroWerks Win32 build flags to create build tools
|
||||
MWCW_MSL = "$(METROWERKS)/MSL"
|
||||
MWCW_W32 = "$(METROWERKS)/Win32-x86 Support"
|
||||
CC_FOR_BUILD = $(WIN_CC)
|
||||
CFLAGS_FOR_BUILD = -O2 -gccinc -nodefaults -proc 586 -w off
|
||||
CFLAGS_FOR_BUILD += -ir $(MWCW_MSL) -ir $(MWCW_W32) -lr $(MWCW_MSL) -lr $(MWCW_W32)
|
||||
CFLAGS_FOR_BUILD += -lMSL_All_x86.lib -lkernel32.lib -luser32.lib
|
||||
else
|
||||
# GNUC build flags to create build tools
|
||||
CC_FOR_BUILD = gcc
|
||||
CFLAGS_FOR_BUILD = -Wall -O2
|
||||
endif
|
||||
|
||||
# Base compile flags
|
||||
# and prefix or precompiled header added here.
|
||||
|
||||
# The default flags are as follows:
|
||||
#
|
||||
# -c compile only, no link
|
||||
# -gccinc search directory of referencing file first for #includes
|
||||
# -Cpp_exceptions off disable C++ exceptions
|
||||
# -RTTI off disable C++ run-time typing information
|
||||
# -align 4 align on 4 byte bounderies
|
||||
# -w nocmdline disable command-line driver/parser warnings
|
||||
# -proc PII generate code base on Pentium II instruction set
|
||||
# -inst mmx use MMX extensions (Not used)
|
||||
|
||||
CFLAGS += -c -w nocmdline -gccinc -Cpp_exceptions off -RTTI off -align 4 -proc PII
|
||||
|
||||
ifdef CC_MAX_ERRORS
|
||||
CFLAGS += -maxerrors $(CC_MAX_ERRORS)
|
||||
else
|
||||
CFLAGS += -maxerrors 1
|
||||
endif
|
||||
|
||||
ifeq "$(REQUIRE_PROTOTYPES)" "1"
|
||||
CFLAGS += -r
|
||||
endif
|
||||
|
||||
# -g generate debugging information
|
||||
# -O0 level 0 optimizations
|
||||
ifeq "$(RELEASE)" "debug"
|
||||
CFLAGS += -g -O0
|
||||
endif
|
||||
|
||||
# -O4,p level 4 optimizations, optimize for speed
|
||||
ifeq "$(RELEASE)" "release"
|
||||
CFLAGS += -O4,p
|
||||
endif
|
||||
|
||||
# -prefix pre_nw.h #include pre_nw.h for all files
|
||||
CFLAGS += -prefix pre_nw.h
|
||||
|
||||
|
||||
ifneq ($(findstring /sh,$(SHELL)),/sh)
|
||||
PATH:=$(PATH);$(METROWERKS)\bin;$(METROWERKS)\Other Metrowerks Tools\Command Line Tools
|
||||
endif
|
||||
|
||||
#
|
||||
# Declare major project deliverables output directories here
|
||||
#
|
||||
|
||||
ifndef PORT
|
||||
PORT = 80
|
||||
endif
|
||||
|
||||
ifndef SSLPORT
|
||||
SSLPORT = 443
|
||||
endif
|
||||
|
||||
ifdef DEST
|
||||
INSTALL = $(subst \,/,$(DEST))
|
||||
ifeq (/, $(findstring /,$(INSTALL)))
|
||||
INSTDIRS = $(INSTALL)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifdef dest
|
||||
INSTALL = $(subst \,/,$(dest))
|
||||
ifeq (/, $(findstring /,$(INSTALL)))
|
||||
INSTDIRS = $(INSTALL)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifndef INSTALL
|
||||
INSTALL = $(AP_WORK)/Dist
|
||||
INSTDIRS = $(INSTALL)
|
||||
endif
|
||||
|
||||
ifeq ($(MAKECMDGOALS),installdev)
|
||||
ifndef BASEDIR
|
||||
export BASEDIR = apache_$(VERSION_STR)-sdk
|
||||
endif
|
||||
else
|
||||
ifndef BASEDIR
|
||||
export BASEDIR = Apache$(VERSION_MAJMIN)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Add support for building IPV6 alongside
|
||||
ifneq "$(IPV6)" ""
|
||||
DEFINES += -DNW_BUILD_IPV6
|
||||
# INCDIRS := $(NOVELLLIBC)/include/winsock/IPV6;$(INCDIRS)
|
||||
|
||||
ifneq "$(findstring IPV6,$(OBJDIR))" "IPV6"
|
||||
OBJDIR := $(OBJDIR)_IPV6
|
||||
endif
|
||||
|
||||
ifneq "$(findstring IPV6,$(INSTALL))" "IPV6"
|
||||
INSTALL := $(INSTALL)_IPV6
|
||||
endif
|
||||
|
||||
ifneq "$(findstring IPV6,$(INSTDIRS))" "IPV6"
|
||||
INSTDIRS := $(INSTDIRS)_IPV6
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
INSTALLBASE = $(INSTALL)/$(BASEDIR)
|
||||
|
||||
INSTDEVDIRS = \
|
||||
$(INSTALL) \
|
||||
$(INSTALLBASE) \
|
||||
$(INSTALLBASE)/build \
|
||||
$(INSTALLBASE)/include \
|
||||
$(INSTALLBASE)/lib \
|
||||
$(EOLIST)
|
||||
|
||||
INSTDIRS += \
|
||||
$(INSTALLBASE) \
|
||||
$(INSTALLBASE)/bin \
|
||||
$(INSTALLBASE)/cgi-bin \
|
||||
$(INSTALLBASE)/conf \
|
||||
$(INSTALLBASE)/conf/extra \
|
||||
$(INSTALLBASE)/error \
|
||||
$(INSTALLBASE)/htdocs \
|
||||
$(INSTALLBASE)/icons \
|
||||
$(INSTALLBASE)/logs \
|
||||
$(INSTALLBASE)/man \
|
||||
$(INSTALLBASE)/manual \
|
||||
$(INSTALLBASE)/modules \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# Common directories
|
||||
#
|
||||
|
||||
SRC = $(subst \,/,$(AP_WORK))
|
||||
APR = $(subst \,/,$(APR_WORK))
|
||||
APRUTIL = $(subst \,/,$(APU_WORK))
|
||||
APBUILD = $(SRC)/build
|
||||
STDMOD = $(SRC)/modules
|
||||
HTTPD = $(SRC)/modules/http
|
||||
DAV = $(SRC)/modules/dav
|
||||
NWOS = $(SRC)/os/netware
|
||||
SERVER = $(SRC)/server
|
||||
SUPMOD = $(SRC)/support
|
||||
APULDAP = $(APRUTIL)/ldap
|
||||
XML = $(APRUTIL)/xml
|
||||
APRTEST = $(APR)/test
|
||||
PCRE = $(PCRESRC)
|
||||
|
||||
PREBUILD_INST = $(SRC)/nwprebuild
|
||||
|
||||
#
|
||||
# Internal Libraries
|
||||
#
|
||||
|
||||
APRLIB = $(APR)/$(OBJDIR)/aprlib.lib
|
||||
APRUTLIB = $(APRUTIL)/$(OBJDIR)/aprutil.lib
|
||||
APULDAPLIB = $(APULDAP)/$(OBJDIR)/apuldap.lib
|
||||
STMODLIB = $(STDMOD)/$(OBJDIR)/stdmod.lib
|
||||
PCRELIB = $(SRC)/$(OBJDIR)/pcre.lib
|
||||
NWOSLIB = $(NWOS)/$(OBJDIR)/netware.lib
|
||||
SERVLIB = $(SERVER)/$(OBJDIR)/server.lib
|
||||
HTTPDLIB = $(HTTPD)/$(OBJDIR)/httpd.lib
|
||||
XMLLIB = $(XML)/$(OBJDIR)/xmllib.lib
|
||||
|
||||
#
|
||||
# Additional general defines
|
||||
#
|
||||
|
||||
EnvironmentDefined = 1
|
||||
endif # ifndef EnvironmentDefined
|
||||
|
||||
# This is always set so that it will show up in lower directories
|
||||
|
||||
ifdef Path
|
||||
Path = $(PATH)
|
||||
endif
|
||||
|
109
build/NWGNUhead.inc
Normal file
109
build/NWGNUhead.inc
Normal file
|
@ -0,0 +1,109 @@
|
|||
#
|
||||
# Obtain the global build environment
|
||||
#
|
||||
|
||||
include $(AP_WORK)/build/NWGNUenvironment.inc
|
||||
|
||||
#
|
||||
# Define base targets and rules
|
||||
#
|
||||
|
||||
TARGETS = libs nlms install clobber_libs clobber_nlms clean installdev
|
||||
|
||||
.PHONY : $(TARGETS) default all help $(NO_LICENSE_FILE)
|
||||
|
||||
# Here is where we will use the NO_LICENSE_FILE variable to see if we need to
|
||||
# restart the make with it defined
|
||||
|
||||
ifdef NO_LICENSE_FILE
|
||||
|
||||
default: NO_LICENSE_FILE
|
||||
|
||||
all: NO_LICENSE_FILE
|
||||
|
||||
install :: NO_LICENSE_FILE
|
||||
|
||||
installdev :: NO_LICENSE_FILE
|
||||
|
||||
NO_LICENSE_FILE :
|
||||
$(MAKE) $(MAKECMDGOALS) -f NWGNUmakefile RELEASE=$(RELEASE) DEST="$(INSTALL)" LM_LICENSE_FILE="$(METROWERKS)/license.dat"
|
||||
|
||||
else # LM_LICENSE_FILE must be defined so use the real targets
|
||||
|
||||
default: $(SUBDIRS) libs nlms
|
||||
|
||||
all: $(SUBDIRS) libs nlms install
|
||||
|
||||
$(TARGETS) :: $(SUBDIRS)
|
||||
|
||||
install :: nlms $(INSTDIRS)
|
||||
|
||||
installdev :: $(INSTDEVDIRS)
|
||||
|
||||
$(INSTDIRS) ::
|
||||
$(call MKDIR,$@)
|
||||
|
||||
$(INSTDEVDIRS) ::
|
||||
$(call MKDIR,$@)
|
||||
|
||||
endif #NO_LICENSE_FILE check
|
||||
|
||||
help :
|
||||
@echo $(DL)targets for RELEASE=$(RELEASE):$(DL)
|
||||
@echo $(DL)(default) . . . . libs nlms$(DL)
|
||||
@echo $(DL)all . . . . . . . does everything (libs nlms install)$(DL)
|
||||
@echo $(DL)libs. . . . . . . builds all libs$(DL)
|
||||
@echo $(DL)nlms. . . . . . . builds all nlms$(DL)
|
||||
@echo $(DL)install . . . . . builds libs and nlms and copies install files to$(DL)
|
||||
@echo $(DL) "$(INSTALL)"$(DL)
|
||||
@echo $(DL)installdev. . . . copies headers and files needed for development to$(DL)
|
||||
@echo $(DL) "$(INSTALL)"$(DL)
|
||||
@echo $(DL)clean . . . . . . deletes $(OBJDIR) dirs, *.err, and *.map$(DL)
|
||||
@echo $(DL)clobber_all . . . deletes all possible output from the make$(DL)
|
||||
@echo $(DL)clobber_install . deletes all files in $(INSTALL)$(DL)
|
||||
@$(ECHONL)
|
||||
@echo $(DL)Multiple targets can be used on a single nmake command line -$(DL)
|
||||
@echo $(DL)(i.e. $(MAKE) clean all)$(DL)
|
||||
@$(ECHONL)
|
||||
@echo $(DL)You can also specify RELEASE=debug, RELEASE=noopt, or RELEASE=optimized$(DL)
|
||||
@echo $(DL)The default is RELEASE=optimized$(DL)
|
||||
|
||||
clobber_all :: clean clobber_install clobber_prebuild
|
||||
|
||||
clobber_install ::
|
||||
$(call RMDIR,$(INSTALL))
|
||||
|
||||
clobber_prebuild ::
|
||||
$(call RMDIR,$(PREBUILD_INST))
|
||||
|
||||
#
|
||||
# build recursive targets
|
||||
#
|
||||
|
||||
$(SUBDIRS) : FORCE
|
||||
ifneq "$(MAKECMDGOALS)" "clean"
|
||||
ifneq "$(findstring clobber_,$(MAKECMDGOALS))" "clobber_"
|
||||
@$(ECHONL)
|
||||
@echo $(DL)Building $(CURDIR)/$@$(DL)
|
||||
endif
|
||||
endif
|
||||
$(MAKE) -C $@ $(MAKECMDGOALS) -f NWGNUmakefile RELEASE=$(RELEASE) DEST="$(INSTALL)" LM_LICENSE_FILE="$(LM_LICENSE_FILE)"
|
||||
@$(ECHONL)
|
||||
|
||||
FORCE:
|
||||
|
||||
#
|
||||
# Standard targets
|
||||
#
|
||||
|
||||
clean :: $(SUBDIRS)
|
||||
@echo $(DL)Cleaning up $(CURDIR)$(DL)
|
||||
$(call RMDIR,$(OBJDIR))
|
||||
$(call DEL,*.err)
|
||||
$(call DEL,*.map)
|
||||
$(call DEL,*.tmp)
|
||||
# $(call DEL,*.d)
|
||||
|
||||
$(OBJDIR) ::
|
||||
$(call MKDIR,$@)
|
||||
|
140
build/NWGNUmakefile
Normal file
140
build/NWGNUmakefile
Normal file
|
@ -0,0 +1,140 @@
|
|||
#
|
||||
# Declare the sub-directories to be built here
|
||||
#
|
||||
|
||||
SUBDIRS = \
|
||||
$(APR_WORK)/build \
|
||||
$(EOLIST)
|
||||
|
||||
#
|
||||
# Get the 'head' of the build environment. This includes default targets and
|
||||
# paths to tools
|
||||
#
|
||||
|
||||
include $(AP_WORK)/build/NWGNUhead.inc
|
||||
|
||||
#
|
||||
# build this level's files
|
||||
|
||||
FILES_prebuild_headers = \
|
||||
$(SRC)/include/ap_config_layout.h \
|
||||
$(NWOS)/test_char.h \
|
||||
$(PCRE)/config.h \
|
||||
$(PCRE)/pcre.h \
|
||||
$(EOLIST)
|
||||
|
||||
nlms :: libs $(NWOS)/httpd.imp $(DAV)/main/dav.imp $(STDMOD)/cache/mod_cache.imp
|
||||
|
||||
libs :: chkapr $(NWOS)/chartables.c
|
||||
|
||||
$(DAV)/main/dav.imp : make_nw_export.awk $(DAV)/main/mod_dav.h
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$(AWK) -v EXPPREFIX=AP$(VERSION_MAJMIN) -f $^ >$@
|
||||
|
||||
$(STDMOD)/cache/mod_cache.imp: make_nw_export.awk $(STDMOD)/cache/mod_cache.h $(STDMOD)/cache/cache_util.h
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$(AWK) -v EXPPREFIX=AP$(VERSION_MAJMIN) -f $^ >$@
|
||||
|
||||
$(NWOS)/httpd.imp : make_nw_export.awk nw_export.i
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$(AWK) -v EXPPREFIX=AP$(VERSION_MAJMIN) -f $^ >$@
|
||||
|
||||
nw_export.i : nw_export.inc $(FILES_prebuild_headers) cc.opt
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$(CC) $< @cc.opt
|
||||
|
||||
cc.opt : NWGNUmakefile $(APBUILD)/NWGNUenvironment.inc $(APBUILD)/NWGNUtail.inc $(APBUILD)/NWGNUhead.inc
|
||||
@echo $(DL)-P$(DL)> $@
|
||||
@echo $(DL)-EP$(DL)>> $@
|
||||
@echo $(DL)-nosyspath$(DL)>> $@
|
||||
@echo $(DL)-w nocmdline$(DL)>> $@
|
||||
@echo $(DL)$(DEFINES)$(DL)>> $@
|
||||
@echo $(DL)-I$(SRC)/include$(DL)>> $@
|
||||
@echo $(DL)-I$(HTTPD)$(DL)>> $@
|
||||
@echo $(DL)-I$(STDMOD)/aaa$(DL)>> $@
|
||||
@echo $(DL)-I$(STDMOD)/core$(DL)>> $@
|
||||
@echo $(DL)-I$(NWOS)$(DL)>> $@
|
||||
@echo $(DL)-I$(SERVER)/mpm/netware$(DL)>> $@
|
||||
@echo $(DL)-I$(APR)/include$(DL)>> $@
|
||||
@echo $(DL)-I$(APRUTIL)/include$(DL)>> $@
|
||||
@echo $(DL)-ir $(NOVELLLIBC)$(DL)>> $@
|
||||
|
||||
$(SRC)/include/ap_config_layout.h: $(NWOS)/netware_config_layout.h
|
||||
@echo Creating $@
|
||||
$(call COPY,$<,$@)
|
||||
|
||||
$(PCRE)/%.h: $(PCRE)/%.h.generic
|
||||
@echo Creating $@
|
||||
$(call COPY,$<,$@)
|
||||
|
||||
$(PCRE)/%.h: $(PCRE)/%.hw
|
||||
@echo Creating $@
|
||||
$(call COPY,$<,$@)
|
||||
|
||||
ifneq "$(BUILDTOOL_AS_NLM)" "1"
|
||||
|
||||
$(NWOS)/chartables.c: dftables.exe $(PCRE)/dftables.c
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$< $@
|
||||
|
||||
%.exe: $(PCRE)/%.c $(PCRE)/config.h $(PCRE)/pcre.h
|
||||
@echo $(DL)Creating Build Helper $@$(DL)
|
||||
$(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -DHAVE_CONFIG_H $< -o $@
|
||||
|
||||
$(NWOS)/test_char.h: gen_test_char.exe $(SERVER)/gen_test_char.c
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$< > $@
|
||||
|
||||
%.exe: $(SERVER)/%.c
|
||||
@echo $(DL)Creating Build Helper $@$(DL)
|
||||
$(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -DCROSS_COMPILE $< -o $@
|
||||
|
||||
else
|
||||
|
||||
ifneq "$(wildcard $(NWOS)/chartables.c)" "$(NWOS)/chartables.c"
|
||||
$(error Error: required source $(NWOS)/chartables.c not found!)
|
||||
endif
|
||||
|
||||
ifneq "$(wildcard $(NWOS)/test_char.h)" "$(NWOS)/test_char.h"
|
||||
$(error Error: required header $(NWOS)/test_char.h not found!)
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
#
|
||||
# Check for minimum APR version
|
||||
#
|
||||
chkapr: $(APR)/build/nw_ver.awk $(APR)/include/apr_version.h
|
||||
@echo $(DL)Checking for APR version...$(DL)
|
||||
$(AWK) -v WANTED=$(APR_WANTED) -f $^
|
||||
|
||||
#
|
||||
# You can use this target if all that is needed is to copy files to the
|
||||
# installation area
|
||||
#
|
||||
install :: nlms FORCE
|
||||
|
||||
clean ::
|
||||
$(call DEL,$(SRC)/include/ap_config_layout.h)
|
||||
$(call DEL,$(PCRE)/config.h)
|
||||
$(call DEL,$(PCRE)/pcre.h)
|
||||
$(call DEL,$(STDMOD)/cache/mod_cache.imp)
|
||||
$(call DEL,$(DAV)/main/dav.imp)
|
||||
$(call DEL,$(NWOS)/httpd.imp)
|
||||
$(call DEL,nw_export.i)
|
||||
$(call DEL,cc.opt)
|
||||
$(call DEL,NWGNUversion.inc)
|
||||
ifneq "$(BUILDTOOL_AS_NLM)" "1"
|
||||
$(call DEL,$(NWOS)/chartables.c)
|
||||
$(call DEL,$(NWOS)/test_char.h)
|
||||
$(call DEL,dftables.exe)
|
||||
$(call DEL,gen_test_char.exe)
|
||||
endif
|
||||
|
||||
#
|
||||
# Include the 'tail' makefile that has targets that depend on variables defined
|
||||
# in this makefile
|
||||
#
|
||||
|
||||
include $(APBUILD)/NWGNUtail.inc
|
||||
|
43
build/NWGNUscripts.inc
Normal file
43
build/NWGNUscripts.inc
Normal file
|
@ -0,0 +1,43 @@
|
|||
# Include for creating start/stop/restart NCF scripts.
|
||||
|
||||
instscripts:: FORCE $(INSTALLBASE)/ap2start.ncf $(INSTALLBASE)/ap2auto.ncf $(INSTALLBASE)/ap2rest.ncf $(INSTALLBASE)/ap2stop.ncf
|
||||
|
||||
$(INSTALLBASE)/ap2start.ncf:
|
||||
@echo $(DL)# NCF to start Apache 2.x in own address space$(DL)> $@
|
||||
@echo $(DL)# Make sure that httpstk is not listening on 80$(DL)>> $@
|
||||
@echo $(DL)# httpcloseport 80 /silent$(DL)>> $@
|
||||
@echo $(DL)# search add SYS:/$(BASEDIR)$(DL)>> $@
|
||||
@echo $(DL)load address space = $(BASEDIR) SYS:/$(BASEDIR)/apache2$(DL)>> $@
|
||||
@echo $(DL)# If you have problems with 3rd-party modules try to load in OS space.$(DL)>> $@
|
||||
@echo $(DL)# load SYS:/$(BASEDIR)/apache2$(DL)>> $@
|
||||
@$(ECHONL)>> $@
|
||||
|
||||
$(INSTALLBASE)/ap2auto.ncf:
|
||||
@echo $(DL)# NCF to start Apache 2.x in own address space$(DL)> $@
|
||||
@echo $(DL)# and let automatically restart in case it crashes$(DL)>> $@
|
||||
@echo $(DL)# Make sure that httpstk is not listening on 80$(DL)>> $@
|
||||
@echo $(DL)# httpcloseport 80 /silent$(DL)>> $@
|
||||
@echo $(DL)# search add SYS:/$(BASEDIR)$(DL)>> $@
|
||||
@echo $(DL)restart address space = $(BASEDIR) SYS:/$(BASEDIR)/apache2$(DL)>> $@
|
||||
@$(ECHONL)>> $@
|
||||
|
||||
$(INSTALLBASE)/ap2rest.ncf:
|
||||
@echo $(DL)# NCF to restart Apache 2.x in own address space$(DL)> $@
|
||||
@echo $(DL)apache2 restart -p $(BASEDIR)$(DL)>> $@
|
||||
@echo $(DL)# If you have loaded Apache2.x in OS space use the line below.$(DL)>> $@
|
||||
@echo $(DL)# apache2 restart$(DL)>> $@
|
||||
@$(ECHONL)>> $@
|
||||
|
||||
$(INSTALLBASE)/ap2stop.ncf:
|
||||
@echo $(DL)# NCF to stop Apache 2.x in own address space$(DL)> $@
|
||||
@echo $(DL)apache2 shutdown -p $(BASEDIR)$(DL)>> $@
|
||||
@echo $(DL)# If you have loaded Apache2.x in OS space use the line below.$(DL)>> $@
|
||||
@echo $(DL)# apache2 shutdown$(DL)>> $@
|
||||
@$(ECHONL)>> $@
|
||||
|
||||
$(INSTALLBASE)/ap2prod.ncf:
|
||||
@echo $(DL)# NCF to create a product record for Apache 2.x in product database$(DL)> $@
|
||||
@echo $(DL)PRODSYNC DEL APACHE$(VERSION_MAJMIN)$(DL)>> $@
|
||||
@echo $(DL)PRODSYNC ADD APACHE$(VERSION_MAJMIN) ProductRecord "$(VERSION_STR)" "Apache $(VERSION_STR) Webserver"$(DL)>> $@
|
||||
@$(ECHONL)>> $@
|
||||
|
332
build/NWGNUtail.inc
Normal file
332
build/NWGNUtail.inc
Normal file
|
@ -0,0 +1,332 @@
|
|||
#
|
||||
# This contains final targets and should be included at the end of any
|
||||
# NWGNUmakefile file
|
||||
#
|
||||
|
||||
#
|
||||
# If we are going to create an nlm, make sure we have assigned variables to
|
||||
# use during the link.
|
||||
#
|
||||
ifndef NLM_NAME
|
||||
NLM_NAME = $(TARGET_nlm)
|
||||
endif
|
||||
|
||||
ifndef NLM_DESCRIPTION
|
||||
NLM_DESCRIPTION = $(NLM_NAME)
|
||||
endif
|
||||
|
||||
ifndef NLM_THREAD_NAME
|
||||
NLM_THREAD_NAME = $(NLM_NAME) Thread
|
||||
endif
|
||||
|
||||
ifndef NLM_SCREEN_NAME
|
||||
NLM_SCREEN_NAME = DEFAULT
|
||||
endif
|
||||
|
||||
ifndef NLM_COPYRIGHT
|
||||
NLM_COPYRIGHT = Licensed under the Apache License, Version 2.0
|
||||
endif
|
||||
|
||||
ifeq "$(NLM_FLAGS)" ""
|
||||
NLM_FLAGS = AUTOUNLOAD, PSEUDOPREEMPTION
|
||||
endif
|
||||
|
||||
ifeq "$(NLM_STACK_SIZE)" ""
|
||||
NLM_STACK_SIZE = 65536
|
||||
endif
|
||||
|
||||
ifeq "$(NLM_ENTRY_SYM)" ""
|
||||
NLM_ENTRY_SYM = _LibCPrelude
|
||||
endif
|
||||
|
||||
ifeq "$(NLM_EXIT_SYM)" ""
|
||||
NLM_EXIT_SYM = _LibCPostlude
|
||||
endif
|
||||
|
||||
ifeq "$(NLM_VERSION)" ""
|
||||
NLM_VERSION = $(VERSION)
|
||||
endif
|
||||
|
||||
#
|
||||
# Create dependency lists based on the files available
|
||||
#
|
||||
|
||||
STANDARD_DEPENDS = \
|
||||
$(APBUILD)/NWGNUhead.inc \
|
||||
$(APBUILD)/NWGNUenvironment.inc \
|
||||
$(APBUILD)/NWGNUtail.inc \
|
||||
$(CUSTOM_INI) \
|
||||
$(EOLIST)
|
||||
|
||||
CCOPT_DEPENDS = $(STANDARD_DEPENDS)
|
||||
|
||||
$(NLM_NAME)_LINKOPT_DEPENDS = \
|
||||
$(TARGET_lib) \
|
||||
$(STANDARD_DEPENDS) \
|
||||
$(VERSION_INC) \
|
||||
$(EOLIST)
|
||||
|
||||
ifeq "$(words $(strip $(TARGET_lib)))" "1"
|
||||
LIB_NAME = $(basename $(notdir $(TARGET_lib)))
|
||||
$(LIB_NAME)_LIBLST_DEPENDS = \
|
||||
$(FILES_lib_objs) \
|
||||
$(STANDARD_DEPENDS) \
|
||||
$(CUSTOM_INI) \
|
||||
$(EOLIST)
|
||||
endif
|
||||
|
||||
ifeq "$(wildcard NWGNU$(LIB_NAME))" "NWGNU$(LIB_NAME)"
|
||||
$(LIB_NAME)_LIBLST_DEPENDS += NWGNU$(LIB_NAME)
|
||||
CCOPT_DEPENDS += NWGNU$(LIB_NAME)
|
||||
else
|
||||
CCOPT_DEPENDS += NWGNUmakefile
|
||||
endif
|
||||
|
||||
ifeq "$(wildcard NWGNU$(NLM_NAME))" "NWGNU$(NLM_NAME)"
|
||||
$(NLM_NAME)_LINKOPT_DEPENDS += NWGNU$(NLM_NAME)
|
||||
CCOPT_DEPENDS += NWGNU$(NLM_NAME)
|
||||
else
|
||||
CCOPT_DEPENDS += NWGNUmakefile
|
||||
endif
|
||||
|
||||
CPPOPT_DEPENDS = $(CCOPT_DEPENDS)
|
||||
|
||||
#
|
||||
# Generic compiler rules
|
||||
#
|
||||
|
||||
ifneq "$(MAKECMDGOALS)" "clean"
|
||||
ifneq "$(findstring clobber_,$(MAKECMDGOALS))" "clobber_"
|
||||
$(APBUILD)/NWGNUversion.inc: $(APBUILD)/nw_ver.awk $(SRC)/include/ap_release.h
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
$(AWK) -f $^ $(SRC)/.svn/all-wcprops > $@
|
||||
|
||||
-include $(APBUILD)/NWGNUversion.inc
|
||||
|
||||
ifneq "$(strip $(VERSION_STR))" ""
|
||||
VERSION_INC = $(APBUILD)/NWGNUversion.inc
|
||||
else
|
||||
VERSION = 2,4,0
|
||||
VERSION_STR = 2.4.0
|
||||
VERSION_MAJMIN = 24
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
ifeq "$(USE_SVNREV)" "1"
|
||||
ifneq "$(strip $(SVN_REVISION))" ""
|
||||
CFLAGS += -DAP_SERVER_ADD_STRING=\"$(SVN_REVISION)\"
|
||||
endif
|
||||
endif
|
||||
|
||||
|
||||
ifeq "$(words $(strip $(TARGET_nlm)))" "1"
|
||||
|
||||
$(OBJDIR)/%.o: %.c $(OBJDIR)/$(NLM_NAME)_cc.opt
|
||||
@echo $(DL)CC $<$(DL)
|
||||
$(CC) -o $@ $< @$(word 2, $^)
|
||||
|
||||
$(OBJDIR)/$(NLM_NAME)_cc.opt: $(CCOPT_DEPENDS)
|
||||
$(call DEL,$@)
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
ifneq "$(strip $(CFLAGS))" ""
|
||||
@echo $(DL)$(CFLAGS)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XCFLAGS))" ""
|
||||
@echo $(DL)$(XCFLAGS)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XINCDIRS))" ""
|
||||
@echo $(DL)$(foreach xincdir,$(strip $(subst ;,$(SPACE),$(XINCDIRS))),-I$(xincdir))$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(INCDIRS))" ""
|
||||
@echo $(DL)$(foreach incdir,$(strip $(subst ;,$(SPACE),$(INCDIRS))),-I$(incdir))$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(DEFINES))" ""
|
||||
@echo $(DL)$(DEFINES)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XDEFINES))" ""
|
||||
@echo $(DL)$(XDEFINES)$(DL)>> $@
|
||||
endif
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp $(OBJDIR)/$(NLM_NAME)_cpp.opt
|
||||
@echo $(DL)CC $<$(DL)
|
||||
$(CC) -o $@ $< @$(word 2, $^)
|
||||
|
||||
$(OBJDIR)/$(NLM_NAME)_cpp.opt: $(CPPOPT_DEPENDS)
|
||||
$(call DEL,$@)
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
ifneq "$(strip $(CFLAGS))" ""
|
||||
@echo $(DL)$(CFLAGS)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XCFLAGS))" ""
|
||||
@echo $(DL)$(XCFLAGS)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XINCDIRS))" ""
|
||||
@echo $(DL)$(foreach xincdir,$(strip $(subst ;,$(SPACE),$(XINCDIRS))),-I$(xincdir))$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(INCDIRS))" ""
|
||||
@echo $(DL)$(foreach incdir,$(strip $(subst ;,$(SPACE),$(INCDIRS))),-I$(incdir))$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(DEFINES))" ""
|
||||
@echo $(DL)$(DEFINES)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(XDEFINES))" ""
|
||||
@echo $(DL)$(XDEFINES)$(DL)>> $@
|
||||
endif
|
||||
|
||||
endif # one target nlm
|
||||
|
||||
#
|
||||
# Rules to build libraries
|
||||
#
|
||||
|
||||
# If we only have one target library then build it
|
||||
|
||||
ifeq "$(words $(strip $(TARGET_lib)))" "1"
|
||||
|
||||
$(TARGET_lib) : $(OBJDIR)/$(LIB_NAME)_lib.lst
|
||||
$(call DEL,$@)
|
||||
@echo $(DL)AR $@$(DL)
|
||||
$(LIB) -o $@ @$<
|
||||
|
||||
$(OBJDIR)/$(LIB_NAME)_lib.lst: $($(LIB_NAME)_LIBLST_DEPENDS)
|
||||
$(call DEL,$@)
|
||||
ifneq "$(strip $(FILES_lib_objs))" ""
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
@echo $(DL)$(FILES_lib_objs)$(DL)>> $@
|
||||
endif
|
||||
|
||||
else # We must have more than one target library so load the individual makefiles
|
||||
|
||||
$(OBJDIR)/%.lib: NWGNU% $(STANDARD_DEPENDS) FORCE
|
||||
@echo $(DL)Calling $<$(DL)
|
||||
$(MAKE) -f $< $(MAKECMDGOALS) RELEASE=$(RELEASE)
|
||||
|
||||
endif
|
||||
|
||||
#
|
||||
# Rules to build nlms.
|
||||
#
|
||||
|
||||
# If we only have one target NLM then build it
|
||||
ifeq "$(words $(strip $(TARGET_nlm)))" "1"
|
||||
|
||||
$(TARGET_nlm) : $(FILES_nlm_objs) $(FILES_nlm_libs) $(OBJDIR)/$(NLM_NAME)_link.opt
|
||||
@echo $(DL)LINK $@$(DL)
|
||||
$(LINK) @$(OBJDIR)/$(NLM_NAME)_link.opt
|
||||
|
||||
# This will force the link option file to be rebuilt if we change the
|
||||
# corresponding makefile
|
||||
|
||||
$(OBJDIR)/$(NLM_NAME)_link.opt : $($(NLM_NAME)_LINKOPT_DEPENDS)
|
||||
$(call DEL,$@)
|
||||
$(call DEL,$(@:.opt=.def))
|
||||
@echo $(DL)GEN $@$(DL)
|
||||
@echo $(DL)-nlmversion=$(NLM_VERSION)$(DL)>> $@
|
||||
@echo $(DL)-warnings off$(DL)>> $@
|
||||
@echo $(DL)-zerobss$(DL)>> $@
|
||||
@echo $(DL)-o $(TARGET_nlm)$(DL)>> $@
|
||||
ifneq "$(FILE_nlm_copyright)" ""
|
||||
@$(CAT) $(FILE_nlm_copyright)>> $@
|
||||
endif
|
||||
ifeq "$(RELEASE)" "debug"
|
||||
@echo $(DL)-g$(DL)>> $@
|
||||
@echo $(DL)-sym internal$(DL)>> $@
|
||||
@echo $(DL)-sym codeview4$(DL)>> $@
|
||||
@echo $(DL)-osym $(OBJDIR)/$(NLM_NAME).sym$(DL)>> $@
|
||||
else
|
||||
@echo $(DL)-sym internal$(DL)>> $@
|
||||
endif
|
||||
@echo $(DL)-l $(SRC)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(HTTPD)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(SERVER)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(STDMOD)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(NWOS)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(NWOS)$(DL)>> $@
|
||||
@echo $(DL)-l $(APR)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(APR)$(DL)>> $@
|
||||
@echo $(DL)-l $(APRUTIL)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(PCRE)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l "$(METROWERKS)/Novell Support/Metrowerks Support/Libraries/Runtime"$(DL)>> $@
|
||||
@echo $(DL)-l "$(METROWERKS)/Novell Support/Metrowerks Support/Libraries/MSL C++"$(DL)>> $@
|
||||
ifneq "$(IPV6)" ""
|
||||
@echo $(DL)-l $(NOVELLLIBC)/include/winsock/IPV6$(DL)>> $@
|
||||
endif
|
||||
@echo $(DL)-l $(NOVELLLIBC)/imports$(DL)>> $@
|
||||
ifneq "$(LDAPSDK)" ""
|
||||
@echo $(DL)-l $(LDAPSDK)/imports$(DL)>> $@
|
||||
endif
|
||||
@echo $(DL)-l $(APULDAP)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(XML)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-l $(SRC)/$(OBJDIR)$(DL)>> $@
|
||||
@echo $(DL)-nodefaults$(DL)>> $@
|
||||
@echo $(DL)-map $(OBJDIR)/$(NLM_NAME).map$(DL)>> $@
|
||||
ifneq "$(strip $(XLFLAGS))" ""
|
||||
@echo $(DL)$(XLFLAGS)$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(strip $(FILES_nlm_objs))" ""
|
||||
@echo $(DL)$(foreach objfile,$(strip $(FILES_nlm_objs)),$(objfile))$(DL)>> $@
|
||||
endif
|
||||
ifneq "$(FILES_nlm_libs)" ""
|
||||
@echo $(DL)$(foreach libfile, $(notdir $(strip $(FILES_nlm_libs))),-l$(libfile))$(DL)>> $@
|
||||
endif
|
||||
@echo $(DL)-commandfile $(@:.opt=.def)$(DL)>> $@
|
||||
@echo $(DL)# Do not edit this file - it is created by make!$(DL)> $(@:.opt=.def)
|
||||
@echo $(DL)# All your changes will be lost!!$(DL)>> $(@:.opt=.def)
|
||||
ifneq "$(FILE_nlm_msg)" ""
|
||||
@echo $(DL)Messages $(FILE_nlm_msg)$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
ifneq "$(FILE_nlm_hlp)" ""
|
||||
@echo $(DL)Help $(FILE_nlm_hlp)$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
ifeq "$(FILE_nlm_copyright)" ""
|
||||
@echo $(DL)copyright "$(NLM_COPYRIGHT)"$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
@echo $(DL)description "$(NLM_DESCRIPTION)"$(DL)>> $(@:.opt=.def)
|
||||
@echo $(DL)threadname "$(NLM_THREAD_NAME)"$(DL)>> $(@:.opt=.def)
|
||||
@echo $(DL)screenname "$(NLM_SCREEN_NAME)"$(DL)>> $(@:.opt=.def)
|
||||
@echo $(DL)stacksize $(subst K,000,$(subst k,K,$(strip $(NLM_STACK_SIZE))))$(DL)>> $(@:.opt=.def)
|
||||
# @echo $(DL)version $(NLM_VERSION) $(DL)>> $(@:.opt=.def)
|
||||
@echo $(DL)start $(NLM_ENTRY_SYM)$(DL)>> $(@:.opt=.def)
|
||||
@echo $(DL)exit $(NLM_EXIT_SYM)$(DL)>> $(@:.opt=.def)
|
||||
ifneq "$(NLM_CHECK_SYM)" ""
|
||||
@echo $(DL)check $(NLM_CHECK_SYM)$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
@echo $(DL)$(strip $(NLM_FLAGS))$(DL)>> $(@:.opt=.def)
|
||||
ifneq "$(FILES_nlm_modules)" ""
|
||||
@echo $(DL)module $(foreach module,$(subst $(SPACE),$(COMMA),$(strip $(FILES_nlm_modules))),$(module))$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
ifneq "$(FILES_nlm_Ximports)" ""
|
||||
@echo $(DL)import $(foreach import,$(subst $(SPACE),$(COMMA),$(strip $(FILES_nlm_Ximports))),$(import))$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
ifneq "$(FILES_nlm_exports)" ""
|
||||
@echo $(DL)export $(foreach export,$(subst $(SPACE),$(COMMA),$(strip $(FILES_nlm_exports))),$(export))$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
# if APACHE_UNIPROC is defined, don't include XDCData
|
||||
ifndef APACHE_UNIPROC
|
||||
ifneq "$(string $(XDCDATA))" ""
|
||||
@echo $(DL)xdcdata $(XDCDATA)$(DL)>> $(@:.opt=.def)
|
||||
else
|
||||
@echo $(DL)xdcdata apache.xdc$(DL)>> $(@:.opt=.def)
|
||||
endif
|
||||
endif
|
||||
|
||||
else # more than one target so look for individual makefiles.
|
||||
|
||||
# Only include these if NO_LICENSE_FILE isn't set to prevent excessive
|
||||
# recursion
|
||||
|
||||
ifndef NO_LICENSE_FILE
|
||||
|
||||
$(OBJDIR)/%.nlm: NWGNU% $($(NLM_NAME)_LINKOPT_DEPENDS) FORCE
|
||||
@echo $(DL)Calling $<$(DL)
|
||||
$(MAKE) -f $< $(MAKECMDGOALS) RELEASE=$(RELEASE)
|
||||
@$(ECHONL)
|
||||
|
||||
else
|
||||
|
||||
$(TARGET_nlm):
|
||||
|
||||
endif # NO_LICENSE_FILE
|
||||
|
||||
endif
|
||||
|
130
build/PrintPath
Executable file
130
build/PrintPath
Executable file
|
@ -0,0 +1,130 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# Look for program[s] somewhere in $PATH.
|
||||
#
|
||||
# Options:
|
||||
# -s
|
||||
# Do not print out full pathname. (silent)
|
||||
# -pPATHNAME
|
||||
# Look in PATHNAME instead of $PATH
|
||||
#
|
||||
# Usage:
|
||||
# PrintPath [-s] [-pPATHNAME] program [program ...]
|
||||
#
|
||||
# Initially written by Jim Jagielski for the Apache configuration mechanism
|
||||
# (with kudos to Kernighan/Pike)
|
||||
|
||||
##
|
||||
# Some "constants"
|
||||
##
|
||||
pathname=$PATH
|
||||
echo="yes"
|
||||
|
||||
##
|
||||
# Find out what OS we are running for later on
|
||||
##
|
||||
os=`(uname) 2>/dev/null`
|
||||
|
||||
##
|
||||
# Parse command line
|
||||
##
|
||||
for args in $*
|
||||
do
|
||||
case $args in
|
||||
-s ) echo="no" ;;
|
||||
-p* ) pathname="`echo $args | sed 's/^..//'`" ;;
|
||||
* ) programs="$programs $args" ;;
|
||||
esac
|
||||
done
|
||||
|
||||
##
|
||||
# Now we make the adjustments required for OS/2 and everyone
|
||||
# else :)
|
||||
#
|
||||
# First of all, all OS/2 programs have the '.exe' extension.
|
||||
# Next, we adjust PATH (or what was given to us as PATH) to
|
||||
# be whitespace separated directories.
|
||||
# Finally, we try to determine the best flag to use for
|
||||
# test/[] to look for an executable file. OS/2 just has '-r'
|
||||
# but with other OSs, we do some funny stuff to check to see
|
||||
# if test/[] knows about -x, which is the prefered flag.
|
||||
##
|
||||
|
||||
if [ "x$os" = "xOS/2" ]
|
||||
then
|
||||
ext=".exe"
|
||||
pathname=`echo -E $pathname |
|
||||
sed 's/^;/.;/
|
||||
s/;;/;.;/g
|
||||
s/;$/;./
|
||||
s/;/ /g
|
||||
s/\\\\/\\//g' `
|
||||
test_exec_flag="-r"
|
||||
else
|
||||
ext="" # No default extensions
|
||||
pathname=`echo $pathname |
|
||||
sed 's/^:/.:/
|
||||
s/::/:.:/g
|
||||
s/:$/:./
|
||||
s/:/ /g' `
|
||||
# Here is how we test to see if test/[] can handle -x
|
||||
testfile="pp.t.$$"
|
||||
|
||||
cat > $testfile <<ENDTEST
|
||||
#!/bin/sh
|
||||
if [ -x / ] || [ -x /bin ] || [ -x /bin/ls ]; then
|
||||
exit 0
|
||||
fi
|
||||
exit 1
|
||||
ENDTEST
|
||||
|
||||
if `/bin/sh $testfile 2>/dev/null`; then
|
||||
test_exec_flag="-x"
|
||||
else
|
||||
test_exec_flag="-r"
|
||||
fi
|
||||
rm -f $testfile
|
||||
fi
|
||||
|
||||
for program in $programs
|
||||
do
|
||||
for path in $pathname
|
||||
do
|
||||
if [ $test_exec_flag $path/${program}${ext} ] && \
|
||||
[ ! -d $path/${program}${ext} ]; then
|
||||
if [ "x$echo" = "xyes" ]; then
|
||||
echo $path/${program}${ext}
|
||||
fi
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Next try without extension (if one was used above)
|
||||
if [ "x$ext" != "x" ]; then
|
||||
if [ $test_exec_flag $path/${program} ] && \
|
||||
[ ! -d $path/${program} ]; then
|
||||
if [ "x$echo" = "xyes" ]; then
|
||||
echo $path/${program}
|
||||
fi
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
done
|
||||
done
|
||||
exit 1
|
||||
|
66
build/aix/README
Normal file
66
build/aix/README
Normal file
|
@ -0,0 +1,66 @@
|
|||
The script buildaix.ksh will attempt to build a AIX installp fileset
|
||||
out of a source tree for ASF project
|
||||
|
||||
REQUIREMENTS:
|
||||
Fileset Level State Type Description (Uninstaller)
|
||||
----------------------------------------------------------------------------
|
||||
bos.adt.insttools 5.3.7.2 C F Tool to Create installp
|
||||
Packages
|
||||
Fileset Level State Type Description (Uninstaller)
|
||||
----------------------------------------------------------------------------
|
||||
rpm.rte 3.0.5.41 C F RPM Package Manager
|
||||
|
||||
Additional:
|
||||
Preferred: download zlib sources and copy zlib.h and zconf.h to /opt/include
|
||||
and, if configure cannot find them directly, add symbolic links from /usr/include to /opt/include
|
||||
|
||||
To build a package, make sure you are in the root of the source tree,
|
||||
and run:
|
||||
|
||||
build/aix/buildaix.ksh
|
||||
|
||||
An AIX fileset named $PKG.$NAME.$ARCH.$VERSION.I will be
|
||||
created in the build/aix directory. the .template file created is also there.
|
||||
|
||||
KNOWN issues:
|
||||
on AIX libtool is known to have issues with the install command.
|
||||
Some of these issues have been resolved by extracting the apr/apu utilities
|
||||
from the projects (i.e. NOT using the embedded version)
|
||||
In case of problems I recommend that you install the GNU 'install' program (part of coreutils)
|
||||
If make DESTDIR=$TEMPDIR install command continues to fail, try 'make install' and then run
|
||||
the buildaix.ksh command again
|
||||
|
||||
TODO
|
||||
Add Copyright display/banner
|
||||
Add Apache LICENSE to fileset and require acceptance
|
||||
Add special instructions for TCB - to ignore /etc/* /var/httpd/htdocs/*
|
||||
Add _config_i scripts to setup autostart
|
||||
Add _pre_i scripts to verify pre-requisites, required users/groups, etc.
|
||||
|
||||
# This layout is intended to put customizeable data in /etc and /var
|
||||
# the file listing will be used to create an exceptions file to modify
|
||||
# the behavior of syschk checksum generation.
|
||||
# AIX layout
|
||||
<Layout AIX>
|
||||
prefix: /opt/httpd
|
||||
exec_prefix: /opt/httpd
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec
|
||||
mandir: /usr/share/man
|
||||
sysconfdir: /etc/httpd
|
||||
datadir: /var/httpd
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
iconsdir: ${prefix}/icons
|
||||
manualdir: ${prefix}/manual
|
||||
includedir: ${prefix}/include
|
||||
localstatedir: /var/httpd
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/logs
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
16
build/aix/aixinfo
Normal file
16
build/aix/aixinfo
Normal file
|
@ -0,0 +1,16 @@
|
|||
|
||||
PKG="ASF"
|
||||
NAME="httpd"
|
||||
ARCH="powerpc"
|
||||
VERSION="2.2.22"
|
||||
CATEGORY="application"
|
||||
VENDOR="Apache Software Foundation"
|
||||
EMAIL="dev@httpd.apache.org"
|
||||
VMMN=`build/get-version.sh mmn include/ap_mmn.h MODULE_MAGIC_NUMBER`
|
||||
REVISION=`build/get-version.sh all include/ap_release.h AP_SERVER`
|
||||
VERSION=`echo $REVISION | cut -d- -s -f1`
|
||||
RELEASE=`echo $REVISION | cut -d- -s -f2`
|
||||
if [ "x$VERSION" = "x" ]; then
|
||||
VERSION=$REVISION
|
||||
RELEASE=0
|
||||
fi
|
78
build/aix/aixproto.ksh
Executable file
78
build/aix/aixproto.ksh
Executable file
|
@ -0,0 +1,78 @@
|
|||
#!/usr/bin/ksh
|
||||
TEMPDIR=$1
|
||||
BUILD=`pwd`
|
||||
. build/aix/pkginfo
|
||||
|
||||
package=$PKG
|
||||
name=$NAME
|
||||
vrmf=$VERSION
|
||||
descr="$VENDOR $NAME for $ARCH"
|
||||
umask 022
|
||||
INFO=$BUILD/build/aix/.info
|
||||
mkdir -p $INFO
|
||||
|
||||
template=${INFO}/${PKG}.${NAME}.${vrmf}.template
|
||||
>$template
|
||||
|
||||
cd ${TEMPDIR}
|
||||
rm -rf .info lpp_name tmp
|
||||
# get the directory sizes in blocks
|
||||
for d in etc opt var
|
||||
do
|
||||
set `du -s $d/${NAME}`
|
||||
let sz$d=$1+1
|
||||
done
|
||||
set `du -s usr/share/man`
|
||||
szman=$1+1
|
||||
|
||||
files=./httpd-root
|
||||
cd ${TEMPDIR}/..
|
||||
find ${files} -type d -exec chmod og+rx {} \;
|
||||
chmod -R go+r ${files}
|
||||
chown -R 0:0 ${files}
|
||||
|
||||
cat - <<EOF >>$template
|
||||
Package Name: ${package}.${NAME}
|
||||
Package VRMF: ${vrmf}.0
|
||||
Update: N
|
||||
Fileset
|
||||
Fileset Name: ${package}.${NAME}.rte
|
||||
Fileset VRMF: ${vrmf}.0
|
||||
Fileset Description: ${descr}
|
||||
USRLIBLPPFiles
|
||||
EOUSRLIBLPPFiles
|
||||
Bosboot required: N
|
||||
License agreement acceptance required: N
|
||||
Include license files in this package: N
|
||||
Requisites:
|
||||
Upsize: /usr/share/man ${szman};
|
||||
Upsize: /etc/${NAME} $szetc;
|
||||
Upsize: /opt/${NAME} $szopt;
|
||||
Upsize: /var/${NAME} $szvar;
|
||||
USRFiles
|
||||
EOF
|
||||
|
||||
find ${files} | sed -e s#^${files}## | sed -e "/^$/d" >>$template
|
||||
|
||||
cat - <<EOF >>$template
|
||||
EOUSRFiles
|
||||
ROOT Part: N
|
||||
ROOTFiles
|
||||
EOROOTFiles
|
||||
Relocatable: N
|
||||
EOFileset
|
||||
EOF
|
||||
|
||||
cp ${template} ${BUILD}/build/aix
|
||||
|
||||
# use mkinstallp to create the fileset. result is in ${TEMPDIR}/tmp
|
||||
mkinstallp -d ${TEMPDIR} -T ${template}
|
||||
|
||||
cp ${TEMPDIR}/tmp/$PKG.$NAME.$VERSION.0.bff ${BUILD}/build/aix
|
||||
cd $BUILD/build/aix
|
||||
rm -f $PKG.$NAME.$VERSION.$ARCH.I
|
||||
mv $PKG.$NAME.$VERSION.0.bff $PKG.$NAME.$VERSION.$ARCH.I
|
||||
rm .toc
|
||||
inutoc .
|
||||
installp -d . -ap ${PKG}.${NAME}
|
||||
installp -d . -L
|
127
build/aix/buildaix.ksh
Executable file
127
build/aix/buildaix.ksh
Executable file
|
@ -0,0 +1,127 @@
|
|||
#!/usr/bin/ksh
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
|
||||
# buildaix.ksh: This script builds an AIX fileset of Apache httpd
|
||||
|
||||
# if arguments - try to run fast
|
||||
cmd=$0
|
||||
|
||||
export CFLAGS='-O2 -qlanglvl=extc99'
|
||||
|
||||
lslpp -L bos.adt.insttools >/dev/null
|
||||
[[ $? -ne 0 ]] && echo "must have bos.adt.insttools installed" && exit -1
|
||||
|
||||
apr_config=`which apr-1-config`
|
||||
apu_config=`which apu-1-config`
|
||||
|
||||
if [[ -z ${apr_config} && -z ${apu_config} ]]
|
||||
then
|
||||
export PATH=/opt/bin:${PATH}
|
||||
apr_config=`which apr-1-config`
|
||||
apu_config=`which apu-1-config`
|
||||
fi
|
||||
|
||||
while test $# -gt 0
|
||||
do
|
||||
# Normalize
|
||||
case "$1" in
|
||||
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
|
||||
*) optarg= ;;
|
||||
esac
|
||||
|
||||
case "$1" in
|
||||
--with-apr=*)
|
||||
apr_config=$optarg
|
||||
;;
|
||||
esac
|
||||
|
||||
case "$1" in
|
||||
--with-apr-util=*)
|
||||
apu_config=$optarg
|
||||
;;
|
||||
esac
|
||||
|
||||
shift
|
||||
argc--
|
||||
done
|
||||
|
||||
if [ ! -f "$apr_config" -a ! -f "$apr_config/configure.in" ]; then
|
||||
echo "The apr source directory / apr-1-config could not be found"
|
||||
echo "If available, install the ASF.apu.rte and ASF.apr.rte filesets"
|
||||
echo "Usage: $cmd [--with-apr=[dir|file]] [--with-apr-util=[dir|file]]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -f "$apu_config" -a ! -f "$apu_config/configure.in" ]; then
|
||||
echo "The apu source directory / apu-1-config could not be found"
|
||||
echo "If available, install the ASF.apu.rte and ASF.apr.rte filesets"
|
||||
echo "Usage: $cmd [--with-apr=[dir|file]] [--with-apr-util=[dir|file]]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
. build/aix/aixinfo
|
||||
LAYOUT=AIX
|
||||
TEMPDIR=/var/tmp/$USER/${NAME}.${VERSION}
|
||||
rm -rf $TEMPDIR
|
||||
|
||||
if [[ ! -e ./Makefile ]] # if Makefile exists go faster
|
||||
then
|
||||
# --with-mpm=worker \n\
|
||||
echo "+ ./configure \n\
|
||||
--enable-layout=$LAYOUT \n\
|
||||
--with-apr=$apr_config \n\
|
||||
--with-apr-util=$apu_config \n\
|
||||
--enable-mpms-shared=all \n\
|
||||
--enable-mods-shared=all \n\
|
||||
--disable-lua > build/aix/configure.out"
|
||||
|
||||
# --with-mpm=worker \
|
||||
./configure \
|
||||
--enable-layout=$LAYOUT \
|
||||
--with-apr=$apr_config \
|
||||
--with-apr-util=$apu_config \
|
||||
--enable-mpms-shared=all \
|
||||
--enable-mods-shared=all \
|
||||
--disable-lua > build/aix/configure.out
|
||||
[[ $? -ne 0 ]] && echo './configure' returned an error && exit -1
|
||||
else
|
||||
echo $0: using existing Makefile
|
||||
echo $0: run make distclean to get a standard AIX configure
|
||||
echo
|
||||
ls -l ./Makefile config.*
|
||||
echo
|
||||
fi
|
||||
|
||||
echo "+ make > build/aix/make.out"
|
||||
make > build/aix/make.out
|
||||
[[ $? -ne 0 ]] && echo 'make' returned an error && exit -1
|
||||
|
||||
echo "+ make install DESTDIR=$TEMPDIR > build/aix/install.out"
|
||||
make install DESTDIR=$TEMPDIR > build/aix/install.out
|
||||
[[ $? -ne 0 ]] && echo 'make install' returned an error && exit -1
|
||||
|
||||
echo "+ build/aix/mkinstallp.ksh $TEMPDIR > build/aix/mkinstallp.out"
|
||||
build/aix/mkinstallp.ksh $TEMPDIR > build/aix/mkinstallp.out
|
||||
[[ $? -ne 0 ]] && echo mkinstallp.ksh returned an error && exit -1
|
||||
|
||||
rm -rf $TEMPDIR
|
||||
|
||||
# list installable fileset(s)
|
||||
echo ========================
|
||||
installp -d build/aix -L
|
||||
echo ========================
|
201
build/aix/mkinstallp.ksh
Executable file
201
build/aix/mkinstallp.ksh
Executable file
|
@ -0,0 +1,201 @@
|
|||
#!/usr/bin/ksh
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
|
||||
# minstallp.ksh # create an installp image of ${NAME} (defined in aixinfo)
|
||||
# from TEMPDIR using mkinstallp (part of bos.adt.insttools)
|
||||
|
||||
[[ $# == 0 ]] && echo $0: Syntax error && echo "Syntax: $0 <BaseDirectory>" && exit -1
|
||||
|
||||
umask 022
|
||||
TEMPDIR=$1
|
||||
BASE=`pwd`
|
||||
cd ${TEMPDIR}
|
||||
[[ $? != 0 ]] && echo $0: ${TEMPDIR} -- bad directory && exit -1
|
||||
|
||||
# clean up side-effects from DEBUG passes - usr/local might be there as
|
||||
# a circular link i.e. usr/local points at /usr/local
|
||||
# as we are not using /usr/local for ASF packaging, remove it!
|
||||
# mkinstallp seems to make usr/local -> /usr/local
|
||||
[[ -f usr/local ]] && rm -f usr/local && echo removed unexpected usr/local !!
|
||||
[[ -L usr/local ]] && rm -f usr/local && echo removed unexpected usr/local !!
|
||||
[[ -d usr/local ]] && rm -rf usr/local && echo removed unexpected usr/local !!
|
||||
|
||||
# use the aixinfo for PKG NAME VERSION etc labels
|
||||
cd ${BASE}
|
||||
. build/aix/aixinfo
|
||||
# INFO=${BASE}/build/aix/.info
|
||||
# mkdir -p $INFO
|
||||
INFO=${BASE}/build/aix
|
||||
template=${INFO}/${PKG}.${NAME}.${VERSION}.template
|
||||
>$template
|
||||
|
||||
# mkinstallp template definitions
|
||||
# TODO: add AIX oslevel/uname information for package filename
|
||||
package=$PKG
|
||||
name=$NAME
|
||||
vrmf=$VERSION
|
||||
release=$RELEASE
|
||||
descr="$NAME version ${VERSION} for $ARCH ${VENDOR}"
|
||||
|
||||
# copy LICENSE information
|
||||
# TODO: setup template so that license acceptance is required
|
||||
# TODO: add Copyright Information for display during install
|
||||
mkdir -p ${TEMPDIR}/usr/swlag/en_US
|
||||
cp ${BASE}/LICENSE ${TEMPDIR}/usr/swlag/en_US/${PKG}.${NAME}.la
|
||||
|
||||
cd ${TEMPDIR}
|
||||
# remove files we do not want as "part" possibly
|
||||
# left-over from a previous packaging
|
||||
rm -rf .info lpp_name tmp usr/lpp
|
||||
[[ $? -ne 0 ]] && echo $cmd: cleanup error && pwd && ls -ltr && exit -1
|
||||
|
||||
#if we are going to add extra symbolic links - do it now
|
||||
[[ -r build/aix/aixlinks ]] && ksh build/aix/aixlinks
|
||||
|
||||
# get the directory sizes in blocks
|
||||
for d in etc opt var
|
||||
do
|
||||
if [[ -d $d/${NAME} ]]
|
||||
then
|
||||
set `du -s $d/${NAME}`
|
||||
else
|
||||
[[ -d $d ]] && set `du -s $d`
|
||||
fi
|
||||
# make sure the argument exists before using setting values
|
||||
if [[ -d $d ]]
|
||||
then
|
||||
eval nm$d=/"$2"
|
||||
let sz$d=$1
|
||||
fi
|
||||
done
|
||||
|
||||
files=./${NAME}.${VERSION}
|
||||
cd ${TEMPDIR}/..
|
||||
find ${files} -type d -exec chmod og+rx {} \;
|
||||
chmod -R go+r ${files}
|
||||
chown -R 0.0 ${files}
|
||||
|
||||
cat - <<EOF >>$template
|
||||
Package Name: ${PKG}.${NAME}
|
||||
Package VRMF: ${VERSION}.${RELEASE}
|
||||
Update: N
|
||||
Fileset
|
||||
Fileset Name: ${PKG}.${NAME}.rte
|
||||
Fileset VRMF: ${VERSION}.${RELEASE}
|
||||
Fileset Description: ${descr}
|
||||
USRLIBLPPFiles
|
||||
EOUSRLIBLPPFiles
|
||||
Bosboot required: N
|
||||
License agreement acceptance required: N
|
||||
Name of license agreement:
|
||||
Include license files in this package: N
|
||||
Requisites:
|
||||
EOF
|
||||
|
||||
[[ $szetc -ne 0 ]] && echo " Upsize: ${nmetc} $szetc;" >> $template
|
||||
[[ $szopt -ne 0 ]] && echo " Upsize: ${nmopt} $szopt;" >> $template
|
||||
[[ $szvar -ne 0 ]] && echo " Upsize: ${nmvar} $szvar;" >> $template
|
||||
echo " USRFiles" >> $template
|
||||
|
||||
# USR part -- i.e. files in /usr and /opt
|
||||
cd ${TEMPDIR}/..
|
||||
find ${files}/usr/swlag ${files}/opt \
|
||||
| sed -e s#^${files}## | sed -e "/^$/d" >>$template
|
||||
echo " EOUSRFiles" >> $template
|
||||
|
||||
if [[ $szetc -gt 0 || $szvar -gt 0 ]]
|
||||
then
|
||||
INSTROOT=${TEMPDIR}/usr/lpp/${PKG}.${NAME}/inst_root
|
||||
mkdir -p ${INSTROOT}
|
||||
cd ${TEMPDIR}
|
||||
[[ $szetc -gt 0 ]] && find ./etc -type d | backup -if - | (cd ${INSTROOT}; restore -xqf -) >/dev/null
|
||||
[[ $szvar -gt 0 ]] && find ./var -type d | backup -if - | (cd ${INSTROOT}; restore -xqf -) >/dev/null
|
||||
cat - <<EOF >>$template
|
||||
ROOT Part: Y
|
||||
ROOTFiles
|
||||
EOF
|
||||
|
||||
# ROOT part
|
||||
cd ${TEMPDIR}/..
|
||||
find ${files}/etc ${files}/var \
|
||||
| sed -e s#^${files}## | sed -e "/^$/d" >>$template
|
||||
else
|
||||
# no ROOT parts to include
|
||||
cat - <<EOF >>$template
|
||||
ROOT Part: N
|
||||
ROOTFiles
|
||||
EOF
|
||||
fi
|
||||
cat - <<EOF >>$template
|
||||
EOROOTFiles
|
||||
Relocatable: N
|
||||
EOFileset
|
||||
EOF
|
||||
# man pages as separate fileset
|
||||
cd ${TEMPDIR}
|
||||
if [[ -d usr/share/man ]]
|
||||
then
|
||||
# manual pages, space required calculation
|
||||
set `du -s usr/share/man`
|
||||
szman=$1
|
||||
descr="$NAME ${VERSION} man pages ${VENDOR}"
|
||||
cat - <<EOF >>$template
|
||||
Fileset
|
||||
Fileset Name: ${PKG}.${NAME}.man.en_US
|
||||
Fileset VRMF: ${VERSION}.${RELEASE}
|
||||
Fileset Description: ${descr}
|
||||
USRLIBLPPFiles
|
||||
EOUSRLIBLPPFiles
|
||||
Bosboot required: N
|
||||
License agreement acceptance required: N
|
||||
Name of license agreement:
|
||||
Include license files in this package: N
|
||||
Requisites:
|
||||
EOF
|
||||
|
||||
echo " Upsize: /usr/share/man ${szman};" >> $template
|
||||
echo " USRFiles" >> $template
|
||||
cd ${TEMPDIR}/..
|
||||
find ${files}/usr/share | sed -e s#^${files}## | sed -e "/^$/d" >>$template
|
||||
cat - <<EOF >>$template
|
||||
EOUSRFiles
|
||||
ROOT Part: N
|
||||
ROOTFiles
|
||||
EOROOTFiles
|
||||
Relocatable: N
|
||||
EOFileset
|
||||
|
||||
EOF
|
||||
fi
|
||||
|
||||
# use mkinstallp to create the fileset. result is in ${TEMPDIR}/tmp
|
||||
# must actually sit in TEMPDIR for ROOT part processing to succeed
|
||||
# also - need "empty" directories to exist, as they do not get copied
|
||||
# in the inst_root part
|
||||
cd ${TEMPDIR}
|
||||
mkinstallp -d ${TEMPDIR} -T ${template}
|
||||
[[ $? -ne 0 ]] && echo mkinstallp returned error status && exit -1
|
||||
|
||||
# copy package to build/aix
|
||||
# create TOC
|
||||
cp ${TEMPDIR}/tmp/$PKG.$NAME.$VERSION.0.bff ${BASE}/build/aix
|
||||
cd ${BASE}/build/aix
|
||||
rm -f $PKG.$NAME.$VERSION.$ARCH.I
|
||||
mv $PKG.$NAME.$VERSION.0.bff $PKG.$NAME.$ARCH.$VERSION.I
|
||||
rm -f .toc
|
||||
inutoc .
|
987
build/apr_common.m4
Normal file
987
build/apr_common.m4
Normal file
|
@ -0,0 +1,987 @@
|
|||
dnl -------------------------------------------------------- -*- autoconf -*-
|
||||
dnl Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
dnl contributor license agreements. See the NOTICE file distributed with
|
||||
dnl this work for additional information regarding copyright ownership.
|
||||
dnl The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
dnl (the "License"); you may not use this file except in compliance with
|
||||
dnl the License. You may obtain a copy of the License at
|
||||
dnl
|
||||
dnl http://www.apache.org/licenses/LICENSE-2.0
|
||||
dnl
|
||||
dnl Unless required by applicable law or agreed to in writing, software
|
||||
dnl distributed under the License is distributed on an "AS IS" BASIS,
|
||||
dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
dnl See the License for the specific language governing permissions and
|
||||
dnl limitations under the License.
|
||||
|
||||
dnl
|
||||
dnl apr_common.m4: APR's general-purpose autoconf macros
|
||||
dnl
|
||||
|
||||
dnl
|
||||
dnl APR_CONFIG_NICE(filename)
|
||||
dnl
|
||||
dnl Saves a snapshot of the configure command-line for later reuse
|
||||
dnl
|
||||
AC_DEFUN([APR_CONFIG_NICE], [
|
||||
rm -f $1
|
||||
cat >$1<<EOF
|
||||
#! /bin/sh
|
||||
#
|
||||
# Created by configure
|
||||
|
||||
EOF
|
||||
if test -n "$CC"; then
|
||||
echo "CC=\"$CC\"; export CC" >> $1
|
||||
fi
|
||||
if test -n "$CFLAGS"; then
|
||||
echo "CFLAGS=\"$CFLAGS\"; export CFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$CPPFLAGS"; then
|
||||
echo "CPPFLAGS=\"$CPPFLAGS\"; export CPPFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$LDFLAGS"; then
|
||||
echo "LDFLAGS=\"$LDFLAGS\"; export LDFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$LTFLAGS"; then
|
||||
echo "LTFLAGS=\"$LTFLAGS\"; export LTFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$LIBS"; then
|
||||
echo "LIBS=\"$LIBS\"; export LIBS" >> $1
|
||||
fi
|
||||
if test -n "$INCLUDES"; then
|
||||
echo "INCLUDES=\"$INCLUDES\"; export INCLUDES" >> $1
|
||||
fi
|
||||
if test -n "$NOTEST_CFLAGS"; then
|
||||
echo "NOTEST_CFLAGS=\"$NOTEST_CFLAGS\"; export NOTEST_CFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$NOTEST_CPPFLAGS"; then
|
||||
echo "NOTEST_CPPFLAGS=\"$NOTEST_CPPFLAGS\"; export NOTEST_CPPFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$NOTEST_LDFLAGS"; then
|
||||
echo "NOTEST_LDFLAGS=\"$NOTEST_LDFLAGS\"; export NOTEST_LDFLAGS" >> $1
|
||||
fi
|
||||
if test -n "$NOTEST_LIBS"; then
|
||||
echo "NOTEST_LIBS=\"$NOTEST_LIBS\"; export NOTEST_LIBS" >> $1
|
||||
fi
|
||||
|
||||
# Retrieve command-line arguments.
|
||||
eval "set x $[0] $ac_configure_args"
|
||||
shift
|
||||
|
||||
for arg
|
||||
do
|
||||
APR_EXPAND_VAR(arg, $arg)
|
||||
echo "\"[$]arg\" \\" >> $1
|
||||
done
|
||||
echo '"[$]@"' >> $1
|
||||
chmod +x $1
|
||||
])dnl
|
||||
|
||||
dnl APR_MKDIR_P_CHECK(fallback-mkdir-p)
|
||||
dnl checks whether mkdir -p works
|
||||
AC_DEFUN([APR_MKDIR_P_CHECK], [
|
||||
AC_CACHE_CHECK(for working mkdir -p, ac_cv_mkdir_p,[
|
||||
test -d conftestdir && rm -rf conftestdir
|
||||
mkdir -p conftestdir/somedir >/dev/null 2>&1
|
||||
if test -d conftestdir/somedir; then
|
||||
ac_cv_mkdir_p=yes
|
||||
else
|
||||
ac_cv_mkdir_p=no
|
||||
fi
|
||||
rm -rf conftestdir
|
||||
])
|
||||
if test "$ac_cv_mkdir_p" = "yes"; then
|
||||
mkdir_p="mkdir -p"
|
||||
else
|
||||
mkdir_p="$1"
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_SUBDIR_CONFIG(dir [, sub-package-cmdline-args, args-to-drop])
|
||||
dnl
|
||||
dnl dir: directory to find configure in
|
||||
dnl sub-package-cmdline-args: arguments to add to the invocation (optional)
|
||||
dnl args-to-drop: arguments to drop from the invocation (optional)
|
||||
dnl
|
||||
dnl Note: This macro relies on ac_configure_args being set properly.
|
||||
dnl
|
||||
dnl The args-to-drop argument is shoved into a case statement, so
|
||||
dnl multiple arguments can be separated with a |.
|
||||
dnl
|
||||
dnl Note: Older versions of autoconf do not single-quote args, while 2.54+
|
||||
dnl places quotes around every argument. So, if you want to drop the
|
||||
dnl argument called --enable-layout, you must pass the third argument as:
|
||||
dnl [--enable-layout=*|\'--enable-layout=*]
|
||||
dnl
|
||||
dnl Trying to optimize this is left as an exercise to the reader who wants
|
||||
dnl to put up with more autoconf craziness. I give up.
|
||||
dnl
|
||||
AC_DEFUN([APR_SUBDIR_CONFIG], [
|
||||
# save our work to this point; this allows the sub-package to use it
|
||||
AC_CACHE_SAVE
|
||||
|
||||
echo "configuring package in $1 now"
|
||||
ac_popdir=`pwd`
|
||||
apr_config_subdirs="$1"
|
||||
test -d $1 || $mkdir_p $1
|
||||
ac_abs_srcdir=`(cd $srcdir/$1 && pwd)`
|
||||
cd $1
|
||||
|
||||
changequote(, )dnl
|
||||
# A "../" for each directory in /$config_subdirs.
|
||||
ac_dots=`echo $apr_config_subdirs|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
|
||||
changequote([, ])dnl
|
||||
|
||||
# Make the cache file pathname absolute for the subdirs
|
||||
# required to correctly handle subdirs that might actually
|
||||
# be symlinks
|
||||
case "$cache_file" in
|
||||
/*) # already absolute
|
||||
ac_sub_cache_file=$cache_file ;;
|
||||
*) # Was relative path.
|
||||
ac_sub_cache_file="$ac_popdir/$cache_file" ;;
|
||||
esac
|
||||
|
||||
ifelse($3, [], [apr_configure_args=$ac_configure_args],[
|
||||
apr_configure_args=
|
||||
apr_sep=
|
||||
for apr_configure_arg in $ac_configure_args
|
||||
do
|
||||
case "$apr_configure_arg" in
|
||||
$3)
|
||||
continue ;;
|
||||
esac
|
||||
apr_configure_args="$apr_configure_args$apr_sep'$apr_configure_arg'"
|
||||
apr_sep=" "
|
||||
done
|
||||
])
|
||||
|
||||
dnl autoconf doesn't add --silent to ac_configure_args; explicitly pass it
|
||||
test "x$silent" = "xyes" && apr_configure_args="$apr_configure_args --silent"
|
||||
|
||||
dnl AC_CONFIG_SUBDIRS silences option warnings, emulate this for 2.62
|
||||
apr_configure_args="--disable-option-checking $apr_configure_args"
|
||||
|
||||
dnl The eval makes quoting arguments work - specifically the second argument
|
||||
dnl where the quoting mechanisms used is "" rather than [].
|
||||
dnl
|
||||
dnl We need to execute another shell because some autoconf/shell combinations
|
||||
dnl will choke after doing repeated APR_SUBDIR_CONFIG()s. (Namely Solaris
|
||||
dnl and autoconf-2.54+)
|
||||
if eval $SHELL $ac_abs_srcdir/configure $apr_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_abs_srcdir $2
|
||||
then :
|
||||
echo "$1 configured properly"
|
||||
else
|
||||
echo "configure failed for $1"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd $ac_popdir
|
||||
|
||||
# grab any updates from the sub-package
|
||||
AC_CACHE_LOAD
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_SAVE_THE_ENVIRONMENT(variable_name)
|
||||
dnl
|
||||
dnl Stores the variable (usually a Makefile macro) for later restoration
|
||||
dnl
|
||||
AC_DEFUN([APR_SAVE_THE_ENVIRONMENT], [
|
||||
apr_ste_save_$1="$$1"
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_RESTORE_THE_ENVIRONMENT(variable_name, prefix_)
|
||||
dnl
|
||||
dnl Uses the previously saved variable content to figure out what configure
|
||||
dnl has added to the variable, moving the new bits to prefix_variable_name
|
||||
dnl and restoring the original variable contents. This makes it possible
|
||||
dnl for a user to override configure when it does something stupid.
|
||||
dnl
|
||||
AC_DEFUN([APR_RESTORE_THE_ENVIRONMENT], [
|
||||
dnl Check whether $apr_ste_save_$1 is empty or
|
||||
dnl only whitespace. The verbatim "X" is token number 1,
|
||||
dnl the following whitespace will be ignored.
|
||||
set X $apr_ste_save_$1
|
||||
if test ${#} -eq 1; then
|
||||
$2$1="$$1"
|
||||
$1=
|
||||
else
|
||||
if test "x$apr_ste_save_$1" = "x$$1"; then
|
||||
$2$1=
|
||||
else
|
||||
$2$1=`echo "$$1" | sed -e "s%${apr_ste_save_$1}%%"`
|
||||
$1="$apr_ste_save_$1"
|
||||
fi
|
||||
fi
|
||||
if test "x$silent" != "xyes"; then
|
||||
echo " restoring $1 to \"$$1\""
|
||||
echo " setting $2$1 to \"$$2$1\""
|
||||
fi
|
||||
AC_SUBST($2$1)
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_SETIFNULL(variable, value)
|
||||
dnl
|
||||
dnl Set variable iff it's currently null
|
||||
dnl
|
||||
AC_DEFUN([APR_SETIFNULL], [
|
||||
if test -z "$$1"; then
|
||||
test "x$silent" != "xyes" && echo " setting $1 to \"$2\""
|
||||
$1="$2"
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_SETVAR(variable, value)
|
||||
dnl
|
||||
dnl Set variable no matter what
|
||||
dnl
|
||||
AC_DEFUN([APR_SETVAR], [
|
||||
test "x$silent" != "xyes" && echo " forcing $1 to \"$2\""
|
||||
$1="$2"
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_ADDTO(variable, value)
|
||||
dnl
|
||||
dnl Add value to variable
|
||||
dnl
|
||||
AC_DEFUN([APR_ADDTO], [
|
||||
if test "x$$1" = "x"; then
|
||||
test "x$silent" != "xyes" && echo " setting $1 to \"$2\""
|
||||
$1="$2"
|
||||
else
|
||||
apr_addto_bugger="$2"
|
||||
for i in $apr_addto_bugger; do
|
||||
apr_addto_duplicate="0"
|
||||
for j in $$1; do
|
||||
if test "x$i" = "x$j"; then
|
||||
apr_addto_duplicate="1"
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test $apr_addto_duplicate = "0"; then
|
||||
test "x$silent" != "xyes" && echo " adding \"$i\" to $1"
|
||||
$1="$$1 $i"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_REMOVEFROM(variable, value)
|
||||
dnl
|
||||
dnl Remove a value from a variable
|
||||
dnl
|
||||
AC_DEFUN([APR_REMOVEFROM], [
|
||||
if test "x$$1" = "x$2"; then
|
||||
test "x$silent" != "xyes" && echo " nulling $1"
|
||||
$1=""
|
||||
else
|
||||
apr_new_bugger=""
|
||||
apr_removed=0
|
||||
for i in $$1; do
|
||||
if test "x$i" != "x$2"; then
|
||||
apr_new_bugger="$apr_new_bugger $i"
|
||||
else
|
||||
apr_removed=1
|
||||
fi
|
||||
done
|
||||
if test $apr_removed = "1"; then
|
||||
test "x$silent" != "xyes" && echo " removed \"$2\" from $1"
|
||||
$1=$apr_new_bugger
|
||||
fi
|
||||
fi
|
||||
]) dnl
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_DEFINE_FILES( symbol, header_file [header_file ...] )
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_DEFINE_FILES], [
|
||||
AC_CACHE_CHECK([for $1 in $2],ac_cv_define_$1,[
|
||||
ac_cv_define_$1=no
|
||||
for curhdr in $2
|
||||
do
|
||||
AC_EGREP_CPP(YES_IS_DEFINED, [
|
||||
#include <$curhdr>
|
||||
#ifdef $1
|
||||
YES_IS_DEFINED
|
||||
#endif
|
||||
], ac_cv_define_$1=yes)
|
||||
done
|
||||
])
|
||||
if test "$ac_cv_define_$1" = "yes"; then
|
||||
AC_DEFINE(HAVE_$1, 1, [Define if $1 is defined])
|
||||
fi
|
||||
])
|
||||
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_DEFINE(symbol, header_file)
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_DEFINE], [
|
||||
AC_CACHE_CHECK([for $1 in $2],ac_cv_define_$1,[
|
||||
AC_EGREP_CPP(YES_IS_DEFINED, [
|
||||
#include <$2>
|
||||
#ifdef $1
|
||||
YES_IS_DEFINED
|
||||
#endif
|
||||
], ac_cv_define_$1=yes, ac_cv_define_$1=no)
|
||||
])
|
||||
if test "$ac_cv_define_$1" = "yes"; then
|
||||
AC_DEFINE(HAVE_$1, 1, [Define if $1 is defined in $2])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_APR_DEFINE( symbol )
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_APR_DEFINE], [
|
||||
apr_old_cppflags=$CPPFLAGS
|
||||
CPPFLAGS="$CPPFLAGS $INCLUDES"
|
||||
AC_EGREP_CPP(YES_IS_DEFINED, [
|
||||
#include <apr.h>
|
||||
#if $1
|
||||
YES_IS_DEFINED
|
||||
#endif
|
||||
], ac_cv_define_$1=yes, ac_cv_define_$1=no)
|
||||
CPPFLAGS=$apr_old_cppflags
|
||||
])
|
||||
|
||||
dnl APR_CHECK_FILE(filename); set ac_cv_file_filename to
|
||||
dnl "yes" if 'filename' is readable, else "no".
|
||||
dnl @deprecated! - use AC_CHECK_FILE instead
|
||||
AC_DEFUN([APR_CHECK_FILE], [
|
||||
dnl Pick a safe variable name
|
||||
define([apr_cvname], ac_cv_file_[]translit([$1], [./+-], [__p_]))
|
||||
AC_CACHE_CHECK([for $1], [apr_cvname],
|
||||
[if test -r $1; then
|
||||
apr_cvname=yes
|
||||
else
|
||||
apr_cvname=no
|
||||
fi])
|
||||
])
|
||||
|
||||
define(APR_IFALLYES,[dnl
|
||||
ac_rc=yes
|
||||
for ac_spec in $1; do
|
||||
ac_type=`echo "$ac_spec" | sed -e 's/:.*$//'`
|
||||
ac_item=`echo "$ac_spec" | sed -e 's/^.*://'`
|
||||
case $ac_type in
|
||||
header )
|
||||
ac_item=`echo "$ac_item" | sed 'y%./+-%__p_%'`
|
||||
ac_var="ac_cv_header_$ac_item"
|
||||
;;
|
||||
file )
|
||||
ac_item=`echo "$ac_item" | sed 'y%./+-%__p_%'`
|
||||
ac_var="ac_cv_file_$ac_item"
|
||||
;;
|
||||
func ) ac_var="ac_cv_func_$ac_item" ;;
|
||||
struct ) ac_var="ac_cv_struct_$ac_item" ;;
|
||||
define ) ac_var="ac_cv_define_$ac_item" ;;
|
||||
custom ) ac_var="$ac_item" ;;
|
||||
esac
|
||||
eval "ac_val=\$$ac_var"
|
||||
if test ".$ac_val" != .yes; then
|
||||
ac_rc=no
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test ".$ac_rc" = .yes; then
|
||||
:
|
||||
$2
|
||||
else
|
||||
:
|
||||
$3
|
||||
fi
|
||||
])
|
||||
|
||||
|
||||
define(APR_BEGIN_DECISION,[dnl
|
||||
ac_decision_item='$1'
|
||||
ac_decision_msg='FAILED'
|
||||
ac_decision=''
|
||||
])
|
||||
|
||||
|
||||
AC_DEFUN([APR_DECIDE],[dnl
|
||||
dnl Define the flag (or not) in apr_private.h via autoheader
|
||||
AH_TEMPLATE($1, [Define if $2 will be used])
|
||||
ac_decision='$1'
|
||||
ac_decision_msg='$2'
|
||||
ac_decision_$1=yes
|
||||
ac_decision_$1_msg='$2'
|
||||
])
|
||||
|
||||
|
||||
define(APR_DECISION_OVERRIDE,[dnl
|
||||
ac_decision=''
|
||||
for ac_item in $1; do
|
||||
eval "ac_decision_this=\$ac_decision_${ac_item}"
|
||||
if test ".$ac_decision_this" = .yes; then
|
||||
ac_decision=$ac_item
|
||||
eval "ac_decision_msg=\$ac_decision_${ac_item}_msg"
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
|
||||
define(APR_DECISION_FORCE,[dnl
|
||||
ac_decision="$1"
|
||||
eval "ac_decision_msg=\"\$ac_decision_${ac_decision}_msg\""
|
||||
])
|
||||
|
||||
|
||||
define(APR_END_DECISION,[dnl
|
||||
if test ".$ac_decision" = .; then
|
||||
echo "[$]0:Error: decision on $ac_decision_item failed" 1>&2
|
||||
exit 1
|
||||
else
|
||||
if test ".$ac_decision_msg" = .; then
|
||||
ac_decision_msg="$ac_decision"
|
||||
fi
|
||||
AC_DEFINE_UNQUOTED(${ac_decision_item})
|
||||
AC_MSG_RESULT([decision on $ac_decision_item... $ac_decision_msg])
|
||||
fi
|
||||
])
|
||||
|
||||
|
||||
dnl
|
||||
dnl APR_TRY_COMPILE_NO_WARNING(INCLUDES, FUNCTION-BODY,
|
||||
dnl [ACTIONS-IF-NO-WARNINGS], [ACTIONS-IF-WARNINGS])
|
||||
dnl
|
||||
dnl Tries a compile test with warnings activated so that the result
|
||||
dnl is false if the code doesn't compile cleanly. For compilers
|
||||
dnl where it is not known how to activate a "fail-on-error" mode,
|
||||
dnl it is undefined which of the sets of actions will be run.
|
||||
dnl
|
||||
AC_DEFUN([APR_TRY_COMPILE_NO_WARNING],
|
||||
[apr_save_CFLAGS=$CFLAGS
|
||||
CFLAGS="$CFLAGS $CFLAGS_WARN"
|
||||
if test "$ac_cv_prog_gcc" = "yes"; then
|
||||
CFLAGS="$CFLAGS -Werror"
|
||||
fi
|
||||
AC_COMPILE_IFELSE(
|
||||
[AC_LANG_SOURCE(
|
||||
[
|
||||
#ifndef PACKAGE_NAME
|
||||
#include "confdefs.h"
|
||||
#endif
|
||||
]
|
||||
[[$1]]
|
||||
[int main(int argc, const char *const *argv) {]
|
||||
[[$2]]
|
||||
[ return 0; }]
|
||||
)], [CFLAGS=$apr_save_CFLAGS
|
||||
$3], [CFLAGS=$apr_save_CFLAGS
|
||||
$4])
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_STRERROR_R_RC
|
||||
dnl
|
||||
dnl Decide which style of retcode is used by this system's
|
||||
dnl strerror_r(). It either returns int (0 for success, -1
|
||||
dnl for failure), or it returns a pointer to the error
|
||||
dnl string.
|
||||
dnl
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_STRERROR_R_RC], [
|
||||
AC_CACHE_CHECK([whether return code from strerror_r has type int],
|
||||
[ac_cv_strerror_r_rc_int],
|
||||
[AC_TRY_RUN([
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
int main(void)
|
||||
{
|
||||
char buf[1024];
|
||||
if (strerror_r(ERANGE, buf, sizeof buf) < 1) {
|
||||
exit(0);
|
||||
}
|
||||
else {
|
||||
exit(1);
|
||||
}
|
||||
}], [
|
||||
ac_cv_strerror_r_rc_int=yes ], [
|
||||
ac_cv_strerror_r_rc_int=no ], [
|
||||
ac_cv_strerror_r_rc_int=no ] ) ] )
|
||||
if test "x$ac_cv_strerror_r_rc_int" = xyes; then
|
||||
AC_DEFINE(STRERROR_R_RC_INT, 1, [Define if strerror returns int])
|
||||
fi
|
||||
] )
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_DIRENT_INODE
|
||||
dnl
|
||||
dnl Decide if d_fileno or d_ino are available in the dirent
|
||||
dnl structure on this platform. Single UNIX Spec says d_ino,
|
||||
dnl BSD uses d_fileno. Undef to find the real beast.
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_DIRENT_INODE], [
|
||||
AC_CACHE_CHECK([for inode member of struct dirent], apr_cv_dirent_inode, [
|
||||
apr_cv_dirent_inode=no
|
||||
AC_TRY_COMPILE([
|
||||
#include <sys/types.h>
|
||||
#include <dirent.h>
|
||||
],[
|
||||
#ifdef d_ino
|
||||
#undef d_ino
|
||||
#endif
|
||||
struct dirent de; de.d_fileno;
|
||||
], apr_cv_dirent_inode=d_fileno)
|
||||
if test "$apr_cv_dirent_inode" = "no"; then
|
||||
AC_TRY_COMPILE([
|
||||
#include <sys/types.h>
|
||||
#include <dirent.h>
|
||||
],[
|
||||
#ifdef d_fileno
|
||||
#undef d_fileno
|
||||
#endif
|
||||
struct dirent de; de.d_ino;
|
||||
], apr_cv_dirent_inode=d_ino)
|
||||
fi
|
||||
])
|
||||
if test "$apr_cv_dirent_inode" != "no"; then
|
||||
AC_DEFINE_UNQUOTED(DIRENT_INODE, $apr_cv_dirent_inode,
|
||||
[Define if struct dirent has an inode member])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_DIRENT_TYPE
|
||||
dnl
|
||||
dnl Decide if d_type is available in the dirent structure
|
||||
dnl on this platform. Not part of the Single UNIX Spec.
|
||||
dnl Note that this is worthless without DT_xxx macros, so
|
||||
dnl look for one while we are at it.
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_DIRENT_TYPE], [
|
||||
AC_CACHE_CHECK([for file type member of struct dirent], apr_cv_dirent_type,[
|
||||
apr_cv_dirent_type=no
|
||||
AC_TRY_COMPILE([
|
||||
#include <sys/types.h>
|
||||
#include <dirent.h>
|
||||
],[
|
||||
struct dirent de; de.d_type = DT_REG;
|
||||
], apr_cv_dirent_type=d_type)
|
||||
])
|
||||
if test "$apr_cv_dirent_type" != "no"; then
|
||||
AC_DEFINE_UNQUOTED(DIRENT_TYPE, $apr_cv_dirent_type,
|
||||
[Define if struct dirent has a d_type member])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl the following is a newline, a space, a tab, and a backslash (the
|
||||
dnl backslash is used by the shell to skip newlines, but m4 sees it;
|
||||
dnl treat it like whitespace).
|
||||
dnl WARNING: don't reindent these lines, or the space/tab will be lost!
|
||||
define([apr_whitespace],[
|
||||
\])
|
||||
|
||||
dnl
|
||||
dnl APR_COMMA_ARGS(ARG1 ...)
|
||||
dnl convert the whitespace-separated arguments into comman-separated
|
||||
dnl arguments.
|
||||
dnl
|
||||
dnl APR_FOREACH(CODE-BLOCK, ARG1, ARG2, ...)
|
||||
dnl subsitute CODE-BLOCK for each ARG[i]. "eachval" will be set to ARG[i]
|
||||
dnl within each iteration.
|
||||
dnl
|
||||
changequote({,})
|
||||
define({APR_COMMA_ARGS},{patsubst([$}{1],[[}apr_whitespace{]+],[,])})
|
||||
define({APR_FOREACH},
|
||||
{ifelse($}{2,,,
|
||||
[define([eachval],
|
||||
$}{2)$}{1[]APR_FOREACH([$}{1],
|
||||
builtin([shift],
|
||||
builtin([shift], $}{@)))])})
|
||||
changequote([,])
|
||||
|
||||
dnl APR_FLAG_HEADERS(HEADER-FILE ... [, FLAG-TO-SET ] [, "yes" ])
|
||||
dnl we set FLAG-TO-SET to 1 if we find HEADER-FILE, otherwise we set to 0
|
||||
dnl if FLAG-TO-SET is null, we automagically determine it's name
|
||||
dnl by changing all "/" to "_" in the HEADER-FILE and dropping
|
||||
dnl all "." and "-" chars. If the 3rd parameter is "yes" then instead of
|
||||
dnl setting to 1 or 0, we set FLAG-TO-SET to yes or no.
|
||||
dnl
|
||||
AC_DEFUN([APR_FLAG_HEADERS], [
|
||||
AC_CHECK_HEADERS($1)
|
||||
for aprt_i in $1
|
||||
do
|
||||
ac_safe=`echo "$aprt_i" | sed 'y%./+-%__p_%'`
|
||||
aprt_2=`echo "$aprt_i" | sed -e 's%/%_%g' -e 's/\.//g' -e 's/-//g'`
|
||||
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
|
||||
eval "ifelse($2,,$aprt_2,$2)=ifelse($3,yes,yes,1)"
|
||||
else
|
||||
eval "ifelse($2,,$aprt_2,$2)=ifelse($3,yes,no,0)"
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
dnl APR_FLAG_FUNCS(FUNC ... [, FLAG-TO-SET] [, "yes" ])
|
||||
dnl if FLAG-TO-SET is null, we automagically determine it's name
|
||||
dnl prepending "have_" to the function name in FUNC, otherwise
|
||||
dnl we use what's provided as FLAG-TO-SET. If the 3rd parameter
|
||||
dnl is "yes" then instead of setting to 1 or 0, we set FLAG-TO-SET
|
||||
dnl to yes or no.
|
||||
dnl
|
||||
AC_DEFUN([APR_FLAG_FUNCS], [
|
||||
AC_CHECK_FUNCS($1)
|
||||
for aprt_j in $1
|
||||
do
|
||||
aprt_3="have_$aprt_j"
|
||||
if eval "test \"`echo '$ac_cv_func_'$aprt_j`\" = yes"; then
|
||||
eval "ifelse($2,,$aprt_3,$2)=ifelse($3,yes,yes,1)"
|
||||
else
|
||||
eval "ifelse($2,,$aprt_3,$2)=ifelse($3,yes,no,0)"
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
dnl Iteratively interpolate the contents of the second argument
|
||||
dnl until interpolation offers no new result. Then assign the
|
||||
dnl final result to $1.
|
||||
dnl
|
||||
dnl Example:
|
||||
dnl
|
||||
dnl foo=1
|
||||
dnl bar='${foo}/2'
|
||||
dnl baz='${bar}/3'
|
||||
dnl APR_EXPAND_VAR(fraz, $baz)
|
||||
dnl $fraz is now "1/2/3"
|
||||
dnl
|
||||
AC_DEFUN([APR_EXPAND_VAR], [
|
||||
ap_last=
|
||||
ap_cur="$2"
|
||||
while test "x${ap_cur}" != "x${ap_last}";
|
||||
do
|
||||
ap_last="${ap_cur}"
|
||||
ap_cur=`eval "echo ${ap_cur}"`
|
||||
done
|
||||
$1="${ap_cur}"
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl Removes the value of $3 from the string in $2, strips of any leading
|
||||
dnl slashes, and returns the value in $1.
|
||||
dnl
|
||||
dnl Example:
|
||||
dnl orig_path="${prefix}/bar"
|
||||
dnl APR_PATH_RELATIVE(final_path, $orig_path, $prefix)
|
||||
dnl $final_path now contains "bar"
|
||||
AC_DEFUN([APR_PATH_RELATIVE], [
|
||||
ap_stripped=`echo $2 | sed -e "s#^$3##"`
|
||||
# check if the stripping was successful
|
||||
if test "x$2" != "x${ap_stripped}"; then
|
||||
# it was, so strip of any leading slashes
|
||||
$1="`echo ${ap_stripped} | sed -e 's#^/*##'`"
|
||||
else
|
||||
# it wasn't so return the original
|
||||
$1="$2"
|
||||
fi
|
||||
])
|
||||
|
||||
dnl APR_HELP_STRING(LHS, RHS)
|
||||
dnl Autoconf 2.50 can not handle substr correctly. It does have
|
||||
dnl AC_HELP_STRING, so let's try to call it if we can.
|
||||
dnl Note: this define must be on one line so that it can be properly returned
|
||||
dnl as the help string. When using this macro with a multi-line RHS, ensure
|
||||
dnl that you surround the macro invocation with []s
|
||||
AC_DEFUN([APR_HELP_STRING], [ifelse(regexp(AC_ACVERSION, 2\.1), -1, AC_HELP_STRING([$1],[$2]),[ ][$1] substr([ ],len($1))[$2])])
|
||||
|
||||
dnl
|
||||
dnl APR_LAYOUT(configlayout, layoutname [, extravars])
|
||||
dnl
|
||||
AC_DEFUN([APR_LAYOUT], [
|
||||
if test ! -f $srcdir/config.layout; then
|
||||
echo "** Error: Layout file $srcdir/config.layout not found"
|
||||
echo "** Error: Cannot use undefined layout '$LAYOUT'"
|
||||
exit 1
|
||||
fi
|
||||
# Catch layout names including a slash which will otherwise
|
||||
# confuse the heck out of the sed script.
|
||||
case $2 in
|
||||
*/*)
|
||||
echo "** Error: $2 is not a valid layout name"
|
||||
exit 1 ;;
|
||||
esac
|
||||
pldconf=./config.pld
|
||||
changequote({,})
|
||||
sed -e "1s/[ ]*<[lL]ayout[ ]*$2[ ]*>[ ]*//;1t" \
|
||||
-e "1,/[ ]*<[lL]ayout[ ]*$2[ ]*>[ ]*/d" \
|
||||
-e '/[ ]*<\/Layout>[ ]*/,$d' \
|
||||
-e "s/^[ ]*//g" \
|
||||
-e "s/:[ ]*/=\'/g" \
|
||||
-e "s/[ ]*$/'/g" \
|
||||
$1 > $pldconf
|
||||
layout_name=$2
|
||||
if test ! -s $pldconf; then
|
||||
echo "** Error: unable to find layout $layout_name"
|
||||
exit 1
|
||||
fi
|
||||
. $pldconf
|
||||
rm $pldconf
|
||||
for var in prefix exec_prefix bindir sbindir libexecdir mandir \
|
||||
sysconfdir datadir includedir localstatedir runtimedir \
|
||||
logfiledir libdir installbuilddir libsuffix $3; do
|
||||
eval "val=\"\$$var\""
|
||||
case $val in
|
||||
*+)
|
||||
val=`echo $val | sed -e 's;\+$;;'`
|
||||
eval "$var=\"\$val\""
|
||||
autosuffix=yes
|
||||
;;
|
||||
*)
|
||||
autosuffix=no
|
||||
;;
|
||||
esac
|
||||
val=`echo $val | sed -e 's:\(.\)/*$:\1:'`
|
||||
val=`echo $val | sed -e 's:[\$]\([a-z_]*\):${\1}:g'`
|
||||
if test "$autosuffix" = "yes"; then
|
||||
if echo $val | grep apache >/dev/null; then
|
||||
addtarget=no
|
||||
else
|
||||
addtarget=yes
|
||||
fi
|
||||
if test "$addtarget" = "yes"; then
|
||||
val="$val/apache2"
|
||||
fi
|
||||
fi
|
||||
eval "$var='$val'"
|
||||
done
|
||||
changequote([,])
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_ENABLE_LAYOUT(default layout name [, extra vars])
|
||||
dnl
|
||||
AC_DEFUN([APR_ENABLE_LAYOUT], [
|
||||
AC_ARG_ENABLE(layout,
|
||||
[ --enable-layout=LAYOUT],[
|
||||
LAYOUT=$enableval
|
||||
])
|
||||
|
||||
if test -z "$LAYOUT"; then
|
||||
LAYOUT="$1"
|
||||
fi
|
||||
APR_LAYOUT($srcdir/config.layout, $LAYOUT, $2)
|
||||
|
||||
AC_MSG_CHECKING(for chosen layout)
|
||||
AC_MSG_RESULT($layout_name)
|
||||
])
|
||||
|
||||
|
||||
dnl
|
||||
dnl APR_PARSE_ARGUMENTS
|
||||
dnl a reimplementation of autoconf's argument parser,
|
||||
dnl used here to allow us to co-exist layouts and argument based
|
||||
dnl set ups.
|
||||
AC_DEFUN([APR_PARSE_ARGUMENTS], [
|
||||
ac_prev=
|
||||
# Retrieve the command-line arguments. The eval is needed because
|
||||
# the arguments are quoted to preserve accuracy.
|
||||
eval "set x $ac_configure_args"
|
||||
shift
|
||||
for ac_option
|
||||
do
|
||||
# If the previous option needs an argument, assign it.
|
||||
if test -n "$ac_prev"; then
|
||||
eval "$ac_prev=\$ac_option"
|
||||
ac_prev=
|
||||
continue
|
||||
fi
|
||||
|
||||
ac_optarg=`expr "x$ac_option" : 'x[[^=]]*=\(.*\)'`
|
||||
|
||||
case $ac_option in
|
||||
|
||||
-bindir | --bindir | --bindi | --bind | --bin | --bi)
|
||||
ac_prev=bindir ;;
|
||||
-bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
|
||||
bindir="$ac_optarg" ;;
|
||||
|
||||
-datadir | --datadir | --datadi | --datad | --data | --dat | --da)
|
||||
ac_prev=datadir ;;
|
||||
-datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
|
||||
| --da=*)
|
||||
datadir="$ac_optarg" ;;
|
||||
|
||||
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
|
||||
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
|
||||
| --exec | --exe | --ex)
|
||||
ac_prev=exec_prefix ;;
|
||||
-exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
|
||||
| --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
|
||||
| --exec=* | --exe=* | --ex=*)
|
||||
exec_prefix="$ac_optarg" ;;
|
||||
|
||||
-includedir | --includedir | --includedi | --included | --include \
|
||||
| --includ | --inclu | --incl | --inc)
|
||||
ac_prev=includedir ;;
|
||||
-includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
|
||||
| --includ=* | --inclu=* | --incl=* | --inc=*)
|
||||
includedir="$ac_optarg" ;;
|
||||
|
||||
-infodir | --infodir | --infodi | --infod | --info | --inf)
|
||||
ac_prev=infodir ;;
|
||||
-infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
|
||||
infodir="$ac_optarg" ;;
|
||||
|
||||
-libdir | --libdir | --libdi | --libd)
|
||||
ac_prev=libdir ;;
|
||||
-libdir=* | --libdir=* | --libdi=* | --libd=*)
|
||||
libdir="$ac_optarg" ;;
|
||||
|
||||
-libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
|
||||
| --libexe | --libex | --libe)
|
||||
ac_prev=libexecdir ;;
|
||||
-libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
|
||||
| --libexe=* | --libex=* | --libe=*)
|
||||
libexecdir="$ac_optarg" ;;
|
||||
|
||||
-localstatedir | --localstatedir | --localstatedi | --localstated \
|
||||
| --localstate | --localstat | --localsta | --localst \
|
||||
| --locals | --local | --loca | --loc | --lo)
|
||||
ac_prev=localstatedir ;;
|
||||
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
|
||||
| --localstate=* | --localstat=* | --localsta=* | --localst=* \
|
||||
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
|
||||
localstatedir="$ac_optarg" ;;
|
||||
|
||||
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
|
||||
ac_prev=mandir ;;
|
||||
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
|
||||
mandir="$ac_optarg" ;;
|
||||
|
||||
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
|
||||
ac_prev=prefix ;;
|
||||
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
|
||||
prefix="$ac_optarg" ;;
|
||||
|
||||
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
|
||||
ac_prev=sbindir ;;
|
||||
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
|
||||
| --sbi=* | --sb=*)
|
||||
sbindir="$ac_optarg" ;;
|
||||
|
||||
-sharedstatedir | --sharedstatedir | --sharedstatedi \
|
||||
| --sharedstated | --sharedstate | --sharedstat | --sharedsta \
|
||||
| --sharedst | --shareds | --shared | --share | --shar \
|
||||
| --sha | --sh)
|
||||
ac_prev=sharedstatedir ;;
|
||||
-sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
|
||||
| --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
|
||||
| --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
|
||||
| --sha=* | --sh=*)
|
||||
sharedstatedir="$ac_optarg" ;;
|
||||
|
||||
-sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
|
||||
| --syscon | --sysco | --sysc | --sys | --sy)
|
||||
ac_prev=sysconfdir ;;
|
||||
-sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
|
||||
| --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
|
||||
sysconfdir="$ac_optarg" ;;
|
||||
|
||||
esac
|
||||
done
|
||||
|
||||
# Be sure to have absolute paths.
|
||||
for ac_var in exec_prefix prefix
|
||||
do
|
||||
eval ac_val=$`echo $ac_var`
|
||||
case $ac_val in
|
||||
[[\\/$]]* | ?:[[\\/]]* | NONE | '' ) ;;
|
||||
*) AC_MSG_ERROR([expected an absolute path for --$ac_var: $ac_val]);;
|
||||
esac
|
||||
done
|
||||
|
||||
])dnl
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_DEPEND
|
||||
dnl
|
||||
dnl Determine what program we can use to generate .deps-style dependencies
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_DEPEND], [
|
||||
dnl Try to determine what depend program we can use
|
||||
dnl All GCC-variants should have -MM.
|
||||
dnl If not, then we can check on those, too.
|
||||
if test "$GCC" = "yes"; then
|
||||
MKDEP='$(CC) -MM'
|
||||
else
|
||||
rm -f conftest.c
|
||||
dnl <sys/types.h> should be available everywhere!
|
||||
cat > conftest.c <<EOF
|
||||
#include <sys/types.h>
|
||||
int main(int argc, const char *argv[]) { return 0; }
|
||||
EOF
|
||||
MKDEP="true"
|
||||
for i in "$CC -MM" "$CC -M" "$CPP -MM" "$CPP -M" "cpp -M"; do
|
||||
AC_MSG_CHECKING([if $i can create proper make dependencies])
|
||||
if $i conftest.c 2>/dev/null | grep 'conftest.o: conftest.c' >/dev/null; then
|
||||
MKDEP=$i
|
||||
AC_MSG_RESULT(yes)
|
||||
break;
|
||||
fi
|
||||
AC_MSG_RESULT(no)
|
||||
done
|
||||
rm -f conftest.c
|
||||
fi
|
||||
|
||||
AC_SUBST(MKDEP)
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_TYPES_FMT_COMPATIBLE(TYPE-1, TYPE-2, FMT-TAG,
|
||||
dnl [ACTION-IF-TRUE], [ACTION-IF-FALSE])
|
||||
dnl
|
||||
dnl Try to determine whether two types are the same and accept the given
|
||||
dnl printf formatter (bare token, e.g. literal d, ld, etc).
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_TYPES_FMT_COMPATIBLE], [
|
||||
define([apr_cvname], apr_cv_typematch_[]translit([$1], [ ], [_])_[]translit([$2], [ ], [_])_[][$3])
|
||||
AC_CACHE_CHECK([whether $1 and $2 use fmt %$3], apr_cvname, [
|
||||
APR_TRY_COMPILE_NO_WARNING([#include <sys/types.h>
|
||||
#include <stdio.h>
|
||||
#ifdef HAVE_STDINT_H
|
||||
#include <stdint.h>
|
||||
#endif
|
||||
], [
|
||||
$1 chk1, *ptr1;
|
||||
$2 chk2, *ptr2 = &chk1;
|
||||
ptr1 = &chk2;
|
||||
*ptr1 = *ptr2 = 0;
|
||||
printf("%$3 %$3", chk1, chk2);
|
||||
], [apr_cvname=yes], [apr_cvname=no])])
|
||||
if test "$apr_cvname" = "yes"; then
|
||||
:
|
||||
$4
|
||||
else
|
||||
:
|
||||
$5
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl APR_CHECK_TYPES_COMPATIBLE(TYPE-1, TYPE-2, [ACTION-IF-TRUE])
|
||||
dnl
|
||||
dnl Try to determine whether two types are the same. Only works
|
||||
dnl for gcc and icc.
|
||||
dnl
|
||||
dnl @deprecated @see APR_CHECK_TYPES_FMT_COMPATIBLE
|
||||
dnl
|
||||
AC_DEFUN([APR_CHECK_TYPES_COMPATIBLE], [
|
||||
define([apr_cvname], apr_cv_typematch_[]translit([$1], [ ], [_])_[]translit([$2], [ ], [_]))
|
||||
AC_CACHE_CHECK([whether $1 and $2 are the same], apr_cvname, [
|
||||
AC_TRY_COMPILE(AC_INCLUDES_DEFAULT, [
|
||||
int foo[0 - !__builtin_types_compatible_p($1, $2)];
|
||||
], [apr_cvname=yes
|
||||
$3], [apr_cvname=no])])
|
||||
])
|
206
build/binbuild.sh
Executable file
206
build/binbuild.sh
Executable file
|
@ -0,0 +1,206 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# binbuild.sh - Builds an Apache binary distribution.
|
||||
# Initially written by Lars Eilebrecht <lars apache.org>.
|
||||
|
||||
OS=`./build/config.guess`
|
||||
PRINTPATH="build/PrintPath"
|
||||
APFULLDIR=`pwd`
|
||||
BUILD_DIR="$APFULLDIR/bindist"
|
||||
DEFAULT_DIR="/usr/local/apache2"
|
||||
APDIR="$APFULLDIR"
|
||||
APDIR=`basename $APDIR`
|
||||
CONFIGPARAM="--enable-layout=Apache --prefix=$BUILD_DIR --enable-mods-shared=most --with-expat=$APFULLDIR/srclib/apr-util/xml/expat --enable-static-support"
|
||||
VER=`echo $APDIR | sed s/httpd-//`
|
||||
TAR="`$PRINTPATH tar`"
|
||||
GZIP="`$PRINTPATH gzip`"
|
||||
COMPRESS="`$PRINTPATH compress`"
|
||||
MD5="`$PRINTPATH md5`"
|
||||
if [ x$MD5 = x ]; then
|
||||
OPENSSL="`$PRINTPATH openssl`"
|
||||
if [ x$OPENSSL != x ]; then
|
||||
MD5="$OPENSSL md5"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ x$1 != x ]; then
|
||||
USER=$1
|
||||
else
|
||||
USER="`build/buildinfo.sh -n %u@%h%d`"
|
||||
fi
|
||||
|
||||
if [ ! -f ./ABOUT_APACHE ]; then
|
||||
echo "ERROR: The current directory contains no valid Apache distribution."
|
||||
echo "Please change the directory to the top level directory of a freshly"
|
||||
echo "unpacked Apache 2.0 source distribution and re-execute the script"
|
||||
echo "'./build/binbuild.sh'."
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
if [ -d ./CVS ]; then
|
||||
echo "ERROR: The current directory is a CVS checkout of Apache."
|
||||
echo "Only a standard Apache 2.0 source distribution should be used to"
|
||||
echo "create a binary distribution."
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
echo "Building Apache $VER binary distribution..."
|
||||
echo "Platform is \"$OS\"..."
|
||||
|
||||
( echo "Build log for Apache binary distribution" && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
./configure $CONFIGPARAM && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
make clean && \
|
||||
rm -rf bindist install-bindist.sh *.bindist
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
make && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
make install root="bindist/" && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
make clean && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
echo "[EOF]" \
|
||||
) 2>&1 | tee build.log
|
||||
|
||||
if [ ! -f ./bindist/bin/httpd ]; then
|
||||
echo "ERROR: Failed to build Apache. See \"build.log\" for details."
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
echo "Binary image successfully created..."
|
||||
|
||||
./bindist/bin/httpd -v
|
||||
|
||||
echo "Creating supplementary files..."
|
||||
|
||||
( echo " " && \
|
||||
echo "Apache $VER binary distribution" && \
|
||||
echo "================================" && \
|
||||
echo " " && \
|
||||
echo "This binary distribution is usable on a \"$OS\"" && \
|
||||
echo "system and was built by \"$USER\"." && \
|
||||
echo "" && \
|
||||
echo "The distribution contains all standard Apache modules as shared" && \
|
||||
echo "objects. This allows you to enable or disable particular modules" && \
|
||||
echo "with the LoadModule/AddModule directives in the configuration file" && \
|
||||
echo "without the need to re-compile Apache." && \
|
||||
echo "" && \
|
||||
echo "See \"INSTALL.bindist\" on how to install the distribution." && \
|
||||
echo " " && \
|
||||
echo "NOTE: Please do not send support-related mails to the address mentioned" && \
|
||||
echo " above or to any member of the Apache Group! Support questions" && \
|
||||
echo " should be directed to the forums mentioned at" && \
|
||||
echo " http://httpd.apache.org/lists.html#http-users" && \
|
||||
echo " where some of the Apache team lurk, in the company of many other" && \
|
||||
echo " Apache gurus who should be able to help." && \
|
||||
echo " If you think you found a bug in Apache or have a suggestion please" && \
|
||||
echo " visit the bug report page at http://httpd.apache.org/bug_report.html" && \
|
||||
echo " " && \
|
||||
echo "----------------------------------------------------------------------" && \
|
||||
./bindist/bin/httpd -V && \
|
||||
echo "----------------------------------------------------------------------" \
|
||||
) > README.bindist
|
||||
cp README.bindist ../httpd-$VER-$OS.README
|
||||
|
||||
( echo " " && \
|
||||
echo "Apache $VER binary installation" && \
|
||||
echo "================================" && \
|
||||
echo " " && \
|
||||
echo "To install this binary distribution you have to execute the installation" && \
|
||||
echo "script \"install-bindist.sh\" in the top-level directory of the distribution." && \
|
||||
echo " " && \
|
||||
echo "The script takes the ServerRoot directory into which you want to install" && \
|
||||
echo "Apache as an option. If you omit the option the default path" && \
|
||||
echo "\"$DEFAULT_DIR\" is used." && \
|
||||
echo "Make sure you have write permissions in the target directory, e.g. switch" && \
|
||||
echo "to user \"root\" before you execute the script." && \
|
||||
echo " " && \
|
||||
echo "See \"README.bindist\" for further details about this distribution." && \
|
||||
echo " " && \
|
||||
echo "Please note that this distribution includes the complete Apache source code." && \
|
||||
echo "Therefore you may compile Apache yourself at any time if you have a compiler" && \
|
||||
echo "installation on your system." && \
|
||||
echo "See \"INSTALL\" for details on how to accomplish this." && \
|
||||
echo " " \
|
||||
) > INSTALL.bindist
|
||||
|
||||
sed -e "s%\@default_dir\@%$DEFAULT_DIR%" \
|
||||
-e "s%\@ver\@%$VER%" \
|
||||
-e "s%\@os\@%$OS%" \
|
||||
build/install-bindist.sh.in > install-bindist.sh
|
||||
|
||||
chmod 755 install-bindist.sh
|
||||
|
||||
sed -e "s%$BUILD_DIR%$DEFAULT_DIR%" \
|
||||
-e "s%^ServerAdmin.*%ServerAdmin you@your.address%" \
|
||||
-e "s%#ServerName.*%#ServerName localhost%" \
|
||||
bindist/conf/httpd-std.conf > bindist/conf/httpd.conf
|
||||
cp bindist/conf/httpd.conf bindist/conf/httpd-std.conf
|
||||
|
||||
for one_file in apachectl envvars envvars-std; do
|
||||
sed -e "s%$BUILD_DIR%$DEFAULT_DIR%" \
|
||||
bindist/bin/$one_file > bindist/bin/$one_file.tmp
|
||||
mv bindist/bin/$one_file.tmp bindist/bin/$one_file
|
||||
done
|
||||
|
||||
echo "Creating distribution archive and readme file..."
|
||||
|
||||
if [ ".`grep -i error build.log > /dev/null`" != . ]; then
|
||||
echo "ERROR: Failed to build Apache. See \"build.log\" for details."
|
||||
exit 1;
|
||||
else
|
||||
if [ "x$TAR" != "x" ]; then
|
||||
case "x$OS" in
|
||||
x*os390*) $TAR -cfU ../httpd-$VER-$OS.tar -C .. httpd-$VER;;
|
||||
*) (cd .. && $TAR -cf httpd-$VER-$OS.tar httpd-$VER);;
|
||||
esac
|
||||
if [ "x$GZIP" != "x" ]; then
|
||||
$GZIP -9 ../httpd-$VER-$OS.tar
|
||||
ARCHIVE=../httpd-$VER-$OS.tar.gz
|
||||
elif [ "x$COMPRESS" != "x" ]; then
|
||||
$COMPRESS ../httpd-$VER-$OS.tar
|
||||
ARCHIVE=../httpd-$VER-$OS.tar.Z
|
||||
else
|
||||
echo "WARNING: Could not find a 'gzip' program!"
|
||||
echo " tar archive is not compressed."
|
||||
ARCHIVE=../httpd-$VER-$OS.tar
|
||||
fi
|
||||
else
|
||||
echo "ERROR: Could not find a 'tar' program!"
|
||||
echo " Please execute the following commands manually:"
|
||||
echo " tar -cf ../httpd-$VER-$OS.tar ."
|
||||
echo " gzip -9 ../httpd-$VER-$OS.tar"
|
||||
fi
|
||||
|
||||
if [ "x$MD5" != "x" ]; then
|
||||
$MD5 $ARCHIVE > $ARCHIVE.md5
|
||||
fi
|
||||
|
||||
if [ -f $ARCHIVE ] && [ -f ../httpd-$VER-$OS.README ]; then
|
||||
echo "Ready."
|
||||
echo "You can find the binary archive ($ARCHIVE)"
|
||||
echo "and the readme file (httpd-$VER-$OS.README) in the"
|
||||
echo "parent directory."
|
||||
exit 0;
|
||||
else
|
||||
echo "ERROR: Archive or README is missing."
|
||||
exit 1;
|
||||
fi
|
||||
fi
|
34
build/bsd_makefile
Executable file
34
build/bsd_makefile
Executable file
|
@ -0,0 +1,34 @@
|
|||
#! /bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
# cwd must be top_srcdir
|
||||
test -f build/bsd_makefile || exit 2
|
||||
|
||||
test -f bsd_converted && exit 0
|
||||
|
||||
tmpfile=`mktemp /tmp/bsd_makefile.XXXXXX 2>/dev/null` || tmpfile="tmp.$$"
|
||||
for i in build/*.mk; do
|
||||
sed 's/^include \(.*\)/.include "\1"/' $i >$tmpfile \
|
||||
&& cp $tmpfile $i
|
||||
done
|
||||
rm -f $tmpfile
|
||||
|
||||
touch bsd_converted
|
||||
exit 0
|
82
build/build-modules-c.awk
Normal file
82
build/build-modules-c.awk
Normal file
|
@ -0,0 +1,82 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
BEGIN {
|
||||
RS = " "
|
||||
# the core module must come first
|
||||
modules[n++] = "core"
|
||||
pmodules[pn++] = "core"
|
||||
}
|
||||
{
|
||||
modules[n] = $1;
|
||||
pmodules[pn] = $1;
|
||||
gsub("\n","",modules[n]);
|
||||
gsub("\n","",pmodules[pn]);
|
||||
++n;
|
||||
++pn;
|
||||
}
|
||||
END {
|
||||
print "/*"
|
||||
print " * modules.c --- automatically generated by Apache"
|
||||
print " * configuration script. DO NOT HAND EDIT!!!!!"
|
||||
print " */"
|
||||
print ""
|
||||
print "#include \"ap_config.h\""
|
||||
print "#include \"httpd.h\""
|
||||
print "#include \"http_config.h\""
|
||||
print ""
|
||||
for (i = 0; i < pn; ++i) {
|
||||
printf ("extern module %s_module;\n", pmodules[i])
|
||||
}
|
||||
print ""
|
||||
print "/*"
|
||||
print " * Modules which implicitly form the"
|
||||
print " * list of activated modules on startup,"
|
||||
print " * i.e. these are the modules which are"
|
||||
print " * initially linked into the Apache processing"
|
||||
print " * [extendable under run-time via AddModule]"
|
||||
print " */"
|
||||
print "module *ap_prelinked_modules[] = {"
|
||||
for (i = 0 ; i < n; ++i) {
|
||||
printf " &%s_module,\n", modules[i]
|
||||
}
|
||||
print " NULL"
|
||||
print "};"
|
||||
print ""
|
||||
print "/*"
|
||||
print " * We need the symbols as strings for <IfModule> containers"
|
||||
print " */"
|
||||
print ""
|
||||
print "ap_module_symbol_t ap_prelinked_module_symbols[] = {"
|
||||
for (i = 0; i < n; ++i) {
|
||||
printf (" {\"%s_module\", &%s_module},\n", modules[i], modules[i])
|
||||
}
|
||||
print " {NULL, NULL}"
|
||||
print "};"
|
||||
print ""
|
||||
print "/*"
|
||||
print " * Modules which initially form the"
|
||||
print " * list of available modules on startup,"
|
||||
print " * i.e. these are the modules which are"
|
||||
print " * initially loaded into the Apache process"
|
||||
print " * [extendable under run-time via LoadModule]"
|
||||
print " */"
|
||||
print "module *ap_preloaded_modules[] = {"
|
||||
for (i = 0; i < pn; ++i) {
|
||||
printf " &%s_module,\n", pmodules[i]
|
||||
}
|
||||
print " NULL"
|
||||
print "};"
|
||||
print ""
|
||||
}
|
171
build/buildinfo.sh
Executable file
171
build/buildinfo.sh
Executable file
|
@ -0,0 +1,171 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# buildinfo.sh -- Determine Build Information
|
||||
# Initially written by Ralf S. Engelschall <rse@apache.org>
|
||||
# for the Apache's Autoconf-style Interface (APACI)
|
||||
|
||||
#
|
||||
# argument line handling
|
||||
#
|
||||
error=no
|
||||
if [ $# -ne 1 -a $# -ne 2 ]; then
|
||||
error=yes
|
||||
fi
|
||||
if [ $# -eq 2 -a "x$1" != "x-n" ]; then
|
||||
error=yes
|
||||
fi
|
||||
if [ "x$error" = "xyes" ]; then
|
||||
echo "$0:Error: invalid argument line"
|
||||
echo "$0:Usage: $0 [-n] <format-string>"
|
||||
echo "Where <format-string> can contain:"
|
||||
echo " %u ...... substituted by determined username (foo)"
|
||||
echo " %h ...... substituted by determined hostname (bar)"
|
||||
echo " %d ...... substituted by determined domainname (.com)"
|
||||
echo " %D ...... substituted by determined day (DD)"
|
||||
echo " %M ...... substituted by determined month (MM)"
|
||||
echo " %Y ...... substituted by determined year (YYYYY)"
|
||||
echo " %m ...... substituted by determined monthname (Jan)"
|
||||
exit 1
|
||||
fi
|
||||
if [ $# -eq 2 ]; then
|
||||
newline=no
|
||||
format_string="$2"
|
||||
else
|
||||
newline=yes
|
||||
format_string="$1"
|
||||
fi
|
||||
|
||||
#
|
||||
# initialization
|
||||
#
|
||||
username=''
|
||||
hostname=''
|
||||
domainname=''
|
||||
time_day=''
|
||||
time_month=''
|
||||
time_year=''
|
||||
time_monthname=''
|
||||
|
||||
#
|
||||
# determine username
|
||||
#
|
||||
username="$LOGNAME"
|
||||
if [ "x$username" = "x" ]; then
|
||||
username="$USER"
|
||||
if [ "x$username" = "x" ]; then
|
||||
username="`(whoami) 2>/dev/null |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$username" = "x" ]; then
|
||||
username="`(who am i) 2>/dev/null |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$username" = "x" ]; then
|
||||
username='unknown'
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
#
|
||||
# determine hostname and domainname
|
||||
#
|
||||
hostname="`(uname -n) 2>/dev/null |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$hostname" = "x" ]; then
|
||||
hostname="`(hostname) 2>/dev/null |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$hostname" = "x" ]; then
|
||||
hostname='unknown'
|
||||
fi
|
||||
fi
|
||||
case $hostname in
|
||||
*.* )
|
||||
domainname=".`echo $hostname | cut -d. -f2-`"
|
||||
hostname="`echo $hostname | cut -d. -f1`"
|
||||
;;
|
||||
esac
|
||||
if [ "x$domainname" = "x" ]; then
|
||||
if [ -f /etc/resolv.conf ]; then
|
||||
domainname="`egrep '^[ ]*domain' /etc/resolv.conf | head -1 |\
|
||||
sed -e 's/.*domain//' \
|
||||
-e 's/^[ ]*//' -e 's/^ *//' -e 's/^ *//' \
|
||||
-e 's/^\.//' -e 's/^/./' |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$domainname" = "x" ]; then
|
||||
domainname="`egrep '^[ ]*search' /etc/resolv.conf | head -1 |\
|
||||
sed -e 's/.*search//' \
|
||||
-e 's/^[ ]*//' -e 's/^ *//' -e 's/^ *//' \
|
||||
-e 's/ .*//' -e 's/ .*//' \
|
||||
-e 's/^\.//' -e 's/^/./' |\
|
||||
awk '{ printf("%s", $1); }'`"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
#
|
||||
# determine current time
|
||||
#
|
||||
time_day="`date '+%d' | awk '{ printf("%s", $1); }'`"
|
||||
time_month="`date '+%m' | awk '{ printf("%s", $1); }'`"
|
||||
time_year="`date '+%Y' 2>/dev/null | awk '{ printf("%s", $1); }'`"
|
||||
if [ "x$time_year" = "x" ]; then
|
||||
time_year="`date '+%y' | awk '{ printf("%s", $1); }'`"
|
||||
case $time_year in
|
||||
[5-9][0-9]) time_year="19$time_year" ;;
|
||||
[0-4][0-9]) time_year="20$time_year" ;;
|
||||
esac
|
||||
fi
|
||||
case $time_month in
|
||||
1|01) time_monthname='Jan' ;;
|
||||
2|02) time_monthname='Feb' ;;
|
||||
3|03) time_monthname='Mar' ;;
|
||||
4|04) time_monthname='Apr' ;;
|
||||
5|05) time_monthname='May' ;;
|
||||
6|06) time_monthname='Jun' ;;
|
||||
7|07) time_monthname='Jul' ;;
|
||||
8|08) time_monthname='Aug' ;;
|
||||
9|09) time_monthname='Sep' ;;
|
||||
10) time_monthname='Oct' ;;
|
||||
11) time_monthname='Nov' ;;
|
||||
12) time_monthname='Dec' ;;
|
||||
esac
|
||||
|
||||
#
|
||||
# create result string
|
||||
#
|
||||
if [ "x$newline" = "xyes" ]; then
|
||||
echo $format_string |\
|
||||
sed -e "s;%u;$username;g" \
|
||||
-e "s;%h;$hostname;g" \
|
||||
-e "s;%d;$domainname;g" \
|
||||
-e "s;%D;$time_day;g" \
|
||||
-e "s;%M;$time_month;g" \
|
||||
-e "s;%Y;$time_year;g" \
|
||||
-e "s;%m;$time_monthname;g"
|
||||
else
|
||||
echo "${format_string}&" |\
|
||||
sed -e "s;%u;$username;g" \
|
||||
-e "s;%h;$hostname;g" \
|
||||
-e "s;%d;$domainname;g" \
|
||||
-e "s;%D;$time_day;g" \
|
||||
-e "s;%M;$time_month;g" \
|
||||
-e "s;%Y;$time_year;g" \
|
||||
-e "s;%m;$time_monthname;g" |\
|
||||
awk '-F&' '{ printf("%s", $1); }'
|
||||
fi
|
||||
|
27
build/config-stubs
Executable file
27
build/config-stubs
Executable file
|
@ -0,0 +1,27 @@
|
|||
#!/bin/sh
|
||||
|
||||
#
|
||||
# Find all config files (config*.m4) and map them into lines with the
|
||||
# form: NUM? '0' ' ' PATH
|
||||
#
|
||||
# For example:
|
||||
#
|
||||
# 50 ./modules/generators/config5.m4
|
||||
# 0 ./modules/aaa/config.m4
|
||||
# 10 ./example/config1.m4
|
||||
#
|
||||
# These lines are sorted, then the first field is removed. Thus, we
|
||||
# have a set of paths sorted on the config-number (if present). All
|
||||
# config files without a number are sorted before those with a number.
|
||||
#
|
||||
|
||||
configfiles=`find os server modules support -name "config*.m4" | \
|
||||
sed 's#\(.*/config\)\(.*\).m4#\20 \1\2.m4#' | \
|
||||
sort | \
|
||||
sed 's#.* ##'`
|
||||
|
||||
for configfile in $configfiles; do
|
||||
if [ -r $configfile ]; then
|
||||
echo "sinclude($configfile)"
|
||||
fi
|
||||
done
|
1812
build/config.guess
vendored
Executable file
1812
build/config.guess
vendored
Executable file
File diff suppressed because it is too large
Load diff
1971
build/config.sub
vendored
Executable file
1971
build/config.sub
vendored
Executable file
File diff suppressed because it is too large
Load diff
78
build/config_vars.sh.in
Normal file
78
build/config_vars.sh.in
Normal file
|
@ -0,0 +1,78 @@
|
|||
#! @SHELL@
|
||||
# -*- sh -*-
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# config_vars.sh is generated by configure, and is run by the "install-build"
|
||||
# target to generate a version of config_vars.mk which is suitable to be
|
||||
# installed. Such a file cannot be generated at configure-time, since it
|
||||
# requires the output of the *installed* ap*-config scripts.
|
||||
|
||||
# For a DESTDIR=... installation using the bundled copies of
|
||||
# apr/apr-util, the installed ap?-config scripts must be found
|
||||
# in the DESTDIR-relocated install tree. For a DESTDIR=...
|
||||
# installation when using *external* copies of apr/apr-util,
|
||||
# the absolute path must be used, not DESTDIR-relocated.
|
||||
|
||||
if test -f ${DESTDIR}@APR_CONFIG@; then
|
||||
APR_CONFIG=${DESTDIR}@APR_CONFIG@
|
||||
APU_CONFIG=${DESTDIR}@APU_CONFIG@
|
||||
else
|
||||
APR_CONFIG=@APR_CONFIG@
|
||||
APU_CONFIG=@APU_CONFIG@
|
||||
fi
|
||||
|
||||
APR_LIBTOOL="`${APR_CONFIG} --apr-libtool`"
|
||||
APR_INCLUDEDIR="`${APR_CONFIG} --includedir`"
|
||||
test -n "@APU_CONFIG@" && APU_INCLUDEDIR="`${APU_CONFIG} --includedir`"
|
||||
|
||||
installbuilddir="@exp_installbuilddir@"
|
||||
|
||||
exec sed "
|
||||
/^[A-Z0-9_]*_LDADD/d
|
||||
/MPM_LIB/d
|
||||
/APACHECTL_ULIMIT/d
|
||||
/[a-z]*_LTFLAGS/d
|
||||
/^MPM_MODULES/d
|
||||
/^ENABLED_MPM_MODULE/d
|
||||
/^DSO_MODULES/d
|
||||
/^MODULE_/d
|
||||
/^PORT/d
|
||||
/^SSLPORT/d
|
||||
/^nonssl_/d
|
||||
/^CORE_IMPLIB/d
|
||||
/^rel_/d
|
||||
/^abs_srcdir/d
|
||||
/^BUILTIN_LIBS/d
|
||||
/^[A-Z]*_SHARED_CMDS/d
|
||||
/^shared_build/d
|
||||
/^OS_DIR/d
|
||||
/^AP_LIBS/d
|
||||
/^OS_SPECIFIC_VARS/d
|
||||
/^MPM_SUBDIRS/d
|
||||
/^EXTRA_INCLUDES/{
|
||||
s, = , = -I\$(includedir) ,
|
||||
s, -I\$(top_srcdir)/[^ ]*,,g
|
||||
s, -I\$(top_builddir)/[^ ]*,,g
|
||||
}
|
||||
/^MKINSTALLDIRS/s,\$(abs_srcdir)/build,$installbuilddir,
|
||||
/^INSTALL /s,\$(abs_srcdir)/build,$installbuilddir,
|
||||
/^HTTPD_LDFLAGS/d
|
||||
/^UTIL_LDFLAGS/d
|
||||
/^APR_INCLUDEDIR.*$/s,.*,APR_INCLUDEDIR = ${APR_INCLUDEDIR},
|
||||
/^APU_INCLUDEDIR.*$/s,.*,APU_INCLUDEDIR = ${APU_INCLUDEDIR},
|
||||
/^LIBTOOL.*$/s,/[^ ]*/libtool \(.*\),${APR_LIBTOOL} @LTFLAGS@,
|
||||
"
|
71
build/cpR_noreplace.pl
Normal file
71
build/cpR_noreplace.pl
Normal file
|
@ -0,0 +1,71 @@
|
|||
#!/usr/bin/perl -w
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
use strict;
|
||||
use File::Basename;
|
||||
use File::Copy;
|
||||
use File::Find;
|
||||
use File::Path qw(mkpath);
|
||||
|
||||
require 5.010;
|
||||
|
||||
my $srcdir;
|
||||
my $destdir;
|
||||
|
||||
sub process_file {
|
||||
return if $_ =~ /^\./;
|
||||
|
||||
my $rel_to_srcdir = substr($File::Find::name, length($srcdir));
|
||||
my $destfile = "$destdir$rel_to_srcdir";
|
||||
|
||||
if (-d $File::Find::name) {
|
||||
# If the directory is empty, it won't get created.
|
||||
# Otherwise it will get created when copying a file.
|
||||
}
|
||||
else {
|
||||
if (-f $destfile) {
|
||||
# Preserve it.
|
||||
}
|
||||
else {
|
||||
# Create it.
|
||||
my $dir = dirname($destfile);
|
||||
if (! -e $dir) {
|
||||
mkpath($dir) or die "Failed to create directory $dir: $!";
|
||||
}
|
||||
copy($File::Find::name, $destfile) or die "Copy $File::Find::name->$destfile failed: $!";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$srcdir = shift;
|
||||
$destdir = shift;
|
||||
if (scalar(@ARGV) > 0) {
|
||||
my $mode = shift;
|
||||
if ($mode eq "ifdestmissing") {
|
||||
# Normally the check for possible overwrite is performed on a
|
||||
# file-by-file basis. If "ifdestmissing" is specified and the
|
||||
# destination directory exists, bail out.
|
||||
if (-d $destdir) {
|
||||
print "[PRESERVING EXISTING SUBDIR $destdir]\n";
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
else {
|
||||
die "bad mode $mode";
|
||||
}
|
||||
}
|
||||
find(\&process_file, ($srcdir));
|
496
build/default.pl
Normal file
496
build/default.pl
Normal file
|
@ -0,0 +1,496 @@
|
|||
<<
|
||||
# Scandoc template file.
|
||||
#
|
||||
# This is an example set of templates that is designed to create several
|
||||
# different kinds of index files. It generates a "master index" which intended
|
||||
# for use with a frames browser; A "package index" which is the root page of
|
||||
# the index, and then "package files" containing documentation for all of the
|
||||
# classes within a single package.
|
||||
|
||||
######################################################################
|
||||
|
||||
## For quick and superficial customization,
|
||||
## simply change these variables
|
||||
|
||||
$project_name = '[Apache]';
|
||||
$company_logo = '<img src="../images/ScanDocBig.jpg">'; # change this to an image tag.
|
||||
$copyright = '© 2000 [Apache Software Foundation]';
|
||||
$image_directory = "../images/";
|
||||
$bullet1_image = $image_directory . "ball1.gif";
|
||||
$bullet2_image = $image_directory . "ball2.gif";
|
||||
$bgcolor1 = "#FFFFFF";
|
||||
$bgcolor2 = "#FFFFFF";
|
||||
|
||||
######################################################################
|
||||
|
||||
## Begin generating frame index file.
|
||||
|
||||
file "index.html";
|
||||
>><html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; iso-8859-1">
|
||||
<title>$project_name</title>
|
||||
</head>
|
||||
<frameset cols="190,*">
|
||||
<frame src="master.html" name="Master Index" noresize>
|
||||
<frame src="packages.html" name="Documentation">
|
||||
<noframes>
|
||||
<body bgcolor="$bgcolor2" stylesrc="index.html">
|
||||
<p>Some Documentation</p>
|
||||
</body>
|
||||
</noframes>
|
||||
</frameset>
|
||||
</html>
|
||||
<<
|
||||
|
||||
######################################################################
|
||||
|
||||
## Begin generating master index file (left-hand frame).
|
||||
|
||||
file "master.html";
|
||||
>><html>
|
||||
<head>
|
||||
<title>Master Index</title>
|
||||
</head>
|
||||
<body bgcolor="$bgcolor1" text=#0000ff link=#0020ff vlink=#0020ff>
|
||||
<center><img src="${image_directory}ScanDocSmall.jpg" border="0" /></center>
|
||||
<p>
|
||||
<a href="packages.html" target="Documentation">Master Index</a>
|
||||
</p>
|
||||
<p>
|
||||
<font size="2">
|
||||
<nobr>
|
||||
<<
|
||||
|
||||
## For each package, generate an index entry.
|
||||
|
||||
foreach $p (packages()) {
|
||||
$_ = $p->url;
|
||||
s/\s/%20/g;
|
||||
>><a href="$_" target="Documentation"><b>$(p.name)</b></a><br>
|
||||
<dir>
|
||||
<<
|
||||
foreach $e ($p->classes()) {
|
||||
$_ = $e->url;
|
||||
s/\s/%20/g;
|
||||
>><li><a href="$_" target="Documentation">$(e.fullname)</a>
|
||||
<<
|
||||
}
|
||||
foreach $e ($p->globals()) {
|
||||
$_ = $e->url;
|
||||
s/\s/%20/g;
|
||||
>><li><a href="$_" target="Documentation">$(e.fullname)</a>
|
||||
<<
|
||||
}
|
||||
>></dir><<
|
||||
}
|
||||
|
||||
>>
|
||||
<a href="to-do.html" target="Documentation"><b>To-Do List</b></a><br>
|
||||
</nobr>
|
||||
</font>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
<<
|
||||
|
||||
######################################################################
|
||||
|
||||
## Begin generating package index file
|
||||
|
||||
file "packages.html";
|
||||
>><html>
|
||||
<head>
|
||||
<title>$project_name -- Packages</title>
|
||||
</head>
|
||||
<body bgcolor="$bgcolor2">
|
||||
|
||||
<center>$company_logo
|
||||
<h1>Documentation for $project_name</h1>
|
||||
</center>
|
||||
<h2>Package List</h2>
|
||||
<<
|
||||
|
||||
## For each package, generate an index entry.
|
||||
|
||||
foreach $p (packages()) {
|
||||
$_ = $p->url;
|
||||
s/\s/%20/g;
|
||||
>><a href = "$_">$(p.name)</a><br>
|
||||
<<
|
||||
}
|
||||
|
||||
>>
|
||||
<p>
|
||||
<hr size=4>
|
||||
$copyright<br>
|
||||
Generated by <a href="$scandocURL"><b>ScanDoc $majorVersion.$minorVersion</b></a><br>
|
||||
Last Updated: $date<br>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<<
|
||||
|
||||
######################################################################
|
||||
|
||||
## Generate "To-do list"
|
||||
|
||||
file "to-do.html";
|
||||
>><html>
|
||||
<head>
|
||||
<title>$project_name -- To-Do list</title>
|
||||
</head>
|
||||
<body bgcolor="$bgcolor2">
|
||||
|
||||
$company_logo
|
||||
|
||||
<h1>To-do list for $project_name</h1>
|
||||
<<
|
||||
|
||||
if (&todolistFiles()) {
|
||||
>><hr size=4><p>
|
||||
<<
|
||||
foreach $f (&todolistFiles()) {
|
||||
my @m = &todolistEntries( $f );
|
||||
if ($f =~ /([^\/]+)$/) { $f = $1; }
|
||||
>><b>$f:</b><ul>
|
||||
<<
|
||||
foreach $text (@m) {
|
||||
if ($text) {
|
||||
print "<li>", &processDescription( $text ), "\n";
|
||||
}
|
||||
}
|
||||
>></ul>
|
||||
<<
|
||||
}
|
||||
}
|
||||
|
||||
>>
|
||||
<hr size=4>
|
||||
$copyright<br>
|
||||
Generated by <a href="$scandocURL"><b>ScanDoc $majorVersion.$minorVersion</b></a><br>
|
||||
Last Updated: $date<br>
|
||||
</body>
|
||||
</html>
|
||||
<<
|
||||
|
||||
######################################################################
|
||||
|
||||
## Generate individual files for each package.
|
||||
|
||||
my $p;
|
||||
foreach $p (packages()) {
|
||||
file $p->name() . ".html";
|
||||
>><html>
|
||||
<head>
|
||||
<title>$project_name -- $(p.name)</title>
|
||||
</head>
|
||||
<body bgcolor="$bgcolor2">
|
||||
<center>
|
||||
<font size=6><b>$project_name</b></font>
|
||||
<hr size=4><p>
|
||||
</center>
|
||||
|
||||
<h2>Package Name: $(p.name)</h2>
|
||||
<b>
|
||||
<<
|
||||
|
||||
## Generate class and member index at the top of the file.
|
||||
|
||||
foreach $c ($p->classes()) {
|
||||
>><h3><img src="$bullet1_image" width=18 height=17 align=texttop>
|
||||
<a href="$(c.url)">$(c.fullname)</h3></a>
|
||||
<ul>
|
||||
<<
|
||||
foreach $m ($c->members()) {
|
||||
>><li><a href="$(m.url)">$(m.longname)</a>
|
||||
<<
|
||||
}
|
||||
>></ul>
|
||||
<<
|
||||
}
|
||||
|
||||
>>
|
||||
</b>
|
||||
<<
|
||||
|
||||
## Generate detailed class documentation
|
||||
foreach $c ($p->classes()) {
|
||||
## Output searchable keyword list
|
||||
if ($c->keywords()) {
|
||||
print "<!-- ", $c->keywords(), " -->\n";
|
||||
}
|
||||
|
||||
>><hr size="4">
|
||||
<a name="$(c.anchor)"></a>
|
||||
<h1>$(c.fullname)</h1>
|
||||
<table bgcolor="ffffff" border="0" cellspacing="4">
|
||||
<tr>
|
||||
<th align=center colspan=2>
|
||||
</th>
|
||||
</tr>
|
||||
<<
|
||||
|
||||
# Output author tag
|
||||
if ($c->author()) {
|
||||
>><tr><th width=20% align=right>Author:</th><<
|
||||
>><td>$(c.author)</td></tr><<
|
||||
}
|
||||
|
||||
# Output package version
|
||||
if ($c->version()) {
|
||||
>><tr><th width=20% align=right>Version:</th><<
|
||||
>><td>$(c.version)</td></tr><<
|
||||
}
|
||||
|
||||
# Output Source file
|
||||
if ($c->sourcefile()) {
|
||||
>><tr><th width=20% align=right>Source:</th><<
|
||||
>><td>$(c.sourcefile)</td></tr><<
|
||||
}
|
||||
|
||||
# Output base class list
|
||||
if ($c->baseclasses()) {
|
||||
>><tr><th width=20% align=right>Base classes:</th>
|
||||
<td><<
|
||||
my @t = ();
|
||||
foreach $b ($c->baseclasses()) {
|
||||
my $name = $b->name();
|
||||
if ($url = $b->url()) {
|
||||
push @t, "<a href=\"$url\">$name</a>";
|
||||
}
|
||||
else { push @t, $name; }
|
||||
}
|
||||
print join( ', ', @t );
|
||||
>></td></tr>
|
||||
<<
|
||||
}
|
||||
|
||||
# Output subclasses list
|
||||
if ($c->subclasses()) {
|
||||
>><tr><th width=20% align=right>Subclasses:</th>
|
||||
<td><<
|
||||
my @t = ();
|
||||
foreach $s ($c->subclasses()) {
|
||||
my $name = $s->name();
|
||||
if ($url = $s->url()) {
|
||||
push @t, "<a href=\"$url\">$name</a>";
|
||||
}
|
||||
else { push @t, $name; }
|
||||
}
|
||||
print join( ', ', @t );
|
||||
>></td></tr><<
|
||||
}
|
||||
|
||||
# Output main class description
|
||||
>></tr>
|
||||
</table>
|
||||
<p>
|
||||
<<
|
||||
print &processDescription( $c->description() );
|
||||
|
||||
# Output "see also" information
|
||||
if ($c->seealso()) {
|
||||
>><p><dt><b>See Also</b><dd>
|
||||
<<
|
||||
my @r = ();
|
||||
foreach $a ($c->seealso()) {
|
||||
my $name = $a->name();
|
||||
if ($url = $a->url()) {
|
||||
push @r, "<a href=\"$url\">$name</a>";
|
||||
}
|
||||
else { push @r, $name; }
|
||||
}
|
||||
print join( ',', @r );
|
||||
>><p>
|
||||
<<
|
||||
}
|
||||
|
||||
# Output class member index
|
||||
if ($c->members()) {
|
||||
print "<h2>Member Index</h2>\n";
|
||||
print "<ul>";
|
||||
foreach $m ($c->members()) {
|
||||
>><li><a href="$(m.url)">$(m.fullname)</a>
|
||||
<<
|
||||
}
|
||||
>></ul><<
|
||||
}
|
||||
|
||||
# Output class member variable documentation
|
||||
if ($c->membervars()) {
|
||||
print "<h2>Class Variables</h2>\n";
|
||||
print "<blockquote>\n";
|
||||
foreach $m ($c->membervars()) { &variable( $m ); }
|
||||
print "</blockquote>\n";
|
||||
}
|
||||
|
||||
# Output class member function documentation
|
||||
if ($c->memberfuncs()) {
|
||||
print "<h2>Class Methods</h2>\n";
|
||||
print "<blockquote>\n";
|
||||
foreach $m ($c->memberfuncs()) { &function( $m ); }
|
||||
print "</blockquote>\n";
|
||||
}
|
||||
}
|
||||
|
||||
# Output global variables
|
||||
if ($p->globalvars()) {
|
||||
>><h2>Global Variables</h2>
|
||||
<blockquote>
|
||||
<<
|
||||
foreach $m ($p->globalvars()) { &variable( $m ); }
|
||||
print "</blockquote>\n";
|
||||
}
|
||||
|
||||
# Output global functions
|
||||
if ($p->globalfuncs()) {
|
||||
>><h2>Global Functions</h2>
|
||||
<blockquote>
|
||||
<<
|
||||
foreach $m ($p->globalfuncs()) { &function( $m ); }
|
||||
print "</blockquote>\n";
|
||||
}
|
||||
|
||||
>>
|
||||
<hr size=4>
|
||||
$copyright<br>
|
||||
Generated by <a href="$scandocURL"><b>ScanDoc $majorVersion.$minorVersion</b></a><br>
|
||||
Last Updated: $date<br>
|
||||
</body>
|
||||
</html>
|
||||
<<
|
||||
} # end of foreach (packages) loop
|
||||
|
||||
######################################################################
|
||||
|
||||
## Subroutine to generate documentation for a member function or global function
|
||||
|
||||
sub function {
|
||||
local ($f) = @_;
|
||||
|
||||
if ($f->keywords()) {
|
||||
>><!-- $(f.keywords) -->
|
||||
<<
|
||||
}
|
||||
>>
|
||||
<a name="$(f.anchor)"></a>
|
||||
<dl>
|
||||
<dt>
|
||||
<b><img src="$bullet2_image" width=19 height=17 align=texttop>$(f.fullname);</b>
|
||||
<dd>
|
||||
<<
|
||||
print &processDescription( $f->description() );
|
||||
>>
|
||||
<p><dl>
|
||||
<<
|
||||
if ($f->params()) {
|
||||
>>
|
||||
<dt><b>Parameters</b><dd>
|
||||
<table width="85%">
|
||||
<<
|
||||
foreach $a ($f->params()) {
|
||||
>><tr valign=top><th align=right>
|
||||
$(a.name)</th><td><<
|
||||
print &processDescription( $a->description() );
|
||||
>></td></tr>
|
||||
<<
|
||||
}
|
||||
>></table>
|
||||
<<
|
||||
}
|
||||
|
||||
if ($f->returnValue()) {
|
||||
>><dt><b>Return Value</b>
|
||||
<dd><<
|
||||
print &processDescription( $f->returnValue() );
|
||||
>><p><<
|
||||
}
|
||||
|
||||
if ($f->exceptions()) {
|
||||
>><dt><b>Exceptions</b><dd>
|
||||
<table width=85%><tr><td colspan=2><hr size=3></td></tr>
|
||||
<<
|
||||
foreach $a ($f->exceptions()) {
|
||||
>><tr valign=top><th align=right>
|
||||
$(a.name)</th><td><<
|
||||
print &processDescription( $a->description() );
|
||||
>></td></tr>
|
||||
<<
|
||||
}
|
||||
>><tr><td colspan=2><hr size=3></td></tr></table>
|
||||
<<
|
||||
}
|
||||
|
||||
if ($f->seealso()) {
|
||||
>><dt><b>See Also</b><dd>
|
||||
<<
|
||||
my @r = ();
|
||||
foreach $a ($f->seealso()) {
|
||||
my $name = $a->name();
|
||||
if ($url = $a->url()) {
|
||||
push @r, "<a href=\"$url\">$name</a>";
|
||||
}
|
||||
else { push @r, $name; }
|
||||
}
|
||||
print join( ',', @r );
|
||||
>><p><<
|
||||
}
|
||||
>></dl></dl>
|
||||
<<
|
||||
}
|
||||
|
||||
######################################################################
|
||||
|
||||
## Subroutine to generate documentation for a member variable or global variable.
|
||||
|
||||
sub variable {
|
||||
local ($v) = @_;
|
||||
|
||||
if ($v->keywords()) {
|
||||
print "<!-- $(v.keywords) -->";
|
||||
}
|
||||
|
||||
>>
|
||||
<a name="$(v.name)"></a>
|
||||
<dl><dt>
|
||||
<b><img src="$bullet2_image" width=19 height=17 align=texttop>$(v.fullname);</b>
|
||||
<dd>
|
||||
<<print &processDescription( $v->description() );>>
|
||||
<p><dl>
|
||||
<<
|
||||
if ($v->seealso()) {
|
||||
>><dt><b>See Also</b><dd>
|
||||
<<
|
||||
$comma = 0;
|
||||
foreach $a ($v->seealso()) {
|
||||
if ($comma) { print ","; }
|
||||
$comma = 1;
|
||||
>><a href="$(a.url)">$(a.name)</a>
|
||||
<<
|
||||
}
|
||||
>><p>
|
||||
<<
|
||||
}
|
||||
>></dl></dl>
|
||||
<<
|
||||
}
|
||||
|
||||
######################################################################
|
||||
|
||||
sub processDescription {
|
||||
local ($_) = @_;
|
||||
|
||||
s/^\s+//; # Remove whitespace from beginning
|
||||
s/\s+$/\n/; # Remove whitespace from end
|
||||
s/\n\n/<p>\n/g; # Replace multiple CR's with paragraph markers
|
||||
s:\@heading(.*)\n:<p><h2>$1</h2>:; # Handle heading text
|
||||
|
||||
# Handle embedded image tags
|
||||
s:\@caution:<p><img src=\"${image_directory}/caution.gif\" align=left>:;
|
||||
s:\@warning:<p><img src=\"${image_directory}/warning.gif\" align=left>:;
|
||||
s:\@bug:<p><img src=\"${image_directory}/bug.gif\">:;
|
||||
s:\@tip:<p><img src=\"${image_directory}/tip.gif\">:;
|
||||
|
||||
return $_;
|
||||
}
|
89
build/fastgen.sh
Executable file
89
build/fastgen.sh
Executable file
|
@ -0,0 +1,89 @@
|
|||
#! /bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
srcdir=$1
|
||||
shift
|
||||
|
||||
mkdir_p=$1
|
||||
shift
|
||||
|
||||
bsd_makefile=$1
|
||||
shift
|
||||
|
||||
top_srcdir=`(cd $srcdir; pwd)`
|
||||
top_builddir=`pwd`
|
||||
|
||||
if test "$mkdir_p" = "yes"; then
|
||||
mkdir_p="mkdir -p"
|
||||
else
|
||||
mkdir_p="$top_srcdir/build/mkdir.sh"
|
||||
fi
|
||||
|
||||
if test "$bsd_makefile" = "yes"; then
|
||||
(cd $top_srcdir; ./build/bsd_makefile)
|
||||
|
||||
for makefile in $@; do
|
||||
echo "creating $makefile"
|
||||
dir=`echo $makefile|sed 's%/*[^/][^/]*$%%'`
|
||||
|
||||
if test -z "$dir"; then
|
||||
real_srcdir=$top_srcdir
|
||||
real_builddir=$top_builddir
|
||||
dir="."
|
||||
else
|
||||
$mkdir_p "$dir/"
|
||||
real_srcdir=$top_srcdir/$dir
|
||||
real_builddir=$top_builddir/$dir
|
||||
fi
|
||||
cat - $top_srcdir/$makefile.in <<EOF |sed 's/^include \(.*\)/.include "\1"/' >$makefile
|
||||
top_srcdir = $top_srcdir
|
||||
top_builddir = $top_builddir
|
||||
srcdir = $real_srcdir
|
||||
builddir = $real_builddir
|
||||
VPATH = $real_srcdir
|
||||
EOF
|
||||
|
||||
touch $dir/.deps
|
||||
done
|
||||
else
|
||||
for makefile in $@; do
|
||||
echo "creating $makefile"
|
||||
dir=`echo $makefile|sed 's%/*[^/][^/]*$%%'`
|
||||
|
||||
if test -z "$dir"; then
|
||||
real_srcdir=$top_srcdir
|
||||
real_builddir=$top_builddir
|
||||
dir="."
|
||||
else
|
||||
$mkdir_p "$dir/"
|
||||
real_srcdir=$top_srcdir/$dir
|
||||
real_builddir=$top_builddir/$dir
|
||||
fi
|
||||
cat - $top_srcdir/$makefile.in <<EOF >$makefile
|
||||
top_srcdir = $top_srcdir
|
||||
top_builddir = $top_builddir
|
||||
srcdir = $real_srcdir
|
||||
builddir = $real_builddir
|
||||
VPATH = $real_srcdir
|
||||
EOF
|
||||
|
||||
touch $dir/.deps
|
||||
done
|
||||
fi
|
202
build/find_apr.m4
Normal file
202
build/find_apr.m4
Normal file
|
@ -0,0 +1,202 @@
|
|||
dnl -------------------------------------------------------- -*- autoconf -*-
|
||||
dnl Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
dnl contributor license agreements. See the NOTICE file distributed with
|
||||
dnl this work for additional information regarding copyright ownership.
|
||||
dnl The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
dnl (the "License"); you may not use this file except in compliance with
|
||||
dnl the License. You may obtain a copy of the License at
|
||||
dnl
|
||||
dnl http://www.apache.org/licenses/LICENSE-2.0
|
||||
dnl
|
||||
dnl Unless required by applicable law or agreed to in writing, software
|
||||
dnl distributed under the License is distributed on an "AS IS" BASIS,
|
||||
dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
dnl See the License for the specific language governing permissions and
|
||||
dnl limitations under the License.
|
||||
|
||||
dnl
|
||||
dnl find_apr.m4 : locate the APR include files and libraries
|
||||
dnl
|
||||
dnl This macro file can be used by applications to find and use the APR
|
||||
dnl library. It provides a standardized mechanism for using APR. It supports
|
||||
dnl embedding APR into the application source, or locating an installed
|
||||
dnl copy of APR.
|
||||
dnl
|
||||
dnl APR_FIND_APR(srcdir, builddir, implicit-install-check, acceptable-majors,
|
||||
dnl detailed-check)
|
||||
dnl
|
||||
dnl where srcdir is the location of the bundled APR source directory, or
|
||||
dnl empty if source is not bundled.
|
||||
dnl
|
||||
dnl where builddir is the location where the bundled APR will will be built,
|
||||
dnl or empty if the build will occur in the srcdir.
|
||||
dnl
|
||||
dnl where implicit-install-check set to 1 indicates if there is no
|
||||
dnl --with-apr option specified, we will look for installed copies.
|
||||
dnl
|
||||
dnl where acceptable-majors is a space separated list of acceptable major
|
||||
dnl version numbers. Often only a single major version will be acceptable.
|
||||
dnl If multiple versions are specified, and --with-apr=PREFIX or the
|
||||
dnl implicit installed search are used, then the first (leftmost) version
|
||||
dnl in the list that is found will be used. Currently defaults to [0 1].
|
||||
dnl
|
||||
dnl where detailed-check is an M4 macro which sets the apr_acceptable to
|
||||
dnl either "yes" or "no". The macro will be invoked for each installed
|
||||
dnl copy of APR found, with the apr_config variable set appropriately.
|
||||
dnl Only installed copies of APR which are considered acceptable by
|
||||
dnl this macro will be considered found. If no installed copies are
|
||||
dnl considered acceptable by this macro, apr_found will be set to either
|
||||
dnl either "no" or "reconfig".
|
||||
dnl
|
||||
dnl Sets the following variables on exit:
|
||||
dnl
|
||||
dnl apr_found : "yes", "no", "reconfig"
|
||||
dnl
|
||||
dnl apr_config : If the apr-config tool exists, this refers to it. If
|
||||
dnl apr_found is "reconfig", then the bundled directory
|
||||
dnl should be reconfigured *before* using apr_config.
|
||||
dnl
|
||||
dnl Note: this macro file assumes that apr-config has been installed; it
|
||||
dnl is normally considered a required part of an APR installation.
|
||||
dnl
|
||||
dnl If a bundled source directory is available and needs to be (re)configured,
|
||||
dnl then apr_found is set to "reconfig". The caller should reconfigure the
|
||||
dnl (passed-in) source directory, placing the result in the build directory,
|
||||
dnl as appropriate.
|
||||
dnl
|
||||
dnl If apr_found is "yes" or "reconfig", then the caller should use the
|
||||
dnl value of apr_config to fetch any necessary build/link information.
|
||||
dnl
|
||||
|
||||
AC_DEFUN([APR_FIND_APR], [
|
||||
apr_found="no"
|
||||
|
||||
if test "$target_os" = "os2-emx"; then
|
||||
# Scripts don't pass test -x on OS/2
|
||||
TEST_X="test -f"
|
||||
else
|
||||
TEST_X="test -x"
|
||||
fi
|
||||
|
||||
ifelse([$4], [], [
|
||||
ifdef(AC_WARNING,AC_WARNING([$0: missing argument 4 (acceptable-majors): Defaulting to APR 0.x then APR 1.x]))
|
||||
acceptable_majors="0 1"],
|
||||
[acceptable_majors="$4"])
|
||||
|
||||
apr_temp_acceptable_apr_config=""
|
||||
for apr_temp_major in $acceptable_majors
|
||||
do
|
||||
case $apr_temp_major in
|
||||
0)
|
||||
apr_temp_acceptable_apr_config="$apr_temp_acceptable_apr_config apr-config"
|
||||
;;
|
||||
*)
|
||||
apr_temp_acceptable_apr_config="$apr_temp_acceptable_apr_config apr-$apr_temp_major-config"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
AC_MSG_CHECKING(for APR)
|
||||
AC_ARG_WITH(apr,
|
||||
[ --with-apr=PATH prefix for installed APR or the full path to
|
||||
apr-config],
|
||||
[
|
||||
if test "$withval" = "no" || test "$withval" = "yes"; then
|
||||
AC_MSG_ERROR([--with-apr requires a directory or file to be provided])
|
||||
fi
|
||||
|
||||
for apr_temp_apr_config_file in $apr_temp_acceptable_apr_config
|
||||
do
|
||||
for lookdir in "$withval/bin" "$withval"
|
||||
do
|
||||
if $TEST_X "$lookdir/$apr_temp_apr_config_file"; then
|
||||
apr_config="$lookdir/$apr_temp_apr_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apr_acceptable="yes"
|
||||
$5
|
||||
if test "$apr_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([Found APR in $apr_config, but we think it is considered unacceptable])
|
||||
continue
|
||||
fi])
|
||||
apr_found="yes"
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
|
||||
if test "$apr_found" != "yes" && $TEST_X "$withval" && $withval --help > /dev/null 2>&1 ; then
|
||||
apr_config="$withval"
|
||||
ifelse([$5], [], [apr_found="yes"], [
|
||||
apr_acceptable="yes"
|
||||
$5
|
||||
if test "$apr_acceptable" = "yes"; then
|
||||
apr_found="yes"
|
||||
fi])
|
||||
fi
|
||||
|
||||
dnl if --with-apr is used, it is a fatal error for its argument
|
||||
dnl to be invalid
|
||||
if test "$apr_found" != "yes"; then
|
||||
AC_MSG_ERROR([the --with-apr parameter is incorrect. It must specify an install prefix, a build directory, or an apr-config file.])
|
||||
fi
|
||||
],[
|
||||
dnl If we allow installed copies, check those before using bundled copy.
|
||||
if test -n "$3" && test "$3" = "1"; then
|
||||
for apr_temp_apr_config_file in $apr_temp_acceptable_apr_config
|
||||
do
|
||||
if $apr_temp_apr_config_file --help > /dev/null 2>&1 ; then
|
||||
apr_config="$apr_temp_apr_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apr_acceptable="yes"
|
||||
$5
|
||||
if test "$apr_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([skipped APR at $apr_config, version not acceptable])
|
||||
continue
|
||||
fi])
|
||||
apr_found="yes"
|
||||
break
|
||||
else
|
||||
dnl look in some standard places
|
||||
for lookdir in /usr /usr/local /usr/local/apr /opt/apr; do
|
||||
if $TEST_X "$lookdir/bin/$apr_temp_apr_config_file"; then
|
||||
apr_config="$lookdir/bin/$apr_temp_apr_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apr_acceptable="yes"
|
||||
$5
|
||||
if test "$apr_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([skipped APR at $apr_config, version not acceptable])
|
||||
continue
|
||||
fi])
|
||||
apr_found="yes"
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
fi
|
||||
done
|
||||
fi
|
||||
dnl if we have not found anything yet and have bundled source, use that
|
||||
if test "$apr_found" = "no" && test -d "$1"; then
|
||||
apr_temp_abs_srcdir="`cd \"$1\" && pwd`"
|
||||
apr_found="reconfig"
|
||||
apr_bundled_major="`sed -n '/#define.*APR_MAJOR_VERSION/s/^[^0-9]*\([0-9]*\).*$/\1/p' \"$1/include/apr_version.h\"`"
|
||||
case $apr_bundled_major in
|
||||
"")
|
||||
AC_MSG_ERROR([failed to find major version of bundled APR])
|
||||
;;
|
||||
0)
|
||||
apr_temp_apr_config_file="apr-config"
|
||||
;;
|
||||
*)
|
||||
apr_temp_apr_config_file="apr-$apr_bundled_major-config"
|
||||
;;
|
||||
esac
|
||||
if test -n "$2"; then
|
||||
apr_config="$2/$apr_temp_apr_config_file"
|
||||
else
|
||||
apr_config="$1/$apr_temp_apr_config_file"
|
||||
fi
|
||||
fi
|
||||
])
|
||||
|
||||
AC_MSG_RESULT($apr_found)
|
||||
])
|
211
build/find_apu.m4
Normal file
211
build/find_apu.m4
Normal file
|
@ -0,0 +1,211 @@
|
|||
dnl -------------------------------------------------------- -*- autoconf -*-
|
||||
dnl Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
dnl contributor license agreements. See the NOTICE file distributed with
|
||||
dnl this work for additional information regarding copyright ownership.
|
||||
dnl The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
dnl (the "License"); you may not use this file except in compliance with
|
||||
dnl the License. You may obtain a copy of the License at
|
||||
dnl
|
||||
dnl http://www.apache.org/licenses/LICENSE-2.0
|
||||
dnl
|
||||
dnl Unless required by applicable law or agreed to in writing, software
|
||||
dnl distributed under the License is distributed on an "AS IS" BASIS,
|
||||
dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
dnl See the License for the specific language governing permissions and
|
||||
dnl limitations under the License.
|
||||
|
||||
dnl
|
||||
dnl find_apu.m4 : locate the APR-util (APU) include files and libraries
|
||||
dnl
|
||||
dnl This macro file can be used by applications to find and use the APU
|
||||
dnl library. It provides a standardized mechanism for using APU. It supports
|
||||
dnl embedding APU into the application source, or locating an installed
|
||||
dnl copy of APU.
|
||||
dnl
|
||||
dnl APR_FIND_APU(srcdir, builddir, implicit-install-check, acceptable-majors,
|
||||
dnl detailed-check)
|
||||
dnl
|
||||
dnl where srcdir is the location of the bundled APU source directory, or
|
||||
dnl empty if source is not bundled.
|
||||
dnl
|
||||
dnl where builddir is the location where the bundled APU will be built,
|
||||
dnl or empty if the build will occur in the srcdir.
|
||||
dnl
|
||||
dnl where implicit-install-check set to 1 indicates if there is no
|
||||
dnl --with-apr-util option specified, we will look for installed copies.
|
||||
dnl
|
||||
dnl where acceptable-majors is a space separated list of acceptable major
|
||||
dnl version numbers. Often only a single major version will be acceptable.
|
||||
dnl If multiple versions are specified, and --with-apr-util=PREFIX or the
|
||||
dnl implicit installed search are used, then the first (leftmost) version
|
||||
dnl in the list that is found will be used. Currently defaults to [0 1].
|
||||
dnl
|
||||
dnl where detailed-check is an M4 macro which sets the apu_acceptable to
|
||||
dnl either "yes" or "no". The macro will be invoked for each installed
|
||||
dnl copy of APU found, with the apu_config variable set appropriately.
|
||||
dnl Only installed copies of APU which are considered acceptable by
|
||||
dnl this macro will be considered found. If no installed copies are
|
||||
dnl considered acceptable by this macro, apu_found will be set to either
|
||||
dnl either "no" or "reconfig".
|
||||
dnl
|
||||
dnl Sets the following variables on exit:
|
||||
dnl
|
||||
dnl apu_found : "yes", "no", "reconfig"
|
||||
dnl
|
||||
dnl apu_config : If the apu-config tool exists, this refers to it. If
|
||||
dnl apu_found is "reconfig", then the bundled directory
|
||||
dnl should be reconfigured *before* using apu_config.
|
||||
dnl
|
||||
dnl Note: this macro file assumes that apr-config has been installed; it
|
||||
dnl is normally considered a required part of an APR installation.
|
||||
dnl
|
||||
dnl Note: At this time, we cannot find *both* a source dir and a build dir.
|
||||
dnl If both are available, the build directory should be passed to
|
||||
dnl the --with-apr-util switch.
|
||||
dnl
|
||||
dnl Note: the installation layout is presumed to follow the standard
|
||||
dnl PREFIX/lib and PREFIX/include pattern. If the APU config file
|
||||
dnl is available (and can be found), then non-standard layouts are
|
||||
dnl possible, since it will be described in the config file.
|
||||
dnl
|
||||
dnl If a bundled source directory is available and needs to be (re)configured,
|
||||
dnl then apu_found is set to "reconfig". The caller should reconfigure the
|
||||
dnl (passed-in) source directory, placing the result in the build directory,
|
||||
dnl as appropriate.
|
||||
dnl
|
||||
dnl If apu_found is "yes" or "reconfig", then the caller should use the
|
||||
dnl value of apu_config to fetch any necessary build/link information.
|
||||
dnl
|
||||
|
||||
AC_DEFUN([APR_FIND_APU], [
|
||||
apu_found="no"
|
||||
|
||||
if test "$target_os" = "os2-emx"; then
|
||||
# Scripts don't pass test -x on OS/2
|
||||
TEST_X="test -f"
|
||||
else
|
||||
TEST_X="test -x"
|
||||
fi
|
||||
|
||||
ifelse([$4], [],
|
||||
[
|
||||
ifdef(AC_WARNING,([$0: missing argument 4 (acceptable-majors): Defaulting to APU 0.x then APU 1.x]))
|
||||
acceptable_majors="0 1"
|
||||
], [acceptable_majors="$4"])
|
||||
|
||||
apu_temp_acceptable_apu_config=""
|
||||
for apu_temp_major in $acceptable_majors
|
||||
do
|
||||
case $apu_temp_major in
|
||||
0)
|
||||
apu_temp_acceptable_apu_config="$apu_temp_acceptable_apu_config apu-config"
|
||||
;;
|
||||
*)
|
||||
apu_temp_acceptable_apu_config="$apu_temp_acceptable_apu_config apu-$apu_temp_major-config"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
AC_MSG_CHECKING(for APR-util)
|
||||
AC_ARG_WITH(apr-util,
|
||||
[ --with-apr-util=PATH prefix for installed APU or the full path to
|
||||
apu-config],
|
||||
[
|
||||
if test "$withval" = "no" || test "$withval" = "yes"; then
|
||||
AC_MSG_ERROR([--with-apr-util requires a directory or file to be provided])
|
||||
fi
|
||||
|
||||
for apu_temp_apu_config_file in $apu_temp_acceptable_apu_config
|
||||
do
|
||||
for lookdir in "$withval/bin" "$withval"
|
||||
do
|
||||
if $TEST_X "$lookdir/$apu_temp_apu_config_file"; then
|
||||
apu_config="$lookdir/$apu_temp_apu_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apu_acceptable="yes"
|
||||
$5
|
||||
if test "$apu_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([Found APU in $apu_config, but it is considered unacceptable])
|
||||
continue
|
||||
fi])
|
||||
apu_found="yes"
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
|
||||
if test "$apu_found" != "yes" && $TEST_X "$withval" && $withval --help > /dev/null 2>&1 ; then
|
||||
apu_config="$withval"
|
||||
ifelse([$5], [], [apu_found="yes"], [
|
||||
apu_acceptable="yes"
|
||||
$5
|
||||
if test "$apu_acceptable" = "yes"; then
|
||||
apu_found="yes"
|
||||
fi])
|
||||
fi
|
||||
|
||||
dnl if --with-apr-util is used, it is a fatal error for its argument
|
||||
dnl to be invalid
|
||||
if test "$apu_found" != "yes"; then
|
||||
AC_MSG_ERROR([the --with-apr-util parameter is incorrect. It must specify an install prefix, a build directory, or an apu-config file.])
|
||||
fi
|
||||
],[
|
||||
if test -n "$3" && test "$3" = "1"; then
|
||||
for apu_temp_apu_config_file in $apu_temp_acceptable_apu_config
|
||||
do
|
||||
if $apu_temp_apu_config_file --help > /dev/null 2>&1 ; then
|
||||
apu_config="$apu_temp_apu_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apu_acceptable="yes"
|
||||
$5
|
||||
if test "$apu_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([skipped APR-util at $apu_config, version not acceptable])
|
||||
continue
|
||||
fi])
|
||||
apu_found="yes"
|
||||
break
|
||||
else
|
||||
dnl look in some standard places (apparently not in builtin/default)
|
||||
for lookdir in /usr /usr/local /usr/local/apr /opt/apr; do
|
||||
if $TEST_X "$lookdir/bin/$apu_temp_apu_config_file"; then
|
||||
apu_config="$lookdir/bin/$apu_temp_apu_config_file"
|
||||
ifelse([$5], [], [], [
|
||||
apu_acceptable="yes"
|
||||
$5
|
||||
if test "$apu_acceptable" != "yes"; then
|
||||
AC_MSG_WARN([skipped APR-util at $apu_config, version not acceptable])
|
||||
continue
|
||||
fi])
|
||||
apu_found="yes"
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
fi
|
||||
done
|
||||
fi
|
||||
dnl if we have not found anything yet and have bundled source, use that
|
||||
if test "$apu_found" = "no" && test -d "$1"; then
|
||||
apu_temp_abs_srcdir="`cd \"$1\" && pwd`"
|
||||
apu_found="reconfig"
|
||||
apu_bundled_major="`sed -n '/#define.*APU_MAJOR_VERSION/s/^[^0-9]*\([0-9]*\).*$/\1/p' \"$1/include/apu_version.h\"`"
|
||||
case $apu_bundled_major in
|
||||
"")
|
||||
AC_MSG_ERROR([failed to find major version of bundled APU])
|
||||
;;
|
||||
0)
|
||||
apu_temp_apu_config_file="apu-config"
|
||||
;;
|
||||
*)
|
||||
apu_temp_apu_config_file="apu-$apu_bundled_major-config"
|
||||
;;
|
||||
esac
|
||||
if test -n "$2"; then
|
||||
apu_config="$2/$apu_temp_apu_config_file"
|
||||
else
|
||||
apu_config="$1/$apu_temp_apu_config_file"
|
||||
fi
|
||||
fi
|
||||
])
|
||||
|
||||
AC_MSG_RESULT($apu_found)
|
||||
])
|
59
build/get-version.sh
Executable file
59
build/get-version.sh
Executable file
|
@ -0,0 +1,59 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# extract version numbers from a header file
|
||||
#
|
||||
# USAGE: get-version.sh CMD VERSION_HEADER PREFIX
|
||||
# where CMD is one of: all, major, libtool
|
||||
# where PREFIX is the prefix to {MAJOR|MINOR|PATCH}_VERSION defines
|
||||
#
|
||||
# get-version.sh all returns a dotted version number
|
||||
# get-version.sh major returns just the major version number
|
||||
# get-version.sh libtool returns a version "libtool -version-info" format
|
||||
#
|
||||
|
||||
if test $# != 3; then
|
||||
echo "USAGE: $0 CMD INCLUDEDIR PREFIX"
|
||||
echo " where CMD is one of: all, major"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
major_sed="/#define.*$3_MAJORVERSION/s/^.*\([0-9][0-9]*\).*$/\1/p"
|
||||
minor_sed="/#define.*$3_MINORVERSION/s/^.*\([0-9][0-9]*\).*$/\1/p"
|
||||
patch_sed="/#define.*$3_PATCHLEVEL/s/^[^0-9]*\([0-9][0-9a-z-]*\).*$/\1/p"
|
||||
mmn_sed="/#define.*$3_MAJOR/s/^[^0-9]*\([0-9][0-9]*\).*$/\1/p"
|
||||
major="`sed -n $major_sed $2`"
|
||||
minor="`sed -n $minor_sed $2`"
|
||||
patch="`sed -n $patch_sed $2`"
|
||||
mmn="`sed -n $mmn_sed $2`"
|
||||
|
||||
if test "$1" = "all"; then
|
||||
echo ${major}.${minor}.${patch}
|
||||
elif test "$1" = "major"; then
|
||||
echo ${major}
|
||||
elif test "$1" = "mmn"; then
|
||||
echo ${mmn}
|
||||
elif test "$1" = "epoch"; then
|
||||
printf "%02d%02d%03d" ${major} ${minor} ${patch}
|
||||
elif test "$1" = "libtool"; then
|
||||
# Yes, ${minor}:${patch}:${minor} is correct due to libtool idiocy.
|
||||
echo ${minor}:${patch}:${minor}
|
||||
else
|
||||
echo "ERROR: unknown version CMD ($1)"
|
||||
exit 1
|
||||
fi
|
176
build/install-bindist.sh.in
Executable file
176
build/install-bindist.sh.in
Executable file
|
@ -0,0 +1,176 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# Usage: install-bindist.sh [ServerRoot]
|
||||
# This script installs the Apache binary distribution and
|
||||
# was automatically created by binbuild.sh.
|
||||
|
||||
lmkdir()
|
||||
{
|
||||
path=""
|
||||
dirs=`echo $1 | sed -e 's%/% %g'`
|
||||
mode=$2
|
||||
|
||||
set -- ${dirs}
|
||||
|
||||
for d in ${dirs}
|
||||
do
|
||||
path="${path}/$d"
|
||||
if test ! -d "${path}" ; then
|
||||
mkdir ${path}
|
||||
if test $? -ne 0 ; then
|
||||
echo "Failed to create directory: ${path}"
|
||||
exit 1
|
||||
fi
|
||||
chmod ${mode} ${path}
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
lcopy()
|
||||
{
|
||||
from=$1
|
||||
to=$2
|
||||
dmode=$3
|
||||
fmode=$4
|
||||
|
||||
test -d ${to} || lmkdir ${to} ${dmode}
|
||||
(cd ${from} && tar -cf - *) | (cd ${to} && tar -xf -)
|
||||
|
||||
if test "X${fmode}" != X ; then
|
||||
find ${to} -type f -print | xargs chmod ${fmode}
|
||||
fi
|
||||
if test "X${dmode}" != X ; then
|
||||
find ${to} -type d -print | xargs chmod ${dmode}
|
||||
fi
|
||||
}
|
||||
|
||||
##
|
||||
## determine path to (optional) Perl interpreter
|
||||
##
|
||||
PERL=no-perl5-on-this-system
|
||||
perls='perl5 perl'
|
||||
path=`echo $PATH | sed -e 's/:/ /g'`
|
||||
found_perl=0
|
||||
|
||||
for dir in ${path} ; do
|
||||
for pperl in ${perls} ; do
|
||||
if test -f "${dir}/${pperl}" ; then
|
||||
if `${dir}/${pperl} -v >/dev/null 2>&1` ; then
|
||||
PERL="${dir}/${pperl}"
|
||||
found_perl=1
|
||||
break
|
||||
fi
|
||||
fi
|
||||
done
|
||||
if test $found_perl = 1 ; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ .$1 = . ]
|
||||
then
|
||||
SR=@default_dir@
|
||||
else
|
||||
SR=$1
|
||||
fi
|
||||
echo "Installing binary distribution for platform @os@"
|
||||
echo "into directory $SR ..."
|
||||
lmkdir $SR 755
|
||||
lmkdir $SR/proxy 750
|
||||
lmkdir $SR/logs 755
|
||||
lmkdir $SR/build 755
|
||||
lcopy bindist/build $SR/build 750 750
|
||||
lcopy bindist/man $SR/man 755 644
|
||||
if [ -d bindist/modules ]
|
||||
then
|
||||
lcopy bindist/modules $SR/modules 750 750
|
||||
fi
|
||||
lcopy bindist/include $SR/include 755 644
|
||||
lcopy bindist/icons $SR/icons 755 644
|
||||
lcopy bindist/manual $SR/manual 755 644
|
||||
lcopy bindist/cgi-bin $SR/cgi-bin 750 750
|
||||
if [ -f $SR/bin/envvars ]
|
||||
then
|
||||
echo "[Preserving existing envvars settings.]"
|
||||
cp -p $SR/bin/envvars ./envvars.orig
|
||||
HAD_ENVVARS=yes
|
||||
else
|
||||
HAD_ENVVARS=no
|
||||
fi
|
||||
lcopy bindist/bin $SR/bin 750 750
|
||||
if [ $HAD_ENVVARS = yes ]
|
||||
then
|
||||
cp -p ./envvars.orig $SR/bin/envvars
|
||||
rm ./envvars.orig
|
||||
fi
|
||||
lcopy bindist/lib $SR/lib 750 750
|
||||
if [ -d $SR/conf ]
|
||||
then
|
||||
echo "[Preserving existing configuration files.]"
|
||||
cp bindist/conf/*-std.conf $SR/conf/
|
||||
else
|
||||
lcopy bindist/conf $SR/conf 750 640
|
||||
sed -e "s%@default_dir@%$SR%" $SR/conf/httpd-std.conf > $SR/conf/httpd.conf
|
||||
fi
|
||||
if [ -d $SR/htdocs ]
|
||||
then
|
||||
echo "[Preserving existing htdocs directory.]"
|
||||
else
|
||||
lcopy bindist/htdocs $SR/htdocs 755 644
|
||||
fi
|
||||
if [ -d $SR/error ]
|
||||
then
|
||||
echo "[Preserving existing error documents directory.]"
|
||||
else
|
||||
lcopy bindist/error $SR/error 755 644
|
||||
fi
|
||||
|
||||
sed -e "s;^#!\@perlbin\@.*;#!$PERL;" -e "s;\@exp_installbuilddir\@;$SR/build;" \
|
||||
support/apxs.in > $SR/bin/apxs
|
||||
PRE=`grep "^prefix = " bindist/build/config_vars.mk`
|
||||
PRE=`echo $PRE | sed -e "s;prefix = ;;"`
|
||||
sed -e "s;$PRE;$SR;" bindist/build/config_vars.mk > $SR/build/config_vars.mk
|
||||
sed -e "s;^#!/.*;#!$PERL;" bindist/bin/dbmmanage > $SR/bin/dbmmanage
|
||||
sed -e "s%@default_dir@%$SR%" \
|
||||
-e "s%^HTTPD=.*$%HTTPD=\"$SR/bin/httpd -d $SR\"%" bindist/bin/apachectl > $SR/bin/apachectl
|
||||
sed -e "s%@default_dir@%$SR%" \
|
||||
bindist/bin/envvars-std > $SR/bin/envvars-std
|
||||
if [ $HAD_ENVVARS = no ]
|
||||
then
|
||||
cp -p $SR/bin/envvars-std $SR/bin/envvars
|
||||
fi
|
||||
|
||||
echo "Ready."
|
||||
echo " +--------------------------------------------------------+"
|
||||
echo " | You now have successfully installed the Apache @ver@ |"
|
||||
echo " | HTTP server. To verify that Apache actually works |"
|
||||
echo " | correctly you should first check the (initially |"
|
||||
echo " | created or preserved) configuration files: |"
|
||||
echo " | |"
|
||||
echo " | $SR/conf/httpd.conf"
|
||||
echo " | |"
|
||||
echo " | You should then be able to immediately fire up |"
|
||||
echo " | Apache the first time by running: |"
|
||||
echo " | |"
|
||||
echo " | $SR/bin/apachectl start "
|
||||
echo " | |"
|
||||
echo " | Thanks for using Apache. The Apache Group |"
|
||||
echo " | http://www.apache.org/ |"
|
||||
echo " +--------------------------------------------------------+"
|
||||
echo " "
|
123
build/install.sh
Executable file
123
build/install.sh
Executable file
|
@ -0,0 +1,123 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# install.sh -- install a program, script or datafile
|
||||
#
|
||||
# Based on `install-sh' from the X Consortium's X11R5 distribution
|
||||
# as of 89/12/18 which is freely available.
|
||||
# Cleaned up for Apache's Autoconf-style Interface (APACI)
|
||||
# by Ralf S. Engelschall <rse apache.org>
|
||||
|
||||
#
|
||||
# put in absolute paths if you don't have them in your path;
|
||||
# or use env. vars.
|
||||
#
|
||||
mvprog="${MVPROG-mv}"
|
||||
cpprog="${CPPROG-cp}"
|
||||
chmodprog="${CHMODPROG-chmod}"
|
||||
chownprog="${CHOWNPROG-chown}"
|
||||
chgrpprog="${CHGRPPROG-chgrp}"
|
||||
stripprog="${STRIPPROG-strip}"
|
||||
rmprog="${RMPROG-rm}"
|
||||
|
||||
#
|
||||
# parse argument line
|
||||
#
|
||||
instcmd="$mvprog"
|
||||
chmodcmd=""
|
||||
chowncmd=""
|
||||
chgrpcmd=""
|
||||
stripcmd=""
|
||||
rmcmd="$rmprog -f"
|
||||
mvcmd="$mvprog"
|
||||
ext=""
|
||||
src=""
|
||||
dst=""
|
||||
while [ "x$1" != "x" ]; do
|
||||
case $1 in
|
||||
-c) instcmd="$cpprog"
|
||||
shift; continue
|
||||
;;
|
||||
-m) chmodcmd="$chmodprog $2"
|
||||
shift; shift; continue
|
||||
;;
|
||||
-o) chowncmd="$chownprog $2"
|
||||
shift; shift; continue
|
||||
;;
|
||||
-g) chgrpcmd="$chgrpprog $2"
|
||||
shift; shift; continue
|
||||
;;
|
||||
-s) stripcmd="$stripprog"
|
||||
shift; continue
|
||||
;;
|
||||
-S) stripcmd="$stripprog $2"
|
||||
shift; shift; continue
|
||||
;;
|
||||
-e) ext="$2"
|
||||
shift; shift; continue
|
||||
;;
|
||||
*) if [ "x$src" = "x" ]; then
|
||||
src=$1
|
||||
else
|
||||
dst=$1
|
||||
fi
|
||||
shift; continue
|
||||
;;
|
||||
esac
|
||||
done
|
||||
if [ "x$src" = "x" ]; then
|
||||
echo "install.sh: no input file specified"
|
||||
exit 1
|
||||
fi
|
||||
if [ "x$dst" = "x" ]; then
|
||||
echo "install.sh: no destination specified"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#
|
||||
# If destination is a directory, append the input filename; if
|
||||
# your system does not like double slashes in filenames, you may
|
||||
# need to add some logic
|
||||
#
|
||||
if [ -d $dst ]; then
|
||||
dst="$dst/`basename $src`"
|
||||
fi
|
||||
|
||||
# Add a possible extension (such as ".exe") to src and dst
|
||||
src="$src$ext"
|
||||
dst="$dst$ext"
|
||||
|
||||
# Make a temp file name in the proper directory.
|
||||
dstdir=`dirname $dst`
|
||||
dsttmp=$dstdir/#inst.$$#
|
||||
|
||||
# Move or copy the file name to the temp name
|
||||
$instcmd $src $dsttmp
|
||||
|
||||
# And set any options; do chmod last to preserve setuid bits
|
||||
if [ "x$chowncmd" != "x" ]; then $chowncmd $dsttmp; fi
|
||||
if [ "x$chgrpcmd" != "x" ]; then $chgrpcmd $dsttmp; fi
|
||||
if [ "x$stripcmd" != "x" ]; then $stripcmd $dsttmp; fi
|
||||
if [ "x$chmodcmd" != "x" ]; then $chmodcmd $dsttmp; fi
|
||||
|
||||
# Now rename the file to the real destination.
|
||||
$rmcmd $dst
|
||||
$mvcmd $dsttmp $dst
|
||||
|
||||
exit 0
|
||||
|
286
build/installwinconf.awk
Normal file
286
build/installwinconf.awk
Normal file
|
@ -0,0 +1,286 @@
|
|||
#
|
||||
# InstallConf.awk Apache HTTP 2.x script to rewrite the @@ServerRoot@@
|
||||
# tags in httpd.conf.in to original\httpd.conf - then duplicate the
|
||||
# conf files to the 'live' configuration if they don't already exist.
|
||||
#
|
||||
# Note that we -don't- want the ARGV file list, so no additional {} blocks
|
||||
# are coded. Use explicit args (more reliable on Win32) and use the fact
|
||||
# that ARGV[] params are -not- '\' escaped to process the C:\Foo\Bar Win32
|
||||
# path format. Note that awk var=path would not succeed, since it -does-
|
||||
# escape backslashes in the assignment. Note also, a trailing space is
|
||||
# required for paths, or the trailing quote following the backslash is
|
||||
# escaped, rather than parsed.
|
||||
#
|
||||
BEGIN {
|
||||
domainname = ARGV[1];
|
||||
servername = ARGV[2];
|
||||
serveradmin = ARGV[3];
|
||||
serverport = ARGV[4];
|
||||
serversslport = ARGV[5];
|
||||
serverroot = ARGV[6];
|
||||
sourceroot = ARGV[7];
|
||||
|
||||
delete ARGV[7];
|
||||
delete ARGV[6];
|
||||
delete ARGV[5];
|
||||
delete ARGV[4];
|
||||
delete ARGV[3];
|
||||
delete ARGV[2];
|
||||
delete ARGV[1];
|
||||
|
||||
gsub( /\\/, "/", serverroot );
|
||||
gsub( /[ \/]+$/, "", serverroot );
|
||||
tstfl = serverroot "/logs/install.log"
|
||||
confroot = serverroot "/conf/";
|
||||
confdefault = confroot "original/";
|
||||
|
||||
if ( sourceroot != "docs/conf/" ) {
|
||||
sourceroot = serverroot "/" sourceroot;
|
||||
}
|
||||
|
||||
usertree = ENVIRON["USERPROFILE"]
|
||||
if ( usertree > "" ) {
|
||||
gsub( /\\/, "/", usertree );
|
||||
gsub( /\/[^\/]+$/, "", usertree );
|
||||
} else {
|
||||
usertree = "C:/Documents and Settings";
|
||||
}
|
||||
|
||||
print "Installing Apache HTTP Server 2.x with" >tstfl;
|
||||
print " DomainName = " domainname >tstfl;
|
||||
print " ServerName = " servername >tstfl;
|
||||
print " ServerAdmin = " serveradmin >tstfl;
|
||||
print " ServerPort = " serverport >tstfl;
|
||||
print " ServerSslPort = " serversslport >tstfl;
|
||||
print " ServerRoot = " serverroot >tstfl;
|
||||
|
||||
filelist["httpd.conf"] = "httpd.conf.in";
|
||||
filelist["httpd-autoindex.conf"] = "httpd-autoindex.conf.in";
|
||||
filelist["httpd-dav.conf"] = "httpd-dav.conf.in";
|
||||
filelist["httpd-default.conf"] = "httpd-default.conf.in";
|
||||
filelist["httpd-info.conf"] = "httpd-info.conf.in";
|
||||
filelist["httpd-languages.conf"] = "httpd-languages.conf.in";
|
||||
filelist["httpd-manual.conf"] = "httpd-manual.conf.in";
|
||||
filelist["httpd-mpm.conf"] = "httpd-mpm.conf.in";
|
||||
filelist["httpd-multilang-errordoc.conf"] = "httpd-multilang-errordoc.conf.in";
|
||||
filelist["httpd-ssl.conf"] = "httpd-ssl.conf.in";
|
||||
filelist["httpd-userdir.conf"] = "httpd-userdir.conf.in";
|
||||
filelist["httpd-vhosts.conf"] = "httpd-vhosts.conf.in";
|
||||
filelist["proxy-html.conf"] = "proxy-html.conf.in";
|
||||
|
||||
for ( conffile in filelist ) {
|
||||
|
||||
if ( conffile == "httpd.conf" ) {
|
||||
srcfl = sourceroot filelist[conffile];
|
||||
dstfl = confdefault conffile;
|
||||
bswarning = 1;
|
||||
} else {
|
||||
srcfl = sourceroot "extra/" filelist[conffile];
|
||||
dstfl = confdefault "extra/" conffile;
|
||||
bswarning = 0;
|
||||
}
|
||||
|
||||
while ( ( getline < srcfl ) > 0 ) {
|
||||
|
||||
if ( bswarning && /^$/ ) {
|
||||
print "#" > dstfl;
|
||||
print "# NOTE: Where filenames are specified, you must use forward slashes" > dstfl;
|
||||
print "# instead of backslashes (e.g., \"c:/apache\" instead of \"c:\\apache\")." > dstfl;
|
||||
print "# If a drive letter is omitted, the drive on which httpd.exe is located" > dstfl;
|
||||
print "# will be used by default. It is recommended that you always supply" > dstfl;
|
||||
print "# an explicit drive letter in absolute paths to avoid confusion." > dstfl;
|
||||
bswarning = 0;
|
||||
}
|
||||
if ( /@@LoadModule@@/ ) {
|
||||
print "LoadModule access_compat_module modules/mod_access_compat.so" > dstfl;
|
||||
print "LoadModule actions_module modules/mod_actions.so" > dstfl;
|
||||
print "LoadModule alias_module modules/mod_alias.so" > dstfl;
|
||||
print "LoadModule allowmethods_module modules/mod_allowmethods.so" > dstfl;
|
||||
print "LoadModule asis_module modules/mod_asis.so" > dstfl;
|
||||
print "LoadModule auth_basic_module modules/mod_auth_basic.so" > dstfl;
|
||||
print "#LoadModule auth_digest_module modules/mod_auth_digest.so" > dstfl;
|
||||
print "#LoadModule auth_form_module modules/mod_auth_form.so" > dstfl;
|
||||
print "#LoadModule authn_anon_module modules/mod_authn_anon.so" > dstfl;
|
||||
print "LoadModule authn_core_module modules/mod_authn_core.so" > dstfl;
|
||||
print "#LoadModule authn_dbd_module modules/mod_authn_dbd.so" > dstfl;
|
||||
print "#LoadModule authn_dbm_module modules/mod_authn_dbm.so" > dstfl;
|
||||
print "LoadModule authn_file_module modules/mod_authn_file.so" > dstfl;
|
||||
print "#LoadModule authn_socache_module modules/mod_authn_socache.so" > dstfl;
|
||||
print "#LoadModule authnz_fcgi_module modules/mod_authnz_fcgi.so" > dstfl;
|
||||
print "#LoadModule authnz_ldap_module modules/mod_authnz_ldap.so" > dstfl;
|
||||
print "LoadModule authz_core_module modules/mod_authz_core.so" > dstfl;
|
||||
print "#LoadModule authz_dbd_module modules/mod_authz_dbd.so" > dstfl;
|
||||
print "#LoadModule authz_dbm_module modules/mod_authz_dbm.so" > dstfl;
|
||||
print "LoadModule authz_groupfile_module modules/mod_authz_groupfile.so" > dstfl;
|
||||
print "LoadModule authz_host_module modules/mod_authz_host.so" > dstfl;
|
||||
print "#LoadModule authz_owner_module modules/mod_authz_owner.so" > dstfl;
|
||||
print "LoadModule authz_user_module modules/mod_authz_user.so" > dstfl;
|
||||
print "LoadModule autoindex_module modules/mod_autoindex.so" > dstfl;
|
||||
print "#LoadModule brotli_module modules/mod_brotli.so" > dstfl;
|
||||
print "#LoadModule buffer_module modules/mod_buffer.so" > dstfl;
|
||||
print "#LoadModule cache_module modules/mod_cache.so" > dstfl;
|
||||
print "#LoadModule cache_disk_module modules/mod_cache_disk.so" > dstfl;
|
||||
print "#LoadModule cache_socache_module modules/mod_cache_socache.so" > dstfl;
|
||||
print "#LoadModule cern_meta_module modules/mod_cern_meta.so" > dstfl;
|
||||
print "LoadModule cgi_module modules/mod_cgi.so" > dstfl;
|
||||
print "#LoadModule charset_lite_module modules/mod_charset_lite.so" > dstfl;
|
||||
print "#LoadModule data_module modules/mod_data.so" > dstfl;
|
||||
print "#LoadModule dav_module modules/mod_dav.so" > dstfl;
|
||||
print "#LoadModule dav_fs_module modules/mod_dav_fs.so" > dstfl;
|
||||
print "#LoadModule dav_lock_module modules/mod_dav_lock.so" > dstfl;
|
||||
print "#LoadModule dbd_module modules/mod_dbd.so" > dstfl;
|
||||
print "#LoadModule deflate_module modules/mod_deflate.so" > dstfl;
|
||||
print "LoadModule dir_module modules/mod_dir.so" > dstfl;
|
||||
print "#LoadModule dumpio_module modules/mod_dumpio.so" > dstfl;
|
||||
print "LoadModule env_module modules/mod_env.so" > dstfl;
|
||||
print "#LoadModule expires_module modules/mod_expires.so" > dstfl;
|
||||
print "#LoadModule ext_filter_module modules/mod_ext_filter.so" > dstfl;
|
||||
print "#LoadModule file_cache_module modules/mod_file_cache.so" > dstfl;
|
||||
print "#LoadModule filter_module modules/mod_filter.so" > dstfl;
|
||||
print "#LoadModule http2_module modules/mod_http2.so" > dstfl;
|
||||
print "#LoadModule headers_module modules/mod_headers.so" > dstfl;
|
||||
print "#LoadModule heartbeat_module modules/mod_heartbeat.so" > dstfl;
|
||||
print "#LoadModule heartmonitor_module modules/mod_heartmonitor.so" > dstfl;
|
||||
print "#LoadModule ident_module modules/mod_ident.so" > dstfl;
|
||||
print "#LoadModule imagemap_module modules/mod_imagemap.so" > dstfl;
|
||||
print "LoadModule include_module modules/mod_include.so" > dstfl;
|
||||
print "#LoadModule info_module modules/mod_info.so" > dstfl;
|
||||
print "LoadModule isapi_module modules/mod_isapi.so" > dstfl;
|
||||
print "#LoadModule lbmethod_bybusyness_module modules/mod_lbmethod_bybusyness.so" > dstfl;
|
||||
print "#LoadModule lbmethod_byrequests_module modules/mod_lbmethod_byrequests.so" > dstfl;
|
||||
print "#LoadModule lbmethod_bytraffic_module modules/mod_lbmethod_bytraffic.so" > dstfl;
|
||||
print "#LoadModule lbmethod_heartbeat_module modules/mod_lbmethod_heartbeat.so" > dstfl;
|
||||
print "#LoadModule ldap_module modules/mod_ldap.so" > dstfl;
|
||||
print "#LoadModule logio_module modules/mod_logio.so" > dstfl;
|
||||
print "LoadModule log_config_module modules/mod_log_config.so" > dstfl;
|
||||
print "#LoadModule log_debug_module modules/mod_log_debug.so" > dstfl;
|
||||
print "#LoadModule log_forensic_module modules/mod_log_forensic.so" > dstfl;
|
||||
print "#LoadModule lua_module modules/mod_lua.so" > dstfl;
|
||||
print "#LoadModule macro_module modules/mod_macro.so" > dstfl;
|
||||
print "#LoadModule md_module modules/mod_md.so" > dstfl;
|
||||
print "LoadModule mime_module modules/mod_mime.so" > dstfl;
|
||||
print "#LoadModule mime_magic_module modules/mod_mime_magic.so" > dstfl;
|
||||
print "LoadModule negotiation_module modules/mod_negotiation.so" > dstfl;
|
||||
print "#LoadModule proxy_module modules/mod_proxy.so" > dstfl;
|
||||
print "#LoadModule proxy_ajp_module modules/mod_proxy_ajp.so" > dstfl;
|
||||
print "#LoadModule proxy_balancer_module modules/mod_proxy_balancer.so" > dstfl;
|
||||
print "#LoadModule proxy_connect_module modules/mod_proxy_connect.so" > dstfl;
|
||||
print "#LoadModule proxy_express_module modules/mod_proxy_express.so" > dstfl;
|
||||
print "#LoadModule proxy_fcgi_module modules/mod_proxy_fcgi.so" > dstfl;
|
||||
print "#LoadModule proxy_ftp_module modules/mod_proxy_ftp.so" > dstfl;
|
||||
print "#LoadModule proxy_hcheck_module modules/mod_proxy_hcheck.so" > dstfl;
|
||||
print "#LoadModule proxy_html_module modules/mod_proxy_html.so" > dstfl;
|
||||
print "#LoadModule proxy_http_module modules/mod_proxy_http.so" > dstfl;
|
||||
print "#LoadModule proxy_http2_module modules/mod_proxy_http2.so" > dstfl;
|
||||
print "#LoadModule proxy_scgi_module modules/mod_proxy_scgi.so" > dstfl;
|
||||
print "#LoadModule proxy_uwsgi_module modules/mod_proxy_uwsgi.so" > dstfl;
|
||||
print "#LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so" > dstfl;
|
||||
print "#LoadModule ratelimit_module modules/mod_ratelimit.so" > dstfl;
|
||||
print "#LoadModule reflector_module modules/mod_reflector.so" > dstfl;
|
||||
print "#LoadModule remoteip_module modules/mod_remoteip.so" > dstfl;
|
||||
print "#LoadModule request_module modules/mod_request.so" > dstfl;
|
||||
print "#LoadModule reqtimeout_module modules/mod_reqtimeout.so" > dstfl;
|
||||
print "#LoadModule rewrite_module modules/mod_rewrite.so" > dstfl;
|
||||
print "#LoadModule sed_module modules/mod_sed.so" > dstfl;
|
||||
print "#LoadModule session_module modules/mod_session.so" > dstfl;
|
||||
print "#LoadModule session_cookie_module modules/mod_session_cookie.so" > dstfl;
|
||||
print "#LoadModule session_crypto_module modules/mod_session_crypto.so" > dstfl;
|
||||
print "#LoadModule session_dbd_module modules/mod_session_dbd.so" > dstfl;
|
||||
print "LoadModule setenvif_module modules/mod_setenvif.so" > dstfl;
|
||||
print "#LoadModule slotmem_plain_module modules/mod_slotmem_plain.so" > dstfl;
|
||||
print "#LoadModule slotmem_shm_module modules/mod_slotmem_shm.so" > dstfl;
|
||||
print "#LoadModule socache_dbm_module modules/mod_socache_dbm.so" > dstfl;
|
||||
print "#LoadModule socache_memcache_module modules/mod_socache_memcache.so" > dstfl;
|
||||
print "#LoadModule socache_redis_module modules/mod_socache_redis.so" > dstfl;
|
||||
print "#LoadModule socache_shmcb_module modules/mod_socache_shmcb.so" > dstfl;
|
||||
print "#LoadModule speling_module modules/mod_speling.so" > dstfl;
|
||||
print "#LoadModule ssl_module modules/mod_ssl.so" > dstfl;
|
||||
print "#LoadModule status_module modules/mod_status.so" > dstfl;
|
||||
print "#LoadModule substitute_module modules/mod_substitute.so" > dstfl;
|
||||
print "#LoadModule unique_id_module modules/mod_unique_id.so" > dstfl;
|
||||
print "#LoadModule userdir_module modules/mod_userdir.so" > dstfl;
|
||||
print "#LoadModule usertrack_module modules/mod_usertrack.so" > dstfl;
|
||||
print "#LoadModule version_module modules/mod_version.so" > dstfl;
|
||||
print "#LoadModule vhost_alias_module modules/mod_vhost_alias.so" > dstfl;
|
||||
print "#LoadModule watchdog_module modules/mod_watchdog.so" > dstfl;
|
||||
print "#LoadModule xml2enc_module modules/mod_xml2enc.so" > dstfl;
|
||||
continue;
|
||||
}
|
||||
if ( /^ServerRoot / ) {
|
||||
print "Define SRVROOT \"" serverroot "\"" > dstfl;
|
||||
print "" > dstfl;
|
||||
}
|
||||
gsub( /@@ServerRoot@@/, "\${SRVROOT}" );
|
||||
gsub( /@exp_cgidir@/, "\${SRVROOT}" "/cgi-bin" );
|
||||
gsub( /@exp_sysconfdir@/, "\${SRVROOT}" "/conf" );
|
||||
gsub( /@exp_errordir@/, "\${SRVROOT}" "/error" );
|
||||
gsub( /@exp_htdocsdir@/, "\${SRVROOT}" "/htdocs" );
|
||||
gsub( /@exp_iconsdir@/, "\${SRVROOT}" "/icons" );
|
||||
gsub( /@exp_manualdir@/, "\${SRVROOT}" "/manual" );
|
||||
gsub( /@exp_runtimedir@/, "\${SRVROOT}" "/logs" );
|
||||
if ( gsub( /@exp_logfiledir@/, "\${SRVROOT}" "/logs" ) ||
|
||||
gsub( /@rel_logfiledir@/, "logs" ) ) {
|
||||
gsub( /_log"/, ".log\"" )
|
||||
}
|
||||
gsub( /@rel_runtimedir@/, "logs" );
|
||||
gsub( /@rel_sysconfdir@/, "conf" );
|
||||
gsub( /\/home\/\*\/public_html/, \
|
||||
usertree "/*/My Documents/My Website" );
|
||||
gsub( /UserDir public_html/, "UserDir \"My Documents/My Website\"" );
|
||||
gsub( /@@ServerName@@|www.example.com/, servername );
|
||||
gsub( /@@ServerAdmin@@|you@example.com/, serveradmin );
|
||||
gsub( /@@DomainName@@|example.com/, domainname );
|
||||
gsub( /@@Port@@/, serverport );
|
||||
gsub( /@@SSLPort@@|443/, serversslport );
|
||||
print $0 > dstfl;
|
||||
}
|
||||
close(srcfl);
|
||||
|
||||
if ( close(dstfl) >= 0 ) {
|
||||
print "Rewrote " srcfl "\n to " dstfl > tstfl;
|
||||
if ( sourceroot != "docs/conf/" ) {
|
||||
gsub(/\//, "\\", srcfl);
|
||||
if (system("del 2>NUL \"" srcfl "\"")) {
|
||||
print "Failed to remove " srcfl > tstfl;
|
||||
} else {
|
||||
print "Successfully removed " srcfl > tstfl;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
print "Failed to rewrite " srcfl "\n to " dstfl > tstfl;
|
||||
}
|
||||
filelist[conffile] = "extra/";
|
||||
}
|
||||
|
||||
filelist["httpd.conf"] = "";
|
||||
filelist["charset.conv"] = "";
|
||||
filelist["magic"] = "";
|
||||
filelist["mime.types"] = "";
|
||||
|
||||
for ( conffile in filelist ) {
|
||||
srcfl = confdefault filelist[conffile] conffile;
|
||||
dstfl = confroot filelist[conffile] conffile;
|
||||
if ( ( getline < dstfl ) < 0 ) {
|
||||
while ( ( getline < srcfl ) > 0 ) {
|
||||
print $0 > dstfl;
|
||||
}
|
||||
print "Duplicated " srcfl "\n to " dstfl > tstfl;
|
||||
} else {
|
||||
print "Existing file " dstfl " preserved" > tstfl;
|
||||
}
|
||||
close(srcfl);
|
||||
close(dstfl);
|
||||
}
|
||||
|
||||
if ( sourceroot != "docs/conf/" ) {
|
||||
srcfl = confdefault "installwinconf.awk";
|
||||
gsub(/\//, "\\", srcfl);
|
||||
if (system("del 2>NUL \"" srcfl "\"")) {
|
||||
print "Failed to remove " srcfl > tstfl;
|
||||
} else {
|
||||
print "Successfully removed " srcfl > tstfl;
|
||||
}
|
||||
}
|
||||
close(tstfl);
|
||||
}
|
||||
|
105
build/instdso.sh
Executable file
105
build/instdso.sh
Executable file
|
@ -0,0 +1,105 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# instdso.sh - install Apache DSO modules
|
||||
#
|
||||
# we use this instead of libtool --install because:
|
||||
# 1) on a few platforms libtool doesn't install DSOs exactly like we'd
|
||||
# want (weird names, doesn't remove DSO first)
|
||||
# 2) we never want the .la files copied, so we might as well copy
|
||||
# the .so files ourselves
|
||||
|
||||
if test "$#" != "3"; then
|
||||
echo "wrong number of arguments to instdso.sh"
|
||||
echo "Usage: instdso.sh SH_LIBTOOL-value dso-name path-to-modules"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
SH_LIBTOOL=`echo $1 | sed -e 's/^SH_LIBTOOL=//'`
|
||||
DSOARCHIVE=$2
|
||||
DSOARCHIVE_BASENAME=`basename $2`
|
||||
TARGETDIR=$3
|
||||
DSOBASE=`echo $DSOARCHIVE_BASENAME | sed -e 's/\.la$//'`
|
||||
TARGET_NAME="$DSOBASE.so"
|
||||
|
||||
SYS=`uname -s`
|
||||
|
||||
if test "$SYS" = "AIX"
|
||||
then
|
||||
# on AIX, shared libraries remain in storage even when
|
||||
# all processes using them have exited; standard practice
|
||||
# prior to installing a shared library is to rm -f first
|
||||
CMD="rm -f $TARGETDIR/$TARGET_NAME"
|
||||
echo $CMD
|
||||
$CMD || exit $?
|
||||
fi
|
||||
|
||||
case $SYS in
|
||||
SunOS|HP-UX)
|
||||
INSTALL_CMD=cp
|
||||
;;
|
||||
*)
|
||||
type install >/dev/null 2>&1 && INSTALL_CMD=install || INSTALL_CMD=cp
|
||||
;;
|
||||
esac
|
||||
|
||||
CMD="$SH_LIBTOOL --mode=install $INSTALL_CMD $DSOARCHIVE $TARGETDIR/"
|
||||
echo $CMD
|
||||
$CMD || exit $?
|
||||
|
||||
if test "$SYS" = "OS/2"
|
||||
then
|
||||
# on OS/2, aplibtool --install doesn't copy the .la files & we can't
|
||||
# rename DLLs to have a .so extension or they won't load so none of the
|
||||
# steps below make sense.
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if test -s "$TARGETDIR/$DSOARCHIVE_BASENAME"
|
||||
then
|
||||
DLNAME=`sed -n "/^dlname=/{s/.*='\([^']*\)'/\1/;p;}" $TARGETDIR/$DSOARCHIVE_BASENAME`
|
||||
LIBRARY_NAMES=`sed -n "/^library_names/{s/library_names='\([^']*\)'/\1/;p;}" $TARGETDIR/$DSOARCHIVE_BASENAME`
|
||||
LIBRARY_NAMES=`echo $LIBRARY_NAMES | sed -e "s/ *$DLNAME//g"`
|
||||
fi
|
||||
|
||||
if test -z "$DLNAME"
|
||||
then
|
||||
echo "Warning! dlname not found in $TARGETDIR/$DSOARCHIVE_BASENAME."
|
||||
echo "Assuming installing a .so rather than a libtool archive."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if test -n "$LIBRARY_NAMES"
|
||||
then
|
||||
for f in $LIBRARY_NAMES
|
||||
do
|
||||
rm -f $TARGETDIR/$f
|
||||
done
|
||||
fi
|
||||
|
||||
if test "$DLNAME" != "$TARGET_NAME"
|
||||
then
|
||||
mv $TARGETDIR/$DLNAME $TARGETDIR/$TARGET_NAME
|
||||
fi
|
||||
|
||||
rm -f $TARGETDIR/$DSOARCHIVE_BASENAME
|
||||
rm -f $TARGETDIR/$DSOBASE.a
|
||||
rm -f $TARGETDIR/lib$DSOBASE.a
|
||||
rm -f $TARGETDIR/lib$TARGET_NAME
|
||||
|
||||
exit 0
|
22
build/library.mk
Normal file
22
build/library.mk
Normal file
|
@ -0,0 +1,22 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
LTLIBRARY_OBJECTS = $(LTLIBRARY_SOURCES:.c=.lo) $(LTLIBRARY_OBJECTS_X)
|
||||
|
||||
$(LTLIBRARY_NAME): $(LTLIBRARY_OBJECTS) $(LTLIBRARY_DEPENDENCIES)
|
||||
$(LINK) -static $(LTLIBRARY_LDFLAGS) $(LTLIBRARY_OBJECTS) $(LTLIBRARY_LIBADD)
|
23
build/ltlib.mk
Normal file
23
build/ltlib.mk
Normal file
|
@ -0,0 +1,23 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
TARGETS = $(LTLIBRARY_NAME)
|
||||
|
||||
include $(top_builddir)/build/rules.mk
|
||||
include $(top_srcdir)/build/library.mk
|
||||
|
11375
build/ltmain.sh
Normal file
11375
build/ltmain.sh
Normal file
File diff suppressed because it is too large
Load diff
162
build/make_exports.awk
Normal file
162
build/make_exports.awk
Normal file
|
@ -0,0 +1,162 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
BEGIN {
|
||||
printf("/*\n")
|
||||
printf(" * THIS FILE WAS AUTOGENERATED BY make_exports.awk\n")
|
||||
printf(" *\n")
|
||||
printf(" * This is an ugly hack that needs to be here, so\n")
|
||||
printf(" * that libtool will link all of the APR functions\n")
|
||||
printf(" * into server regardless of whether the base server\n")
|
||||
printf(" * uses them.\n")
|
||||
printf(" */\n")
|
||||
printf("\n")
|
||||
|
||||
for (i = 1; i < ARGC; i++) {
|
||||
file = ARGV[i]
|
||||
sub("([^/]*[/])*", "", file)
|
||||
printf("#include \"%s\"\n", file)
|
||||
}
|
||||
|
||||
printf("\n")
|
||||
printf("const void *ap_ugly_hack = NULL;\n")
|
||||
printf("\n")
|
||||
|
||||
TYPE_NORMAL = 0
|
||||
TYPE_HEADER = 1
|
||||
|
||||
stackptr = 0
|
||||
}
|
||||
|
||||
function push(line) {
|
||||
stack[stackptr] = line
|
||||
stackptr++
|
||||
}
|
||||
|
||||
function do_output() {
|
||||
printf("/*\n")
|
||||
printf(" * %s\n", FILENAME)
|
||||
printf(" */\n")
|
||||
|
||||
for (i = 0; i < stackptr; i++) {
|
||||
printf("%s\n", stack[i])
|
||||
}
|
||||
|
||||
stackptr = 0
|
||||
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
function enter_scope(type) {
|
||||
scope++
|
||||
scope_type[scope] = type
|
||||
scope_stack[scope] = stackptr
|
||||
delete scope_used[scope]
|
||||
}
|
||||
|
||||
function leave_scope() {
|
||||
used = scope_used[scope]
|
||||
|
||||
if (!used)
|
||||
stackptr = scope_stack[scope]
|
||||
|
||||
scope--
|
||||
if (used) {
|
||||
scope_used[scope] = 1
|
||||
|
||||
if (!scope)
|
||||
do_output()
|
||||
}
|
||||
}
|
||||
|
||||
function add_symbol(symbol) {
|
||||
if (!index(symbol, "#")) {
|
||||
push("const void *ap_hack_" symbol " = (const void *)" symbol ";")
|
||||
scope_used[scope] = 1
|
||||
}
|
||||
}
|
||||
|
||||
/^[ \t]*AP[RU]?_(CORE_)?DECLARE[^(]*[(][^)]*[)]([^ ]* )*[^(]+[(]/ {
|
||||
sub("[ \t]*AP[RU]?_(CORE_)?DECLARE[^(]*[(][^)]*[)][ \t]*", "")
|
||||
sub("[(].*", "")
|
||||
sub("([^ ]* (^([ \t]*[(])))+", "")
|
||||
|
||||
add_symbol($0)
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*AP_DECLARE_HOOK[^(]*[(][^)]*/ {
|
||||
split($0, args, ",")
|
||||
symbol = args[2]
|
||||
sub("^[ \t]+", "", symbol)
|
||||
sub("[ \t]+$", "", symbol)
|
||||
|
||||
add_symbol("ap_hook_" symbol)
|
||||
add_symbol("ap_hook_get_" symbol)
|
||||
add_symbol("ap_run_" symbol)
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_POOL_DECLARE_ACCESSOR[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_POOL_DECLARE_ACCESSOR[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_pool_get")
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_DECLARE_INHERIT_SET[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_DECLARE_INHERIT_SET[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_inherit_set")
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_DECLARE_INHERIT_UNSET[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_DECLARE_INHERIT_UNSET[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_inherit_unset")
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*if(ndef| !defined[(])([^_]*_)*H/ {
|
||||
enter_scope(TYPE_HEADER)
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*if([n]?def)? / {
|
||||
enter_scope(TYPE_NORMAL)
|
||||
push($0)
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*endif/ {
|
||||
if (scope_type[scope] == TYPE_NORMAL)
|
||||
push($0)
|
||||
|
||||
leave_scope()
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*else/ {
|
||||
push($0)
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*elif/ {
|
||||
push($0)
|
||||
next
|
||||
}
|
||||
|
||||
|
118
build/make_nw_export.awk
Normal file
118
build/make_nw_export.awk
Normal file
|
@ -0,0 +1,118 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
# Based on apr's make_export.awk, which is
|
||||
# based on Ryan Bloom's make_export.pl
|
||||
#
|
||||
|
||||
BEGIN {
|
||||
}
|
||||
|
||||
function add_symbol(sym_name) {
|
||||
sub(" ", "", sym_name)
|
||||
exports[++idx] = sym_name
|
||||
}
|
||||
|
||||
# List of functions that we don't support, yet??
|
||||
#/ap_some_name/{next}
|
||||
/ap_mpm_pod_/{next}
|
||||
|
||||
/^[ \t]*(AP|DAV|CACHE)([RU]|_CORE)?_DECLARE[^(]*[(][^)]*[)]([^ ]* )*[^(]+[(]/ {
|
||||
sub("[ \t]*(AP|DAV|CACHE)([RU]|_CORE)?_DECLARE[^(]*[(][^)]*[)][ \t]*", "")
|
||||
sub("[(].*", "")
|
||||
sub("([^ ]* (^([ \t]*[(])))+", "")
|
||||
add_symbol($0)
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*AP_DECLARE_HOOK[^(]*[(][^)]*/ {
|
||||
split($0, args, ",")
|
||||
symbol = args[2]
|
||||
sub("^[ \t]+", "", symbol)
|
||||
sub("[ \t]+$", "", symbol)
|
||||
add_symbol("ap_hook_" symbol)
|
||||
add_symbol("ap_hook_get_" symbol)
|
||||
add_symbol("ap_run_" symbol)
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*AP[RU]?_DECLARE_EXTERNAL_HOOK[^(]*[(][^)]*/ {
|
||||
split($0, args, ",")
|
||||
prefix = args[1]
|
||||
sub("^.*[(]", "", prefix)
|
||||
symbol = args[4]
|
||||
sub("^[ \t]+", "", symbol)
|
||||
sub("[ \t]+$", "", symbol)
|
||||
add_symbol(prefix "_hook_" symbol)
|
||||
add_symbol(prefix "_hook_get_" symbol)
|
||||
add_symbol(prefix "_run_" symbol)
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_POOL_DECLARE_ACCESSOR[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_POOL_DECLARE_ACCESSOR[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_pool_get")
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_DECLARE_INHERIT_SET[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_DECLARE_INHERIT_SET[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_inherit_set")
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*APR_DECLARE_INHERIT_UNSET[^(]*[(][^)]*[)]/ {
|
||||
sub("[ \t]*APR_DECLARE_INHERIT_UNSET[^(]*[(]", "", $0)
|
||||
sub("[)].*$", "", $0)
|
||||
add_symbol("apr_" $0 "_inherit_unset")
|
||||
next
|
||||
}
|
||||
|
||||
/^[ \t]*(extern[ \t]+)?AP[RU]?_DECLARE_DATA .*;/ {
|
||||
gsub(/[*;\n\r]/, "")
|
||||
gsub(/\[.*\]/, "")
|
||||
add_symbol($NF)
|
||||
}
|
||||
|
||||
|
||||
END {
|
||||
printf("Added %d symbols to export list.\n", idx) > "/dev/stderr"
|
||||
# sort symbols with shell sort
|
||||
increment = int(idx / 2)
|
||||
while (increment > 0) {
|
||||
for (i = increment+1; i <= idx; i++) {
|
||||
j = i
|
||||
temp = exports[i]
|
||||
while ((j >= increment+1) && (exports[j-increment] > temp)) {
|
||||
exports[j] = exports[j-increment]
|
||||
j -= increment
|
||||
}
|
||||
exports[j] = temp
|
||||
}
|
||||
if (increment == 2)
|
||||
increment = 1
|
||||
else
|
||||
increment = int(increment*5/11)
|
||||
}
|
||||
# print the array
|
||||
printf(" (%s)\n", EXPPREFIX)
|
||||
while (x < idx - 1) {
|
||||
printf(" %s,\n", exports[++x])
|
||||
}
|
||||
printf(" %s\n", exports[++x])
|
||||
}
|
||||
|
75
build/make_var_export.awk
Normal file
75
build/make_var_export.awk
Normal file
|
@ -0,0 +1,75 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# Based on apr's make_export.awk, which is
|
||||
# based on Ryan Bloom's make_export.pl
|
||||
|
||||
/^#[ \t]*if(def)? (AP[RU]?_|!?defined).*/ {
|
||||
if (old_filename != FILENAME) {
|
||||
if (old_filename != "") printf("%s", line)
|
||||
macro_no = 0
|
||||
found = 0
|
||||
count = 0
|
||||
old_filename = FILENAME
|
||||
line = ""
|
||||
}
|
||||
macro_stack[macro_no++] = macro
|
||||
macro = substr($0, length($1)+2)
|
||||
count++
|
||||
line = line "#ifdef " macro "\n"
|
||||
next
|
||||
}
|
||||
|
||||
/^#[ \t]*endif/ {
|
||||
if (count > 0) {
|
||||
count--
|
||||
line = line "#endif /* " macro " */\n"
|
||||
macro = macro_stack[--macro_no]
|
||||
}
|
||||
if (count == 0) {
|
||||
if (found != 0) {
|
||||
printf("%s", line)
|
||||
}
|
||||
line = ""
|
||||
}
|
||||
next
|
||||
}
|
||||
|
||||
function add_symbol (sym_name) {
|
||||
if (count) {
|
||||
found++
|
||||
}
|
||||
for (i = 0; i < count; i++) {
|
||||
line = line "\t"
|
||||
}
|
||||
line = line sym_name "\n"
|
||||
|
||||
if (count == 0) {
|
||||
printf("%s", line)
|
||||
line = ""
|
||||
}
|
||||
}
|
||||
|
||||
/^[ \t]*(extern[ \t]+)?AP[RU]?_DECLARE_DATA .*;$/ {
|
||||
varname = $NF;
|
||||
gsub( /[*;]/, "", varname);
|
||||
gsub( /\[.*\]/, "", varname);
|
||||
add_symbol(varname);
|
||||
}
|
||||
|
||||
END {
|
||||
printf("%s", line)
|
||||
}
|
161
build/mkconfNW.awk
Normal file
161
build/mkconfNW.awk
Normal file
|
@ -0,0 +1,161 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
BEGIN {
|
||||
A["ServerRoot"] = "\${SRVROOT}"
|
||||
A["Port"] = PORT
|
||||
A["SSLPort"] = SSLPORT
|
||||
A["cgidir"] = "cgi-bin"
|
||||
A["logfiledir"] = "logs"
|
||||
A["htdocsdir"] = "htdocs"
|
||||
A["sysconfdir"] = "conf"
|
||||
A["iconsdir"] = "icons"
|
||||
A["manualdir"] = "manual"
|
||||
A["runtimedir"] = "logs"
|
||||
A["errordir"] = "error"
|
||||
A["proxycachedir"] = "proxy"
|
||||
|
||||
B["htdocsdir"] = A["ServerRoot"]"/"A["htdocsdir"]
|
||||
B["iconsdir"] = A["ServerRoot"]"/"A["iconsdir"]
|
||||
B["manualdir"] = A["ServerRoot"]"/"A["manualdir"]
|
||||
B["errordir"] = A["ServerRoot"]"/"A["errordir"]
|
||||
B["proxycachedir"] = A["ServerRoot"]"/"A["proxycachedir"]
|
||||
B["cgidir"] = A["ServerRoot"]"/"A["cgidir"]
|
||||
B["logfiledir"] = A["logfiledir"]
|
||||
B["sysconfdir"] = A["sysconfdir"]
|
||||
B["runtimedir"] = A["runtimedir"]
|
||||
}
|
||||
|
||||
/^ServerRoot / {
|
||||
print "Define SRVROOT \"SYS:/" BDIR "\""
|
||||
print ""
|
||||
}
|
||||
/@@LoadModule@@/ {
|
||||
print "#LoadModule access_compat_module modules/accesscompat.nlm"
|
||||
print "#LoadModule actions_module modules/actions.nlm"
|
||||
print "#LoadModule allowmethods_module modules/allowmethods.nlm"
|
||||
print "#LoadModule auth_basic_module modules/authbasc.nlm"
|
||||
print "#LoadModule auth_digest_module modules/authdigt.nlm"
|
||||
print "#LoadModule authn_anon_module modules/authnano.nlm"
|
||||
print "#LoadModule authn_dbd_module modules/authndbd.nlm"
|
||||
print "#LoadModule authn_dbm_module modules/authndbm.nlm"
|
||||
print "#LoadModule authn_file_module modules/authnfil.nlm"
|
||||
print "#LoadModule authz_dbd_module modules/authzdbd.nlm"
|
||||
print "#LoadModule authz_dbm_module modules/authzdbm.nlm"
|
||||
print "#LoadModule authz_groupfile_module modules/authzgrp.nlm"
|
||||
print "#LoadModule authz_user_module modules/authzusr.nlm"
|
||||
print "#LoadModule authnz_ldap_module modules/authnzldap.nlm"
|
||||
print "#LoadModule ldap_module modules/utilldap.nlm"
|
||||
print "#LoadModule asis_module modules/mod_asis.nlm"
|
||||
print "LoadModule autoindex_module modules/autoindex.nlm"
|
||||
print "#LoadModule buffer_module modules/modbuffer.nlm"
|
||||
print "#LoadModule cern_meta_module modules/cernmeta.nlm"
|
||||
print "LoadModule cgi_module modules/mod_cgi.nlm"
|
||||
print "#LoadModule data_module modules/mod_data.nlm"
|
||||
print "#LoadModule dav_module modules/mod_dav.nlm"
|
||||
print "#LoadModule dav_fs_module modules/moddavfs.nlm"
|
||||
print "#LoadModule dav_lock_module modules/moddavlk.nlm"
|
||||
print "#LoadModule expires_module modules/expires.nlm"
|
||||
print "#LoadModule filter_module modules/mod_filter.nlm"
|
||||
print "#LoadModule ext_filter_module modules/extfiltr.nlm"
|
||||
print "#LoadModule file_cache_module modules/filecach.nlm"
|
||||
print "#LoadModule headers_module modules/headers.nlm"
|
||||
print "#LoadModule ident_module modules/modident.nlm"
|
||||
print "#LoadModule imagemap_module modules/imagemap.nlm"
|
||||
print "#LoadModule info_module modules/info.nlm"
|
||||
print "#LoadModule log_forensic_module modules/forensic.nlm"
|
||||
print "#LoadModule logio_module modules/modlogio.nlm"
|
||||
print "#LoadModule mime_magic_module modules/mimemagi.nlm"
|
||||
print "#LoadModule proxy_module modules/proxy.nlm"
|
||||
print "#LoadModule proxy_connect_module modules/proxycon.nlm"
|
||||
print "#LoadModule proxy_http_module modules/proxyhtp.nlm"
|
||||
print "#LoadModule proxy_ftp_module modules/proxyftp.nlm"
|
||||
print "#LoadModule rewrite_module modules/rewrite.nlm"
|
||||
print "#LoadModule speling_module modules/speling.nlm"
|
||||
print "#LoadModule status_module modules/status.nlm"
|
||||
print "#LoadModule unique_id_module modules/uniqueid.nlm"
|
||||
print "#LoadModule usertrack_module modules/usertrk.nlm"
|
||||
print "#LoadModule version_module modules/modversion.nlm"
|
||||
print "#LoadModule userdir_module modules/userdir.nlm"
|
||||
print "#LoadModule vhost_alias_module modules/vhost.nlm"
|
||||
if (MODSSL) {
|
||||
print "#LoadModule socache_dbm_module modules/socachedbm.nlm"
|
||||
print "#LoadModule socache_shmcb_module modules/socacheshmcb.nlm"
|
||||
print "#LoadModule ssl_module modules/mod_ssl.nlm"
|
||||
}
|
||||
print ""
|
||||
next
|
||||
}
|
||||
|
||||
match ($0,/^#SSLSessionCache +"dbm:/) {
|
||||
sub(/^#/, "")
|
||||
}
|
||||
|
||||
match ($0,/^SSLSessionCache +"shmcb:/) {
|
||||
sub(/^SSLSessionCache/, "#SSLSessionCache")
|
||||
}
|
||||
|
||||
match ($0,/^# Mutex +default +file:@rel_runtimedir@/) {
|
||||
sub(/file:@rel_runtimedir@/, "default")
|
||||
}
|
||||
|
||||
match ($0,/@@.*@@/) {
|
||||
s=substr($0,RSTART+2,RLENGTH-4)
|
||||
sub(/@@.*@@/,A[s],$0)
|
||||
}
|
||||
|
||||
match ($0,/@rel_.*@/) {
|
||||
s=substr($0,RSTART+5,RLENGTH-6)
|
||||
sub(/@rel_.*@/,A[s],$0)
|
||||
}
|
||||
|
||||
match ($0,/@exp_.*@/) {
|
||||
s=substr($0,RSTART+5,RLENGTH-6)
|
||||
sub(/@exp_.*@/,B[s],$0)
|
||||
}
|
||||
|
||||
match ($0,/@nonssl_.*@/) {
|
||||
s=substr($0,RSTART+8,RLENGTH-9)
|
||||
sub(/@nonssl_.*@/,B[s],$0)
|
||||
}
|
||||
|
||||
match ($0,/^<IfModule cgid_module>$/) {
|
||||
print "#"
|
||||
print "# CGIMapExtension: Technique for locating the interpreter for CGI scripts."
|
||||
print "# The special interpreter path \"OS\" can be used for NLM CGIs."
|
||||
print "#"
|
||||
print "#CGIMapExtension OS .cgi"
|
||||
print "CGIMapExtension SYS:/perl/Perlcgi/perlcgi.nlm .pl"
|
||||
print ""
|
||||
}
|
||||
|
||||
{
|
||||
print
|
||||
}
|
||||
|
||||
END {
|
||||
if ((ARGV[1] ~ /httpd.conf.in/) && !BSDSKT) {
|
||||
print ""
|
||||
print "#"
|
||||
print "# SecureListen: Allows you to securely bind Apache to specific IP addresses "
|
||||
print "# and/or ports (mod_nwssl)."
|
||||
print "#"
|
||||
print "# Change this to SecureListen on specific IP addresses as shown below to "
|
||||
print "# prevent Apache from glomming onto all bound IP addresses (0.0.0.0)"
|
||||
print "#"
|
||||
print "#SecureListen "SSLPORT" \"SSL CertificateDNS\""
|
||||
}
|
||||
print ""
|
||||
}
|
90
build/mkdep.perl
Normal file
90
build/mkdep.perl
Normal file
|
@ -0,0 +1,90 @@
|
|||
#!/usr/bin/perl
|
||||
#
|
||||
# Created: Thu Aug 15 11:57:33 1996 too
|
||||
# Last modified: Mon Dec 27 09:23:56 1999 too
|
||||
#
|
||||
# Copyright (c) 1996-1999 Tomi Ollila. All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
|
||||
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
|
||||
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
|
||||
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
|
||||
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
die "Usage: mkdep CPP-command [CPP options] file1 [file2...]\n"
|
||||
if ($#ARGV < 1);
|
||||
|
||||
$cmdl = shift(@ARGV);
|
||||
|
||||
$cmdl = "$cmdl " . shift (@ARGV) while ($ARGV[0] =~ /^-[A-Z]/);
|
||||
|
||||
while ($file = shift(@ARGV))
|
||||
{
|
||||
$file =~ s/\.o$/.c/;
|
||||
|
||||
open(F, "$cmdl $file|");
|
||||
|
||||
&parseout;
|
||||
|
||||
close(F);
|
||||
}
|
||||
|
||||
|
||||
sub initinit
|
||||
{
|
||||
%used = ();
|
||||
$of = $file;
|
||||
$of =~ s/\.c$/.lo/;
|
||||
$str = "$of:\t$file";
|
||||
$len = length $str;
|
||||
}
|
||||
|
||||
sub initstr
|
||||
{
|
||||
$str = "\t";
|
||||
$len = length $str;
|
||||
}
|
||||
|
||||
sub parseout
|
||||
{
|
||||
&initinit;
|
||||
while (<F>)
|
||||
{
|
||||
s/\\\\/\//g;
|
||||
next unless (/^# [0-9]* "(.*\.h)"/);
|
||||
|
||||
next if ($1 =~ /^\//);
|
||||
|
||||
next if $used{$1};
|
||||
|
||||
$used{$1} = 1;
|
||||
|
||||
$nlen = length($1) + 1;
|
||||
|
||||
if ($len + $nlen > 72)
|
||||
{
|
||||
print $str, "\\\n";
|
||||
&initstr;
|
||||
$str = $str . $1;
|
||||
}
|
||||
else { $str = $str . " " . $1; }
|
||||
|
||||
$len += $nlen;
|
||||
|
||||
}
|
||||
print $str, "\n";
|
||||
}
|
48
build/mkdir.sh
Executable file
48
build/mkdir.sh
Executable file
|
@ -0,0 +1,48 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# mkdir.sh -- make directory hierarchy
|
||||
#
|
||||
# Based on `mkinstalldirs' from Noah Friedman <friedman@prep.ai.mit.edu>
|
||||
# as of 1994-03-25, which was placed in the Public Domain.
|
||||
# Cleaned up for Apache's Autoconf-style Interface (APACI)
|
||||
# by Ralf S. Engelschall <rse apache.org>
|
||||
|
||||
umask 022
|
||||
errstatus=0
|
||||
for file in ${1+"$@"} ; do
|
||||
set fnord `echo ":$file" |\
|
||||
sed -e 's/^:\//%/' -e 's/^://' -e 's/\// /g' -e 's/^%/\//'`
|
||||
shift
|
||||
pathcomp=
|
||||
for d in ${1+"$@"}; do
|
||||
pathcomp="$pathcomp$d"
|
||||
case "$pathcomp" in
|
||||
-* ) pathcomp=./$pathcomp ;;
|
||||
?: ) pathcomp="$pathcomp/"
|
||||
continue ;;
|
||||
esac
|
||||
if test ! -d "$pathcomp"; then
|
||||
echo "mkdir $pathcomp" 1>&2
|
||||
mkdir "$pathcomp" || errstatus=$?
|
||||
fi
|
||||
pathcomp="$pathcomp/"
|
||||
done
|
||||
done
|
||||
exit $errstatus
|
||||
|
67
build/nw_export.inc
Normal file
67
build/nw_export.inc
Normal file
|
@ -0,0 +1,67 @@
|
|||
/* Must include ap_config.h first so that we can redefine
|
||||
the standard prototypes macros after it messes with
|
||||
them. */
|
||||
#include "ap_config.h"
|
||||
|
||||
/* Define all of the standard prototype macros as themselves
|
||||
so that httpd.h will not mess with them. This allows
|
||||
them to pass untouched so that the AWK script can pick
|
||||
them out of the preprocessed result file. */
|
||||
#undef AP_DECLARE
|
||||
#define AP_DECLARE AP_DECLARE
|
||||
#undef AP_CORE_DECLARE
|
||||
#define AP_CORE_DECLARE AP_CORE_DECLARE
|
||||
#undef AP_DECLARE_NONSTD
|
||||
#define AP_DECLARE_NONSTD AP_DECLARE_NONSTD
|
||||
#undef AP_CORE_DECLARE_NONSTD
|
||||
#define AP_CORE_DECLARE_NONSTD AP_CORE_DECLARE_NONSTD
|
||||
#undef AP_DECLARE_HOOK
|
||||
#define AP_DECLARE_HOOK AP_DECLARE_HOOK
|
||||
#undef AP_DECLARE_DATA
|
||||
#define AP_DECLARE_DATA AP_DECLARE_DATA
|
||||
#undef APR_DECLARE_OPTIONAL_FN
|
||||
#define APR_DECLARE_OPTIONAL_FN APR_DECLARE_OPTIONAL_FN
|
||||
#undef APR_DECLARE_EXTERNAL_HOOK
|
||||
#define APR_DECLARE_EXTERNAL_HOOK APR_DECLARE_EXTERNAL_HOOK
|
||||
#undef APACHE_OS_H
|
||||
|
||||
#include "httpd.h"
|
||||
|
||||
/* Preprocess all of the standard HTTPD headers. */
|
||||
#include "ap_compat.h"
|
||||
#include "ap_listen.h"
|
||||
#include "ap_mmn.h"
|
||||
#include "ap_mpm.h"
|
||||
#include "ap_provider.h"
|
||||
#include "ap_release.h"
|
||||
#include "ap_expr.h"
|
||||
#include "http_config.h"
|
||||
#include "http_connection.h"
|
||||
#include "http_core.h"
|
||||
#include "http_log.h"
|
||||
#include "http_main.h"
|
||||
#include "http_protocol.h"
|
||||
#include "http_request.h"
|
||||
#include "http_ssl.h"
|
||||
#include "http_vhost.h"
|
||||
#include "mpm_common.h"
|
||||
#include "ap_regex.h"
|
||||
#include "scoreboard.h"
|
||||
#include "util_cfgtree.h"
|
||||
#include "util_charset.h"
|
||||
#include "util_cookies.h"
|
||||
#include "util_ebcdic.h"
|
||||
#include "util_fcgi.h"
|
||||
#include "util_filter.h"
|
||||
/*#include "util_ldap.h"*/
|
||||
#include "util_md5.h"
|
||||
#include "util_mutex.h"
|
||||
#include "util_script.h"
|
||||
#include "util_time.h"
|
||||
#include "util_varbuf.h"
|
||||
#include "util_xml.h"
|
||||
|
||||
#include "mod_core.h"
|
||||
#include "mod_auth.h"
|
||||
#include "mod_watchdog.h"
|
||||
|
62
build/nw_ver.awk
Normal file
62
build/nw_ver.awk
Normal file
|
@ -0,0 +1,62 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
BEGIN {
|
||||
# fetch Apache version numbers from input file and write them to STDOUT
|
||||
|
||||
while ((getline < ARGV[1]) > 0) {
|
||||
if (match ($0, /^#define AP_SERVER_COPYRIGHT \\/)) {
|
||||
if (((getline < ARGV[1]) > 0) && (split($0, c, "\"") == 3)) {
|
||||
copyright_str = c[2];
|
||||
}
|
||||
}
|
||||
else if (match ($0, /^#define AP_SERVER_MAJORVERSION_NUMBER /)) {
|
||||
ver_major = $3;
|
||||
}
|
||||
else if (match ($0, /^#define AP_SERVER_MINORVERSION_NUMBER /)) {
|
||||
ver_minor = $3;
|
||||
}
|
||||
else if (match ($0, /^#define AP_SERVER_PATCHLEVEL_NUMBER/)) {
|
||||
ver_patch = $3;
|
||||
}
|
||||
else if (match ($0, /^#define AP_SERVER_DEVBUILD_BOOLEAN/)) {
|
||||
ver_devbuild = $3;
|
||||
}
|
||||
}
|
||||
|
||||
if (ver_devbuild) {
|
||||
ver_dev = "-dev"
|
||||
if (ARGV[2]) {
|
||||
while ((getline < ARGV[2]) > 0) {
|
||||
if (match ($0, /^\/repos\/asf\/!svn\/ver\/[0-9]+\/httpd\/httpd\/(trunk|branches\/[0-9]\.[0-9]\.x)$/)) {
|
||||
gsub(/^\/repos\/asf\/!svn\/ver\/|\/httpd\/httpd\/(trunk|branches\/[0-9]\.[0-9]\.x)$/, "", $0)
|
||||
ver_dev = svn_rev = "-r" $0
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ver_nlm = ver_major "," ver_minor "," ver_patch;
|
||||
ver_str = ver_major "." ver_minor "." ver_patch ver_dev;
|
||||
|
||||
print "VERSION = " ver_nlm "";
|
||||
print "VERSION_STR = " ver_str "";
|
||||
print "VERSION_MAJMIN = " ver_major ver_minor "";
|
||||
print "COPYRIGHT_STR = " copyright_str "";
|
||||
print "SVN_REVISION = " svn_rev "";
|
||||
|
||||
}
|
||||
|
||||
|
16
build/pkg/README
Normal file
16
build/pkg/README
Normal file
|
@ -0,0 +1,16 @@
|
|||
The script in this directory will attempt to build a Solaris package
|
||||
out of a source tree for httpd.
|
||||
|
||||
To build a package, make sure you are in the root of the source tree,
|
||||
and run:
|
||||
|
||||
build/pkg/buildpkg.sh
|
||||
|
||||
A Solaris package called httpd-<version>-<architecture>-local.gz will be
|
||||
created in the root of the source tree.
|
||||
|
||||
By default, the script will attempt to find a system installed version of
|
||||
APR and APR-util v1. You may override the location of apr or apr-util like so:
|
||||
|
||||
build/pkg/buildpkg.sh --with-apr=some/other/path --with-apr-util=some/other/path
|
||||
|
94
build/pkg/buildpkg.sh
Executable file
94
build/pkg/buildpkg.sh
Executable file
|
@ -0,0 +1,94 @@
|
|||
#!/bin/sh
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
|
||||
# buildpkg.sh: This script builds a Solaris PKG from the source tree
|
||||
# provided.
|
||||
|
||||
LAYOUT=Apache
|
||||
PREFIX=/usr/local/apache2
|
||||
TEMPDIR=/var/tmp/$USER/httpd-root
|
||||
rm -rf $TEMPDIR
|
||||
|
||||
apr_config=`which apr-1-config`
|
||||
apu_config=`which apu-1-config`
|
||||
|
||||
while test $# -gt 0
|
||||
do
|
||||
# Normalize
|
||||
case "$1" in
|
||||
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
|
||||
*) optarg= ;;
|
||||
esac
|
||||
|
||||
case "$1" in
|
||||
--with-apr=*)
|
||||
apr_config=$optarg
|
||||
;;
|
||||
esac
|
||||
|
||||
case "$1" in
|
||||
--with-apr-util=*)
|
||||
apu_config=$optarg
|
||||
;;
|
||||
esac
|
||||
|
||||
shift
|
||||
done
|
||||
|
||||
if [ ! -f "$apr_config" -a ! -f "$apr_config/configure.in" ]; then
|
||||
echo "The apr source directory / apr-1-config could not be found"
|
||||
echo "Usage: buildpkg [--with-apr=[dir|file]] [--with-apr-util=[dir|file]]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -f "$apu_config" -a ! -f "$apu_config/configure.in" ]; then
|
||||
echo "The apu source directory / apu-1-config could not be found"
|
||||
echo "Usage: buildpkg [--with-apr=[dir|file]] [--with-apr-util=[dir|file]]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
./configure --enable-layout=$LAYOUT \
|
||||
--with-apr=$apr_config \
|
||||
--with-apr-util=$apu_config \
|
||||
--enable-mods-shared=all \
|
||||
--with-devrandom \
|
||||
--with-ldap --enable-ldap --enable-authnz-ldap \
|
||||
--enable-cache --enable-disk-cache --enable-mem-cache \
|
||||
--enable-ssl --with-ssl \
|
||||
--enable-deflate --enable-cgid \
|
||||
--enable-proxy --enable-proxy-connect \
|
||||
--enable-proxy-http --enable-proxy-ftp
|
||||
|
||||
make
|
||||
make install DESTDIR=$TEMPDIR
|
||||
. build/pkg/pkginfo
|
||||
cp build/pkg/pkginfo $TEMPDIR$PREFIX
|
||||
|
||||
current=`pwd`
|
||||
cd $TEMPDIR$PREFIX
|
||||
echo "i pkginfo=./pkginfo" > prototype
|
||||
find . -print | grep -v ./prototype | grep -v ./pkginfo | pkgproto | awk '{print $1" "$2" "$3" "$4" root bin"}' >> prototype
|
||||
mkdir $TEMPDIR/pkg
|
||||
pkgmk -r $TEMPDIR$PREFIX -d $TEMPDIR/pkg
|
||||
|
||||
cd $current
|
||||
pkgtrans -s $TEMPDIR/pkg $current/$NAME-$VERSION-$ARCH-local
|
||||
gzip $current/$NAME-$VERSION-$ARCH-local
|
||||
|
||||
rm -rf $TEMPDIR
|
||||
|
11
build/pkg/pkginfo.in
Normal file
11
build/pkg/pkginfo.in
Normal file
|
@ -0,0 +1,11 @@
|
|||
PKG="ASFhttpd"
|
||||
NAME="httpd"
|
||||
ARCH="@target_cpu@"
|
||||
VERSION="@HTTPD_VERSION@"
|
||||
CATEGORY="application"
|
||||
VENDOR="Apache Software Foundation"
|
||||
EMAIL="dev@httpd.apache.org"
|
||||
PSTAMP="dev@httpd.apache.org"
|
||||
BASEDIR="@prefix@"
|
||||
CLASSES="none"
|
||||
|
23
build/program.mk
Normal file
23
build/program.mk
Normal file
|
@ -0,0 +1,23 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
PROGRAM_OBJECTS = $(PROGRAM_SOURCES:.c=.lo)
|
||||
|
||||
$(PROGRAM_NAME): $(PROGRAM_DEPENDENCIES) $(PROGRAM_OBJECTS)
|
||||
$(PROGRAM_PRELINK)
|
||||
$(LINK) $(PROGRAM_LDFLAGS) $(PROGRAM_OBJECTS) $(PROGRAM_LDADD)
|
100
build/rpm/htcacheclean.init
Executable file
100
build/rpm/htcacheclean.init
Executable file
|
@ -0,0 +1,100 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# htcacheclean Startup script for the Apache cache cleaner
|
||||
#
|
||||
# chkconfig: - 85 15
|
||||
# description: The Apache htcacheclean daemon maintains and prunes the
|
||||
# size of the mod_cache_disk cache directory.
|
||||
# processname: htcacheclean
|
||||
# pidfile: /var/log/httpd/htcacheclean.pid
|
||||
# config: /etc/sysconfig/htcacheclean
|
||||
#
|
||||
### BEGIN INIT INFO
|
||||
# Provides: htcacheclean
|
||||
# Required-Start: $local_fs $remote_fs $network
|
||||
# Required-Stop: $local_fs $remote_fs $network
|
||||
# Should-Start: httpd
|
||||
# Short-Description: start and stop Apache htcacheclean
|
||||
# Description: The Apache htcacheclean daemon maintains a mod_cache_disk
|
||||
### END INIT INFO
|
||||
|
||||
# Source function library.
|
||||
. /etc/rc.d/init.d/functions
|
||||
|
||||
# What were we called? Multiple instances of the same daemon can be
|
||||
# created by creating suitably named symlinks to this startup script
|
||||
prog=$(basename $0 | sed -e 's/^[SK][0-9][0-9]//')
|
||||
|
||||
if [ -f /etc/sysconfig/${prog} ]; then
|
||||
. /etc/sysconfig/${prog}
|
||||
fi
|
||||
|
||||
# Path to htcacheclean, server binary, and short-form for messages.
|
||||
htcacheclean=${HTTPD-/usr/sbin/htcacheclean}
|
||||
lockfile=${LOCKFILE-/var/lock/subsys/${prog}}
|
||||
pidfile=/var/run/${prog}.pid
|
||||
interval=${INTERVAL-10}
|
||||
cachepath=${CACHEPATH-/var/cache/httpd/cache-root}
|
||||
limit=${LIMIT-100M}
|
||||
RETVAL=0
|
||||
|
||||
start() {
|
||||
echo -n $"Starting $prog: "
|
||||
daemon --pidfile=${pidfile} $htcacheclean -d "$interval" -p "$cachepath" -l "$limit" -P "$pidfile" $OPTIONS
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL = 0 ] && touch ${lockfile}
|
||||
return $RETVAL
|
||||
}
|
||||
stop() {
|
||||
echo -n $"Stopping $prog: "
|
||||
killproc -p ${pidfile} $htcacheclean
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL = 0 ] && rm -f ${lockfile}
|
||||
}
|
||||
|
||||
# See how we were called.
|
||||
case "$1" in
|
||||
start)
|
||||
start
|
||||
;;
|
||||
stop)
|
||||
stop
|
||||
;;
|
||||
status)
|
||||
status -p ${pidfile} $htcacheclean
|
||||
RETVAL=$?
|
||||
;;
|
||||
restart)
|
||||
stop
|
||||
start
|
||||
;;
|
||||
condrestart)
|
||||
if status -p ${pidfile} $htcacheclean >&/dev/null; then
|
||||
stop
|
||||
start
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
echo $"Usage: $prog {start|stop|restart|condrestart|status|help}"
|
||||
exit 1
|
||||
esac
|
||||
|
||||
exit $RETVAL
|
155
build/rpm/httpd.init
Executable file
155
build/rpm/httpd.init
Executable file
|
@ -0,0 +1,155 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# httpd Startup script for the Apache Web Server
|
||||
#
|
||||
# chkconfig: - 85 15
|
||||
# description: The Apache HTTP Server is an efficient and extensible \
|
||||
# server implementing the current HTTP standards.
|
||||
# processname: httpd
|
||||
# pidfile: /var/run/httpd.pid
|
||||
# config: /etc/sysconfig/httpd
|
||||
#
|
||||
### BEGIN INIT INFO
|
||||
# Provides: httpd
|
||||
# Required-Start: $local_fs $remote_fs $network $named
|
||||
# Required-Stop: $local_fs $remote_fs $network
|
||||
# Should-Start: distcache
|
||||
# Short-Description: start and stop Apache HTTP Server
|
||||
# Description: The Apache HTTP Server is an extensible server
|
||||
# implementing the current HTTP standards.
|
||||
### END INIT INFO
|
||||
|
||||
# Source function library.
|
||||
. /etc/rc.d/init.d/functions
|
||||
|
||||
# What were we called? Multiple instances of the same daemon can be
|
||||
# created by creating suitably named symlinks to this startup script
|
||||
prog=$(basename $0 | sed -e 's/^[SK][0-9][0-9]//')
|
||||
|
||||
if [ -f /etc/sysconfig/${prog} ]; then
|
||||
. /etc/sysconfig/${prog}
|
||||
fi
|
||||
|
||||
# Start httpd in the C locale by default.
|
||||
HTTPD_LANG=${HTTPD_LANG-"C"}
|
||||
|
||||
# This will prevent initlog from swallowing up a pass-phrase prompt if
|
||||
# mod_ssl needs a pass-phrase from the user.
|
||||
INITLOG_ARGS=""
|
||||
|
||||
# Set HTTPD=/usr/sbin/httpd.worker in /etc/sysconfig/httpd to use a server
|
||||
# with the thread-based "worker" MPM; BE WARNED that some modules may not
|
||||
# work correctly with a thread-based MPM; notably PHP will refuse to start.
|
||||
|
||||
httpd=${HTTPD-/usr/sbin/httpd}
|
||||
pidfile=${PIDFILE-/var/run/${prog}.pid}
|
||||
lockfile=${LOCKFILE-/var/lock/subsys/${prog}}
|
||||
RETVAL=0
|
||||
|
||||
# check for 1.3 configuration
|
||||
check13 () {
|
||||
CONFFILE=/etc/httpd/conf/httpd.conf
|
||||
GONE="(ServerType|BindAddress|Port|AddModule|ClearModuleList|"
|
||||
GONE="${GONE}AgentLog|RefererLog|RefererIgnore|FancyIndexing|"
|
||||
GONE="${GONE}AccessConfig|ResourceConfig)"
|
||||
if grep -Eiq "^[[:space:]]*($GONE)" $CONFFILE; then
|
||||
echo
|
||||
echo 1>&2 " Apache 1.3 configuration directives found"
|
||||
echo 1>&2 " please read @docdir@/migration.html"
|
||||
failure "Apache 1.3 config directives test"
|
||||
echo
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
# The semantics of these two functions differ from the way apachectl does
|
||||
# things -- attempting to start while running is a failure, and shutdown
|
||||
# when not running is also a failure. So we just do it the way init scripts
|
||||
# are expected to behave here.
|
||||
start() {
|
||||
echo -n $"Starting $prog: "
|
||||
check13 || exit 1
|
||||
LANG=$HTTPD_LANG daemon --pidfile=${pidfile} $httpd $OPTIONS
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL = 0 ] && touch ${lockfile}
|
||||
return $RETVAL
|
||||
}
|
||||
stop() {
|
||||
echo -n $"Stopping $prog: "
|
||||
killproc -p ${pidfile} -d 10 $httpd
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL = 0 ] && rm -f ${lockfile} ${pidfile}
|
||||
}
|
||||
reload() {
|
||||
echo -n $"Reloading $prog: "
|
||||
check13 || exit 1
|
||||
killproc -p ${pidfile} $httpd -HUP
|
||||
RETVAL=$?
|
||||
echo
|
||||
}
|
||||
|
||||
# See how we were called.
|
||||
case "$1" in
|
||||
start)
|
||||
start
|
||||
;;
|
||||
stop)
|
||||
stop
|
||||
;;
|
||||
status)
|
||||
if ! test -f ${pidfile}; then
|
||||
echo $prog is stopped
|
||||
RETVAL=3
|
||||
else
|
||||
status -p ${pidfile} $httpd
|
||||
RETVAL=$?
|
||||
fi
|
||||
;;
|
||||
restart)
|
||||
stop
|
||||
start
|
||||
;;
|
||||
condrestart)
|
||||
if test -f ${pidfile} && status -p ${pidfile} $httpd >&/dev/null; then
|
||||
stop
|
||||
start
|
||||
fi
|
||||
;;
|
||||
reload)
|
||||
reload
|
||||
;;
|
||||
configtest)
|
||||
LANG=$HTTPD_LANG $httpd $OPTIONS -t
|
||||
RETVAL=$?
|
||||
;;
|
||||
graceful)
|
||||
echo -n $"Gracefully restarting $prog: "
|
||||
LANG=$HTTPD_LANG $httpd $OPTIONS -k $@
|
||||
RETVAL=$?
|
||||
echo
|
||||
;;
|
||||
*)
|
||||
echo $"Usage: $prog {start|stop|restart|condrestart|reload|status|graceful|help|configtest}"
|
||||
exit 1
|
||||
esac
|
||||
|
||||
exit $RETVAL
|
||||
|
8
build/rpm/httpd.logrotate
Normal file
8
build/rpm/httpd.logrotate
Normal file
|
@ -0,0 +1,8 @@
|
|||
/var/log/httpd/*log {
|
||||
missingok
|
||||
notifempty
|
||||
sharedscripts
|
||||
postrotate
|
||||
/sbin/service httpd graceful 2> /dev/null || true
|
||||
endscript
|
||||
}
|
494
build/rpm/httpd.spec.in
Normal file
494
build/rpm/httpd.spec.in
Normal file
|
@ -0,0 +1,494 @@
|
|||
%define contentdir /var/www
|
||||
%define suexec_caller apache
|
||||
%define mmn APACHE_MMN
|
||||
|
||||
Summary: Apache HTTP Server
|
||||
Name: httpd
|
||||
Version: APACHE_VERSION
|
||||
Release: APACHE_RELEASE
|
||||
URL: http://httpd.apache.org/
|
||||
Vendor: Apache Software Foundation
|
||||
Source0: http://www.apache.org/dist/httpd/httpd-%{version}.tar.bz2
|
||||
License: Apache License, Version 2.0
|
||||
Group: System Environment/Daemons
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
BuildRequires: autoconf, perl, pkgconfig, findutils
|
||||
BuildRequires: zlib-devel, libselinux-devel, libuuid-devel
|
||||
BuildRequires: apr-devel >= 1.4.0, apr-util-devel >= 1.4.0, pcre-devel >= 5.0
|
||||
Requires: initscripts >= 8.36, /etc/mime.types
|
||||
Obsoletes: httpd-suexec
|
||||
Requires(pre): /usr/sbin/useradd
|
||||
Requires(post): chkconfig
|
||||
Provides: webserver
|
||||
Provides: mod_dav = %{version}-%{release}, httpd-suexec = %{version}-%{release}
|
||||
Provides: httpd-mmn = %{mmn}
|
||||
|
||||
%description
|
||||
Apache is a powerful, full-featured, efficient, and freely-available
|
||||
Web server. Apache is also the most popular Web server on the
|
||||
Internet.
|
||||
|
||||
%package devel
|
||||
Group: Development/Libraries
|
||||
Summary: Development tools for the Apache HTTP server.
|
||||
Obsoletes: secureweb-devel, apache-devel
|
||||
Requires: apr-devel, apr-util-devel, pkgconfig, libtool
|
||||
Requires: httpd = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
The httpd-devel package contains the APXS binary and other files
|
||||
that you need to build Dynamic Shared Objects (DSOs) for the
|
||||
Apache HTTP Server.
|
||||
|
||||
If you are installing the Apache HTTP server and you want to be
|
||||
able to compile or develop additional modules for Apache, you need
|
||||
to install this package.
|
||||
|
||||
%package manual
|
||||
Group: Documentation
|
||||
Summary: Documentation for the Apache HTTP server.
|
||||
Requires: httpd = :%{version}-%{release}
|
||||
Obsoletes: secureweb-manual, apache-manual
|
||||
|
||||
%description manual
|
||||
The httpd-manual package contains the complete manual and
|
||||
reference guide for the Apache HTTP server. The information can
|
||||
also be found at http://httpd.apache.org/docs/.
|
||||
|
||||
%package tools
|
||||
Group: System Environment/Daemons
|
||||
Summary: Tools for use with the Apache HTTP Server
|
||||
|
||||
%description tools
|
||||
The httpd-tools package contains tools which can be used with
|
||||
the Apache HTTP Server.
|
||||
|
||||
%package -n mod_authnz_ldap
|
||||
Group: System Environment/Daemons
|
||||
Summary: LDAP modules for the Apache HTTP server
|
||||
BuildRequires: openldap-devel
|
||||
Requires: httpd = %{version}-%{release}, httpd-mmn = %{mmn}, apr-util-ldap
|
||||
|
||||
%description -n mod_authnz_ldap
|
||||
The mod_authnz_ldap module for the Apache HTTP server provides
|
||||
authentication and authorization against an LDAP server, while
|
||||
mod_ldap provides an LDAP cache.
|
||||
|
||||
%package -n mod_lua
|
||||
Group: System Environment/Daemons
|
||||
Summary: Lua language module for the Apache HTTP server
|
||||
BuildRequires: lua-devel
|
||||
Requires: httpd = %{version}-%{release}, httpd-mmn = %{mmn}
|
||||
|
||||
%description -n mod_lua
|
||||
The mod_lua module for the Apache HTTP server allows the server to be
|
||||
extended with scripts written in the Lua programming language.
|
||||
|
||||
%package -n mod_proxy_html
|
||||
Group: System Environment/Daemons
|
||||
Summary: Proxy HTML filter modules for the Apache HTTP server
|
||||
Epoch: 1
|
||||
BuildRequires: libxml2-devel
|
||||
Requires: httpd = 0:%{version}-%{release}, httpd-mmn = %{mmn}
|
||||
|
||||
%description -n mod_proxy_html
|
||||
The mod_proxy_html module for the Apache HTTP server provides
|
||||
a filter to rewrite HTML links within web content when used within
|
||||
a reverse proxy environment. The mod_xml2enc module provides
|
||||
enhanced charset/internationalisation support for mod_proxy_html.
|
||||
|
||||
%package -n mod_ssl
|
||||
Group: System Environment/Daemons
|
||||
Summary: SSL/TLS module for the Apache HTTP server
|
||||
Epoch: 1
|
||||
BuildRequires: openssl-devel
|
||||
Requires(post): openssl, /bin/cat
|
||||
Requires(pre): httpd
|
||||
Requires: httpd = 0:%{version}-%{release}, httpd-mmn = %{mmn}
|
||||
|
||||
%description -n mod_ssl
|
||||
The mod_ssl module provides strong cryptography for the Apache Web
|
||||
server via the Secure Sockets Layer (SSL) and Transport Layer
|
||||
Security (TLS) protocols.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
# Safety check: prevent build if defined MMN does not equal upstream MMN.
|
||||
vmmn=`echo MODULE_MAGIC_NUMBER_MAJOR | cpp -include include/ap_mmn.h | sed -n '
|
||||
/^2/p'`
|
||||
if test "x${vmmn}" != "x%{mmn}"; then
|
||||
: Error: Upstream MMN is now ${vmmn}, packaged MMN is %{mmn}.
|
||||
: Update the mmn macro and rebuild.
|
||||
exit 1
|
||||
fi
|
||||
|
||||
%build
|
||||
# forcibly prevent use of bundled apr, apr-util, pcre
|
||||
rm -rf srclib/{apr,apr-util,pcre}
|
||||
|
||||
%configure \
|
||||
--enable-layout=RPM \
|
||||
--libdir=%{_libdir} \
|
||||
--sysconfdir=%{_sysconfdir}/httpd/conf \
|
||||
--includedir=%{_includedir}/httpd \
|
||||
--libexecdir=%{_libdir}/httpd/modules \
|
||||
--datadir=%{contentdir} \
|
||||
--with-installbuilddir=%{_libdir}/httpd/build \
|
||||
--enable-mpms-shared=all \
|
||||
--with-apr=%{_prefix} --with-apr-util=%{_prefix} \
|
||||
--enable-suexec --with-suexec \
|
||||
--with-suexec-caller=%{suexec_caller} \
|
||||
--with-suexec-docroot=%{contentdir} \
|
||||
--with-suexec-logfile=%{_localstatedir}/log/httpd/suexec.log \
|
||||
--with-suexec-bin=%{_sbindir}/suexec \
|
||||
--with-suexec-uidmin=500 --with-suexec-gidmin=100 \
|
||||
--enable-pie \
|
||||
--with-pcre \
|
||||
--enable-mods-shared=all \
|
||||
--enable-ssl --with-ssl --enable-bucketeer \
|
||||
--enable-case-filter --enable-case-filter-in \
|
||||
--disable-imagemap
|
||||
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
|
||||
# for holding mod_dav lock database
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/dav
|
||||
|
||||
# create a prototype session cache
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/cache/mod_ssl
|
||||
touch $RPM_BUILD_ROOT%{_localstatedir}/cache/mod_ssl/scache.{dir,pag,sem}
|
||||
|
||||
# Make the MMN accessible to module packages
|
||||
echo %{mmn} > $RPM_BUILD_ROOT%{_includedir}/httpd/.mmn
|
||||
|
||||
# Set up /var directories
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/httpd
|
||||
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/cache/httpd/cache-root
|
||||
|
||||
# symlinks for /etc/httpd
|
||||
ln -s ../..%{_localstatedir}/log/httpd $RPM_BUILD_ROOT/etc/httpd/logs
|
||||
ln -s ../..%{_localstatedir}/run $RPM_BUILD_ROOT/etc/httpd/run
|
||||
ln -s ../..%{_libdir}/httpd/modules $RPM_BUILD_ROOT/etc/httpd/modules
|
||||
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d
|
||||
|
||||
# install SYSV init stuff
|
||||
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
|
||||
install -m755 ./build/rpm/httpd.init \
|
||||
$RPM_BUILD_ROOT/etc/rc.d/init.d/httpd
|
||||
install -m755 ./build/rpm/htcacheclean.init \
|
||||
$RPM_BUILD_ROOT/etc/rc.d/init.d/htcacheclean
|
||||
|
||||
# install log rotation stuff
|
||||
mkdir -p $RPM_BUILD_ROOT/etc/logrotate.d
|
||||
install -m644 ./build/rpm/httpd.logrotate \
|
||||
$RPM_BUILD_ROOT/etc/logrotate.d/httpd
|
||||
|
||||
# Remove unpackaged files
|
||||
rm -rf $RPM_BUILD_ROOT%{_libdir}/httpd/modules/*.exp \
|
||||
$RPM_BUILD_ROOT%{contentdir}/cgi-bin/*
|
||||
|
||||
# Make suexec a+rw so it can be stripped. %%files lists real permissions
|
||||
chmod 755 $RPM_BUILD_ROOT%{_sbindir}/suexec
|
||||
|
||||
%pre
|
||||
# Add the "apache" user
|
||||
/usr/sbin/useradd -c "Apache" -u 48 \
|
||||
-s /sbin/nologin -r -d %{contentdir} apache 2> /dev/null || :
|
||||
|
||||
%post
|
||||
# Register the httpd service
|
||||
/sbin/chkconfig --add httpd
|
||||
/sbin/chkconfig --add htcacheclean
|
||||
|
||||
%preun
|
||||
if [ $1 = 0 ]; then
|
||||
/sbin/service httpd stop > /dev/null 2>&1
|
||||
/sbin/service htcacheclean stop > /dev/null 2>&1
|
||||
/sbin/chkconfig --del httpd
|
||||
/sbin/chkconfig --del htcacheclean
|
||||
fi
|
||||
|
||||
%post -n mod_ssl
|
||||
umask 077
|
||||
|
||||
if [ ! -f %{_sysconfdir}/httpd/conf/server.key ] ; then
|
||||
%{_bindir}/openssl genrsa -rand /proc/apm:/proc/cpuinfo:/proc/dma:/proc/filesystems:/proc/interrupts:/proc/ioports:/proc/pci:/proc/rtc:/proc/uptime 1024 > %{_sysconfdir}/httpd/conf/server.key 2> /dev/null
|
||||
fi
|
||||
|
||||
FQDN=`hostname`
|
||||
if [ "x${FQDN}" = "x" ]; then
|
||||
FQDN=localhost.localdomain
|
||||
fi
|
||||
|
||||
if [ ! -f %{_sysconfdir}/httpd/conf/server.crt ] ; then
|
||||
cat << EOF | %{_bindir}/openssl req -new -key %{_sysconfdir}/httpd/conf/server.key -x509 -days 365 -out %{_sysconfdir}/httpd/conf/server.crt 2>/dev/null
|
||||
--
|
||||
SomeState
|
||||
SomeCity
|
||||
SomeOrganization
|
||||
SomeOrganizationalUnit
|
||||
${FQDN}
|
||||
root@${FQDN}
|
||||
EOF
|
||||
fi
|
||||
|
||||
%check
|
||||
# Check the built modules are all PIC
|
||||
if readelf -d $RPM_BUILD_ROOT%{_libdir}/httpd/modules/*.so | grep TEXTREL; then
|
||||
: modules contain non-relocatable code
|
||||
exit 1
|
||||
fi
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
|
||||
%doc ABOUT_APACHE README CHANGES LICENSE NOTICE
|
||||
|
||||
%dir %{_sysconfdir}/httpd
|
||||
%{_sysconfdir}/httpd/modules
|
||||
%{_sysconfdir}/httpd/logs
|
||||
%{_sysconfdir}/httpd/run
|
||||
%dir %{_sysconfdir}/httpd/conf
|
||||
%dir %{_sysconfdir}/httpd/conf.d
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/httpd.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/magic
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/mime.types
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-autoindex.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-dav.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-default.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-info.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-languages.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-manual.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-mpm.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-multilang-errordoc.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-userdir.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-vhosts.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/proxy-html.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-autoindex.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-dav.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-default.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-info.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-languages.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-manual.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-mpm.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-multilang-errordoc.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-userdir.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-vhosts.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/proxy-html.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/httpd.conf
|
||||
|
||||
%config %{_sysconfdir}/logrotate.d/httpd
|
||||
%config %{_sysconfdir}/rc.d/init.d/httpd
|
||||
%config %{_sysconfdir}/rc.d/init.d/htcacheclean
|
||||
|
||||
%{_sbindir}/fcgistarter
|
||||
%{_sbindir}/htcacheclean
|
||||
%{_sbindir}/httpd
|
||||
%{_sbindir}/apachectl
|
||||
%attr(4510,root,%{suexec_caller}) %{_sbindir}/suexec
|
||||
|
||||
%dir %{_libdir}/httpd
|
||||
%dir %{_libdir}/httpd/modules
|
||||
%{_libdir}/httpd/modules/mod_access_compat.so
|
||||
%{_libdir}/httpd/modules/mod_actions.so
|
||||
%{_libdir}/httpd/modules/mod_alias.so
|
||||
%{_libdir}/httpd/modules/mod_allowmethods.so
|
||||
%{_libdir}/httpd/modules/mod_asis.so
|
||||
%{_libdir}/httpd/modules/mod_auth_basic.so
|
||||
%{_libdir}/httpd/modules/mod_auth_digest.so
|
||||
%{_libdir}/httpd/modules/mod_auth_form.so
|
||||
%{_libdir}/httpd/modules/mod_authn_anon.so
|
||||
%{_libdir}/httpd/modules/mod_authn_core.so
|
||||
%{_libdir}/httpd/modules/mod_authn_dbd.so
|
||||
%{_libdir}/httpd/modules/mod_authn_dbm.so
|
||||
%{_libdir}/httpd/modules/mod_authn_file.so
|
||||
%{_libdir}/httpd/modules/mod_authn_socache.so
|
||||
%{_libdir}/httpd/modules/mod_authz_core.so
|
||||
%{_libdir}/httpd/modules/mod_authz_dbd.so
|
||||
%{_libdir}/httpd/modules/mod_authz_dbm.so
|
||||
%{_libdir}/httpd/modules/mod_authz_groupfile.so
|
||||
%{_libdir}/httpd/modules/mod_authz_host.so
|
||||
%{_libdir}/httpd/modules/mod_authz_owner.so
|
||||
%{_libdir}/httpd/modules/mod_authz_user.so
|
||||
%{_libdir}/httpd/modules/mod_autoindex.so
|
||||
%{_libdir}/httpd/modules/mod_bucketeer.so
|
||||
%{_libdir}/httpd/modules/mod_buffer.so
|
||||
%{_libdir}/httpd/modules/mod_cache_disk.so
|
||||
%{_libdir}/httpd/modules/mod_cache_socache.so
|
||||
%{_libdir}/httpd/modules/mod_cache.so
|
||||
%{_libdir}/httpd/modules/mod_case_filter.so
|
||||
%{_libdir}/httpd/modules/mod_case_filter_in.so
|
||||
%{_libdir}/httpd/modules/mod_cgid.so
|
||||
%{_libdir}/httpd/modules/mod_charset_lite.so
|
||||
%{_libdir}/httpd/modules/mod_data.so
|
||||
%{_libdir}/httpd/modules/mod_dav_fs.so
|
||||
%{_libdir}/httpd/modules/mod_dav_lock.so
|
||||
%{_libdir}/httpd/modules/mod_dav.so
|
||||
%{_libdir}/httpd/modules/mod_dbd.so
|
||||
%{_libdir}/httpd/modules/mod_deflate.so
|
||||
%{_libdir}/httpd/modules/mod_dialup.so
|
||||
%{_libdir}/httpd/modules/mod_dir.so
|
||||
%{_libdir}/httpd/modules/mod_dumpio.so
|
||||
%{_libdir}/httpd/modules/mod_echo.so
|
||||
%{_libdir}/httpd/modules/mod_env.so
|
||||
%{_libdir}/httpd/modules/mod_expires.so
|
||||
%{_libdir}/httpd/modules/mod_ext_filter.so
|
||||
%{_libdir}/httpd/modules/mod_file_cache.so
|
||||
%{_libdir}/httpd/modules/mod_filter.so
|
||||
%{_libdir}/httpd/modules/mod_headers.so
|
||||
%{_libdir}/httpd/modules/mod_heartbeat.so
|
||||
%{_libdir}/httpd/modules/mod_heartmonitor.so
|
||||
%{_libdir}/httpd/modules/mod_include.so
|
||||
%{_libdir}/httpd/modules/mod_info.so
|
||||
%{_libdir}/httpd/modules/mod_lbmethod_bybusyness.so
|
||||
%{_libdir}/httpd/modules/mod_lbmethod_byrequests.so
|
||||
%{_libdir}/httpd/modules/mod_lbmethod_bytraffic.so
|
||||
%{_libdir}/httpd/modules/mod_lbmethod_heartbeat.so
|
||||
%{_libdir}/httpd/modules/mod_log_config.so
|
||||
%{_libdir}/httpd/modules/mod_log_debug.so
|
||||
%{_libdir}/httpd/modules/mod_log_forensic.so
|
||||
%{_libdir}/httpd/modules/mod_logio.so
|
||||
%{_libdir}/httpd/modules/mod_macro.so
|
||||
%{_libdir}/httpd/modules/mod_mime_magic.so
|
||||
%{_libdir}/httpd/modules/mod_mime.so
|
||||
%{_libdir}/httpd/modules/mod_mpm_event.so
|
||||
%{_libdir}/httpd/modules/mod_mpm_prefork.so
|
||||
%{_libdir}/httpd/modules/mod_mpm_worker.so
|
||||
%{_libdir}/httpd/modules/mod_negotiation.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_ajp.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_balancer.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_connect.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_express.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_fcgi.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_fdpass.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_ftp.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_http.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_scgi.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_uwsgi.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_wstunnel.so
|
||||
%{_libdir}/httpd/modules/mod_proxy_hcheck.so
|
||||
%{_libdir}/httpd/modules/mod_proxy.so
|
||||
%{_libdir}/httpd/modules/mod_ratelimit.so
|
||||
%{_libdir}/httpd/modules/mod_reflector.so
|
||||
%{_libdir}/httpd/modules/mod_remoteip.so
|
||||
%{_libdir}/httpd/modules/mod_reqtimeout.so
|
||||
%{_libdir}/httpd/modules/mod_request.so
|
||||
%{_libdir}/httpd/modules/mod_rewrite.so
|
||||
%{_libdir}/httpd/modules/mod_sed.so
|
||||
%{_libdir}/httpd/modules/mod_session_cookie.so
|
||||
%{_libdir}/httpd/modules/mod_session_crypto.so
|
||||
%{_libdir}/httpd/modules/mod_session_dbd.so
|
||||
%{_libdir}/httpd/modules/mod_session.so
|
||||
%{_libdir}/httpd/modules/mod_setenvif.so
|
||||
%{_libdir}/httpd/modules/mod_slotmem_plain.so
|
||||
%{_libdir}/httpd/modules/mod_slotmem_shm.so
|
||||
%{_libdir}/httpd/modules/mod_socache_dbm.so
|
||||
%{_libdir}/httpd/modules/mod_socache_memcache.so
|
||||
%{_libdir}/httpd/modules/mod_socache_redis.so
|
||||
%{_libdir}/httpd/modules/mod_socache_shmcb.so
|
||||
%{_libdir}/httpd/modules/mod_speling.so
|
||||
%{_libdir}/httpd/modules/mod_status.so
|
||||
%{_libdir}/httpd/modules/mod_substitute.so
|
||||
%{_libdir}/httpd/modules/mod_suexec.so
|
||||
%{_libdir}/httpd/modules/mod_unique_id.so
|
||||
%{_libdir}/httpd/modules/mod_unixd.so
|
||||
%{_libdir}/httpd/modules/mod_userdir.so
|
||||
%{_libdir}/httpd/modules/mod_usertrack.so
|
||||
%{_libdir}/httpd/modules/mod_version.so
|
||||
%{_libdir}/httpd/modules/mod_vhost_alias.so
|
||||
%{_libdir}/httpd/modules/mod_watchdog.so
|
||||
|
||||
%dir %{contentdir}
|
||||
%dir %{contentdir}/cgi-bin
|
||||
%dir %{contentdir}/html
|
||||
%dir %{contentdir}/icons
|
||||
%dir %{contentdir}/error
|
||||
%dir %{contentdir}/error/include
|
||||
%{contentdir}/icons/*
|
||||
%{contentdir}/error/README
|
||||
%{contentdir}/html/index.html
|
||||
%config(noreplace) %{contentdir}/error/*.var
|
||||
%config(noreplace) %{contentdir}/error/include/*.html
|
||||
|
||||
%attr(0700,root,root) %dir %{_localstatedir}/log/httpd
|
||||
|
||||
%attr(0700,apache,apache) %dir %{_localstatedir}/lib/dav
|
||||
%attr(0700,apache,apache) %dir %{_localstatedir}/cache/httpd/cache-root
|
||||
|
||||
%{_mandir}/man1/*
|
||||
%{_mandir}/man8/suexec*
|
||||
%{_mandir}/man8/apachectl.8*
|
||||
%{_mandir}/man8/httpd.8*
|
||||
%{_mandir}/man8/htcacheclean.8*
|
||||
%{_mandir}/man8/fcgistarter.8*
|
||||
|
||||
%files manual
|
||||
%defattr(-,root,root)
|
||||
%{contentdir}/manual
|
||||
%{contentdir}/error/README
|
||||
|
||||
%files tools
|
||||
%defattr(-,root,root)
|
||||
%{_bindir}/ab
|
||||
%{_bindir}/htdbm
|
||||
%{_bindir}/htdigest
|
||||
%{_bindir}/htpasswd
|
||||
%{_bindir}/logresolve
|
||||
%{_bindir}/httxt2dbm
|
||||
%{_sbindir}/rotatelogs
|
||||
%{_mandir}/man1/htdbm.1*
|
||||
%{_mandir}/man1/htdigest.1*
|
||||
%{_mandir}/man1/htpasswd.1*
|
||||
%{_mandir}/man1/httxt2dbm.1*
|
||||
%{_mandir}/man1/ab.1*
|
||||
%{_mandir}/man1/logresolve.1*
|
||||
%{_mandir}/man8/rotatelogs.8*
|
||||
%doc LICENSE NOTICE
|
||||
|
||||
%files -n mod_authnz_ldap
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/httpd/modules/mod_ldap.so
|
||||
%{_libdir}/httpd/modules/mod_authnz_ldap.so
|
||||
|
||||
%files -n mod_lua
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/httpd/modules/mod_lua.so
|
||||
|
||||
%files -n mod_proxy_html
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/httpd/modules/mod_proxy_html.so
|
||||
%{_libdir}/httpd/modules/mod_xml2enc.so
|
||||
|
||||
%files -n mod_ssl
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/httpd/modules/mod_ssl.so
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/original/extra/httpd-ssl.conf
|
||||
%config(noreplace) %{_sysconfdir}/httpd/conf/extra/httpd-ssl.conf
|
||||
%attr(0700,apache,root) %dir %{_localstatedir}/cache/mod_ssl
|
||||
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.dir
|
||||
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.pag
|
||||
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.sem
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%{_includedir}/httpd
|
||||
%{_bindir}/apxs
|
||||
%{_sbindir}/checkgid
|
||||
%{_bindir}/dbmmanage
|
||||
%{_sbindir}/envvars*
|
||||
%{_mandir}/man1/dbmmanage.1*
|
||||
%{_mandir}/man1/apxs.1*
|
||||
%dir %{_libdir}/httpd/build
|
||||
%{_libdir}/httpd/build/*.mk
|
||||
%{_libdir}/httpd/build/instdso.sh
|
||||
%{_libdir}/httpd/build/config.nice
|
||||
%{_libdir}/httpd/build/mkdir.sh
|
||||
|
245
build/rules.mk.in
Normal file
245
build/rules.mk.in
Normal file
|
@ -0,0 +1,245 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was originally provided by Sascha Schumann.
|
||||
|
||||
@ap_make_include@ @ap_make_delimiter@$(top_builddir)/build/config_vars.mk@ap_make_delimiter@
|
||||
|
||||
# Combine all of the flags together in the proper order so that
|
||||
# the user-defined flags can always override the configure ones, if needed.
|
||||
# Note that includes are listed after the flags because -I options have
|
||||
# left-to-right precedence and CPPFLAGS may include user-defined overrides.
|
||||
# The "MOD_" prefixed variable are provided to allow modules to insert their
|
||||
# (per-subdirectory) settings through definitions in modules.mk, with highest
|
||||
# precedence.
|
||||
#
|
||||
ALL_CFLAGS = $(MOD_CFLAGS) $(EXTRA_CFLAGS) $(NOTEST_CFLAGS) $(CFLAGS)
|
||||
ALL_CPPFLAGS = $(DEFS) $(INTERNAL_CPPFLAGS) $(MOD_CPPFLAGS) $(EXTRA_CPPFLAGS) $(NOTEST_CPPFLAGS) $(CPPFLAGS)
|
||||
ALL_CXXFLAGS = $(MOD_CXXFLAGS) $(EXTRA_CXXFLAGS) $(NOTEST_CXXFLAGS) $(CXXFLAGS)
|
||||
ALL_LDFLAGS = $(MOD_LDFLAGS) $(EXTRA_LDFLAGS) $(NOTEST_LDFLAGS) $(LDFLAGS)
|
||||
ALL_LIBS = $(MOD_LIBS) $(EXTRA_LIBS) $(NOTEST_LIBS) $(LIBS)
|
||||
ALL_INCLUDES = $(MOD_INCLUDES) $(INCLUDES) $(EXTRA_INCLUDES)
|
||||
|
||||
# Compile commands
|
||||
|
||||
BASE_CC = $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(ALL_INCLUDES)
|
||||
BASE_CXX = $(CXX) $(ALL_CXXFLAGS) $(ALL_CPPFLAGS) $(ALL_INCLUDES)
|
||||
|
||||
COMPILE = $(BASE_CC) $(PICFLAGS)
|
||||
CXX_COMPILE = $(BASE_CXX) $(PICFLAGS)
|
||||
|
||||
SH_COMPILE = $(LIBTOOL) --mode=compile $(BASE_CC) $(SHLTCFLAGS) -c $< && touch $@
|
||||
SH_CXX_COMPILE = $(LIBTOOL) --mode=compile $(BASE_CXX) $(SHLTCFLAGS) -c $< && touch $@
|
||||
|
||||
LT_COMPILE = $(LIBTOOL) --mode=compile $(COMPILE) $(LTCFLAGS) -c $< && touch $@
|
||||
LT_CXX_COMPILE = $(LIBTOOL) --mode=compile $(CXX_COMPILE) $(LTCFLAGS) -c $< && touch $@
|
||||
|
||||
# Link-related commands
|
||||
|
||||
LINK = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) $(PILDFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
|
||||
SH_LINK = $(SH_LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) $(SH_LDFLAGS) $(CORE_IMPLIB) $(SH_LIBS) -o $@
|
||||
MOD_LINK = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) -static $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
|
||||
|
||||
# Cross compile commands
|
||||
|
||||
# Helper programs
|
||||
|
||||
INSTALL_DATA = $(INSTALL) -m 644
|
||||
INSTALL_PROGRAM = $(INSTALL) -m 755 $(INSTALL_PROG_FLAGS)
|
||||
|
||||
#
|
||||
# Standard build rules
|
||||
#
|
||||
all: all-recursive
|
||||
depend: depend-recursive
|
||||
clean: clean-recursive
|
||||
distclean: distclean-recursive
|
||||
extraclean: extraclean-recursive
|
||||
install: install-recursive
|
||||
shared-build: shared-build-recursive
|
||||
|
||||
all-recursive install-recursive depend-recursive:
|
||||
@otarget=`echo $@|sed s/-recursive//`; \
|
||||
list=' $(BUILD_SUBDIRS) $(SUBDIRS)'; \
|
||||
for i in $$list; do \
|
||||
if test -d "$$i"; then \
|
||||
target="$$otarget"; \
|
||||
echo "Making $$target in $$i"; \
|
||||
if test "$$i" = "."; then \
|
||||
made_local=yes; \
|
||||
target="local-$$target"; \
|
||||
fi; \
|
||||
(cd $$i && $(MAKE) $$target) || exit 1; \
|
||||
fi; \
|
||||
done; \
|
||||
if test "$$otarget" = "all" && test -z '$(TARGETS)'; then \
|
||||
made_local=yes; \
|
||||
fi; \
|
||||
if test "$$made_local" != "yes"; then \
|
||||
$(MAKE) "local-$$otarget" || exit 1; \
|
||||
fi
|
||||
|
||||
clean-recursive distclean-recursive extraclean-recursive:
|
||||
@otarget=`echo $@|sed s/-recursive//`; \
|
||||
list='$(CLEAN_SUBDIRS) $(SUBDIRS)'; \
|
||||
for i in $$list; do \
|
||||
if test -d "$$i"; then \
|
||||
target="$$otarget"; \
|
||||
echo "Making $$target in $$i"; \
|
||||
if test "$$i" = "."; then \
|
||||
made_local=yes; \
|
||||
target="local-$$target"; \
|
||||
fi; \
|
||||
(cd $$i && $(MAKE) $$target); \
|
||||
fi; \
|
||||
done; \
|
||||
if test "$$otarget" = "all" && test -z '$(TARGETS)'; then \
|
||||
made_local=yes; \
|
||||
fi; \
|
||||
if test "$$made_local" != "yes"; then \
|
||||
$(MAKE) "local-$$otarget"; \
|
||||
fi
|
||||
|
||||
shared-build-recursive:
|
||||
@if test `pwd` = "$(top_builddir)"; then \
|
||||
$(PRE_SHARED_CMDS) ; \
|
||||
fi; \
|
||||
list='$(SUBDIRS)'; for i in $$list; do \
|
||||
target="shared-build"; \
|
||||
if test "$$i" = "."; then \
|
||||
made_local=yes; \
|
||||
target="local-shared-build"; \
|
||||
fi; \
|
||||
if test "$$i" != "srclib"; then \
|
||||
(cd $$i && $(MAKE) $$target) || exit 1; \
|
||||
fi; \
|
||||
done; \
|
||||
if test -f 'modules.mk'; then \
|
||||
if test -n '$(SHARED_TARGETS)'; then \
|
||||
echo "Building shared: $(SHARED_TARGETS)"; \
|
||||
if test "$$made_local" != "yes"; then \
|
||||
$(MAKE) "local-shared-build" || exit 1; \
|
||||
fi; \
|
||||
fi; \
|
||||
fi; \
|
||||
if test `pwd` = "$(top_builddir)"; then \
|
||||
$(POST_SHARED_CMDS) ; \
|
||||
fi
|
||||
|
||||
local-all: $(TARGETS)
|
||||
|
||||
local-shared-build: $(SHARED_TARGETS)
|
||||
|
||||
local-depend: x-local-depend
|
||||
@if test -n "`ls $(srcdir)/*.c 2> /dev/null`"; then \
|
||||
rm -f .deps; \
|
||||
list='$(srcdir)/*.c'; \
|
||||
for i in $$list; do \
|
||||
$(MKDEP) $(ALL_CPPFLAGS) $(ALL_INCLUDES) $$i | sed 's/\.o:/.lo:/' >> .deps; \
|
||||
done; \
|
||||
sed 's/\.lo:/.slo:/' < .deps > .deps.$$; \
|
||||
cat .deps.$$ >> .deps; \
|
||||
rm -f .deps.$$; \
|
||||
fi
|
||||
|
||||
local-clean: x-local-clean
|
||||
rm -f *.o *.lo *.slo *.obj *.a *.la $(CLEAN_TARGETS) $(TARGETS)
|
||||
rm -rf .libs
|
||||
|
||||
local-distclean: local-clean x-local-distclean
|
||||
rm -f .deps Makefile $(DISTCLEAN_TARGETS)
|
||||
|
||||
local-extraclean: local-distclean x-local-extraclean
|
||||
@if test -n "$(EXTRACLEAN_TARGETS)"; then \
|
||||
echo "rm -f $(EXTRACLEAN_TARGETS)"; \
|
||||
rm -f $(EXTRACLEAN_TARGETS) ; \
|
||||
fi
|
||||
|
||||
program-install: $(TARGETS) $(SHARED_TARGETS)
|
||||
@if test -n '$(bin_PROGRAMS)'; then \
|
||||
test -d $(DESTDIR)$(bindir) || $(MKINSTALLDIRS) $(DESTDIR)$(bindir); \
|
||||
list='$(bin_PROGRAMS)'; for i in $$list; do \
|
||||
$(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir); \
|
||||
done; \
|
||||
fi
|
||||
@if test -n '$(sbin_PROGRAMS)'; then \
|
||||
test -d $(DESTDIR)$(sbindir) || $(MKINSTALLDIRS) $(DESTDIR)$(sbindir); \
|
||||
list='$(sbin_PROGRAMS)'; for i in $$list; do \
|
||||
$(INSTALL_PROGRAM) $$i $(DESTDIR)$(sbindir); \
|
||||
done; \
|
||||
fi
|
||||
|
||||
local-install: program-install $(INSTALL_TARGETS)
|
||||
|
||||
# to be filled in by the actual Makefile if extra commands are needed
|
||||
x-local-depend x-local-clean x-local-distclean x-local-extraclean:
|
||||
|
||||
#
|
||||
# Implicit rules for creating outputs from input files
|
||||
#
|
||||
CXX_SUFFIX = cpp
|
||||
SHLIB_SUFFIX = so
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .S .c .$(CXX_SUFFIX) .lo .o .s .y .l .slo .def .la
|
||||
|
||||
.c.o:
|
||||
$(COMPILE) -c $<
|
||||
|
||||
.s.o:
|
||||
$(COMPILE) -c $<
|
||||
|
||||
.c.lo:
|
||||
$(LT_COMPILE)
|
||||
|
||||
.s.lo:
|
||||
$(LT_COMPILE)
|
||||
|
||||
.c.slo:
|
||||
$(SH_COMPILE)
|
||||
|
||||
.$(CXX_SUFFIX).lo:
|
||||
$(LT_CXX_COMPILE)
|
||||
|
||||
.$(CXX_SUFFIX).slo:
|
||||
$(SH_CXX_COMPILE)
|
||||
|
||||
.y.c:
|
||||
$(YACC) $(YFLAGS) $< && mv y.tab.c $*.c
|
||||
if test -f y.tab.h; then \
|
||||
if cmp -s y.tab.h $*.h; then rm -f y.tab.h; else mv y.tab.h $*.h; fi; \
|
||||
else :; fi
|
||||
|
||||
.l.c:
|
||||
$(LEX) $(LFLAGS) $< && mv $(LEX_OUTPUT_ROOT).c $@
|
||||
|
||||
# Makes an import library from a def file
|
||||
.def.la:
|
||||
$(LIBTOOL) --mode=compile $(MK_IMPLIB) -o $@ $<
|
||||
|
||||
#
|
||||
# Dependencies
|
||||
#
|
||||
@ap_make_include@ @ap_make_delimiter@$(builddir)/.deps@ap_make_delimiter@
|
||||
|
||||
.PHONY: all all-recursive install-recursive local-all $(PHONY_TARGETS) \
|
||||
shared-build shared-build-recursive local-shared-build \
|
||||
depend depend-recursive local-depend x-local-depend \
|
||||
clean clean-recursive local-clean x-local-clean \
|
||||
distclean distclean-recursive local-distclean x-local-distclean \
|
||||
extraclean extraclean-recursive local-extraclean x-local-extraclean \
|
||||
install local-install docs $(INSTALL_TARGETS)
|
||||
|
36
build/special.mk
Normal file
36
build/special.mk
Normal file
|
@ -0,0 +1,36 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
all: all-recursive
|
||||
|
||||
include $(builddir)/modules.mk
|
||||
|
||||
TARGETS = $(static)
|
||||
SHARED_TARGETS = $(shared)
|
||||
INSTALL_TARGETS = install-modules-$(INSTALL_DSO)
|
||||
|
||||
include $(top_builddir)/build/rules.mk
|
||||
|
||||
install-modules-yes: $(SHARED_TARGETS)
|
||||
@$(MKINSTALLDIRS) $(DESTDIR)$(libexecdir)
|
||||
@list='$(shared)'; for i in $$list; do \
|
||||
$(top_srcdir)/build/instdso.sh SH_LIBTOOL='$(SH_LIBTOOL)' $$i $(DESTDIR)$(libexecdir); \
|
||||
done
|
||||
|
||||
install-modules-no:
|
||||
|
34
build/sysv_makefile
Executable file
34
build/sysv_makefile
Executable file
|
@ -0,0 +1,34 @@
|
|||
#! /bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# The build environment was provided by Sascha Schumann.
|
||||
|
||||
# cwd must be top_srcdir
|
||||
test -f build/sysv_makefile || exit 2
|
||||
|
||||
test -f bsd_converted || exit 1
|
||||
|
||||
tmpfile=`mktemp /tmp/sysv_makefile.XXXXXX 2>/dev/null` || tmpfile="tmp.$$"
|
||||
for i in build/*.mk; do
|
||||
sed 's/^\.include "\(.*\)"/include \1/' $i >$tmpfile \
|
||||
&& cp $tmpfile $i
|
||||
done
|
||||
rm -f $tmpfile
|
||||
|
||||
rm bsd_converted
|
||||
exit 0
|
BIN
build/win32/apache.ico
Normal file
BIN
build/win32/apache.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
88
build/win32/httpd.rc
Normal file
88
build/win32/httpd.rc
Normal file
|
@ -0,0 +1,88 @@
|
|||
/* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
* contributor license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright ownership.
|
||||
* The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
* (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "ap_release.h"
|
||||
|
||||
#define AP_SERVER_LICENSE_RCSTR \
|
||||
"Licensed under the Apache License, Version 2.0 (the ""License""); " \
|
||||
"you may not use this file except in compliance with the License. " \
|
||||
"You may obtain a copy of the License at\r\n" \
|
||||
"\r\n" \
|
||||
"http://www.apache.org/licenses/LICENSE-2.0\r\n" \
|
||||
"\r\n" \
|
||||
"Unless required by applicable law or agreed to in writing, software " \
|
||||
"distributed under the License is distributed on an ""AS IS"" BASIS, " \
|
||||
"WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. " \
|
||||
"See the License for the specific language governing permissions and " \
|
||||
"limitations under the License."
|
||||
|
||||
|
||||
#ifdef ICON_FILE
|
||||
1 ICON DISCARDABLE APR_STRINGIFY(ICON_FILE)
|
||||
#endif
|
||||
|
||||
#define LONG_NAME_STR APR_STRINGIFY(LONG_NAME)
|
||||
#define BIN_NAME_STR APR_STRINGIFY(BIN_NAME)
|
||||
|
||||
1 VERSIONINFO
|
||||
FILEVERSION AP_SERVER_PATCHLEVEL_CSV,0
|
||||
PRODUCTVERSION AP_SERVER_PATCHLEVEL_CSV,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#if AP_SERVER_DEVBUILD_BOOLEAN
|
||||
#if defined(_DEBUG)
|
||||
FILEFLAGS 0x03L
|
||||
#else
|
||||
FILEFLAGS 0x02L
|
||||
#endif
|
||||
#else
|
||||
#if defined(_DEBUG)
|
||||
FILEFLAGS 0x01L
|
||||
#else
|
||||
FILEFLAGS 0x00L
|
||||
#endif
|
||||
#endif
|
||||
#if defined(WINNT) || defined(WIN64)
|
||||
FILEOS 0x40004L
|
||||
#else
|
||||
FILEOS 0x4L
|
||||
#endif
|
||||
#if defined(APP_FILE)
|
||||
FILETYPE 0x1L
|
||||
#else
|
||||
FILETYPE 0x2L
|
||||
#endif
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904b0"
|
||||
BEGIN
|
||||
VALUE "Comments", AP_SERVER_LICENSE_RCSTR "\0"
|
||||
VALUE "CompanyName", AP_SERVER_BASEVENDOR "\0"
|
||||
VALUE "FileDescription", LONG_NAME_STR "\0"
|
||||
VALUE "FileVersion", AP_SERVER_BASEREVISION "\0"
|
||||
VALUE "InternalName", BIN_NAME_STR "\0"
|
||||
VALUE "LegalCopyright", AP_SERVER_COPYRIGHT "\0"
|
||||
VALUE "OriginalFilename", BIN_NAME_STR "\0"
|
||||
VALUE "ProductName", "Apache HTTP Server\0"
|
||||
VALUE "ProductVersion", AP_SERVER_BASEREVISION "\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
331
buildconf
Executable file
331
buildconf
Executable file
|
@ -0,0 +1,331 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
#
|
||||
# buildconf: Build the support scripts needed to compile from a
|
||||
# checked-out version of the source code.
|
||||
|
||||
# version check for AC_PROG_CC_C99
|
||||
ac_version=`${AUTOCONF:-autoconf} --version 2>/dev/null|sed -e 's/^[^0-9]*//;s/[a-z]* *$//;q'`
|
||||
case "$ac_version" in
|
||||
# versions older than 2.50 are denied by AC_PREREQ
|
||||
2.5*)
|
||||
echo WARNING: You are using an outdated version of autoconf.
|
||||
echo WARNING: This may lead to less than optimal performance of httpd.
|
||||
echo WARNING: You should use autoconf 2.60 or newer.
|
||||
sleep 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# set a couple of defaults for where we should be looking for our support libs.
|
||||
# can be overridden with --with-apr=[dir] and --with-apr-util=[dir]
|
||||
|
||||
apr_src_dir="srclib/apr ../apr"
|
||||
apu_src_dir=""
|
||||
|
||||
while test $# -gt 0
|
||||
do
|
||||
# Normalize
|
||||
case "$1" in
|
||||
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
|
||||
*) optarg= ;;
|
||||
esac
|
||||
|
||||
case "$1" in
|
||||
--with-apr=*)
|
||||
apr_src_dir=$optarg
|
||||
;;
|
||||
|
||||
--with-apr-util=*)
|
||||
apu_src_dir=$optarg
|
||||
;;
|
||||
|
||||
-h|--help)
|
||||
cat <<EOF
|
||||
buildconf: generates the files needed to configure httpd.
|
||||
|
||||
Usage: $0 [OPTION]...
|
||||
|
||||
Configuration:
|
||||
-h, --help display this help and exit
|
||||
|
||||
--with-apr=SRCDIR define a space-separated list of directories to
|
||||
search for the APR source code. If, instead of a
|
||||
directory, an apr-config executable name is passed,
|
||||
APR-Config Mode is enabled (see below). Defaults to
|
||||
"srclib/apr ../apr"
|
||||
--with-apr-util=SRCDIR define a space-separated list of directories to
|
||||
search for the APR-util source code. Defaults to the
|
||||
same location as the --with-apr SRCDIR, but with
|
||||
"apr" replaced with "apr-util" or "aprutil". Ignored
|
||||
in APR-Config Mode.
|
||||
|
||||
APR-Config Mode:
|
||||
|
||||
When passing an apr-config executable to --with-apr, buildconf will attempt to
|
||||
copy build scripts from various installed locations on your system instead of
|
||||
an APR source tree. This allows you to configure httpd from source without
|
||||
also requiring you to download the APR and/or APR-util sources.
|
||||
|
||||
For example:
|
||||
|
||||
./buildconf --with-apr=apr-1-config
|
||||
|
||||
For this functionality to work reliably, you must have automake >= 1.12 and be
|
||||
using a distribution that includes both find_apr.m4 and find_apu.m4 in the
|
||||
--installbuilddir pointed to by apr-config.
|
||||
|
||||
Environment variables used by buildconf:
|
||||
AUTOCONF autoconf executable name [autoconf]
|
||||
AUTOMAKE automake executable name [automake]
|
||||
AUTOHEADER autoheader executable name [autoheader]
|
||||
EOF
|
||||
exit
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "unknown option $1 (try --help for usage)"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
shift
|
||||
done
|
||||
|
||||
#
|
||||
# Check to be sure that we have the srclib dependencies checked-out, or that a
|
||||
# working apr-config installation has been specified.
|
||||
#
|
||||
|
||||
should_exit=0
|
||||
apr_config= # path to apr-config (empty if using a source directory)
|
||||
apr_found=0
|
||||
apu_found=0
|
||||
apr_major_version=2
|
||||
|
||||
for dir in $apr_src_dir
|
||||
do
|
||||
if [ -f "${dir}/build/apr_common.m4" ]; then
|
||||
echo "found apr source: ${dir}"
|
||||
apr_src_dir=$dir
|
||||
apr_found=1
|
||||
break
|
||||
elif which "${dir}" >/dev/null 2>&1; then
|
||||
# We're using apr-config. Do a sanity check.
|
||||
apr_config=`which "${dir}"`
|
||||
echo "testing apr-config executable: ${apr_config}"
|
||||
|
||||
version=`"${apr_config}" --version`
|
||||
version=`echo "${version}" | sed -n '/^[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*$/p'`
|
||||
|
||||
if [ -z "${version}" ]; then
|
||||
echo "apr-config gave us an invalid --version"
|
||||
apr_config=
|
||||
continue
|
||||
fi
|
||||
|
||||
echo "using apr-config version ${version}"
|
||||
apr_major_version=${version} # we'll make a real "major version" later
|
||||
apr_src_dir=`"${apr_config}" --installbuilddir`
|
||||
apr_found=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ $apr_found -lt 1 ]; then
|
||||
echo ""
|
||||
echo "You don't have a copy of the apr source in srclib/apr. "
|
||||
echo "Please get the source using the following instructions,"
|
||||
echo "or specify the location of the source with "
|
||||
echo "--with-apr=[path to apr] :"
|
||||
echo ""
|
||||
echo " svn co http://svn.apache.org/repos/asf/apr/apr/trunk srclib/apr"
|
||||
echo ""
|
||||
should_exit=1
|
||||
elif [ -n "${apr_config}" ]; then
|
||||
apr_major_version=`echo "${apr_major_version}" | sed 's/\..*//'`
|
||||
else
|
||||
apr_major_version=`grep "#define APR_MAJOR_VERSION" \
|
||||
$apr_src_dir/include/apr_version.h | sed 's/[^0-9]//g'`
|
||||
fi
|
||||
|
||||
# Find APR-util. Note: if we're using apr-config, we can completely skip this,
|
||||
# even if APR is version 1. That's because we only end up caring about
|
||||
# find_apu.m4, which is not actually installed in the standard APR-util
|
||||
# distribution to begin with.
|
||||
if [ -z "${apr_config}" -a $apr_major_version -lt 2 ] ; then
|
||||
if test -z "$apu_src_dir"; then
|
||||
apu_src_dir=`echo $apr_src_dir | sed -e 's#/apr#/apr-util#g;'`
|
||||
apu_src_dir="$apu_src_dir `echo $apr_src_dir | sed -e 's#/apr#/aprutil#;g'`"
|
||||
apu_src_dir="$apu_src_dir srclib/apr-util ../apr-util"
|
||||
fi
|
||||
|
||||
for dir in $apu_src_dir
|
||||
do
|
||||
if [ -f "${dir}/Makefile.in" ]; then
|
||||
echo "found apr-util source: ${dir}"
|
||||
apu_src_dir=$dir
|
||||
apu_found=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ $apu_found -lt 1 ]; then
|
||||
echo ""
|
||||
echo "You don't have a copy of the apr-util source in srclib/apr-util. "
|
||||
echo "Please get one the source using the following instructions, "
|
||||
echo "or specify the location of the source with "
|
||||
echo "--with-apr-util=[path to apr-util]:"
|
||||
echo ""
|
||||
echo " svn co http://svn.apache.org/repos/asf/apr/apr-util/branches/1.5.x srclib/apr-util"
|
||||
echo ""
|
||||
should_exit=1
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ $should_exit -gt 0 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# These are temporary until Roy finishes the other build changes
|
||||
#
|
||||
touch .deps
|
||||
rm -f aclocal.m4
|
||||
rm -f generated_lists
|
||||
|
||||
# Remove autoconf 2.5x cache directories
|
||||
rm -rf autom4te*.cache
|
||||
|
||||
case "`uname`" in
|
||||
*BSD/OS*)
|
||||
./build/bsd_makefile;;
|
||||
esac
|
||||
#
|
||||
# end temporary stuff
|
||||
|
||||
apr_configure="$apr_src_dir/configure"
|
||||
if [ $apr_major_version -lt 2 ] ; then
|
||||
aprutil_configure="$apu_src_dir/configure"
|
||||
fi
|
||||
config_h_in="include/ap_config_auto.h.in"
|
||||
|
||||
cross_compile_warning="warning: AC_TRY_RUN called without default to allow cross compiling"
|
||||
|
||||
if [ "$apr_src_dir" = "srclib/apr" ]; then
|
||||
echo rebuilding $apr_configure
|
||||
(cd srclib/apr && ./buildconf) || {
|
||||
echo "./buildconf failed for apr"
|
||||
exit 1
|
||||
}
|
||||
rm -f srclib/apr/apr.spec
|
||||
fi
|
||||
|
||||
apr_src_dir=`cd $apr_src_dir && pwd`
|
||||
|
||||
if [ $apr_major_version -lt 2 ] ; then
|
||||
if [ "$apu_src_dir" = "srclib/apr-util" ]; then
|
||||
echo rebuilding $aprutil_configure
|
||||
(cd srclib/apr-util && ./buildconf --with-apr=$apr_src_dir) || {
|
||||
echo "./buildconf failed for apr-util"
|
||||
exit 1
|
||||
}
|
||||
rm -f srclib/apr-util/apr-util.spec
|
||||
fi
|
||||
|
||||
apu_src_dir=`cd $apu_src_dir && pwd`
|
||||
fi
|
||||
|
||||
echo copying build files
|
||||
if [ -n "${apr_config}" ]; then
|
||||
# If we're using apr-config, we switch things up a little bit:
|
||||
# - use automake's config.* scripts instead of APR's
|
||||
# - use the included PrintPath instead of copying from APR
|
||||
# - assume find_apu.m4 is also in APR's --installbuilddir
|
||||
|
||||
# Figure out where to copy config.* from.
|
||||
automake=${AUTOMAKE:-automake}
|
||||
am_libdir=`"${automake}" --print-libdir`
|
||||
cp "${am_libdir}/config.guess" "${am_libdir}/config.sub" build
|
||||
|
||||
# Remember that in this case, $apr_src_dir points to the build directory.
|
||||
cp "$apr_src_dir/apr_common.m4" "$apr_src_dir/find_apr.m4" build
|
||||
if [ $apr_major_version -lt 2 ] ; then
|
||||
cp "$apr_src_dir/find_apu.m4" build
|
||||
fi
|
||||
else
|
||||
cp $apr_src_dir/build/config.guess $apr_src_dir/build/config.sub \
|
||||
$apr_src_dir/build/PrintPath $apr_src_dir/build/apr_common.m4 \
|
||||
$apr_src_dir/build/find_apr.m4 build
|
||||
if [ $apr_major_version -lt 2 ] ; then
|
||||
cp $apu_src_dir/build/find_apu.m4 build
|
||||
fi
|
||||
fi
|
||||
|
||||
# Remove any libtool files so one can switch between libtool 1.3
|
||||
# and libtool 1.4 by simply rerunning the buildconf script.
|
||||
(cd build ; rm -f ltconfig ltmain.sh)
|
||||
|
||||
if [ -z "${apr_config}" ]; then
|
||||
# Optionally copy libtool-1.3.x files
|
||||
if [ -f $apr_src_dir/build/ltconfig ]; then
|
||||
cp $apr_src_dir/build/ltconfig build
|
||||
fi
|
||||
if [ -f $apr_src_dir/build/ltmain.sh ]; then
|
||||
cp $apr_src_dir/build/ltmain.sh build
|
||||
fi
|
||||
fi
|
||||
|
||||
echo rebuilding $config_h_in
|
||||
rm -f $config_h_in
|
||||
${AUTOHEADER:-autoheader} 2>&1 | grep -v "$cross_compile_warning"
|
||||
|
||||
echo rebuilding configure
|
||||
rm -f config.cache
|
||||
${AUTOCONF:-autoconf} 2>&1 | grep -v "$cross_compile_warning"
|
||||
|
||||
# Remove autoconf 2.5x cache directories
|
||||
rm -rf autom4te*.cache
|
||||
|
||||
if [ -f `which cut` ]; then
|
||||
echo rebuilding rpm spec file
|
||||
( VMMN=`build/get-version.sh mmn include/ap_mmn.h MODULE_MAGIC_NUMBER`
|
||||
EPOCH=`build/get-version.sh epoch include/ap_release.h AP_SERVER`
|
||||
REVISION=`build/get-version.sh all include/ap_release.h AP_SERVER`
|
||||
VERSION=`echo $REVISION | cut -d- -s -f1`
|
||||
RELEASE=`echo $REVISION | cut -d- -s -f2`
|
||||
if [ "x$VERSION" = "x" ]; then
|
||||
VERSION=$REVISION
|
||||
RELEASE=1
|
||||
fi
|
||||
cat ./build/rpm/httpd.spec.in | \
|
||||
sed -e "s/APACHE_VERSION/$VERSION/" \
|
||||
-e "s/APACHE_RELEASE/$RELEASE/" \
|
||||
-e "s/APACHE_MMN/$VMMN/" \
|
||||
-e "s/APACHE_EPOCH/$EPOCH/" \
|
||||
> httpd.spec )
|
||||
fi
|
||||
|
||||
# ensure that the ap_expr expression parser sources are never regenerated
|
||||
# when running make
|
||||
echo fixing timestamps for ap_expr sources
|
||||
cd server
|
||||
touch util_expr_parse.y util_expr_scan.l
|
||||
sleep 1
|
||||
touch util_expr_parse.c util_expr_parse.h util_expr_scan.c
|
||||
cd ..
|
||||
|
||||
exit 0
|
421
config.layout
Normal file
421
config.layout
Normal file
|
@ -0,0 +1,421 @@
|
|||
##
|
||||
## config.layout -- Pre-defined Installation Path Layouts
|
||||
##
|
||||
## Hints:
|
||||
## - layouts can be loaded with configure's --enable-layout=ID option
|
||||
## - when no --enable-layout option is given, the default layout is `Apache'
|
||||
## - a trailing plus character (`+') on paths is replaced with a
|
||||
## `/<target>' suffix where <target> is currently hardcoded to 'apache2'.
|
||||
## (This may become a configurable parameter at some point.)
|
||||
##
|
||||
|
||||
# Classical Apache path layout.
|
||||
<Layout Apache>
|
||||
prefix: /usr/local/apache2
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/bin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/modules
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: ${prefix}/conf
|
||||
datadir: ${prefix}
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include
|
||||
localstatedir: ${prefix}
|
||||
runtimedir: ${localstatedir}/logs
|
||||
logfiledir: ${localstatedir}/logs
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# GNU standards conforming path layout.
|
||||
# See FSF's GNU project `make-stds' document for details.
|
||||
<Layout GNU>
|
||||
prefix: /usr/local
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: ${prefix}/etc+
|
||||
datadir: ${prefix}/share+
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include+
|
||||
localstatedir: ${prefix}/var+
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# Mac OS X Server (Rhapsody)
|
||||
<Layout Mac OS X Server>
|
||||
prefix: /Local/Library/WebServer
|
||||
exec_prefix: /usr
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: /System/Library/Apache/Modules
|
||||
mandir: ${exec_prefix}/share/man
|
||||
sysconfdir: ${prefix}/Configuration
|
||||
datadir: ${prefix}
|
||||
installbuilddir: /System/Library/Apache/Build
|
||||
errordir: /System/Library/Apache/Error
|
||||
iconsdir: /System/Library/Apache/Icons
|
||||
manualdir: /System/Library/Apache/Manual
|
||||
htdocsdir: ${datadir}/Documents
|
||||
cgidir: ${datadir}/CGI-Executables
|
||||
includedir: /System/Library/Frameworks/Apache.framework/Versions/2.0/Headers
|
||||
localstatedir: /var
|
||||
runtimedir: ${prefix}/Logs
|
||||
logfiledir: ${prefix}/Logs
|
||||
proxycachedir: ${prefix}/ProxyCache
|
||||
</Layout>
|
||||
|
||||
# Darwin/Mac OS Layout
|
||||
<Layout Darwin>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec+
|
||||
mandir: ${prefix}/share/man
|
||||
datadir: /Library/WebServer
|
||||
sysconfdir: /etc+
|
||||
installbuilddir: ${prefix}/share/httpd/build
|
||||
errordir: ${prefix}/share/httpd/error
|
||||
iconsdir: ${prefix}/share/httpd/icons
|
||||
htdocsdir: ${datadir}/Documents
|
||||
manualdir: ${datadir}/share/httpd/manual
|
||||
cgidir: ${datadir}/CGI-Executables
|
||||
includedir: ${prefix}/include+
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log+
|
||||
proxycachedir: ${runtimedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# Red Hat Linux 7.x layout
|
||||
<Layout RedHat>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib
|
||||
libexecdir: ${prefix}/lib/apache
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: /etc/httpd/conf
|
||||
datadir: /var/www
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/html
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include/apache
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log/httpd
|
||||
proxycachedir: ${localstatedir}/cache/httpd
|
||||
</Layout>
|
||||
|
||||
# Layout used in Fedora httpd packaging.
|
||||
<Layout Fedora>
|
||||
prefix: /usr
|
||||
localstatedir: /var
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib
|
||||
libexecdir: ${prefix}/libexec
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: /etc/httpd/conf
|
||||
datadir: ${prefix}/share/httpd
|
||||
installbuilddir: ${libdir}/httpd/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${localstatedir}/www/html
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${localstatedir}/www/cgi-bin
|
||||
includedir: ${prefix}/include/httpd
|
||||
runtimedir: /run/httpd
|
||||
logfiledir: ${localstatedir}/log/httpd
|
||||
proxycachedir: ${localstatedir}/cache/httpd/proxy
|
||||
</Layout>
|
||||
|
||||
# According to the /opt filesystem conventions
|
||||
<Layout opt>
|
||||
prefix: /opt/apache
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: /etc${prefix}
|
||||
datadir: ${prefix}/share
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include
|
||||
localstatedir: /var${prefix}
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/logs
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# SuSE 6.x layout
|
||||
<Layout SuSE>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib
|
||||
libexecdir: ${prefix}/lib/apache
|
||||
mandir: ${prefix}/share/man
|
||||
sysconfdir: /etc/httpd
|
||||
datadir: /usr/local/httpd
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include/apache
|
||||
localstatedir: /var/lib/httpd
|
||||
runtimedir: /var/run
|
||||
logfiledir: /var/log/httpd
|
||||
proxycachedir: /var/cache/httpd
|
||||
</Layout>
|
||||
|
||||
# BSD/OS layout
|
||||
<Layout BSDI>
|
||||
prefix: /var/www
|
||||
exec_prefix: /usr/contrib
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/bin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec/apache
|
||||
mandir: ${exec_prefix}/man
|
||||
sysconfdir: ${prefix}/conf
|
||||
datadir: ${prefix}
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${exec_prefix}/include/apache
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log/httpd
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# Solaris 8 Layout
|
||||
<Layout Solaris>
|
||||
prefix: /usr/apache
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/bin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec
|
||||
mandir: ${exec_prefix}/man
|
||||
sysconfdir: /etc/apache
|
||||
datadir: /var/apache
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${exec_prefix}/include
|
||||
localstatedir: ${prefix}
|
||||
runtimedir: /var/run
|
||||
logfiledir: ${datadir}/logs
|
||||
proxycachedir: ${datadir}/proxy
|
||||
</Layout>
|
||||
|
||||
# OpenBSD Layout
|
||||
<Layout OpenBSD>
|
||||
prefix: /var/www
|
||||
exec_prefix: /usr
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/lib/apache/modules
|
||||
mandir: ${exec_prefix}/share/man
|
||||
sysconfdir: ${prefix}/conf
|
||||
datadir: ${prefix}
|
||||
installbuilddir: ${prefix}/build
|
||||
errordir: ${prefix}/error
|
||||
iconsdir: ${prefix}/icons
|
||||
htdocsdir: ${prefix}/htdocs
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${prefix}/cgi-bin
|
||||
includedir: ${exec_prefix}/lib/apache/include
|
||||
localstatedir: ${prefix}
|
||||
runtimedir: ${prefix}/logs
|
||||
logfiledir: ${prefix}/logs
|
||||
proxycachedir: ${prefix}/proxy
|
||||
</Layout>
|
||||
|
||||
# FreeBSD Layout
|
||||
<Layout FreeBSD>
|
||||
prefix: /usr/local
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec/apache2
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: ${prefix}/etc/apache2
|
||||
datadir: ${prefix}/www
|
||||
installbuilddir: ${prefix}/share/apache2/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/data
|
||||
manualdir: ${prefix}/share/doc/apache2
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include/apache2
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log
|
||||
proxycachedir: ${datadir}/proxy
|
||||
</Layout>
|
||||
|
||||
# Debian layout
|
||||
<Layout Debian>
|
||||
prefix:
|
||||
exec_prefix: ${prefix}/usr
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/lib/apache2/modules
|
||||
mandir: ${exec_prefix}/share/man
|
||||
sysconfdir: ${prefix}/etc/apache2
|
||||
datadir: ${exec_prefix}/share/apache2
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${prefix}/usr/share/apache2/default-site/htdocs
|
||||
manualdir: ${htdocsdir}/manual
|
||||
cgidir: ${prefix}/usr/lib/cgi-bin
|
||||
includedir: ${exec_prefix}/include/apache2
|
||||
localstatedir: ${prefix}/var/lock/apache2
|
||||
runtimedir: ${prefix}/var/run/apache2
|
||||
logfiledir: ${prefix}/var/log/apache2
|
||||
proxycachedir: ${prefix}/var/cache/apache2/proxy
|
||||
infodir: ${exec_prefix}/share/info
|
||||
installbuilddir: ${prefix}/usr/share/apache2/build
|
||||
errordir: ${datadir}/error
|
||||
</Layout>
|
||||
|
||||
# Generic RPM layout
|
||||
<Layout RPM>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib
|
||||
libexecdir: ${libdir}/httpd/modules
|
||||
mandir: ${prefix}/share/man
|
||||
sysconfdir: /etc/httpd/conf
|
||||
installbuilddir: ${libdir}/httpd/build
|
||||
includedir: ${prefix}/include/httpd
|
||||
localstatedir: /var
|
||||
datadir: ${localstatedir}/www
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/html
|
||||
manualdir: ${datadir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/log/httpd
|
||||
proxycachedir: ${localstatedir}/cache/httpd/cache-root
|
||||
</Layout>
|
||||
|
||||
# AIX layout
|
||||
<Layout AIX>
|
||||
prefix: /opt/httpd
|
||||
exec_prefix: /opt/httpd
|
||||
bindir: ${exec_prefix}/bin
|
||||
sbindir: ${exec_prefix}/sbin
|
||||
libdir: ${exec_prefix}/lib
|
||||
libexecdir: ${exec_prefix}/libexec
|
||||
mandir: /usr/share/man
|
||||
sysconfdir: /etc/httpd
|
||||
datadir: /var/httpd
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
iconsdir: ${prefix}/icons
|
||||
manualdir: ${prefix}/manual
|
||||
includedir: ${prefix}/include
|
||||
localstatedir: /var/httpd
|
||||
runtimedir: ${localstatedir}/run
|
||||
logfiledir: ${localstatedir}/logs
|
||||
proxycachedir: ${localstatedir}/proxy
|
||||
</Layout>
|
||||
|
||||
# FHS layout
|
||||
<Layout Slackware-FHS>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib/httpd
|
||||
libexecdir: ${prefix}/lib/httpd/modules
|
||||
installbuilddir: ${prefix}/lib/httpd/build
|
||||
mandir: ${prefix}/man
|
||||
sysconfdir: /etc/httpd
|
||||
datadir: /srv/httpd
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: ${htdocsdir}/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
errordir: ${datadir}/error
|
||||
includedir: ${prefix}/include/httpd
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run/httpd
|
||||
logfiledir: ${localstatedir}/log/httpd
|
||||
proxycachedir: ${localstatedir}/cache/httpd
|
||||
</Layout>
|
||||
|
||||
# OpenWrt layout
|
||||
<Layout OpenWrt>
|
||||
prefix: /usr
|
||||
exec_prefix: ${prefix}
|
||||
bindir: ${prefix}/bin
|
||||
sbindir: ${prefix}/sbin
|
||||
libdir: ${prefix}/lib
|
||||
libexecdir: ${prefix}/lib+
|
||||
mandir: ${prefix}/share/man
|
||||
sysconfdir: /etc+
|
||||
datadir: ${prefix}/share+
|
||||
installbuilddir: ${datadir}/build
|
||||
errordir: ${datadir}/error
|
||||
iconsdir: ${datadir}/icons
|
||||
htdocsdir: ${datadir}/htdocs
|
||||
manualdir: /usr/share/doc/apache2/manual
|
||||
cgidir: ${datadir}/cgi-bin
|
||||
includedir: ${prefix}/include+
|
||||
localstatedir: /var
|
||||
runtimedir: ${localstatedir}/run+
|
||||
logfiledir: ${localstatedir}/log+
|
||||
proxycachedir: ${localstatedir}/cache/apache2
|
||||
</Layout>
|
||||
|
986
configure.in
Normal file
986
configure.in
Normal file
|
@ -0,0 +1,986 @@
|
|||
dnl
|
||||
dnl Autoconf configuration for Apache httpd
|
||||
dnl
|
||||
dnl Use ./buildconf to produce a configure script
|
||||
dnl
|
||||
|
||||
AC_PREREQ(2.50)
|
||||
AC_INIT(ABOUT_APACHE)
|
||||
|
||||
AC_CONFIG_HEADER(include/ap_config_auto.h)
|
||||
AC_CONFIG_AUX_DIR(build)
|
||||
|
||||
dnl Absolute source/build directory
|
||||
abs_srcdir=`(cd $srcdir && pwd)`
|
||||
abs_builddir=`pwd`
|
||||
|
||||
dnl Ensure that the httpd version is included
|
||||
HTTPD_VERSION=`$abs_srcdir/build/get-version.sh all $abs_srcdir/include/ap_release.h AP_SERVER`
|
||||
HTTPD_MMN=`$abs_srcdir/build/get-version.sh mmn $abs_srcdir/include/ap_mmn.h MODULE_MAGIC_NUMBER`
|
||||
|
||||
dnl #
|
||||
dnl # Include our own M4 macros along with those for APR and libtool
|
||||
dnl #
|
||||
sinclude(build/apr_common.m4)
|
||||
sinclude(build/find_apr.m4)
|
||||
sinclude(build/find_apu.m4)
|
||||
sinclude(acinclude.m4)
|
||||
|
||||
dnl Later versions of autoconf (>= 2.62) by default cause the produced
|
||||
dnl configure script to emit at least warnings when it comes across unknown
|
||||
dnl command line options. These versions also have the macro
|
||||
dnl AC_DISABLE_OPTION_CHECKING defined which turns this off by default.
|
||||
dnl We want to have this turned off here since our configure calls can
|
||||
dnl contain options for APR / APR-UTIL configure that are unknown to us.
|
||||
dnl So avoid confusing the user by turning this off. See also PR 45221.
|
||||
ifdef([AC_DISABLE_OPTION_CHECKING], [AC_DISABLE_OPTION_CHECKING])
|
||||
|
||||
dnl XXX we can't just use AC_PREFIX_DEFAULT because that isn't subbed in
|
||||
dnl by configure until it is too late. Is that how it should be or not?
|
||||
dnl Something seems broken here.
|
||||
AC_PREFIX_DEFAULT(/usr/local/apache2)
|
||||
|
||||
dnl Get the layout here, so we can pass the required variables to apr
|
||||
APR_ENABLE_LAYOUT(Apache, [errordir iconsdir htdocsdir cgidir])
|
||||
|
||||
dnl reparse the configure arguments.
|
||||
APR_PARSE_ARGUMENTS
|
||||
|
||||
dnl export expanded and relative configure argument variables
|
||||
APACHE_EXPORT_ARGUMENTS
|
||||
|
||||
dnl Save user-defined environment settings for later restoration
|
||||
dnl
|
||||
APR_SAVE_THE_ENVIRONMENT(CPPFLAGS)
|
||||
APR_SAVE_THE_ENVIRONMENT(CFLAGS)
|
||||
APR_SAVE_THE_ENVIRONMENT(CXXFLAGS)
|
||||
APR_SAVE_THE_ENVIRONMENT(LDFLAGS)
|
||||
APR_SAVE_THE_ENVIRONMENT(LIBS)
|
||||
APR_SAVE_THE_ENVIRONMENT(INCLUDES)
|
||||
|
||||
dnl Generate ./config.nice for reproducing runs of configure
|
||||
dnl
|
||||
APR_CONFIG_NICE(config.nice)
|
||||
|
||||
nl='
|
||||
'
|
||||
dnl Check that mkdir -p works
|
||||
APR_MKDIR_P_CHECK($top_srcdir/build/mkdir.sh)
|
||||
|
||||
dnl get an EGREP to use in the Makefiles
|
||||
AC_PROG_EGREP
|
||||
APACHE_SUBST(EGREP)
|
||||
|
||||
dnl ## Run configure for packages Apache uses
|
||||
|
||||
dnl shared library support for these packages doesn't currently
|
||||
dnl work on some platforms
|
||||
|
||||
AC_CANONICAL_SYSTEM
|
||||
|
||||
orig_prefix="$prefix"
|
||||
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Configuring Apache Portable Runtime library...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
AC_ARG_WITH(included-apr,
|
||||
APACHE_HELP_STRING(--with-included-apr,Use bundled copies of APR/APR-Util))
|
||||
|
||||
if test "x$with_included_apr" = "xyes"; then
|
||||
apr_found=reconfig
|
||||
if test ! -d srclib/apr && test ! -d $srcdir/srclib/apr; then
|
||||
AC_MSG_ERROR([Bundled APR requested but not found at ./srclib/. Download and unpack the corresponding apr and apr-util packages to ./srclib/.])
|
||||
fi
|
||||
else
|
||||
APR_FIND_APR("$srcdir/srclib/apr", "./srclib/apr", 1, 1 2, [
|
||||
version=`$apr_config --version`
|
||||
case x${version} in
|
||||
x1.[[0-3]].*)
|
||||
AC_MSG_WARN([APR version 1.4.0 or later is required, found $version])
|
||||
apr_acceptable=no
|
||||
;;
|
||||
esac
|
||||
unset version
|
||||
])
|
||||
fi
|
||||
|
||||
if test "$apr_found" = "no"; then
|
||||
AC_MSG_ERROR([APR not found. Please read the documentation.])
|
||||
fi
|
||||
|
||||
if test "$apr_found" = "reconfig"; then
|
||||
APR_SUBDIR_CONFIG(srclib/apr,
|
||||
[$apache_apr_flags --prefix=$prefix --exec-prefix=$exec_prefix --libdir=$libdir --includedir=$includedir --bindir=$bindir --datadir=$datadir --with-installbuilddir=$installbuilddir],
|
||||
[--enable-layout=*|\'--enable-layout=*])
|
||||
dnl We must be the first to build and the last to be cleaned
|
||||
AP_BUILD_SRCLIB_DIRS="apr $AP_BUILD_SRCLIB_DIRS"
|
||||
AP_CLEAN_SRCLIB_DIRS="$AP_CLEAN_SRCLIB_DIRS apr"
|
||||
|
||||
dnl We have to find apr-N-config when we reconfigure APR.
|
||||
for majorver in 1 2; do
|
||||
test_apr_config="./srclib/apr/apr-${majorver}-config"
|
||||
if test -f "$test_apr_config"; then
|
||||
apr_config="$test_apr_config"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
APR_SETIFNULL(CC, `$apr_config --cc`)
|
||||
APR_SETIFNULL(CPP, `$apr_config --cpp`)
|
||||
APR_ADDTO(CFLAGS, `$apr_config --cflags`)
|
||||
APR_ADDTO(CPPFLAGS, `$apr_config --cppflags`)
|
||||
dnl internal-only CPPFLAGS (shouldn't affect third-party module builds)
|
||||
INTERNAL_CPPFLAGS=""
|
||||
APR_ADDTO(LDFLAGS, `$apr_config --ldflags`)
|
||||
SHLIBPATH_VAR=`$apr_config --shlib-path-var`
|
||||
APR_BINDIR=`$apr_config --bindir`
|
||||
APR_INCLUDEDIR=`$apr_config --includedir`
|
||||
APR_INCLUDES=`$apr_config --includes`
|
||||
APR_VERSION=`$apr_config --version`
|
||||
apr_major_version=`echo ${APR_VERSION} | sed 's,\..*,,'`
|
||||
APR_CONFIG="$APR_BINDIR/apr-${apr_major_version}-config"
|
||||
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Configuring Apache Portable Runtime Utility library...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
if test "x${apr_major_version}" = "x2"; then
|
||||
apu_found=obsolete
|
||||
elif test "x$with_included_apr" = "xyes"; then
|
||||
apu_found=reconfig
|
||||
if test ! -d srclib/apr-util && test ! -d $srcdir/srclib/apr-util; then
|
||||
AC_MSG_ERROR([Bundled APR-Util requested but not found at ./srclib/. Download and unpack the corresponding apr and apr-util packages to ./srclib/.])
|
||||
fi
|
||||
else
|
||||
dnl If httpd is buildconf'ed against an apr 2.x tree, then 1.x
|
||||
dnl isn't supported.
|
||||
ifdef([APR_FIND_APU], [
|
||||
APR_FIND_APU("$srcdir/srclib/apr-util", "./srclib/apr-util",
|
||||
1, ${apr_major_version})
|
||||
], [apu_found=no])
|
||||
fi
|
||||
|
||||
if test "$apu_found" = "no"; then
|
||||
AC_MSG_ERROR([APR-util not found. Please read the documentation.])
|
||||
fi
|
||||
|
||||
# Catch some misconfigurations:
|
||||
case ${apr_found}.${apu_found} in
|
||||
reconfig.yes)
|
||||
AC_MSG_ERROR([Cannot use an external APR-util with the bundled APR])
|
||||
;;
|
||||
yes.reconfig)
|
||||
AC_MSG_ERROR([Cannot use an external APR with the bundled APR-util])
|
||||
;;
|
||||
esac
|
||||
|
||||
if test "$apu_found" = "reconfig"; then
|
||||
APR_SUBDIR_CONFIG(srclib/apr-util,
|
||||
[--with-apr=../apr --prefix=$prefix --exec-prefix=$exec_prefix --libdir=$libdir --includedir=$includedir --bindir=$bindir],
|
||||
[--enable-layout=*|\'--enable-layout=*])
|
||||
dnl We must be the last to build and the first to be cleaned
|
||||
AP_BUILD_SRCLIB_DIRS="$AP_BUILD_SRCLIB_DIRS apr-util"
|
||||
AP_CLEAN_SRCLIB_DIRS="apr-util $AP_CLEAN_SRCLIB_DIRS"
|
||||
dnl APR and APR-Util major versions must match
|
||||
apu_config="./srclib/apr-util/apu-${apr_major_version}-config"
|
||||
fi
|
||||
|
||||
if test "$apu_found" = "obsolete"; then
|
||||
AC_MSG_NOTICE([APR-util obsoleted, woohoo])
|
||||
else
|
||||
APR_ADDTO(LDFLAGS, `$apu_config --ldflags`)
|
||||
APU_BINDIR=`$apu_config --bindir`
|
||||
APU_INCLUDEDIR=`$apu_config --includedir`
|
||||
APU_INCLUDES=`$apu_config --includes`
|
||||
APU_VERSION=`$apu_config --version`
|
||||
APU_CONFIG="$APU_BINDIR/apu-`echo ${APU_VERSION} | sed 's,\..*,,'`-config"
|
||||
fi
|
||||
|
||||
dnl In case we picked up CC and CPP from APR, get that info into the
|
||||
dnl config cache so that PCRE uses it. Otherwise, CC and CPP used for
|
||||
dnl PCRE and for our config tests will be whatever PCRE determines.
|
||||
AC_PROG_CC
|
||||
AC_PROG_CPP
|
||||
|
||||
dnl Try to get c99 support for variadic macros
|
||||
ifdef([AC_PROG_CC_C99], [AC_PROG_CC_C99])
|
||||
|
||||
if test "x${cache_file}" = "x/dev/null"; then
|
||||
# Likewise, ensure that CC and CPP are passed through to the pcre
|
||||
# configure script iff caching is disabled (the autoconf 2.5x default).
|
||||
export CC; export CPP
|
||||
fi
|
||||
|
||||
AC_ARG_WITH(pcre,
|
||||
APACHE_HELP_STRING(--with-pcre=PATH,Use external PCRE library))
|
||||
if test "x$with_pcre" = "x" || test "$with_pcre" = "yes"; then
|
||||
with_pcre="$PATH"
|
||||
else if which $with_pcre 2>/dev/null; then :; else
|
||||
with_pcre="$with_pcre/bin:$with_pcre"
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_CHECK_TARGET_TOOLS(PCRE_CONFIG, [pcre2-config pcre-config],
|
||||
[`which $with_pcre 2>/dev/null`], $with_pcre)
|
||||
|
||||
if test "x$PCRE_CONFIG" != "x"; then
|
||||
if $PCRE_CONFIG --version >/dev/null 2>&1; then :; else
|
||||
AC_MSG_ERROR([Did not find working script at $PCRE_CONFIG])
|
||||
fi
|
||||
case `$PCRE_CONFIG --version` in
|
||||
[1[0-9].*])
|
||||
AC_DEFINE(HAVE_PCRE2, 1, [Detected PCRE2])
|
||||
;;
|
||||
[[1-5].*])
|
||||
AC_MSG_ERROR([Need at least pcre version 6.0])
|
||||
;;
|
||||
esac
|
||||
AC_MSG_NOTICE([Using external PCRE library from $PCRE_CONFIG])
|
||||
APR_ADDTO(PCRE_INCLUDES, [`$PCRE_CONFIG --cflags`])
|
||||
APR_ADDTO(PCRE_LIBS, [`$PCRE_CONFIG --libs8 2>/dev/null || $PCRE_CONFIG --libs`])
|
||||
else
|
||||
AC_MSG_ERROR([pcre(2)-config for libpcre not found. PCRE is required and available from http://pcre.org/])
|
||||
fi
|
||||
APACHE_SUBST(PCRE_LIBS)
|
||||
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Configuring Apache httpd...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
dnl If the source dir is not equal to the build dir,
|
||||
dnl then we are running in VPATH mode.
|
||||
|
||||
APR_ADDTO(INCLUDES, [-I.])
|
||||
|
||||
if test "$abs_builddir" != "$abs_srcdir"; then
|
||||
APR_ADDTO(INCLUDES, [-I\$(top_builddir)/include])
|
||||
fi
|
||||
|
||||
APR_ADDTO(INCLUDES, [-I\$(top_srcdir)/os/\$(OS_DIR) -I\$(top_srcdir)/include])
|
||||
|
||||
# apr/apr-util --includes may pick up system paths for dependent
|
||||
# libraries, so ensure these are later in INCLUDES than local source
|
||||
# directories.
|
||||
APR_ADDTO(INCLUDES, $APR_INCLUDES)
|
||||
APR_ADDTO(INCLUDES, $APU_INCLUDES)
|
||||
|
||||
dnl Add in path to PCRE includes
|
||||
APR_ADDTO(INCLUDES, $PCRE_INCLUDES)
|
||||
|
||||
save_CPPFLAGS="$CPPFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS $PCRE_INCLUDES"
|
||||
AC_EGREP_CPP(yes,
|
||||
[
|
||||
#ifdef HAVE_PCRE2
|
||||
yes
|
||||
#else
|
||||
#include <pcre.h>
|
||||
#ifdef PCRE_DUPNAMES
|
||||
yes
|
||||
#endif
|
||||
#endif
|
||||
],pcre_have_dupnames=yes,pcre_have_dupnames=no)
|
||||
if test "$pcre_have_dupnames" != "yes"; then
|
||||
AC_MSG_ERROR([pcre version does not support PCRE_DUPNAMES])
|
||||
fi
|
||||
CPPFLAGS="$save_CPPFLAGS"
|
||||
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Applying OS-specific hints for httpd...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
case $host in
|
||||
*os2*)
|
||||
# Use a custom made libtool replacement
|
||||
echo "using aplibtool"
|
||||
LIBTOOL="$abs_srcdir/srclib/apr/build/aplibtool"
|
||||
SH_LIBTOOL="$LIBTOOL --shared --export-all"
|
||||
SH_LIBS="\$(ALL_LIBS)"
|
||||
CORE_IMPLIB_FILE="ApacheCoreOS2.la"
|
||||
CORE_IMPLIB="$abs_srcdir/server/$CORE_IMPLIB_FILE"
|
||||
MK_IMPLIB="emximp"
|
||||
other_targets="$other_targets os2core"
|
||||
INSTALL_PROG_FLAGS="-e .exe"
|
||||
SHLTCFLAGS=""
|
||||
LTCFLAGS=""
|
||||
;;
|
||||
*)
|
||||
if test "x$LTFLAGS" = "x"; then
|
||||
LTFLAGS='--silent'
|
||||
fi
|
||||
my_libtool=`$apr_config --apr-libtool`
|
||||
LIBTOOL="$my_libtool \$(LTFLAGS)"
|
||||
libtoolversion=`$my_libtool --version`
|
||||
case $libtoolversion in
|
||||
*1.[[45]]* | *[[2-9]].[[0-9]]*)
|
||||
SH_LIBTOOL='$(LIBTOOL)'
|
||||
SHLTCFLAGS="-prefer-pic"
|
||||
LTCFLAGS="-prefer-non-pic -static"
|
||||
;;
|
||||
*)
|
||||
SH_LIBTOOL='$(SHELL) $(top_builddir)/shlibtool $(LTFLAGS)'
|
||||
SHLTCFLAGS=""
|
||||
LTCFLAGS=""
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
APACHE_SUBST(SHLTCFLAGS)
|
||||
APACHE_SUBST(LTCFLAGS)
|
||||
|
||||
case $host in
|
||||
*-apple-aux3*)
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
*os2-emx*)
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
*-linux-*)
|
||||
case `uname -r` in
|
||||
# Unserialized accept() was not recommended until Linux 2.2.
|
||||
[[01]].* | 2.[[01]]* )
|
||||
;;
|
||||
* )
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*486-*-bsdi* | *-netbsd* | *-freebsd* | *-apple-darwin* | *-dec-osf* | *-qnx)
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
*-solaris2*)
|
||||
dnl This is a hack -- we should be using AC_TRY_RUN instead
|
||||
ap_platform_runtime_link_flag="-R"
|
||||
dnl solaris 8 and above don't have a thundering herd
|
||||
dnl not sure about rev's before this one.
|
||||
case `uname -r` in
|
||||
5.[[567]]*)
|
||||
;;
|
||||
* )
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*cygwin*)
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
*mingw32*)
|
||||
APR_ADDTO(INTERNAL_CPPFLAGS, [-DAP_DECLARE_EXPORT])
|
||||
APR_SETIFNULL(ac_cv_func_times, [no])
|
||||
APR_SETIFNULL(ac_cv_func_getpwnam, [no])
|
||||
APR_SETIFNULL(ac_cv_func_getgrnam, [no])
|
||||
;;
|
||||
*aix*)
|
||||
aixver=`echo $host | sed 's/^[[^0-9]]*//' | sed 's/\.//g'`
|
||||
if test $aixver -ge 4320; then
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
fi
|
||||
;;
|
||||
*os390*)
|
||||
APR_SETVAR(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, [1])
|
||||
;;
|
||||
esac
|
||||
|
||||
APR_SETVAR(AP_NONBLOCK_WHEN_MULTI_LISTEN, [1])
|
||||
|
||||
dnl
|
||||
dnl Process command line arguments. This is done early in the process so the
|
||||
dnl user can get feedback quickly in case of an error.
|
||||
dnl
|
||||
dnl ### need to move some of the arguments "up here"
|
||||
|
||||
dnl ## Check for programs
|
||||
|
||||
AC_PATH_PROG(RM, rm)
|
||||
AC_PATH_PROG(PKGCONFIG, pkg-config)
|
||||
AC_PATH_PROG(RSYNC, rsync)
|
||||
AC_PATH_PROG(SVN, svn)
|
||||
AC_PROG_AWK
|
||||
AC_PROG_LN_S
|
||||
AC_CHECK_TOOL(RANLIB, ranlib, true)
|
||||
dnl AC_PATH_PROG(PERL_PATH, perl)
|
||||
AC_CHECK_PROGS(LYNX_PATH,[lynx links elinks], [lynx])
|
||||
|
||||
# Hard-coded install programs
|
||||
MKINSTALLDIRS="\$(abs_srcdir)/build/mkdir.sh"
|
||||
INSTALL="\$(LIBTOOL) --mode=install \$(abs_srcdir)/build/install.sh -c"
|
||||
APACHE_SUBST(MKINSTALLDIRS)
|
||||
APACHE_SUBST(INSTALL)
|
||||
|
||||
dnl Various OS checks that apparently set required flags
|
||||
ifdef([AC_USE_SYSTEM_EXTENSIONS], [
|
||||
AC_USE_SYSTEM_EXTENSIONS
|
||||
], [
|
||||
AC_AIX
|
||||
AC_MINIX
|
||||
])
|
||||
|
||||
AC_ISC_POSIX
|
||||
|
||||
# Ensure that satisfactory versions of apr and apr-util are
|
||||
# found if external copies are configured.
|
||||
if test "${apr_found}" = "yes"; then
|
||||
# Require at least APR 1.3.x otherwise fail
|
||||
APACHE_CHECK_APxVER([apr], 1, 3)
|
||||
fi
|
||||
|
||||
if test "${apu_found}" = "yes"; then
|
||||
# Require at least APR-util 1.3.x otherwise fail
|
||||
if test "${apr_found}" = "yes"; then
|
||||
# we need to add the APR includes to CPPFLAGS
|
||||
apu_ckver_CPPFLAGS="$CPPFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS `$apr_config --includes`"
|
||||
APACHE_CHECK_APxVER([apu], 1, 3)
|
||||
CPPFLAGS="$apu_ckver_CPPFLAGS"
|
||||
else
|
||||
APACHE_CHECK_APxVER([apu], 1, 3)
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl Check for what we can generate dependency files with
|
||||
APR_CHECK_DEPEND
|
||||
|
||||
dnl ## Check for libraries
|
||||
|
||||
dnl ## Check for header files
|
||||
|
||||
dnl I think these are just used all over the place, so just check for
|
||||
dnl them at the base of the tree. If some are specific to a single
|
||||
dnl directory, they should be moved (Comment #Spoon)
|
||||
|
||||
dnl Regarding standard header files: AC_HEADER_STDC doesn't set symbols
|
||||
dnl HAVE_STRING_H, HAVE_STDLIB_H, etc., so those are checked for
|
||||
dnl explicitly so that the normal HAVE_xxx_H symbol is defined.
|
||||
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS( \
|
||||
string.h \
|
||||
limits.h \
|
||||
unistd.h \
|
||||
sys/socket.h \
|
||||
pwd.h \
|
||||
grp.h \
|
||||
strings.h \
|
||||
sys/prctl.h \
|
||||
sys/processor.h \
|
||||
sys/sem.h \
|
||||
sys/sdt.h \
|
||||
sys/loadavg.h
|
||||
)
|
||||
AC_HEADER_SYS_WAIT
|
||||
|
||||
dnl ## Check for typedefs, structures, and compiler characteristics.
|
||||
|
||||
AC_C_CONST
|
||||
|
||||
dnl ## Check for library functions
|
||||
dnl ## sqrt() only needed in support/ab.c
|
||||
saved_LIBS="$LIBS"
|
||||
LIBS=""
|
||||
AC_SEARCH_LIBS(sqrt, m)
|
||||
MATH_LIBS="$LIBS"
|
||||
APACHE_SUBST(MATH_LIBS)
|
||||
LIBS="$saved_LIBS"
|
||||
|
||||
saved_LIBS="$LIBS"
|
||||
LIBS=""
|
||||
AC_SEARCH_LIBS(crypt, crypt)
|
||||
CRYPT_LIBS="$LIBS"
|
||||
APACHE_SUBST(CRYPT_LIBS)
|
||||
|
||||
if test "$ac_cv_search_crypt" != "no"; then
|
||||
# Test crypt() with the SHA-512 test vector from https://akkadia.org/drepper/SHA-crypt.txt
|
||||
AC_CACHE_CHECK([whether crypt() supports SHA-2], [ap_cv_crypt_sha2], [
|
||||
AC_RUN_IFELSE([AC_LANG_PROGRAM([[
|
||||
#include <crypt.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#define PASSWD_0 "Hello world!"
|
||||
#define SALT_0 "\$6\$saltstring"
|
||||
#define EXPECT_0 "\$6\$saltstring\$svn8UoSVapNtMuq1ukKS4tPQd8iKwSMHWjl/O817G3uBnIFNjnQJu" \
|
||||
"esI68u4OTLiBFdcbYEdFCoEOfaS35inz1"
|
||||
]], [char *result = crypt(PASSWD_0, SALT_0);
|
||||
if (!result) return 1;
|
||||
if (strcmp(result, EXPECT_0)) return 2;
|
||||
])], [ap_cv_crypt_sha2=yes], [ap_cv_crypt_sha2=no], [ap_cv_crypt_sha2=no])])
|
||||
if test "$ap_cv_crypt_sha2" = yes; then
|
||||
AC_DEFINE([HAVE_CRYPT_SHA2], 1, [Define if crypt() supports SHA-2 hashes])
|
||||
fi
|
||||
fi
|
||||
|
||||
LIBS="$saved_LIBS"
|
||||
|
||||
dnl See Comment #Spoon
|
||||
|
||||
AC_CHECK_FUNCS( \
|
||||
getpwnam \
|
||||
getgrnam \
|
||||
initgroups \
|
||||
bindprocessor \
|
||||
prctl \
|
||||
timegm \
|
||||
getpgid \
|
||||
fopen64 \
|
||||
getloadavg \
|
||||
gettid
|
||||
)
|
||||
|
||||
dnl confirm that a void pointer is large enough to store a long integer
|
||||
APACHE_CHECK_VOID_PTR_LEN
|
||||
|
||||
if test $ac_cv_func_gettid = no; then
|
||||
# On Linux before glibc 2.30, gettid() is only usable via syscall()
|
||||
AC_CACHE_CHECK([for gettid() via syscall], ap_cv_gettid,
|
||||
[AC_TRY_RUN(#define _GNU_SOURCE
|
||||
#include <unistd.h>
|
||||
#include <sys/syscall.h>
|
||||
#include <sys/types.h>
|
||||
int main(int argc, char **argv) {
|
||||
pid_t t = syscall(SYS_gettid); return t == -1 ? 1 : 0; },
|
||||
[ap_cv_gettid=yes], [ap_cv_gettid=no], [ap_cv_gettid=no])])
|
||||
if test "$ap_cv_gettid" = "yes"; then
|
||||
AC_DEFINE(HAVE_SYS_GETTID, 1, [Define if you have gettid() via syscall()])
|
||||
fi
|
||||
fi
|
||||
|
||||
case ${host}X${ac_cv_func_gettid}X${ap_cv_gettid} in
|
||||
*linux-*XyesX* | *linux-*XnoXyes)
|
||||
AC_DEFINE(DEFAULT_LOG_TID, ["g"], [Define as default argument for thread id in error logging])
|
||||
;;
|
||||
esac
|
||||
|
||||
dnl ## Check for the tm_gmtoff field in struct tm to get the timezone diffs
|
||||
AC_CACHE_CHECK([for tm_gmtoff in struct tm], ac_cv_struct_tm_gmtoff,
|
||||
[AC_TRY_COMPILE([#include <sys/types.h>
|
||||
#include <time.h>], [struct tm tm; tm.tm_gmtoff;],
|
||||
ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)])
|
||||
if test "$ac_cv_struct_tm_gmtoff" = "yes"; then
|
||||
AC_DEFINE(HAVE_GMTOFF, 1, [Define if struct tm has a tm_gmtoff field])
|
||||
fi
|
||||
|
||||
APACHE_CHECK_SYSTEMD
|
||||
|
||||
dnl ## Set up any appropriate OS-specific environment variables for apachectl
|
||||
|
||||
case $host in
|
||||
*aix*)
|
||||
# for 32-bit builds, increase MAXDATA to allow lots of threads
|
||||
if test x$OBJECT_MODE != x64; then
|
||||
OS_SPECIFIC_VARS="LDR_CNTRL=\"MAXDATA=0x80000000\" ; export LDR_CNTRL ;"
|
||||
fi
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS AIXTHREAD_SCOPE=S ; export AIXTHREAD_SCOPE"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; AIXTHREAD_MUTEX_DEBUG=OFF ; export AIXTHREAD_MUTEX_DEBUG"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; AIXTHREAD_RWLOCK_DEBUG=OFF ; export AIXTHREAD_RWLOCK_DEBUG"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; AIXTHREAD_COND_DEBUG=OFF ; export AIXTHREAD_COND_DEBUG"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; SPINLOOPTIME=1000 ; export SPINLOOPTIME"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; YIELDLOOPTIME=8 ; export YIELDLOOPTIME"
|
||||
OS_SPECIFIC_VARS="$OS_SPECIFIC_VARS ; MALLOCMULTIHEAP=considersize,heaps:8 ; export MALLOCMULTIHEAP"
|
||||
;;
|
||||
*os390*)
|
||||
OS_SPECIFIC_VARS="export _CEE_RUNOPTS=\"STACK(,,ANY)\" ; export _EDC_ADD_ERRNO2=1"
|
||||
;;
|
||||
*)
|
||||
OS_SPECIFIC_VARS=""
|
||||
esac
|
||||
|
||||
AC_ARG_WITH(port,APACHE_HELP_STRING(--with-port=PORT,Port on which to listen (default is 80)),
|
||||
[if test "$withval" = "yes"; then AC_MSG_ERROR('option --with-port requires a value (the TCP port number)'); else PORT="$withval"; fi],
|
||||
[PORT=80])
|
||||
|
||||
AC_ARG_WITH(sslport,APACHE_HELP_STRING(--with-sslport=SSLPORT,Port on which to securelisten (default is 443)),
|
||||
[if test "$withval" = "yes"; then AC_MSG_ERROR('option --with-sslport requires a value (the SSL TCP port number)'); else SSLPORT="$withval"; fi],
|
||||
[SSLPORT=443])
|
||||
|
||||
DTRACE=true
|
||||
AC_ARG_ENABLE(dtrace,APACHE_HELP_STRING(--enable-dtrace,Enable DTrace probes),
|
||||
[
|
||||
enable_dtrace=$enableval
|
||||
if test "$enableval" = "yes"; then
|
||||
APR_ADDTO(CPPFLAGS, -DAPR_DTRACE_PROVIDER)
|
||||
AC_MSG_ERROR('DTrace Support in the build system is not complete. Patches Welcome!')
|
||||
fi
|
||||
],
|
||||
[
|
||||
enable_dtrace=no
|
||||
])
|
||||
|
||||
dnl Disabled dtrace build for now.
|
||||
enable_dtrace=no
|
||||
|
||||
case $host in
|
||||
*-solaris2*)
|
||||
if test $enable_dtrace = "yes" -a "$ac_cv_header_sys_sdt_h" = "yes"; then
|
||||
AC_DEFINE(AP_ENABLE_DTRACE, 1,
|
||||
[Enable DTrace probes])
|
||||
DTRACE="/usr/sbin/dtrace $DTRACEFLAGS"
|
||||
test -f include/apache_probes.h || $DTRACE -h -s apache_probes.d -o include/apache_probes.h
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
APACHE_SUBST(DTRACE)
|
||||
|
||||
AC_ARG_ENABLE(hook-probes,APACHE_HELP_STRING(--enable-hook-probes,Enable APR hook probes),
|
||||
[
|
||||
if test "$enableval" = "yes"; then
|
||||
AC_DEFINE(AP_HOOK_PROBES_ENABLED, 1,
|
||||
[Enable the APR hook probes capability, reading from ap_hook_probes.h])
|
||||
APR_ADDTO(INTERNAL_CPPFLAGS, -DAP_HOOK_PROBES_ENABLED)
|
||||
fi
|
||||
])dnl
|
||||
|
||||
AC_ARG_ENABLE(exception-hook,APACHE_HELP_STRING(--enable-exception-hook,Enable fatal exception hook),
|
||||
[
|
||||
if test "$enableval" = "yes"; then
|
||||
AC_DEFINE(AP_ENABLE_EXCEPTION_HOOK, 1,
|
||||
[Allow modules to run hook after a fatal exception])
|
||||
fi
|
||||
])dnl
|
||||
|
||||
AC_ARG_ENABLE(load-all-modules,APACHE_HELP_STRING(--enable-load-all-modules,Load all modules),
|
||||
[
|
||||
LOAD_ALL_MODULES=$enableval
|
||||
AC_MSG_NOTICE([Setting "LOAD_ALL_MODULES" to $LOAD_ALL_MODULES])
|
||||
],
|
||||
[
|
||||
LOAD_ALL_MODULES="no"
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(maintainer-mode,APACHE_HELP_STRING(--enable-maintainer-mode,Turn on debugging and compile time warnings and load all compiled modules),
|
||||
[
|
||||
if test "$enableval" = "yes"; then
|
||||
APR_ADDTO(NOTEST_CPPFLAGS, -DAP_DEBUG)
|
||||
if test "$GCC" = "yes"; then
|
||||
APACHE_ADD_GCC_CFLAG([-std=c89])
|
||||
APACHE_ADD_GCC_CFLAG([-Werror])
|
||||
APACHE_ADD_GCC_CFLAG([-Wall])
|
||||
APACHE_ADD_GCC_CFLAG([-Wstrict-prototypes])
|
||||
APACHE_ADD_GCC_CFLAG([-Wmissing-prototypes])
|
||||
APACHE_ADD_GCC_CFLAG([-Wmissing-declarations])
|
||||
APACHE_ADD_GCC_CFLAG([-Wdeclaration-after-statement])
|
||||
APACHE_ADD_GCC_CFLAG([-Wpointer-arith])
|
||||
APACHE_ADD_GCC_CFLAG([-Wformat])
|
||||
APACHE_ADD_GCC_CFLAG([-Wformat-security])
|
||||
APACHE_ADD_GCC_CFLAG([-Wunused])
|
||||
elif test "$AIX_XLC" = "yes"; then
|
||||
APR_ADDTO(NOTEST_CFLAGS,-qfullpath -qcheck=all -qinfo=pro)
|
||||
fi
|
||||
if test "x$enable_load_all_modules" = "x"; then
|
||||
LOAD_ALL_MODULES=yes
|
||||
AC_MSG_NOTICE([Maintainer mode setting "LOAD_ALL_MODULES" to $LOAD_ALL_MODULES])
|
||||
fi
|
||||
if test "x$enable_bucketeer" = "x"; then
|
||||
enable_bucketeer=yes
|
||||
AC_MSG_NOTICE([Maintainer mode setting "enable_bucketeer" to yes])
|
||||
fi
|
||||
fi
|
||||
])dnl
|
||||
|
||||
AC_ARG_ENABLE(debugger-mode,APACHE_HELP_STRING(--enable-debugger-mode,Turn on debugging and compile time warnings and turn off optimization),
|
||||
[
|
||||
if test "$enableval" = "yes"; then
|
||||
APR_ADDTO(NOTEST_CPPFLAGS, -DAP_DEBUG)
|
||||
if test "$GCC" = "yes"; then
|
||||
APACHE_ADD_GCC_CFLAG([-O0])
|
||||
APACHE_ADD_GCC_CFLAG([-Wall])
|
||||
APACHE_ADD_GCC_CFLAG([-Wstrict-prototypes])
|
||||
APACHE_ADD_GCC_CFLAG([-Wmissing-prototypes])
|
||||
APACHE_ADD_GCC_CFLAG([-Wmissing-declarations])
|
||||
APACHE_ADD_GCC_CFLAG([-Wdeclaration-after-statement])
|
||||
APACHE_ADD_GCC_CFLAG([-Werror=declaration-after-statement])
|
||||
APACHE_ADD_GCC_CFLAG([-Wpointer-arith])
|
||||
APACHE_ADD_GCC_CFLAG([-Wformat])
|
||||
APACHE_ADD_GCC_CFLAG([-Wformat-security])
|
||||
APACHE_ADD_GCC_CFLAG([-Werror=format-security])
|
||||
elif test "$AIX_XLC" = "yes"; then
|
||||
APR_ADDTO(NOTEST_CFLAGS,-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro)
|
||||
fi
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl Conditionally enable PIE support for GNU toolchains.
|
||||
AC_ARG_ENABLE(pie,APACHE_HELP_STRING(--enable-pie,Build httpd as a Position Independent Executable))
|
||||
if test "$enable_pie" = "yes"; then
|
||||
AC_CACHE_CHECK([whether $CC accepts PIE flags], [ap_cv_cc_pie], [
|
||||
save_CFLAGS=$CFLAGS
|
||||
save_LDFLAGS=$LDFLAGS
|
||||
CFLAGS="$CFLAGS -fPIE"
|
||||
LDFLAGS="$LDFLAGS -pie"
|
||||
AC_TRY_RUN([static int foo[30000]; int main () { return 0; }],
|
||||
[ap_cv_cc_pie=yes], [ap_cv_cc_pie=no], [ap_cv_cc_pie=yes])
|
||||
CFLAGS=$save_CFLAGS
|
||||
LDFLAGS=$save_LDFLAGS
|
||||
])
|
||||
if test "$ap_cv_cc_pie" = "yes"; then
|
||||
PICFLAGS="-fPIE"
|
||||
PILDFLAGS="-pie"
|
||||
else
|
||||
AC_ERROR([--enable-pie requested but $CC failed using PIE flags])
|
||||
fi
|
||||
fi
|
||||
APACHE_SUBST(PICFLAGS)
|
||||
APACHE_SUBST(PILDFLAGS)
|
||||
|
||||
prefix="$orig_prefix"
|
||||
APACHE_ENABLE_MODULES
|
||||
|
||||
dnl reading config stubs
|
||||
esyscmd(./build/config-stubs .)
|
||||
|
||||
APACHE_SUBST(progname)
|
||||
APACHE_SUBST(OS)
|
||||
APACHE_SUBST(OS_DIR)
|
||||
APACHE_SUBST(BUILTIN_LIBS)
|
||||
APACHE_SUBST(SHLIBPATH_VAR)
|
||||
APACHE_SUBST(OS_SPECIFIC_VARS)
|
||||
|
||||
PRE_SHARED_CMDS='echo ""'
|
||||
POST_SHARED_CMDS='echo ""'
|
||||
|
||||
dnl apache_need_shared tells us if Apache modules are being built as DSOs
|
||||
|
||||
if test "$apache_need_shared" = "yes"; then
|
||||
if test -f $ac_aux_dir/ltconfig; then
|
||||
$SHELL $ac_aux_dir/ltconfig --output=shlibtool --disable-static --srcdir=$ac_aux_dir --cache-file=./config.cache $ac_aux_dir/ltmain.sh
|
||||
fi
|
||||
shared_build="shared-build"
|
||||
fi
|
||||
|
||||
dnl enable_so tells us if *any* modules can be built as DSOs
|
||||
|
||||
if test "$enable_so" = "yes" -o "$enable_so" = "static"; then
|
||||
case $host in
|
||||
*-ibm-aix*)
|
||||
APR_ADDTO(HTTPD_LDFLAGS, [-Wl,-uXML_Parse -Wl,-bE:$abs_builddir/server/httpd.exp])
|
||||
APR_ADDTO(SH_LDFLAGS, [\$(EXTRA_LDFLAGS) \$(EXTRA_LIBS)])
|
||||
APR_ADDTO(UTIL_LDFLAGS, [-Wl,-uXML_Parse])
|
||||
;;
|
||||
*os390)
|
||||
APR_ADDTO(HTTPD_LDFLAGS, [--main=$abs_srcdir/server/main.o --core-dll=$abs_srcdir/apachecore.dll])
|
||||
APR_ADDTO(SH_LDFLAGS, [--core-dll=$abs_srcdir/apachecore.dll])
|
||||
esac
|
||||
MOD_SO_ENABLED=yes
|
||||
fi
|
||||
AC_SUBST(MOD_SO_ENABLED)
|
||||
|
||||
APACHE_SUBST(PRE_SHARED_CMDS)
|
||||
APACHE_SUBST(POST_SHARED_CMDS)
|
||||
APACHE_SUBST(shared_build)
|
||||
|
||||
AC_ARG_WITH(program-name,
|
||||
APACHE_HELP_STRING(--with-program-name,alternate executable name),[
|
||||
progname="$withval" ], [
|
||||
progname="httpd"] )
|
||||
|
||||
# SuExec parameters
|
||||
AC_ARG_WITH(suexec-bin,
|
||||
APACHE_HELP_STRING(--with-suexec-bin,Path to suexec binary),[
|
||||
AC_DEFINE_UNQUOTED(SUEXEC_BIN, "$withval", [Path to suexec binary] )
|
||||
] )
|
||||
|
||||
AC_ARG_WITH(suexec-caller,
|
||||
APACHE_HELP_STRING(--with-suexec-caller,User allowed to call SuExec),[
|
||||
AC_DEFINE_UNQUOTED(AP_HTTPD_USER, "$withval", [User allowed to call SuExec] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-userdir,
|
||||
APACHE_HELP_STRING(--with-suexec-userdir,User subdirectory),[
|
||||
AC_DEFINE_UNQUOTED(AP_USERDIR_SUFFIX, "$withval", [User subdirectory] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-docroot,
|
||||
APACHE_HELP_STRING(--with-suexec-docroot,SuExec root directory),[
|
||||
AC_DEFINE_UNQUOTED(AP_DOC_ROOT, "$withval", [SuExec root directory] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-uidmin,
|
||||
APACHE_HELP_STRING(--with-suexec-uidmin,Minimal allowed UID),[
|
||||
AC_DEFINE_UNQUOTED(AP_UID_MIN, $withval, [Minimum allowed UID] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-gidmin,
|
||||
APACHE_HELP_STRING(--with-suexec-gidmin,Minimal allowed GID),[
|
||||
AC_DEFINE_UNQUOTED(AP_GID_MIN, $withval, [Minimum allowed GID] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-logfile,
|
||||
APACHE_HELP_STRING(--with-suexec-logfile,Set the logfile),[
|
||||
if test "x$withval" = "xyes"; then
|
||||
AC_MSG_ERROR([log filename required for --with-suexec-logfile option])
|
||||
elif test "x$withval" != "xno"; then
|
||||
AC_DEFINE_UNQUOTED(AP_LOG_EXEC, "$withval", [SuExec log file])
|
||||
fi
|
||||
])
|
||||
|
||||
AC_ARG_WITH(suexec-syslog,
|
||||
APACHE_HELP_STRING(--with-suexec-syslog,Use syslog for suexec logging),[
|
||||
if test $withval = "yes"; then
|
||||
if test "x${with_suexec_logfile}" != "xno"; then
|
||||
AC_MSG_NOTICE([hint: use "--without-suexec-logfile --with-suexec-syslog"])
|
||||
AC_MSG_ERROR([suexec does not support both logging to file and syslog])
|
||||
fi
|
||||
AC_CHECK_FUNCS([vsyslog], [], [
|
||||
AC_MSG_ERROR([cannot support syslog from suexec without vsyslog()])])
|
||||
AC_DEFINE(AP_LOG_SYSLOG, 1, [SuExec log to syslog])
|
||||
fi
|
||||
])
|
||||
|
||||
|
||||
AC_ARG_WITH(suexec-safepath,
|
||||
APACHE_HELP_STRING(--with-suexec-safepath,Set the safepath),[
|
||||
AC_DEFINE_UNQUOTED(AP_SAFE_PATH, "$withval", [safe shell path for SuExec] ) ] )
|
||||
|
||||
AC_ARG_WITH(suexec-umask,
|
||||
APACHE_HELP_STRING(--with-suexec-umask,umask for suexec'd process),[
|
||||
AC_DEFINE_UNQUOTED(AP_SUEXEC_UMASK, 0$withval, [umask for suexec'd process] ) ] )
|
||||
|
||||
INSTALL_SUEXEC=setuid
|
||||
AC_ARG_ENABLE([suexec-capabilities],
|
||||
APACHE_HELP_STRING(--enable-suexec-capabilities,Use Linux capability bits not setuid root suexec), [
|
||||
INSTALL_SUEXEC=caps
|
||||
AC_DEFINE(AP_SUEXEC_CAPABILITIES, 1,
|
||||
[Enable if suexec is installed with Linux capabilities, not setuid])
|
||||
])
|
||||
APACHE_SUBST(INSTALL_SUEXEC)
|
||||
|
||||
dnl APR should go after the other libs, so the right symbols can be picked up
|
||||
if test x${apu_found} != xobsolete; then
|
||||
AP_LIBS="$AP_LIBS `$apu_config --avoid-ldap --link-libtool --libs`"
|
||||
fi
|
||||
AP_LIBS="$AP_LIBS `$apr_config --link-libtool --libs`"
|
||||
APACHE_SUBST(AP_LIBS)
|
||||
APACHE_SUBST(AP_BUILD_SRCLIB_DIRS)
|
||||
APACHE_SUBST(AP_CLEAN_SRCLIB_DIRS)
|
||||
|
||||
AC_DEFINE(AP_USING_AUTOCONF, 1,
|
||||
[Using autoconf to configure Apache])
|
||||
|
||||
if test "$SINGLE_LISTEN_UNSERIALIZED_ACCEPT" = "1"; then
|
||||
AC_DEFINE(SINGLE_LISTEN_UNSERIALIZED_ACCEPT, 1,
|
||||
[This platform doesn't suffer from the thundering herd problem])
|
||||
fi
|
||||
|
||||
if test "$AP_NONBLOCK_WHEN_MULTI_LISTEN" = "1"; then
|
||||
AC_DEFINE(AP_NONBLOCK_WHEN_MULTI_LISTEN, 1,
|
||||
[Listening sockets are non-blocking when there are more than 1])
|
||||
fi
|
||||
|
||||
APR_CHECK_APR_DEFINE(APR_HAVE_IPV6)
|
||||
|
||||
AC_ARG_ENABLE(v4-mapped,APACHE_HELP_STRING(--enable-v4-mapped,Allow IPv6 sockets to handle IPv4 connections),
|
||||
[
|
||||
v4mapped=$enableval
|
||||
],
|
||||
[
|
||||
case $host in
|
||||
*freebsd[[1234]].*)
|
||||
v4mapped=yes
|
||||
;;
|
||||
*freebsd*|*netbsd*|*openbsd*)
|
||||
v4mapped=no
|
||||
;;
|
||||
*)
|
||||
v4mapped=yes
|
||||
;;
|
||||
esac
|
||||
if ap_mpm_is_enabled winnt; then
|
||||
dnl WinNT MPM doesn't support this.
|
||||
v4mapped=no
|
||||
fi
|
||||
])
|
||||
|
||||
if test $v4mapped = "yes" -a $ac_cv_define_APR_HAVE_IPV6 = "yes"; then
|
||||
AC_DEFINE(AP_ENABLE_V4_MAPPED, 1,
|
||||
[Allow IPv4 connections on IPv6 listening sockets])
|
||||
fi
|
||||
|
||||
APACHE_FAST_OUTPUT(Makefile modules/Makefile srclib/Makefile)
|
||||
APACHE_FAST_OUTPUT(os/Makefile server/Makefile)
|
||||
APACHE_FAST_OUTPUT(support/Makefile)
|
||||
|
||||
if test -d ./test; then
|
||||
APACHE_FAST_OUTPUT(test/Makefile)
|
||||
fi
|
||||
if test -d ./test/modules/http2; then
|
||||
APACHE_FAST_OUTPUT(test/Makefile)
|
||||
AC_CONFIG_FILES([test/pyhttpd/config.ini])
|
||||
APACHE_FAST_OUTPUT(test/clients/Makefile)
|
||||
fi
|
||||
|
||||
dnl ## Finalize the variables
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Restore user-defined environment settings...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
APACHE_CONF_SEL_CC=${CC}
|
||||
APACHE_CONF_SEL_CFLAGS="${CFLAGS} ${EXTRA_CFLAGS} ${NOTEST_CFLAGS}"
|
||||
APACHE_CONF_SEL_CPPFLAGS="${CPPFLAGS} ${EXTRA_CPPFLAGS} ${NOTEST_CPPFLAGS}"
|
||||
APACHE_CONF_SEL_LDFLAGS="${LDFLAGS} ${EXTRA_LDFLAGS} ${NOTEST_LDFLAGS}"
|
||||
APACHE_CONF_SEL_LIBS="${LIBS} ${EXTRA_LIBS} ${NOTEST_LIBS}"
|
||||
APACHE_CONF_SEL_CPP=${CPP}
|
||||
|
||||
APR_RESTORE_THE_ENVIRONMENT(CPPFLAGS, EXTRA_)
|
||||
APR_RESTORE_THE_ENVIRONMENT(CFLAGS, EXTRA_)
|
||||
APR_RESTORE_THE_ENVIRONMENT(CXXFLAGS, EXTRA_)
|
||||
APR_RESTORE_THE_ENVIRONMENT(LDFLAGS, EXTRA_)
|
||||
APR_RESTORE_THE_ENVIRONMENT(LIBS, EXTRA_)
|
||||
APR_RESTORE_THE_ENVIRONMENT(INCLUDES, EXTRA_)
|
||||
|
||||
AC_MSG_NOTICE([])
|
||||
AC_MSG_NOTICE([Construct makefiles and header files...])
|
||||
AC_MSG_NOTICE([])
|
||||
|
||||
APACHE_GEN_CONFIG_VARS
|
||||
|
||||
dnl ## Build modules.c
|
||||
rm -f modules.c
|
||||
echo $MODLIST | $AWK -f $srcdir/build/build-modules-c.awk > modules.c
|
||||
|
||||
APR_EXPAND_VAR(ap_prefix, $prefix)
|
||||
AC_DEFINE_UNQUOTED(HTTPD_ROOT, "${ap_prefix}",
|
||||
[Root directory of the Apache install area])
|
||||
AC_DEFINE_UNQUOTED(SERVER_CONFIG_FILE, "${rel_sysconfdir}/${progname}.conf",
|
||||
[Location of the config file, relative to the Apache root directory])
|
||||
AC_DEFINE_UNQUOTED(AP_TYPES_CONFIG_FILE, "${rel_sysconfdir}/mime.types",
|
||||
[Location of the MIME types config file, relative to the Apache root directory])
|
||||
|
||||
perlbin=`$ac_aux_dir/PrintPath perl`
|
||||
if test "x$perlbin" = "x"; then
|
||||
perlbin="/replace/with/path/to/perl/interpreter"
|
||||
fi
|
||||
AC_SUBST(perlbin)
|
||||
|
||||
dnl If we are running on BSD/OS, we need to use the BSD .include syntax.
|
||||
|
||||
BSD_MAKEFILE=no
|
||||
ap_make_include=include
|
||||
ap_make_delimiter=' '
|
||||
case $host in
|
||||
*bsdi*)
|
||||
# Check whether they've installed GNU make
|
||||
if make --version > /dev/null 2>&1; then
|
||||
true
|
||||
else
|
||||
BSD_MAKEFILE=yes
|
||||
ap_make_include=.include
|
||||
ap_make_delimiter='"'
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
AC_SUBST(ap_make_include)
|
||||
AC_SUBST(ap_make_delimiter)
|
||||
|
||||
dnl Ensure that docs/conf is created.
|
||||
test -d docs/conf||$mkdir_p docs/conf
|
||||
|
||||
AC_CONFIG_FILES(docs/conf/httpd.conf docs/conf/extra/httpd-autoindex.conf docs/conf/extra/httpd-dav.conf docs/conf/extra/httpd-default.conf docs/conf/extra/httpd-info.conf docs/conf/extra/httpd-languages.conf docs/conf/extra/httpd-manual.conf docs/conf/extra/httpd-mpm.conf docs/conf/extra/httpd-multilang-errordoc.conf docs/conf/extra/httpd-ssl.conf docs/conf/extra/httpd-userdir.conf docs/conf/extra/httpd-vhosts.conf docs/conf/extra/proxy-html.conf include/ap_config_layout.h support/apxs support/apachectl support/dbmmanage support/envvars-std support/log_server_status support/logresolve.pl support/phf_abuse_log.cgi support/split-logfile build/rules.mk build/pkg/pkginfo build/config_vars.sh)
|
||||
AC_CONFIG_COMMANDS([default], [true], [APACHE_GEN_MAKEFILES])
|
||||
AC_OUTPUT
|
||||
AC_MSG_NOTICE([summary of build options:
|
||||
|
||||
Server Version: ${HTTPD_VERSION}
|
||||
Install prefix: ${prefix}
|
||||
C compiler: ${APACHE_CONF_SEL_CC}
|
||||
CFLAGS: ${APACHE_CONF_SEL_CFLAGS}
|
||||
CPPFLAGS: ${APACHE_CONF_SEL_CPPFLAGS}
|
||||
LDFLAGS: ${APACHE_CONF_SEL_LDFLAGS}
|
||||
LIBS: ${APACHE_CONF_SEL_LIBS}
|
||||
C preprocessor: ${APACHE_CONF_SEL_CPP}
|
||||
])
|
27
docs/cgi-examples/printenv
Normal file
27
docs/cgi-examples/printenv
Normal file
|
@ -0,0 +1,27 @@
|
|||
#
|
||||
|
||||
# To permit this cgi, replace # on the first line above with the
|
||||
# appropriate #!/path/to/perl shebang, and on Unix / Linux also
|
||||
# set this script executable with chmod 755.
|
||||
#
|
||||
# ***** !!! WARNING !!! *****
|
||||
# This script echoes the server environment variables and therefore
|
||||
# leaks information - so NEVER use it in a live server environment!
|
||||
# It is provided only for testing purpose.
|
||||
# Also note that it is subject to cross site scripting attacks on
|
||||
# MS IE and any other browser which fails to honor RFC2616.
|
||||
|
||||
##
|
||||
## printenv -- demo CGI program which just prints its environment
|
||||
##
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
print "Content-type: text/plain; charset=iso-8859-1\n\n";
|
||||
foreach my $var (sort(keys(%ENV))) {
|
||||
my $val = $ENV{$var};
|
||||
$val =~ s|\n|\\n|g;
|
||||
$val =~ s|"|\\"|g;
|
||||
print "${var}=\"${val}\"\n";
|
||||
}
|
||||
|
32
docs/cgi-examples/printenv.vbs
Normal file
32
docs/cgi-examples/printenv.vbs
Normal file
|
@ -0,0 +1,32 @@
|
|||
'
|
||||
|
||||
' To permit this cgi, replace ' on the first line above with the
|
||||
' appropriate shebang, f.e. '!c:/windows/system32/cscript -nologo
|
||||
'
|
||||
' ***** !!! WARNING !!! *****
|
||||
' This script echoes the server environment variables and therefore
|
||||
' leaks information - so NEVER use it in a live server environment!
|
||||
' It is provided only for testing purpose.
|
||||
' Also note that it is subject to cross site scripting attacks on
|
||||
' MS IE and any other browser which fails to honor RFC2616.
|
||||
|
||||
''
|
||||
'' printenv -- demo CGI program which just prints its environment
|
||||
''
|
||||
Option Explicit
|
||||
|
||||
Dim objShell, objArray, str, envvar, envval
|
||||
Set objShell = CreateObject("WScript.Shell")
|
||||
Set objArray = CreateObject("System.Collections.ArrayList")
|
||||
|
||||
WScript.StdOut.WriteLine "Content-type: text/plain; charset=iso-8859-1" & vbLF
|
||||
For Each str In objShell.Environment("PROCESS")
|
||||
objArray.Add str
|
||||
Next
|
||||
objArray.Sort()
|
||||
For Each str In objArray
|
||||
envvar = Left(str, InStr(str, "="))
|
||||
envval = Replace(Mid(str, InStr(str, "=") + 1), vbLF, "\n")
|
||||
WScript.StdOut.WriteLine envvar & Chr(34) & envval & Chr(34)
|
||||
Next
|
||||
|
33
docs/cgi-examples/printenv.wsf
Normal file
33
docs/cgi-examples/printenv.wsf
Normal file
|
@ -0,0 +1,33 @@
|
|||
'
|
||||
|
||||
' To permit this cgi, replace ' on the first line above with the
|
||||
' appropriate shebang, f.e. '!c:/windows/system32/cscript -nologo
|
||||
'
|
||||
' ***** !!! WARNING !!! *****
|
||||
' This script echoes the server environment variables and therefore
|
||||
' leaks information - so NEVER use it in a live server environment!
|
||||
' It is provided only for testing purpose.
|
||||
' Also note that it is subject to cross site scripting attacks on
|
||||
' MS IE and any other browser which fails to honor RFC2616.
|
||||
|
||||
''
|
||||
'' printenv -- demo CGI program which just prints its environment
|
||||
''
|
||||
<job>
|
||||
<script language="JScript">
|
||||
WScript.Echo("Content-type: text/plain; charset=iso-8859-1\n");
|
||||
var objShell = new ActiveXObject("WScript.Shell");
|
||||
var objArray = new Array();
|
||||
var e = new Enumerator(objShell.Environment("PROCESS"));
|
||||
for (;!e.atEnd();e.moveNext()) {
|
||||
var i = e.item().indexOf("=");
|
||||
var envvar = e.item().substring(0, i);
|
||||
var envval = e.item().substring(i + 1, e.item().length);
|
||||
envval = envval.replace("\n", "\\n");
|
||||
objArray.push(envvar + "=\"" + envval + "\"");
|
||||
}
|
||||
objArray.sort();
|
||||
WScript.Echo(objArray.join("\n"));
|
||||
</script>
|
||||
</job>
|
||||
|
42
docs/cgi-examples/test-cgi
Normal file
42
docs/cgi-examples/test-cgi
Normal file
|
@ -0,0 +1,42 @@
|
|||
#
|
||||
|
||||
# To permit this cgi, replace # on the first line above with the
|
||||
# appropriate #!/path/to/sh shebang, and set this script executable
|
||||
# with chmod 755.
|
||||
#
|
||||
# ***** !!! WARNING !!! *****
|
||||
# This script echoes the server environment variables and therefore
|
||||
# leaks information - so NEVER use it in a live server environment!
|
||||
# It is provided only for testing purpose.
|
||||
# Also note that it is subject to cross site scripting attacks on
|
||||
# MS IE and any other browser which fails to honor RFC2616.
|
||||
|
||||
# disable filename globbing
|
||||
set -f
|
||||
|
||||
echo "Content-type: text/plain; charset=iso-8859-1"
|
||||
echo
|
||||
|
||||
echo CGI/1.0 test script report:
|
||||
echo
|
||||
|
||||
echo argc is $#. argv is "$*".
|
||||
echo
|
||||
|
||||
echo SERVER_SOFTWARE = $SERVER_SOFTWARE
|
||||
echo SERVER_NAME = $SERVER_NAME
|
||||
echo GATEWAY_INTERFACE = $GATEWAY_INTERFACE
|
||||
echo SERVER_PROTOCOL = $SERVER_PROTOCOL
|
||||
echo SERVER_PORT = $SERVER_PORT
|
||||
echo REQUEST_METHOD = $REQUEST_METHOD
|
||||
echo HTTP_ACCEPT = "$HTTP_ACCEPT"
|
||||
echo PATH_INFO = "$PATH_INFO"
|
||||
echo PATH_TRANSLATED = "$PATH_TRANSLATED"
|
||||
echo SCRIPT_NAME = "$SCRIPT_NAME"
|
||||
echo QUERY_STRING = "$QUERY_STRING"
|
||||
echo REMOTE_HOST = $REMOTE_HOST
|
||||
echo REMOTE_ADDR = $REMOTE_ADDR
|
||||
echo REMOTE_USER = $REMOTE_USER
|
||||
echo AUTH_TYPE = $AUTH_TYPE
|
||||
echo CONTENT_TYPE = $CONTENT_TYPE
|
||||
echo CONTENT_LENGTH = $CONTENT_LENGTH
|
55
docs/conf/charset.conv
Normal file
55
docs/conf/charset.conv
Normal file
|
@ -0,0 +1,55 @@
|
|||
|
||||
# Lang-abbv Charset Language
|
||||
#---------------------------------
|
||||
en ISO-8859-1 English
|
||||
UTF-8 utf8 UTF-8
|
||||
Unicode ucs Unicode
|
||||
th Cp874 Thai
|
||||
ja SJIS Japanese
|
||||
ko Cp949 Korean
|
||||
zh Cp950 Chinese-Traditional
|
||||
zh-cn GB2312 Chinese-Simplified
|
||||
zh-tw Cp950 Chinese
|
||||
cs ISO-8859-2 Czech
|
||||
hu ISO-8859-2 Hungarian
|
||||
hr ISO-8859-2 Croatian
|
||||
pl ISO-8859-2 Polish
|
||||
ro ISO-8859-2 Romanian
|
||||
sr ISO-8859-2 Serbian
|
||||
sk ISO-8859-2 Slovak
|
||||
sl ISO-8859-2 Slovenian
|
||||
sq ISO-8859-2 Albanian
|
||||
bg ISO-8859-5 Bulgarian
|
||||
be ISO-8859-5 Byelorussian
|
||||
mk ISO-8859-5 Macedonian
|
||||
ru ISO-8859-5 Russian
|
||||
uk ISO-8859-5 Ukrainian
|
||||
ca ISO-8859-1 Catalan
|
||||
de ISO-8859-1 German
|
||||
da ISO-8859-1 Danish
|
||||
fi ISO-8859-1 Finnish
|
||||
fr ISO-8859-1 French
|
||||
es ISO-8859-1 Spanish
|
||||
is ISO-8859-1 Icelandic
|
||||
it ISO-8859-1 Italian
|
||||
nl ISO-8859-1 Dutch
|
||||
no ISO-8859-1 Norwegian
|
||||
pt ISO-8859-1 Portuguese
|
||||
sv ISO-8859-1 Swedish
|
||||
af ISO-8859-1 Afrikaans
|
||||
eu ISO-8859-1 Basque
|
||||
fo ISO-8859-1 Faroese
|
||||
gl ISO-8859-1 Galician
|
||||
ga ISO-8859-1 Irish
|
||||
gd ISO-8859-1 Scottish
|
||||
mt ISO-8859-3 Maltese
|
||||
eo ISO-8859-3 Esperanto
|
||||
el ISO-8859-7 Greek
|
||||
tr ISO-8859-9 Turkish
|
||||
he ISO-8859-8 Hebrew
|
||||
iw ISO-8859-8 Hebrew
|
||||
ar ISO-8859-6 Arabic
|
||||
et ISO-8859-1 Estonian
|
||||
lv ISO-8859-2 Latvian
|
||||
lt ISO-8859-2 Lithuanian
|
||||
|
93
docs/conf/extra/httpd-autoindex.conf.in
Normal file
93
docs/conf/extra/httpd-autoindex.conf.in
Normal file
|
@ -0,0 +1,93 @@
|
|||
#
|
||||
# Directives controlling the display of server-generated directory listings.
|
||||
#
|
||||
# Required modules: mod_authz_core, mod_authz_host,
|
||||
# mod_autoindex, mod_alias
|
||||
#
|
||||
# To see the listing of a directory, the Options directive for the
|
||||
# directory must include "Indexes", and the directory must not contain
|
||||
# a file matching those listed in the DirectoryIndex directive.
|
||||
#
|
||||
|
||||
#
|
||||
# IndexOptions: Controls the appearance of server-generated directory
|
||||
# listings.
|
||||
#
|
||||
IndexOptions FancyIndexing HTMLTable VersionSort
|
||||
|
||||
# We include the /icons/ alias for FancyIndexed directory listings. If
|
||||
# you do not use FancyIndexing, you may comment this out.
|
||||
#
|
||||
Alias /icons/ "@exp_iconsdir@/"
|
||||
|
||||
<Directory "@exp_iconsdir@">
|
||||
Options Indexes MultiViews
|
||||
AllowOverride None
|
||||
Require all granted
|
||||
</Directory>
|
||||
|
||||
#
|
||||
# AddIcon* directives tell the server which icon to show for different
|
||||
# files or filename extensions. These are only displayed for
|
||||
# FancyIndexed directories.
|
||||
#
|
||||
AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip
|
||||
|
||||
AddIconByType (TXT,/icons/text.gif) text/*
|
||||
AddIconByType (IMG,/icons/image2.gif) image/*
|
||||
AddIconByType (SND,/icons/sound2.gif) audio/*
|
||||
AddIconByType (VID,/icons/movie.gif) video/*
|
||||
|
||||
AddIcon /icons/binary.gif .bin .exe
|
||||
AddIcon /icons/binhex.gif .hqx
|
||||
AddIcon /icons/tar.gif .tar
|
||||
AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
|
||||
AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
|
||||
AddIcon /icons/a.gif .ps .ai .eps
|
||||
AddIcon /icons/layout.gif .html .shtml .htm .pdf
|
||||
AddIcon /icons/text.gif .txt
|
||||
AddIcon /icons/c.gif .c
|
||||
AddIcon /icons/p.gif .pl .py
|
||||
AddIcon /icons/f.gif .for
|
||||
AddIcon /icons/dvi.gif .dvi
|
||||
AddIcon /icons/uuencoded.gif .uu
|
||||
AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
|
||||
AddIcon /icons/tex.gif .tex
|
||||
AddIcon /icons/bomb.gif core
|
||||
|
||||
AddIcon /icons/back.gif ..
|
||||
AddIcon /icons/hand.right.gif README
|
||||
AddIcon /icons/folder.gif ^^DIRECTORY^^
|
||||
AddIcon /icons/blank.gif ^^BLANKICON^^
|
||||
|
||||
#
|
||||
# DefaultIcon is which icon to show for files which do not have an icon
|
||||
# explicitly set.
|
||||
#
|
||||
DefaultIcon /icons/unknown.gif
|
||||
|
||||
#
|
||||
# AddDescription allows you to place a short description after a file in
|
||||
# server-generated indexes. These are only displayed for FancyIndexed
|
||||
# directories.
|
||||
# Format: AddDescription "description" filename
|
||||
#
|
||||
#AddDescription "GZIP compressed document" .gz
|
||||
#AddDescription "tar archive" .tar
|
||||
#AddDescription "GZIP compressed tar archive" .tgz
|
||||
|
||||
#
|
||||
# ReadmeName is the name of the README file the server will look for by
|
||||
# default, and append to directory listings.
|
||||
#
|
||||
# HeaderName is the name of a file which should be prepended to
|
||||
# directory indexes.
|
||||
ReadmeName README.html
|
||||
HeaderName HEADER.html
|
||||
|
||||
#
|
||||
# IndexIgnore is a set of filenames which directory indexing should ignore
|
||||
# and not include in the listing. Shell-style wildcarding is permitted.
|
||||
#
|
||||
IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t
|
||||
|
53
docs/conf/extra/httpd-dav.conf.in
Normal file
53
docs/conf/extra/httpd-dav.conf.in
Normal file
|
@ -0,0 +1,53 @@
|
|||
#
|
||||
# Distributed authoring and versioning (WebDAV)
|
||||
#
|
||||
# Required modules: mod_alias, mod_auth_digest, mod_authn_core, mod_authn_file,
|
||||
# mod_authz_core, mod_authz_user, mod_dav, mod_dav_fs,
|
||||
# mod_setenvif
|
||||
|
||||
# The following example gives DAV write access to a directory called
|
||||
# "uploads" under the ServerRoot directory.
|
||||
#
|
||||
# The User/Group specified in httpd.conf needs to have write permissions
|
||||
# on the directory where the DavLockDB is placed and on any directory where
|
||||
# "Dav On" is specified.
|
||||
|
||||
DavLockDB "@@ServerRoot@@/var/DavLock"
|
||||
|
||||
Alias /uploads "@@ServerRoot@@/uploads"
|
||||
|
||||
<Directory "@@ServerRoot@@/uploads">
|
||||
Dav On
|
||||
|
||||
AuthType Digest
|
||||
AuthName DAV-upload
|
||||
# You can use the htdigest program to create the password database:
|
||||
# htdigest -c "@@ServerRoot@@/user.passwd" DAV-upload admin
|
||||
AuthUserFile "@@ServerRoot@@/user.passwd"
|
||||
AuthDigestProvider file
|
||||
|
||||
# Allow universal read-access, but writes are restricted
|
||||
# to the admin user.
|
||||
<RequireAny>
|
||||
Require method GET POST OPTIONS
|
||||
Require user admin
|
||||
</RequireAny>
|
||||
</Directory>
|
||||
|
||||
#
|
||||
# The following directives disable redirects on non-GET requests for
|
||||
# a directory that does not include the trailing slash. This fixes a
|
||||
# problem with several clients that do not appropriately handle
|
||||
# redirects for folders with DAV methods.
|
||||
#
|
||||
BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully
|
||||
BrowserMatch "MS FrontPage" redirect-carefully
|
||||
BrowserMatch "^WebDrive" redirect-carefully
|
||||
BrowserMatch "^WebDAVFS/1\.[012]" redirect-carefully
|
||||
BrowserMatch "^gnome-vfs/1\.0" redirect-carefully
|
||||
BrowserMatch "^gvfs/1" redirect-carefully
|
||||
BrowserMatch "^XML Spy" redirect-carefully
|
||||
BrowserMatch "^Dreamweaver-WebDAV-SCM1" redirect-carefully
|
||||
BrowserMatch " Konqueror/4" redirect-carefully
|
||||
BrowserMatch " Konqueror/5" redirect-carefully
|
||||
BrowserMatch " dolphin/" redirect-carefully
|
90
docs/conf/extra/httpd-default.conf.in
Normal file
90
docs/conf/extra/httpd-default.conf.in
Normal file
|
@ -0,0 +1,90 @@
|
|||
#
|
||||
# This configuration file reflects default settings for Apache HTTP Server.
|
||||
#
|
||||
# You may change these, but chances are that you may not need to.
|
||||
#
|
||||
|
||||
#
|
||||
# Timeout: The number of seconds before receives and sends time out.
|
||||
#
|
||||
Timeout 60
|
||||
|
||||
#
|
||||
# KeepAlive: Whether or not to allow persistent connections (more than
|
||||
# one request per connection). Set to "Off" to deactivate.
|
||||
#
|
||||
KeepAlive On
|
||||
|
||||
#
|
||||
# MaxKeepAliveRequests: The maximum number of requests to allow
|
||||
# during a persistent connection. Set to 0 to allow an unlimited amount.
|
||||
# We recommend you leave this number high, for maximum performance.
|
||||
#
|
||||
MaxKeepAliveRequests 100
|
||||
|
||||
#
|
||||
# KeepAliveTimeout: Number of seconds to wait for the next request from the
|
||||
# same client on the same connection.
|
||||
#
|
||||
KeepAliveTimeout 5
|
||||
|
||||
#
|
||||
# UseCanonicalName: Determines how Apache constructs self-referencing
|
||||
# URLs and the SERVER_NAME and SERVER_PORT variables.
|
||||
# When set "Off", Apache will use the Hostname and Port supplied
|
||||
# by the client. When set "On", Apache will use the value of the
|
||||
# ServerName directive.
|
||||
#
|
||||
UseCanonicalName Off
|
||||
|
||||
#
|
||||
# AccessFileName: The name of the file to look for in each directory
|
||||
# for additional configuration directives. See also the AllowOverride
|
||||
# directive.
|
||||
#
|
||||
AccessFileName .htaccess
|
||||
|
||||
#
|
||||
# ServerTokens
|
||||
# This directive configures what you return as the Server HTTP response
|
||||
# Header. The default is 'Full' which sends information about the OS-Type
|
||||
# and compiled in modules.
|
||||
# Set to one of: Full | OS | Minor | Minimal | Major | Prod
|
||||
# where Full conveys the most information, and Prod the least.
|
||||
#
|
||||
ServerTokens Full
|
||||
|
||||
#
|
||||
# Optionally add a line containing the server version and virtual host
|
||||
# name to server-generated pages (internal error documents, FTP directory
|
||||
# listings, mod_status and mod_info output etc., but not CGI generated
|
||||
# documents or custom error documents).
|
||||
# Set to "EMail" to also include a mailto: link to the ServerAdmin.
|
||||
# Set to one of: On | Off | EMail
|
||||
#
|
||||
ServerSignature Off
|
||||
|
||||
#
|
||||
# HostnameLookups: Log the names of clients or just their IP addresses
|
||||
# e.g., www.apache.org (on) or 204.62.129.132 (off).
|
||||
# The default is off because it'd be overall better for the net if people
|
||||
# had to knowingly turn this feature on, since enabling it means that
|
||||
# each client request will result in AT LEAST one lookup request to the
|
||||
# nameserver.
|
||||
#
|
||||
HostnameLookups Off
|
||||
|
||||
#
|
||||
# Set a timeout for how long the client may take to send the request header
|
||||
# and body.
|
||||
# The default for the headers is header=20-40,MinRate=500, which means wait
|
||||
# for the first byte of headers for 20 seconds. If some data arrives,
|
||||
# increase the timeout corresponding to a data rate of 500 bytes/s, but not
|
||||
# above 40 seconds.
|
||||
# The default for the request body is body=20,MinRate=500, which is the same
|
||||
# but has no upper limit for the timeout.
|
||||
# To disable, set to header=0 body=0
|
||||
#
|
||||
<IfModule reqtimeout_module>
|
||||
RequestReadTimeout header=20-40,MinRate=500 body=20,MinRate=500
|
||||
</IfModule>
|
36
docs/conf/extra/httpd-info.conf.in
Normal file
36
docs/conf/extra/httpd-info.conf.in
Normal file
|
@ -0,0 +1,36 @@
|
|||
#
|
||||
# Get information about the requests being processed by the server
|
||||
# and the configuration of the server.
|
||||
#
|
||||
# Required modules: mod_authz_core, mod_authz_host,
|
||||
# mod_info (for the server-info handler),
|
||||
# mod_status (for the server-status handler)
|
||||
|
||||
#
|
||||
# Allow server status reports generated by mod_status,
|
||||
# with the URL of http://servername/server-status
|
||||
# Change the ".example.com" to match your domain to enable.
|
||||
|
||||
<Location /server-status>
|
||||
SetHandler server-status
|
||||
Require host .example.com
|
||||
Require ip 127
|
||||
</Location>
|
||||
|
||||
#
|
||||
# ExtendedStatus controls whether Apache will generate "full" status
|
||||
# information (ExtendedStatus On) or just basic information (ExtendedStatus
|
||||
# Off) when the "server-status" handler is called. The default is Off.
|
||||
#
|
||||
#ExtendedStatus On
|
||||
|
||||
#
|
||||
# Allow remote server configuration reports, with the URL of
|
||||
# http://servername/server-info (requires that mod_info.c be loaded).
|
||||
# Change the ".example.com" to match your domain to enable.
|
||||
#
|
||||
<Location /server-info>
|
||||
SetHandler server-info
|
||||
Require host .example.com
|
||||
Require ip 127
|
||||
</Location>
|
141
docs/conf/extra/httpd-languages.conf.in
Normal file
141
docs/conf/extra/httpd-languages.conf.in
Normal file
|
@ -0,0 +1,141 @@
|
|||
#
|
||||
# Settings for hosting different languages.
|
||||
#
|
||||
# Required modules: mod_mime, mod_negotiation
|
||||
|
||||
# DefaultLanguage and AddLanguage allows you to specify the language of
|
||||
# a document. You can then use content negotiation to give a browser a
|
||||
# file in a language the user can understand.
|
||||
#
|
||||
# Specify a default language. This means that all data
|
||||
# going out without a specific language tag (see below) will
|
||||
# be marked with this one. You probably do NOT want to set
|
||||
# this unless you are sure it is correct for all cases.
|
||||
#
|
||||
# * It is generally better to not mark a page as
|
||||
# * being a certain language than marking it with the wrong
|
||||
# * language!
|
||||
#
|
||||
# DefaultLanguage nl
|
||||
#
|
||||
# Note 1: The suffix does not have to be the same as the language
|
||||
# keyword --- those with documents in Polish (whose net-standard
|
||||
# language code is pl) may wish to use "AddLanguage pl .po" to
|
||||
# avoid the ambiguity with the common suffix for perl scripts.
|
||||
#
|
||||
# Note 2: The example entries below illustrate that in some cases
|
||||
# the two character 'Language' abbreviation is not identical to
|
||||
# the two character 'Country' code for its country,
|
||||
# E.g. 'Danmark/dk' versus 'Danish/da'.
|
||||
#
|
||||
# Note 3: In the case of 'ltz' we violate the RFC by using a three char
|
||||
# specifier. There is 'work in progress' to fix this and get
|
||||
# the reference data for rfc1766 cleaned up.
|
||||
#
|
||||
# Catalan (ca) - Croatian (hr) - Czech (cs) - Danish (da) - Dutch (nl)
|
||||
# English (en) - Esperanto (eo) - Estonian (et) - French (fr) - German (de)
|
||||
# Greek-Modern (el) - Hebrew (he) - Italian (it) - Japanese (ja)
|
||||
# Korean (ko) - Luxembourgeois* (ltz) - Norwegian Nynorsk (nn)
|
||||
# Norwegian (no) - Polish (pl) - Portugese (pt)
|
||||
# Brazilian Portuguese (pt-BR) - Russian (ru) - Swedish (sv)
|
||||
# Turkish (tr) - Simplified Chinese (zh-CN) - Spanish (es)
|
||||
# Traditional Chinese (zh-TW)
|
||||
#
|
||||
AddLanguage ca .ca
|
||||
AddLanguage cs .cz .cs
|
||||
AddLanguage da .dk
|
||||
AddLanguage de .de
|
||||
AddLanguage el .el
|
||||
AddLanguage en .en
|
||||
AddLanguage eo .eo
|
||||
AddLanguage es .es
|
||||
AddLanguage et .et
|
||||
AddLanguage fr .fr
|
||||
AddLanguage he .he
|
||||
AddLanguage hr .hr
|
||||
AddLanguage it .it
|
||||
AddLanguage ja .ja
|
||||
AddLanguage ko .ko
|
||||
AddLanguage ltz .ltz
|
||||
AddLanguage nl .nl
|
||||
AddLanguage nn .nn
|
||||
AddLanguage no .no
|
||||
AddLanguage pl .po
|
||||
AddLanguage pt .pt
|
||||
AddLanguage pt-BR .pt-br
|
||||
AddLanguage ru .ru
|
||||
AddLanguage sv .sv
|
||||
AddLanguage tr .tr
|
||||
AddLanguage zh-CN .zh-cn
|
||||
AddLanguage zh-TW .zh-tw
|
||||
|
||||
# LanguagePriority allows you to give precedence to some languages
|
||||
# in case of a tie during content negotiation.
|
||||
#
|
||||
# Just list the languages in decreasing order of preference. We have
|
||||
# more or less alphabetized them here. You probably want to change this.
|
||||
#
|
||||
LanguagePriority en ca cs da de el eo es et fr he hr it ja ko ltz nl nn no pl pt pt-BR ru sv tr zh-CN zh-TW
|
||||
|
||||
#
|
||||
# ForceLanguagePriority allows you to serve a result page rather than
|
||||
# MULTIPLE CHOICES (Prefer) [in case of a tie] or NOT ACCEPTABLE (Fallback)
|
||||
# [in case no accepted languages matched the available variants]
|
||||
#
|
||||
ForceLanguagePriority Prefer Fallback
|
||||
|
||||
#
|
||||
# Commonly used filename extensions to character sets. You probably
|
||||
# want to avoid clashes with the language extensions, unless you
|
||||
# are good at carefully testing your setup after each change.
|
||||
# See http://www.iana.org/assignments/character-sets for the
|
||||
# official list of charset names and their respective RFCs.
|
||||
#
|
||||
AddCharset us-ascii.ascii .us-ascii
|
||||
AddCharset ISO-8859-1 .iso8859-1 .latin1
|
||||
AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen
|
||||
AddCharset ISO-8859-3 .iso8859-3 .latin3
|
||||
AddCharset ISO-8859-4 .iso8859-4 .latin4
|
||||
AddCharset ISO-8859-5 .iso8859-5 .cyr .iso-ru
|
||||
AddCharset ISO-8859-6 .iso8859-6 .arb .arabic
|
||||
AddCharset ISO-8859-7 .iso8859-7 .grk .greek
|
||||
AddCharset ISO-8859-8 .iso8859-8 .heb .hebrew
|
||||
AddCharset ISO-8859-9 .iso8859-9 .latin5 .trk
|
||||
AddCharset ISO-8859-10 .iso8859-10 .latin6
|
||||
AddCharset ISO-8859-13 .iso8859-13
|
||||
AddCharset ISO-8859-14 .iso8859-14 .latin8
|
||||
AddCharset ISO-8859-15 .iso8859-15 .latin9
|
||||
AddCharset ISO-8859-16 .iso8859-16 .latin10
|
||||
AddCharset ISO-2022-JP .iso2022-jp .jis
|
||||
AddCharset ISO-2022-KR .iso2022-kr .kis
|
||||
AddCharset ISO-2022-CN .iso2022-cn .cis
|
||||
AddCharset Big5.Big5 .big5 .b5
|
||||
AddCharset cn-Big5 .cn-big5
|
||||
# For russian, more than one charset is used (depends on client, mostly):
|
||||
AddCharset WINDOWS-1251 .cp-1251 .win-1251
|
||||
AddCharset CP866 .cp866
|
||||
AddCharset KOI8 .koi8
|
||||
AddCharset KOI8-E .koi8-e
|
||||
AddCharset KOI8-r .koi8-r .koi8-ru
|
||||
AddCharset KOI8-U .koi8-u
|
||||
AddCharset KOI8-ru .koi8-uk .ua
|
||||
AddCharset ISO-10646-UCS-2 .ucs2
|
||||
AddCharset ISO-10646-UCS-4 .ucs4
|
||||
AddCharset UTF-7 .utf7
|
||||
AddCharset UTF-8 .utf8
|
||||
AddCharset UTF-16 .utf16
|
||||
AddCharset UTF-16BE .utf16be
|
||||
AddCharset UTF-16LE .utf16le
|
||||
AddCharset UTF-32 .utf32
|
||||
AddCharset UTF-32BE .utf32be
|
||||
AddCharset UTF-32LE .utf32le
|
||||
AddCharset euc-cn .euc-cn
|
||||
AddCharset euc-gb .euc-gb
|
||||
AddCharset euc-jp .euc-jp
|
||||
AddCharset euc-kr .euc-kr
|
||||
#Not sure how euc-tw got in - IANA doesn't list it???
|
||||
AddCharset EUC-TW .euc-tw
|
||||
AddCharset gb2312 .gb2312 .gb
|
||||
AddCharset iso-10646-ucs-2 .ucs-2 .iso-10646-ucs-2
|
||||
AddCharset iso-10646-ucs-4 .ucs-4 .iso-10646-ucs-4
|
||||
AddCharset shift_jis .shift_jis .sjis
|
38
docs/conf/extra/httpd-manual.conf.in
Normal file
38
docs/conf/extra/httpd-manual.conf.in
Normal file
|
@ -0,0 +1,38 @@
|
|||
#
|
||||
# Provide access to the documentation on your server as
|
||||
# http://yourserver.example.com/manual/
|
||||
# The documentation is always available at
|
||||
# http://httpd.apache.org/docs/2.4/
|
||||
#
|
||||
# Required modules: mod_alias, mod_authz_core, mod_authz_host,
|
||||
# mod_setenvif, mod_negotiation
|
||||
#
|
||||
|
||||
AliasMatch ^/manual(?:/(?:da|de|en|es|fr|ja|ko|pt-br|ru|tr|zh-cn))?(/.*)?$ "@exp_manualdir@$1"
|
||||
|
||||
<Directory "@exp_manualdir@">
|
||||
Options Indexes
|
||||
AllowOverride None
|
||||
Require all granted
|
||||
|
||||
<Files *.html>
|
||||
SetHandler type-map
|
||||
</Files>
|
||||
|
||||
# .tr is text/troff in mime.types!
|
||||
RemoveType tr
|
||||
|
||||
# Traditionally, used .dk filename extension for da language
|
||||
AddLanguage da .da
|
||||
|
||||
SetEnvIf Request_URI ^/manual/(da|de|en|es|fr|ja|ko|pt-br|ru|tr|zh-cn)/ prefer-language=$1
|
||||
RedirectMatch 301 ^/manual(?:/(da|de|en|es|fr|ja|ko|pt-br|ru|tr|zh-cn)){2,}(/.*)?$ /manual/$1$2
|
||||
|
||||
# Reflect the greatest effort in translation (most content available),
|
||||
# inferring greater attention to detail (potentially false assumption,
|
||||
# counting translations presently in-sync would be more helpful.)
|
||||
# Use caution counting; safest pattern is '*.xml.XX'. Recent .xml source
|
||||
# document count: 266 214 110 94 82 25 22 18 4 1 1
|
||||
LanguagePriority en fr ko ja tr es de zh-cn pt-br da ru
|
||||
ForceLanguagePriority Prefer Fallback
|
||||
</Directory>
|
119
docs/conf/extra/httpd-mpm.conf.in
Normal file
119
docs/conf/extra/httpd-mpm.conf.in
Normal file
|
@ -0,0 +1,119 @@
|
|||
#
|
||||
# Server-Pool Management (MPM specific)
|
||||
#
|
||||
|
||||
#
|
||||
# PidFile: The file in which the server should record its process
|
||||
# identification number when it starts.
|
||||
#
|
||||
# Note that this is the default PidFile for most MPMs.
|
||||
#
|
||||
<IfModule !mpm_netware_module>
|
||||
PidFile "@rel_runtimedir@/httpd.pid"
|
||||
</IfModule>
|
||||
|
||||
#
|
||||
# Only one of the below sections will be relevant on your
|
||||
# installed httpd. Use "apachectl -l" to find out the
|
||||
# active mpm.
|
||||
#
|
||||
|
||||
# prefork MPM
|
||||
# StartServers: number of server processes to start
|
||||
# MinSpareServers: minimum number of server processes which are kept spare
|
||||
# MaxSpareServers: maximum number of server processes which are kept spare
|
||||
# MaxRequestWorkers: maximum number of server processes allowed to start
|
||||
# MaxConnectionsPerChild: maximum number of connections a server process serves
|
||||
# before terminating
|
||||
<IfModule mpm_prefork_module>
|
||||
StartServers 5
|
||||
MinSpareServers 5
|
||||
MaxSpareServers 10
|
||||
MaxRequestWorkers 250
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# worker MPM
|
||||
# StartServers: initial number of server processes to start
|
||||
# MinSpareThreads: minimum number of worker threads which are kept spare
|
||||
# MaxSpareThreads: maximum number of worker threads which are kept spare
|
||||
# ThreadsPerChild: constant number of worker threads in each server process
|
||||
# MaxRequestWorkers: maximum number of worker threads
|
||||
# MaxConnectionsPerChild: maximum number of connections a server process serves
|
||||
# before terminating
|
||||
<IfModule mpm_worker_module>
|
||||
StartServers 3
|
||||
MinSpareThreads 75
|
||||
MaxSpareThreads 250
|
||||
ThreadsPerChild 25
|
||||
MaxRequestWorkers 400
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# event MPM
|
||||
# StartServers: initial number of server processes to start
|
||||
# MinSpareThreads: minimum number of worker threads which are kept spare
|
||||
# MaxSpareThreads: maximum number of worker threads which are kept spare
|
||||
# ThreadsPerChild: constant number of worker threads in each server process
|
||||
# MaxRequestWorkers: maximum number of worker threads
|
||||
# MaxConnectionsPerChild: maximum number of connections a server process serves
|
||||
# before terminating
|
||||
<IfModule mpm_event_module>
|
||||
StartServers 3
|
||||
MinSpareThreads 75
|
||||
MaxSpareThreads 250
|
||||
ThreadsPerChild 25
|
||||
MaxRequestWorkers 400
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# NetWare MPM
|
||||
# ThreadStackSize: Stack size allocated for each worker thread
|
||||
# StartThreads: Number of worker threads launched at server startup
|
||||
# MinSpareThreads: Minimum number of idle threads, to handle request spikes
|
||||
# MaxSpareThreads: Maximum number of idle threads
|
||||
# MaxThreads: Maximum number of worker threads alive at the same time
|
||||
# MaxConnectionsPerChild: Maximum number of connections a thread serves. It
|
||||
# is recommended that the default value of 0 be set
|
||||
# for this directive on NetWare. This will allow the
|
||||
# thread to continue to service requests indefinitely.
|
||||
<IfModule mpm_netware_module>
|
||||
ThreadStackSize 65536
|
||||
StartThreads 250
|
||||
MinSpareThreads 25
|
||||
MaxSpareThreads 250
|
||||
MaxThreads 1000
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# OS/2 MPM
|
||||
# StartServers: Number of server processes to maintain
|
||||
# MinSpareThreads: Minimum number of idle threads per process,
|
||||
# to handle request spikes
|
||||
# MaxSpareThreads: Maximum number of idle threads per process
|
||||
# MaxConnectionsPerChild: Maximum number of connections per server process
|
||||
<IfModule mpm_mpmt_os2_module>
|
||||
StartServers 2
|
||||
MinSpareThreads 5
|
||||
MaxSpareThreads 10
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# WinNT MPM
|
||||
# ThreadsPerChild: constant number of worker threads in the server process
|
||||
# MaxConnectionsPerChild: maximum number of connections a server process serves
|
||||
<IfModule mpm_winnt_module>
|
||||
ThreadsPerChild 150
|
||||
MaxConnectionsPerChild 0
|
||||
</IfModule>
|
||||
|
||||
# The maximum number of free Kbytes that every allocator is allowed
|
||||
# to hold without calling free(). In threaded MPMs, every thread has its own
|
||||
# allocator. When not set, or when set to zero, the threshold will be set to
|
||||
# unlimited.
|
||||
<IfModule !mpm_netware_module>
|
||||
MaxMemFree 2048
|
||||
</IfModule>
|
||||
<IfModule mpm_netware_module>
|
||||
MaxMemFree 100
|
||||
</IfModule>
|
52
docs/conf/extra/httpd-multilang-errordoc.conf.in
Normal file
52
docs/conf/extra/httpd-multilang-errordoc.conf.in
Normal file
|
@ -0,0 +1,52 @@
|
|||
#
|
||||
# The configuration below implements multi-language error documents through
|
||||
# content-negotiation.
|
||||
#
|
||||
# Required modules: mod_alias, mod_authz_core, mod_authz_host,
|
||||
# mod_include, mod_negotiation
|
||||
#
|
||||
# We use Alias to redirect any /error/HTTP_<error>.html.var response to
|
||||
# our collection of by-error message multi-language collections. We use
|
||||
# includes to substitute the appropriate text.
|
||||
#
|
||||
# You can modify the messages' appearance without changing any of the
|
||||
# default HTTP_<error>.html.var files by adding the line:
|
||||
#
|
||||
# Alias /error/include/ "/your/include/path/"
|
||||
#
|
||||
# which allows you to create your own set of files by starting with the
|
||||
# @exp_errordir@/include/ files and copying them to /your/include/path/,
|
||||
# even on a per-VirtualHost basis. The default include files will display
|
||||
# your Apache version number and your ServerAdmin email address regardless
|
||||
# of the setting of ServerSignature.
|
||||
|
||||
Alias /error/ "@exp_errordir@/"
|
||||
|
||||
<Directory "@exp_errordir@">
|
||||
AllowOverride None
|
||||
Options IncludesNoExec
|
||||
AddOutputFilter Includes html
|
||||
AddHandler type-map var
|
||||
Require all granted
|
||||
LanguagePriority en cs de es fr it ja ko nl pl pt-br ro sv tr
|
||||
ForceLanguagePriority Prefer Fallback
|
||||
</Directory>
|
||||
|
||||
ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
|
||||
ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
|
||||
ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
|
||||
ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var
|
||||
ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
|
||||
ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
|
||||
ErrorDocument 410 /error/HTTP_GONE.html.var
|
||||
ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
|
||||
ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
|
||||
ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
|
||||
ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
|
||||
ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
|
||||
ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var
|
||||
ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
|
||||
ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
|
||||
ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
|
||||
ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var
|
||||
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue