download.pm (dfe9974f) | download.pm (49cc8443) |
---|---|
1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 288 unchanged lines hidden (view full) --- 297######################################################### 298# Create a tar file from the binary package 299######################################################### 300 301sub tar_package 302{ 303 my ( $installdir, $tarfilename, $getuidlibrary) = @_; 304 | 1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 288 unchanged lines hidden (view full) --- 297######################################################### 298# Create a tar file from the binary package 299######################################################### 300 301sub tar_package 302{ 303 my ( $installdir, $tarfilename, $getuidlibrary) = @_; 304 |
305 my $ldpreloadstring = ""; | 305 my $ldpreloadstring = $ENV{'FAKEROOT'}; |
306 | 306 |
307 if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) { 308 $ldpreloadstring = $ENV{'FAKEROOT'}; 309 } else { 310 if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; } 311 } 312 | |
313 my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - * > $tarfilename"; 314 315 my $returnvalue = system($systemcall); 316 317 $installer::logger::Lang->printf("Systemcall: %s\n", $systemcall); 318 319 if ($returnvalue) 320 { --- 47 unchanged lines hidden (view full) --- 368 if ( $packagename eq "" ) { installer::exiter::exit_program("ERROR: Could not find package in directory $installdir!", "determine_packagename"); } 369 370 installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$packagename); 371 372 $installer::globals::downloadfileextension = ".tar.gz"; 373 my $targzname = $packagename . $installer::globals::downloadfileextension; 374 $installer::globals::downloadfilename = $targzname; 375 | 307 my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - * > $tarfilename"; 308 309 my $returnvalue = system($systemcall); 310 311 $installer::logger::Lang->printf("Systemcall: %s\n", $systemcall); 312 313 if ($returnvalue) 314 { --- 47 unchanged lines hidden (view full) --- 362 if ( $packagename eq "" ) { installer::exiter::exit_program("ERROR: Could not find package in directory $installdir!", "determine_packagename"); } 363 364 installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$packagename); 365 366 $installer::globals::downloadfileextension = ".tar.gz"; 367 my $targzname = $packagename . $installer::globals::downloadfileextension; 368 $installer::globals::downloadfilename = $targzname; 369 |
376 my $ldpreloadstring = ""; | 370 my $ldpreloadstring = $ENV{'FAKEROOT'}; |
377 | 371 |
378 if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) { 379 $ldpreloadstring = $ENV{'FAKEROOT'}; 380 } else { 381 if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; } 382 } 383 | |
384 my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - $packagename | gzip > $targzname"; 385 $installer::logger::Info->printf("... %s ...\n", $systemcall); 386 387 my $returnvalue = system($systemcall); 388 389 $installer::logger::Lang->printf("Systemcall: %s\n", $systemcall); 390 391 if ($returnvalue) --- 401 unchanged lines hidden (view full) --- 793{ 794 my ($installdir, $getuidlibrary, $downloaddir, $downloadfilename) = @_; 795 796 my $packdir = $installdir; 797 installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$packdir); 798 my $changedir = $installdir; 799 installer::pathanalyzer::get_path_from_fullqualifiedname(\$changedir); 800 | 372 my $systemcall = "cd $installdir; $ldpreloadstring tar -cf - $packagename | gzip > $targzname"; 373 $installer::logger::Info->printf("... %s ...\n", $systemcall); 374 375 my $returnvalue = system($systemcall); 376 377 $installer::logger::Lang->printf("Systemcall: %s\n", $systemcall); 378 379 if ($returnvalue) --- 401 unchanged lines hidden (view full) --- 781{ 782 my ($installdir, $getuidlibrary, $downloaddir, $downloadfilename) = @_; 783 784 my $packdir = $installdir; 785 installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$packdir); 786 my $changedir = $installdir; 787 installer::pathanalyzer::get_path_from_fullqualifiedname(\$changedir); 788 |
801 my $ldpreloadstring = ""; | 789 my $ldpreloadstring = $ENV{'FAKEROOT'}; |
802 | 790 |
803 if (($ENV{'FAKEROOT'} ne "no") && ($ENV{'FAKEROOT'} ne "")) { 804 $ldpreloadstring = $ENV{'FAKEROOT'}; 805 } else { 806 if ( $getuidlibrary ne "" ) { $ldpreloadstring = "LD_PRELOAD=" . $getuidlibrary; } 807 } 808 | |
809 $installer::globals::downloadfileextension = ".tar.gz"; 810 $installer::globals::downloadfilename = $downloadfilename . $installer::globals::downloadfileextension; 811 my $targzname = $downloaddir . $installer::globals::separator . $installer::globals::downloadfilename; 812 813 my $systemcall = "cd $changedir; $ldpreloadstring tar -cf - $packdir | gzip > $targzname"; 814 815 my $returnvalue = system($systemcall); 816 --- 1237 unchanged lines hidden --- | 791 $installer::globals::downloadfileextension = ".tar.gz"; 792 $installer::globals::downloadfilename = $downloadfilename . $installer::globals::downloadfileextension; 793 my $targzname = $downloaddir . $installer::globals::separator . $installer::globals::downloadfilename; 794 795 my $systemcall = "cd $changedir; $ldpreloadstring tar -cf - $packdir | gzip > $targzname"; 796 797 my $returnvalue = system($systemcall); 798 --- 1237 unchanged lines hidden --- |