ubuntu下编译为知笔记

先把为知笔记官方的教程放在前面

一、 准备环境

Linux (Ubuntu)

Qt

安装 5.7.0 for Linux 64-bit (715 MB) 或者更高版本

http://download.qt.io/official_releases/qt/5.7/5.7.0/qt-opensource-linux-x64-5.7.0.run

下载下来的安装文件,更改权限为可执行,然后执行安装程序。不要用管理员权限安装,直接安装到home目录即可,例如~/Qt5.7.0

Git

  1. sudo apt-get install git

编译工具

  1. sudo apt-get install build-essential

CMake

  1. sudo apt-get install cmake

zlib

    1. sudo apt-get install zlib1g-dev

二、Clone为知笔记源代码

可以直接clone。然后切换到分支v2.4.0或者更新的分支。也可以直接使用master分支(通常代码不是最新的)

对于Mac/Linux,可以在终端中运行:

  1. cd ~
  2. mkdir WizTeam
  3. cd WizTeam
  4. git clone https://github.com/WizTeam/WizQTClient.git
  5. cd WizQTClient
  6. git checkout v2.4.4

三、编译源代码

运行QtCreator,选择打开~/WizTeam/WizQTClient/CMakeLists.txt这个文件

注:通常QtCreator在安装路径下面的Tools/QtCreator/bin这个文件夹里面

如果出现运行CMake对话框,在参数中,输入下面的参数:(如果不设置参数,则会按照Release方式编译)。

  1. -DCMAKE_BUILD_TYPE=Debug

点击安装Run CMake,此时将会开始配置工程。等待1分钟左右后,如果没有错误,Done按钮将可以点击。点击Done(Finish)按钮。

如果没有出现 CMake 对话框,在QtCreator左侧导航栏,点击左下角Project构建按钮,选择 Build Debug->Run WizNote,然后点击左下角Build按钮,就可以开始编译WizNote源代码了。

几分钟后,就可以开始调试或者运行为知笔记客户端了。

若出现错误:No CMAKE_CXX_COMPILER could be found. mac qt

点击「项目」,打开「构建设置」,在 CMake 构建目录中添加以下两个参数,重新构建即可:

-DCMAKE_C_COMPILER=clang

-DCMAKE_CXX_COMPILER=clang++

Let‘s GO

在下载的时候安装其他的软件,顺利

[email protected]:~$ sudo apt-get install git
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
将会同时安装下列软件:
  git-man liberror-perl
建议安装:
  git-daemon-run | git-daemon-sysvinit git-doc git-el git-email git-gui gitk
  gitweb git-arch git-cvs git-mediawiki git-svn
下列【新】软件包将被安装:
  git git-man liberror-perl
升级了 0 个软件包,新安装了 3 个软件包,要卸载 0 个软件包,有 99 个软件包未被升级。
需要下载 3,823 kB 的归档。
解压缩后会消耗 25.6 MB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 http://cn.archive.ubuntu.com/ubuntu xenial/main amd64 liberror-perl all 0.17-1.2 [19.6 kB]
获取:2 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 git-man all 1:2.7.4-0ubuntu1.1 [735 kB]
获取:3 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 git amd64 1:2.7.4-0ubuntu1.1 [3,068 kB]
已下载 3,823 kB,耗时 4秒 (945 kB/s)
正在选中未选择的软件包 liberror-perl。
(正在读取数据库 ... 系统当前共安装有 219466 个文件和目录。)
正准备解包 .../liberror-perl_0.17-1.2_all.deb  ...
正在解包 liberror-perl (0.17-1.2) ...
正在选中未选择的软件包 git-man。
正准备解包 .../git-man_1%3a2.7.4-0ubuntu1.1_all.deb  ...
正在解包 git-man (1:2.7.4-0ubuntu1.1) ...
正在选中未选择的软件包 git。
正准备解包 .../git_1%3a2.7.4-0ubuntu1.1_amd64.deb  ...
正在解包 git (1:2.7.4-0ubuntu1.1) ...
正在处理用于 man-db (2.7.5-1) 的触发器 ...
正在设置 liberror-perl (0.17-1.2) ...
正在设置 git-man (1:2.7.4-0ubuntu1.1) ...
正在设置 git (1:2.7.4-0ubuntu1.1) ...
[email protected]:~$ sudo apt-get install build-essential
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
build-essential 已经是最新版 (12.1ubuntu2)。
升级了 0 个软件包,新安装了 0 个软件包,要卸载 0 个软件包,有 99 个软件包未被升级。
[email protected]:~$ sudo apt-get install cmake
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
将会同时安装下列软件:
  cmake-data libjsoncpp1
