public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* I need help with telldir and seekdir
@ 1998-10-27  6:15 ARNULFO RODRIGUEZ ZAMORA
  1998-10-29 11:20 ` tjoen
  0 siblings, 1 reply; 7+ messages in thread
From: ARNULFO RODRIGUEZ ZAMORA @ 1998-10-27  6:15 UTC (permalink / raw)
  To: gnu-win32

I'm trying to port code from unix to win32 with cygwin32.  Everything
worked right until a tried to compile a file wich included "dirent.h"
and tried to use seekdir and telldir.
    Can somebody tellme either  if  those functions are available in
other  header file, or  if i should implement them, and if that's the
case, how can i do it.

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
  1998-10-27  6:15 I need help with telldir and seekdir ARNULFO RODRIGUEZ ZAMORA
@ 1998-10-29 11:20 ` tjoen
  0 siblings, 0 replies; 7+ messages in thread
From: tjoen @ 1998-10-29 11:20 UTC (permalink / raw)
  To: gnu-win32

> Date:          Tue, 27 Oct 1998 08:12:44 -0600
> From:          ARNULFO RODRIGUEZ ZAMORA <e952508@anubis.ecci.ucr.ac.cr>

> Everything
> worked right until a tried to compile a file wich included "dirent.h"
> and tried to use seekdir and telldir.

grep or the windows findfiles util *.h files
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
@ 1998-10-30  5:08 Earnie Boyd
  0 siblings, 0 replies; 7+ messages in thread
From: Earnie Boyd @ 1998-10-30  5:08 UTC (permalink / raw)
  To: Dr. Volker Zell, e952508; +Cc: Cygnus

---"Dr. Volker Zell" <vzell@de.oracle.com> wrote:
>
> 
> Hi
> 
> >I'm trying to port code from unix to win32 with cygwin32.  Everything
> >worked right until a tried to compile a file wich included "dirent.h"
> >and tried to use seekdir and telldir.
> >    Can somebody tellme either  if  those functions are available in
> >other  header file, or  if i should implement them, and if that's the
> >case, how can i do it.
> 
> 
> I have the same question. I end up with the followin two erro45rs when
> trying to compile mc-4.5.0:
> 
> 
> gcc  -o mc dir.o util.o screen.o dialog.o key.o keyxdef.o menu.o
file.o win.o color.o help.o find.o profile.o user.o view.o ext.o
mouse.o setup.o dlg.o option.o tree.o widget.o chmod.o mad.o wtools.o
info.o cons.handler.o chown.o subshell.o terms.o boxes.o hotlist.o
achown.o layout.o fsusage.o mountlist.o regex.o complete.o slint.o
command.o cmd.o main.o panelize.o learn.o listmode.o utilunix.o
background.o rxvt.o popt.o text.o -L../vfs -L../slang -L../edit
-lvfs-mc  -ledit -L/src/mc-4.5.0/intl -lintl -lintl  -lcrypt -lslang
-lcurses
> ../vfs/libvfs-mc.a(local.o): In function `local_telldir':
> /src/mc-4.5.0/vfs/local.c:89: undefined reference to `telldir'
> ../vfs/libvfs-mc.a(local.o): In function `local_seekdir':
> /src/mc-4.5.0/vfs/local.c:94: undefined reference to `seekdir'
> collect2: ld returned 1 exit status
> make[1]: *** [mc] Error 1
> make: *** [all] Error 1
> 

What preprocessor conditions are around telldir and seekdir?  I know
that the header and functions are defined with mingw32.

==
-                  \\||//
-------------o0O0--Earnie--0O0o--------------
--          earnie_boyd@yahoo.com          --
-- http://www.freeyellow.com/members5/gw32 --
----------------ooo0O--O0ooo-----------------

PS: Newbie's, you should visit my page.
_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
  1998-10-28 11:32 Dr. Volker Zell
