【GUI编程之准备--1】MAC 编译wxWidgets 源码
2013-10-18 14:24
405 查看
下载wxwidgets进行源码编译
IOS: mac 10.8.2
wx: 2.9.5 (http://www.wxwidgets.org/downloads/)
gcc: i686-apple-darwin11-llvm-gcc-4.2 (xCode) ($gcc 查看)
步骤:
a. 使用终端,进入源码目录
创建自己可识别的文件夹cocoabuildwx,进入目录
$mkdir cocoabuild
$cd cocoabuild
b.指定使用编译的CPU架构,我用的是x86_64($uname -a查看)
c.变更一些参数
$../configure --with-cocoa --disable-shared CFLAGS="$arch_flags" CXXFLAGS="$arch_flags" CPPFALGS="$arch_flags" LDFLAGS="$arch_flags"
d.
$make
f.
编译例子【可以不选择编译】
$cd samples
$pwd
/Users/shelley/Downloads/wxWidgets-2.9.5/cocoabuildwx/samples
$make
例子编译完成之后,即可运行。
经过以上步骤,我们把下载的源文件,都已经编译为可执行文件.o 可以在./cocoabuildwx/lib 文件夹下看到我们所需要的静态链接库和与此库对应的setup.h
IOS: mac 10.8.2
wx: 2.9.5 (http://www.wxwidgets.org/downloads/)
gcc: i686-apple-darwin11-llvm-gcc-4.2 (xCode) ($gcc 查看)
步骤:
a. 使用终端,进入源码目录
创建自己可识别的文件夹cocoabuildwx,进入目录
$mkdir cocoabuild
$cd cocoabuild
b.指定使用编译的CPU架构,我用的是x86_64($uname -a查看)
c.变更一些参数
$../configure --with-cocoa --disable-shared CFLAGS="$arch_flags" CXXFLAGS="$arch_flags" CPPFALGS="$arch_flags" LDFLAGS="$arch_flags"
d.
$make
f.
编译例子【可以不选择编译】
$cd samples
$pwd
/Users/shelley/Downloads/wxWidgets-2.9.5/cocoabuildwx/samples
$make
例子编译完成之后,即可运行。
经过以上步骤,我们把下载的源文件,都已经编译为可执行文件.o 可以在./cocoabuildwx/lib 文件夹下看到我们所需要的静态链接库和与此库对应的setup.h
相关文章推荐
- C# Dictionary<TKey, TValue>的学习
- iOS学习:UILabel和sizeWithFont方法,可用于动态调整UILabel大小
- iOS学习:UILabel和sizeWithFont方法,可用于动态调整UILabel大小
- NGUI系列教程四(自定义Atlas,Font)
- Knockout.Js官网学习(selectedOptions绑定、uniqueName 绑定)
- android SystemUI 流程分析
- JetBrains WebStorm 7.0 Build 131.202 Win/Mac/Liniux
- 关于master..spt_values的应用帖子
- getRequestDispatcher()与sendRedirect()区别
- EasyUi_学习之路_04
- PHP中include与require的用法区别
- asterisk-gui nautilus-gksu_2.0.2-5ubuntu2_i386.deb
- Ext.ComponentQuery用法
- ligerUi Grid 自动换行
- The 1st tip of DB Query Analyzer
- The 1st tip of DB Query Analyzer
- UITextField详解
- UVa 10049 Self-describing Sequence (自描述序列&二分递推)
- LeetCode:N-Queens
- LeetCode:N-Queens II