無法開啟檔案“libboost_filesystem-vc140-mt-sgd-1_61.lib”

來源:互聯網
上載者:User

問題1:無法開啟檔案“libboost_filesystem-vc140-mt-sgd-1_61.lib”. 參考 重新編譯Boost

  b2 stage  architecture=x86 address-model=64  link=static runtime-link=static threading=multi debug release

選項說明

link=static/shared,靜態或者動態編譯boost
runtime-link=static/shared,boost是否需要依賴vc運行庫,如果你要內建vc運行庫可用shared
threading=multi/single,是否支援多線程
在一個vs版本的的情況下可以直接b2 –toolset=msvc
多個的話需要指定vs版本號碼b2 –toolset=msvc-12.0
產生的檔案名稱:libboost_log-vc120-mt-sgd-1_59.lib,其中mt表示多線程。

編譯Python版Boost庫
(此處以anaconda的python3.5為例) 運行boostrap.bat 產生 b2.exe和bjam.exe檔案 編輯project-config.jam

    import option ;     using msvc ;     using python     : 3.5     : "C:\\Program Files\\Anaconda3"    : "C:\\Program Files\\Anaconda3\\include"    : "C:\\Program Files\\Anaconda3\\libs"    ;    option.set keep-going : false ; 
產生debug版
bjam --with-python --prefix=d:\boost stage toolset=msvc-10.0 variant=debug link=shared address-model=64 threading=multi runtime-link=shared install
產生Release版
bjam --with-python --prefix=d:\boost stage toolset=msvc-10.0 variant=release link=shared address-model=64 threading=multi runtime-link=shared install
按照官方的方法產生dll並將對應檔案尾碼改為pyd

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.