@ 1998-10-30  0:03 ` Mumit Khan
  0 siblings, 0 replies; 7+ messages in thread
From: Mumit Khan @ 1998-10-30  0:03 UTC (permalink / raw)
  To: Dr. Volker Zell; +Cc: e952508, Cygnus

"Dr. Volker Zell" <vzell@de.oracle.com> writes:
> 
> Hi
> 
> >I'm trying to port code from unix to win32 with cygwin32.  Everything
> >worked right until a tried to compile a file wich included "dirent.h"
> >and tried to use seekdir and telldir.
> >    Can somebody tellme either  if  those functions are available in
> >other  header file, or  if i should implement them, and if that's the
> >case, how can i do it.

seekdir and telldir are not part of POSIX (and obviously not part of the
ANSI C library), and any code using these (presumably expecting a BSD 4.3 
environment) is inherently non-portable to POSIX systems.

More often than not, the combination of telldir and seekdir is simply used 
as a replacement for rewinddir, which *is* POSIX and is part of cygwin. 

Older versions of mc (eg,. 4.1.35) didn't use these, so must be recent
addition, and I would assume quite easy to work around.

Regards,
Mumit

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
@ 1998-10-30  0:03 N8TM
  0 siblings, 0 replies; 7+ messages in thread
From: N8TM @ 1998-10-30  0:03 UTC (permalink / raw)
  To: vzell, e952508; +Cc: gnu-win32

In a message dated 10/29/98 3:02:49 PM Pacific Standard Time,
vzell@de.oracle.com writes:

> I'm trying to port code from unix to win32 with cygwin32.  Everything
>  >worked right until a tried to compile a file wich included "dirent.h"
>  >and tried to use seekdir and telldir.
>  >    Can somebody tellme either  if  those functions are available in
>  >other  header file, or  if i should implement them, and if that's the
>  >case, how can i do it.

from a source code which works for me:

#if ! defined (_WIN32) || defined (__CYGWIN32__)
#if defined(POSIX) || defined(CONCURRENT)
#include <dirent.h>
#else
#include <sys/dir.h>
#endif
#endif

so it looks to me like you're mis-configured.  There may be conflicting
consequences to your decision whether to set POSIX.
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
@ 1998-10-28 11:32 Dr. Volker Zell
  1998-10-30  0:03 ` Mumit Khan
  0 siblings, 1 reply; 7+ messages in thread
From: Dr. Volker Zell @ 1998-10-28 11:32 UTC (permalink / raw)
  To: e952508; +Cc: Cygnus

Hi

>I'm trying to port code from unix to win32 with cygwin32.  Everything
>worked right until a tried to compile a file wich included "dirent.h"
>and tried to use seekdir and telldir.
>    Can somebody tellme either  if  those functions are available in
>other  header file, or  if i should implement them, and if that's the
>case, how can i do it.


I have the same question. I end up with the followin two erro45rs when
trying to compile mc-4.5.0:


gcc  -o mc dir.o util.o screen.o dialog.o key.o keyxdef.o menu.o file.o win.o color.o help.o find.o profile.o user.o view.o ext.o mouse.o setup.o dlg.o option.o tree.o widget.o chmod.o mad.o wtools.o info.o cons.handler.o chown.o subshell.o terms.o boxes.o hotlist.o achown.o layout.o fsusage.o mountlist.o regex.o complete.o slint.o command.o cmd.o main.o panelize.o learn.o listmode.o utilunix.o background.o rxvt.o popt.o text.o -L../vfs -L../slang -L../edit -lvfs-mc  -ledit -L/src/mc-4.5.0/intl -lintl -lintl  -lcrypt -lslang -lcurses
../vfs/libvfs-mc.a(local.o): In function `local_telldir':
/src/mc-4.5.0/vfs/local.c:89: undefined reference to `telldir'
../vfs/libvfs-mc.a(local.o): In function `local_seekdir':
/src/mc-4.5.0/vfs/local.c:94: undefined reference to `seekdir'
collect2: ld returned 1 exit status
make[1]: *** [mc] Error 1
make: *** [all] Error 1


Ciao
  Volker


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

* Re: I need help with telldir and seekdir
@ 1998-10-28  4:06 Earnie Boyd
  0 siblings, 0 replies; 7+ messages in thread
From: Earnie Boyd @ 1998-10-28  4:06 UTC (permalink / raw)
  To: gnu-win32 @cygnus.com

---ARNULFO RODRIGUEZ ZAMORA <e952508@anubis.ecci.ucr.ac.cr> wrote:
>
> I'm trying to port code from unix to win32 with cygwin32.  Everything
> worked right until a tried to compile a file wich included "dirent.h"
> and tried to use seekdir and telldir.
>     Can somebody tellme either  if  those functions are available in
> other  header file, or  if i should implement them, and if that's the
> case, how can i do it.
> 

It sounds to me as if the code has _WIN32 specific coding in it
already.  If you want the UNIX version on WIN32 then I suggest that
you add these compile switches -U_WIN32 -UWINNT.  If you want the
_WIN32 coding you can either wait until version b20 is announced or
goto Mumit Khan's page and get the MINGW32 version of EGCS,
reconfigure (don't forget to remove config.cache) and build the
package as a native package.  URL's are listed on my webpage under
"List of links".

==
-                  \\||//
-------------o0O0--Earnie--0O0o--------------
--          earnie_boyd@yahoo.com          --
-- http://www.freeyellow.com/members5/gw32 --
----------------ooo0O--O0ooo-----------------

PS: Newbie's, you should visit my page.
_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

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

end of thread, other threads:[~1998-10-30  5:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-10-27  6:15 I need help with telldir and seekdir ARNULFO RODRIGUEZ ZAMORA
1998-10-29 11:20 ` tjoen
1998-10-28  4:06 Earnie Boyd
1998-10-28 11:32 Dr. Volker Zell
1998-10-30  0:03 ` Mumit Khan
1998-10-30  0:03 N8TM
1998-10-30  5:08 Earnie Boyd

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).