tar: Update to 1.30 (V2)

Message ID 20180529184258.29492-1-matthias.fischer@ipfire.org
State Dropped
Headers
Series tar: Update to 1.30 (V2) |

Commit Message

Matthias Fischer May 30, 2018, 4:42 a.m. UTC
  For details see:
https://www.gnu.org/software/tar/

Second attempt to update 'tar' to 1.30.

Since new 'tar' has changes in commandline option parsing, the first
commit broke cdrom build and probably some others. Sorry for the noise...

Thanks to Marcel for tips and diffs and Arne for reverting.

Here, these patches built without any errors, I hope it's all right now.

Could somebody please have a look at this?

Best,
Matthias

Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
---
 lfs/Config       | 8 +++-----
 lfs/cdrom        | 5 ++---
 lfs/core-updates | 7 +++----
 lfs/tar          | 6 +++---
 make.sh          | 4 ++--
 5 files changed, 13 insertions(+), 17 deletions(-)
  

Comments

Michael Tremer May 30, 2018, 5:36 a.m. UTC | #1
Hi,

On Tue, 2018-05-29 at 20:42 +0200, Matthias Fischer wrote:
> For details see:
> https://www.gnu.org/software/tar/
> 
> Second attempt to update 'tar' to 1.30.
> 
> Since new 'tar' has changes in commandline option parsing, the first
> commit broke cdrom build and probably some others. Sorry for the noise...
> 
> Thanks to Marcel for tips and diffs and Arne for reverting.
> 
> Here, these patches built without any errors, I hope it's all right now.
> 
> Could somebody please have a look at this?
> 
> Best,
> Matthias
> 
> Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
> ---
>  lfs/Config       | 8 +++-----
>  lfs/cdrom        | 5 ++---
>  lfs/core-updates | 7 +++----
>  lfs/tar          | 6 +++---
>  make.sh          | 4 ++--
>  5 files changed, 13 insertions(+), 17 deletions(-)
> 
> diff --git a/lfs/Config b/lfs/Config
> index cf70f81f9..8e8e5879b 100644
> --- a/lfs/Config
> +++ b/lfs/Config
> @@ -205,13 +205,11 @@ define PAK
>  	sed -e 's/BUILDTARGET/$(BUILDTARGET)/g' -e 's/KVER/$(KVER)/g' -e
> 's/MACHINE/$(BUILD_ARCH)/g' -i /install/packages/package/ROOTFILES
>  	sed -e 's/xxxKVERxxx/$(KVER)/g' -i
> /install/packages/package/install.sh
>  	chmod 755 /install/packages/package/{{,un}install,update}.sh
> -	cd / && tar cf /install/packages/package/files.tmp --files-
> from=/install/packages/package/ROOTFILES --exclude='#*' \
> -		-p --numeric-owner
> +	cd / && tar cfp /install/packages/package/files.tmp --numeric-owner
> --exclude='#*' --files-from=/install/packages/package/ROOTFILES
>  	# Double tar to remove double files
> -	tar xf /install/packages/package/files.tmp -C
> /install/packages/package/tmp/ \
> -		-p --numeric-owner
> +	tar xfp /install/packages/package/files.tmp --numeric-owner -C
> /install/packages/package/tmp/
>  	rm -f /install/packages/package/files.tmp
> -	cd /install/packages/package/tmp/ && tar cf - -p --numeric-owner * |
> xz $(XZ_OPT) > /install/packages/package/files.tar.xz
> +	cd /install/packages/package/tmp/ && tar cJp --numeric-owner * | xz
> $(XZ_OPT) > /install/packages/package/files.tar.xz

You are introducing another -J parameter here again which will cause the tarball
to be compressed twice.

