# $Header: /cvsroot/lsb/test_sets/lsb-os/tset/LSB.os/procprim/execl/Makefile,v 1.1 2001/05/27 06:59:19 cyeoh Exp $
#
# Copyright (c) 1997 X/Open Company Ltd., A member of The Open Group
#
# All rights reserved.  No part of this source code may be reproduced,
# stored in a retrieval system, or transmitted, in any form or by any
# means, electronic, mechanical, photocopying, recording or otherwise,
# except as stated in the end-user licence agreement, without the prior
# permission of the copyright owners.
#
# Motif, OSF/1 and UNIX are registered trademarks and X/Open,
# the "X Device" and The Open Group are trademarks of The Open Group.
#
# Developed for X/Open by Applied Testing and Technology, Inc.
#
# Project: VSRT
#
# File: tset/rt.os/procprim/execl/Makefile
#
# Modifications:
# $Log: Makefile,v $
# Revision 1.1  2001/05/27 06:59:19  cyeoh
# Adds files for lsb-os test suite
#
# Revision 11.1  2000/03/22 17:39:54  vsx
# use threads versions of libraries and compiler flags
#
# Revision 11.0  1999/03/22 19:42:26  andy
# Branch point for Release 5.0.3
#
# Revision 10.0  1999/02/08 16:40:55  andy
# Branch point for Release 5.0.3b1
#
# Revision 9.2  1998/08/04 00:27:14  vsx0
# expanded clean target to cover all .o's. SR 47
#
# Revision 9.0  1998/07/15 18:54:15  andy
# Branch point for Release 5.0.2
#
# Revision 8.0  1998/06/18 22:18:23  andy
# Branch point for Release 5.0.2b2
#
# Revision 7.0  1998/05/25 01:51:49  andy
# Branch point for Release 5.0.2b1
#
# Revision 6.1  1998/04/22 00:16:28  vsx0
# Removed more TET 1.10 dependencies.
#
# Revision 6.0  1998/01/04 02:30:37  tbr
# Branch point for Release vsrt 5.0.1A
#
# Revision 5.0  1997/11/26 21:41:29  andy
# Branch point for Release 5.0.1
#
# Revision 4.1  1997/11/19 03:35:48  vsx0
# Moved LDFLAGS before system libraries.
#
# Revision 4.0  1997/10/22 15:40:28  dave
# Branch point for Release 5-0-0b1
#
# Revision 3.0  1997/07/27 18:02:23  andy
# Branch point for Release 5.0.0
#
# Revision 2.1  1997/07/16  22:03:19  andy
# Locations of TET libraries and includes inherited from vmake
#
# Revision 2.0  1997/06/15  19:46:18  andy
# Branch point for Release 5.0.0b1
#
# Revision 1.2  1997/06/04  18:37:23  andy
# Added scheduling test
#


CC =	cc
RM =		rm -f
LINT =	lint
LINT1 =		/usr/lib/lint1
# This is a working lint in the top level testset directory
PRINTER =	lpr
PRINTFLAGS =	
TET_EXECUTE =	../../../../TESTROOT

TET_ROOT =	../../../../..
VSXDIR =	../../../../SRC
SYSINC =	$(VSXDIR)/SYSINC
VSRT_LIBS = 
SYSLIBS =	
LIBVPORT =	$(VSXLIB)/thrvport.a

VSXINC =	$(VSXDIR)/INC
VSXLIB =	$(VSXDIR)/LIB
VSXBIN =	$(VSXDIR)/BIN
CHMOG =		$(VSXBIN)/chmog
GENLIB =	$(VSXLIB)/thrgenlib.a
VSRTLIB =	$(VSXLIB)/vsrtlib.a
TSETLIB =	$(VSXLIB)/thrtsetlib.a

# What is installed:

INSTOWN =	vsx0
INSTGRP =	vsxg0
INSTMODE =	755
INSTOWN1 =      root
INSTMODE1 =     6755
INSTDIR =	$(TET_EXECUTE)/tset/LSB.os/procprim/execl

# Local (to this product only) includes, libraries, etc:

LOCALINC =
LOCALLIB =	

# product-wide libraries for ld(1):

LIBS =		$(VSRTLIB) $(TSETLIB) $(GENLIB) $(VSXLIB)/thrvlib.a $(LIBVPORT) $(THRAPILIB)

THR_COPTS =	
DEFINES =	

# INCS, as seen from obj directory
INCS =		-I$(TETINC) -I$(VSXINC) -I$(SYSINC)
CFLOCAL =
CFLAGS =	$(CFLOCAL) $(INCS) -DTET_POSIX_THREADS $(DEFINES) $(THR_COPTS)
VSRT_LDFLAGS =	

