stefan pushed a commit to branch master.

http://git.enlightenment.org/admin/release-management.git/commit/?id=b8555a57e8527701e66bb6b454492444fa57ebae

commit b8555a57e8527701e66bb6b454492444fa57ebae
Author: Stefan Schmidt <[email protected]>
Date:   Tue Sep 3 09:44:52 2019 +0200

    release: update release script for meson buildsystem
    
    In preparations for the 1.23 release this needs updating for our switch
    from autotools to meson. Cleaning up some no longer needed separated
    libs handling.
---
 release.sh | 126 +++++++++++++++++++++++--------------------------------------
 1 file changed, 47 insertions(+), 79 deletions(-)

diff --git a/release.sh b/release.sh
index 86b945c..f702af5 100755
--- a/release.sh
+++ b/release.sh
@@ -2,15 +2,14 @@
 
 ### CONFIG - Please edit this section before using this script
 VERSION_MAJ=1
-VERSION_MIN=22
-OLD_VERSION_MIN=21
+VERSION_MIN=23
+OLD_VERSION_MIN=22
 VERSION_MIC=0
 OLD_VERSION_MIC=0
 PRE_RELEASE_STRING="-alpha1" # "", "-alpha1", "-beta1", ...
 OLD_PRE_RELEASE_STRING=""
 
 #OLD_VERSION_MIC=$(let $VERSION_MIC-1)
-libs="efl"
 VERSION_SIMPLE="$VERSION_MAJ.$VERSION_MIN.$VERSION_MIC"
 VERSION="$VERSION_SIMPLE$PRE_RELEASE_STRING"
 
