mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-09 15:37:56 -05:00
* rebuild bison,sed; update cpio * add strace * expand comment * add gpgme, putty * update tre * update elinks * deprecate js91 * rebuild anagram, update libgudev & upower * rebuild openjpeg * update libdeflate * update openexr * remove ilmbase deps (replaced by openexr) * deprecate ilmbase * rebuild gegl with newer openexr * update R * libjxl rebuild * graphviz => 9 * update gdal * imagemagick7 update * gimp rebuild * suggested changes * Add pre_ options to cmake and meson buildsystems * suggested changes * reversion gegl * update gdal url * redo versions * update py3_numpy * update openblas, mold * remove 'pre_' empty? checks in buildsystems * rebuild rust to fix binary issues on x86_64 * fixup missing rust completions
23 lines
877 B
Ruby
23 lines
877 B
Ruby
require 'package'
|
|
|
|
class CMake < Package
|
|
property :cmake_options, :pre_cmake_options
|
|
|
|
def self.build
|
|
puts "Additional cmake_options being used: #{@pre_cmake_options.nil? ? '<no pre_cmake_options>' : @pre_cmake_options} #{@cmake_options.nil? ? '<no cmake_options>' : @cmake_options}".orange
|
|
@crew_cmake_options = @no_lto ? CREW_CMAKE_FNO_LTO_OPTIONS : CREW_CMAKE_OPTIONS
|
|
@mold_linker_prefix_cmd = CREW_LINKER == 'mold' ? 'mold -run' : ''
|
|
system "#{@pre_cmake_options} #{@mold_linker_prefix_cmd} cmake -B builddir -G Ninja #{@crew_cmake_options} #{@cmake_options}"
|
|
system "#{CREW_NINJA} -C builddir"
|
|
end
|
|
|
|
def self.install
|
|
system "DESTDIR=#{CREW_DEST_DIR} #{CREW_NINJA} -C builddir install"
|
|
end
|
|
|
|
def self.check
|
|
puts "Testing with #{CREW_NINJA} test.".orange if @run_tests
|
|
system "#{CREW_NINJA} -C builddir test" if @run_tests
|
|
end
|
|
end
|