|
| 1 | +#------------------------------------------------------------------------- |
| 2 | +# |
| 3 | +# Makefile-- |
| 4 | +# Makefile for the port-specific subsystem of the backend |
| 5 | +# |
| 6 | +# You must invoke this make file with the PORTNAME variable set to the |
| 7 | +# name of a port, i.e. the name of a subdirectory of the current directory. |
| 8 | +# Example: |
| 9 | +# |
| 10 | +# make SUBSYS.o PORTNAME=linux |
| 11 | +# |
| 12 | +# We have two different modes of operation: 1) put stuff specific to Port X |
| 13 | +# in subdirectory X and have that subdirectory's make file make it all, and |
| 14 | +# 2) use conditional statements in the present make file to include what's |
| 15 | +# necessary for a specific port in our own output. (1) came first, but (2) |
| 16 | +# is superior for many things, like when the same thing needs to be done for |
| 17 | +# multiple ports and you don't want to duplicate files in multiple |
| 18 | +# subdirectories. Much of the stuff done via Method 1 today should probably |
| 19 | +# be converted to Method 2. |
| 20 | +# |
| 21 | +# IDENTIFICATION |
| 22 | +# $Header: /cvsroot/pgsql/src/backend/port/Attic/Makefile.in,v 1.1 1997/02/05 21:27:04 scrappy Exp $ |
| 23 | +# |
| 24 | +#------------------------------------------------------------------------- |
| 25 | + |
| 26 | +include ../../Makefile.global |
| 27 | + |
| 28 | +ifndefPORTNAME |
| 29 | +.DEFAULTall: |
| 30 | +@echo"Error: Must invoke make with PORTNAME= argument." |
| 31 | +@false |
| 32 | +else |
| 33 | + |
| 34 | +OBJS =$(PORTNAME)/SUBSYS.o @INET_ATON@ |
| 35 | + |
| 36 | +all: submake SUBSYS.o |
| 37 | + |
| 38 | +SUBSYS.o:$(OBJS) |
| 39 | +$(LD) -r -o SUBSYS.o$(OBJS) |
| 40 | + |
| 41 | +.PHONY: submake clean dep |
| 42 | + |
| 43 | +submake: |
| 44 | +$(MAKE) -C$(PORTNAME) SUBSYS.o |
| 45 | + |
| 46 | +clean: |
| 47 | +rm -f$(OBJS) |
| 48 | +$(MAKE) -C$(PORTNAME) clean |
| 49 | + |
| 50 | +dependdep: |
| 51 | +$(CC) -MM$(INCLUDE_OPT)*.c>depend |
| 52 | +$(MAKE) -C$(PORTNAME)$@ |
| 53 | + |
| 54 | +ifeq (depend,$(wildcard depend)) |
| 55 | +include depend |
| 56 | +endif |
| 57 | + |
| 58 | +endif |
| 59 | + |