OLD_VERSION="$VERSION_MAJ.$OLD_VERSION_MIN.$OLD_VERSION_MIC$OLD_PRE_RELEASE_STRING"
@@ -25,109 +24,92 @@ set -e
 
 get_news()
 {
-       $EDITOR configure.ac || exit 1
+       $EDITOR meson.build || exit 1
        echo "Changes since $OLD_VERSION:" >> NEWS
        echo -e "---------------------\n" >> NEWS
        ../release-management/generate_news.py v$OLD_VERSION..HEAD >> NEWS || 
exit 1
        git diff || exit 1
        $EDITOR NEWS || exit 1
        git diff || exit 1
-       git commit -v configure.ac NEWS -m "release: Update NEWS and bump 
version for $VERSION release" || exit 1
+       git commit -v meson.build NEWS -m "release: Update NEWS and bump 
version for $VERSION release" || exit 1
        git show || exit 1
 }
 
 do_compile()
 {
-       ./autogen.sh || exit 1
-       make "$MAKEFLAGS" || exit 1
-       make -j 3 distcheck || exit 1
+       meson build-efl-$VERSION
+       ninja -C build-efl-$VERSION dist
 
-       make doc
+#      make doc
 }
 
 do_package_and_upload()
 {
-       local lib flags
-
-       lib="$1"
        echo
-       echo "Package $lib"
+       echo "Package efl"
        echo
 
-       cd "$lib"
-       #git co po/ || exit 1
-       make clean distclean || exit 1
+       cd efl
 
        get_news
        do_compile
 
-       sha256sum $lib-$VERSION.tar.xz > $lib-$VERSION.tar.xz.sha256
+       build-efl-$VERSION/meson-dist/efl-1.23.0.tar.xz
+       build-efl-$VERSION/meson-dist/efl-1.23.0.tar.xz.sha256sum
 
-       if [ $MAJOR = 0 ]
-       then
-               mv $lib-$VERSION.tar.xz $lib-$VERSION-pre.tar.xz
-               mv $lib-$VERSION.tar.xz.sha256 $lib-$VERSION-pre.tar.xz.sha256
-       fi
 
        if [ $MAJOR = 0 ]
        then
-               scp $lib-$VERSION-pre.tar.* 
download.enlightenment.org:/srv/web/download.enlightenment.org/public_html/pre-releases/
+               mv efl-$VERSION.tar.xz efl-$VERSION-pre.tar.xz
+               mv efl-$VERSION.tar.xz.sha256 efl-$VERSION-pre.tar.xz.sha256
+               scp efl-$VERSION-pre.tar.* 
download.enlightenment.org:/srv/web/download.enlightenment.org/pre-releases/
        fi
 
-       scp $lib-$VERSION.tar.* 
download.enlightenment.org:/srv/web/download.enlightenment.org/public_html/pre-releases/
+       scp efl-$VERSION.tar.* 
download.enlightenment.org:/srv/web/download.enlightenment.org/pre-releases/
 
        cd ..
        echo
-       echo "Packaged and uploaded $lib. Please push changes to repo now."
+       echo "Packaged and uploaded efl. Please push changes to repo now."
        echo
 }
 
 do_finalize_release()
 {
-       local lib flags
-
-       lib="$1"
        echo
-       echo "Finalize $lib"
+       echo "Finalize efl"
        echo
 
-       cd "$lib"
+       cd efl
        git tag -a v$VERSION -m "v$VERSION" || exit 1
 
 #      if [ $MAJOR = 1 ]
 #      then
-#              git branch $lib-$VERSION_MAJ.$VERSION_MIN
-#              git push origin 
$lib-$VERSION_MAJ.$VERSION_MIN:$lib-$VERSION_MAJ.$VERSION_MIN
+#              git branch efl-$VERSION_MAJ.$VERSION_MIN
+#              git push origin 
efl-$VERSION_MAJ.$VERSION_MIN:efl-$VERSION_MAJ.$VERSION_MIN
 #      fi
 
        echo "Move tarballs to final destination"
        if [ $MAJOR = 0 ]
        then
-               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/public_html/pre-releases/$lib-$VERSION-pre.tar.xz
 
/srv/web/download.enlightenment.org/public_html/rel/libs/$lib/$lib-$VERSION.tar.xz
-               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/public_html/pre-releases/$lib-$VERSION-pre.tar.xz.sha256
 
/srv/web/download.enlightenment.org/public_html/rel/libs/$lib/$lib-$VERSION.tar.xz.sha256
+               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/pre-releases/efl-$VERSION-pre.tar.xz 
/srv/web/download.enlightenment.org/rel/libs/efl/efl-$VERSION.tar.xz
+               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/pre-releases/efl-$VERSION-pre.tar.xz.sha256 
/srv/web/download.enlightenment.org/rel/libs/efl/efl-$VERSION.tar.xz.sha256
        else
-               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/public_html/pre-releases/$lib-$VERSION.tar.*
 /srv/web/download.enlightenment.org/public_html/rel/libs/$lib/
-
-               # only efl and elementary
-               if [ $lib = "efl" ]
-               then
-                       scp $lib-$VERSION-doc.tar.bz2 
download.enlightenment.org:/srv/web/docs.enlightenment.org/public_html/$lib/
-                       ssh download.enlightenment.org tar xf 
/srv/web/docs.enlightenment.org/public_html/$lib/$lib-$VERSION-doc.tar.bz2 -C  
/srv/web/docs.enlightenment.org/public_html/$lib/
-                       ssh download.enlightenment.org rm -r 
/srv/web/docs.enlightenment.org/public_html/$lib/$VERSION_SIMPLE
-                       ssh download.enlightenment.org mv 
/srv/web/docs.enlightenment.org/public_html/$lib/$lib-$VERSION-doc/doc/html 
/srv/web/docs.enlightenment.org/public_html/$lib/$VERSION_SIMPLE
-                       ssh download.enlightenment.org rm -r 
/srv/web/docs.enlightenment.org/public_html/$lib/$lib-$VERSION-doc
-                       ssh download.enlightenment.org rm 
/srv/web/docs.enlightenment.org/public_html/$lib/$lib-$VERSION-doc.tar.bz2
-
-                       ssh download.enlightenment.org rm 
/srv/web/docs.enlightenment.org/public_html/$lib/current
-                       ssh download.enlightenment.org ln -s 
/srv/web/docs.enlightenment.org/public_html/$lib/$VERSION_SIMPLE 
/srv/web/docs.enlightenment.org/public_html/$lib/current
-               fi
-
-#              Sed version to .99 and dev mode
+               ssh download.enlightenment.org mv 
/srv/web/download.enlightenment.org/pre-releases/efl-$VERSION.tar.* 
/srv/web/download.enlightenment.org/rel/libs/efl/
+
+               scp efl-$VERSION-doc.tar.bz2 
download.enlightenment.org:/srv/web/docs.enlightenment.org/public_html/efl/
+               ssh download.enlightenment.org tar xf 
/srv/web/docs.enlightenment.org/public_html/efl/efl-$VERSION-doc.tar.bz2 -C 
/srv/web/docs.enlightenment.org/public_html/efl/
+               ssh download.enlightenment.org rm -r 
/srv/web/docs.enlightenment.org/public_html/efl/$VERSION_SIMPLE
+               ssh download.enlightenment.org mv 
/srv/web/docs.enlightenment.org/public_html/efl/efl-$VERSION-doc/doc/html 
/srv/web/docs.enlightenment.org/public_html/efl/$VERSION_SIMPLE
+               ssh download.enlightenment.org rm -r 
/srv/web/docs.enlightenment.org/public_html/efl/efl-$VERSION-doc
+               ssh download.enlightenment.org rm 
/srv/web/docs.enlightenment.org/public_html/efl/efl-$VERSION-doc.tar.bz2
+
+               ssh download.enlightenment.org rm 
/srv/web/docs.enlightenment.org/public_html/efl/current
+               ssh download.enlightenment.org ln -s 
/srv/web/docs.enlightenment.org/public_html/efl/$VERSION_SIMPLE 
/srv/web/docs.enlightenment.org/public_html/efl/current
        fi
 
        cd ..
        echo
-       echo "Finalized $lib. Please push changes to repo now."
+       echo "Finalized efl. Please push changes to repo now."
        echo
 }
 
@@ -148,20 +130,10 @@ Options:
   --finalise Finalise a release. Move to the right location, git tags, etc
   --help     Show this message
 
-
 EOF
 exit 0
 }
 
-# how many CPUs?
-if [ -f /proc/cpuinfo ]
-then
-       cpus="`grep ^processor /proc/cpuinfo | wc -l`"
-        cpus=$(($cpus+2))
-fi
-[ "$cpus" ] || cpus=4
-MAKEFLAGS="-j$cpus"
-
 while [ $# -ge 1 ]
 do
        case "$1" in
@@ -185,21 +157,17 @@ do
        shift
 done
 
-for e in $libs
-do
-       if [ ! -d "$e" ]
-       then
-               echo "$e directory missing?"
-               exit 1
-       fi
-
-       if [ $PREPARE = 1 ]
-       then
-               do_package_and_upload "$e"
-       fi
-       if [ $FINALISE = 1 ]
-       then
-               do_finalize_release "$e"
-       fi
+if [ ! -d "efl" ]
+then
+       echo "efl directory missing?"
+       exit 1
+fi
 
-done
+if [ $PREPARE = 1 ]
+then
+       do_package_and_upload
+fi
+if [ $FINALISE = 1 ]
+then
+       do_finalize_release
+fi

-- 


Reply via email to