OpenWrt Forum Archive

Topic: samba3

The content of this topic has been archived on 3 May 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I've posted the samba3 build package at http://www.seiner.com/samba3.tar.gz

This is based on the patch by forum2006: http://forum.openwrt.org/viewtopic.php?id=12939.

This should correctly build samba 3.0.26b

It will build 5 packages:

samba3-common
samba3-server
samba3-client
samba3-smbmount
samba3-cifsmount

The reason I broke it up is because samba3 is *BIG* - about 4 MB total, so pick and choose only the packages you need.

It also contains a couple of small utils - scan and unscan - which will mount and unmount shares automagically.

Comments welcome.

--Yan

Great work!

Unfortunately, it won't compile for me (using r10173):

make[4]: Leaving directory `/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source'
make -C /home/km/trunk/build_dir/mipsel/samba-3.0.26a/source prefix="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr" BASEDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr" BINDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/bin" SBINDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/bin" LIBDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/lib" VARDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/var/log/samba" MANDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/share/man" SWATDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/swat" LOCKDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/var/run/samba" SAMBABOOK="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/swat/using_samba" CODEPAGEDIR="/home/km/trunk/build_dir/mipsel/samba-3.0.26a/ipkg-install/usr/share/samba" installservers installbin installcifsmount
make[4]: Entering directory `/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source'
Using FLAGS      =  -O -D_SAMBA_BUILD_=3 -I/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source/popt -I/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source/iniparser/src -Iinclude -I./include  -I. -I. -I./lib/replace -I./lib/talloc -I./tdb/include -I./libaddns -I./librpc -DHAVE_CONFIG_H     -I/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source/lib -D_SAMBA_BUILD_=3
      PICFLAG    = -fPIC
      LIBS       = -lcrypt -lresolv -ldl
      LDFLAGS    = -pie 
      DYNEXP     = -Wl,--export-dynamic
      LDSHFLAGS  = -shared -Wl,-Bsymbolic 
      SHLIBEXT   = so
      SONAMEFLAG = -Wl,-soname=
