Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Emscripten compilation issue

オープン
#44 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
cpp, wasm
領域
build-system

調査の方向性

include/boost/numeric/interval/hw_rounding.hpp と include/boost/config/platform/wasm.hpp から始め、BOOST_NO_FENV_H が Emscripten ツールチェーン向けの丸め実装をどのように選択するかを調べます。Emscripten 3.1.51 で Boost 1.82.0 のビルドを再現し、C99 実装と失敗しているパスを比較します。ライブラリが報告されたローカルパッチなしでビルドでき、結果として得られる動作が検証されれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Hello!
I might do something wrong, but I had to apply the following patch to the boost interval library (v1.82.0) in order to build it successfully using the emscripten toolchain (v3.1.51).

diff --git a/include/boost/numeric/interval/hw_rounding.hpp b/include/boost/numeric/interval/hw_rounding.hpp
index 46d452e..4211079 100644
--- a/include/boost/numeric/interval/hw_rounding.hpp
+++ b/include/boost/numeric/interval/hw_rounding.hpp
@@ -16,6 +16,7 @@
 #include <boost/numeric/interval/rounded_arith.hpp>

 #define BOOST_NUMERIC_INTERVAL_NO_HARDWARE
+#undef BOOST_NO_FENV_H

 // define appropriate specialization of rounding_control for built-in types
 #if defined(__x86_64__) && !defined(BOOST_NO_FENV_H)

This reverts to the c99 impl, which builds and works fine as far I can tell.
From what I gathered, the definition of BOOST_NO_FENV_H occurs in include/boost/config/platform/wasm.hpp:23 and commenting it out also fixes the issue.
This is, however, very hacky and I was wondering if there way a cleaner way to achieve the same results.

主要言語
C++
スター
31
フォーク
49
平均マージ
1日 13時間
マージ済み PR(30日)
6

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

boostorg/interval のほかの issue

boostorg/interval の issue をすべて見る

似ている issue

C++ の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。