Ticket #27566: patch-install.rb.diff

File patch-install.rb.diff, 1.5 KB (added by nigel@…, 14 years ago)
  • install.rb

    old new  
    204204    opts.on('--[no-]tests', 'Prevents the execution of unit tests.', 'Default on.') do |ontest|
    205205      InstallOptions.tests = ontest
    206206    end
    207     opts.on('--[no-]configs', 'Prevents the installation of config files', 'Default off.') do |ontest|
    208       InstallOptions.configs = ontest
     207    opts.on('--[no-]configs', 'Prevents the installation of config files', 'Default off.') do |onconfigs|
     208      InstallOptions.configs = onconfigs
    209209    end
    210210    opts.on('--destdir[=OPTIONAL]', 'Installation prefix for all targets', 'Default essentially /') do |destdir|
    211211      InstallOptions.destdir = destdir
     
    300300    mandir = Config::CONFIG['mandir']
    301301  end
    302302
    303   # To be deprecated once people move over to using --destdir option
    304   if (destdir = ENV['DESTDIR'])
    305     configdir = "#{destdir}#{configdir}"
    306     bindir = "#{destdir}#{bindir}"
    307     sbindir = "#{destdir}#{sbindir}"
    308     mandir = "#{destdir}#{mandir}"
    309     sitelibdir = "#{destdir}#{sitelibdir}"
    310 
    311     FileUtils.makedirs(configdir) if InstallOptions.configs
    312     FileUtils.makedirs(bindir)
    313     FileUtils.makedirs(sbindir)
    314     FileUtils.makedirs(mandir)
    315     FileUtils.makedirs(sitelibdir)
    316   # This is the new way forward
    317   elsif (destdir = InstallOptions.destdir)
     303  if (destdir = InstallOptions.destdir)
    318304    configdir = "#{destdir}#{configdir}"
    319305    bindir = "#{destdir}#{bindir}"
    320306    sbindir = "#{destdir}#{sbindir}"