建议安装:
  codeblocks eclipse ninja-build
下列【新】软件包将被安装:
  cmake cmake-data libjsoncpp1
升级了 0 个软件包,新安装了 3 个软件包,要卸载 0 个软件包,有 99 个软件包未被升级。
需要下载 3,817 kB 的归档。
解压缩后会消耗 20.5 MB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 cmake-data all 3.5.1-1ubuntu3 [1,121 kB]
获取:2 http://cn.archive.ubuntu.com/ubuntu xenial/main amd64 libjsoncpp1 amd64 1.7.2-1 [73.0 kB]
获取:3 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 cmake amd64 3.5.1-1ubuntu3 [2,623 kB]
已下载 3,817 kB,耗时 3秒 (1,052 kB/s)
正在选中未选择的软件包 cmake-data。
(正在读取数据库 ... 系统当前共安装有 220280 个文件和目录。)
正准备解包 .../cmake-data_3.5.1-1ubuntu3_all.deb  ...
正在解包 cmake-data (3.5.1-1ubuntu3) ...
正在选中未选择的软件包 libjsoncpp1:amd64。
正准备解包 .../libjsoncpp1_1.7.2-1_amd64.deb  ...
正在解包 libjsoncpp1:amd64 (1.7.2-1) ...
正在选中未选择的软件包 cmake。
正准备解包 .../cmake_3.5.1-1ubuntu3_amd64.deb  ...
正在解包 cmake (3.5.1-1ubuntu3) ...
正在处理用于 man-db (2.7.5-1) 的触发器 ...
正在处理用于 libc-bin (2.23-0ubuntu9) 的触发器 ...
正在设置 cmake-data (3.5.1-1ubuntu3) ...
正在设置 libjsoncpp1:amd64 (1.7.2-1) ...
正在设置 cmake (3.5.1-1ubuntu3) ...
正在处理用于 libc-bin (2.23-0ubuntu9) 的触发器 ...
顺利完成:)))))))))

clone 顺利

checkout 2。5。5 顺利

qt编译 报错

p,li { white-space: pre-wrap }

Failed to find "GL/gl.h" in "/usr/include/libdrm"

try

{

sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev 顺利完成

try again

}

顺利完成

qt 输出

{

p,li { white-space: pre-wrap }

Running "/usr/bin/cmake /home/yongqian/WizNote/WizQTClient ‘-GCodeBlocks - Unix Makefiles‘ -DCMAKE_CXX_COMPILER:STRING=/usr/bin/g++ -DQT_QMAKE_EXECUTABLE:STRING=/home/yongqian/Qt5.7.0/5.7/gcc_64/bin/qmake" in /tmp/qtc-cmake-s5sMQw.

-- The C compiler identification is GNU 5.4.0

-- The CXX compiler identification is GNU 5.4.0

-- Check for working C compiler: /usr/bin/cc

-- Check for working C compiler: /usr/bin/cc -- works

-- Detecting C compiler ABI info

-- Detecting C compiler ABI info - done

-- Detecting C compile features

-- Detecting C compile features - done

-- Check for working CXX compiler: /usr/bin/g++

-- Check for working CXX compiler: /usr/bin/g++ -- works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- Detecting CXX compile features

-- Detecting CXX compile features - done

-- Performing Test COMPILER_SUPPORTS_CXX11

-- Performing Test COMPILER_SUPPORTS_CXX11 - Success

-- Performing Test COMPILER_SUPPORTS_CXX0X

-- Performing Test COMPILER_SUPPORTS_CXX0X - Success

-- Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)

