網頁

2014年4月19日 星期六

C++ vector 與 memory

Last Update: 2014/04/20 13:29+08


Intro

關於vector 與 memory 使用注意事項


2014年4月8日 星期二

gcc/g++ in Windows - MinGW & Cygwin

Last Update: 2014/04/09 09:35+08
Type: Note



---MinGW---

Download
官網(http://www.mingw.org/)下載 MinGW installer

Install
選擇要安裝的資料夾(避免空白和符號)
在選擇 package 時, 將 [Basic Setup] 全部 mark 起來
> Apply Changes

Set Environment Variables
/bin 加入 環境變數中的 PATH

Eclipse > Project > 右鍵 Properties
> C/C++ General
> Paths and Symbols
> Include
> 在 GNU C Or GNU C++ 加入 <install dir>/include
> 在 Library Paths 加入 <install dir>/lib



---Cygwin---

Download
官網(http://cygwin.com/install.html)下載 Cygwin installer

Install
> 照指示安裝
    過程中有 Local Package Directory, 會把安裝檔載在這, 下次安裝就不用再次下載
> Select Packages 時, 搜尋 "gcc-g++"
     安裝 Devel 裡的
     cygwin32-gcc-g++: GCC for Cygwin 32 bit toolchain (C++)
     gcc-g++: GNU Compiler Collection (C++)
     [無效]cmake: Cross-platform makefile generation system
     make: The GNU version of the 'make' utility

Set Windows Environment Variables
新增 CYGWIN_HOME=<install dir>
PATH加入 %CYGWIN_HOME%/bin