Building include/proto.h
creating /home/km/trunk/build_dir/mipsel/samba-3.0.26a/source/include/proto.h
/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source/include/proto.h unchanged
mkdir: cannot create directory `///etc/samba': Permission denied
Failed to make directory ///etc/samba 
make[4]: *** [installdirs] Error 1
make[4]: Leaving directory `/home/km/trunk/build_dir/mipsel/samba-3.0.26a/source'
make[3]: *** [/home/km/trunk/build_dir/mipsel/samba-3.0.26a/.built] Error 2
make[3]: Leaving directory `/home/km/local-packages/samba3'
make[2]: *** [package/local-packages/samba3/compile] Error 2
make[2]: Leaving directory `/home/km/trunk'
make[1]: *** [/home/km/trunk/staging_dir/mipsel/stamp/.package_compile] Error 2
make[1]: Leaving directory `/home/km/trunk'
make: *** [world] Error 2

Hmmm... Could you please look in the Makefile and look at the install for samba-common?  It looks like $(1) isn't being set correctly.  Maybe some echo $(1) could be useful.

Or perhaps something in the build environment for recent SVN  has changed?  Could someone comment?

The problem line is:

$(INSTALL_DIR) $(1)/etc/samba


It build with my (older) SVN:

URL: https://svn.openwrt.org/openwrt/trunk                                     
Repository Root: https://svn.openwrt.org/openwrt                               
Repository UUID: 3c298f89-4303-0410-b956-a3cf2f4a3e73                           
Revision: 9579                                                                 
Node Kind: directory                                                           
Schedule: normal                                                               
Last Changed Author: nbd                                                       
Last Changed Rev: 9579                                                         
Last Changed Date: 2007-11-17 08:01:28 -0800 (Sat, 17 Nov 2007)

I tried again, and it fails in the Build/Compile step, specifically

        $(MAKE) -C $(PKG_BUILD_DIR)/source \
                prefix="$(PKG_INSTALL_DIR)/usr" \
                BASEDIR="$(PKG_INSTALL_DIR)/usr" \
                BINDIR="$(PKG_INSTALL_DIR)/usr/bin" \
                SBINDIR="$(PKG_INSTALL_DIR)/usr/bin" \
                LIBDIR="$(PKG_INSTALL_DIR)/usr/lib" \
                VARDIR="$(PKG_INSTALL_DIR)/var/log/samba" \
                MANDIR="$(PKG_INSTALL_DIR)/usr/share/man" \
                SWATDIR="$(PKG_INSTALL_DIR)/usr/swat" \
                LOCKDIR="$(PKG_INSTALL_DIR)/var/run/samba" \
                SAMBABOOK="$(PKG_INSTALL_DIR)/usr/swat/using_samba" \
                CODEPAGEDIR="$(PKG_INSTALL_DIR)/usr/share/samba" \
                installservers installbin installcifsmount


#               CONFIGDIR="$(PKG_INSTALL_DIR)/etc/samba" \
#               PRIVATEDIR="$(PKG_INSTALL_DIR)/etc/samba" \

Is the one that fails. I let it echo something before and after, and only the one before was shown. $(1) was set to "samba3-common" in that step.
Don't know if that helps.
KM.

OK, move the two commented lines back into the MAKE command:

#               CONFIGDIR="$(PKG_INSTALL_DIR)/etc/samba" \
#               PRIVATEDIR="$(PKG_INSTALL_DIR)/etc/samba" \

Insert them above the install* line in the MAKE and remove the #:

$(MAKE) -C $(PKG_BUILD_DIR)/source \
                prefix="$(PKG_INSTALL_DIR)/usr" \
                BASEDIR="$(PKG_INSTALL_DIR)/usr" \
                BINDIR="$(PKG_INSTALL_DIR)/usr/bin" \
                SBINDIR="$(PKG_INSTALL_DIR)/usr/bin" \
                LIBDIR="$(PKG_INSTALL_DIR)/usr/lib" \
                VARDIR="$(PKG_INSTALL_DIR)/var/log/samba" \
                MANDIR="$(PKG_INSTALL_DIR)/usr/share/man" \
                SWATDIR="$(PKG_INSTALL_DIR)/usr/swat" \
                LOCKDIR="$(PKG_INSTALL_DIR)/var/run/samba" \
                SAMBABOOK="$(PKG_INSTALL_DIR)/usr/swat/using_samba" \
                CODEPAGEDIR="$(PKG_INSTALL_DIR)/usr/share/samba" \
                CONFIGDIR="$(PKG_INSTALL_DIR)/etc/samba" \
                PRIVATEDIR="$(PKG_INSTALL_DIR)/etc/samba" \
                installservers installbin installcifsmount

I'm guessing since it works fine on my system....

--Yan

That did it, it now compiles successfully, and I see the 4 MB of packages.
Thank you!

KM

Any binary packages for this?

what platform?

Hi,

I don't have my build environment at the moment.

Any chance that one of you could post binaries for brcm47xx-2.6?

Thanks
W

Does anyone have a binary samba 3 package available for the Asus wl500g platform?

Thanks in advance!

Jeroen

In trunk there is now a samba3 package included.

Well, if you really don't like compiling you can use the samba3 binary package from here: http://universe.freifunk-halle.net/kamikaze/nightly/

(Last edited by Yanira on 17 Sep 2008, 10:05)

Thanks! I was able to install the samba3 package and it's now running without problems.

Jeroen

hi,

I followed the instructions and i can´t compiled the samba:

./autogen.sh: running script/mkversion.sh
./script/mkversion.sh: 'include/version.h' created for Samba("3.0.26a")
./autogen.sh: running autoheader -I. -Ilib/replace
configure.in:330: error: AC_REQUIRE: circular dependency of AC_AIX
lib/replace/autoconf-2.60.m4:182: AC_USE_SYSTEM_EXTENSIONS is expanded from...
../../lib/autoconf/specific.m4:451: AC_AIX is expanded from...
lib/replace/autoconf-2.60.m4:182: AC_USE_SYSTEM_EXTENSIONS is expanded from...
configure.in:330: the top level
autom4te: /usr/bin/m4 failed with exit status: 1
autoheader: '/media/disk_2/kamikaze2/staging_dir/host/bin/autom4te' failed with exit status: 1
--: ./configure: No such file or directory
make[2]: *** [/media/disk_2/kamikaze2/build_dir/i386/samba-3.0.26a/.built] Error 127
make[2]: Leaving directory `/media/disk_2/kamikaze2/feeds/packages/net/samba3'
make[1]: *** [package/feeds/packages/samba3/compile] Error 2
make[1]: Leaving directory `/media/disk_2/kamikaze2'
make: *** [package/samba3/compile] Error 2


this is the error messages.
wtf?

regards
yamshee

(Last edited by yamshee70 on 24 Feb 2009, 02:54)

I've got exactly same error.
Anybody knows how to fix it?

dz wrote:

I've got exactly same error.
Anybody knows how to fix it?

I give a tip onto the compiler environment.

How big is the full samba package?

~ JoW

What do u mean exactly?

The size is doesen't matter.

samba3-common
samba3-server
samba3-client
samba3-smbmount
samba3-cifsmount
samba3-libs
samba3-scan

7 packs is the full samba3, everybody will choose which is the packages that would like to install.

(Last edited by yamshee70 on 13 Mar 2009, 00:11)

The discussion might have continued from here.