>  	rm -r /install/packages/package/tmp
>  	-cat /install/packages/package/ROOTFILES | grep -v "#" >
> /install/packages/package/ROOTFILES.tmp
>  	mv /install/packages/package/ROOTFILES.tmp
> /install/packages/package/ROOTFILES
> diff --git a/lfs/cdrom b/lfs/cdrom
> index 00f185d81..6382034b5 100644
> --- a/lfs/cdrom
> +++ b/lfs/cdrom
> @@ -65,9 +65,8 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
>  
>  	# Compress root filesystem
>  	# Reason for this tar+untar+tar is removing of entries listed two or
> more in src/ROOTFILES
> -	tar -c -C / --files-from=/tmp/ROOTFILES \
> -		-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
> -		--exclude='proc/*' --exclude='tmp/ROOTFILES'
> +	tar -c --exclude='#*' --exclude='proc/*' --exclude='dev/pts/*' --
> exclude='tmp/ROOTFILES' \
> +		-C / --files-from=/tmp/ROOTFILES -f /$(SNAME).tar
>  	rm -f /tmp/ROOTFILES
>  	tar -x -C /tmp -f /$(SNAME).tar
>  	rm -f /$(SNAME).tar
> diff --git a/lfs/core-updates b/lfs/core-updates
> index d34926967..3d12d40b1 100644
> --- a/lfs/core-updates
> +++ b/lfs/core-updates
> @@ -72,10 +72,9 @@ core/%:
>  	sed -e "s/KVER/$(KVER)/g" -i /tmp/ROOTFILES
>  
>  	#Remove doubled files with tar/untar/tar to save space
> -	tar -c -C / --files-from=/tmp/ROOTFILES \
> -		-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
> -		--exclude='proc/*' --exclude='tmp/ROOTFILES' \
> -		--exclude-from=$(DIR_SRC)/config/rootfiles/$@/exclude
> +	tar -c --exclude='proc/*' --exclude='tmp/ROOTFILES' --exclude='#*' --
> exclude='dev/pts/*' \
> +		--exclude-from=$(DIR_SRC)/config/rootfiles/$@/exclude \
> +		-C / --files-from=/tmp/ROOTFILES -f /$(SNAME).tar
>  	mv -f /tmp/ROOTFILES /install/packages/package/ROOTFILES
>  	tar -p --numeric-owner -x  -C /tmp -f /$(SNAME).tar
>  	rm -f /$(SNAME).tar
> diff --git a/lfs/tar b/lfs/tar
> index 6a949a003..4e914b535 100644
> --- a/lfs/tar
> +++ b/lfs/tar
> @@ -1,7 +1,7 @@
>  #############################################################################
> ##
>  #                                                                            
>  #
>  # IPFire.org - A linux based
> firewall                                         #
> -# Copyright (C) 2007  Michael Tremer & Christian
> Schmidt                      #
> +# Copyright (C) 2018  Michael Tremer & Christian
> Schmidt                      #
>  #                                                                            
>  #
>  # 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        #
> @@ -24,7 +24,7 @@
>  
>  include Config
>  
> -VER        = 1.28
> +VER        = 1.30
>  
>  THISAPP    = tar-$(VER)
>  DL_FILE    = $(THISAPP).tar.bz2
> @@ -50,7 +50,7 @@ objects = $(DL_FILE)
>  
>  $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
>  
> -$(DL_FILE)_MD5 = 8f32b2bc1ed7ddf4cf4e4a39711341b0
> +$(DL_FILE)_MD5 = 8404e4c1fc5a3000228ab2b8ad674a65
>  
>  install : $(TARGET)
>  
> diff --git a/make.sh b/make.sh
> index bfcfbc3e4..1050eb03b 100755
> --- a/make.sh
> +++ b/make.sh
> @@ -1785,8 +1785,8 @@ toolchain)
>  	buildtoolchain
>  	echo "`date -u '+%b %e %T'`: Create toolchain image for
> ${BUILD_ARCH}" | tee -a $LOGFILE
>  	test -d $BASEDIR/cache/toolchains || mkdir -p
> $BASEDIR/cache/toolchains
> -	cd $BASEDIR && tar -cf- --exclude='log/_build.*.log'
> build/${TOOLS_DIR} build/bin/sh log | xz ${XZ_OPT} \
> -		> cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-
> ${BUILD_ARCH}.tar.xz
> +	cd $BASEDIR && XZ_OPT="$(XZ_OPT)" tar -Jc --
> exclude='log/_build.*.log' -f cache/toolchains/$SNAME-$VERSION-toolchain-
> $TOOLCHAINVER-${BUILD_ARCH}.tar.xz --xz \
> +		build/${TOOLS_DIR} build/bin/sh log >> $LOGFILE