CFILES =	execl.c
OFILES =	execl.o
CFILESc =	execl_check.c
OFILESc =	execl_check.o
CFILES3 =	execl3.c
OFILES3 =	execl3.o
IFILES =	
LFILES =	

OLDLINT =	TRUE
LINTFLAGS =	$(INCS) -DTET_POSIX_THREADS $(DEFINES) -n
LINTLIBS =	-lvsx -lvlib -ltset -lgen -lvport
LINTDRV =	$(VSXDIR)/common/tet_startup/startup.c

# Targets: ---------------------------------------------------------

all:		T.execl execl_check execl3

execl:	T.execl

T.execl:	$(OFILES) $(THRTCM) $(VSXLIB)/thrstartup.o $(LIBS)
		$(CC) -o $@ $(OFILES) $(THRTCM) $(VSXLIB)/thrstartup.o $(LIBS) $(VSRT_LDFLAGS) $(VSRT_LIBS)
		@echo "	$@ made"

execl_check:	$(OFILESc) $(THRTCM) $(VSXLIB)/thrstartup.o $(LIBS)
		$(CC) -o $@ $(OFILESc) $(LIBS) $(VSRT_LDFLAGS) $(VSRT_LIBS)
		@echo "	$@ made"

execl3:		$(OFILES3) $(THRTCMCHILD) $(LIBS)
		$(CC) -o $@ $(OFILES3) $(THRTCMCHILD) $(LIBS) $(VSRT_LDFLAGS) $(VSRT_LIBS)
		@echo "	$@ made"

$(LIBS):
	-@echo "Warning: cannot continue making: $@ needs to be installed"
		@false

INSTALL:	$(INSTDIR)/T.execl $(INSTDIR)/execl_check $(INSTDIR)/execl3

$(INSTDIR)/T.execl:	T.execl
		$(CHMOG) $(INSTMODE) $(INSTOWN) $(INSTGRP) -m $? $@
		@echo " $? installed in $@"

$(INSTDIR)/execl_check:	execl_check
		$(CHMOG) $(INSTMODE) $(INSTOWN) $(INSTGRP) -m $? $@
		@echo " $? installed in $@"

$(INSTDIR)/execl3:    execl3
		$(CHMOG) $(INSTMODE1) $(INSTOWN1) $(INSTGRP) -m $? $@

LINTLIB:

LINT:
		$(LINT) $(LINTFLAGS) $(CFILES) $(LINTDRV) -ltcm $(LINTLIBS)

FORCE:		CLOBBER all

PRINT:
		@$(PRINTER) $(PRINTFLAGS) Makefile $(IFILES) $(CFILES) 

CLEAN:
		$(RM) $(OFILES) $(OFILESc) $(OFILES3)

CLOBBER:	CLEAN
		$(RM) T.execl $(INSTDIR)/T.execl execl_check $(INSTDIR)/execl_check

depend:
	CFLAGS="$(CFLAGS)" CC="$(CC)" $(VSXBIN)/mkdep $(CFILES)

# DO NOT DELETE THIS LINE -- make depend uses it
# DEPENDENCIES MUST END AT END OF FILE
execl.o:	../../../../SRC/INC/dbug.h  \
	../../../../SRC/INC/exitcodes.h  \
	../../../../SRC/INC/report.h  \
	../../../../SRC/INC/std.h  \
	../../../../SRC/INC/sysdep.h  \
	../../../../SRC/INC/vsrt/vsrt.h  \
	../../../../SRC/SYSINC/errno.h  \
	../../../../SRC/SYSINC/sys/mman.h  \
	../../../../SRC/SYSINC/limits.h  \
	../../../../SRC/SYSINC/signal.h  \
	../../../../SRC/SYSINC/stdio.h  \
	../../../../SRC/SYSINC/sys/types.h  \
	../../../../SRC/SYSINC/time.h  \
	../../../../SRC/SYSINC/unistd.h 
execl_check.o:	../../../../SRC/INC/dbug.h  \
	../../../../SRC/INC/exitcodes.h  \
	../../../../SRC/INC/report.h  \
	../../../../SRC/INC/std.h  \
	../../../../SRC/INC/sysdep.h  \
	../../../../SRC/INC/vsrt/vsrt.h  \
	../../../../SRC/SYSINC/errno.h  \
	../../../../SRC/SYSINC/sys/mman.h  \
	../../../../SRC/SYSINC/limits.h  \
	../../../../SRC/SYSINC/signal.h  \
	../../../../SRC/SYSINC/stdio.h  \
	../../../../SRC/SYSINC/sys/types.h  \
	../../../../SRC/SYSINC/time.h  \
	../../../../SRC/SYSINC/unistd.h 
# DEPENDENCIES MUST END AT END OF FILE
# IF YOU PUT STUFF HERE IT WILL GO AWAY
# see make depend above
