Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 446190

Summary: net-fs/samba-3.5.19: cross compile fixes
Product: Gentoo Linux Reporter: Ambroz Bizjak <ambrop7>
Component: [OLD] ServerAssignee: Gentoo's SAMBA Team <samba>
Severity: normal CC: bkohler, steev, zerochaos
Priority: Normal Keywords: PATCH
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---
Attachments: samba-3.5.19.ebuild-cross-compile.patch

Description Ambroz Bizjak 2012-12-06 01:35:34 UTC
Samba has some problems related to cross-compilation. The following variables should to be set before running configure:

- samba_cv_CC_NEGATIVE_ENUM_VALUES=yes, to prevent a failing configure run-test

- samba_cv_USE_SETREUID=yes, to make Samba use setreuid() and setregid() to switch uid/gid when clients connect. The configure script will look for various setuid functions and test them using run-tests, but since all the run-tests will fail, it will find no useful functions. Configure wont't fail, but the resulting build will be broken.

- libreplace_cv_HAVE_SECURE_MKSTEMP=yes (this isn't strictly necessary, I just set it because that's how it gets detected on native)

Also, --with-libiconv="${EROOT}/usr" needs to be passed to configure, or -L/usr/lib will for some reason be added to link flags and cause hundreds of "skipping incompatible" messages

Reproducible: Always
Comment 1 Ambroz Bizjak 2012-12-06 01:37:22 UTC
Created attachment 331608 [details, diff]

Ebuild patch. Note I haven't patched samba >=3.6 because of bug 411649.
Comment 2 Rick Farina (Zero_Chaos) gentoo-dev 2012-12-06 05:03:46 UTC
we asked him to add us to the cc, thanks
Comment 3 Ben Kohler gentoo-dev 2020-01-07 20:14:49 UTC
If this is still needed, let's get a fresh bug report for samba4