On Wed, Feb 20, 2013 at 11:48:54AM -0800, Fred Ollinger wrote: > Below is the list to the patch I spoke of which seems better than the > one I sent b/c this one fixes the ant build file as well. > > When I applied it, it only patched: patches/jdbc-4.1.patch which is cool. > > But now I can not apply this patch as it is rejected.
This might be related to the way you generated the patch, the order
matters: your patch will be the last patch in the list, so before
generating the diff you have to apply first all the previous patches in
both hsqldd-old and hsqldb-new, make your modification in hsqldb-new and
diff both dirs.
For example, take a look at hsqldb/patches/i96823.patch
--- misc/hsqldb/src/org/hsqldb/Expression.java 2008-05-27 17:15:05.000000000
+0200
+++ misc/build/hsqldb/src/org/hsqldb/Expression.java 2009-01-27
11:42:16.890625000 +0100
hsqldb-old is <unxlngx6>/misc/hsqldb
hsqldb-new is <unxlngx6>/misc/build/hsqldb
Given this, the steps should be
# cd the source main dir
cd trunk/main
# source the script, we will use variables after this command
source <LinuxX86-64Env.Set.sh>
# cd hsqldb source dir
cd $SRC_ROOT/hsqldb
# clean the output dir
rm -rf $OUTPATH
# create the directories
mkdir -p $OUTPATH/misc/build/
# unzip the sources, we need both old and new
unzip $TARFILE_LOCATION/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip -d
$OUTPATH/misc
unzip $TARFILE_LOCATION/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip -d
$OUTPATH/misc/build
# patch old-dir
cd $OUTPATH/misc
# we are in hsqld/$OUTPATH/misc patching misc/hsqldb
PATCHDIR=$SRC_ROOT/hsqldb/patches && cat \
$PATCHDIR/i96823.patch \
$PATCHDIR/i97032.patch \
$PATCHDIR/i103528.patch \
$PATCHDIR/i104901.patch | patch -p2
# cd $OUTPATH/misc/build
cd build
# we are in hsqld/$OUTPATH/misc/build patching misc/build/hsqldb
PATCHDIR=$SRC_ROOT/hsqldb/patches && cat \
$PATCHDIR/i96823.patch \
$PATCHDIR/i97032.patch \
$PATCHDIR/i103528.patch \
$PATCHDIR/i104901.patch | patch -p2
Now make your changes in $OUTPATH/misc/build/hsqldb
When you finish, diff both dirs and create the patch:
cd $SRC_ROOT/hsqldb/$OUTPATH
diff -uNrp misc/hsqldb misc/build/hsqldb > $SRC_ROOT/hsqldb/patches/java7.patch
Make sure the patch is fine. Add it as last patch in PATCH_FILES from
hsqldb/makefile.mk
PATCH_FILES=patches$/i96823.patch \
patches$/i97032.patch \
patches$/i103528.patch \
patches$/i104901.patch \
patches$/java7.patch
Remove the $SRC_ROOT/hsqldb/$OUTPATH and build to test the patch. If
it's ok, generate a patch and attach it to the bug. The patch should
only contain the changes made to main/hsqldb/makefile.mk and the new
patch in hsqldb/patches
Regards
--
Ariel Constenla-Haile
La Plata, Argentina
pgpv9tLNlSrVf.pgp
Description: PGP signature
