Getting ready for 2.2.2.

Eric Boehm boehm at
Tue Sep 18 07:26:05 GMT 2001

On Mon, Sep 17, 2001 at 03:55:09PM -0700, Jeremy Allison wrote:
>>>>> "Jeremy" == Jeremy Allison <jra at> writes:

    Jeremy> Hi all, I know of one showstopper (the WINS re-registation
    Jeremy> bug) I need to fix before Samba 2.2.2 is in a shippable
    Jeremy> state (ie. then Gerry, John and I do all our regression
    Jeremy> testing :-).

    Jeremy> If you think different, now's the time to say so :-).

There is a problem with the Makefile generated by configure. 

I just tried building SAMBA_2_2 under Solaris 8 with Sun Workshop 6 C

grep '\-shared' Makefile
        @$(LD) -shared -o $@ $(PICOBJS) $(LIBS)
        @$(LD) -32 -shared -o $@ $(PICOBJS32) $(LIBS)
          $(CC) -shared -o bin/$ $(LIBSMBCLIENT_PICOBJS) $(LIBS); \
        @echo Linking libsmbclient non-shared library bin/$@.a
        $(LD) -shared -symbolic -o $@ $(PAM_SMBPASS_OBJ) -lpam $(LIBS) -lc
        @$(LD) -shared -o $@ $(NSS_OBJ) -lc
        @$(LINK) -shared -o $@ $(WINBIND_NSS_PICOBJS)
        @$(LINK) -shared -o $@ $(PAM_WINBIND_OBJ)

"-shared" is really only appropriate if you are using GCC. The above
corresponds to LDSHFLAGS and should be:

a. -G    for ld on Solaris
b. -KPIC for cc on Solaris (see third line of output above)
c. -fPIC for gcc

"-symbolic" should be "-B symbolic" under Solaris cc/ld

LDSHFLAGS is set at line 8254 of configure but is not set correctly

Additionally, PICFLAG is set again for some OS's even though it had
been determined earlier in the script.

Linking of PAM_SMBPASS_OBJO should use a pattern replacement instead of
hardcoding "-symbolic" into I added @SYMBOLICFLAGS at .

Additionally, linking of results in an undefined symbol
vasprintf because lib/snprintf.o isn't included in the link. I added
lib/snprintf.o to PAM_SMBPASS_OBJ0

I've attached some potential diffs. Feel free to use, modify or ignore

Eric M. Boehm                               boehm at
-------------- next part --------------
--- configure.orig	Tue Sep 18 09:41:18 2001
+++ configure	Tue Sep 18 10:21:50 2001
@@ -8252,6 +8252,7 @@
 # these are the defaults, good for lots of systems
@@ -8271,7 +8272,10 @@
 		*solaris*) cat >> confdefs.h <<\EOF
 #define SUNOS5 1
+                        if test "$GCC" != "yes"; then
+			    LDSHFLAGS="-G"
+                            SYMBOLICFLAGS="-B symbolic"
+                        fi
 		*sunos*) cat >> confdefs.h <<\EOF
 #define SUNOS4 1
@@ -12521,6 +12525,7 @@
-------------- next part --------------
---	Tue Sep 18 08:45:44 2001
+++	Tue Sep 18 10:23:00 2001
@@ -353,7 +353,7 @@
 		lib/charset.o lib/util_file.o lib/kanji.o lib/genrand.o \
 		lib/username.o lib/charcnv.o lib/time.o lib/md4.o \
 		lib/util_unistr.o lib/signal.o lib/talloc.o lib/ms_fnmatch.o \
-		lib/util_sock.o lib/smbrun.o lib/util_sec.o \
+		lib/util_sock.o lib/smbrun.o lib/util_sec.o lib/snprintf.o \
 		ubiqx/ubi_sLinkList.o libsmb/smbencrypt.o libsmb/smbdes.o \
@@ -617,7 +617,7 @@
 bin/pam_smbpass. at SHLIBEXT@: $(PAM_SMBPASS_OBJ)
 	@echo Linking shared library $@
-	$(LD) @LDSHFLAGS@ -symbolic -o $@ $(PAM_SMBPASS_OBJ) -lpam $(LIBS) -lc
 nsswitch/ $(NSS_OBJ)
 	@echo "Linking $@"

More information about the samba-technical mailing list