This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

how to create a new GCC branch?


Background:
A while back, we were given the OK to create a GCC branch for
"GNU UPC" (aka, GUPC and/or GCC/UPC).  Recently, I've merged
our UPC-related changes into a working copy of the "GCC trunk".
I have a wwwdocs update ready to go, which I'll commit once
the gupc branch has been created.  I have only a passing familiarity
with "svn", though have spent some time reviewing the material
in the GCC Wiki.

Before attempting to create the branch, I thought it might
be best to run the following procedure by you to see if
it lists the correct steps in creating a new branch.
I've written it as a parametrized shell script.

I'd appreciate your review/suggestions to make sure:
(1) that the command syntax is correct, (2) the sequence
of commands is correct, and (3) that the steps follow
the GCC conventions for working with the SVN repository.

My reading of the GCC docs. indicates that it
isn't necessary for me to submit for review the patches
that make up the gupc branch.  If that's incorrect, please
let me know.

Thanks,
- Gary

#!/bin/sh -xe
GCCUSER=gfunck
BRANCH=gupc
GCCREPO="svn+ssh://${GCCUSER}@gcc.gnu.org/svn/gcc"
# Create new branch.
BRANCHPOINT=`svnversion . | sed -e 's/^\([0-9]*\).*$/\1/'`
svn copy -m "creating ${BRANCH} branch" . \
       "${GCCREPO}/branches/${BRANCH}"
# Record the branch point.
svn copy -r"${BRANCHPOINT}" -m "record ${BRANCH} branch point" \
          "${GCCREPO}/trunk" \
          "${GCCREPO}/tags/${BRANCH}-branchpoint"
# Switch to new branch.
svn switch "${GCCREPO}/branches/${BRANCH}"
# Record merge point.
MERGEPOINT=`svnversion . | sed -e 's/^\([0-9]*\).*$/\1/'`
MERGEDATE=`date +'%Y%m%d'`
svn copy -r"${MERGEPOINT}" -m "record ${BRANCH} merge point" \
          "${GCCREPO}/trunk" \
          "${GCCREPO}/tags/${BRANCH}-merge-${MERGEDATE}"
# Initialize svnmerge
svnmerge.py init
# Trim back to "gcc core + gcc/testsuite"
extradirs="libjava libstdc++-v3 gcc/objcp gcc/java gcc/cp gcc/fortran
           gcc/ada gcc/objc libffi boehm-gc libobjc gnattools
           libgfortran libada"
for dir in $extradirs; do
  svn switch "${GCCREPO}/emptydir" $dir
done


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]