lorikeet-heimdal: Improve the heimdal import scripts
authorAndrew Bartlett <abartlet@samba.org>
Tue, 30 Nov 2010 23:54:49 +0000 (10:54 +1100)
committerStefan Metzmacher <metze@samba.org>
Wed, 29 Apr 2020 09:07:57 +0000 (11:07 +0200)
import-lorikeet.sh
rebase-lorikeet.sh

index 714e719814742ff51e7b046e251ae8d399a4d0ec..787e5073e315cf526756acb77e6b2cb41aab150a 100755 (executable)
@@ -17,7 +17,10 @@ DATE=`date --utc +%Y%m%d%H%M`
 lorikeet_branch="$1"
 tmp_samba_branch="import-lorikeet-tmp"
 new_samba_branch="import-${lorikeet_branch}"
-samba_master_branch="origin/master"
+samba_master_branch="$2"
+test -n "$samba_master_branch" || {
+    samba_master_branch="origin/master"
+}
 
 export CC="ccache gcc"
 
@@ -34,7 +37,7 @@ heimdal_check() {
        }
 
        test -n "$lorikeet_branch" || {
-               echo "usage: $0 <lorikeet-branch>"
+               echo "usage: $0 <lorikeet-branch> [<samba-branch>]"
                bailout 1
        }
 
@@ -71,16 +74,6 @@ samba_fetch() {
 # It would be good if you have a lex:yacc combination which can rebuild this
 # files...
 #
-samba_generated_files=""
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/asn1/lex.c"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/asn1/parse.c"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/asn1/parse.h"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/com_err/lex.c"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/com_err/parse.c"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/com_err/parse.h"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/hx509/sel-gram.c"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/hx509/sel-gram.h"
-samba_generated_files="${samba_generated_files} source4/heimdal/lib/hx509/sel-lex.c"
 
 build_samba() {
        test x"$skip_build" = x"yes" || {
@@ -117,15 +110,12 @@ samba_create() {
                echo "swap old -> new"
                mv source4/heimdal source4/heimdal-old || bailout $?
                rsync -a source4/heimdal-new/ source4/heimdal || bailout $?
-               echo "restore autogenerated files"
-               for f in ${samba_generated_files};do
-                       echo "restore file: $f"
-                       test -e $f && {
-                               echo "file: $f: already exists"
-                               bailout 255
-                       }
-                       git checkout $f
-               done
+               echo "restore autogenerated files (run lexyacc.sh)"
+               ( 
+                   cd source4
+                   heimdal_build/lexyacc.sh 
+                   git add heimdal/lib/asn1/asn1parse.c heimdal/lib/asn1/asn1parse.h
+               )
        #       echo "PS1=\"'import-heimdal shell'>\"" > ../.bashrc.samba_create
        #       bash --rcfile ../.bashrc.samba_create
        #       bailout 255
index 3f20f1dc87355aeb6b85f0fc7a2659969e34c774..07fd7021bdd347f067fd42f4d461b4b9677c5ce3 100755 (executable)
@@ -19,8 +19,8 @@ old_lorikeet_branch=$1
 
 DATE=`date --utc +%Y%m%d%H%M`
 
-heimdal_my_wip_name="heimdal-my-wip"
-heimdal_my_wip_url="git://git.samba.org/metze/heimdal/wip.git"
+heimdal_my_wip_name="heimdal-local"
+heimdal_my_wip_url="/data/heimdal"
 
 if test x"$old_lorikeet_branch" = x""; then
        old_lorikeet_branch="heimdal-metze-wip/lorikeet-heimdal"
@@ -40,8 +40,9 @@ heimdal_init() {
                mkdir heimdal || bailout $?
                pushd heimdal
                git init || bailout $?
-               git remote add heimdal-svnmirror git://git.samba.org/metze/heimdal/svnmirror.git
-               git remote add heimdal-metze-wip git://git.samba.org/metze/heimdal/wip.git
+               git remote add heimdal-git git://github.com/heimdal/heimdal.git
+               git remote add lorikeet-heimdal-abartlet ssh://git.samba.org/data/git/abartlet/lorikeet-heimdal.git/.git
+               git remote add lorikeet-heimdal ssh://git.samba.org/lorikeet-heimdal.git
                git remote add ${heimdal_my_wip_name} ${heimdal_my_wip_url}
                popd
        }
@@ -53,8 +54,8 @@ heimdal_init() {
 heimdal_fetch() {
        test x"$skip_fetch" = x"yes" || {
                pushd heimdal
-               git fetch heimdal-svnmirror || bailout $?
-               git fetch heimdal-metze-wip || bailout $?
+               git fetch heimdal-git || bailout $?
+               git fetch lorikeet-heimdal-abartlet || bailout $?
                git fetch ${heimdal_my_wip_name} || bailout $?
                popd
        }
@@ -73,7 +74,7 @@ heimdal_rebase() {
                echo "git reset --hard HEAD"
                git reset --hard HEAD
                echo "git rebase"
-               git rebase heimdal-svnmirror/trunk || {
+               git rebase heimdal-git/master || {
                        echo "PS1=\"'git-rebase shell'>\"" > ../.bashrc.heimdal_rebase
                        bash --rcfile ../.bashrc.heimdal_rebase || {
                                ret=$?