This bit also reverts some of the previous changes.

Are you sure you worked on next?

-Michael

>  	md5sum cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-
> ${BUILD_ARCH}.tar.xz \
>  		> cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-
> ${BUILD_ARCH}.md5
>  	stdumount
  
Matthias Fischer May 31, 2018, 7:11 p.m. UTC | #2
Hi,

On 29.05.2018 21:36, Michael Tremer wrote:
> Hi,
> 
> On Tue, 2018-05-29 at 20:42 +0200, Matthias Fischer wrote:
>> For details see:
>> https://www.gnu.org/software/tar/
>> 
>> Second attempt to update 'tar' to 1.30.

>> ...

>>  lfs/Config       | 8 +++-----
>>  lfs/cdrom        | 5 ++---
>>  lfs/core-updates | 7 +++----
>>  lfs/tar          | 6 +++---
>>  make.sh          | 4 ++--
>>  5 files changed, 13 insertions(+), 17 deletions(-)
>> 
>> diff --git a/lfs/Config b/lfs/Config
>> index cf70f81f9..8e8e5879b 100644
>> --- a/lfs/Config
>> +++ b/lfs/Config
>> @@ -205,13 +205,11 @@ define PAK
>>  	sed -e 's/BUILDTARGET/$(BUILDTARGET)/g' -e 's/KVER/$(KVER)/g' -e
>> 's/MACHINE/$(BUILD_ARCH)/g' -i /install/packages/package/ROOTFILES
>>  	sed -e 's/xxxKVERxxx/$(KVER)/g' -i
>> /install/packages/package/install.sh
>>  	chmod 755 /install/packages/package/{{,un}install,update}.sh
>> -	cd / && tar cf /install/packages/package/files.tmp --files-
>> from=/install/packages/package/ROOTFILES --exclude='#*' \
>> -		-p --numeric-owner
>> +	cd / && tar cfp /install/packages/package/files.tmp --numeric-owner
>> --exclude='#*' --files-from=/install/packages/package/ROOTFILES
>>  	# Double tar to remove double files
>> -	tar xf /install/packages/package/files.tmp -C
>> /install/packages/package/tmp/ \
>> -		-p --numeric-owner
>> +	tar xfp /install/packages/package/files.tmp --numeric-owner -C
>> /install/packages/package/tmp/
>>  	rm -f /install/packages/package/files.tmp
>> -	cd /install/packages/package/tmp/ && tar cf - -p --numeric-owner * |
>> xz $(XZ_OPT) > /install/packages/package/files.tar.xz
>> +	cd /install/packages/package/tmp/ && tar cJp --numeric-owner * | xz
>> $(XZ_OPT) > /install/packages/package/files.tar.xz
> 
> You are introducing another -J parameter here again which will cause the tarball
> to be compressed twice.

Yep. Now I saw this too. I should have checked the logs a little more
closely. Overlooked this.

>> ...

>> diff --git a/lfs/cdrom b/lfs/cdrom
>> index 00f185d81..6382034b5 100644
>> --- a/lfs/cdrom
>> +++ b/lfs/cdrom

>>...

>> diff --git a/lfs/tar b/lfs/tar
>> index 6a949a003..4e914b535 100644
>> --- a/lfs/tar
>> +++ b/lfs/tar


