• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Generic creation of a symblic link
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Generic creation of a symblic link


  • Subject: Re: Generic creation of a symblic link
  • From: Jim Luther <email@hidden>
  • Date: Thu, 11 Oct 2012 17:30:13 -0700

symlink files are created in a single step by symlink(2). It's not a multi-step process in user-land code -- it's a single call into the kernel.

- Jim

On Oct 11, 2012, at 3:33 PM, James Bucanek <email@hidden> wrote:

> Greetings,
>
> I want to use the BSD API to create an empty symbolic link file and then write its contents. There's no obvious way of doing this with open(), as the object type flags in the mode parameter appear to be ignored.
>
> I would *assume* that the generic way of creating a symbolic link file would be to use a function like mknod() to create an arbitrary filesystem object (of type S_IFLNK), and then open() (using O_SYMLINK) the newly created symlink file and write its content.
>
> I tried to research this by finding out how the symbolic link creation function symlink() is implemented ... but I can't seem to find its source code. I've grep'd the entire Libc-825.25 folder from the latest Darwin release. I can see where other functions call it, but not where it's implemented.
>
> --
> James Bucanek
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Filesystem-dev mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Generic creation of a symblic link
      • From: James Bucanek <email@hidden>
References: 
 >Generic creation of a symblic link (From: James Bucanek <email@hidden>)

  • Prev by Date: Re: Generic creation of a symblic link
  • Next by Date: Re: Generic creation of a symblic link
  • Previous by thread: Re: Generic creation of a symblic link
  • Next by thread: Re: Generic creation of a symblic link
  • Index(es):
    • Date
    • Thread