系统版本15.11桌面版,全新安装

在$HOME/SoftwareLibrary中克隆wxWidgets
不可以直接从git拉,会少文件

SoftwareLibrary是我自己的建立的目录

https://github.com/wxWidgets/wxWidgets/releases下载最新的发布包
然后进入wxWidgets目录,
docs/gtk/install.md有安装教程,说的比较简单粗暴,很适合我:

If you compile wxWidgets on Linux for the first time and don't like to read
install instructions just do (in the base dir):> mkdir buildgtk> cd buildgtk> ../configure --with-gtk> make> su <type root password>> make install> ldconfig[if you get "ldconfig: command not found", try using "/sbin/ldconfig"]If you don't do the 'make install' part, you can still use the libraries from
the buildgtk directory, but they may not be available to other users.If you want to remove wxWidgets on Unix you can do this:> su <type root password>> make uninstall> ldconfigNote that by default, GTK+ 2.x is used. GTK+ 3 can be specified
with --with-gtk=3.

中文翻译:

如果你是第一次在Linux上编译wxWidgets,并且不想读安装教程,只需要(在根目录):> mkdir buildgtk> cd buildgtk> ../configure --with-gtk> make> su <type root password>> make install> ldconfig
[如果你发现ldconfig:找不到命令,尝试使用“/sbin/ldconfig”]
如果你没有执行"make install"部分,你仍然可以从buildgtk使用库,但是其他用户无法使用。如果你想要删除wxWigets,可以这样做:> su <type root password>> make uninstall> ldconfig
注意,默认情况下,使用GTK+ 2.x,可以使用--with-gtk=3来指定GTK+ 3于是直接开始
发现提示我没有装C++ 编译器

configure: error: C++ compiler is needed to build wxWidgets

于是用apt-get进行安装
sudo apt-get install g++
再一次../configure
又出现错误:

configure: error:
The development files for GTK+ were not found. For GTK+ 2, please
ensure that pkg-config is in the path and that gtk+-2.0.pc is
installed. For GTK+ 1.2 please check that gtk-config is in the path,
and that the version is 1.2.3 or above. Also check that the
libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config
--libs' are in the LD_LIBRARY_PATH or equivalent.

就是提示我没有装GTK+,尝试了一下源码编译,想了想我还是太弱了

GTK+ requires the following packages:- The GLib, Pango, GdkPixbuf, ATK and cairo libraries, available atthe same location as GTK+. GTK+ 3.22.0 requires at leastGLib 2.49.4, Pango 1.37.3,GdkPixbuf 2.30.0, ATK 2.15.1and cairo 1.14.0.- libepoxy, for cross-platform OpenGL support.It can be found here: https://github.com/anholt/libepoxy- Each GDK backend has its own backend-specific requirements. Forthe X11 backend, X11 R6 and XInput version 2 (as well as a numberof other extensions) are required. The Wayland backend requires(obviously) the Wayland libraries.- gobject-introspection 1.39.0 or newer.

sudo apt-get install libgtk-3-dev
还是apt-get轻松
再次
../configure --with-gtk=3

