xfs
[Top] [All Lists]

Re: several messages

To: Rajagopal Ananthanarayanan <ananth@xxxxxxx>, Steve Lord <lord@xxxxxxx>
Subject: Re: several messages
From: Jim Bray <jb@xxxxxxxxx>
Date: Fri, 7 Apr 2000 20:56:33 -0400 (EDT)
Cc: linux-xfs@xxxxxxxxxxx
In-reply-to: <200004072159.QAA10643@xxxxxxxxxxxxxxxxxxxx>
Sender: owner-linux-xfs@xxxxxxxxxxx
On Fri, 7 Apr 2000, Rajagopal Ananthanarayanan wrote:

> 
> Hmm. kdb is open-sourced.

On Fri, 7 Apr 2000, Steve Lord wrote:

> According to this page kdb is GPL, the code does not seem to say
> that though.

  Right. The code just says:

 * Copyright (C) 1999 Silicon Graphics, Inc.
...
 * See the file LIA-COPYRIGHT for additional information.

  I think for it to be GPL, that has to be explicit in the code, as with
the xfs code:


* Copyright (c) 2000 Silicon Graphics, Inc.  All Rights Reserved.
 * 
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of version 2 of the GNU General Public License as
 * published by the Free Software Foundation.

  So it appears that kdb is still proprietary code.

On Fri, 7 Apr 2000, Rajagopal Ananthanarayanan wrote:

> 
> There is a bfd.h for download if you need it.

  Thanks. I'm more interested at present in getting SGI Linux to build on
my Debian/unstable system without tweakage.

On Fri, 7 Apr 2000, Steve Lord wrote:

> It looks like bdf.h comes from binutils, I am using binutils-2.9.5.0.22-6
> which does contain it.

 Ahh, the right clue. Should have done this earlier:
> 
> gilgamesh:~[1]dpkg -S bfd
...
binutils: /usr/lib/libbfd-2.9.5.0.31.so
...
but no bfd.h.

  The problem is that there is a binutils-dev, in the Extra section of
Debian, that I hadn't needed till now and didn't know about. Something is
broken with debian/unstable (happens less often than you'd think), so I
can't get the package at present, but it will almost certainly give me
bfd.h.

  Debian seems as a rule to separate out the .h files and so forth and put
them in a separate <package>-devel. You might want to note the need for
binutils-dev in appropriate READMEs, maybe in the configuration help for
CONFIG_KDB. I suspect most Debian users won't have binutils-devel
installed; some will figure it out on their own, and maybe others like me
will assume it is some SGI-specific .h file that for some reason didn't
make it into the tree.

  The case could be made that #including bfd.h is a bad idea unless it is
unavoidable. I don't know if this is a hard and fast rule, but I poked
thru the kernel code to confirm my impression that things generally only
#include <linux/ or asm/>, thus keeping the kernel source self-contained.
Looking thru kdbprivate.h, which is where <bfd.h> comes in, the only
obvious use of a bfd-thing is:

typedef struct _kdb_bp {
        bfd_vma         bp_addr;        /* Address breakpoint is present
at */
        kdb_machinst_t  bp_inst;        /* Replaced instruction */

  If bfd_vma turns out to be a fancy way to say char *, I'd toss it.
Doesn't look like it comes into play in the code much:
gilgamesh:/src/sgi/linux/kdb[1]grep bfd *.c
<sound of one hand clapping>

Jim     http://as220.org/jb


<Prev in Thread] Current Thread [Next in Thread>