c - Setting up GTK for C application development on Windows without MYSYS2 or gvsbuild
问题描述
In order for me to program my application on Windows with GTK, The official website instructs me to install MYSYS2 and then use pacman to install the required files.
- Why am I unable to simply download the required assets, C and header files by myself and just add them to my C project like I do with my own files?
- Why do these files need to be installed with some form of package manager like that? Why do I need to "build" this? Is there any workaround to this? How is it that this is impossible without the help of some Linux environment?
- At the very least, would it be possible to install GTK environment using MYSYS2 and copy just the GTK+ contents somewhere and never have to repeat this again?
As I understand it, currently I would still have to compile the application using a Linux environment for GTK+ to be compiled into the application.
解决方案
这可能很有用https://github.com/Wesley-Chan/GTK-for-Windows。
还有Quod Libet 的Windows 开发自述文件,它可以帮助您。
然而,从历史上看,Gtk 并不是跨平台开发最友好的工具包,所以如果您需要良好的 Windows 支持,我建议您使用 Qt。
也就是说,Gtk 有更好的许可证,希望Gtk 4的跨平台支持会得到改善。
推荐阅读
- php - session_destroy() 被执行但会话在 PHP 中是活动的
- python - GDAL/OGR (Ogr2ogr) python绑定windows OCI驱动
- c++ - 样式表在继承自 QWidget 的类上被忽略
- javascript - Cisco webex 将流媒体直播嵌入网站
- ios - 错误:预期类型 - eventDispatcher:(nonnull RCTEventDispatcher *)eventDispatcher; 在 iOS 构建期间出现“未定义符号”错误
- git - 如何使用 TFVC 创建拉取请求?
- javascript - 在正则表达式中转义特殊字符
- python - 如何正确转换重音
- vue.js - 是否可以在使用多个页面(在同一个窗口上)的应用程序中使用 Electron(使用 VueJS)?
- ios - 如何快速检查整周的持续时间