Soc: Configuration backends

Gerald (Jerry) Carter jerry at samba.org
Wed Jul 5 15:57:01 GMT 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mingwang wrote:
> Ok here is the project status:

I've still got compile problems in your tree.  Just running
my standard build script in source/.  The compile problems
need to be resolved today.







cheers, jerry
=====================================================================
Samba                                    ------- http://www.samba.org
Centeris                         -----------  http://www.centeris.com
"What man is a man who does not make the world better?"      --Balian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iD8DBQFEq+FNIR7qMdg1EfYRApqbAKCkQQzWpbxY+eL6b95wp9xFhN8kjQCeLHiz
cgpsmJlK9zpRVUlj/HMbaNA=
=SeZE
-----END PGP SIGNATURE-----
-------------- next part --------------
Compiling dynconfig.c
In file included from include/includes.h:1059,
                 from /home/drizzt/jerry/bzr/soc/samba-soc/source/dynconfig.c:21:
include/proto.h: In function ‘fn_name’:
include/proto.h:141: error: ‘Key’ undeclared (first use in this function)
include/proto.h:141: error: (Each undeclared identifier is reported only once
include/proto.h:141: error: for each function it appears in.)
include/proto.h:141: error: ‘k’ undeclared (first use in this function)
include/proto.h:141: warning: ISO C90 forbids mixed declarations and code
include/proto.h:141: error: ‘key_path_buffer’ undeclared (first use in this function)
include/proto.h:141: error: ‘CONF_GLOBAL_ROOT’ undeclared (first use in this function)
include/proto.h:141: error: ‘path_ptr’ undeclared (first use in this function)
include/proto.h:141: warning: implicit declaration of function ‘ksLookupByName’
include/proto.h:141: error: ‘smbConfig’ undeclared (first use in this function)
include/proto.h:141: error: ‘KDB_O_ALL’ undeclared (first use in this function)
include/proto.h:141: warning: implicit declaration of function ‘keyStealValue’
include/proto.h: At top level:
include/proto.h:249: error: syntax error before ‘.’ token
include/proto.h:249: warning: type defaults to ‘int’ in declaration of ‘FN_GLOBAL_KEY_STRING’
include/proto.h:249: warning: function declaration isn’t a prototype
include/proto.h:249: warning: data definition has no type or storage class
include/proto.h:250: error: conflicting types for ‘fn_name’
include/proto.h:141: error: previous definition of ‘fn_name’ was here
include/proto.h: In function ‘fn_name’:
include/proto.h:250: error: ‘Key’ undeclared (first use in this function)
include/proto.h:250: error: ‘k’ undeclared (first use in this function)
include/proto.h:250: warning: ISO C90 forbids mixed declarations and code
include/proto.h:250: error: ‘key_path_buffer’ undeclared (first use in this function)
include/proto.h:250: error: ‘CONF_LOCAL_ROOT’ undeclared (first use in this function)
include/proto.h:250: error: ‘path_ptr’ undeclared (first use in this function)
include/proto.h:250: error: ‘smbConfig’ undeclared (first use in this function)
include/proto.h:250: error: ‘KDB_O_ALL’ undeclared (first use in this function)
include/proto.h: At top level:
include/proto.h:356: error: syntax error before ‘.’ token
include/proto.h:356: warning: type defaults to ‘int’ in declaration of ‘FN_LOCAL_KEY_STRING’
include/proto.h:356: warning: function declaration isn’t a prototype
include/proto.h:356: warning: data definition has no type or storage class
include/proto.h:361: error: syntax error before ‘*’ token
include/proto.h:361: warning: function declaration isn’t a prototype
include/proto.h:363: error: syntax error before ‘*’ token
include/proto.h:363: warning: function declaration isn’t a prototype
include/proto.h:364: warning: function declaration isn’t a prototype
include/proto.h:5745: warning: declaration of ‘fn_name’ shadows a global declaration
include/proto.h:250: warning: shadowed declaration is here
make: *** [dynconfig.o] Error 1

-------------- next part --------------
#!/bin/sh

case "$1" in
	3)	
	CONFIGURE_OPTS="--prefix=/opt/samba --disable-pie --enable-developer \
--with-pam --with-pam_smbpass --with-acl-support --with-syslog \
--with-quotas --with-smbmount"
		;;
	4)
	CONFIGURE_OPTS="--prefix=/opt/samba4"
		;;
	*)	
		echo "Usage: $0 {3,4}"
		exit 1
		;;
esac

CONFIGURE_OPTS="${CONFIGURE_OPTS} \
--enable-debug \
--localstatedir=/var/lib/samba \
--with-piddir=/var/run \
--with-logfilebase=/var/log/samba \
--with-privatedir=/etc/samba \
--with-configdir=/etc/samba \
--with-lockdir=/var/lib/samba"

SRCDIR=$2
if [ "x${SRCDIR}" = "x" ]; then
	SRCDIR=.
fi


## compiler and flags
CFLAGS=""
CPPFLAGS=""
LDFLAGS=""
CC="gcc"

#type ccache > /dev/null
#if [ $? = 0 ]; then
#	CC="ccache gcc"
#	export CCACHE_DIR="/misc/src/jerry/.ccache"
#	export CCACHE_LOGFILE="${CCACHE_DIR}/ccache.log"
#
#	if [ ! -d ${CCACHE_DIR} ]; then
#		mkdir -p ${CCACHE_DIR}
#	fi
#fi

## required library paths
DIRPATH=""
for dir in $DIRPATH ; do
	CPPFLAGS="$CPPFLAGS -I$dir/include"
	CFLAGS="$CFLAGS -Wl,-rpath,$dir/lib"
	LDFLAGS="$LDFLAGS -L$dir/lib"
done

CC_VERSION=`${CC} --version | head -1 | awk '{print $3}'`
CC_MAJOR=`echo ${CC_VERSION} | cut -d. -f 1`
CC_MINOR=`echo ${CC_VERSION} | cut -d. -f 2`

## check for gcc 3.4 or later
MAKE_BASICS="proto"
if [ ${CC_MAJOR} -ge 3 ]; then
	if [ ${CC_MAJOR} -gt 3 -o ${CC_MINOR} -ge 4 ]; then
		MAKE_BASICS="${MAKE_BASICS} pch"
	fi
fi

## check for parallel builds
NUM_CPUS=`cat /proc/cpuinfo | grep ^processor | wc -l`
MAKE_ARGS=""
if [ ${NUM_CPUS} -gt 1 ]; then
	MAKE_ARGS="-j${NUM_CPUS}"
fi

echo "SRCDIR=${SRCDIR}"
echo "CPPFLAGS=${CPPFLAGS}"
echo "CFLAGS=${CFLAGS}"
echo "LDFLAGS=${LDFLAGS}"
echo "CC=${CC}"
echo "NUM_CPUS=${NUM_CPUS}"
echo "CC_VERSION=${CC_MAJOR}.${CC_MINOR}"
echo "CONFIGURE_OPTS=${CONFIGURE_OPTS}"
export CPPFLAGS CFLAGS LDFLAGS CC

## configure && build
if [ ! -f ${SRCDIR}/configure ]; then
	(cd ${SRCDIR} && ./autogen.sh ) || exit 1
fi
${SRCDIR}/configure ${CONFIGURE_OPTS}

if [ $? -ne 0 ]; then
	echo "configure failed.  Exiting...."
	exit 1
fi

make showlayout
make ${MAKE_BASICS}
make ${MAKE_ARGS}




More information about the samba-technical mailing list