1

i686-w64-mingw32-g++ コンパイラを使用して、Linux から Windows 用の単純なチャイスクリプトの例をコンパイルしようとしています。g ++で動作するように既に取得していますが、コマンドを使用してアプリをコンパイルするとき

i686-w64-mingw32-g++ ./main.cpp -pthread -L/lib/x86_64-linux-gnu/libdl.a -std=c++17

そして、これがmain.cppの内容です

#include "chaiscript/chaiscript.hpp"
#include "chaiscript/chaiscript_stdlib.hpp"

int main()
{
  chaiscript::ChaiScript chai;

  chai.eval(R"(puts("Hello"))");
}

これは私に与えるエラーです

コードをコンパイルできるように、このエラーを修正するにはどうすればよいですか?


編集:
i686-w64-mingw32-g++ の代わりに x86_64-w64-mingw32-g++ を使用してさらに先に進むことができましたが、現在、次のエラーが発生しています:
/usr/bin/x86_64-w64-mingw32-as: /tmp/ccE1ZcKe.o: too many sections (73147)
/tmp/ccwlaMBb.s: Assembler messages:
/tmp/ccwlaMBb.s: Fatal error: can't write 41 bytes to section .text of /tmp/ccE1ZcKe.o: 'file too big'
/usr/bin/x86_64-w64-mingw32-as: /tmp/ccE1ZcKe.o: too many sections (73147)
/tmp/ccwlaMBb.s: Fatal error: can't close /tmp/ccE1ZcKe.o: file too big
4

2 に答える 2