samba 2.2.7a 编译
来源:互联网 发布:数控车床编程入门讲解 编辑:程序博客网 时间:2024/05/23 23:28
今天在君正T20上编译samba 2.2.7a 遇到了一些问题,特此记录一下
1.自己写一个build.sh脚本,方便后续的再次编译
#!/bin/sh
#
export CFLAGS="-O2 -muclibc"
export CPPFLAGS="-O2 -muclibc"
export CXXFLAGS="-O2 -muclibc"
export LDFLAGS="-O2 -muclibc"
#export CFLAGS='-O3 -w -isystem /home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/mips-linux-gnu/libc/usr/include'
#export CPPFLAGS='-O3 -w -isystem /home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/mips-linux-gnu/libc/usr/include'
export PATH=/home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/bin:$PATH
export COMPILE_TOOL=/home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/bin/mips-linux-gnu-
export CC=${COMPILE_TOOL}gcc
export AS=${COMPILE_TOOL}as
export AR=${COMPILE_TOOL}ar
export LD=${COMPILE_TOOL}ld
export RANLIB=${COMPILE_TOOL}ranlib
export STRIP=${COMPILE_TOOL}strip
export CPP=${COMPILE_TOOL}cpp
export LD_LIBRARY_PATH=/home/xuxuequan/Ingenicwork/Ingenic-SDK/rootfs/lib
#
MQARMDIR=/usr/samba
MQUSERDIR=/usr/samba/config
#
./configure --build=i686-build_pc-linux-gnu --host=mips-linux-gnu --target=mips-linux-gnu \
--prefix=/home/xuxuequan/Ingenicwork/lib/libsource/samba-2.2.7a/install \
--includedir=/home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/mips-linux-gnu/libc/uclibc/usr/include \
--oldincludedir=/home/xuxuequan/Ingenicwork/toolchain/mips-gcc472-glibc216-32bit/mips-linux-gnu/libc/uclibc/usr/include \
--disable-largefile \
--enable-swat=no \
--enable-smbtorture4=no \
--enable-cups=no \
--enable-iprint=no \
--enable-pie=no \
--enable-relro=no \
--with-PACKAGE=no \
--enable-external-libtalloc=no \
--enable-external-libtevent=no \
--enable-external-libtdb=no \
--enable-fam=no \
--enable-avahi=no \
--with-libtalloc=no \
--with-libtevent=no \
--with-libtdb=no \
--with-libnetapi=no \
--with-libsmbsharemodes=no \
--with-dmapi=no \
--with-ldap=no \
--with-ads=no \
--with-dnsupdate=no \
--with-pam=no \
--with-pam_smbpass=no \
--with-sys-quotas=no \
--with-utmp=no \
--with-cluster-support=no \
--with-acl-support=no \
--with-sendfile-support=no \
--with-wbclient=no \
--with-winbind=no \
--with-included-popt=no \
--with-included-iniparser=no \
--bindir=$MQARMDIR/bin \
--sbindir=$MQARMDIR/sbin \
--localstatedir=$MQUSERDIR/var \
--libdir=$MQARMDIR/lib \
--with-privatedir=$MQUSERDIR/private \
--with-rootsbindir=$MQARMDIR/bin \
--with-lockdir=$MQUSERDIR/var/locks \
--with-configdir=$MQUSERDIR \
--with-logfilebase=$MQUSERDIR/var \
--with-piddir=$MQUSERDIR/var
2.执行这个build.sh生成Makefile文件
3.修改/home/xuxuequan/Ingenicwork/lib/libsource/samba-2.2.7a/source/include/config.h
注释掉三个宏定义,增加下面红色的定义
/* The number of bytes in a int. */
//#define SIZEOF_INT cross
/* The number of bytes in a long. */
//#define SIZEOF_LONG cross
/* The number of bytes in a short. */
//#define SIZEOF_SHORT cross
#define SIZEOF_INT 4
#define SIZEOF_LONG 4
#define SIZEOF_SHORT 2
#define HAVE_GETTIMEOFDAY_TZ 1
#define USE_SETEUID 1
#define HAVE_IFACE_IFCONF 1
4.后续执行make即可在bin下面生成smbclient
- samba 2.2.7a 编译
- 移植samba-2.2.7a
- samba交叉编译
- samba源码编译步骤
- 源码编译安装samba
- samba 编译安装
- 交叉编译samba服务器
- Samba(MIPSEL)交叉编译
- 编译安装samba 3.3.3
- 编译安装samba以及配置
- Samba源码编译及安装
- A Samba server configuration example
- samba-3源码安装一:编译安装
- 关于编译后文件取回 - Samba服务器
- Fedora 7 samba 共享
- 7、Samba软件包
- centos 7 samba
- CentOS 7 安装 samba
- 阅读理解FireFox浏览器插件开发文档(二)
- 第一次安装android studio时候弹出unable to access android sdk add-on list解决方法
- OSAL操作系统实验学习笔记08
- GSON解析JSON
- Oracle之select into var1
- samba 2.2.7a 编译
- 让两个布局都在同一个控件的上方
- 2017第二届全球虚拟现实与增强现实中国峰会全新会议日程
- Win下redis管理工具安装于使用说明
- QT QTableview
- NodeJS-05 express
- ZOJ-3956-Course Selection System【01背包】【17th浙大校赛】
- CString与string、char*的区别和转换
- MAC下载安卓源码提示"gpg (GnuPG) is not available"