AIDE:Data/src/m4/init.m4

From Tom
Jump to: navigation, search


header

divert(-1)
#
# Comments
#

VERSIONID

define(`VERSIONID', ``#####  $1)

COMMENT

define(`COMMENT', ``# $1)

_CF_DIR_

ifdef(`_CF_DIR_', `',
`ifelse(__file__, `__file__',
`define(`_CF_DIR_', `../src/')',
`define(`_CF_DIR_', regexp(__file__, `^(.*)/([^/]*/[^/]*)$', `1/'))'
)'
)

header2

divert(2)dnl
VERSIONID(`$Id: init.m4 1651 2016-01-20 20:56:33Z aa0026 $')
divert(-1)

OS Info

COMMENT(`Define very low level variables and functions.')

define(`OS_HARDWARE',  esyscmd(`uname -i'))
define(`OS_HARDWARE',  substr(OS_HARDWARE,  0, eval(len(OS_HARDWARE)-1)))

define(`OS_KERNEL',    esyscmd(`uname -s'))
define(`OS_KERNEL',    substr(OS_KERNEL,    0, eval(len(OS_KERNEL)-1)))

define(`OS_MACHINE',   esyscmd(`uname -m'))
define(`OS_MACHINE',   substr(OS_MACHINE,   0, eval(len(OS_MACHINE)-1)))

define(`OS_NODENAME',   esyscmd(`uname -n'))
define(`OS_NODENAME',   substr(OS_NODENAME,   0, eval(len(OS_NODENAME)-1)))

define(`OS_PROCESSOR', esyscmd(`uname -p'))
define(`OS_PROCESSOR', substr(OS_PROCESSOR, 0, eval(len(OS_PROCESSOR)-1)))

define(`OS_RELEASE',   esyscmd(`uname -r'))
define(`OS_RELEASE',   substr(OS_RELEASE,   0, eval(len(OS_RELEASE)-1)))

os_include

define(`os_include',dnl
`sinclude(_CF_DIR_`os/'OS_KERNEL`/'$1`.m4')dnl
sinclude(_CF_DIR_`os/'OS_KERNEL`/'OS_MACHINE`/'$1`.m4')dnl
sinclude(_CF_DIR_`os/'OS_KERNEL`/'OS_RELEASE`/'$1`.m4')'dnl
)dnl

app_include

define(`app_include',dnl
`sinclude(_CF_DIR_`app/'OS_KERNEL`/'$1`.m4')dnl
sinclude(_CF_DIR_`app/'OS_KERNEL`/'OS_MACHINE`/'$1`.m4')dnl
sinclude(_CF_DIR_`app/'OS_KERNEL`/'OS_RELEASE`/'$1`.m4')'dnl
)dnl

m4_include

define(`m4_include',dnl
`sinclude(_CF_DIR_`m4/'$1`.m4')dnl
sinclude(_CF_DIR_`m4/'OS_KERNEL`/'$1`.m4')dnl
sinclude(_CF_DIR_`m4/'OS_KERNEL`/'OS_MACHINE`/'$1`.m4')dnl
sinclude(_CF_DIR_`m4/'OS_KERNEL`/'OS_RELEASE`/'$1`.m4')'dnl
)dnl

Initialize

COMMENT(`Initialize default User Variables based on OS version (if any).')

os_include(`init')dnl

Load Functions

COMMENT(`Load additonal functions.')

m4_include(`functions')dnl

Default Variables

COMMENT(`Initialize default User Variables if not already set above (if any).')

ifdef(`AIDE_DB', `',
`define(`AIDE_DB', `/var/lib/aide')'
)
ifdef(`AIDE_DB_FILE_HEAD', `',
`define(`AIDE_DB_FILE_HEAD', `aide.db')'
)
ifdef(`GZIP', `',
`define(`GZIP', `yes')'
)

--Tom Stevenson (talk) 12:27, 4 February 2016 (EST)

Help contents:

Reading: Go | Search | URL | Namespace | Page name | Section | Link | Backlinks | Piped link | Interwiki link | Redirect | Variable | Category | Special page
Tracking changes: Recent | (enhanced) | Related | Watching pages | Page history | Diff | User contributions | Edit summary | Minor edit | Patrolled edit
Logging in and preferences: Logging in | Preferences | User style
Editing: Overview | Wikitext | New page | List | Images/files | Image page | Special characters | Formula | Table | EasyTimeline | Inputbox | Template | (p. 2) | Renaming (moving) a page | Editing shortcuts | Talk page | Testing | Export | Import | rlc |