-- Looking for sys/types.h

-- Looking for sys/types.h - found

-- Looking for stdint.h

-- Looking for stdint.h - found

-- Looking for stddef.h

-- Looking for stddef.h - found

-- Check size of off64_t

-- Check size of off64_t - done

-- Looking for fseeko

-- Looking for fseeko - found

-- Looking for unistd.h

-- Looking for unistd.h - found

ZLIB not found, using internal: /home/yongqian/WizNote/WizQTClient/lib/zlib

CMake Error at /home/yongqian/Qt5.7.0/5.7/gcc_64/lib/cmake/Qt5Gui/Qt5GuiConfigExtras.cmake:9 (message):

Failed to find "GL/gl.h" in "/usr/include/libdrm".

Call Stack (most recent call first):

/home/yongqian/Qt5.7.0/5.7/gcc_64/lib/cmake/Qt5Gui/Qt5GuiConfig.cmake:146 (include)

/home/yongqian/Qt5.7.0/5.7/gcc_64/lib/cmake/Qt5Widgets/Qt5WidgetsConfig.cmake:87 (find_package)

/home/yongqian/Qt5.7.0/5.7/gcc_64/lib/cmake/Qt5/Qt5Config.cmake:26 (find_package)

cmake/QtChooser.cmake:1 (find_package)

lib/quazip/CMakeLists.txt:6 (include)

-- Configuring incomplete, errors occurred!

See also "/tmp/qtc-cmake-s5sMQw/CMakeFiles/CMakeOutput.log".

*** cmake process exited with exit code 1.

Running "/usr/bin/cmake /home/yongqian/WizNote/WizQTClient ‘-GCodeBlocks - Unix Makefiles‘ -DCMAKE_CXX_COMPILER:STRING=/usr/bin/g++ -DQT_QMAKE_EXECUTABLE:STRING=/home/yongqian/Qt5.7.0/5.7/gcc_64/bin/qmake" in /tmp/qtc-cmake-c4Vg32.

-- The C compiler identification is GNU 5.4.0

-- The CXX compiler identification is GNU 5.4.0

-- Check for working C compiler: /usr/bin/cc

-- Check for working C compiler: /usr/bin/cc -- works

-- Detecting C compiler ABI info

-- Detecting C compiler ABI info - done

-- Detecting C compile features

-- Detecting C compile features - done

-- Check for working CXX compiler: /usr/bin/g++

-- Check for working CXX compiler: /usr/bin/g++ -- works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- Detecting CXX compile features

-- Detecting CXX compile features - done

-- Performing Test COMPILER_SUPPORTS_CXX11

-- Performing Test COMPILER_SUPPORTS_CXX11 - Success

-- Performing Test COMPILER_SUPPORTS_CXX0X

-- Performing Test COMPILER_SUPPORTS_CXX0X - Success

-- Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)

-- Looking for sys/types.h

-- Looking for sys/types.h - found

-- Looking for stdint.h

-- Looking for stdint.h - found

-- Looking for stddef.h

-- Looking for stddef.h - found

-- Check size of off64_t

-- Check size of off64_t - done

-- Looking for fseeko

-- Looking for fseeko - found

-- Looking for unistd.h

-- Looking for unistd.h - found

ZLIB not found, using internal: /home/yongqian/WizNote/WizQTClient/lib/zlib

-- /home/yongqian/WizNote/WizQTClient/resources/wiznote.qrc

WizNote whill compiling as Release, use Qt: 5.7.0

-- Configuring done

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in src/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning (dev) in lib/quazip/CMakeLists.txt:

Policy CMP0043 is not set: Ignore COMPILE_DEFINITIONS_<Config> properties.

Run "cmake --help-policy CMP0043" for policy details. Use the cmake_policy

command to set the policy and suppress this warning.

This warning is for project developers. Use -Wno-dev to suppress it.

-- Generating done

CMake Warning:

Manually-specified variables were not used by the project:

QT_QMAKE_EXECUTABLE

-- Build files have been written to: /tmp/qtc-cmake-c4Vg32

}

尝试run一下,经过很长时间的等待,我的机器上大概2分钟

报错:

/home/yongqian/WizNote/WizQTClient/lib/quazip/zip.h:56: error: zlib.h: No such file or directory

看来是忘记了 这个:::

  1. sudo apt-get install zlib1g-dev

{ sudo apt-get install zlib1g-dev
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
将会同时安装下列软件:
  zlib1g
下列【新】软件包将被安装:
  zlib1g-dev
下列软件包将被升级:
  zlib1g
升级了 1 个软件包,新安装了 1 个软件包,要卸载 0 个软件包,有 98 个软件包未被升级。
需要下载 219 kB 的归档。
解压缩后会消耗 424 kB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 zlib1g amd64 1:1.2.8.dfsg-2ubuntu4.1 [51.2 kB]
获取:2 http://cn.archive.ubuntu.com/ubuntu xenial-updates/main amd64 zlib1g-dev amd64 1:1.2.8.dfsg-2ubuntu4.1 [168 kB]
已下载 219 kB,耗时 0秒 (820 kB/s)  
(正在读取数据库 ... 系统当前共安装有 224086 个文件和目录。)
正准备解包 .../zlib1g_1%3a1.2.8.dfsg-2ubuntu4.1_amd64.deb  ...
正在将 zlib1g:amd64 (1:1.2.8.dfsg-2ubuntu4.1) 解包到 (1:1.2.8.dfsg-2ubuntu4) 上 ...
正在处理用于 libc-bin (2.23-0ubuntu9) 的触发器 ...
正在设置 zlib1g:amd64 (1:1.2.8.dfsg-2ubuntu4.1) ...
正在处理用于 libc-bin (2.23-0ubuntu9) 的触发器 ...
正在选中未选择的软件包 zlib1g-dev:amd64。
(正在读取数据库 ... 系统当前共安装有 224086 个文件和目录。)
正准备解包 .../zlib1g-dev_1%3a1.2.8.dfsg-2ubuntu4.1_amd64.deb  ...
正在解包 zlib1g-dev:amd64 (1:1.2.8.dfsg-2ubuntu4.1) ...
正在处理用于 man-db (2.7.5-1) 的触发器 ...
正在设置 zlib1g-dev:amd64 (1:1.2.8.dfsg-2ubuntu4.1) ...
[email protected]:~/WizNote/WizQTClient$

}

and then……

再一次编译,好激动

成功喽

弹出了登录的界面

时间: 2024-10-10 23:05:06

ubuntu下编译为知笔记的相关文章

在Ubuntu下编译Assimp库

在Ubuntu下编译Assimp库 如何在Ubuntu下编译Assimp库?这是我以前编译成功后做的笔记,供参考. 1.去下面的网站去下载Assimp库: http://assimp.sourceforge.net/ 2.安装cmake,似乎Assimp库只能通过cmake和vs工程文件进行构建,普通的makfile是通过它来产生的.Ubuntu下使用sudo apt-get install cmake.然后通过cmake --version查看cmake的版本,我cmake版本是2.8.11.

ubuntu下编译java程序

ubuntu下编译java程序 首先需要安装jdk,并配置好相应环境变量 下面以简单的HelloWorld为例 文件名为HelloWorld.java java代码: public class HelloWorld { public static void main(String args[]) { System.out.println("Hello World!"); } } 编译: javac HelloWorld.java 此时会在当前文件夹生成 HelloWorld.class

Ubuntu下编译3.0.4内核

Ubuntu下编译3.0.4内核 Linux内核3.0版本发布已有一段时间了,不知道这个版本号大跃进的内核是否好用.目前各个发行版的linux还仍未采用3.0的内核,因此可以自己动手编译内核来感受一下!趁着这次编译内核的机会可以再熟悉一下编译内核的步骤. 1.下载并解压内核到任意目录 从源码官网下载最新的内核源码3.0.4,可以解压至任意目录,我放在主目录下: 1 ~$ tar xjvf linux-3.0.4.tar.bz2 2.配置内核 对内核进行配置是为了得到内核配置文件.config.通

Ubuntu下编译Android JNI实例全过程

第一步:保证make和gcc可用 在shell中输入make-v,不报错就是对的.(可参考http://wenku.baidu.com/view/d87586c24028915f804dc24a.html.) 在shell中输入gcc-v,不报错就是对的. 第二步:安装NDK 下载NDK后,设置环境变量: 将android-ndk的路劲加到环境变量PATH中:sudogedit /etc/environment 然后再让这个更改的环境变量立即生效:source /etc/environment

《Swift入门》ubuntu下编译运行Swift开发的Web后端示例

这里只是演示如何在ubuntu下编译运行Swift开发的Web后端项目. 项目代码来自Bluemix上提供的示例代码,如果你有账号,可以去自己的空间下载,没有的话,可以通过下面的地址下载: http://download.csdn.net/detail/testcs_dn/9513395 编译环境安装配置请参考:Ubuntu 14 server安装Swift运行环境 环境配置好之后,将下载的示例代码解压出来: 主要代码是"main.swift",内容如下: /** * Copyrigh

ubuntu下编译VLC源码

http://blog.csdn.net/beitiandijun/article/details/9225591ubuntu下编译VLC源码 分类: 视频处理 2013-07-02 17:33 5761人阅读 评论(0) 收藏 举报VLC 操作系统选择:http://old-releases.ubuntu.com/releases/14.04.0/ubuntu-14.04-desktop-amd64.iso sudo apt-get install已经安装了freescale的i.MX6Q的a

Ubuntu下编译安装QEMU

Ubuntu下编译安装QEMU 由于环境需求,今天在ubuntu14.04的环境下手动编译安装了QEMU2.1.2. QEMU下载地址:http://wiki.qemu-project.org/download/qemu-2.1.2.tar.bz2 具体下载及解压步骤这里就不在赘述了,主要就是说下环境准备的一些依赖包,编译QEMU最重要的就是gcc,所以我们要先把gcc安装上. [email protected]:~# apt-get install gcc-3.4 cpp-3.4 安装QEMU

ubuntu下编译交叉编译工具链

交叉编译工具链在arm开发中出很重要的位置,开发之前肯定要先有编译器 连接器 汇编器等基础的编译工具.arm体系是一个很复杂的体系,里面的指令有数个版本不同的体系level还有很多自己的特点 ,这就要求编译器也要出几个版本的针对不同的应用. 当然网络上存在很多的编译器的资源,但是作为一个嵌入式开发人员还是要会自己构建出来一个工具链的,做到只能说不想做,不能说做不到,不然真的遇到特殊应用的需要无法作出编译器项目就直接挂了. 整个工具链的编译过程如果采用纯手工的step by step  真的需要几

在 ubuntu 下编译 android 找不到头文件问题解决

在 ubuntu 下编译 android 的时候, 发现编译错误, 有些头文件找不到, 如: 致命错误: alsa/asoundlib.h: 没有那个文件或目录 网上搜索了一下, 原因是某些库没安装导致. 可以使用 apt-file 查看该头文件在什么库中, 找到相应的库, 安装即可. 安装 apt-file : sudo apt-get install apt-file 查找头文件: apt-file search 头文件, 如: apt-file search alsa/asoundlib.