+この新しい名前は全ての操作において古い名前と完全に同じように使用される; 両方の名前は同じファイルを参照しており (それで同じ許可
+(permission) や所有者 (ownership) となるので)、 どちらの名前が本来のものであるか判別できない。
+.SS linkat()
+\fBlinkat\fP() システムコールは \fBlink\fP() と全く同様に動作するが、以下で説明する点が異なる。
+
+\fIoldpath\fP で指定されたパス名が相対パスの場合、このパス名はファイルディスクリプター \fIolddirfd\fP
+が参照するディレクトリに対する相対パスと解釈される (\fBlink\fP(2)
+に相対パス名を渡した場合のように、呼び出したプロセスのカレントワーキングディレクトリに対する相対パスではない)。
+
+\fIoldpath\fP で指定されたパス名が相対パスで、 \fIolddirfd\fP が特別な値 \fBAT_FDCWD\fP の場合、 (\fBlink\fP(2)
+と同様に) \fIoldpath\fP は呼び出したプロセスのカレントワーキングディレクトリに対する相対パスと解釈される。
+
+\fIoldpath\fP で指定されたパス名が絶対パスの場合、 \fIolddirfd\fP は無視される。
+
+\fInewpath\fP の解釈は \fIoldpath\fP と同じである。 相対パスのパス名がファイルディスクリプター \fInewdirfd\fP
+が参照するディレクトリと解釈される点だけが異なる。
+
+以下の値のビット単位の論理和を \fIflags\fP に指定できる。
+.TP
+\fBAT_EMPTY_PATH\fP (Linux 2.6.39 以降)
+.\" commit 11a7b371b64ef39fc5fb1b6f2218eef7c4d035e3
+.\" Before glibc 2.16, defining _ATFILE_SOURCE sufficed
+If \fIoldpath\fP is an empty string, create a link to the file referenced by
+\fIolddirfd\fP (which may have been obtained using the \fBopen\fP(2) \fBO_PATH\fP
+flag). In this case, \fIolddirfd\fP can refer to any type of file, not just a
+directory. This will generally not work if the file has a link count of
+zero (files created with \fBO_TMPFILE\fP and without \fBO_EXCL\fP are an
+exception). The caller must have the \fBCAP_DAC_READ_SEARCH\fP capability in
+order to use this flag. This flag is Linux\-specific; define \fB_GNU_SOURCE\fP
+to obtain its definition.
+.TP
+\fBAT_SYMLINK_FOLLOW\fP (Linux 2.6.18 以降)
+By default, \fBlinkat\fP(), does not dereference \fIoldpath\fP if it is a symbolic
+link (like \fBlink\fP()). The flag \fBAT_SYMLINK_FOLLOW\fP can be specified in
+\fIflags\fP to cause \fIoldpath\fP to be dereferenced if it is a symbolic link.
+If procfs is mounted, this can be used as an alternative to
+\fBAT_EMPTY_PATH\fP, like this:
+
+.nf
+.in +4n
+linkat(AT_FDCWD, "/proc/self/fd/<fd>", newdirfd,
+ newname, AT_SYMLINK_FOLLOW);
+.in
+.fi
+.PP
+カーネル 2.6.18 より前では、 \fIflags\fP 引き数は未使用で、 0 を指定しなければならなかった。
+.PP
+\fBlinkat\fP() の必要性についての説明については \fBopenat\fP(2) を参照。