Configured wxWidgets 3.1.4 for `x86_64-pc-linux-gnu'Which GUI toolkit should wxWidgets use?                 GTK+ 3 with support for GTK+ printingShould wxWidgets be compiled into single library?       noShould wxWidgets be linked as a shared library?         yesShould wxWidgets support Unicode?                       yes (using wchar_t)What level of wxWidgets compatibility should be enabled?wxWidgets 2.8      nowxWidgets 3.0      yesWhich libraries should wxWidgets use?STL                nojpeg               builtinpng                sysregex              builtintiff               builtinlzma               nozlib               sysexpat              syslibmspack          nosdl                no

看起来OJBK了,直接make
然后就成功了,执行make install

接下来尝试编译一个例子:
https://docs.wxwidgets.org/trunk/overview_helloworld.html

g++ main.cpp `wx-config --libs --cxxflags` -o main
就成功了,然后./main执行,窗口就出来了

将我的一个Windows上的wxWidgets写的工具扔过来运行效果(上Linux,下Windows):


Deepin上编译wxWidgets相关推荐

  1. deepin终端编译c程序_在deepin linux上安装国人开发的编程语言-“明”语言

    闲来无事,在网上看到了介绍<>这篇文章,找到了它在gitcafe的地址:http://gkmail.gitcafe.io/ming/,这是国人开发的一个脚本语言,中文名称"明语言 ...

  2. linux下运行yolo,deepin(linux)编译安装yolo v4测试效果

    # 背景 五一放假的最后一天我也凑了个热闹,试一下新鲜出炉的yolo v4, 由于没有装CUDA和CUDNN,只试了一下在CPU上的速度和效果,电脑环境及编译依赖如下: * deepin 15.11桌 ...

  3. 在deepin上安装YouCompleteMe

    详细安装步骤在github上有,https://github.com/Valloric/YouCompleteMe,我这里是自己总结的简化版安装步骤. 步骤1.安装Vundle 首先,clone到本地 ...

  4. mac c语言 gui,MAC GUI编程编译wxWidgets源码教程

    想要对您Mac电脑上的文件进行GUI编程或者编译吗?可是又不知道如何去启动编辑?那就来看看这里的MAC GUI编程编译wxWidgets源码教程吧.只要通过了MAC GUI编程编译wxWidgets源 ...

  5. 云主机装黑果实践(1):deepin上qemu+kvm装黑果

    本文关键字:用ubi在osx上打造一分区一安装启动U盘,deepin上qemu+kvm装黑果 在上文<云主机装黑果>中,我们讨论了其可能性,或许这里面的坑远远不止那文提到的,甚至最终不能成 ...

  6. c 远程编辑linux文件,makefile - 在远程Linux机器上编译C ++ - “检测到时钟偏差”警告...

    makefile - 在远程Linux机器上编译C ++ - "检测到时钟偏差"警告 我通过PuTTY和WinSCP连接到我大学的小型Linux集群,使用后者传输文件,并使用前者编 ...

  7. 在Ubuntu 14.04 64bit上编译安装Crtmpserver trunk svn 811版本!

    这里仅在 在Ubuntu 12.04 64bit上搭建Crtmpserver视频点播服务 基础上补充一下在Ubuntu 14.04上编译安装Crtmpserver的方法,以作备忘.因为Ubuntu 1 ...

  8. Ubuntu14.04上编译指定版本的protobuf源码操作步骤

    Google Protobuf的介绍可以参考 http://blog.csdn.net/fengbingchun/article/details/49977903 ,这里介绍在Ubuntu14.04上 ...

  9. RH系列linux上编译android2.3(gingerbread)

    在RH系列linux上编译android2.3(gingerbread)的过程如下: 官方源码及ubuntu编译过程在(http://source.android.com/source/index.h ...

最新文章

  1. 转载 - 使用HTML5、CSS3和jQuery增强网站用户体验
  2. runloop源代码
  3. 异步消息队列zeromq实现服务器间高性能通信
  4. 选择行_外出旅游你会选择自由行还是跟团游?
  5. vue.js 安装
  6. BZOJ2002: [Hnoi2010]Bounce 弹飞绵羊(LCT)
  7. 2017.8.24 快速傅里叶 思考记录
  8. Swift延迟加载的一种用途
  9. Masterlab 1.1 发布,基于敏捷开发的项目管理工具
  10. ug计算机环境变量,ug80添加中文环境变量的具体方法
  11. 万年历插件软件测试,中华万年历app测试用例.xls
  12. MIPI接口和DVP接口的区别及优点
  13. Windows 7 - TeamViewer 13 安装
  14. 程序猿麒麟臂打造之路(健身一)
  15. lempel ziv matlab,精讲Lempel-Ziv压缩算法
  16. VC6命令行编译配置
  17. new Set( ) 数组去重 适用场景
  18. linux虚拟网口不同vlan,Openwrt创建虚拟网口(macvlan)
  19. python 里面的无穷大与无穷小
  20. Jenkins 凭证管理

热门文章

  1. 面相学论眼睛:看眼形善与不善
  2. python中的一些数学小技巧
  3. Laravel 8 文件的上传/下载/显示的实例
  4. 【Python实战】爬取豆瓣排行榜电影数据(含GUI界面版)
  5. padding在css中是什么意思,html里padding是什么意思
  6. 如何解决服务之间的通信问题?
  7. 交易猫 转转 闲鱼 源码去后门永久授权
  8. O2O小程序点餐平台架构分享
  9. GNU make使用(一)
  10. 查看安装的kafka的版本的方法