免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1658 | 回复: 3
打印 上一主题 下一主题

[samba] samba服务器 升级编译问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2015-03-21 10:13 |只看该作者 |倒序浏览
编译时出现一下问题

[root@hacker samba-4.2.0]# ./configure
Traceback (most recent call last):
  File "./buildtools/bin/waf", line 34, in ?
    if sys.hexversion<0x203000f: raise ImportError("Waf requires Python >= 2.3")
ImportError: Waf requires Python >= 2.3

求解怎么把这个问题解决掉然后直接编译成功
[root@hacker samba-4.2.0]# more ./buildtools/bin/waf
#!/usr/bin/env python
# encoding: ISO-8859-1
# Thomas Nagy, 2005-2010

"""
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:

1. Redistributions of source code must retain the above copyright
   notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright
   notice, this list of conditions and the following disclaimer in the
   documentation and/or other materials provided with the distribution.

3. The name of the author may not be used to endorse or promote products
   derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
"""

import os, sys
if sys.hexversion<0x203000f: raise ImportError("Waf requires Python >= 2.3")

if 'PSYCOWAF' in os.environ:
        try:import psyco;psyco.full()
        except:pass

VERSION="1.5.19"
REVISION="x"
INSTALL="x"
C1='x'
C2='x'
cwd = os.getcwd()
join = os.path.join

WAF='waf'
def b(x):
        return x

if sys.hexversion>0x300000f:
        WAF='waf3'
        def b(x):
                return x.encode()

def err(m):
        print(('\033[91mError: %s\033[0m' % m))
        sys.exit(1)

def test(dir):
        try: os.stat(join(dir, 'wafadmin')); return os.path.abspath(dir)
        except OSError: pass

def find_lib():
        return os.path.abspath(os.path.dirname(os.path.dirname(__file__)))

wafdir = find_lib()
w = join(wafdir, 'wafadmin')
t = join(w, 'Tools')
f = join(w, '3rdparty')
sys.path = [w, t, f] + sys.path

if __name__ == '__main__':
        import Scripting
        Scripting.prepare(t, cwd, VERSION, wafdir)

求职 : 机器学习
论坛徽章:
79
2015年亚洲杯纪念徽章
日期:2015-05-06 19:18:572015七夕节徽章
日期:2015-08-21 11:06:172015亚冠之阿尔纳斯尔
日期:2015-09-07 09:30:232015亚冠之萨济拖拉机
日期:2015-10-21 08:26:3915-16赛季CBA联赛之浙江
日期:2015-12-30 09:59:1815-16赛季CBA联赛之浙江
日期:2016-01-10 12:35:21技术图书徽章
日期:2016-01-15 11:07:2015-16赛季CBA联赛之新疆
日期:2016-02-24 13:46:0215-16赛季CBA联赛之吉林
日期:2016-06-26 01:07:172015-2016NBA季后赛纪念章
日期:2016-06-28 17:44:45黑曼巴
日期:2016-06-28 17:44:4515-16赛季CBA联赛之浙江
日期:2017-07-18 13:41:54
2 [报告]
发表于 2015-03-21 11:22 |只看该作者
  1. raise ImportError("Waf requires Python >= 2.3")
复制代码
这个报错信息说你的python的版本是不对的

论坛徽章:
0
3 [报告]
发表于 2015-03-21 11:27 |只看该作者
重新编译了 python   编译成功之后再编译的 samba  之后是报错的
samba版本samba-4.2.0
python版本 Python-3.5.0a2.tgz

论坛徽章:
0
4 [报告]
发表于 2015-03-21 11:40 |只看该作者
在线等求解 ,求解决办法
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP