Re: patch to add FreeBSD support
On Sun, Feb 10, 2002 at 01:44:52AM +0100, Wichert Akkerman wrote:
> Previously utsl@quic.net wrote:
> > --- dpkg/utils/start-stop-daemon.c Fri Feb 1 23:28:13 2002
> > +++ dpkg-1.10-freebsd/utils/start-stop-daemon.c Fri Feb 8 04:36:55 2002
> > @@ -707,7 +709,9 @@
> >
> > /* WTA: this needs to be an autoconf check for /proc/pid existance.
> > */
> > -#if defined(OSLinux) || defined (OSsunos)
> > +
> > +/* WART: FreeBSD also has /proc support */
> > +#if defined(OSLinux) || defined (OSsunos) || defined(OSfreebsd)
>
> Removed the WART comment, that was already covered by the statement
> above that.
That was an inheritance from Wartan Hachaturow's patch, some months ago. It's
probably not important...
> > diff -urN dpkg/configure.in dpkg-1.10-freebsd/configure.in
> > --- dpkg/configure.in Sat Feb 2 17:58:58 2002
> > +++ dpkg-1.10-freebsd/configure.in Fri Feb 8 23:35:45 2002
> > @@ -93,7 +93,7 @@
> >
> > dpkg_archset=''
> > AC_MSG_CHECKING(Debian architecture)
> > -dpkg_archset="`awk '$1 == "'$target_cpu-$target_os'" { print $2 }' $srcdir/archtable`"
> > +dpkg_archset="`perl -ane 'if("'$target_cpu-$target_os'"=~m#^$F[0]$#) {print $F[1]; exit(0)}' archtable`"
> > # Finish off
> > if test "x$dpkg_archset" = "x"; then
> > AC_MSG_RESULT([$target_cpu-$target_os, but not found in archtable])
>
> Please don't use perl there, I want to get rid of all perl in dpkg.
Sorry, it was the first implementation that came to mind. I'll see if I can
remember how to use awk well enough to get it to do that. Is the basic concept
acceptable?
Reply to: