OSDN Git Service

Corrected theimplementation of portsreinstall-chroot destroy.
authorMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Tue, 21 Aug 2018 07:39:51 +0000 (15:39 +0800)
committerMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Tue, 21 Aug 2018 07:39:51 +0000 (15:39 +0800)
 Changes to be committed:
modified:   lib/chroot/libdatabase_maintain.sh
modified:   lib/libmain.sh

lib/chroot/libdatabase_maintain.sh
lib/libmain.sh

index 3998a3a..86d4236 100644 (file)
@@ -7,17 +7,25 @@
 # This software is distributed under the 2-Clause BSD License.
 # ==============================================================================
 
-# ============= Destroy the builder chroot environment and clean up the temporary database =============
+# ============= Destroy the builder chroot environment by preserving the option setting =============
 database_maintain_destroy ()
 {
        message_echo "Starting to clean up the builder chroot environment..."
+       program_deregister_stage_complete CLEANUP_GUEST
        fs_destroy
+       message_echo "Starting to reset the temporary database by preserving the option setting..."
+       find "${DBDIR}" -depth 1 -maxdepth 1 \
+               -not \( -name saved_options.sh \
+                       -or -name MYVERSION -or -name .lock \) \
+               -exec rm -rf {} \; 2> /dev/null || :
+       touch "${DBDIR}/MYVERSION"
 }
 
 # ============= Destroy the builder chroot environment and clean up the temporary database =============
 database_maintain_clean ()
 {
-       database_maintain_destroy
+       message_echo "Starting to clean up the builder chroot environment..."
+       fs_destroy
        message_echo "Starting to clean up the temporary database..."
        command_exec_without_pkgtools__notify_reset_options
        rm -rf "${DBDIR}"
index e693fdd..ce038f5 100644 (file)
@@ -12,7 +12,7 @@ main_set_version ()
        MYVERSION=4.1.0
        COMPATIBLE_VERSIONS='^(4\.[1]\.[0-9])$'
        # Template for development versions
-       MYVERSION=4.0.0+toward_4.1.0_20180821151910
+       MYVERSION=4.0.0+toward_4.1.0_20180821153931
        COMPATIBLE_VERSIONS='^(4\.[0-1]\.[0-9]]|4\.[0]\.[0]+(|\+toward_4\.[0-1]\.[0-9]+_[0-9]+))$'
 }