Add perl buildsystem (#8994)

* Add perl buildsystem

* avoid conflict between perl and buildsystem

* build perl_xml_parser

* rebuild remaining perl packages with files in 5.38.0 dir

* bump version

* suggested changes

* suggested changes
This commit is contained in:
Satadru Pramanik, DO, MPH, MEng
2023-11-26 21:39:23 -05:00
committed by GitHub
parent 37380bf7d5
commit c583f2eca3
46 changed files with 755 additions and 863 deletions

20
lib/buildsystems/perl.rb Normal file
View File

@@ -0,0 +1,20 @@
require 'package'
class PERL < Package
property :pre_perl_options
def self.prebuild
puts "Additional pre_perl_options being used: #{@pre_perl_options.nil? ? '<no pre_perl_options>' : @pre_perl_options}".orange
system "#{@pre_perl_options} perl Makefile.PL"
system "sed -i 's,/usr/local,#{CREW_PREFIX},g' Makefile"
end
def self.build
@mold_linker_prefix_cmd = CREW_LINKER == 'mold' ? 'mold -run' : ''
system "#{@pre_perl_options} #{@mold_linker_prefix_cmd} make"
end
def self.install
system 'make', "DESTDIR=#{CREW_DEST_DIR}", 'install'
end
end