On Tue, Feb 28, 2023 at 07:17:50AM +0100, Otto Moerbeek wrote: > I have no problem removing the mruby flavor of h2o. I hope to be able > to do that soon.
Here you go. -Otto Index: Makefile =================================================================== RCS file: /home/cvs/ports/www/h2o/Makefile,v retrieving revision 1.14 diff -u -p -r1.14 Makefile --- Makefile 7 Jan 2023 20:05:13 -0000 1.14 +++ Makefile 28 Feb 2023 07:17:36 -0000 @@ -21,13 +21,6 @@ WANTLIB += ${COMPILER_LIBCXX} c crypto m # uses TLS COMPILER = base-clang ports-gcc -FLAVORS = mruby -FLAVOR ?= - -.if ${FLAVOR:Mmruby} -BROKEN-arm = SIGBUS in mruby build -.endif - MODULES = devel/cmake BUILD_DEPENDS = devel/bison @@ -37,22 +30,6 @@ CONFIGURE_ARGS = -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_SYSCONFDIR=${SYSCONFDIR}/h2o \ -DWITH_BUNDLED_SSL=OFF \ -DWITH_PICOTLS=OFF - -.if ${FLAVOR:Mmruby} -MODULES += lang/ruby -MODRUBY_RUNDEP = No -CONFIGURE_ARGS += -DWITH_MRUBY=ON -# mruby build picks up the static oniguruma library if present during build -# otherwise uses a bundled older version -BUILD_DEPENDS += textproc/oniguruma -MAKE_ENV += AWK=/usr/bin/awk \ - SED=/usr/bin/sed \ - GREP=/usr/bin/grep \ - ac_cv_path_mkdir=/bin/mkdir - -pre-configure: - ln -sf ${RUBY} ${WRKDIR}/bin/ruby -.endif post-install: cd ${WRKSRC}/doc; pax -rw [a-z]* ${PREFIX}/share/doc/h2o/ Index: patches/patch-CMakeLists_txt =================================================================== RCS file: /home/cvs/ports/www/h2o/patches/patch-CMakeLists_txt,v retrieving revision 1.3 diff -u -p -r1.3 patch-CMakeLists_txt --- patches/patch-CMakeLists_txt 2 Sep 2022 13:18:16 -0000 1.3 +++ patches/patch-CMakeLists_txt 28 Feb 2023 07:17:36 -0000 @@ -45,27 +45,3 @@ Index: CMakeLists.txt IF (ZLIB_FOUND) INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIRS}) -@@ -460,14 +460,21 @@ IF (WITH_MRUBY) - ELSE () - SET(MRUBY_TOOLCHAIN "gcc") - ENDIF () -- ADD_CUSTOM_TARGET(mruby MRUBY_TOOLCHAIN=${MRUBY_TOOLCHAIN} MRUBY_CONFIG=${CMAKE_CURRENT_SOURCE_DIR}/misc/mruby_config.rb MRUBY_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}/mruby ruby minirake -- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/deps/mruby) -+ ADD_CUSTOM_TARGET(mruby -+ # deps/mruby/tasks/toolchains/clang.rake looks for CC, CXX and LD. -+ # There are no C++ files in deps/mruby, use the C compiler for linking. -+ MRUBY_TOOLCHAIN=${MRUBY_TOOLCHAIN} CC=${CMAKE_C_COMPILER} CXX=${CMAKE_CXX_COMPILER} LD=${CMAKE_C_COMPILER} MRUBY_CONFIG=${CMAKE_CURRENT_SOURCE_DIR}/misc/mruby_config.rb MRUBY_BUILD_DIR=${CMAKE_CURRENT_BINARY_DIR}/mruby MRUBY_ADDITIONAL_CONFIG=${MRUBY_ADDITIONAL_CONFIG} ruby minirake -+ WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/deps/mruby -+ BYPRODUCTS "${CMAKE_CURRENT_BINARY_DIR}/mruby/host/lib/libmruby.a" -+ "${CMAKE_CURRENT_BINARY_DIR}/mruby/host/mrbgems/mruby-onig-regexp/onigmo-6.1.1/.libs/libonigmo.a" -+ ) - LIST(APPEND STANDALONE_SOURCE_FILES - lib/handler/mruby.c - lib/handler/mruby/chunked.c - lib/handler/mruby/http_request.c - lib/handler/configurator/mruby.c) - SET(STANDALONE_COMPILE_FLAGS "${STANDALONE_COMPILE_FLAGS} -DH2O_USE_MRUBY=1") -+ SET_PROPERTY(DIRECTORY PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${CMAKE_CURRENT_BINARY_DIR}/mruby/) - ENDIF (WITH_MRUBY) - IF (WITH_PICOTLS) - LIST(APPEND STANDALONE_SOURCE_FILES ${PICOTLS_SOURCE_FILES}) Index: patches/patch-deps_mruby_Rakefile =================================================================== RCS file: patches/patch-deps_mruby_Rakefile diff -N patches/patch-deps_mruby_Rakefile --- patches/patch-deps_mruby_Rakefile 11 Mar 2022 20:09:54 -0000 1.2 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,66 +0,0 @@ -Fix build with Ruby 3.0. - -Index: deps/mruby/Rakefile ---- deps/mruby/Rakefile.orig -+++ deps/mruby/Rakefile -@@ -37,15 +37,15 @@ load "#{MRUBY_ROOT}/tasks/gitlab.rake" - task :default => :all - - bin_path = ENV['INSTALL_DIR'] || "#{MRUBY_ROOT}/bin" --FileUtils.mkdir_p bin_path, { :verbose => $verbose } -+FileUtils.mkdir_p bin_path, :verbose => $verbose - - depfiles = MRuby.targets['host'].bins.map do |bin| - install_path = MRuby.targets['host'].exefile("#{bin_path}/#{bin}") - source_path = MRuby.targets['host'].exefile("#{MRuby.targets['host'].build_dir}/bin/#{bin}") - - file install_path => source_path do |t| -- FileUtils.rm_f t.name, { :verbose => $verbose } -- FileUtils.cp t.prerequisites.first, t.name, { :verbose => $verbose } -+ FileUtils.rm_f t.name, :verbose => $verbose -+ FileUtils.cp t.prerequisites.first, t.name, :verbose => $verbose - end - - install_path -@@ -78,8 +78,8 @@ MRuby.each_target do |target| - install_path = MRuby.targets['host'].exefile("#{bin_path}/#{bin}") - - file install_path => exec do |t| -- FileUtils.rm_f t.name, { :verbose => $verbose } -- FileUtils.cp t.prerequisites.first, t.name, { :verbose => $verbose } -+ FileUtils.rm_f t.name, :verbose => $verbose -+ FileUtils.cp t.prerequisites.first, t.name, :verbose => $verbose - end - depfiles += [ install_path ] - elsif target == MRuby.targets['host-debug'] -@@ -87,8 +87,8 @@ MRuby.each_target do |target| - install_path = MRuby.targets['host-debug'].exefile("#{bin_path}/#{bin}") - - file install_path => exec do |t| -- FileUtils.rm_f t.name, { :verbose => $verbose } -- FileUtils.cp t.prerequisites.first, t.name, { :verbose => $verbose } -+ FileUtils.rm_f t.name, :verbose => $verbose -+ FileUtils.cp t.prerequisites.first, t.name, :verbose => $verbose - end - depfiles += [ install_path ] - end -@@ -127,16 +127,16 @@ end - desc "clean all built and in-repo installed artifacts" - task :clean do - MRuby.each_target do |t| -- FileUtils.rm_rf t.build_dir, { :verbose => $verbose } -+ FileUtils.rm_rf t.build_dir, :verbose => $verbose - end -- FileUtils.rm_f depfiles, { :verbose => $verbose } -+ FileUtils.rm_f depfiles, :verbose => $verbose - puts "Cleaned up target build folder" - end - - desc "clean everything!" - task :deep_clean => ["clean"] do - MRuby.each_target do |t| -- FileUtils.rm_rf t.gem_clone_dir, { :verbose => $verbose } -+ FileUtils.rm_rf t.gem_clone_dir, :verbose => $verbose - end - puts "Cleaned up mrbgems build folder" - end Index: pkg/DESCR =================================================================== RCS file: /home/cvs/ports/www/h2o/pkg/DESCR,v retrieving revision 1.2 diff -u -p -r1.2 DESCR --- pkg/DESCR 7 Jan 2020 10:18:30 -0000 1.2 +++ pkg/DESCR 28 Feb 2023 07:17:36 -0000 @@ -3,6 +3,3 @@ users with less CPU utilization when com servers. Designed from ground-up, the server takes full advantage of HTTP/2 features including prioritized content serving and server push, promising outstanding experience to the visitors of your web site. - -Flavors: - mruby - build the standalone server with support for mruby scripting Index: pkg/PFRAG.mruby =================================================================== RCS file: pkg/PFRAG.mruby diff -N pkg/PFRAG.mruby --- pkg/PFRAG.mruby 2 Sep 2022 13:18:16 -0000 1.3 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ -share/examples/h2o/h2o_mruby/ -share/examples/h2o/h2o_mruby/h2o.conf -share/examples/h2o/h2o_mruby/hello.rb -share/h2o/mruby/ -share/h2o/mruby/acl.rb -share/h2o/mruby/bootstrap.rb -share/h2o/mruby/dos_detector.rb -share/h2o/mruby/htpasswd.rb -share/h2o/mruby/lru_cache.rb -share/h2o/mruby/preloads.rb -share/h2o/mruby/trie_addr.rb