>>  ...
>> diff --git a/make.sh b/make.sh
>> index bfcfbc3e4..1050eb03b 100755
>> --- a/make.sh
>> +++ b/make.sh
>> @@ -1785,8 +1785,8 @@ toolchain)
>>  	buildtoolchain
>>  	echo "`date -u '+%b %e %T'`: Create toolchain image for
>> ${BUILD_ARCH}" | tee -a $LOGFILE
>>  	test -d $BASEDIR/cache/toolchains || mkdir -p
>> $BASEDIR/cache/toolchains
>> -	cd $BASEDIR && tar -cf- --exclude='log/_build.*.log'
>> build/${TOOLS_DIR} build/bin/sh log | xz ${XZ_OPT} \
>> -		> cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-
>> ${BUILD_ARCH}.tar.xz
>> +	cd $BASEDIR && XZ_OPT="$(XZ_OPT)" tar -Jc --
>> exclude='log/_build.*.log' -f cache/toolchains/$SNAME-$VERSION-toolchain-
>> $TOOLCHAINVER-${BUILD_ARCH}.tar.xz --xz \
>> +		build/${TOOLS_DIR} build/bin/sh log >> $LOGFILE
> 
> This bit also reverts some of the previous changes.

Yep. Hm! Too bad. I was a bit too fast in committing. I'm dropping the
changes for 'make.sh' and try to make only the changes necessary for
'tar 1.30' in 'Config', 'cdrom' and 'core-updates'.
I updated the branch and rebuild.

> Are you sure you worked on next?

Yes. Definitely.

Best,
Matthias
  
Michael Tremer June 6, 2018, 10:32 p.m. UTC | #3
Hello,

did you test our backup and restore scripts as well? Are they affected by any of
these changes?

-Michael

