Merge lp:~james-page/ubuntu/oneiric/likewise-open/make-it-work into lp:ubuntu/oneiric/likewise-open

Proposed by James Page
Status: Merged
Merge reported by: James Page
Merged at revision: not available
Proposed branch: lp:~james-page/ubuntu/oneiric/likewise-open/make-it-work
Merge into: lp:ubuntu/oneiric/likewise-open
Diff against target: 2261 lines (+2223/-0)
4 files modified
debian/changelog (+12/-0)
debian/likewise-open.postinst (+8/-0)
debian/patches/config-fixes-for-verbose-make.patch (+2202/-0)
debian/patches/series (+1/-0)
To merge this branch: bzr merge lp:~james-page/ubuntu/oneiric/likewise-open/make-it-work
Reviewer Review Type Date Requested Status
Ubuntu branches Pending
Review via email: mp+77390@code.launchpad.net

Description of the change

This MP sweeps up an existing proposal which resolves a conflict between makekit and verbose builds
and disables the npfs component on existing installs which means likewise actually starts.

I can't claim much knowledge about either fix - credit goes to Scott Sally for them.

To post a comment you must log in.
Revision history for this message
James Page (james-page) wrote :

Oh - I have installed it on a upgraded natty system and it appears to work fine - I've not tested it completely as that requires a more complex setup but is does at least start cleanly.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2011-09-06 22:10:33 +0000
3+++ debian/changelog 2011-09-28 19:20:30 +0000
4@@ -1,3 +1,15 @@
5+likewise-open (6.1.0.406-0ubuntu4) oneiric; urgency=low
6+
7+ [ Scott Salley ]
8+ * d/patches/config-fixes-for-verbose-make.patch: resolve issues with
9+ verbose build/makekit causing issues with init scripts (LP: #845477).
10+
11+ [ James Page ]
12+ * d/likewise-open.postinst: Disable npfs component as no longer part
13+ of likewise-open (LP: #854971). Thanks to Scott Salley for this fix.
14+
15+ -- James Page <james.page@ubuntu.com> Wed, 28 Sep 2011 20:15:24 +0100
16+
17 likewise-open (6.1.0.406-0ubuntu3) oneiric; urgency=low
18
19 * Re-enable and update dropped patch
20
21=== modified file 'debian/likewise-open.postinst'
22--- debian/likewise-open.postinst 2011-07-29 17:43:42 +0000
23+++ debian/likewise-open.postinst 2011-09-28 19:20:30 +0000
24@@ -160,6 +160,12 @@
25 fi
26 }
27
28+remove_npfs_dependencies()
29+{
30+ run_quiet '/usr/bin/lwregshell' set_value '[HKEY_THIS_MACHINE\Services\lwio\Parameters\Drivers]' 'Load' 'rdr'
31+ run_quiet '/usr/bin/lwregshell' set_value '[HKEY_THIS_MACHINE\Services\lsass]' 'Dependencies' 'netlogon lwio lwreg rdr'
32+}
33+
34 switch_to_open_provider()
35 {
36 _value='[HKEY_THIS_MACHINE\Services\lsass\Parameters\Providers\ActiveDirectory]'
37@@ -204,6 +210,8 @@
38
39 fix_old_registry
40
41+ remove_npfs_dependencies
42+
43 switch_to_open_provider
44
45 run_or_fail /usr/bin/lwsm shutdown
46
47=== added file 'debian/patches/config-fixes-for-verbose-make.patch'
48--- debian/patches/config-fixes-for-verbose-make.patch 1970-01-01 00:00:00 +0000
49+++ debian/patches/config-fixes-for-verbose-make.patch 2011-09-28 19:20:30 +0000
50@@ -0,0 +1,2202 @@
51+Author: Scott Salley <ssalley@beyondtrust.com>
52+Description: Modify the way init scripts are fixed up because 'make V=1' results
53+in corrupted files.
54+Forwarded: yes
55+Last-Update: 2011-09-12
56+
57+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/init-base.sh likewise-open.new/git-build/config/init-base.sh
58+--- likewise-open/git-build/config/init-base.sh 2011-09-09 11:04:54.000000000 -0700
59++++ likewise-open.new/git-build/config/init-base.sh 1969-12-31 16:00:00.000000000 -0800
60+@@ -1,679 +0,0 @@
61+-#!/bin/sh
62+-
63+-# Generic cross-platform init script logic
64+-# Copyright (c) Likewise Software, Inc.
65+-# All rights reserved.
66+-#
67+-# Authors: Jerry Carter (gcarter@likewisesoftware.com)
68+-# Kyle Stemen (kstemen@likewisesoftware.com)
69+-# Brian Koropoff (bkoropoff@likewisesoftware.com)
70+-
71+-# Implict arguments to this script when sourced:
72+-#
73+-# PROG_DESC - English description of program/service
74+-# PROG_BIN - path to the program binary
75+-# PROG_ARGS - additional arguments to pass to program on startup
76+-# PROG_ERR - file where error diagnostics are logged
77+-# PIDFILE - file where pid is stored (or empty/unset if a pid file is not created)
78+-# SCRIPTNAME - the name of the init script
79+-
80+-## Have to set the path for HP-UX boot process
81+-PATH=/sbin:/usr/sbin:/bin:/usr/bin:$PATH
82+-export PATH
83+-
84+-alias_replacement()
85+-{
86+- # Simulates the alias builtin function. It does this by creating a function
87+- # with the name of what should be aliased. So if it was run like this:
88+- # alias_replacement myecho='echo my'
89+- # Then the alias would be emulated like this:
90+- # myecho()
91+- # {
92+- # echo my "$@"
93+- # }
94+- if [ "$#" -ne 1 ]; then
95+- echo "alias takes 1 argument"
96+- return 1
97+- fi
98+- # This function is passed something like abc=xyz . The name variable gets
99+- # set to abc, and value gets set to xyz .
100+- name="`expr "$1" : '^\(.*\)='`"
101+- value="`expr "$1" : '.*=\(.*\)$'`"
102+- eval "$name() { $value \"\$@\"; }"
103+-}
104+-
105+-alias aliastest=echo
106+-type aliastest 1>/dev/null 2>/dev/null
107+-alias_works=$?
108+-
109+-_test_alias() { false; }
110+-alias _test_alias="true"
111+-case a in a) _test_alias; alias_case_works=$?;; esac
112+-eval '_test_alias >/dev/null 2>&1'
113+-alias_eval_works=$?
114+-
115+-if [ $alias_works -ne 0 -o $alias_case_works -ne 0 ]
116+-then
117+- ( alias() { true; } ) >/dev/null 2>&1
118+- can_overwrite_builtins=$?
119+- unset alias >/dev/null 2>&1
120+-
121+- if [ $alias_eval_works -eq 0 -a $can_overwrite_builtins -ne 0 ]; then
122+- # This is HP-UX. The alias command only takes effect when the file
123+- # is read. Furthermore, HP-UX won't let us redefine shell
124+- # builtins as system functions. So we'll have to alias
125+- # whatever shell builtins we need to now, and reread the file. The
126+- # alias_replacement function can realias the shell builtins after
127+- # they are renamed.
128+- echo_rename()
129+- {
130+- echo "$@"
131+- }
132+- alias echo=echo_rename
133+- alias alias=alias_replacement
134+- # It would cause problems if these aliases are left around for
135+- # when this script is resourced.
136+- unalias _test_alias
137+- unalias aliastest
138+- # Resource this script
139+- . EXECDIR/init-base.sh
140+- exit $?
141+- fi
142+-
143+- # This platform doesn't have a working alias (at all). It needs to be
144+- # replaced. This is primarily for Solaris and FreeBSD.
145+- alias()
146+- {
147+- alias_replacement "$@"
148+- }
149+-fi
150+-
151+-
152+-##
153+-## Determine what platform we are on
154+-##
155+-PLATFORM=""
156+-if [ -f /etc/init.d/functions ]; then
157+- . /etc/init.d/functions
158+- PLATFORM="REDHAT"
159+-elif [ -f /etc/rc.status ]; then
160+- . /etc/rc.status
161+- PLATFORM="SUSE"
162+-elif [ -f /etc/debian_version ]; then
163+- . /lib/lsb/init-functions
164+- PLATFORM="DEBIAN"
165+-elif [ "`uname -s`" = 'AIX' ]; then
166+- PLATFORM="AIX"
167+-elif [ "`uname -s`" = 'HP-UX' ]; then
168+- PLATFORM="HP-UX"
169+-elif [ "`uname -s`" = 'SunOS' ]; then
170+- PLATFORM="SOLARIS"
171+-elif [ "`uname -s`" = 'VMkernel' ]; then
172+- PLATFORM="ESXI"
173+-elif [ "`uname`" = "FreeBSD" -o "`uname`" = "Isilon OneFS" ]; then
174+- PLATFORM="FREEBSD"
175+- extra_commands="reload"
176+- reload_cmd=daemon_reload
177+- status_cmd=daemon_status
178+- start_cmd=daemon_start
179+- stop_cmd=daemon_stop
180+-else
181+- PLATFORM="UNKNOWN"
182+-fi
183+-
184+-if [ -f /etc/rc.subr ]; then
185+- . /etc/rc.subr
186+-fi
187+-
188+-if [ $PLATFORM = "HP-UX" -o $PLATFORM = "SOLARIS" -o $PLATFORM = "FREEBSD" ]; then
189+- LOCKFILE="/var/run/${SCRIPTNAME}.lock"
190+-else
191+- LOCKFILE="/var/lock/subsys/${SCRIPTNAME}"
192+-fi
193+-
194+-type printf 1>/dev/null 2>/dev/null
195+-if [ $? -ne 0 ]; then
196+- # Usually printf is a shell built in, but on HPUX it is a program located
197+- # at /bin/printf. During system startup and shutdown the path is only
198+- # /sbin, so we need to manually find printf
199+- if [ -x /bin/printf ]; then
200+- alias printf=/bin/printf
201+- else
202+- echo "WARNING: unable to find printf program"
203+- fi
204+-fi
205+-
206+-# echo_replacement emulates echo for all platforms using printf. printf is a
207+-# shell builtin that exists on all platforms.
208+-echo_replacement()
209+-{
210+- if [ "$1" = "-n" ]; then
211+- shift;
212+- printf %s "$*"
213+- else
214+- printf %s\\n "$*"
215+- fi
216+-}
217+-
218+-# 'echo -n' works with bash, but not with sh on Solaris, HPUX, and AIX.
219+-if [ "`echo -n`" = "-n" ]; then
220+- alias echo=echo_replacement
221+-fi
222+-
223+-seq_replacement()
224+-{
225+- FIRST=1
226+- INCREMENT=1
227+- case "$#" in
228+- 0)
229+- echo too few arguments
230+- return 1
231+- ;;
232+- 1)
233+- LAST="$1"
234+- ;;
235+- 2)
236+- FIRST="$1"
237+- LAST="$2"
238+- ;;
239+- 3)
240+- FIRST="$1"
241+- INCREMENT="$2"
242+- LAST="$3"
243+- ;;
244+- *)
245+- echo too many arguments
246+- return 1
247+- ;;
248+- esac
249+- i="$FIRST"
250+- while [ "$i" -le "$LAST" ]; do
251+- echo "$i"
252+- i="`expr "$i" + "$INCREMENT"`"
253+- done
254+- return 0;
255+-}
256+-
257+-# seq doesn't exist on HPUX or FreeBSD
258+-type seq 2>/dev/null 1>/dev/null
259+-if [ $? -ne 0 ]; then
260+- alias seq=seq_replacement
261+-fi
262+-
263+-##
264+-## small wrapper functions around distro specific calls
265+-##
266+-
267+-status_success() {
268+- case "${PLATFORM}" in
269+- REDHAT)
270+- echo_success
271+- echo
272+- ;;
273+- SUSE)
274+- rc_reset
275+- rc_status -v
276+- ;;
277+- DEBIAN)
278+- ;;
279+- AIX | HP-UX | SOLARIS | FREEBSD | ESXI | UNKNOWN)
280+- echo "...ok"
281+- ;;
282+- esac
283+-}
284+-
285+-status_failed() {
286+- status=$1
287+- case "${PLATFORM}" in
288+- REDHAT)
289+- echo_failure
290+- echo
291+- ;;
292+- SUSE)
293+- rc_failed $status
294+- rc_status -v
295+- ;;
296+- DEBIAN)
297+- ;;
298+- AIX | HP-UX | SOLARIS | ESXI | UNKNOWN)
299+- echo "...failed"
300+- ;;
301+- esac
302+-}
303+-
304+-print_status () {
305+- status=$1
306+-
307+- if [ $status = 0 ]; then
308+- status_success
309+- else
310+- status_failed $status
311+- fi
312+-}
313+-
314+-generic_status()
315+-{
316+- #Uses return codes specified in
317+- # http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
318+- pids="`generic_pid`"
319+- #Take the list of pids and get just the last one
320+- pid=""
321+- for i in $pids; do
322+- pid="$i"
323+- done
324+-
325+- if [ -n "$pid" ]
326+- then
327+- #Is the pid valid?
328+- #Does the program with that pid match our program name?
329+- #HP-UX needs UNIX95 set to support the -o option
330+- if [ "${PLATFORM}" = "ESXI" ]; then
331+- if kill -0 $pid > /dev/null 2>&1 ; then
332+- # pid is valid. have to assume it's the right program
333+- return 0
334+- else
335+- return 1
336+- fi
337+- fi
338+- pid_comm="`UNIX95=1 ps -p "$pid" -o args= 2>/dev/null | awk '{print $1}'`"
339+- if [ "$pid_comm" = "<defunct>" ]; then
340+- #It is a zombie process
341+- return 4
342+- fi
343+- if [ "$pid_comm" = "${PROG_BIN}" ]; then
344+- #If the system keeps cmdline files, check it
345+- if [ -f /proc/${pid}/cmdline ]; then
346+- #We can't check the exe file because we may be looking
347+- #at a version of the program that has been overwritten
348+- grep -q ${PROG_BIN} /proc/${pid}/cmdline && return 0
349+- else
350+- return 0
351+- fi
352+- fi
353+-
354+- #Program is dead, but lock file exists
355+- [ -f "${LOCKFILE}" ] && return 2
356+-
357+- #Program is dead, but pid file exists
358+- return 1
359+- else
360+- return 3
361+- fi
362+-}
363+-
364+-generic_pid()
365+-{
366+- if [ -n "${PIDFILE}" -a -f "${PIDFILE}" ]
367+- then
368+- cat "${PIDFILE}"
369+- else
370+- case "${PLATFORM}" in
371+- FREEBSD)
372+- pgrep -f "^${PROG_BIN}"
373+- ;;
374+- ESXI)
375+- ( ps | grep "^[0-9]* [0-9]* `basename ${PROG_BIN}` *${PROG_BIN}" | awk '{ print $1 };' | head -1 )
376+- ;;
377+- HP-UX)
378+- ( UNIX95= ps -e -o pid= -o args= | grep "^ *[0123456789]* *${PROG_BIN}" | awk '{ print $1 };' )
379+- ;;
380+- *)
381+- ( UNIX95=1; ps -e -o pid= -o args= | grep "^ *[0123456789]* *${PROG_BIN}" | awk '{ print $1 };' )
382+- ;;
383+- esac
384+- fi
385+-}
386+-
387+-check_load_path()
388+-{
389+- libdir=/opt/likewise/lib
390+- if [ -x /opt/likewise/lib64 ]; then
391+- libdir=/opt/likewise/lib64
392+- fi
393+- for name in LD_LIBRARY_PATH LIBPATH SHLIB_PATH; do
394+- eval value=\$$name
395+- if [ -n "$value" ]; then
396+- expr "$value" : "^$libdir:" >/dev/null
397+- if [ $? -ne 0 ]; then
398+- if type logger >/dev/null 2>&1; then
399+- logger -p daemon.error "LD_LIBRARY_PATH, LIBPATH, and SHLIB_PATH must be unset or list $libdir as the first directory. Likewise daemons will automatically unset the variable, but this variable still must be changed for the rest of your system. See the \"Requirements for the Agent\" section of the Likewise manual for more information."
400+- fi
401+- unset $name
402+- export $name
403+- fi
404+- fi
405+- done
406+- if [ -n "$LD_PRELOAD" ]; then
407+- if type logger >/dev/null 2>&1; then
408+- logger -p daemon.error "LD_PRELOAD must be unset. Likewise daemons will automatically unset the variable, but this variable still must be changed for the rest of your system. See the \"Requirements for the Agent\" section of the Likewise manual for more information."
409+- fi
410+- unset LD_PRELOAD
411+- export LD_PRELOAD
412+- fi
413+-}
414+-
415+-daemon_start() {
416+-
417+- if [ -f "${PROG_ERR}" ]; then
418+- /bin/rm -f $PROG_ERR;
419+- fi
420+-
421+- if [ -n "${STARTHOOK}" ]; then
422+- ${STARTHOOK}
423+- fi
424+-
425+- check_load_path
426+-
427+- case "${PLATFORM}" in
428+- REDHAT)
429+- echo -n $"Starting `basename ${PROG_BIN}`: "
430+- daemon ${PROG_BIN} ${PROG_ARGS}
431+- status=$?
432+- ;;
433+- SUSE)
434+- echo -n "Starting $PROG_DESC"
435+- startproc ${PROG_BIN} ${PROG_ARGS}
436+- status=$?
437+- ;;
438+- DEBIAN)
439+- log_daemon_msg "Starting $PROG_DESC: `basename $PROG_BIN`"
440+- start-stop-daemon --start --exec ${PROG_BIN} -- ${PROG_ARGS}
441+- status=$?
442+- log_end_msg $status
443+- ;;
444+- AIX)
445+- echo -n "Starting $PROG_DESC"
446+- if (lssrc -s dhcpcd | grep active >/dev/null); then
447+- # Wait up to 30 seconds for an ip address
448+- for i in `seq 30`; do
449+- ifconfig -a | grep inet | grep -v 127.0.0 | grep -v 0.0.0.0 | grep -v ::1/0 >/dev/null && break
450+- sleep 1
451+- done
452+- fi
453+- ${PROG_BIN} ${PROG_ARGS}
454+- status=$?
455+- if [ $status -eq 0 ]; then
456+- status=1
457+- for i in `seq 5`; do
458+- #Did the program start?
459+- generic_status
460+- status=$?
461+- [ $status -eq 0 ] && break
462+- sleep 1
463+- done
464+- fi
465+- ;;
466+- HP-UX | SOLARIS | FREEBSD | ESXI)
467+- echo -n "Starting $PROG_DESC"
468+- if type svcadm >/dev/null 2>&1 ; then
469+- # Use the solaris service manager
470+-
471+- # This will start the program again if it was in maintenance
472+- # mode.
473+- svcadm clear "$SCRIPTNAME" 2>/dev/null
474+- # This will start the program again if it was disabled.
475+- svcadm enable "$SCRIPTNAME"
476+- status=$?
477+- else
478+- ${PROG_BIN} ${PROG_ARGS}
479+- status=$?
480+- fi
481+- if [ $status -eq 0 ]; then
482+- status=1
483+- for i in `seq 5`; do
484+- #Did the program start?
485+- generic_status
486+- status=$?
487+- [ $status -eq 0 ] && break
488+- sleep 1
489+- done
490+- fi
491+- ;;
492+- UNKNOWN)
493+- ${PROG_BIN} ${PROG_ARGS}
494+- status=$?
495+- ;;
496+- esac
497+-
498+- if [ -n "${POSTSTARTHOOK}" ]; then
499+- ${POSTSTARTHOOK}
500+- fi
501+-
502+- [ $status = 0 ] && [ ${PLATFORM} != "DEBIAN" ] && touch ${LOCKFILE}
503+- return $status
504+-}
505+-
506+-daemon_stop() {
507+- case "${PLATFORM}" in
508+- REDHAT)
509+- echo -n $"Stopping `basename ${PROG_BIN}`: "
510+- killproc `basename ${PROG_BIN}`
511+- status=$?
512+- ;;
513+- SUSE)
514+- echo -n "Stopping $PROG_DESC "
515+- killproc -TERM ${PROG_BIN}
516+- status=$?
517+- ;;
518+- DEBIAN)
519+- log_daemon_msg "Stopping $PROG_DESC: `basename $PROG_BIN`"
520+- status=1
521+- #only try to stop the daemon if it is running
522+- if generic_status; then
523+- kill -TERM "`generic_pid`"
524+- # Forget our pidfile since it will now be invalid
525+- # if is still present. This means generic_status
526+- # will fall back on ps to see if the daemon is still
527+- # running. This is important on LinuxThreads-based
528+- # systems where other threads can still be in the process
529+- # of shutting down even when the main thread has exited
530+- PIDFILE=""
531+- #Wait up to 5 seconds for the program to end
532+- for i in `seq 5`; do
533+- #Did the program end?
534+- generic_status
535+- # Make sure the agent is not running and is not a zombie
536+- # process.
537+- [ $? -ne 0 -a $? -ne 4 ] && status=0 && break
538+- # use the following line instead after bug 3634 is fixed
539+- #[ $? -eq 3 -o $? -eq 2 ] && status=0 && break
540+- sleep 1
541+- done
542+- fi
543+- log_end_msg $status
544+- ;;
545+- AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
546+- echo -n "Stopping $PROG_DESC"
547+- status=1
548+- #only try to stop the daemon if it is running
549+- if generic_status; then
550+- pid="`generic_pid`"
551+- kill -TERM $pid
552+-
553+- #Wait up to 5 seconds for the program to end
554+- for i in `seq 5`; do
555+- #Did the program end?
556+- generic_status
557+- # Make sure the agent is not running and is not a zombie
558+- # process.
559+- [ $? -ne 0 -a $? -ne 4 ] && status=0 && break
560+- # use the following line instead after bug 3634 is fixed
561+- #[ $? -eq 3 -o $? -eq 2 ] && status=0 && break
562+- sleep 1
563+- done
564+- fi
565+- ;;
566+- UNKNOWN)
567+- killall -TERM `basename ${PROG_BIN}`
568+- status=$?
569+- ;;
570+- esac
571+-
572+- [ $status = 0 ] && /bin/rm -f ${LOCKFILE}
573+- return $status
574+-}
575+-
576+-daemon_reload()
577+-{
578+- case "${PLATFORM}" in
579+- REDHAT | SUSE | FREEBSD | ESXI)
580+- echo -n $"Reloading ${PROG_DESC} configuration"
581+- killall -HUP "`basename ${PROG_BIN}`"
582+- status=$?
583+- ;;
584+- DEBIAN)
585+- log_daemon_msg "Reloading $PROG_DESC configuration"
586+- killall -HUP "`basename ${PROG_BIN}`"
587+- status=$?
588+- log_end_msg $status
589+- ;;
590+- AIX | HP-UX | SOLARIS | UNKNOWN)
591+- echo -n "Stopping $PROG_DESC"
592+- generic_killall -HUP
593+- status=$?
594+- ;;
595+- esac
596+-
597+- return $status
598+-}
599+-
600+-daemon_status() {
601+- case "${PLATFORM}" in
602+- REDHAT)
603+- status ${PROG_BIN}
604+- ;;
605+- SUSE)
606+- checkproc ${PROG_BIN}
607+- rc_status -v
608+- ;;
609+- AIX | HP-UX | SOLARIS | DEBIAN | FREEBSD | ESXI)
610+- generic_status
611+- status=$?
612+- case "$status" in
613+- 0)
614+- echo "running";
615+- ;;
616+- 1)
617+- echo "stopped";
618+- #Use the bellow line instead after bug 3634 is fixed
619+- #echo "died leaving pid file";
620+- ;;
621+- 2)
622+- echo "died leaving lock file";
623+- ;;
624+- 3)
625+- echo "stopped";
626+- ;;
627+- esac
628+- return $status
629+- ;;
630+- UNKNOWN)
631+- echo "Not implemented."
632+- ;;
633+- esac
634+-}
635+-
636+-#Sends the signal specified by the first parameter to all instances
637+-#of $PROG_BIN
638+-generic_killall()
639+-{
640+- #This gets the list of all current running instances of PROG_BIN,
641+- #but it can't tell which directory the program was run from. If
642+- #cmdline is available in the proc pseudo-filesystem, we'll verify
643+- #the pids.
644+- unverified_pids=`generic_pid`
645+- pids=
646+- for pid in $unverified_pids; do
647+- #If the system keeps cmdline files, check them
648+- if [ -f /proc/${pid}/cmdline ]; then
649+- #We can't check the exe file because we may be looking
650+- #at a version of the program that has been overwritten
651+- grep -q ${AUTHD_BIN} /proc/${pid}/cmdline && pids="$pids $pid"
652+- else
653+- pids="$pids $pid"
654+- fi
655+- done
656+-
657+- for pid in $pids; do
658+- [ ! -z "`UNIX95=1 ps -p $pid -o pid=`" ] && kill "$1" $pid
659+- done
660+-
661+- #The manpage of killall says it returns 0 if at least one process is
662+- #killed. I can't get it to return anything other than 0. Even if no
663+- #processes die with SIGTERM. We'll just return 0 here too
664+- return 0
665+-}
666+-
667+-####################################################################
668+-## Main init script code
669+-##
670+-
671+-if type run_rc_command >/dev/null 2>&1; then
672+- # Looks like this is a FreeBSD based system. We should use their arg
673+- # parsing instead of our own.
674+- name="$SCRIPTNAME"
675+- rcvar="`set_rcvar`"
676+- command="$PROG_BIN"
677+- command_args="$PROG_ARGS"
678+- pidfile="$PIDFILE"
679+- eval "${name}_enable=YES"
680+-
681+- load_rc_config "$name"
682+- [ "$1" = "start" -a -n "${STARTHOOK}" ] && ${STARTHOOK}
683+- check_load_path
684+- run_rc_command "$1" || exit $?
685+- [ "$1" = "start" -a -n "${POSTSTARTHOOK}" ] && ${POSTSTARTHOOK}
686+- exit 0
687+-fi
688+-
689+-case "$1" in
690+- start)
691+- daemon_start
692+- ret=$?
693+- print_status $ret
694+- ;;
695+-
696+- stop)
697+- daemon_stop
698+- ret=$?
699+- print_status $ret
700+- ;;
701+-
702+- # HP-UX calls this
703+- stop_msg)
704+- echo "Stopping $PROG_DESC"
705+- exit 0
706+- ;;
707+-
708+- # HP-UX calls this
709+- start_msg)
710+- echo "Starting $PROG_DESC"
711+- exit 0
712+- ;;
713+-
714+- restart)
715+- daemon_stop
716+- ret=$?
717+- print_status $ret
718+- daemon_start
719+- ret=$?
720+- print_status $ret
721+- ;;
722+-
723+- status)
724+- daemon_status
725+- ;;
726+-
727+- reload)
728+- # Ignore SIGHUP since killall could send it to us as well
729+- trap '' HUP
730+- daemon_reload
731+- ret=$?
732+- print_status $ret
733+- ;;
734+- *)
735+- echo "Usage: $0 {start|stop|restart|status|reload}"
736+- exit 1
737+- ;;
738+-esac
739+-
740+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/init-base.sh.in likewise-open.new/git-build/config/init-base.sh.in
741+--- likewise-open/git-build/config/init-base.sh.in 1969-12-31 16:00:00.000000000 -0800
742++++ likewise-open.new/git-build/config/init-base.sh.in 2011-09-09 14:27:31.000000000 -0700
743+@@ -0,0 +1,679 @@
744++#!/bin/sh
745++
746++# Generic cross-platform init script logic
747++# Copyright (c) Likewise Software, Inc.
748++# All rights reserved.
749++#
750++# Authors: Jerry Carter (gcarter@likewisesoftware.com)
751++# Kyle Stemen (kstemen@likewisesoftware.com)
752++# Brian Koropoff (bkoropoff@likewisesoftware.com)
753++
754++# Implict arguments to this script when sourced:
755++#
756++# PROG_DESC - English description of program/service
757++# PROG_BIN - path to the program binary
758++# PROG_ARGS - additional arguments to pass to program on startup
759++# PROG_ERR - file where error diagnostics are logged
760++# PIDFILE - file where pid is stored (or empty/unset if a pid file is not created)
761++# SCRIPTNAME - the name of the init script
762++
763++## Have to set the path for HP-UX boot process
764++PATH=/sbin:/usr/sbin:/bin:/usr/bin:$PATH
765++export PATH
766++
767++alias_replacement()
768++{
769++ # Simulates the alias builtin function. It does this by creating a function
770++ # with the name of what should be aliased. So if it was run like this:
771++ # alias_replacement myecho='echo my'
772++ # Then the alias would be emulated like this:
773++ # myecho()
774++ # {
775++ # echo my "$@"
776++ # }
777++ if [ "$#" -ne 1 ]; then
778++ echo "alias takes 1 argument"
779++ return 1
780++ fi
781++ # This function is passed something like abc=xyz . The name variable gets
782++ # set to abc, and value gets set to xyz .
783++ name="`expr "$1" : '^\(.*\)='`"
784++ value="`expr "$1" : '.*=\(.*\)$'`"
785++ eval "$name() { $value \"\$@\"; }"
786++}
787++
788++alias aliastest=echo
789++type aliastest 1>/dev/null 2>/dev/null
790++alias_works=$?
791++
792++_test_alias() { false; }
793++alias _test_alias="true"
794++case a in a) _test_alias; alias_case_works=$?;; esac
795++eval '_test_alias >/dev/null 2>&1'
796++alias_eval_works=$?
797++
798++if [ $alias_works -ne 0 -o $alias_case_works -ne 0 ]
799++then
800++ ( alias() { true; } ) >/dev/null 2>&1
801++ can_overwrite_builtins=$?
802++ unset alias >/dev/null 2>&1
803++
804++ if [ $alias_eval_works -eq 0 -a $can_overwrite_builtins -ne 0 ]; then
805++ # This is HP-UX. The alias command only takes effect when the file
806++ # is read. Furthermore, HP-UX won't let us redefine shell
807++ # builtins as system functions. So we'll have to alias
808++ # whatever shell builtins we need to now, and reread the file. The
809++ # alias_replacement function can realias the shell builtins after
810++ # they are renamed.
811++ echo_rename()
812++ {
813++ echo "$@"
814++ }
815++ alias echo=echo_rename
816++ alias alias=alias_replacement
817++ # It would cause problems if these aliases are left around for
818++ # when this script is resourced.
819++ unalias _test_alias
820++ unalias aliastest
821++ # Resource this script
822++ . @MK_LIBEXECDIR@/init-base.sh
823++ exit $?
824++ fi
825++
826++ # This platform doesn't have a working alias (at all). It needs to be
827++ # replaced. This is primarily for Solaris and FreeBSD.
828++ alias()
829++ {
830++ alias_replacement "$@"
831++ }
832++fi
833++
834++
835++##
836++## Determine what platform we are on
837++##
838++PLATFORM=""
839++if [ -f /etc/init.d/functions ]; then
840++ . /etc/init.d/functions
841++ PLATFORM="REDHAT"
842++elif [ -f /etc/rc.status ]; then
843++ . /etc/rc.status
844++ PLATFORM="SUSE"
845++elif [ -f /etc/debian_version ]; then
846++ . /lib/lsb/init-functions
847++ PLATFORM="DEBIAN"
848++elif [ "`uname -s`" = 'AIX' ]; then
849++ PLATFORM="AIX"
850++elif [ "`uname -s`" = 'HP-UX' ]; then
851++ PLATFORM="HP-UX"
852++elif [ "`uname -s`" = 'SunOS' ]; then
853++ PLATFORM="SOLARIS"
854++elif [ "`uname -s`" = 'VMkernel' ]; then
855++ PLATFORM="ESXI"
856++elif [ "`uname`" = "FreeBSD" -o "`uname`" = "Isilon OneFS" ]; then
857++ PLATFORM="FREEBSD"
858++ extra_commands="reload"
859++ reload_cmd=daemon_reload
860++ status_cmd=daemon_status
861++ start_cmd=daemon_start
862++ stop_cmd=daemon_stop
863++else
864++ PLATFORM="UNKNOWN"
865++fi
866++
867++if [ -f /etc/rc.subr ]; then
868++ . /etc/rc.subr
869++fi
870++
871++if [ $PLATFORM = "HP-UX" -o $PLATFORM = "SOLARIS" -o $PLATFORM = "FREEBSD" ]; then
872++ LOCKFILE="/var/run/${SCRIPTNAME}.lock"
873++else
874++ LOCKFILE="/var/lock/subsys/${SCRIPTNAME}"
875++fi
876++
877++type printf 1>/dev/null 2>/dev/null
878++if [ $? -ne 0 ]; then
879++ # Usually printf is a shell built in, but on HPUX it is a program located
880++ # at /bin/printf. During system startup and shutdown the path is only
881++ # /sbin, so we need to manually find printf
882++ if [ -x /bin/printf ]; then
883++ alias printf=/bin/printf
884++ else
885++ echo "WARNING: unable to find printf program"
886++ fi
887++fi
888++
889++# echo_replacement emulates echo for all platforms using printf. printf is a
890++# shell builtin that exists on all platforms.
891++echo_replacement()
892++{
893++ if [ "$1" = "-n" ]; then
894++ shift;
895++ printf %s "$*"
896++ else
897++ printf %s\\n "$*"
898++ fi
899++}
900++
901++# 'echo -n' works with bash, but not with sh on Solaris, HPUX, and AIX.
902++if [ "`echo -n`" = "-n" ]; then
903++ alias echo=echo_replacement
904++fi
905++
906++seq_replacement()
907++{
908++ FIRST=1
909++ INCREMENT=1
910++ case "$#" in
911++ 0)
912++ echo too few arguments
913++ return 1
914++ ;;
915++ 1)
916++ LAST="$1"
917++ ;;
918++ 2)
919++ FIRST="$1"
920++ LAST="$2"
921++ ;;
922++ 3)
923++ FIRST="$1"
924++ INCREMENT="$2"
925++ LAST="$3"
926++ ;;
927++ *)
928++ echo too many arguments
929++ return 1
930++ ;;
931++ esac
932++ i="$FIRST"
933++ while [ "$i" -le "$LAST" ]; do
934++ echo "$i"
935++ i="`expr "$i" + "$INCREMENT"`"
936++ done
937++ return 0;
938++}
939++
940++# seq doesn't exist on HPUX or FreeBSD
941++type seq 2>/dev/null 1>/dev/null
942++if [ $? -ne 0 ]; then
943++ alias seq=seq_replacement
944++fi
945++
946++##
947++## small wrapper functions around distro specific calls
948++##
949++
950++status_success() {
951++ case "${PLATFORM}" in
952++ REDHAT)
953++ echo_success
954++ echo
955++ ;;
956++ SUSE)
957++ rc_reset
958++ rc_status -v
959++ ;;
960++ DEBIAN)
961++ ;;
962++ AIX | HP-UX | SOLARIS | FREEBSD | ESXI | UNKNOWN)
963++ echo "...ok"
964++ ;;
965++ esac
966++}
967++
968++status_failed() {
969++ status=$1
970++ case "${PLATFORM}" in
971++ REDHAT)
972++ echo_failure
973++ echo
974++ ;;
975++ SUSE)
976++ rc_failed $status
977++ rc_status -v
978++ ;;
979++ DEBIAN)
980++ ;;
981++ AIX | HP-UX | SOLARIS | ESXI | UNKNOWN)
982++ echo "...failed"
983++ ;;
984++ esac
985++}
986++
987++print_status () {
988++ status=$1
989++
990++ if [ $status = 0 ]; then
991++ status_success
992++ else
993++ status_failed $status
994++ fi
995++}
996++
997++generic_status()
998++{
999++ #Uses return codes specified in
1000++ # http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
1001++ pids="`generic_pid`"
1002++ #Take the list of pids and get just the last one
1003++ pid=""
1004++ for i in $pids; do
1005++ pid="$i"
1006++ done
1007++
1008++ if [ -n "$pid" ]
1009++ then
1010++ #Is the pid valid?
1011++ #Does the program with that pid match our program name?
1012++ #HP-UX needs UNIX95 set to support the -o option
1013++ if [ "${PLATFORM}" = "ESXI" ]; then
1014++ if kill -0 $pid > /dev/null 2>&1 ; then
1015++ # pid is valid. have to assume it's the right program
1016++ return 0
1017++ else
1018++ return 1
1019++ fi
1020++ fi
1021++ pid_comm="`UNIX95=1 ps -p "$pid" -o args= 2>/dev/null | awk '{print $1}'`"
1022++ if [ "$pid_comm" = "<defunct>" ]; then
1023++ #It is a zombie process
1024++ return 4
1025++ fi
1026++ if [ "$pid_comm" = "${PROG_BIN}" ]; then
1027++ #If the system keeps cmdline files, check it
1028++ if [ -f /proc/${pid}/cmdline ]; then
1029++ #We can't check the exe file because we may be looking
1030++ #at a version of the program that has been overwritten
1031++ grep -q ${PROG_BIN} /proc/${pid}/cmdline && return 0
1032++ else
1033++ return 0
1034++ fi
1035++ fi
1036++
1037++ #Program is dead, but lock file exists
1038++ [ -f "${LOCKFILE}" ] && return 2
1039++
1040++ #Program is dead, but pid file exists
1041++ return 1
1042++ else
1043++ return 3
1044++ fi
1045++}
1046++
1047++generic_pid()
1048++{
1049++ if [ -n "${PIDFILE}" -a -f "${PIDFILE}" ]
1050++ then
1051++ cat "${PIDFILE}"
1052++ else
1053++ case "${PLATFORM}" in
1054++ FREEBSD)
1055++ pgrep -f "^${PROG_BIN}"
1056++ ;;
1057++ ESXI)
1058++ ( ps | grep "^[0-9]* [0-9]* `basename ${PROG_BIN}` *${PROG_BIN}" | awk '{ print $1 };' | head -1 )
1059++ ;;
1060++ HP-UX)
1061++ ( UNIX95= ps -e -o pid= -o args= | grep "^ *[0123456789]* *${PROG_BIN}" | awk '{ print $1 };' )
1062++ ;;
1063++ *)
1064++ ( UNIX95=1; ps -e -o pid= -o args= | grep "^ *[0123456789]* *${PROG_BIN}" | awk '{ print $1 };' )
1065++ ;;
1066++ esac
1067++ fi
1068++}
1069++
1070++check_load_path()
1071++{
1072++ libdir=/opt/likewise/lib
1073++ if [ -x /opt/likewise/lib64 ]; then
1074++ libdir=/opt/likewise/lib64
1075++ fi
1076++ for name in LD_LIBRARY_PATH LIBPATH SHLIB_PATH; do
1077++ eval value=\$$name
1078++ if [ -n "$value" ]; then
1079++ expr "$value" : "^$libdir:" >/dev/null
1080++ if [ $? -ne 0 ]; then
1081++ if type logger >/dev/null 2>&1; then
1082++ logger -p daemon.error "LD_LIBRARY_PATH, LIBPATH, and SHLIB_PATH must be unset or list $libdir as the first directory. Likewise daemons will automatically unset the variable, but this variable still must be changed for the rest of your system. See the \"Requirements for the Agent\" section of the Likewise manual for more information."
1083++ fi
1084++ unset $name
1085++ export $name
1086++ fi
1087++ fi
1088++ done
1089++ if [ -n "$LD_PRELOAD" ]; then
1090++ if type logger >/dev/null 2>&1; then
1091++ logger -p daemon.error "LD_PRELOAD must be unset. Likewise daemons will automatically unset the variable, but this variable still must be changed for the rest of your system. See the \"Requirements for the Agent\" section of the Likewise manual for more information."
1092++ fi
1093++ unset LD_PRELOAD
1094++ export LD_PRELOAD
1095++ fi
1096++}
1097++
1098++daemon_start() {
1099++
1100++ if [ -f "${PROG_ERR}" ]; then
1101++ /bin/rm -f $PROG_ERR;
1102++ fi
1103++
1104++ if [ -n "${STARTHOOK}" ]; then
1105++ ${STARTHOOK}
1106++ fi
1107++
1108++ check_load_path
1109++
1110++ case "${PLATFORM}" in
1111++ REDHAT)
1112++ echo -n $"Starting `basename ${PROG_BIN}`: "
1113++ daemon ${PROG_BIN} ${PROG_ARGS}
1114++ status=$?
1115++ ;;
1116++ SUSE)
1117++ echo -n "Starting $PROG_DESC"
1118++ startproc ${PROG_BIN} ${PROG_ARGS}
1119++ status=$?
1120++ ;;
1121++ DEBIAN)
1122++ log_daemon_msg "Starting $PROG_DESC: `basename $PROG_BIN`"
1123++ start-stop-daemon --start --exec ${PROG_BIN} -- ${PROG_ARGS}
1124++ status=$?
1125++ log_end_msg $status
1126++ ;;
1127++ AIX)
1128++ echo -n "Starting $PROG_DESC"
1129++ if (lssrc -s dhcpcd | grep active >/dev/null); then
1130++ # Wait up to 30 seconds for an ip address
1131++ for i in `seq 30`; do
1132++ ifconfig -a | grep inet | grep -v 127.0.0 | grep -v 0.0.0.0 | grep -v ::1/0 >/dev/null && break
1133++ sleep 1
1134++ done
1135++ fi
1136++ ${PROG_BIN} ${PROG_ARGS}
1137++ status=$?
1138++ if [ $status -eq 0 ]; then
1139++ status=1
1140++ for i in `seq 5`; do
1141++ #Did the program start?
1142++ generic_status
1143++ status=$?
1144++ [ $status -eq 0 ] && break
1145++ sleep 1
1146++ done
1147++ fi
1148++ ;;
1149++ HP-UX | SOLARIS | FREEBSD | ESXI)
1150++ echo -n "Starting $PROG_DESC"
1151++ if type svcadm >/dev/null 2>&1 ; then
1152++ # Use the solaris service manager
1153++
1154++ # This will start the program again if it was in maintenance
1155++ # mode.
1156++ svcadm clear "$SCRIPTNAME" 2>/dev/null
1157++ # This will start the program again if it was disabled.
1158++ svcadm enable "$SCRIPTNAME"
1159++ status=$?
1160++ else
1161++ ${PROG_BIN} ${PROG_ARGS}
1162++ status=$?
1163++ fi
1164++ if [ $status -eq 0 ]; then
1165++ status=1
1166++ for i in `seq 5`; do
1167++ #Did the program start?
1168++ generic_status
1169++ status=$?
1170++ [ $status -eq 0 ] && break
1171++ sleep 1
1172++ done
1173++ fi
1174++ ;;
1175++ UNKNOWN)
1176++ ${PROG_BIN} ${PROG_ARGS}
1177++ status=$?
1178++ ;;
1179++ esac
1180++
1181++ if [ -n "${POSTSTARTHOOK}" ]; then
1182++ ${POSTSTARTHOOK}
1183++ fi
1184++
1185++ [ $status = 0 ] && [ ${PLATFORM} != "DEBIAN" ] && touch ${LOCKFILE}
1186++ return $status
1187++}
1188++
1189++daemon_stop() {
1190++ case "${PLATFORM}" in
1191++ REDHAT)
1192++ echo -n $"Stopping `basename ${PROG_BIN}`: "
1193++ killproc `basename ${PROG_BIN}`
1194++ status=$?
1195++ ;;
1196++ SUSE)
1197++ echo -n "Stopping $PROG_DESC "
1198++ killproc -TERM ${PROG_BIN}
1199++ status=$?
1200++ ;;
1201++ DEBIAN)
1202++ log_daemon_msg "Stopping $PROG_DESC: `basename $PROG_BIN`"
1203++ status=1
1204++ #only try to stop the daemon if it is running
1205++ if generic_status; then
1206++ kill -TERM "`generic_pid`"
1207++ # Forget our pidfile since it will now be invalid
1208++ # if is still present. This means generic_status
1209++ # will fall back on ps to see if the daemon is still
1210++ # running. This is important on LinuxThreads-based
1211++ # systems where other threads can still be in the process
1212++ # of shutting down even when the main thread has exited
1213++ PIDFILE=""
1214++ #Wait up to 5 seconds for the program to end
1215++ for i in `seq 5`; do
1216++ #Did the program end?
1217++ generic_status
1218++ # Make sure the agent is not running and is not a zombie
1219++ # process.
1220++ [ $? -ne 0 -a $? -ne 4 ] && status=0 && break
1221++ # use the following line instead after bug 3634 is fixed
1222++ #[ $? -eq 3 -o $? -eq 2 ] && status=0 && break
1223++ sleep 1
1224++ done
1225++ fi
1226++ log_end_msg $status
1227++ ;;
1228++ AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
1229++ echo -n "Stopping $PROG_DESC"
1230++ status=1
1231++ #only try to stop the daemon if it is running
1232++ if generic_status; then
1233++ pid="`generic_pid`"
1234++ kill -TERM $pid
1235++
1236++ #Wait up to 5 seconds for the program to end
1237++ for i in `seq 5`; do
1238++ #Did the program end?
1239++ generic_status
1240++ # Make sure the agent is not running and is not a zombie
1241++ # process.
1242++ [ $? -ne 0 -a $? -ne 4 ] && status=0 && break
1243++ # use the following line instead after bug 3634 is fixed
1244++ #[ $? -eq 3 -o $? -eq 2 ] && status=0 && break
1245++ sleep 1
1246++ done
1247++ fi
1248++ ;;
1249++ UNKNOWN)
1250++ killall -TERM `basename ${PROG_BIN}`
1251++ status=$?
1252++ ;;
1253++ esac
1254++
1255++ [ $status = 0 ] && /bin/rm -f ${LOCKFILE}
1256++ return $status
1257++}
1258++
1259++daemon_reload()
1260++{
1261++ case "${PLATFORM}" in
1262++ REDHAT | SUSE | FREEBSD | ESXI)
1263++ echo -n $"Reloading ${PROG_DESC} configuration"
1264++ killall -HUP "`basename ${PROG_BIN}`"
1265++ status=$?
1266++ ;;
1267++ DEBIAN)
1268++ log_daemon_msg "Reloading $PROG_DESC configuration"
1269++ killall -HUP "`basename ${PROG_BIN}`"
1270++ status=$?
1271++ log_end_msg $status
1272++ ;;
1273++ AIX | HP-UX | SOLARIS | UNKNOWN)
1274++ echo -n "Stopping $PROG_DESC"
1275++ generic_killall -HUP
1276++ status=$?
1277++ ;;
1278++ esac
1279++
1280++ return $status
1281++}
1282++
1283++daemon_status() {
1284++ case "${PLATFORM}" in
1285++ REDHAT)
1286++ status ${PROG_BIN}
1287++ ;;
1288++ SUSE)
1289++ checkproc ${PROG_BIN}
1290++ rc_status -v
1291++ ;;
1292++ AIX | HP-UX | SOLARIS | DEBIAN | FREEBSD | ESXI)
1293++ generic_status
1294++ status=$?
1295++ case "$status" in
1296++ 0)
1297++ echo "running";
1298++ ;;
1299++ 1)
1300++ echo "stopped";
1301++ #Use the bellow line instead after bug 3634 is fixed
1302++ #echo "died leaving pid file";
1303++ ;;
1304++ 2)
1305++ echo "died leaving lock file";
1306++ ;;
1307++ 3)
1308++ echo "stopped";
1309++ ;;
1310++ esac
1311++ return $status
1312++ ;;
1313++ UNKNOWN)
1314++ echo "Not implemented."
1315++ ;;
1316++ esac
1317++}
1318++
1319++#Sends the signal specified by the first parameter to all instances
1320++#of $PROG_BIN
1321++generic_killall()
1322++{
1323++ #This gets the list of all current running instances of PROG_BIN,
1324++ #but it can't tell which directory the program was run from. If
1325++ #cmdline is available in the proc pseudo-filesystem, we'll verify
1326++ #the pids.
1327++ unverified_pids=`generic_pid`
1328++ pids=
1329++ for pid in $unverified_pids; do
1330++ #If the system keeps cmdline files, check them
1331++ if [ -f /proc/${pid}/cmdline ]; then
1332++ #We can't check the exe file because we may be looking
1333++ #at a version of the program that has been overwritten
1334++ grep -q ${AUTHD_BIN} /proc/${pid}/cmdline && pids="$pids $pid"
1335++ else
1336++ pids="$pids $pid"
1337++ fi
1338++ done
1339++
1340++ for pid in $pids; do
1341++ [ ! -z "`UNIX95=1 ps -p $pid -o pid=`" ] && kill "$1" $pid
1342++ done
1343++
1344++ #The manpage of killall says it returns 0 if at least one process is
1345++ #killed. I can't get it to return anything other than 0. Even if no
1346++ #processes die with SIGTERM. We'll just return 0 here too
1347++ return 0
1348++}
1349++
1350++####################################################################
1351++## Main init script code
1352++##
1353++
1354++if type run_rc_command >/dev/null 2>&1; then
1355++ # Looks like this is a FreeBSD based system. We should use their arg
1356++ # parsing instead of our own.
1357++ name="$SCRIPTNAME"
1358++ rcvar="`set_rcvar`"
1359++ command="$PROG_BIN"
1360++ command_args="$PROG_ARGS"
1361++ pidfile="$PIDFILE"
1362++ eval "${name}_enable=YES"
1363++
1364++ load_rc_config "$name"
1365++ [ "$1" = "start" -a -n "${STARTHOOK}" ] && ${STARTHOOK}
1366++ check_load_path
1367++ run_rc_command "$1" || exit $?
1368++ [ "$1" = "start" -a -n "${POSTSTARTHOOK}" ] && ${POSTSTARTHOOK}
1369++ exit 0
1370++fi
1371++
1372++case "$1" in
1373++ start)
1374++ daemon_start
1375++ ret=$?
1376++ print_status $ret
1377++ ;;
1378++
1379++ stop)
1380++ daemon_stop
1381++ ret=$?
1382++ print_status $ret
1383++ ;;
1384++
1385++ # HP-UX calls this
1386++ stop_msg)
1387++ echo "Stopping $PROG_DESC"
1388++ exit 0
1389++ ;;
1390++
1391++ # HP-UX calls this
1392++ start_msg)
1393++ echo "Starting $PROG_DESC"
1394++ exit 0
1395++ ;;
1396++
1397++ restart)
1398++ daemon_stop
1399++ ret=$?
1400++ print_status $ret
1401++ daemon_start
1402++ ret=$?
1403++ print_status $ret
1404++ ;;
1405++
1406++ status)
1407++ daemon_status
1408++ ;;
1409++
1410++ reload)
1411++ # Ignore SIGHUP since killall could send it to us as well
1412++ trap '' HUP
1413++ daemon_reload
1414++ ret=$?
1415++ print_status $ret
1416++ ;;
1417++ *)
1418++ echo "Usage: $0 {start|stop|restart|status|reload}"
1419++ exit 1
1420++ ;;
1421++esac
1422++
1423+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/init-likewise.sh likewise-open.new/git-build/config/init-likewise.sh
1424+--- likewise-open/git-build/config/init-likewise.sh 2011-09-09 11:04:54.000000000 -0700
1425++++ likewise-open.new/git-build/config/init-likewise.sh 1969-12-31 16:00:00.000000000 -0800
1426+@@ -1,251 +0,0 @@
1427+-#!/bin/sh
1428+-# Implicit arguments
1429+-# PREFIX - prefix of Likewise installation
1430+-# SERVICE_NAME - name of the service
1431+-
1432+-LWSM="${PREFIX}/bin/lwsm"
1433+-
1434+-PLATFORM=""
1435+-if [ -f /etc/init.d/functions ]; then
1436+- . /etc/init.d/functions
1437+- PLATFORM="REDHAT"
1438+-elif [ -f /etc/rc.status ]; then
1439+- . /etc/rc.status
1440+- PLATFORM="SUSE"
1441+-elif [ -f /etc/debian_version ]; then
1442+- . /lib/lsb/init-functions
1443+- PLATFORM="DEBIAN"
1444+-elif [ "`uname -s`" = 'AIX' ]; then
1445+- PLATFORM="AIX"
1446+-elif [ "`uname -s`" = 'HP-UX' ]; then
1447+- PLATFORM="HP-UX"
1448+-elif [ "`uname -s`" = 'SunOS' ]; then
1449+- PLATFORM="SOLARIS"
1450+-elif [ "`uname -s`" = 'VMkernel' ]; then
1451+- PLATFORM="ESXI"
1452+-elif [ "`uname`" = "FreeBSD" ]; then
1453+- PLATFORM="FREEBSD"
1454+-else
1455+- PLATFORM="UNKNOWN"
1456+-fi
1457+-
1458+-service_description()
1459+-{
1460+- echo "Likewise Open services"
1461+-}
1462+-
1463+-service_start()
1464+-{
1465+- status=""
1466+-
1467+- case "${PLATFORM}" in
1468+- REDHAT)
1469+- printf "%s" "Starting `service_description`: "
1470+- ${LWSM} -q autostart
1471+- status=$?
1472+- if [ $status -eq 0 ]
1473+- then
1474+- echo_success
1475+- echo
1476+- else
1477+- echo_failure
1478+- echo
1479+- fi
1480+- ;;
1481+- SUSE)
1482+- printf "%s" "Starting `service_description`"
1483+- ${LWSM} -q autostart
1484+- status=$?
1485+- if [ $status -eq 0 ]
1486+- then
1487+- rc_reset
1488+- rc_status -v
1489+- else
1490+- rc_failed $status
1491+- rc_status -v
1492+- fi
1493+- ;;
1494+- DEBIAN)
1495+- log_daemon_msg "Starting `service_description`"
1496+- ${LWSM} -q autostart
1497+- status=$?
1498+- log_end_msg $status
1499+- ;;
1500+- HP-UX | SOLARIS | FREEBSD | ESXI | AIX)
1501+- printf "%s" "Starting `service_description`"
1502+- if [ -x /usr/sbin/svcadm ]; then
1503+- # Don't do anything!
1504+- status=0
1505+- else
1506+- ${LWSM} -q autostart
1507+- status=$?
1508+- fi
1509+-
1510+- if [ $status -eq 0 ]
1511+- then
1512+- echo " ...ok"
1513+- else
1514+- echo " ...failed"
1515+- fi
1516+- ;;
1517+- UNKNOWN)
1518+- ${LWSM} -q autostart
1519+- status=$?
1520+- ;;
1521+- esac
1522+-
1523+- return $status
1524+-}
1525+-
1526+-service_restart()
1527+-{
1528+- status=""
1529+-
1530+- case "${PLATFORM}" in
1531+- REDHAT)
1532+- printf "%s" "Restarting `service_description` (not supported)"
1533+- status=0
1534+- echo_success
1535+- ;;
1536+- SUSE)
1537+- printf "%s" "Restarting `service_description` (not supported)"
1538+- status=0
1539+- rc_reset
1540+- rc_status -v
1541+- ;;
1542+- DEBIAN)
1543+- log_daemon_msg "Restarting `service_description` (not supported)"
1544+- status=0
1545+- log_end_msg $status
1546+- ;;
1547+- HP-UX | SOLARIS | FREEBSD | ESXI | AIX)
1548+- printf "%s" "Restarting `service_description` (not supported)"
1549+- status=0
1550+- echo " ...ok"
1551+- ;;
1552+- UNKNOWN)
1553+- status=0
1554+- ;;
1555+- esac
1556+-
1557+- return $status
1558+-}
1559+-
1560+-service_stop()
1561+-{
1562+- status=""
1563+-
1564+- case "${PLATFORM}" in
1565+- REDHAT)
1566+- printf "%s" "Stopping `service_description` (not supported) "
1567+- status=0
1568+- echo_success
1569+- ;;
1570+- SUSE)
1571+- printf "%s" "Stopping `service_description` (not supported)"
1572+- status=0
1573+- rc_reset
1574+- rc_status -v
1575+- ;;
1576+- DEBIAN)
1577+- log_daemon_msg "Stopping `service_description` (not supported)"
1578+- status=0
1579+- log_end_msg $status
1580+- ;;
1581+- AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
1582+- printf "%s" "Stopping `service_description` (not supported)"
1583+- status=0
1584+- echo " ...ok"
1585+- ;;
1586+- UNKNOWN)
1587+- status=0
1588+- ;;
1589+- esac
1590+-
1591+- return $status
1592+-}
1593+-
1594+-service_refresh()
1595+-{
1596+- case "${PLATFORM}" in
1597+- REDHAT)
1598+- printf "%s" "Refreshing `service_description $1` configuration"
1599+- status=0
1600+- echo_success
1601+- ;;
1602+- SUSE)
1603+- printf "%s" "Refreshing `service_description $1` configuration"
1604+- status=0
1605+- rc_reset
1606+- rc_status -v
1607+- ;;
1608+- DEBIAN)
1609+- log_daemon_msg "Refreshing `service_description $1` configuration"
1610+- status=0
1611+- log_end_msg $status
1612+- ;;
1613+- AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
1614+- printf "%s" "Refreshing `service_description $1` configuration"
1615+- status=0
1616+- echo " ...ok"
1617+- ;;
1618+- UNKNOWN)
1619+- status=0
1620+- ;;
1621+- esac
1622+-
1623+- return $status
1624+-}
1625+-
1626+-if [ -f /etc/rc.subr ]; then
1627+- . /etc/rc.subr
1628+-fi
1629+-
1630+-case "$1" in
1631+- start|faststart|forcestart|onestart)
1632+- service_start "$SERVICE_NAME"
1633+- exit $?
1634+- ;;
1635+- stop|faststop|forcestop|onestop)
1636+- service_stop "$SERVICE_NAME"
1637+- exit $?
1638+- ;;
1639+- status|faststatus|forcestatus|onestop)
1640+- echo "not supported"
1641+- exit 0
1642+- ;;
1643+- restart|fastrestart|forcerestart|onerestart)
1644+- service_restart "$SERVICE_NAME"
1645+- exit $?
1646+- ;;
1647+- refresh|reload)
1648+- service_refresh "$SERVICE_NAME"
1649+- exit $?
1650+- ;;
1651+- start_msg)
1652+- echo "Starting `service_description`"
1653+- exit 0
1654+- ;;
1655+- stop_msg)
1656+- echo "Stopping `service_description` (not supported)"
1657+- exit 0
1658+- ;;
1659+- rcvar|fastrcvar|forcercvar|onercvar)
1660+- if type run_rc_command >/dev/null 2>&1; then
1661+- # Looks like this is a FreeBSD based system.
1662+- name=likewise
1663+- rcvar="`set_rcvar`"
1664+- start_cmd="service_start"
1665+- stop_cmd="service_stop"
1666+- eval "${name}_enable=YES"
1667+-
1668+- load_rc_config "$name"
1669+- run_rc_command "$1" || exit $?
1670+- exit 0
1671+- fi
1672+- ;;
1673+- *)
1674+- echo "Unrecognized command: $1"
1675+- exit 1
1676+- ;;
1677+-esac
1678+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/init-likewise.sh.in likewise-open.new/git-build/config/init-likewise.sh.in
1679+--- likewise-open/git-build/config/init-likewise.sh.in 1969-12-31 16:00:00.000000000 -0800
1680++++ likewise-open.new/git-build/config/init-likewise.sh.in 2011-09-09 11:04:54.000000000 -0700
1681+@@ -0,0 +1,251 @@
1682++#!/bin/sh
1683++# Implicit arguments
1684++# PREFIX - prefix of Likewise installation
1685++# SERVICE_NAME - name of the service
1686++
1687++LWSM="${PREFIX}/bin/lwsm"
1688++
1689++PLATFORM=""
1690++if [ -f /etc/init.d/functions ]; then
1691++ . /etc/init.d/functions
1692++ PLATFORM="REDHAT"
1693++elif [ -f /etc/rc.status ]; then
1694++ . /etc/rc.status
1695++ PLATFORM="SUSE"
1696++elif [ -f /etc/debian_version ]; then
1697++ . /lib/lsb/init-functions
1698++ PLATFORM="DEBIAN"
1699++elif [ "`uname -s`" = 'AIX' ]; then
1700++ PLATFORM="AIX"
1701++elif [ "`uname -s`" = 'HP-UX' ]; then
1702++ PLATFORM="HP-UX"
1703++elif [ "`uname -s`" = 'SunOS' ]; then
1704++ PLATFORM="SOLARIS"
1705++elif [ "`uname -s`" = 'VMkernel' ]; then
1706++ PLATFORM="ESXI"
1707++elif [ "`uname`" = "FreeBSD" ]; then
1708++ PLATFORM="FREEBSD"
1709++else
1710++ PLATFORM="UNKNOWN"
1711++fi
1712++
1713++service_description()
1714++{
1715++ echo "Likewise Open services"
1716++}
1717++
1718++service_start()
1719++{
1720++ status=""
1721++
1722++ case "${PLATFORM}" in
1723++ REDHAT)
1724++ printf "%s" "Starting `service_description`: "
1725++ ${LWSM} -q autostart
1726++ status=$?
1727++ if [ $status -eq 0 ]
1728++ then
1729++ echo_success
1730++ echo
1731++ else
1732++ echo_failure
1733++ echo
1734++ fi
1735++ ;;
1736++ SUSE)
1737++ printf "%s" "Starting `service_description`"
1738++ ${LWSM} -q autostart
1739++ status=$?
1740++ if [ $status -eq 0 ]
1741++ then
1742++ rc_reset
1743++ rc_status -v
1744++ else
1745++ rc_failed $status
1746++ rc_status -v
1747++ fi
1748++ ;;
1749++ DEBIAN)
1750++ log_daemon_msg "Starting `service_description`"
1751++ ${LWSM} -q autostart
1752++ status=$?
1753++ log_end_msg $status
1754++ ;;
1755++ HP-UX | SOLARIS | FREEBSD | ESXI | AIX)
1756++ printf "%s" "Starting `service_description`"
1757++ if [ -x /usr/sbin/svcadm ]; then
1758++ # Don't do anything!
1759++ status=0
1760++ else
1761++ ${LWSM} -q autostart
1762++ status=$?
1763++ fi
1764++
1765++ if [ $status -eq 0 ]
1766++ then
1767++ echo " ...ok"
1768++ else
1769++ echo " ...failed"
1770++ fi
1771++ ;;
1772++ UNKNOWN)
1773++ ${LWSM} -q autostart
1774++ status=$?
1775++ ;;
1776++ esac
1777++
1778++ return $status
1779++}
1780++
1781++service_restart()
1782++{
1783++ status=""
1784++
1785++ case "${PLATFORM}" in
1786++ REDHAT)
1787++ printf "%s" "Restarting `service_description` (not supported)"
1788++ status=0
1789++ echo_success
1790++ ;;
1791++ SUSE)
1792++ printf "%s" "Restarting `service_description` (not supported)"
1793++ status=0
1794++ rc_reset
1795++ rc_status -v
1796++ ;;
1797++ DEBIAN)
1798++ log_daemon_msg "Restarting `service_description` (not supported)"
1799++ status=0
1800++ log_end_msg $status
1801++ ;;
1802++ HP-UX | SOLARIS | FREEBSD | ESXI | AIX)
1803++ printf "%s" "Restarting `service_description` (not supported)"
1804++ status=0
1805++ echo " ...ok"
1806++ ;;
1807++ UNKNOWN)
1808++ status=0
1809++ ;;
1810++ esac
1811++
1812++ return $status
1813++}
1814++
1815++service_stop()
1816++{
1817++ status=""
1818++
1819++ case "${PLATFORM}" in
1820++ REDHAT)
1821++ printf "%s" "Stopping `service_description` (not supported) "
1822++ status=0
1823++ echo_success
1824++ ;;
1825++ SUSE)
1826++ printf "%s" "Stopping `service_description` (not supported)"
1827++ status=0
1828++ rc_reset
1829++ rc_status -v
1830++ ;;
1831++ DEBIAN)
1832++ log_daemon_msg "Stopping `service_description` (not supported)"
1833++ status=0
1834++ log_end_msg $status
1835++ ;;
1836++ AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
1837++ printf "%s" "Stopping `service_description` (not supported)"
1838++ status=0
1839++ echo " ...ok"
1840++ ;;
1841++ UNKNOWN)
1842++ status=0
1843++ ;;
1844++ esac
1845++
1846++ return $status
1847++}
1848++
1849++service_refresh()
1850++{
1851++ case "${PLATFORM}" in
1852++ REDHAT)
1853++ printf "%s" "Refreshing `service_description $1` configuration"
1854++ status=0
1855++ echo_success
1856++ ;;
1857++ SUSE)
1858++ printf "%s" "Refreshing `service_description $1` configuration"
1859++ status=0
1860++ rc_reset
1861++ rc_status -v
1862++ ;;
1863++ DEBIAN)
1864++ log_daemon_msg "Refreshing `service_description $1` configuration"
1865++ status=0
1866++ log_end_msg $status
1867++ ;;
1868++ AIX | HP-UX | SOLARIS | FREEBSD | ESXI)
1869++ printf "%s" "Refreshing `service_description $1` configuration"
1870++ status=0
1871++ echo " ...ok"
1872++ ;;
1873++ UNKNOWN)
1874++ status=0
1875++ ;;
1876++ esac
1877++
1878++ return $status
1879++}
1880++
1881++if [ -f /etc/rc.subr ]; then
1882++ . /etc/rc.subr
1883++fi
1884++
1885++case "$1" in
1886++ start|faststart|forcestart|onestart)
1887++ service_start "$SERVICE_NAME"
1888++ exit $?
1889++ ;;
1890++ stop|faststop|forcestop|onestop)
1891++ service_stop "$SERVICE_NAME"
1892++ exit $?
1893++ ;;
1894++ status|faststatus|forcestatus|onestop)
1895++ echo "not supported"
1896++ exit 0
1897++ ;;
1898++ restart|fastrestart|forcerestart|onerestart)
1899++ service_restart "$SERVICE_NAME"
1900++ exit $?
1901++ ;;
1902++ refresh|reload)
1903++ service_refresh "$SERVICE_NAME"
1904++ exit $?
1905++ ;;
1906++ start_msg)
1907++ echo "Starting `service_description`"
1908++ exit 0
1909++ ;;
1910++ stop_msg)
1911++ echo "Stopping `service_description` (not supported)"
1912++ exit 0
1913++ ;;
1914++ rcvar|fastrcvar|forcercvar|onercvar)
1915++ if type run_rc_command >/dev/null 2>&1; then
1916++ # Looks like this is a FreeBSD based system.
1917++ name=likewise
1918++ rcvar="`set_rcvar`"
1919++ start_cmd="service_start"
1920++ stop_cmd="service_stop"
1921++ eval "${name}_enable=YES"
1922++
1923++ load_rc_config "$name"
1924++ run_rc_command "$1" || exit $?
1925++ exit 0
1926++ fi
1927++ ;;
1928++ *)
1929++ echo "Unrecognized command: $1"
1930++ exit 1
1931++ ;;
1932++esac
1933+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/likewise likewise-open.new/git-build/config/likewise
1934+--- likewise-open/git-build/config/likewise 2011-09-09 11:04:54.000000000 -0700
1935++++ likewise-open.new/git-build/config/likewise 1969-12-31 16:00:00.000000000 -0800
1936+@@ -1,36 +0,0 @@
1937+-#! /bin/sh
1938+-# ex: set tabstop=4 expandtab shiftwidth=4:
1939+-#
1940+-# Copyright (c) Likewise Software. All rights reserved.
1941+-#
1942+-#LWI_STARTUP_TYPE_REDHAT###
1943+-#LWI_STARTUP_TYPE_REDHAT# chkconfig: 35 21 9
1944+-#LWI_STARTUP_TYPE_REDHAT# description: Start Likewise Open services
1945+-#LWI_STARTUP_TYPE_REDHAT###
1946+-#LWI_STARTUP_TYPE_REDHAT#
1947+-#LWI_STARTUP_TYPE_SUSE### BEGIN INIT INFO
1948+-#LWI_STARTUP_TYPE_SUSE# Provides: likewise
1949+-#LWI_STARTUP_TYPE_SUSE# Required-Start: $network $remote_fs lwsmd
1950+-#LWI_STARTUP_TYPE_SUSE# Required-Stop:
1951+-#LWI_STARTUP_TYPE_SUSE# Default-Start: 3 5
1952+-#LWI_STARTUP_TYPE_SUSE# Default-Stop:
1953+-#LWI_STARTUP_TYPE_SUSE# Description: Start Likewise Open services
1954+-#LWI_STARTUP_TYPE_SUSE### END INIT INFO
1955+-#LWI_STARTUP_TYPE_DEBIAN### BEGIN INIT INFO
1956+-#LWI_STARTUP_TYPE_DEBIAN# Provides: likewise
1957+-#LWI_STARTUP_TYPE_DEBIAN# Required-Start: $network $remote_fs $syslog lwsmd
1958+-#LWI_STARTUP_TYPE_DEBIAN# Required-Stop:
1959+-#LWI_STARTUP_TYPE_DEBIAN# X-Start-Before: cron
1960+-#LWI_STARTUP_TYPE_DEBIAN# X-Start-After:
1961+-#LWI_STARTUP_TYPE_DEBIAN# Default-Start: 2 3 4 5
1962+-#LWI_STARTUP_TYPE_DEBIAN# Default-Stop:
1963+-#LWI_STARTUP_TYPE_DEBIAN# Description: Start Likewise Open services
1964+-#LWI_STARTUP_TYPE_DEBIAN### END INIT INFO
1965+-#LWI_STARTUP_TYPE_FREEBSD# PROVIDE: likewise
1966+-#LWI_STARTUP_TYPE_FREEBSD# REQUIRE: NETWORKING lwsmd
1967+-#LWI_STARTUP_TYPE_FREEBSD# BEFORE: LOGIN
1968+-
1969+-PREFIX="PREFIX_DIR"
1970+-SERVICE_NAME="likewise"
1971+-
1972+-. EXECDIR/init-likewise.sh
1973+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/likewise.in likewise-open.new/git-build/config/likewise.in
1974+--- likewise-open/git-build/config/likewise.in 1969-12-31 16:00:00.000000000 -0800
1975++++ likewise-open.new/git-build/config/likewise.in 2011-09-09 14:25:19.000000000 -0700
1976+@@ -0,0 +1,36 @@
1977++#! /bin/sh
1978++# ex: set tabstop=4 expandtab shiftwidth=4:
1979++#
1980++# Copyright (c) Likewise Software. All rights reserved.
1981++#
1982++#LWI_STARTUP_TYPE_REDHAT###
1983++#LWI_STARTUP_TYPE_REDHAT# chkconfig: 35 21 9
1984++#LWI_STARTUP_TYPE_REDHAT# description: Start Likewise Open services
1985++#LWI_STARTUP_TYPE_REDHAT###
1986++#LWI_STARTUP_TYPE_REDHAT#
1987++#LWI_STARTUP_TYPE_SUSE### BEGIN INIT INFO
1988++#LWI_STARTUP_TYPE_SUSE# Provides: likewise
1989++#LWI_STARTUP_TYPE_SUSE# Required-Start: $network $remote_fs lwsmd
1990++#LWI_STARTUP_TYPE_SUSE# Required-Stop:
1991++#LWI_STARTUP_TYPE_SUSE# Default-Start: 3 5
1992++#LWI_STARTUP_TYPE_SUSE# Default-Stop:
1993++#LWI_STARTUP_TYPE_SUSE# Description: Start Likewise Open services
1994++#LWI_STARTUP_TYPE_SUSE### END INIT INFO
1995++#LWI_STARTUP_TYPE_DEBIAN### BEGIN INIT INFO
1996++#LWI_STARTUP_TYPE_DEBIAN# Provides: likewise
1997++#LWI_STARTUP_TYPE_DEBIAN# Required-Start: $network $remote_fs $syslog lwsmd
1998++#LWI_STARTUP_TYPE_DEBIAN# Required-Stop:
1999++#LWI_STARTUP_TYPE_DEBIAN# X-Start-Before: cron
2000++#LWI_STARTUP_TYPE_DEBIAN# X-Start-After:
2001++#LWI_STARTUP_TYPE_DEBIAN# Default-Start: 2 3 4 5
2002++#LWI_STARTUP_TYPE_DEBIAN# Default-Stop:
2003++#LWI_STARTUP_TYPE_DEBIAN# Description: Start Likewise Open services
2004++#LWI_STARTUP_TYPE_DEBIAN### END INIT INFO
2005++#LWI_STARTUP_TYPE_FREEBSD# PROVIDE: likewise
2006++#LWI_STARTUP_TYPE_FREEBSD# REQUIRE: NETWORKING lwsmd
2007++#LWI_STARTUP_TYPE_FREEBSD# BEFORE: LOGIN
2008++
2009++PREFIX="@MK_PREFIX@"
2010++SERVICE_NAME="likewise"
2011++
2012++. @MK_LIBEXECDIR@/init-likewise.sh
2013+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/lwsmd likewise-open.new/git-build/config/lwsmd
2014+--- likewise-open/git-build/config/lwsmd 2011-09-09 11:04:54.000000000 -0700
2015++++ likewise-open.new/git-build/config/lwsmd 1969-12-31 16:00:00.000000000 -0800
2016+@@ -1,67 +0,0 @@
2017+-#! /bin/sh
2018+-# ex: set tabstop=4 expandtab shiftwidth=4:
2019+-#
2020+-# Copyright (c) Likewise Software. All rights reserved.
2021+-#
2022+-#LWI_STARTUP_TYPE_REDHAT###
2023+-#LWI_STARTUP_TYPE_REDHAT# chkconfig: 35 17 9
2024+-#LWI_STARTUP_TYPE_REDHAT# description: Start and Stop Likewise Service Manager
2025+-#LWI_STARTUP_TYPE_REDHAT###
2026+-#LWI_STARTUP_TYPE_REDHAT#
2027+-#LWI_STARTUP_TYPE_SUSE### BEGIN INIT INFO
2028+-#LWI_STARTUP_TYPE_SUSE# Provides: lwsmd
2029+-#LWI_STARTUP_TYPE_SUSE# Required-Start: $network $syslog
2030+-#LWI_STARTUP_TYPE_SUSE# Required-Stop:
2031+-#LWI_STARTUP_TYPE_SUSE# Default-Start: 3 5
2032+-#LWI_STARTUP_TYPE_SUSE# Default-Stop: 0 1 2 6
2033+-#LWI_STARTUP_TYPE_SUSE# Description: Start and Stop Likewise Service Manager
2034+-#LWI_STARTUP_TYPE_SUSE### END INIT INFO
2035+-#LWI_STARTUP_TYPE_DEBIAN### BEGIN INIT INFO
2036+-#LWI_STARTUP_TYPE_DEBIAN# Provides: lwsmd
2037+-#LWI_STARTUP_TYPE_DEBIAN# Required-Start:
2038+-#LWI_STARTUP_TYPE_DEBIAN# Required-Stop:
2039+-#LWI_STARTUP_TYPE_DEBIAN# Default-Start: 2 3 4 5
2040+-#LWI_STARTUP_TYPE_DEBIAN# Default-Stop: 0 1 6
2041+-#LWI_STARTUP_TYPE_DEBIAN# Description: Start and Stop Likewise Service Manager
2042+-#LWI_STARTUP_TYPE_DEBIAN### END INIT INFO
2043+-#LWI_STARTUP_TYPE_FREEBSD# PROVIDE: lwsmd
2044+-#LWI_STARTUP_TYPE_FREEBSD# REQUIRE: NETWORKING
2045+-#LWI_STARTUP_TYPE_FREEBSD# BEFORE: LOGIN
2046+-
2047+-PROG_DESC="Likewise Service Manager"
2048+-PROG_BIN=PREFIX_DIR/sbin/lwsmd
2049+-PROG_ARGS="--start-as-daemon --syslog"
2050+-PIDFILE=
2051+-SCRIPTNAME="lwsmd"
2052+-STARTHOOK="fix_locale"
2053+-
2054+-lookup_user_locale()
2055+-{
2056+- . /etc/sysconfig/language
2057+- printf 'LANG=%q; export LANG\n' "$RC_LANG"
2058+- printf 'LC_ALL=%q; export LC_ALL\n' "$RC_LC_ALL"
2059+- printf 'LC_CTYPE=%q; export LC_CTYPE\n' "$RC_LC_CTYPE"
2060+-}
2061+-
2062+-fix_locale()
2063+-{
2064+- if [ "$LC_ALL" = "POSIX" ]
2065+- then
2066+- unset LC_ALL
2067+- export LC_ALL
2068+- fi
2069+- if type locale >/dev/null &&
2070+- locale | grep LC_CTYPE | grep POSIX >/dev/null; then
2071+- if [ -f /etc/sysconfig/language ]; then
2072+- eval "`lookup_user_locale`"
2073+- elif [ -f /etc/default/locale ]; then
2074+- . /etc/default/locale
2075+- export LANG
2076+- fi
2077+- elif [ -z "$LANG" ]; then
2078+- LANG="en_US.UTF-8"
2079+- export LANG
2080+- fi
2081+-}
2082+-
2083+-. EXECDIR/init-base.sh
2084+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/lwsmd.in likewise-open.new/git-build/config/lwsmd.in
2085+--- likewise-open/git-build/config/lwsmd.in 1969-12-31 16:00:00.000000000 -0800
2086++++ likewise-open.new/git-build/config/lwsmd.in 2011-09-09 14:25:44.000000000 -0700
2087+@@ -0,0 +1,67 @@
2088++#! /bin/sh
2089++# ex: set tabstop=4 expandtab shiftwidth=4:
2090++#
2091++# Copyright (c) Likewise Software. All rights reserved.
2092++#
2093++#LWI_STARTUP_TYPE_REDHAT###
2094++#LWI_STARTUP_TYPE_REDHAT# chkconfig: 35 17 9
2095++#LWI_STARTUP_TYPE_REDHAT# description: Start and Stop Likewise Service Manager
2096++#LWI_STARTUP_TYPE_REDHAT###
2097++#LWI_STARTUP_TYPE_REDHAT#
2098++#LWI_STARTUP_TYPE_SUSE### BEGIN INIT INFO
2099++#LWI_STARTUP_TYPE_SUSE# Provides: lwsmd
2100++#LWI_STARTUP_TYPE_SUSE# Required-Start: $network $syslog
2101++#LWI_STARTUP_TYPE_SUSE# Required-Stop:
2102++#LWI_STARTUP_TYPE_SUSE# Default-Start: 3 5
2103++#LWI_STARTUP_TYPE_SUSE# Default-Stop: 0 1 2 6
2104++#LWI_STARTUP_TYPE_SUSE# Description: Start and Stop Likewise Service Manager
2105++#LWI_STARTUP_TYPE_SUSE### END INIT INFO
2106++#LWI_STARTUP_TYPE_DEBIAN### BEGIN INIT INFO
2107++#LWI_STARTUP_TYPE_DEBIAN# Provides: lwsmd
2108++#LWI_STARTUP_TYPE_DEBIAN# Required-Start:
2109++#LWI_STARTUP_TYPE_DEBIAN# Required-Stop:
2110++#LWI_STARTUP_TYPE_DEBIAN# Default-Start: 2 3 4 5
2111++#LWI_STARTUP_TYPE_DEBIAN# Default-Stop: 0 1 6
2112++#LWI_STARTUP_TYPE_DEBIAN# Description: Start and Stop Likewise Service Manager
2113++#LWI_STARTUP_TYPE_DEBIAN### END INIT INFO
2114++#LWI_STARTUP_TYPE_FREEBSD# PROVIDE: lwsmd
2115++#LWI_STARTUP_TYPE_FREEBSD# REQUIRE: NETWORKING
2116++#LWI_STARTUP_TYPE_FREEBSD# BEFORE: LOGIN
2117++
2118++PROG_DESC="Likewise Service Manager"
2119++PROG_BIN=@MK_PREFIX@/sbin/lwsmd
2120++PROG_ARGS="--start-as-daemon --syslog"
2121++PIDFILE=
2122++SCRIPTNAME="lwsmd"
2123++STARTHOOK="fix_locale"
2124++
2125++lookup_user_locale()
2126++{
2127++ . /etc/sysconfig/language
2128++ printf 'LANG=%q; export LANG\n' "$RC_LANG"
2129++ printf 'LC_ALL=%q; export LC_ALL\n' "$RC_LC_ALL"
2130++ printf 'LC_CTYPE=%q; export LC_CTYPE\n' "$RC_LC_CTYPE"
2131++}
2132++
2133++fix_locale()
2134++{
2135++ if [ "$LC_ALL" = "POSIX" ]
2136++ then
2137++ unset LC_ALL
2138++ export LC_ALL
2139++ fi
2140++ if type locale >/dev/null &&
2141++ locale | grep LC_CTYPE | grep POSIX >/dev/null; then
2142++ if [ -f /etc/sysconfig/language ]; then
2143++ eval "`lookup_user_locale`"
2144++ elif [ -f /etc/default/locale ]; then
2145++ . /etc/default/locale
2146++ export LANG
2147++ fi
2148++ elif [ -z "$LANG" ]; then
2149++ LANG="en_US.UTF-8"
2150++ export LANG
2151++ fi
2152++}
2153++
2154++. @MK_LIBEXECDIR@/init-base.sh
2155+diff -Nurb '--exclude=.bzr' likewise-open/git-build/config/MakeKitBuild likewise-open.new/git-build/config/MakeKitBuild
2156+--- likewise-open/git-build/config/MakeKitBuild 2011-09-09 11:04:54.000000000 -0700
2157++++ likewise-open.new/git-build/config/MakeKitBuild 2011-09-12 11:03:00.000000000 -0700
2158+@@ -1,14 +1,27 @@
2159+ configure()
2160+ {
2161++ mk_declare -o \
2162++ MK_PREFIX \
2163++ MK_LIBEXECDIR \
2164++ MK_SBINDIR \
2165++ LW_INITDIR \
2166++ VERSION="$LW_VERSION" \
2167++ BUILD="${LW_BUILD_ID:-0}" \
2168++ REVISION="${LW_BUILD_REVISION:-0}"
2169++
2170+ mk_output_file VERSION
2171++ mk_output_file init-base.sh
2172++ mk_output_file init-likewise.sh
2173++ mk_output_file likewise
2174++ mk_output_file lwsmd
2175+ }
2176+
2177+ make()
2178+ {
2179+- for i in init-base.sh init-likewise.sh
2180+- do
2181+- lw_init_script_helper "$i"
2182+- done
2183++ mk_stage \
2184++ DESTDIR="${MK_LIBEXECDIR}" \
2185++ MODE=0755 \
2186++ init-base.sh init-likewise.sh
2187+
2188+ mk_stage \
2189+ SOURCE="krb5.conf.default" \
2190+@@ -26,58 +39,8 @@
2191+ DESTDIR="${MK_DATADIR}" \
2192+ SOURCE="likewise.pam-auth-update"
2193+
2194+- for i in lwsmd likewise
2195+- do
2196+- lw_init_script "$i"
2197+- done
2198+-}
2199+-
2200+-lw_init_script()
2201+-{
2202+- mk_target \
2203+- TARGET="${LW_INITDIR}/$1" \
2204+- DEPS="$1" \
2205+- _lw_install_init_script '$@' "&$1"
2206+-
2207+- mk_add_all_target "$result"
2208+-}
2209+-
2210+-_lw_install_init_script()
2211+-{
2212+- mk_msg_domain init
2213+-
2214+- mk_msg "${1#$MK_STAGE_DIR}"
2215+-
2216+- mk_mkdir "${1%/*}"
2217+-
2218+- mk_run_or_fail sed \
2219+- -e "s:PREFIX_DIR:${MK_PREFIX}:g" \
2220+- -e "s:EXECDIR:${MK_LIBEXECDIR}:g" \
2221+- < "$2" > "$1"
2222+- mk_run_or_fail chmod +x "$1"
2223+-}
2224+-
2225+-lw_init_script_helper()
2226+-{
2227+- mk_target \
2228+- TARGET="${MK_LIBEXECDIR}/$1" \
2229+- DEPS="$1" \
2230+- _lw_install_init_script_helper '$@' "&$1"
2231+-
2232+- mk_add_all_target "$result"
2233+-}
2234+-
2235+-_lw_install_init_script_helper()
2236+-{
2237+- mk_msg_domain init
2238+-
2239+- mk_msg "${1#$MK_STAGE_DIR}"
2240+-
2241+- mk_mkdir "${1%/*}"
2242+-
2243+- mk_run_or_fail sed \
2244+- -e "s:PREFIX_DIR:${MK_PREFIX}:g" \
2245+- -e "s:EXECDIR:${MK_LIBEXECDIR}:g" \
2246+- < "$2" > "$1"
2247+- mk_run_or_fail chmod +x "$1"
2248++ mk_stage \
2249++ DESTDIR="${LW_INITDIR}" \
2250++ MODE=0755 \
2251++ lwsmd likewise
2252+ }
2253
2254=== modified file 'debian/patches/series'
2255--- debian/patches/series 2011-09-06 22:10:33 +0000
2256+++ debian/patches/series 2011-09-28 19:20:30 +0000
2257@@ -13,3 +13,4 @@
2258 correct_lsass_configure_platform_detection.patch
2259 arm-platform.diff
2260 arm-dcerpc.diff
2261+config-fixes-for-verbose-make.patch

Subscribers

People subscribed via source and target branches

to all changes: