#!/bin/sh #CC=cc if test "1ドル" = "mingw" -o "1ドル" = "gnuwin95" ; then EXE=.exe ; # CC=gcc rm -f o/*.ini fi #(cd bin ; make file-sub EXE=${EXE} CC=${CC}) if [ $# -le 0 ] ; then echo usage: ./add-defs machine-type; echo or ' ' ./add-defs machine-type directory echo where directory might be '/usr/local' or '/public' or '/lusr' -- a place to find various local includes or libs echo see echo h/*.defs exit 1 ; fi if [ -f h/1ドル.defs ] ; then echo using 1ドル.defs ; else echo h/1ドル.defs does not exist echo Build one or use one of `ls h/*.defs` exit 1 fi echo 1ドル> machine # rm -f makedefs # echo> makedefs # echo "# begin makedefs">> makedefs # echo "# constructed by ${USER} using: 0ドル 1ドル 2ドル 3ドル 4ドル 5ドル">> makdefs rm -f makedefs cp makedefc makedefs if [ -d ${PWD}/unixport ] ; then echo "GCLDIR=${PWD}">> makedefs ; else echo "GCLDIR=`pwd`">> makedefs ; fi echo "SHELL=/bin/sh">> makedefs echo "MACHINE=1ドル">> makedefs ####machine specific .defs files may over ride the above#### ####### insert the h/machine.defs file ############ cat h/1ドル.defs>> makedefs if [ -f makedefsafter ] ; then cat makedefsafter>> makedefs ; fi if [ -f ${HOME}/local_gcl.defs ] ; then cat ${HOME}/local_gcl.defs>> makedefs fi echo "">> makedefs echo "# end makedefs">> makedefs # echo inserting h/1ドル.defs in .. # for v in makefile unixport/make_kcn */makefile ; # do # echo " $v," # ./bin/file-sub makedefs $v "# begin makedefs" "# end makedefs" tmpx # mv tmpx $v # done # #echo "" # Copy the config.h over. cat h/1ドル.h> tmpx if [ -f ${HOME}/local_gcl.h ] ; then cat ${HOME}/local_gcl.h>> tmpx fi if fgrep =unknown makedefs> /dev/null ; then echo " if the 'unknown' directories exist you may provide a second argument to ./add-defs of a local directory where things might be, or edit ./add-defs so that it can find them. Otherwise just continue and the portions with unknown will not be compiled." fi if cmp tmpx h/config.h> /dev/null 2>&1 ;then true; else rm -f h/config.h cp tmpx h/config.h fi rm -f tmpx # machine specific stuff that cant be handled normally... if [ -f ./xbin/1ドル-fix ] ; then ./xbin/1ドル-fix ; fi