On Thu, 2018-05-31 at 11:11 +0200, Matthias Fischer wrote:
> Hi,
> 
> On 29.05.2018 21:36, Michael Tremer wrote:
> > Hi,
> > 
> > On Tue, 2018-05-29 at 20:42 +0200, Matthias Fischer wrote:
> > > For details see:
> > > https://www.gnu.org/software/tar/
> > > 
> > > Second attempt to update 'tar' to 1.30.
> > > ...
> > >  lfs/Config       | 8 +++-----
> > >  lfs/cdrom        | 5 ++---
> > >  lfs/core-updates | 7 +++----
> > >  lfs/tar          | 6 +++---
> > >  make.sh          | 4 ++--
> > >  5 files changed, 13 insertions(+), 17 deletions(-)
> > > 
> > > diff --git a/lfs/Config b/lfs/Config
> > > index cf70f81f9..8e8e5879b 100644
> > > --- a/lfs/Config
> > > +++ b/lfs/Config
> > > @@ -205,13 +205,11 @@ define PAK
> > >  	sed -e 's/BUILDTARGET/$(BUILDTARGET)/g' -e 's/KVER/$(KVER)/g' -e
> > > 's/MACHINE/$(BUILD_ARCH)/g' -i /install/packages/package/ROOTFILES
> > >  	sed -e 's/xxxKVERxxx/$(KVER)/g' -i
> > > /install/packages/package/install.sh
> > >  	chmod 755 /install/packages/package/{{,un}install,update}.sh
> > > -	cd / && tar cf /install/packages/package/files.tmp --files-
> > > from=/install/packages/package/ROOTFILES --exclude='#*' \
> > > -		-p --numeric-owner
> > > +	cd / && tar cfp /install/packages/package/files.tmp --numeric-
> > > owner
> > > --exclude='#*' --files-from=/install/packages/package/ROOTFILES
> > >  	# Double tar to remove double files
> > > -	tar xf /install/packages/package/files.tmp -C
> > > /install/packages/package/tmp/ \
> > > -		-p --numeric-owner
> > > +	tar xfp /install/packages/package/files.tmp --numeric-owner -C
> > > /install/packages/package/tmp/
> > >  	rm -f /install/packages/package/files.tmp
> > > -	cd /install/packages/package/tmp/ && tar cf - -p --numeric-owner
> > > * |
> > > xz $(XZ_OPT) > /install/packages/package/files.tar.xz
> > > +	cd /install/packages/package/tmp/ && tar cJp --numeric-owner * |
> > > xz
> > > $(XZ_OPT) > /install/packages/package/files.tar.xz
> > 
> > You are introducing another -J parameter here again which will cause the
> > tarball
> > to be compressed twice.
> 
> Yep. Now I saw this too. I should have checked the logs a little more
> closely. Overlooked this.
> 
> > > ...
> > > diff --git a/lfs/cdrom b/lfs/cdrom
> > > index 00f185d81..6382034b5 100644
> > > --- a/lfs/cdrom
> > > +++ b/lfs/cdrom
> > > ...
> > > diff --git a/lfs/tar b/lfs/tar
> > > index 6a949a003..4e914b535 100644
> > > --- a/lfs/tar
> > > +++ b/lfs/tar
> 
> 
> > >  ...
> > > diff --git a/make.sh b/make.sh
> > > index bfcfbc3e4..1050eb03b 100755
> > > --- a/make.sh
> > > +++ b/make.sh
> > > @@ -1785,8 +1785,8 @@ toolchain)
> > >  	buildtoolchain
> > >  	echo "`date -u '+%b %e %T'`: Create toolchain image for
> > > ${BUILD_ARCH}" | tee -a $LOGFILE
> > >  	test -d $BASEDIR/cache/toolchains || mkdir -p
> > > $BASEDIR/cache/toolchains
> > > -	cd $BASEDIR && tar -cf- --exclude='log/_build.*.log'
> > > build/${TOOLS_DIR} build/bin/sh log | xz ${XZ_OPT} \
> > > -		> cache/toolchains/$SNAME-$VERSION-toolchain-
> > > $TOOLCHAINVER-
> > > ${BUILD_ARCH}.tar.xz
> > > +	cd $BASEDIR && XZ_OPT="$(XZ_OPT)" tar -Jc --
> > > exclude='log/_build.*.log' -f cache/toolchains/$SNAME-$VERSION-toolchain-
> > > $TOOLCHAINVER-${BUILD_ARCH}.tar.xz --xz \
> > > +		build/${TOOLS_DIR} build/bin/sh log >> $LOGFILE
> > 
> > This bit also reverts some of the previous changes.
> 
> Yep. Hm! Too bad. I was a bit too fast in committing. I'm dropping the
> changes for 'make.sh' and try to make only the changes necessary for
> 'tar 1.30' in 'Config', 'cdrom' and 'core-updates'.
> I updated the branch and rebuild.
> 
> > Are you sure you worked on next?
> 
> Yes. Definitely.
> 
> Best,
> Matthias
  
Matthias Fischer June 7, 2018, 5:49 a.m. UTC | #4
On 06.06.2018 14:32, Michael Tremer wrote:
> Hello,

Hi,

> did you test our backup and restore scripts as well? Are they affected by any of
> these changes?

Twice: Yes.

I installed the new 'tar 1.30' on my production machine (Duo Box, Core
120), made a backup and restored it on my testmachine (Core 120, clean
install). Everything worked.

No seen problems so far, except for the fact that right after the
restore I had to watch out hellishly which machine I administered... ;-)

All that is left: I have to install a bunch of addons.

HTH,
Matthias

> -Michael
> 
> On Thu, 2018-05-31 at 11:11 +0200, Matthias Fischer wrote:
>> Hi,
>> 
>> On 29.05.2018 21:36, Michael Tremer wrote:
>> > Hi,
>> > 
>> > On Tue, 2018-05-29 at 20:42 +0200, Matthias Fischer wrote:
>> > > For details see:
>> > > https://www.gnu.org/software/tar/
>> > > 
>> > > Second attempt to update 'tar' to 1.30.
>> > > ...
>> > >  lfs/Config       | 8 +++-----
>> > >  lfs/cdrom        | 5 ++---
>> > >  lfs/core-updates | 7 +++----
>> > >  lfs/tar          | 6 +++---
>> > >  make.sh          | 4 ++--
>> > >  5 files changed, 13 insertions(+), 17 deletions(-)
>> > > 
>> > > diff --git a/lfs/Config b/lfs/Config
>> > > index cf70f81f9..8e8e5879b 100644
>> > > --- a/lfs/Config
>> > > +++ b/lfs/Config
>> > > @@ -205,13 +205,11 @@ define PAK
>> > >  	sed -e 's/BUILDTARGET/$(BUILDTARGET)/g' -e 's/KVER/$(KVER)/g' -e
>> > > 's/MACHINE/$(BUILD_ARCH)/g' -i /install/packages/package/ROOTFILES
>> > >  	sed -e 's/xxxKVERxxx/$(KVER)/g' -i
>> > > /install/packages/package/install.sh
>> > >  	chmod 755 /install/packages/package/{{,un}install,update}.sh
>> > > -	cd / && tar cf /install/packages/package/files.tmp --files-
>> > > from=/install/packages/package/ROOTFILES --exclude='#*' \
>> > > -		-p --numeric-owner
>> > > +	cd / && tar cfp /install/packages/package/files.tmp --numeric-
>> > > owner
>> > > --exclude='#*' --files-from=/install/packages/package/ROOTFILES
>> > >  	# Double tar to remove double files
>> > > -	tar xf /install/packages/package/files.tmp -C
>> > > /install/packages/package/tmp/ \
>> > > -		-p --numeric-owner
>> > > +	tar xfp /install/packages/package/files.tmp --numeric-owner -C
>> > > /install/packages/package/tmp/
>> > >  	rm -f /install/packages/package/files.tmp
>> > > -	cd /install/packages/package/tmp/ && tar cf - -p --numeric-owner
>> > > * |
>> > > xz $(XZ_OPT) > /install/packages/package/files.tar.xz
>> > > +	cd /install/packages/package/tmp/ && tar cJp --numeric-owner * |
>> > > xz
>> > > $(XZ_OPT) > /install/packages/package/files.tar.xz
>> > 
>> > You are introducing another -J parameter here again which will cause the
>> > tarball
>> > to be compressed twice.
>> 
>> Yep. Now I saw this too. I should have checked the logs a little more
>> closely. Overlooked this.
>> 
>> > > ...
>> > > diff --git a/lfs/cdrom b/lfs/cdrom
>> > > index 00f185d81..6382034b5 100644
>> > > --- a/lfs/cdrom
>> > > +++ b/lfs/cdrom
>> > > ...
>> > > diff --git a/lfs/tar b/lfs/tar
>> > > index 6a949a003..4e914b535 100644
>> > > --- a/lfs/tar
>> > > +++ b/lfs/tar
>> 
>> 
>> > >  ...
>> > > diff --git a/make.sh b/make.sh
>> > > index bfcfbc3e4..1050eb03b 100755
>> > > --- a/make.sh
>> > > +++ b/make.sh
>> > > @@ -1785,8 +1785,8 @@ toolchain)
>> > >  	buildtoolchain
>> > >  	echo "`date -u '+%b %e %T'`: Create toolchain image for
>> > > ${BUILD_ARCH}" | tee -a $LOGFILE
>> > >  	test -d $BASEDIR/cache/toolchains || mkdir -p
>> > > $BASEDIR/cache/toolchains
>> > > -	cd $BASEDIR && tar -cf- --exclude='log/_build.*.log'
>> > > build/${TOOLS_DIR} build/bin/sh log | xz ${XZ_OPT} \
>> > > -		> cache/toolchains/$SNAME-$VERSION-toolchain-
>> > > $TOOLCHAINVER-
>> > > ${BUILD_ARCH}.tar.xz
>> > > +	cd $BASEDIR && XZ_OPT="$(XZ_OPT)" tar -Jc --
>> > > exclude='log/_build.*.log' -f cache/toolchains/$SNAME-$VERSION-toolchain-
>> > > $TOOLCHAINVER-${BUILD_ARCH}.tar.xz --xz \
>> > > +		build/${TOOLS_DIR} build/bin/sh log >> $LOGFILE
>> > 
>> > This bit also reverts some of the previous changes.
>> 
>> Yep. Hm! Too bad. I was a bit too fast in committing. I'm dropping the
>> changes for 'make.sh' and try to make only the changes necessary for
>> 'tar 1.30' in 'Config', 'cdrom' and 'core-updates'.
>> I updated the branch and rebuild.
>> 
>> > Are you sure you worked on next?
>> 
>> Yes. Definitely.
>> 
>> Best,
>> Matthias
>
  
