Linux-Development-Sys Digest #235, Volume #8 Wed, 25 Oct 00 15:13:09 EDT
Contents:
Re: using /linuxrc (Josef Moellers)
Re: using /linuxrc (Josef Moellers)
Re: Microsoft Linux API? (Josef Moellers)
Re: init ramdisk vs. root ramdisk (Kasper Dupont)
DON'T GO HERE (PORN SITE) ("[EMAIL PROTECTED]")
Memory Allocation Problem ("Michael Schoettner")
msgrcv/msgsnd error ("Brad Taylor")
Re: ModSSL/Linux 6.1/Apache ("[EMAIL PROTECTED]")
OLICOM ISA/IV 2173 driver needed (Alexey Gimadiev)
Re: msgrcv/msgsnd error (James Moe)
Re: Memory Allocation Problem (James Moe)
Re: msgrcv/msgsnd error (ChromeDome)
Re: Memory Allocation Problem (John Reiser)
Re: Memory Allocation Problem ("Arthur H. Gold")
Re: using /linuxrc ([EMAIL PROTECTED])
Re: using /linuxrc ([EMAIL PROTECTED])
Re: porting from SCO to linux problems? ([EMAIL PROTECTED])
makefile (Mikael Chambon)
_findfirst, _findnext from win32? ("Igor Bobalo")
LinkUP and LinkDown ("Ron")
Re: ModSSL/Linux 6.1/Apache (Fabien Voland)
Re: _findfirst, _findnext from win32? (Lew Pitcher)
Re: ModSSL/Linux 6.1/Apache (Kaz Kylheku)
Re: _findfirst, _findnext from win32? (Kaz Kylheku)
Re: _findfirst, _findnext from win32? (Kaz Kylheku)
Question - make remote block dev look like local (Don Carroll)
Re: _findfirst, _findnext from win32? (Lew Pitcher)
----------------------------------------------------------------------------
From: Josef Moellers <[EMAIL PROTECTED]>
Subject: Re: using /linuxrc
Date: Wed, 25 Oct 2000 08:33:10 +0200
[EMAIL PROTECTED] wrote:
> The first line? What first line? Maybe you're referring to some actua=
l
> script that runs as /linux (which I am not aware of).
Oops, you're right, it seems that not all /linuxrc files are scripts.
SuSE7.0 has an ELF 32-bit LSB executable while
RedHat7.0 has a symbolic link to /sbin/init which is an ELF 32-bit LSB
executable.
Blast ... I know I have seen a shell script somewhere ...
> My intention is to have a C program compiled without any libraries be
> run as the /linuxrc program to do the things mentioned in my prior post=
=2E
Mee too mee too, I need to determine what the on-board SCSI hostadapter
is, in order to load the driver to handle it, presuming that the boot
disk is conected to it. Since it may very well be an aic7xxx based
adapter and the customer also has a sym53c8xx based PCI card and vice
versa, loading either driver first will fail in one setup or the other.
Hmm, this thread gives new hope.
-- =
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
------------------------------
From: Josef Moellers <[EMAIL PROTECTED]>
Subject: Re: using /linuxrc
Date: Wed, 25 Oct 2000 08:47:38 +0200
I hat to follow up on myself, but ...
Josef Moellers wrote:
> =
> [EMAIL PROTECTED] wrote:
> =
> > The first line? What first line? Maybe you're referring to some act=
ual
> > script that runs as /linux (which I am not aware of).
> =
> Oops, you're right, it seems that not all /linuxrc files are scripts.
> SuSE7.0 has an ELF 32-bit LSB executable while
> RedHat7.0 has a symbolic link to /sbin/init which is an ELF 32-bit LSB
> executable.
> =
> Blast ... I know I have seen a shell script somewhere ...
Yeppp, an installed RedHat7.0 has an initrd with /linuxrc being a shell
script:
#!/bin/sash
aliasall
echo "Loading sym53c8xx module"
insmod /lib/sym53c8xx.o
echo "Loading qla2x00 module"
insmod /lib/qla2x00.o
So, what I'd like to do is insert something like
case `bootcontroller` of
aic*) echo "loading aic7xxx module"; insmod /lib/aic7xxx.o;;
sym*) echo "loading sym53c8xx module"; insmod /lib/sym53c8xx.o;;
esac
-- =
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
------------------------------
From: Josef Moellers <[EMAIL PROTECTED]>
Subject: Re: Microsoft Linux API?
Date: Wed, 25 Oct 2000 09:07:21 +0200
"J.H.Delaney" wrote:
> =
> >
> > Pretty soon, Microsoft can use this dependency to
> > leverage control over the Linux marketplace.
> >
> =
> Will never happen. Sure, Microsoft 'ports' some apps to linux, but... I=
ts
> **BINARYS** they deliver, not source code. People that love linux, love=
it
> because they can modify anything they want. Cant do that with binarys.
I beg to differ, "People that love linux, love it because they can" find
out how things work, have trust in the tools (and the OS) they use and
fix bugs and make things better.
> > multiple operating systems, not just Linux. If apps start
> > coming to Linux so that it is of very high value and runs
> > specifially for Linux, THAT is the day when Windows will see
> > serious competition. However, if Microsoft was to become the
> =
> There already are application on linux that are of very high value. And=
most
> of the people that use linux dont really care about windows, so they wi=
ll
> not 'switch' to linux just cause windows has a cool new feauture.
But why do people continue using Windows? One reason, obviously is,
because Microsoft has spent millions to tell people that "Operating
System" =3D=3D "Windows" and Joe User buys a computer, Windows is already=
installed.
Why did I install Windows? Not for these reasons, I built my PC from
components, no pre-installed stuff there, but because there are many
games^H^H^H^H^Happlications that run only on Windows.
As soon as there are real-world applications (games, office apps) that
come close to their Windows counterparts, will more and more companies
offer pre-installed Linux on Desktops.
IMHO that is one of the most positive results of the anti-trust
investigation against Microsoft: Now more and more companies dare to say
"No" to Microsoft when they demand that applications and software
packages be built only for Windows.
In general, people don't buy Windows, they buy a tool, and if it happens
to run (only) on Windows, they buy Windows.
-- =
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
------------------------------
From: Kasper Dupont <[EMAIL PROTECTED]>
Subject: Re: init ramdisk vs. root ramdisk
Date: Wed, 25 Oct 2000 11:43:57 +0200
[EMAIL PROTECTED] wrote:
[...]
> An issue I am running into is which ramdisk to use. I cannot
> use /dev/ram0 (1,0) because initrd uses that one, and it is
> already mounted. Overwriting it would have nasty consequences.
>
> So I will use a 2nd ramdisk. Now the issue is which one. Should
> I use /dev/ram1? Maybe programs on a running system expect to
> take the next ramdisk past one that might be used by initrd. Or
> should I use /dev/ram15? Similarly, programs might grab ramdisks
> from the top down. I'd really prefer to let whoever uses this
[...]
Just use the ramdisks you prefer.
Programs does not grab ramdisks
like you suggest, they store data
in files.
/KD
------------------------------
From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
Subject: DON'T GO HERE (PORN SITE)
Date: Wed, 25 Oct 2000 13:40:10 +0200
DON'T GO HERE (PORN SITE)
[EMAIL PROTECTED] wrote:
>
> http://tracyspalace.tripod.com
------------------------------
From: "Michael Schoettner" <[EMAIL PROTECTED]>
Subject: Memory Allocation Problem
Date: Wed, 25 Oct 2000 14:37:59 +0200
Hi all,
I want to allocate a virtual memory block and I want to suggest a starting
address (like VirtualAlloc in MS-Windows). Does anybody know the proper
system call? A short e-mail would be great.
Many thanks in advance,
Michael
==================================================================
Michael Schoettner
University of Ulm
Department of Distributed Systems
E-Mail: [EMAIL PROTECTED]
Web: http://www-vs.informatik.uni-ulm.de/Mitarbeiter/Schoettner/
==================================================================
------------------------------
From: "Brad Taylor" <[EMAIL PROTECTED]>
Subject: msgrcv/msgsnd error
Date: Wed, 25 Oct 2000 08:57:11 -0500
I have three processes which communicate via msgsnd/msgrcv.
P1 - msgsnd with id=1
P2 - msgrcv with id=1...(work)...msgsnd with id=2
P3 - msgrcv with id=2
When I first bring up my apps the message flows correctly, as described
above. Upon subsequent sends when P1 does the send, immediately P3 wakes up
with a message. Following is a copy of what I dump in debug mode: In this
case P1 = 398 & P3 = 399.
08:05:26 (398) debug - about to write message q=129, len=372, id=1
08:05:26 (398) debug - 0000 01000000 00000000 07601A80 544F5343
(399) receive_message post, Msgq=129, Rc=372, Id=2
08:05:26 (399) debug - 0000 02000000 00000000 07601A80 544F5343
When I do a ps -l I get: in this case P2=401
100140 0 399 398 0 0 860 380 quota_on S p1 0:00
./scserve
100100 0 401 179 0 0 852 352 quota_on S p0 0:00
./scagent
is this quota on state have anything to do with my problem?
------------------------------
From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
Subject: Re: ModSSL/Linux 6.1/Apache
Date: Wed, 25 Oct 2000 16:05:05 +0200
Hi,
It is best to compile from source,
go to the modssl site.
the source you need is
-Apache (the version specified)
-ModSSL
-OpenSSL
Thanks,
Richard.
PS Please don't call Linux : Linux 6.1 , that's redhat.
Fabien Voland wrote:
>
> Hi!
>
> I have installed the ModSSL package RPM.
>
> Now, when I start Apache httpd, I have a error message : undefined
> symbol:ap_global_ctx.
>
> In FAQ of ModSSL, it writes : I must installed a patch for Apache
> EAPI. In the site ModSSL, I find a patch but not for Apache/Linux but
> only for Apache.
>
> Can you help me for find the patch EAPI for Apache ?
>
> Thanks.
>
> Fabien
> ----------------------------------------------------
> From Anywhere
> ----------------------------------------------------
------------------------------
From: Alexey Gimadiev <[EMAIL PROTECTED]>
Crossposted-To:
comp.os.linux.hardware,comp.os.linux.setup,comp.os.linux.development,comp.os.linux.help,comp.os.linux.misc,comp.os.linux.networking,comp.os.linux.questions
Subject: OLICOM ISA/IV 2173 driver needed
Date: 25 Oct 2000 14:05:12 GMT
Hi All!
I need OLICOM ISA/IV 2173 driver for linux, can somebody help me?
Thanks
Alex
------------------------------
From: James Moe <[EMAIL PROTECTED]>
Subject: Re: msgrcv/msgsnd error
Date: Wed, 25 Oct 2000 15:28:53 GMT
Brad Taylor wrote:
>
> I have three processes which communicate via msgsnd/msgrcv.
> P1 - msgsnd with id=1
> P2 - msgrcv with id=1...(work)...msgsnd with id=2
> P3 - msgrcv with id=2
>
> When I first bring up my apps the message flows correctly, as described
> above. Upon subsequent sends when P1 does the send, immediately P3 wakes up
> with a message. Following is a copy of what I dump in debug mode: In this
> case P1 = 398 & P3 = 399.
>
You haven't given us much to work with here.
If P2 and P3 are blocked on msgrcv() with mtype = 0, ie, receive
anything, it is somewhat random which process will wake up first and
grab a message. It becomes a function of the scheduler.
To assure correct reception, assign a specific mtype for each
process to receive.
--
sma at rtd dot com
------------------------------
From: James Moe <[EMAIL PROTECTED]>
Subject: Re: Memory Allocation Problem
Date: Wed, 25 Oct 2000 15:29:59 GMT
Michael Schoettner wrote:
>
> Hi all,
>
> I want to allocate a virtual memory block and I want to suggest a starting
> address (like VirtualAlloc in MS-Windows). Does anybody know the proper
> system call? A short e-mail would be great.
>
What do you mean by "virtual memory"?
--
sma at rtd dot com
------------------------------
From: ChromeDome <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: Re: msgrcv/msgsnd error
Date: Wed, 25 Oct 2000 16:25:16 GMT
Brad Taylor wrote:
>
> I have three processes which communicate via msgsnd/msgrcv.
> P1 - msgsnd with id=1
> P2 - msgrcv with id=1...(work)...msgsnd with id=2
> P3 - msgrcv with id=2
>
> When I first bring up my apps the message flows correctly, as described
> above. Upon subsequent sends when P1 does the send, immediately P3 wakes up
If P3 is really only reading message type 2 and P1 is really only
sending message type 1, then your error has to be in the debug print
from P2. It has to be running :-).
I'm not familiar with the "quota_on" state, but could it have to do with
printing?
Gene
--
ChromeDome
"Anyone who wants to be elected shouldn't be" - Will Rogers
------------------------------
From: John Reiser <[EMAIL PROTECTED]>
Subject: Re: Memory Allocation Problem
Date: Wed, 25 Oct 2000 09:59:56 -0700
> I want to allocate a virtual memory block and I want to suggest a starting
> address (like VirtualAlloc in MS-Windows).
Call mmap(), specify a page-aligned address, remember to specify
MAP_FIXED and MAP_PRIVATE and MAP_ANONYMOUS, and check the
return value for success. See <bits/mman.h>.
--
John Reiser, [EMAIL PROTECTED]
------------------------------
Date: Wed, 25 Oct 2000 12:10:11 -0500
From: "Arthur H. Gold" <[EMAIL PROTECTED]>
Subject: Re: Memory Allocation Problem
John Reiser wrote:
>
> > I want to allocate a virtual memory block and I want to suggest a starting
> > address (like VirtualAlloc in MS-Windows).
>
> Call mmap(), specify a page-aligned address, remember to specify
> MAP_FIXED and MAP_PRIVATE and MAP_ANONYMOUS, and check the
> return value for success. See <bits/mman.h>.
>
> --
> John Reiser, [EMAIL PROTECTED]
But be careful; ISTR that a MAP_FIXED mmap call will happily
comply, even if the address you specify is already part of
your address space (IOW, you can overwrite--or actually zero
out--your code and/or/data).
HTH,
--ag
--
Artie Gold, Austin, TX (finger the cs.utexas.edu account
for more info)
mailto:[EMAIL PROTECTED] or mailto:[EMAIL PROTECTED]
--
"I'd sooner fly another combat mission than ride the Cyclone
again" -- Joseph Heller
------------------------------
From: [EMAIL PROTECTED]
Subject: Re: using /linuxrc
Date: Wed, 25 Oct 2000 17:32:32 -0000
On Wed, 25 Oct 2000 08:33:10 +0200 Josef Moellers <[EMAIL PROTECTED]>
wrote:
| Mee too mee too, I need to determine what the on-board SCSI hostadapter
| is, in order to load the driver to handle it, presuming that the boot
| disk is conected to it. Since it may very well be an aic7xxx based
| adapter and the customer also has a sym53c8xx based PCI card and vice
| versa, loading either driver first will fail in one setup or the other.
If the set of driver choices is finite, you could in theory compile them
into the kernel. But I'm assuming you have some reason to use modules,
such as a vast range of SCSI possibilities. You're /linuxrc will have to
do the probing, I assume.
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED]
Subject: Re: using /linuxrc
Date: Wed, 25 Oct 2000 17:37:00 -0000
On Wed, 25 Oct 2000 08:47:38 +0200 Josef Moellers <[EMAIL PROTECTED]>
wrote:
| Yeppp, an installed RedHat7.0 has an initrd with /linuxrc being a shell
| script:
|
| #!/bin/sash
|
| aliasall
|
| echo "Loading sym53c8xx module"
| insmod /lib/sym53c8xx.o
| echo "Loading qla2x00 module"
| insmod /lib/qla2x00.o
|
| So, what I'd like to do is insert something like
| case `bootcontroller` of
| aic*) echo "loading aic7xxx module"; insmod /lib/aic7xxx.o;;
| sym*) echo "loading sym53c8xx module"; insmod /lib/sym53c8xx.o;;
| esac
I guess the probing process is complex enough that they only do so at
install time because of the problems it could encounter, such as the
time it takes, etc.
What is this "bootcontroller" program? Your prober?
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED]
Crossposted-To: comp.os.linux.development.apps
Subject: Re: porting from SCO to linux problems?
Date: Wed, 25 Oct 2000 17:42:16 -0000
In comp.os.linux.development.system Martin Collins <[EMAIL PROTECTED]> wrote:
| I've gotten the job of porting a set of programs and
| a daemon from SCO Opendesktop to Caldera linux.
| Some of the software is in ansi C and the rest in C++.
| There is no X interface. Sockets are used however.
|
| Does anybody have any experience in this line and can
| point out possible sources of difficulty. I'm supposed to
| estimate the effort invloved.
Your porting target should not be to a specific distribution. Even better
would be to port "to UNIX". The actual time involved is probably going
to be more a function of how well, or how poorly, the original set of
programs were written, than of the differences between SCO and Linux.
I've seen programs ported the other way with no problem, but then, the
programs in question were written under a team leader I know that has
experience in multiple UNIX platform development.
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: Mikael Chambon <[EMAIL PROTECTED]>
Subject: makefile
Date: Wed, 25 Oct 2000 12:44:17 -0500
Hello,
I have a Makefile that procude a shared library, on linux we have to use
-shared and
under solaris we have to use -G, because of that i Have two Makefile.
Can someone tell how to make only one Makefile.
I mean, i thing that I should use a conditionnal statement that look the
architecture, but
how to do this ??
Thx for all.
Mikael Chambon
------------------------------
From: "Igor Bobalo" <[EMAIL PROTECTED]>
Subject: _findfirst, _findnext from win32?
Date: Wed, 25 Oct 2000 19:18:37 -0000
Hi.
I'm porting some system routlines from win32 platform to linux. Is there are
some replacement for _findfirst, _findnext function? If not - how to solve
the problem?
--
Sincerely yours
Igor Bobalo.
=======================
[EMAIL PROTECTED]
------------------------------
From: "Ron" <[EMAIL PROTECTED]>
Subject: LinkUP and LinkDown
Date: Wed, 25 Oct 2000 14:18:05 -0400
There has to be a way to find out if an interface has changed its state
without going to the proc fs. I am looking at the /etc/rc.d/init.d/network
utility. It gives this information. When I edit this file, it appears like
the information is stored in the $DEV_UP and #DEV_RECONF variables. I don't
know how to access them.
Any help would be appreciated.
ROn
------------------------------
From: [EMAIL PROTECTED] (Fabien Voland)
Subject: Re: ModSSL/Linux 6.1/Apache
Date: Wed, 25 Oct 2000 18:34:54 GMT
Hi, thanks for your answer.
En date du Wed, 25 Oct 2000 16:05:05 +0200, de
"[EMAIL PROTECTED]" <[EMAIL PROTECTED]>, a �crit:
>Hi,
>
>It is best to compile from source,
Can you tell me why ? (I'm novice in Redhat 6.1).
Thanks.
Fabien
>go to the modssl site.
>the source you need is
>-Apache (the version specified)
>-ModSSL
>-OpenSSL
>
>Thanks,
>Richard.
>
>PS Please don't call Linux : Linux 6.1 , that's redhat.
>
>Fabien Voland wrote:
>>
>> Hi!
>>
>> I have installed the ModSSL package RPM.
>>
>> Now, when I start Apache httpd, I have a error message : undefined
>> symbol:ap_global_ctx.
>>
>> In FAQ of ModSSL, it writes : I must installed a patch for Apache
>> EAPI. In the site ModSSL, I find a patch but not for Apache/Linux but
>> only for Apache.
>>
>> Can you help me for find the patch EAPI for Apache ?
>>
>> Thanks.
>>
>> Fabien
>> ----------------------------------------------------
>> From Anywhere
>> ----------------------------------------------------
====================================================
>From Anywhere
====================================================
------------------------------
From: [EMAIL PROTECTED] (Lew Pitcher)
Subject: Re: _findfirst, _findnext from win32?
Reply-To: [EMAIL PROTECTED]
Date: Wed, 25 Oct 2000 18:43:38 GMT
On Wed, 25 Oct 2000 19:18:37 -0000, "Igor Bobalo"
<[EMAIL PROTECTED]> wrote:
>Hi.
>
>I'm porting some system routlines from win32 platform to linux. Is there are
>some replacement for _findfirst, _findnext function?
Not directly. opendir(), readdir() and family are the directory
functions (one flavour at least), but they don't support globing.
>If not - how to solve the problem?
What problem (<g>)?? Seriously, not having findfirst()/findnext()
hasn't caused any problem on Unix/Linux.
You might try the regexp package in combination with readdir()
function to emulate findfirst()/findnext(). However, it would probably
be better if you re-examine the assumptions behind and design of your
program in the light of the different facilities of Linux. Likely,
you'll find that you don't really need findfirst()/findnext().
Lew Pitcher
Information Technology Consultant
Toronto Dominion Bank Financial Group
([EMAIL PROTECTED])
(Opinions expressed are my own, not my employer's.)
------------------------------
From: [EMAIL PROTECTED] (Kaz Kylheku)
Subject: Re: ModSSL/Linux 6.1/Apache
Reply-To: [EMAIL PROTECTED]
Date: Wed, 25 Oct 2000 18:39:35 GMT
On Wed, 25 Oct 2000 18:34:54 GMT, Fabien Voland <[EMAIL PROTECTED]> wrote:
>Hi, thanks for your answer.
>
>En date du Wed, 25 Oct 2000 16:05:05 +0200, de
>"[EMAIL PROTECTED]" <[EMAIL PROTECTED]>, a �crit:
>
>>Hi,
>>
>>It is best to compile from source,
>
>Can you tell me why ? (I'm novice in Redhat 6.1).
Because if you compile the source code, then the resulting executable will be
perfectly matched to the versions of libraries you have on your system. People
who compile their own binaries are strangers to shared library versioning
headaches.
------------------------------
From: [EMAIL PROTECTED] (Kaz Kylheku)
Subject: Re: _findfirst, _findnext from win32?
Reply-To: [EMAIL PROTECTED]
Date: Wed, 25 Oct 2000 18:42:47 GMT
On Wed, 25 Oct 2000 19:18:37 -0000, Igor Bobalo <[EMAIL PROTECTED]> wrote:
>Hi.
>
>I'm porting some system routlines from win32 platform to linux. Is there are
>some replacement for _findfirst, _findnext function? If not - how to solve
>the problem?
You can snarf large chunks of the directory using the POSIX.1 getdents() (get
directory entries) function.
Also take a look at the POSIX.2 glob() function if you need to get a list of
path names that match a given shell regular expression pattern.
--
Any hyperlinks appearing in this article were inserted by the unscrupulous
operators of a Usenet-to-web gateway, without obtaining the proper permission
of the author, who does not endorse any of the linked-to products or services.
------------------------------
From: [EMAIL PROTECTED] (Kaz Kylheku)
Subject: Re: _findfirst, _findnext from win32?
Reply-To: [EMAIL PROTECTED]
Date: Wed, 25 Oct 2000 18:46:02 GMT
On Wed, 25 Oct 2000 18:43:38 GMT, Lew Pitcher <[EMAIL PROTECTED]> wrote:
>On Wed, 25 Oct 2000 19:18:37 -0000, "Igor Bobalo"
><[EMAIL PROTECTED]> wrote:
>
>>Hi.
>>
>>I'm porting some system routlines from win32 platform to linux. Is there are
>>some replacement for _findfirst, _findnext function?
>Not directly. opendir(), readdir() and family are the directory
>functions (one flavour at least), but they don't support globing.
Note that readdir() returns a pointer to static storage, so it is not thread
safe. I recommend readdir_r() or getdents() in code that may need to be thread
safe in the future.
------------------------------
From: Don Carroll <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: Question - make remote block dev look like local
Date: Wed, 25 Oct 2000 18:36:22 GMT
Is there a way to make remote block dev look like local dev
make a Linux Appliance with a cdrom or dvd drive and make it accessable
with /dev/cdrom on another Linux system
i.e. small linux device in stereo rack networked to Linux server in
computer closet
------------------------------
From: [EMAIL PROTECTED] (Lew Pitcher)
Subject: Re: _findfirst, _findnext from win32?
Reply-To: [EMAIL PROTECTED]
Date: Wed, 25 Oct 2000 19:07:21 GMT
On Wed, 25 Oct 2000 18:46:02 GMT, [EMAIL PROTECTED] (Kaz
Kylheku) wrote:
>On Wed, 25 Oct 2000 18:43:38 GMT, Lew Pitcher <[EMAIL PROTECTED]> wrote:
>>On Wed, 25 Oct 2000 19:18:37 -0000, "Igor Bobalo"
>><[EMAIL PROTECTED]> wrote:
>>
>>>Hi.
>>>
>>>I'm porting some system routlines from win32 platform to linux. Is there are
>>>some replacement for _findfirst, _findnext function?
>>Not directly. opendir(), readdir() and family are the directory
>>functions (one flavour at least), but they don't support globing.
>
>Note that readdir() returns a pointer to static storage, so it is not thread
>safe. I recommend readdir_r() or getdents() in code that may need to be thread
>safe in the future.
I qualified readdir() as "one flavour of directory functions" because
I didn't have my references handy, and am in a CYA mode today <g>.
I'm pleased to learn that my memory isn't completely faulty, as I
would have hoped that you would correct me if I had misstated things.
I still maintain that, if a porting exercise becomes a task of
rewriting the environment from which the program is derived (i.e.
building a findfirst() equivalent), then there's something
questionable with the design or implementation of the program being
ported. Rather than "look for the equivalent" of a platform-specific
API, porting should "look for how" other implementations on the
platform usually solve the problem.
For instance, because MSDOS derivatives do not glob in the shell,
MSDOS programs have taken on the effort of performing the globbing
within their own code (i.e. TYPE *.TXT would result in TYPE.EXE
invoking the findfirst()/findnext() API). On Linux (as in Unix),
filename globbing is (typically) performed at the shell, and is
(usually) unnecessary within the program (i.e. cat *.txt would result
in the shell globbing *.txt into a list of filenames into the
commandstring before the program is executed, and 'cat' just looks
through a list of completed filenames). If someone were to port an
MSDOS program that used findfirst()/findnext() in this manner, then
the effort of emulating findfirst()/findnext() in Linux would be of
minimal benefit (I'd say no benefit at all) to the program.
Lew Pitcher
Information Technology Consultant
Toronto Dominion Bank Financial Group
([EMAIL PROTECTED])
(Opinions expressed are my own, not my employer's.)
------------------------------
** FOR YOUR REFERENCE **
The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:
Internet: [EMAIL PROTECTED]
You can send mail to the entire list (and comp.os.linux.development.system) via:
Internet: [EMAIL PROTECTED]
Linux may be obtained via one of these FTP sites:
ftp.funet.fi pub/Linux
tsx-11.mit.edu pub/linux
sunsite.unc.edu pub/Linux
End of Linux-Development-System Digest
******************************