Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* SmbMount Compile Problem.
@ 1999-07-22 13:53 jimmyc
  1999-07-22 16:49 ` Wes Bauske
  0 siblings, 1 reply; 3+ messages in thread
From: jimmyc @ 1999-07-22 13:53 UTC (permalink / raw)
  To: axp-list

I am still having problems with smbmount.
When I compile it is says:

[root@what source]# make bin/smbmount
Compiling client/smbmount.c
client/smbmount.c: In function `close_our_files':
client/smbmount.c:242: `NR_OPEN' undeclared (first use in this function)

client/smbmount.c:242: (Each undeclared identifier is reported only once

client/smbmount.c:242: for each function it appears in.)
make: *** [client/smbmount.o] Error 1
[root@what source]#


What do I do??
Has anyone else has this problem.

btw: I am running redhat AlphaLinux 6.0 on a dec Multia

--
**************************************************************
The laws of physics do not apply to me
**************************************************************



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: SmbMount Compile Problem.
  1999-07-22 13:53 SmbMount Compile Problem jimmyc
@ 1999-07-22 16:49 ` Wes Bauske
  1999-07-22 17:31   ` jimmyc
  0 siblings, 1 reply; 3+ messages in thread
From: Wes Bauske @ 1999-07-22 16:49 UTC (permalink / raw)
  To: axp-list

jimmyc wrote:
> 
> I am still having problems with smbmount.
> When I compile it is says:
> 
> [root@what source]# make bin/smbmount
> Compiling client/smbmount.c
> client/smbmount.c: In function `close_our_files':
> client/smbmount.c:242: `NR_OPEN' undeclared (first use in this function)
> 
> client/smbmount.c:242: (Each undeclared identifier is reported only once
> 
> client/smbmount.c:242: for each function it appears in.)
> make: *** [client/smbmount.o] Error 1
> [root@what source]#
> 
> What do I do??
> Has anyone else has this problem.

It's mucked with in /usr/include/bits/local_lim.h.

The real value is in /usr/include/linux/limits.h:

#define NR_OPEN         1024


Don't know why the "bits" files are screwing with it.

When you have missing variables, you can check the source
tree for them with:

find the_dir_you_want_to_scan -print -exec grep string_to_find {} \;

This starts at the specified directory and greps for the string in
every file under that directory. Also, it's good to do the same
starting at /usr/include. It's the quickest way I know of to find
problems like that. Then all you have to do is figure out what flag
to turn on to get the defines you want. In this case, the bits file says:

/* The kernel header pollutes the namespace with the NR_OPEN symbol.
   Remove this after including the header if necessary.  */
#ifndef NR_OPEN
# define __undef_NR_OPEN
#endif

/* The kernel sources contain a file with all the needed information.  */
#include <linux/limits.h>

/* Have to remove NR_OPEN?  */
#ifdef __undef_NR_OPEN
# undef NR_OPEN
# undef __undef_NR_OPEN
#endif

Which I take to mean your average program shouldn't want to pick
up that define. Apparently, the loop in the code is attempting to
use the variable instead of actually keeping track of what files
are open and is blindly closing all possible file connections.
That starts to sound a bit flakey.

How to fix it? How about:

#if __alpha__
#define NR_OPEN   1024
#endif


Wes


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: SmbMount Compile Problem.
  1999-07-22 16:49 ` Wes Bauske
@ 1999-07-22 17:31   ` jimmyc
  0 siblings, 0 replies; 3+ messages in thread
From: jimmyc @ 1999-07-22 17:31 UTC (permalink / raw)
  To: axp-list

Thanks.
#if __alpha__
#define NR_OPEN   1024
#endif

Worked

Wes Bauske wrote:

> jimmyc wrote:
> >
> > I am still having problems with smbmount.
> > When I compile it is says:
> >
> > [root@what source]# make bin/smbmount
> > Compiling client/smbmount.c
> > client/smbmount.c: In function `close_our_files':
> > client/smbmount.c:242: `NR_OPEN' undeclared (first use in this function)
> >
> > client/smbmount.c:242: (Each undeclared identifier is reported only once
> >
> > client/smbmount.c:242: for each function it appears in.)
> > make: *** [client/smbmount.o] Error 1
> > [root@what source]#
> >
> > What do I do??
> > Has anyone else has this problem.
>
> It's mucked with in /usr/include/bits/local_lim.h.
>
> The real value is in /usr/include/linux/limits.h:
>
> #define NR_OPEN         1024
>
> Don't know why the "bits" files are screwing with it.
>
> When you have missing variables, you can check the source
> tree for them with:
>
> find the_dir_you_want_to_scan -print -exec grep string_to_find {} \;
>
> This starts at the specified directory and greps for the string in
> every file under that directory. Also, it's good to do the same
> starting at /usr/include. It's the quickest way I know of to find
> problems like that. Then all you have to do is figure out what flag
> to turn on to get the defines you want. In this case, the bits file says:
>
> /* The kernel header pollutes the namespace with the NR_OPEN symbol.
>    Remove this after including the header if necessary.  */
> #ifndef NR_OPEN
> # define __undef_NR_OPEN
> #endif
>
> /* The kernel sources contain a file with all the needed information.  */
> #include <linux/limits.h>
>
> /* Have to remove NR_OPEN?  */
> #ifdef __undef_NR_OPEN
> # undef NR_OPEN
> # undef __undef_NR_OPEN
> #endif
>
> Which I take to mean your average program shouldn't want to pick
> up that define. Apparently, the loop in the code is attempting to
> use the variable instead of actually keeping track of what files
> are open and is blindly closing all possible file connections.
> That starts to sound a bit flakey.
>
> How to fix it? How about:
>
> #if __alpha__
> #define NR_OPEN   1024
> #endif
>
> Wes
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

--
**************************************************************
The laws of physics do not apply to me
**************************************************************



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-07-22 17:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-07-22 13:53 SmbMount Compile Problem jimmyc
1999-07-22 16:49 ` Wes Bauske
1999-07-22 17:31   ` jimmyc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox