Home | History | Annotate | Line # | Download | only in dist
      1  1.1  christos # -*-Makefile-*- for building GNU make with smake
      2  1.1  christos #
      3  1.1  christos # NOTE: If you have no 'make' program at all to process this makefile,
      4  1.1  christos # run 'build.sh' instead.
      5  1.1  christos #
      6  1.1  christos # Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
      7  1.1  christos # 2005, 2006 Free Software Foundation, Inc.
      8  1.1  christos # This file is part of GNU Make.
      9  1.1  christos #
     10  1.1  christos # GNU Make is free software; you can redistribute it and/or modify it under the
     11  1.1  christos # terms of the GNU General Public License as published by the Free Software
     12  1.1  christos # Foundation; either version 2, or (at your option) any later version.
     13  1.1  christos #
     14  1.1  christos # GNU Make is distributed in the hope that it will be useful, but WITHOUT ANY
     15  1.1  christos # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
     16  1.1  christos # A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
     17  1.1  christos #
     18  1.1  christos # You should have received a copy of the GNU General Public License along with
     19  1.1  christos # GNU Make; see the file COPYING.  If not, write to the Free Software
     20  1.1  christos # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
     21  1.1  christos 
     22  1.1  christos #
     23  1.1  christos #	Makefile for GNU Make
     24  1.1  christos #
     25  1.1  christos 
     26  1.1  christos # Ultrix 2.2 make doesn't expand the value of VPATH.
     27  1.1  christos VPATH = /make-3.81/
     28  1.1  christos # This must repeat the value, because configure will remove `VPATH = .'.
     29  1.1  christos srcdir = /make-3.81/
     30  1.1  christos 
     31  1.1  christos CC = sc
     32  1.1  christos RM = delete
     33  1.1  christos MAKE = smake
     34  1.1  christos 
     35  1.1  christos CFLAGS =
     36  1.1  christos CPPFLAGS =
     37  1.1  christos LDFLAGS =
     38  1.1  christos 
     39  1.1  christos # Define these for your system as follows:
     40  1.1  christos #	-DNO_ARCHIVES		To disable `ar' archive support.
     41  1.1  christos #	-DNO_FLOAT		To avoid using floating-point numbers.
     42  1.1  christos #	-DENUM_BITFIELDS	If the compiler isn't GCC but groks enum foo:2.
     43  1.1  christos #				Some compilers apparently accept this
     44  1.1  christos #				without complaint but produce losing code,
     45  1.1  christos #				so beware.
     46  1.1  christos # NeXT 1.0a uses an old version of GCC, which required -D__inline=inline.
     47  1.1  christos # See also `config.h'.
     48  1.1  christos defines =
     49  1.1  christos 
     50  1.1  christos # Which flavor of remote job execution support to use.
     51  1.1  christos # The code is found in `remote-$(REMOTE).c'.
     52  1.1  christos REMOTE = stub
     53  1.1  christos 
     54  1.1  christos # If you are using the GNU C library, or have the GNU getopt functions in
     55  1.1  christos # your C library, you can comment these out.
     56  1.1  christos GETOPT = getopt.o getopt1.o
     57  1.1  christos GETOPT_SRC = $(srcdir)getopt.c $(srcdir)getopt1.c $(srcdir)getopt.h
     58  1.1  christos 
     59  1.1  christos # If you are using the GNU C library, or have the GNU glob functions in
     60  1.1  christos # your C library, you can comment this out.  GNU make uses special hooks
     61  1.1  christos # into the glob functions to be more efficient (by using make's directory
     62  1.1  christos # cache for globbing), so you must use the GNU functions even if your
     63  1.1  christos # system's C library has the 1003.2 glob functions already.  Also, the glob
     64  1.1  christos # functions in the AIX and HPUX C libraries are said to be buggy.
     65  1.1  christos GLOB = Lib glob/glob.lib
     66  1.1  christos 
     67  1.1  christos # If your system doesn't have alloca, or the one provided is bad, define this.
     68  1.1  christos ALLOCA = alloca.o
     69  1.1  christos ALLOCA_SRC = $(srcdir)alloca.c
     70  1.1  christos 
     71  1.1  christos # If your system needs extra libraries loaded in, define them here.
     72  1.1  christos # System V probably need -lPW for alloca.  HP-UX 7.0's alloca in
     73  1.1  christos # libPW.a is broken on HP9000s300 and HP9000s400 machines.  Use
     74  1.1  christos # alloca.c instead on those machines.
     75  1.1  christos LOADLIBES =
     76  1.1  christos 
     77  1.1  christos # Any extra object files your system needs.
     78  1.1  christos extras = amiga.o
     79  1.1  christos 
     80  1.1  christos # Common prefix for machine-independent installed files.
     81  1.1  christos prefix =
     82  1.1  christos # Common prefix for machine-dependent installed files.
     83  1.1  christos exec_prefix =
     84  1.1  christos 
     85  1.1  christos # Directory to install `make' in.
     86  1.1  christos bindir = sc:c
     87  1.1  christos # Directory to find libraries in for `-lXXX'.
     88  1.1  christos libdir = lib:
     89  1.1  christos # Directory to search by default for included makefiles.
     90  1.1  christos includedir = include:
     91  1.1  christos # Directory to install the Info files in.
     92  1.1  christos infodir = doc:
     93  1.1  christos # Directory to install the man page in.
     94  1.1  christos mandir = t:
     95  1.1  christos # Number to put on the man page filename.
     96  1.1  christos manext = 1
     97  1.1  christos # Prefix to put on installed `make' binary file name.
     98  1.1  christos binprefix =
     99  1.1  christos # Prefix to put on installed `make' man page file name.
    100  1.1  christos manprefix = $(binprefix)
    101  1.1  christos 
    102  1.1  christos # Whether or not make needs to be installed setgid.
    103  1.1  christos # The value should be either `true' or `false'.
    104  1.1  christos # On many systems, the getloadavg function (used to implement the `-l'
    105  1.1  christos # switch) will not work unless make is installed setgid kmem.
    106  1.1  christos install_setgid = false
    107  1.1  christos # Install make setgid to this group so it can read /dev/kmem.
    108  1.1  christos group = sys
    109  1.1  christos 
    110  1.1  christos # Program to install `make'.
    111  1.1  christos INSTALL_PROGRAM = copy
    112  1.1  christos # Program to install the man page.
    113  1.1  christos INSTALL_DATA = copy
    114  1.1  christos # Generic install program.
    115  1.1  christos INSTALL = copy
    116  1.1  christos 
    117  1.1  christos # Program to format Texinfo source into Info files.
    118  1.1  christos MAKEINFO = makeinfo
    119  1.1  christos # Program to format Texinfo source into DVI files.
    120  1.1  christos TEXI2DVI = texi2dvi
    121  1.1  christos 
    122  1.1  christos # Programs to make tags files.
    123  1.1  christos ETAGS = etags -w
    124  1.1  christos CTAGS = ctags -w
    125  1.1  christos 
    126  1.1  christos objs = commands.o job.o dir.o file.o misc.o main.o read.o remake.o	\
    127  1.1  christos        rule.o implicit.o default.o variable.o expand.o function.o	\
    128  1.1  christos        vpath.o version.o ar.o arscan.o signame.o strcache.o hash.o      \
    129  1.1  christos        remote-$(REMOTE).o $(GLOB) $(GETOPT) $(ALLOCA) $(extras)
    130  1.1  christos srcs = $(srcdir)commands.c $(srcdir)job.c $(srcdir)dir.c             \
    131  1.1  christos        $(srcdir)file.c $(srcdir)getloadavg.c $(srcdir)misc.c         \
    132  1.1  christos        $(srcdir)main.c $(srcdir)read.c $(srcdir)remake.c             \
    133  1.1  christos        $(srcdir)rule.c $(srcdir)implicit.c $(srcdir)default.c        \
    134  1.1  christos        $(srcdir)variable.c $(srcdir)expand.c $(srcdir)function.c     \
    135  1.1  christos        $(srcdir)vpath.c $(srcdir)version.c $(srcdir)hash.c           \
    136  1.1  christos        $(srcdir)remote-$(REMOTE).c                                     \
    137  1.1  christos        $(srcdir)ar.c $(srcdir)arscan.c $(srcdir)strcache.c              \
    138  1.1  christos        $(srcdir)signame.c $(srcdir)signame.h $(GETOPT_SRC)            \
    139  1.1  christos        $(srcdir)commands.h $(srcdir)dep.h $(srcdir)file.h            \
    140  1.1  christos        $(srcdir)job.h $(srcdir)make.h $(srcdir)rule.h                \
    141  1.1  christos        $(srcdir)variable.h $(ALLOCA_SRC) $(srcdir)config.h.in
    142  1.1  christos 
    143  1.1  christos 
    144  1.1  christos .SUFFIXES:
    145  1.1  christos .SUFFIXES: .o .c .h .ps .dvi .info .texinfo
    146  1.1  christos 
    147  1.1  christos all: make
    148  1.1  christos info: make.info
    149  1.1  christos dvi: make.dvi
    150  1.1  christos # Some makes apparently use .PHONY as the default goal if it is before `all'.
    151  1.1  christos .PHONY: all check info dvi
    152  1.1  christos 
    153  1.1  christos make.info: make.texinfo
    154  1.1  christos 	$(MAKEINFO) -I$(srcdir) $(srcdir)make.texinfo -o make.info
    155  1.1  christos 
    156  1.1  christos make.dvi: make.texinfo
    157  1.1  christos 	$(TEXI2DVI) $(srcdir)make.texinfo
    158  1.1  christos 
    159  1.1  christos make.ps: make.dvi
    160  1.1  christos 	dvi2ps make.dvi > make.ps
    161  1.1  christos 
    162  1.1  christos make: $(objs) glob/glob.lib
    163  1.1  christos 	$(CC) Link $(LDFLAGS) $(objs) $(LOADLIBES) To make.new
    164  1.1  christos 	-delete quiet make
    165  1.1  christos 	rename make.new make
    166  1.1  christos 
    167  1.1  christos # -I. is needed to find config.h in the build directory.
    168  1.1  christos .c.o:
    169  1.1  christos 	$(CC) $(defines) IDir "" IDir $(srcdir)glob \
    170  1.1  christos 	      $(CPPFLAGS) $(CFLAGS) $< $(OUTPUT_OPTION)
    171  1.1  christos 
    172  1.1  christos glob/glob.lib:
    173  1.1  christos 	execute <<
    174  1.1  christos 	    cd glob
    175  1.1  christos 	    smake
    176  1.1  christos <
    177  1.1  christos 
    178  1.1  christos tagsrcs = $(srcs) $(srcdir)remote-*.c
    179  1.1  christos TAGS: $(tagsrcs)
    180  1.1  christos 	$(ETAGS) $(tagsrcs)
    181  1.1  christos tags: $(tagsrcs)
    182  1.1  christos 	$(CTAGS) $(tagsrcs)
    183  1.1  christos 
    184  1.1  christos .PHONY: install installdirs
    185  1.1  christos install:
    186  1.1  christos 	copy make sc:c
    187  1.1  christos 
    188  1.1  christos loadavg: loadavg.c config.h
    189  1.1  christos 	$(CC) $(defines) -DTEST -I. -I$(srcdir) $(CFLAGS) $(LDFLAGS) \
    190  1.1  christos 	      loadavg.c $(LOADLIBES) -o $@
    191  1.1  christos 
    192  1.1  christos clean: glob-clean
    193  1.1  christos 	-$(RM) -f make loadavg *.o core make.dvi
    194  1.1  christos 
    195  1.1  christos distclean: clean glob-realclean
    196  1.1  christos 	-$(RM) -f Makefile config.h config.status build.sh
    197  1.1  christos 	-$(RM) -f config.log config.cache
    198  1.1  christos 	-$(RM) -f TAGS tags
    199  1.1  christos 	-$(RM) -f make.?? make.??s make.log make.toc make.*aux
    200  1.1  christos 	-$(RM) -f loadavg.c
    201  1.1  christos 
    202  1.1  christos realclean: distclean
    203  1.1  christos 	-$(RM) -f make.info*
    204  1.1  christos 
    205  1.1  christos mostlyclean: clean
    206  1.1  christos 
    207  1.1  christos .PHONY: glob-clean glob-realclean
    208  1.1  christos 
    209  1.1  christos glob-clean glob-realclean:
    210  1.1  christos 	execute <<
    211  1.1  christos 	cd glob
    212  1.1  christos 	smake $@
    213  1.1  christos <
    214  1.1  christos 
    215  1.1  christos # --------------- DEPENDENCIES
    216  1.1  christos #
    217  1.1  christos 
    218  1.1  christos # .deps/alloca.Po
    219  1.1  christos # dummy
    220  1.1  christos 
    221  1.1  christos # .deps/ar.Po
    222  1.1  christos ar.o ar.o: ar.c make.h config.h \
    223  1.1  christos   getopt.h \
    224  1.1  christos   gettext.h filedef.h hash.h dep.h \
    225  1.1  christos 
    226  1.1  christos # .deps/arscan.Po
    227  1.1  christos arscan.o arscan.o: arscan.c make.h config.h \
    228  1.1  christos   getopt.h \
    229  1.1  christos   gettext.h \
    230  1.1  christos 
    231  1.1  christos # .deps/commands.Po
    232  1.1  christos commands.o commands.o: commands.c make.h config.h \
    233  1.1  christos   getopt.h \
    234  1.1  christos   gettext.h dep.h filedef.h hash.h variable.h \
    235  1.1  christos   job.h commands.h
    236  1.1  christos 
    237  1.1  christos # .deps/default.Po
    238  1.1  christos default.o default.o: default.c make.h config.h \
    239  1.1  christos   getopt.h \
    240  1.1  christos   gettext.h filedef.h hash.h variable.h rule.h \
    241  1.1  christos   dep.h job.h commands.h
    242  1.1  christos 
    243  1.1  christos # .deps/dir.Po
    244  1.1  christos dir.o dir.o: dir.c make.h config.h \
    245  1.1  christos   getopt.h \
    246  1.1  christos   gettext.h hash.h \
    247  1.1  christos 
    248  1.1  christos # .deps/expand.Po
    249  1.1  christos expand.o expand.o: expand.c make.h config.h \
    250  1.1  christos   getopt.h \
    251  1.1  christos   gettext.h filedef.h hash.h \
    252  1.1  christos   job.h commands.h \
    253  1.1  christos   variable.h rule.h
    254  1.1  christos 
    255  1.1  christos # .deps/file.Po
    256  1.1  christos file.o file.o: file.c make.h config.h \
    257  1.1  christos   getopt.h \
    258  1.1  christos   gettext.h dep.h filedef.h \
    259  1.1  christos   hash.h job.h commands.h \
    260  1.1  christos   variable.h debug.h
    261  1.1  christos 
    262  1.1  christos # .deps/function.Po
    263  1.1  christos function.o function.o: function.c make.h config.h \
    264  1.1  christos   getopt.h \
    265  1.1  christos   gettext.h filedef.h hash.h variable.h dep.h \
    266  1.1  christos   job.h commands.h debug.h
    267  1.1  christos 
    268  1.1  christos # .deps/getloadavg.Po
    269  1.1  christos # dummy
    270  1.1  christos 
    271  1.1  christos # .deps/getopt.Po
    272  1.1  christos getopt.o getopt.o: getopt.c config.h \
    273  1.1  christos 
    274  1.1  christos # .deps/getopt1.Po
    275  1.1  christos getopt1.o getopt1.o: getopt1.c config.h getopt.h \
    276  1.1  christos 
    277  1.1  christos # .deps/hash.Po
    278  1.1  christos hash.o hash.o: hash.c make.h config.h \
    279  1.1  christos   getopt.h \
    280  1.1  christos   gettext.h hash.h
    281  1.1  christos 
    282  1.1  christos # .deps/implicit.Po
    283  1.1  christos implicit.o implicit.o: implicit.c make.h config.h \
    284  1.1  christos   getopt.h \
    285  1.1  christos   gettext.h filedef.h hash.h rule.h dep.h debug.h \
    286  1.1  christos   variable.h job.h \
    287  1.1  christos   commands.h
    288  1.1  christos 
    289  1.1  christos # .deps/job.Po
    290  1.1  christos job.o job.o: job.c make.h config.h \
    291  1.1  christos   getopt.h \
    292  1.1  christos   gettext.h job.h \
    293  1.1  christos   debug.h filedef.h hash.h \
    294  1.1  christos   commands.h variable.h \
    295  1.1  christos 
    296  1.1  christos # .deps/loadavg-getloadavg.Po
    297  1.1  christos loadavg-getloadavg.o loadavg-getloadavg.o: getloadavg.c config.h \
    298  1.1  christos   make.h \
    299  1.1  christos   getopt.h \
    300  1.1  christos   gettext.h \
    301  1.1  christos 
    302  1.1  christos # .deps/main.Po
    303  1.1  christos main.o main.o: main.c make.h config.h \
    304  1.1  christos   getopt.h \
    305  1.1  christos   gettext.h dep.h filedef.h hash.h variable.h \
    306  1.1  christos   job.h commands.h rule.h \
    307  1.1  christos   debug.h getopt.h \
    308  1.1  christos 
    309  1.1  christos # .deps/misc.Po
    310  1.1  christos misc.o misc.o: misc.c make.h config.h \
    311  1.1  christos   getopt.h \
    312  1.1  christos   gettext.h dep.h debug.h
    313  1.1  christos 
    314  1.1  christos # .deps/read.Po
    315  1.1  christos read.o read.o: read.c make.h config.h \
    316  1.1  christos   getopt.h \
    317  1.1  christos   gettext.h \
    318  1.1  christos   dep.h filedef.h hash.h job.h \
    319  1.1  christos   commands.h variable.h rule.h debug.h \
    320  1.1  christos 
    321  1.1  christos # .deps/remake.Po
    322  1.1  christos remake.o remake.o: remake.c make.h config.h \
    323  1.1  christos   getopt.h \
    324  1.1  christos   gettext.h filedef.h hash.h job.h \
    325  1.1  christos   commands.h dep.h \
    326  1.1  christos   variable.h debug.h
    327  1.1  christos 
    328  1.1  christos # .deps/remote-cstms.Po
    329  1.1  christos # dummy
    330  1.1  christos 
    331  1.1  christos # .deps/remote-stub.Po
    332  1.1  christos remote-stub.o remote-stub.o: remote-stub.c make.h config.h \
    333  1.1  christos   getopt.h \
    334  1.1  christos   gettext.h filedef.h hash.h job.h \
    335  1.1  christos   commands.h
    336  1.1  christos 
    337  1.1  christos # .deps/rule.Po
    338  1.1  christos rule.o rule.o: rule.c make.h config.h \
    339  1.1  christos   getopt.h \
    340  1.1  christos   gettext.h dep.h filedef.h hash.h job.h \
    341  1.1  christos   commands.h variable.h \
    342  1.1  christos   rule.h
    343  1.1  christos 
    344  1.1  christos # .deps/signame.Po
    345  1.1  christos signame.o signame.o: signame.c make.h config.h \
    346  1.1  christos   getopt.h \
    347  1.1  christos   gettext.h
    348  1.1  christos 
    349  1.1  christos # .deps/strcache.Po
    350  1.1  christos strcache.o strcache.o: strcache.c make.h config.h \
    351  1.1  christos   getopt.h \
    352  1.1  christos   gettext.h hash.h
    353  1.1  christos 
    354  1.1  christos # .deps/variable.Po
    355  1.1  christos variable.o variable.o: variable.c make.h config.h \
    356  1.1  christos   getopt.h \
    357  1.1  christos   gettext.h dep.h filedef.h \
    358  1.1  christos   hash.h job.h commands.h \
    359  1.1  christos   variable.h rule.h
    360  1.1  christos 
    361  1.1  christos # .deps/version.Po
    362  1.1  christos version.o version.o: version.c config.h
    363  1.1  christos 
    364  1.1  christos # .deps/vmsjobs.Po
    365  1.1  christos # dummy
    366  1.1  christos 
    367  1.1  christos # .deps/vpath.Po
    368  1.1  christos vpath.o vpath.o: vpath.c make.h config.h \
    369  1.1  christos   getopt.h \
    370  1.1  christos   gettext.h filedef.h hash.h variable.h
    371