Subject: compilation error ?

From: Peter Evstatiev <[email-masked]>
Date: Mon, 08 Jun 1998 12:48:28 +0300

Hi all,
I don't know what to do whit my problem ?!
I'm trying to compile wu-ftpd 2.4.2 beta-17 ,but although that I moved H
files where have to  I got error while compilation with gcc version
2.7.2.3 on linux 2.0.33

what's I got is:

gcc -O6 -fomit-frame-pointer -fno-strength-reduce -pipe -I..
-I../support  -L../support -s   -c ftpd.c -o ftpd.o
ftpd.c: In function `statcmd':
ftpd.c:2737: `bytesize' undeclared (first use this function)
ftpd.c:2737: (Each undeclared identifier is reported only once
ftpd.c:2737: for each function it appears in.)
make: *** [ftpd.o] Error 1

Please If You can Help me , replay me ASAP

best regards
Peter Evstatiev

---

From: Gregory A Lundberg <[email-masked]>
Date: Mon, 8 Jun 1998 09:31:10 -0400 (EDT)

in src/config/config.lnx are the lines

#if LINUX_VERSION_CODE < 131104
#define NBBY 8

which could solve your problems but it's not taking effect.

In /usr/include/linux/version.h is
#define LINUX_VERSION_CODE 131102

Since I'm also running 2.0.33 (from RedHat 4.2 CD) I'd say your problem is
a bunged up /usr/include/linux .. maybe you should check your linux
installation?  Have you upgraded any of it by hand?

> Please If You can Help me , replay me ASAP

----

Gregory A Lundberg		Senior Partner, VRnet Company
1441 Elmdale Drive              [email-masked]
Kettering, OH 45409-1615 USA    1-800-809-2195

---

From: Peter Evstatiev <[email-masked]>
Date: Mon, 08 Jun 1998 17:08:48 +0300

> #if LINUX_VERSION_CODE < 131104

I have these lines but i have

> #define LINUX_VERSION_CODE 131102

this  , too ?!

 ftpd.c:2737: `bytesize' undeclared (first use this function)
    ... bytesize is one thing ,that I haven't nowhere in my computer :-)
  I simply haven't declaration of bytesize.I think that I can #define
bytesize 8,
 but who knows :-)

My installation of slackware 3.4 is full ,and I have full content of
directory /usr/include.. s.o.

I'll try to define this "bytesize" ,but I'm scare that it's meaning may be
other ...

regards
peter

---

From: Gregory A Lundberg <[email-masked]>
Date: Mon, 8 Jun 1998 10:12:56 -0400 (EDT)

> I'll try to define this "bytesize" ,but I'm scare that it's meaning may be

NBBY being defined _should_ bypass the reference to bytesize:

ftpd.c:2754 (approx., I've patched ftpd.c) says:
#ifdef NBBY
        lreply(0, "     TYPE: %s %d; STRUcture: %s; transfer MODE: %s",
               typenames[type], NBBY, strunames[stru], modenames[mode]);
#else
        lreply(0, "     TYPE: %s %d; STRUcture: %s; transfer MODE: %s",
               typenames[type], bytesize, strunames[stru],
modenames[mode]);
#endif /* NBBY */
    else
        lreply(0, "     TYPE: %s%s%s; STRUcture: %s; transfer MODE: %s",
               typenames[type], (type == TYPE_A || type == TYPE_E) ?
               ", FORM: " : "", (type == TYPE_A || type == TYPE_E) ?
               formnames[form] : "", strunames[stru], modenames[mode]);
    /*
    printf("     TYPE: %s", typenames[type]);
    if (type == TYPE_A || type == TYPE_E)
        printf(", FORM: %s", formnames[form]);
    if (type == TYPE_L)
#ifdef NBBY 
        printf(" %d", NBBY);
#else
        printf(" %d", bytesize);/ * need definition! * /
#endif

since these are the only two references to bytesize anywhere in the code
the NBBY definition should bypass them.

----