Google Tensorflow 源码编译(一):Protobuf<v3.0.0-alpha-3>
这几天终于把tensorflow安装上了,中间遇到过不少的问题,这里记录下来。供大家想源码安装的参考。
安装环境:POWER8处理器,Docker容器Ubuntu14.04镜像。
Build Protobuf<v3.0.0-alpha-3> for IBM POWER8 CPU from Source Code
My computer's os is ubuntu 14.04 , and I want to install protobuf v3.0.0-alpha-3, but there is no deb package in the repository, so I need to build from source code.
Here are the steps that I succeed to install protobuf<v3.0.0-alpha-3> on my computer:
1. Get source code
1.1 Get protobuf code
git clone https://github.com/google/protobuf
git checkout v3.0.0-alpha-3
1.2 Get gtest code
The latest protobuf version uses gmock, but v3.0.0-alpha-3 uses gtest. Anyway ,the following code always works!
git clone https://github.com/franramirez688/gmock(../ is the root path of protobuf)
cp ./gmock/gtest ../
2. Modify the code to support POWER cpu
2.1 Add g++ MACRO
in protobuf/src/google/protobuf/stubs/platform_macros.h:
change #elif defined(_POWER) to #elif defined(_POWER) || defined(__powerpc64__) || defined(__PPC64__).
2.2 Include power cpu header file
in protobuf/src/google/protobuf/stubs/atomicops.h, add:
if defined(GOOGLE_PROTOBUF_ARCH_POWER)
#include <google/protobuf/stubs/atomicops_internals_power.h>
endif
2.3 Add power cpu header file
add atomicops_internals_power.h to google/protobuf/stubs folder:
you can copy it from the latest version < v3.0.0-beta-1>
3. Compile source code
$ ./autogen.sh
$ ./configure
$ make
$ make install
4. the binary file <protoc> is saved at protobuf/src/protoc.
Google Tensorflow 源码编译(一):Protobuf<v3.0.0-alpha-3>的更多相关文章
- Google Tensorflow 源码编译(三):tensorflow<v0.5.0>
这几天终于把tensorflow安装上了,中间遇到过不少的问题,这里记录下来.供大家想源码安装的参考. 安装环境:POWER8处理器,Docker容器Ubuntu14.04镜像. Build Tens ...
- Google Tensorflow 源码编译(二):Bazel<v0.1.0>
这几天终于把tensorflow安装上了,中间遇到过不少的问题,这里记录下来.供大家想源码安装的参考. 安装环境:POWER8处理器,Docker容器Ubuntu14.04镜像. Build Baze ...
- tensorflow 源码编译tensorflow 1.1.0到 tensorflow 2.0,ver:1.1.0rc1、1.4.0rc1、1.14.0-rc1、2.0.0b1
目录 tensorflow-build table 更多详细过程信息及下载: tensorflow-build tensorflow 源码编译,提升硬件加速,支持cpu加速指令,suport SSE4 ...
- Tensorflow源码编译常见问题点总结
Tensorflow源码编译分两种:一种是本地源码编译,另一种是针对ARM平台的源码编译. 接下来分别介绍: 一.本地编译 本地编译时,使用的编译工具是本地GCC. 一般会碰到以下问题: 第1个:ex ...
- Ubuntu 16.04源码编译安装nginx 1.10.0
一.下载相关的依赖库 pcre 下载地址 http://120.52.73.43/jaist.dl.sourceforge.net/project/pcre/pcre/8.38/pcre-8.38.t ...
- Centos7下源码编译安装与配置redis5.0
1.下载redis5.0源码包 wget http://download.redis.io/releases/redis-5.0.5.tar.gz 2.检查是否安装过之前的历史版本 rpm -qa|g ...
- Tensorflow源码编译,解决tf提示未使用SSE4.1 SSE4.2 AVX警告【转】
本文转载自:https://blog.csdn.net/iTaacy/article/details/72799833 版权声明:欢迎转载,转载请注明出处! https://blog.csdn.net ...
- tensorflow 源码编译
https://blog.csdn.net/xsfl1234/article/details/67669707 https://blog.csdn.net/guxi123/article/detail ...
- TensorFlow 源码编译安装
## Install prerequisites (rhel) yum install numpy python-devel python-wheel python-mock ## Install B ...
随机推荐
- SqlParameter设定value为0却变成null
直接MSDN:http://msdn.microsoft.com/zh-cn/library/0881fz2y(VS.80).aspx 当在 value 参数中指定 Object 时,SqlDbTyp ...
- Octopus系列之模板快速开发手册
公共代码 html_header_1 <title>${sitename}-${seotitle}</title> <meta http-equiv="Cont ...
- iOS开发UI篇—在UIImageView中添加按钮以及Tag的参数说明
ios开发UI篇—在ImageView中添加按钮以及Tag的参数说明 一.tag参数 一个视图通常都只有一个父视图,多个子视图,在开发中可以通过使用子视图的tag来取出对应的子视图.方法为Viewwi ...
- pwnable.kr-collision
题目: 链接后登陆 ssh col@pwnable.kr -p2222 查看文件以及权限 Ls –al 查看代码 cat col.c 根据 if(strlen(argv[1]) != 20){ pri ...
- Hibernate 检索策略
概述 检索数据时的 2 个问题: –不浪费内存:当 Hibernate 从数据库中加载 Customer 对象时, 如果同时加载所有关联的 Order 对象, 而程序实际上仅仅需要访问 Custome ...
- 【个人使用.Net类库】(4)验证码类
验证码是现在管理系统常用的一种保护用户帐户信息的一种功能. 验证码可以有效防止某个黑客对某一个特定注册用户用特定程序暴力破解方式进行不断的登录尝试,虽然这可能是我们登录麻烦一点,但是对用户的密码安全来 ...
- ArrayList与普通数组的区别
import java.util.ArrayList; public class Shuzuqubie { public static void main(String[] args){ String ...
- Python的平凡之路(2)
一.标准库(sys & os): Python 的标准库(standard library) 是随着 Python 一起安装在你的电脑中的,是 Python 的一部分 (当然也有特殊情况. ...
- MapReducer程序调试技巧
写过程序分布式代码的人都知道,分布式的程序是比较难以调试的,但是也不是不可以调试,对于Hadoop分布式集群来说,在其上面运行的是mapreduce程序,因此,有时候写好了mapreduce程序之后, ...
- VIM_git
一:Git是什么? Git是目前世界上最先进的分布式版本控制系统. 二:SVN与Git的最主要的区别? SVN是集中式版本控制系统,版本库是集中放在中央服务器的,而干活的时候,用的都是自己的电脑,所以 ...