Matthias Fischer June 7, 2018, 5:55 a.m. UTC | #5
On 06.06.2018 21:49, Matthias Fischer wrote:
> Hi,
> 
>> did you test our backup and restore scripts as well? Are they affected by any of
>> these changes?
> Twice: Yes.
         ^^^
Sorry, I meant YES / NO!

I tested the backup and restore scripts: they ran without problems.

Best,
Matthias
  
Michael Tremer June 8, 2018, 5:33 a.m. UTC | #6
Okay, cool. Thanks for confirming!

On Wed, 2018-06-06 at 21:55 +0200, Matthias Fischer wrote:
> On 06.06.2018 21:49, Matthias Fischer wrote:
> > Hi,
> > 
> > > did you test our backup and restore scripts as well? Are they affected by any of
> > > these changes?
> > 
> > Twice: Yes.
> 
>          ^^^
> Sorry, I meant YES / NO!
> 
> I tested the backup and restore scripts: they ran without problems.
> 
> Best,
> Matthias
  

Patch

diff --git a/lfs/Config b/lfs/Config
index cf70f81f9..8e8e5879b 100644
--- a/lfs/Config
+++ b/lfs/Config
@@ -205,13 +205,11 @@  define PAK
 	sed -e 's/BUILDTARGET/$(BUILDTARGET)/g' -e 's/KVER/$(KVER)/g' -e 's/MACHINE/$(BUILD_ARCH)/g' -i /install/packages/package/ROOTFILES
 	sed -e 's/xxxKVERxxx/$(KVER)/g' -i /install/packages/package/install.sh
 	chmod 755 /install/packages/package/{{,un}install,update}.sh
-	cd / && tar cf /install/packages/package/files.tmp --files-from=/install/packages/package/ROOTFILES --exclude='#*' \
-		-p --numeric-owner
+	cd / && tar cfp /install/packages/package/files.tmp --numeric-owner --exclude='#*' --files-from=/install/packages/package/ROOTFILES
 	# Double tar to remove double files
-	tar xf /install/packages/package/files.tmp -C /install/packages/package/tmp/ \
-		-p --numeric-owner
+	tar xfp /install/packages/package/files.tmp --numeric-owner -C /install/packages/package/tmp/
 	rm -f /install/packages/package/files.tmp
-	cd /install/packages/package/tmp/ && tar cf - -p --numeric-owner * | xz $(XZ_OPT) > /install/packages/package/files.tar.xz
+	cd /install/packages/package/tmp/ && tar cJp --numeric-owner * | xz $(XZ_OPT) > /install/packages/package/files.tar.xz
 	rm -r /install/packages/package/tmp
 	-cat /install/packages/package/ROOTFILES | grep -v "#" > /install/packages/package/ROOTFILES.tmp
 	mv /install/packages/package/ROOTFILES.tmp /install/packages/package/ROOTFILES
diff --git a/lfs/cdrom b/lfs/cdrom
index 00f185d81..6382034b5 100644
--- a/lfs/cdrom
+++ b/lfs/cdrom
@@ -65,9 +65,8 @@  $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
 
 	# Compress root filesystem
 	# Reason for this tar+untar+tar is removing of entries listed two or more in src/ROOTFILES
