openoffice-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matthias Seidel <matthias.sei...@hamburg.de>
Subject Re: [openoffice] branch trunk updated: 'fakeroot' is no longer optional, but required, when making deb/dpkg so no need to worry about the old hack and seeing if we have fakeroot.
Date Sun, 03 Jan 2021 14:16:20 GMT
Hi Jim,

One user has a problem with this commit, see:

https://bz.apache.org/ooo/show_bug.cgi?id=128422

Could you have a look?

Regards,

   Matthias


Am 30.12.20 um 17:07 schrieb jim@apache.org:
> This is an automated email from the ASF dual-hosted git repository.
>
> jim pushed a commit to branch trunk
> in repository https://gitbox.apache.org/repos/asf/openoffice.git
>
>
> The following commit(s) were added to refs/heads/trunk by this push:
>      new 49cc844  'fakeroot' is no longer optional, but required, when making deb/dpkg
so no need to worry about the old hack and seeing if we have fakeroot.
> 49cc844 is described below
>
> commit 49cc8443e2aaa7c02ddd1611e7be852fd90266a6
> Author: Jim Jagielski <jimjag@gmail.com>
> AuthorDate: Wed Dec 30 11:06:33 2020 -0500
>
>     'fakeroot' is no longer optional, but required, when making deb/dpkg
>     so no need to worry about the old hack and seeing if we have
>     fakeroot.
> ---
>  main/solenv/bin/modules/installer/download.pm | 24 +++---------------------
>  main/solenv/bin/modules/installer/epmfile.pm  | 27 ++++-----------------------
>  main/solenv/bin/modules/installer/worker.pm   | 16 ++--------------
>  main/sysui/desktop/debian/makefile.mk         | 10 ++--------
>  4 files changed, 11 insertions(+), 66 deletions(-)
>
> diff --git a/main/solenv/bin/modules/installer/download.pm b/main/solenv/bin/modules/installer/download.pm
> index 573d546..05f9237 100644
> --- a/main/solenv/bin/modules/installer/download.pm
> +++ b/main/solenv/bin/modules/installer/download.pm
> @@ -302,13 +302,7 @@ sub tar_package
>  {
>  	my ( $installdir, $tarfilename, $getuidlibrary) = @_;
>  
> -	my $ldpreloadstring = "";
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -	} else {
> -		if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; }
> -	}
> +	my $ldpreloadstring = $ENV{'FAKEROOT'};
>  
>  	my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - * > $tarfilename";
>  	
> @@ -373,13 +367,7 @@ sub create_tar_gz_file_from_package
>  	my $targzname = $packagename . $installer::globals::downloadfileextension;
>  	$installer::globals::downloadfilename = $targzname;
>  
> -	my $ldpreloadstring = "";
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -	} else {
> -		if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; }
> -	}
> +	my $ldpreloadstring = $ENV{'FAKEROOT'};
>  
>  	my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - $packagename | gzip >
$targzname";
>  	$installer::logger::Info->printf("... %s ...\n", $systemcall);
> @@ -798,13 +786,7 @@ sub create_tar_gz_file_from_directory
>  	my $changedir = $installdir;
>  	installer::pathanalyzer::get_path_from_fullqualifiedname(\$changedir);
>  
> -	my $ldpreloadstring = "";
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -	} else {
> -		if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; }
> -	}
> +	my $ldpreloadstring = $ENV{'FAKEROOT'};
>  
>  	$installer::globals::downloadfileextension = ".tar.gz";
>  	$installer::globals::downloadfilename = $downloadfilename . $installer::globals::downloadfileextension;
> diff --git a/main/solenv/bin/modules/installer/epmfile.pm b/main/solenv/bin/modules/installer/epmfile.pm
> index c7f9860..d33ffcd 100644
> --- a/main/solenv/bin/modules/installer/epmfile.pm
> +++ b/main/solenv/bin/modules/installer/epmfile.pm
> @@ -885,26 +885,7 @@ sub set_patch_state
>  
>  sub get_ld_preload_string
>  {
> -	my ($includepatharrayref) = @_;
> -
> -	my $getuidlibraryname = "getuid.so";
> -
> -	my $ldpreloadstring;
> -
> -	my $getuidlibraryref = installer::scriptitems::get_sourcepath_from_filename_and_includepath(\$getuidlibraryname,
$includepatharrayref, 0);
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -
> -	} else {
> -
> -		if ($$getuidlibraryref eq "") { installer::exiter::exit_program("ERROR: Could not
find $getuidlibraryname!", "get_ld_preload_string"); }
> -
> -		my $ldpreloadstring = "LD_PRELOAD=" . $$getuidlibraryref;
> -	}
> -	
> -	return $ldpreloadstring;
> +	return $ENV{'FAKEROOT'};
>  }
>  
>  #################################################
> @@ -926,15 +907,15 @@ sub call_epm
>  	my $outdirstring = "";
>  	if ( $installer::globals::epmoutpath ne "" ) { $outdirstring = " --output-dir $installer::globals::epmoutpath";
}
>  	
> -	# Debian package build needs fakeroot or our LD_PRELOAD hack for correct rights
> +	# Debian package build needs fakeroot which we check for at configure time
>  	# NOTE: EPM 5.0.0 or later also uses fakeroot w/ dpkg if available
>  	
>  	my $ldpreloadstring = "";
>  	
> -	if ( $installer::globals::debian ) { $ldpreloadstring = get_ld_preload_string($includepatharrayref)
. " "; }
> +	if ( $installer::globals::debian ) { $ldpreloadstring = get_ld_preload_string() . "
"; }
>  
>  	my $extraflags = "";
> -        if ($ENV{'EPM_FLAGS'}) { $extraflags = $ENV{'EPM_FLAGS'}; }
> +    if ($ENV{'EPM_FLAGS'}) { $extraflags = $ENV{'EPM_FLAGS'}; }
>  
>      my $verboseflag = "-v";
>      if ( ! $installer::globals::quiet ) { $verboseflag = "-v2"; };
> diff --git a/main/solenv/bin/modules/installer/worker.pm b/main/solenv/bin/modules/installer/worker.pm
> index 413095e..d745209 100644
> --- a/main/solenv/bin/modules/installer/worker.pm
> +++ b/main/solenv/bin/modules/installer/worker.pm
> @@ -3198,13 +3198,7 @@ sub tar_package
>  {
>  	my ( $installdir, $packagename, $tarfilename, $getuidlibrary) = @_;
>  
> -	my $ldpreloadstring = "";
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -	} else {
> -		if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; }
> -	}
> +	my $ldpreloadstring = $ENV{'FAKEROOT'};
>  
>  	my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - $packagename > $tarfilename";
>  	# my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - * > $tarfilename";
> @@ -3242,13 +3236,7 @@ sub untar_package
>  {
>  	my ( $installdir, $tarfilename, $getuidlibrary) = @_;
>  
> -	my $ldpreloadstring = "";
> -
> -	if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) {
> -		$ldpreloadstring = $ENV{'FAKEROOT'};
> -	} else {
> -		if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; }
> -	}
> +	my $ldpreloadstring = $ENV{'FAKEROOT'};
>  
>  	my $systemcall = "cd $installdir; $ldpreloadstring tar -xf $tarfilename";
>  	
> diff --git a/main/sysui/desktop/debian/makefile.mk b/main/sysui/desktop/debian/makefile.mk
> index a60050b..982b22d 100644
> --- a/main/sysui/desktop/debian/makefile.mk
> +++ b/main/sysui/desktop/debian/makefile.mk
> @@ -45,12 +45,6 @@ DEBFILES=$(foreach,i,{$(PRODUCTLIST)} $(PKGDIR)$/$i4.2-$(TARGET)-menus_$(PKGVERS
>  
>  .ENDIF
>  
> -.IF "$(FAKEROOT)"!="no"
> -FAKEROOT2="$(FAKEROOT)"
> -.ELSE
> -FAKEROOT2="LD_PRELOAD=$(SOLARBINDIR)/getuid.so"
> -.ENDIF
> -
>  # --- Targets -------------------------------------------------------
>  
>  .INCLUDE :  target.mk
> @@ -81,7 +75,7 @@ ALLTAR : $(DEBFILES)
>  
>  # --- packaging ---------------------------------------------------
>  
> -# getuid.so fakes the user/group for us	
> +# fakeroot (which is required and checked for at configure time) fakes the user/group
for us
>  $(DEBFILES) : $(COMMONMISC)$/{$(PRODUCTLIST)}$/build.flag
>  $(DEBFILES) : makefile.mk control postinst postrm prerm
>  	-$(RM) $(@:d)$(@:f:s/_/ /:1)_*
> @@ -91,7 +85,7 @@ $(DEBFILES) : makefile.mk control postinst postrm prerm
>  	@chmod a+rx $(MISC)$/$(@:b)$/DEBIAN $(MISC)/$(@:b)/DEBIAN/post* $(MISC)/$(@:b)/DEBIAN/pre*
>  	@chmod g-s $(MISC)/$(@:b)/DEBIAN
>  	@mkdir -p $(PKGDIR)
> -	/bin/bash -c "$(FAKEROOT2) dpkg-deb --build $(MISC)/$(@:b) $@" 
> +	/bin/bash -c "$(FAKEROOT) dpkg-deb --build $(MISC)/$(@:b) $@"
>  	$(RM) -r $(MISC)$/$(@:b)
>  #	@chmod -R g+w $(MISC)/$(TARGET)/$(DEBFILE:f)
>  
>


Mime
View raw message