Solaris build: fix

Signed-off-by: Oleksandr Lepetyukh <olepetyukh@op5.com>
solaris: Add dependencies

This is a guess. It just might work.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris: Only specify gcc as dependency

Another guess.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris/depend: s/gcc/SUNWgccruntime

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris: Remove package.sh

This build file is not executed, the build server has its own package.sh
that actually does stuff. Exceptions for certain packages, such as
Merlin, should go into that build file.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris/preremove: Do not fail if services are not started/installed

If you want to remove a partial installation, the preremove script has
to be run but the services might not have been installed before the
installation was aborted. In that case, do not choke out.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
daemonize.c: Do unlink pidfil on shutdown signal

Because both daemon.c and daemonize.c tried to register a handler for
SIGINT/SIGTERM, only one of them was successful, which in this case was
daemon.c. The only thing done in daemonize.c's signal handler was to
remove the pid file, which thus wasn't done, causing it to be left
behind, which isn't pretty. This meant op5kad always thought merlin had
crashed, instantly restarting it, which was never the intended behavior.

Make daemon.c call daemonize.c's previous signal handler, and thus do a
clean shutdown.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
solaris: Depend on op5-monitor-config

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris/postinstall: Correct bash syntax

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris/postinstall: Use correct version of grep

The man page of grep includes two synopsiseses, that's clever. Thanks.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris: Fail on first error with set -e

Also, specify that we're using bash.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
sql/oracle: Spelling of comment_tbl_id_SEQ

Almost the same as edbf98f4f0bde6f52ea1b4b68b41fd91163a862a in master

Signed-off-by: Carl Helmertz <chelmertz@op5.com>

Conflicts:
	sql/oracle/merlin_seq.sql

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
sql/oracle: Upgrade script from 5.4 to 5.5

This is the script as it was found on repos.op5.com/g..

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
oracle: SQL from master

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
oracle: mv {,merlin_}grant.sql

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
oracle: Rename SQL files so that we can find them easier later on

It's either this, or checking them out, renaming the copies and try to
find your way back home when backtracking. Good luck with that.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris: Adapt mon-scripts

Some of the sed's were quite alright but we don't, for example, have -q
for grep in the Solaris' builtin. As such, mon start had syntax errors.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
oracle: Syntax error on DROP INDEX

The schema is, contrary to MySQL, left out. This is the error received:

ORA-00933: SQL command not properly ended

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
oracle: Remove duplicate definition of rename_log

It's not present in the already delivered 5.4.2.6-Solaris release, so
we'll keep the definitions already given in merlin-v5.4_to_v5.5.sql.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>
solaris: Quote arguments for grep

Errors otherwise occur did.

Signed-off-by: Carl Helmertz <chelmertz@op5.com>