Annotation of coherent/b/lib/libc/stdio/Makefile, revision 1.1.1.1

1.1       root        1: # /usr/src/libc/stdio/Makefile 1/26/93
                      2: 
                      3: # The order of stdio objects in libc.a is significant and a bit complicated.
                      4: # To reduce the size of linked objects when possible,
                      5: # libc includes both real and fake versions of _dtefg() (floating point output)
                      6: # and of _finish() (close open FILEs).
                      7: # If a program requires floating point output, the "-f" flag to /bin/cc
                      8: # produces an "-u _dtefg_" argument to /bin/ld, forcing the link to include
                      9: # the real floating point output routine from _dtefg.o.
                     10: # Otherwise, /bin/ld resolves the reference to _dtefg() in vfprintf.o with
                     11: # the much smaller fake floating point output routine from _fdtefg.o.
                     12: # To avoid linking in extra stdio overhead when not required,
                     13: # libc.a should contain _fp.o, _finit.o, exit.o and _finish.o, in that order,
                     14: # after stdio objects from $(OBJ) and from the machine-dependent subdirectory,
                     15: # If a program uses stdio, /bin/ld will link in _finit.o;
                     16: # finit.o defines the real _finish() which closes all open files for exit().
                     17: # If a program does not use stdio, /bin/ld will link in exit.o but not _finit.o;
                     18: # then it resolves the _finish() reference in exit() with the fake _finish.o,
                     19: # which does nothing.
                     20: 
                     21: OBJ=\
                     22:        _dscan.o\
                     23:        _fgetb.o\
                     24:        _fgetc.o\
                     25:        _fgete.o\
                     26:        _fgetstr.o\
                     27:        _filbuf.o\
                     28:        _flsbuf.o\
                     29:        _fopen.o\
                     30:        _fpseek.o\
                     31:        _fputa.o\
                     32:        _fputb.o\
                     33:        _fputc.o\
                     34:        _fpute.o\
                     35:        _fputt.o\
                     36:        _scanf.o\
                     37:        _stropen.o\
                     38:        clearerr.o\
                     39:        ecvt.o\
                     40:        fclose.o\
                     41:        fcvt.o\
                     42:        fdopen.o\
                     43:        feof.o\
                     44:        ferror.o\
                     45:        fflush.o\
                     46:        fgetc.o\
                     47:        fgetpos.o\
                     48:        fgets.o\
                     49:        fopen.o\
                     50:        fputc.o\
                     51:        fputs.o\
                     52:        fread.o\
                     53:        freopen.o\
                     54:        fscanf.o\
                     55:        fseek.o\
                     56:        fsetpos.o\
                     57:        ftell.o\
                     58:        fwrite.o\
                     59:        gcvt.o\
                     60:        getc.o\
                     61:        getchar.o\
                     62:        gets.o\
                     63:        perror.o\
                     64:        popen.o\
                     65:        putc.o\
                     66:        putchar.o\
                     67:        puts.o\
                     68:        remove.o\
                     69:        rename.o\
                     70:        rewind.o\
                     71:        scanf.o\
                     72:        setbuf.o\
                     73:        setvbuf.o\
                     74:        sscanf.o\
                     75:        tmpfile.o\
                     76:        tmpnam.o\
                     77:        ungetc.o
                     78: 
                     79: # N.B. The order of objects in $(OBJ2) is significant,
                     80: # see the lengthy comment above and be extremely careful if you change it.
                     81: OBJ2=\
                     82:        _dtefg.o\
                     83:        fprintf.o\
                     84:        printf.o\
                     85:        sprintf.o\
                     86:        vprintf.o\
                     87:        vsprintf.o\
                     88:        vfprintf.o\
                     89:        _fdtefg.o\
                     90:        _fp.o\
                     91:        _finit.o\
                     92:        exit.o\
                     93:        _finish.o
                     94: 
                     95: # Primary target.
                     96: all:   stdio$(MCH) STDIO
                     97:        : libc/stdio done.
                     98: 
                     99: # Pseudotargets.
                    100: stdio$(MCH):
                    101:        SRCPATH=$(SRCPATH)/$(MCH) make -e
                    102: # This assumes that either libc.a is being made from scratch
                    103: # or the names of the objects in $(OBJ2) are unchanged.
                    104: # Otherwise, "$(AR) rkus lib.c $?" may not preserve the required object order.
                    105: # It could be done more correctly with $(AR) positional specifications.
                    106: STDIO: $(OBJ) $(OBJ2)
                    107:        $(AR) rkus libc.a $?
                    108:        touch $@
                    109: 
                    110: # Secondary targets.
                    111: _dscan.o:      _dscan.c
                    112: _dtefg.o:      _dtefg.c
                    113: _fdtefg.o:     _fdtefg.c
                    114: _fgetb.o:      _fgetb.c
                    115: _fgetc.o:      _fgetc.c
                    116: _fgete.o:      _fgete.c
                    117: _fgetstr.o:    _fgetstr.c
                    118: _filbuf.o:     _filbuf.c
                    119: _finish.o:     _finish.c
                    120: _finit.o:      _finit.c
                    121: _flsbuf.o:     _flsbuf.c
                    122: _fopen.o:      _fopen.c
                    123: _fp.o:         _fp.c
                    124: _fpseek.o:     _fpseek.c
                    125: _fputa.o:      _fputa.c
                    126: _fputb.o:      _fputb.c
                    127: _fputc.o:      _fputc.c
                    128: _fpute.o:      _fpute.c
                    129: _fputt.o:      _fputt.c
                    130: _scanf.o:      _scanf.c
                    131: _stropen.o:    _stropen.c
                    132: clearerr.o:    clearerr.c
                    133: ecvt.o:                ecvt.c
                    134: exit.o:                exit.c
                    135: fclose.o:      fclose.c
                    136: fcvt.o:                fcvt.c
                    137: fdopen.o:      fdopen.c
                    138: feof.o:                feof.c
                    139: ferror.o:      ferror.c
                    140: fflush.o:      fflush.c
                    141: fgetc.o:       fgetc.c
                    142: fgetpos.o:     fgetpos.c
                    143: fgets.o:       fgets.c
                    144: fopen.o:       fopen.c
                    145: fprintf.o:     fprintf.c
                    146: fputc.o:       fputc.c
                    147: fputs.o:       fputs.c
                    148: fread.o:       fread.c
                    149: freopen.o:     freopen.c
                    150: fscanf.o:      fscanf.c
                    151: fseek.o:       fseek.c
                    152: fsetpos.o:     fsetpos.c
                    153: ftell.o:       ftell.c
                    154: fwrite.o:      fwrite.c
                    155: gcvt.o:                gcvt.c
                    156: getc.o:                getc.c
                    157: getchar.o:     getchar.c
                    158: gets.o:                gets.c
                    159: perror.o:      perror.c
                    160: popen.o:       popen.c
                    161: printf.o:      printf.c
                    162: putc.o:                putc.c
                    163: putchar.o:     putchar.c
                    164: puts.o:                puts.c
                    165: remove.o:      remove.c
                    166: rename.o:      rename.c
                    167: rewind.o:      rewind.c
                    168: scanf.o:       scanf.c
                    169: setbuf.o:      setbuf.c
                    170: setvbuf.o:     setvbuf.c
                    171: sprintf.o:     sprintf.c
                    172: sscanf.o:      sscanf.c
                    173: tmpfile.o:     tmpfile.c
                    174: tmpnam.o:      tmpnam.c
                    175: ungetc.o:      ungetc.c
                    176: vprintf.o:     vprintf.c
                    177: vfprintf.o:    vfprintf.c
                    178: vsprintf.o:    vsprintf.c
                    179: 
                    180: # end of /usr/src/libc/stdio/Makefile

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.