Re: Bering-uClibc build files for Wireguard VPN server (rerouted to leaf-user and leaf-devel)

John Sager <[email protected]> Fri, 24 Aug 2018 11:11:21 +0100
Newsgroups gmane.linux.leaf.devel
Message-ID <[email protected]>
Reading around the subject it seems that /dev/fd -> /proc/self/fd has been
around since at least Linux 2.6, and there should also be soft links for
/dev/stdin, /dev/stdout /dev/stderr:

ln -s /dev/self/fd/0 /dev/stdin
ln -s /dev/self/fd/1 /dev/stdout
ln -s /dev/self/fd/2 /dev/stderr

Perhaps these should also be added to the root.linuxrc script to avoid any
issues with code that depends on them.

John

On 23/08/18 22:41, John Sager wrote:
> Erich,
> 
> 
> On 23/08/18 21:31, Erich Titl wrote:
>> Hi John
> 
> ...
> 
>>  The change to root.linuxrc
>>> is to generate a link from /dev/fd to /proc/self/fd.
>>
>> Is proc/self/fd provided by the kernel module? Can this link be
>> generated by the startup script?
>>
> 
> /proc/self is a standard feature of the kernel and it is a soft link to
> /proc/<N> where N is the PID of this process. I guess most modern Linux
> distributions, and also *BSD apparently, have /dev/fd as a link to
> /proc/self/fd if bash assumes it will be there.
> 
> 
>>
>> I believe the easiest way would be to discuss this on leaf-devel and I
>> hope you can be tricked into integrating it yourself in the repository.
>> Should you not be susbscribed to leaf-devel then please do so. I am sure
>> KP would be very keen to welcome a new contributor.
> 
> I have just joined leaf-devel so I'll follow up on there.
> 
> 
> John
> 
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> 
> _______________________________________________
> leaf-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/leaf-devel
> 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot