#!/bin/sh #ident "@(#)cls4:bsd.fix 1.3" ############################################################################### # # C++ source for the C++ Language System, Release 3.0. This product # is a new release of the original cfront developed in the computer # science research center of AT&T Bell Laboratories. # # Copyright (c) 1993 UNIX System Laboratories, Inc. # Copyright (c) 1991, 1992 AT&T and UNIX System Laboratories, Inc. # Copyright (c) 1984, 1989, 1990 AT&T. All Rights Reserved. # # THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE of AT&T and UNIX System # # Laboratories, Inc. The copyright notice above does not evidence # any actual or intended publication of such source code. # ############################################################################### #This shell script should be run exactly once by BSD 4.3 or later users. #It fixes various files to allow a build of cfront on a BSD system. #The fixes are: # 1. Runs bsd.sed in the scratch directory. This updates the ..c # files to use the bsd FILE structure instead of the system V # FILE structure. # 2. (no longer necessary) # These files contain Unix version-dependent constructs. # This also causes BSD to be defined when cfront is built. # 3. Changes LOPT in demo/task/makefile to use correct form of -L option. # 4. Changes LOPT in CC command to use correct form of -L option. # # Integrity checks if test -f bsd.corrupt ;then echo Your source files may have been corrupted by a previous build. echo Reload the distribution and try again. exit 1 fi > bsd.corrupt echo "Fix cfront to allow a build on BSD systems:" echo if test ! -f scratch/bsd.sed..c ;then echo "running scratch/bsd.sed." (cd scratch; sh bsd.sed) > scratch/bsd.sed..c else echo "scratch/bsd.sed has already been run." fi echo rm bsd.corrupt echo "Updating CC and demo/task/makefile" echo echo "chmod +w CC demo/task/makefile" chmod +w CC demo/task/makefile chmod +w CC demo/complex/makefile for i in CC demo/task/makefile demo/complex/makefile do ed $i <