LoginSignup
2
1

gcc の簡単な更新方法

Posted at

なぜ更新しようと思ったか

競プロ(Atcoder)の環境はgcc12.2である。
しかし自分の環境はmingw installation managerで構築した古い環境であり、使える標準ライブラリが一致せず不便なため。

環境・日時

Windows 11・2024/03/14

更新した方法

  1. ダウンロードに行く
  2. Mingw-buildsのGitHubをクリック
  3. Release of 12.2.0-rt_v10-rev2をクリック
  4. x86_64-12.2.0-release-win32-seh-ucrt-rt_v10-rev2.7zをダウンロード
  5. 7-zipで解凍する
  6. 解凍して出てきたmingw64をCドライブのprogram Filesに移動させる
  7. 用意した /mingw64/bin を環境変数に設定する

vscode上の設定

  1. ctrl + shift + p を押して"C/C++ Edit Configuration UI"を選択
  2. 以下の項目を変更
    • コンパイラパス: bin内のgccのパスを設定
    • c++ 標準: C++20にする
2
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
1