本文介绍了如何建立和放大器;安装GLFW 3和一个Linux项目中使用它的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

昨天晚上我工作到很晚试图从源头建立GLFW 3包的Linux版本。这个过程花了我很长的时间,共约3个小时,部分原因是因为我不熟悉CMake的,部分是因为我不太熟悉GLFW。

Last night I was working late trying to build the GLFW 3 packages for Linux from source. This process took me a very long time, about 3 hours in total, partly because I am unfamiliar with CMake, and partly because I am was unfamiliar with GLFW.

我希望这篇文章能够将你从我昨天的难度!我想我应该做一个简短的写了起来,并希望为您节省几个小时你的生活......

I hope that this post will save you from the difficulty I had yesterday! I thought I should make a short write-up, and hopefully save you several hours of your life...

由于urraka,B6,并在#glfw IRC频道尼古拉斯,我已经能够得到GLFW 3.0.1版的工作。

Thanks to "urraka", "b6" and "niklas" on the #glfw IRC channel, I have been able to get glfw version 3.0.1 working.

原来,这不是一个简单的过程(当然不是我,我不是专家),因为没有太多的文档中关于glfw3在网络上,特别是有关与CMake的设置它。

It turns out this is not a trivial process (certainly not for me, I am no expert) as there is not much documentation on the web about glfw3, particularly about setting it up with CMake.

有人问我这个分成的问题和答案部分,所以我这样做,得到的回答部分是现在的下面。

I was asked to split this into a question and answer section, and so I have done that, and the answer parts are now below.

如果任何GLFW3的维护者的看到这一点,那么我的消息对他们来说是请部分增加了建立GLFW3在Windows,Mac OS X和Linux到您的网站!这是很容易编写与GLFW方案,因为在线文档是相当不错的,所有可用类和模块的快速扫描,你会准备去。测试项目的例子在这里特色也很不错。我发现两个主要问题是,首先我该如何设置GLFW3我的系统上,其次如何我建一个GLFW3项目?这两件事情也许还不太清楚足以让一个非专家。

If any of the maintainers of GLFW3 see this, then my message to them is please add a "setting up GLFW3 on Windows, Mac OS X and Linux" section to your website! It is quite easy to write programs with GLFW, since the online documentation is quite good, a quick scan of all the available classes and modules and you'll be ready to go. The example of a test project featured here is also very good. The two main problems I found were, firstly how do I set up GLFW3 on my system, and secondly how to I build a GLFW3 project? These two things perhaps aren't quite clear enough for a non-expert.

有一个简单的介绍一下今天(日期:2014年1月14日),它看起来好像GLFW网站经历了沉重的变化,因为我上次看,现在有上编译与GLFW GLFW和栋计划,我认为一节是新的。

Had a brief look today (Date: 2014-01-14) it looks as if the GLFW website has undergone heavy changes since I last looked and there is now a section on compiling GLFW and buliding programs with GLFW, which I think are new.

推荐答案

有关此安装,我使用的Kubuntu 13.04,64位。

Step 1: Installing GLFW 3 on your system with CMAKE

For this install, I was using KUbuntu 13.04, 64bit.

的第一个步骤是从www.glfw.org下载最新版本(假设在以后的工作版本以类似的方式),可能使用这。

The first step is to download the latest version (assuming versions in the future work in a similar way) from www.glfw.org, probably using this link.

下一步是提取存档,打开一个终端。 CD 进入GLFW-3.XX目录并运行的CMake -G的Unix的Makefile您可能需要提升权限,你可能还需要为昨天!

Hopefully this information was correct and everything worked for you, and you enjoyed writing the GLFW test program. Also hopefully this guide has helped, or will help, a few people in the future who were struggling as I was yesterday!

顺便说一句,所有的标签都是我搜索计算器上寻找根本不存在的答案的事情。 (到现在为止)。我希望他们是你搜索的内容,如果你是在一个相似的位置自己。

By the way, all the tags are the things I searched for on stackoverflow looking for an answer that didn't exist. (Until now.) Hopefully they are what you searched for if you were in a similar position to myself.

这篇关于如何建立和放大器;安装GLFW 3和一个Linux项目中使用它的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-24 02:19