-	tar -c -C / --files-from=/tmp/ROOTFILES \
-		-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
-		--exclude='proc/*' --exclude='tmp/ROOTFILES'
+	tar -c --exclude='#*' --exclude='proc/*' --exclude='dev/pts/*' --exclude='tmp/ROOTFILES' \
+		-C / --files-from=/tmp/ROOTFILES -f /$(SNAME).tar
 	rm -f /tmp/ROOTFILES
 	tar -x -C /tmp -f /$(SNAME).tar
 	rm -f /$(SNAME).tar
diff --git a/lfs/core-updates b/lfs/core-updates
index d34926967..3d12d40b1 100644
--- a/lfs/core-updates
+++ b/lfs/core-updates
@@ -72,10 +72,9 @@  core/%:
 	sed -e "s/KVER/$(KVER)/g" -i /tmp/ROOTFILES
 
 	#Remove doubled files with tar/untar/tar to save space
-	tar -c -C / --files-from=/tmp/ROOTFILES \
-		-f /$(SNAME).tar --exclude='#*' --exclude='dev/pts/*' \
-		--exclude='proc/*' --exclude='tmp/ROOTFILES' \
-		--exclude-from=$(DIR_SRC)/config/rootfiles/$@/exclude
+	tar -c --exclude='proc/*' --exclude='tmp/ROOTFILES' --exclude='#*' --exclude='dev/pts/*' \
+		--exclude-from=$(DIR_SRC)/config/rootfiles/$@/exclude \
+		-C / --files-from=/tmp/ROOTFILES -f /$(SNAME).tar
 	mv -f /tmp/ROOTFILES /install/packages/package/ROOTFILES
 	tar -p --numeric-owner -x  -C /tmp -f /$(SNAME).tar
 	rm -f /$(SNAME).tar
diff --git a/lfs/tar b/lfs/tar
index 6a949a003..4e914b535 100644
--- a/lfs/tar
+++ b/lfs/tar
@@ -1,7 +1,7 @@ 
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007  Michael Tremer & Christian Schmidt                      #
+# Copyright (C) 2018  Michael Tremer & Christian Schmidt                      #
 #                                                                             #
 # 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        #
@@ -24,7 +24,7 @@ 
 
 include Config
 
-VER        = 1.28
+VER        = 1.30
 
 THISAPP    = tar-$(VER)
 DL_FILE    = $(THISAPP).tar.bz2
@@ -50,7 +50,7 @@  objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = 8f32b2bc1ed7ddf4cf4e4a39711341b0
+$(DL_FILE)_MD5 = 8404e4c1fc5a3000228ab2b8ad674a65
 
 install : $(TARGET)
 
diff --git a/make.sh b/make.sh
index bfcfbc3e4..1050eb03b 100755
--- a/make.sh
+++ b/make.sh
@@ -1785,8 +1785,8 @@  toolchain)
 	buildtoolchain
 	echo "`date -u '+%b %e %T'`: Create toolchain image for ${BUILD_ARCH}" | tee -a $LOGFILE
 	test -d $BASEDIR/cache/toolchains || mkdir -p $BASEDIR/cache/toolchains
-	cd $BASEDIR && tar -cf- --exclude='log/_build.*.log' build/${TOOLS_DIR} build/bin/sh log | xz ${XZ_OPT} \
-		> cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-${BUILD_ARCH}.tar.xz
+	cd $BASEDIR && XZ_OPT="$(XZ_OPT)" tar -Jc --exclude='log/_build.*.log' -f cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-${BUILD_ARCH}.tar.xz --xz \
+		build/${TOOLS_DIR} build/bin/sh log >> $LOGFILE
 	md5sum cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-${BUILD_ARCH}.tar.xz \
 		> cache/toolchains/$SNAME-$VERSION-toolchain-$TOOLCHAINVER-${BUILD_ARCH}.md5
 	stdumount