Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ basename(3G) — svr4 — mips UMIPS RISC/os 5.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

dirname(3G)

basename(1)



BASENAME(3G-SVR4)   RISC/os Reference Manual    BASENAME(3G-SVR4)



NAME
     basename - return the last element of a path name

SYNOPSIS
     cc [flag ...] file ...  -lgen [library ...]

     #include <libgen.h>

     char *basename (char *path);

DESCRIPTION
     Given a pointer to a null-terminated character string that
     contains a path name, basename returns a pointer to the last
     element of path.  Trailing slashes (/) are deleted.

     If path or *path is zero, pointer to a static constant ``.''
     is returned.

EXAMPLES
          Input string   Output pointer
          _____________________________
          /usr/lib       lib
          /usr/          usr
          /              /

SEE ALSO
     dirname(3G).
     basename(1) in the User's Reference Manual.



























                        Printed 11/19/92                   Page 1



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026