#! /bin/sh /usr/share/dpatch/dpatch-run ## 124-integrate-patchy-bootstrap.dpatch by Kevin B. McCarty ## ## All lines beginning with `## DP:' are a description of the patch. ## DP: Write a stub Imakefile for the "p5boot" directory so it can easily ## DP: be integrated into the build. @DPATCH@ diff -urNad cernlib-2006.dfsg.2~/src/Imakefile cernlib-2006.dfsg.2/src/Imakefile --- cernlib-2006.dfsg.2~/src/Imakefile 2008-02-26 14:39:40.000000000 -0800 +++ cernlib-2006.dfsg.2/src/Imakefile 2008-02-26 14:41:31.000000000 -0800 @@ -7,7 +7,7 @@ SUBDIRS= $(LIBDIRS) patchy cfortran #ifdef CERNLIB_UNIX -SUBDIRS:= $(SUBDIRS) scripts mgr +SUBDIRS:= $(SUBDIRS) p5boot scripts mgr #endif InstallLibSubdirs($(LIBDIRS)) diff -urNad cernlib-2006.dfsg.2~/src/p5boot/Imakefile cernlib-2006.dfsg.2/src/p5boot/Imakefile --- cernlib-2006.dfsg.2~/src/p5boot/Imakefile 1969-12-31 16:00:00.000000000 -0800 +++ cernlib-2006.dfsg.2/src/p5boot/Imakefile 2008-02-26 14:39:46.000000000 -0800 @@ -0,0 +1,7 @@ +install.bin: $(CERN_ROOT)/bin/ypatchy + +$(CERN_ROOT)/bin/ypatchy: $(CVSCOSRC)/p5boot/p5boot.sh + chmod a+x $< + FCOMP="$(FC) $(FCFLAGS)" $< + +.PHONY: install.bin diff -urNad cernlib-2006.dfsg.2~/src/p5boot/p5boot.sh cernlib-2006.dfsg.2/src/p5boot/p5boot.sh --- cernlib-2006.dfsg.2~/src/p5boot/p5boot.sh 2006-12-07 06:17:53.000000000 -0800 +++ cernlib-2006.dfsg.2/src/p5boot/p5boot.sh 2008-02-26 14:39:46.000000000 -0800 @@ -1,20 +1,22 @@ -#!/bin/sh +#!/bin/sh -e -mkdir -p $CERN_ROOT/build/p5boot -cd $CERN_ROOT/build/p5boot -cp -p -r $CERN_ROOT/src/p5boot/* . +mkdir -p "$CERN_ROOT"/build/p5boot +cd "$CERN_ROOT"/build/p5boot +cp -p -r -f "$CERN_ROOT"/src/p5boot/* . AR="ar cr" -cd $CERN_ROOT/build/p5boot/p5lib +cd "$CERN_ROOT"/build/p5boot/p5lib $FCOMP -c *.f +# This file contains a "main" program which we don't want in the library: +rm -f nsynopt.o $AR ../p5lib.a *.o -cd $CERN_ROOT/build/p5boot +cd "$CERN_ROOT"/build/p5boot -$FCOMP -o nypatchy nypatchy.f p5lib.a $CERN_ROOT/lib/libkernlib.a +$FCOMP -o nypatchy nypatchy.f p5lib.a "$CERN_ROOT"/lib/libkernlib.a -cd $CERN_ROOT/bin -ln -s $CERN_ROOT/build/p5boot/nypatchy ypatchy +cd "$CERN_ROOT"/bin +ln -s "$CERN_ROOT"/build/p5boot/nypatchy ypatchy -cd $CERN_ROOT/build +cd "$CERN_ROOT"/build