Thứ Ba, 22 tháng 5, 2012

Một số lỗi khi tạo project wxWiget với Codelite trên linux


1. Lỗi .
 wx/wx.h: No such file or directory
........................
(etc)
 Để giải quyết lỗi này chỉ cần chạy lệnh sau
ln -s /usr/lib/wx/include/gtk2ud-2.5/wx/setup.h /usr/include/"your wx version"/wx/setup.h
 Thay "your wx version" bẳng tên thư mục wx tương ứng của bạn. ví dụ như của tôi là wx-2.8 thì lệnh sẽ như sau

ln -s /usr/lib/wx/include/gtk2ud-2.5/wx/setup.h /usr/include/wx-2.8/wx/setup.h


 2. Lỗi
#error "No Target! You should use wx-config program for compilation flags!"

 Lỗi này do chưa cài gói debug cho wxWiget.
có 3 cách giải quyết:
- Biên dịch ở chế độ Release
- cài thêm Wx ở chế độ debug (trên ubuntu: sudo apt-get install libwxgtk2.8-dbg)
- bỏ tùy chọn --debug=yes trong compiler optionlinker option (click chuột phải vào project --> Setting)

Không có nhận xét nào:

Đăng nhận xét