1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

fixed the Makefile so we don't rebuild libsmbclient and build_env.h

(and thus smbd) every time
This commit is contained in:
Andrew Tridgell -
parent bc7963bd64
commit e78d0a3615
4 changed files with 655 additions and 642 deletions

View File

@ -58,9 +58,6 @@ SWATDIR = @swatdir@
# the directory where lock files go
LOCKDIR = @lockdir@
# libsmbclient support here
BLDSHARED = @BLDSHARED@
PASSWD_FLAGS = -DSMB_PASSWD_FILE=\"$(SMB_PASSWD_FILE)\" -DPRIVATE_DIR=\"$(PRIVATE_DIR)\"
FLAGS1 = $(CFLAGS) -Iinclude -I$(srcdir)/include -I$(srcdir)/ubiqx -I$(srcdir)/smbwrapper $(CPPFLAGS) -DLOGFILEBASE=\"$(LOGFILEBASE)\"
FLAGS2 = -DCONFIGFILE=\"$(CONFIGFILE)\" -DLMHOSTSFILE=\"$(LMHOSTSFILE)\"
@ -484,7 +481,7 @@ bin/.dummy:
dir=bin $(MAKEDIR); fi
@: >> $@ || : > $@ # what a fancy emoticon!
bin/smbd: build_env $(SMBD_OBJ) bin/.dummy
bin/smbd: $(SMBD_OBJ) bin/.dummy
@echo Linking $@
@$(CC) $(FLAGS) -o $@ $(SMBD_OBJ) $(LDFLAGS) $(LIBS)
@ -613,13 +610,15 @@ bin/smbwrapper.32.@SHLIBEXT@: $(PICOBJS32)
@echo Linking shared library $@
@$(LD) -32 @LDSHFLAGS@ -o $@ $(PICOBJS32) $(LIBS)
libsmbclient: $(LIBSMBCLIENT_PICOBJS)
@if [ $(BLDSHARED) = true ]; then \
echo Linking libsmbclient shared library bin/$@.@SHLIBEXT@; \
$(SHLD) @LDSHFLAGS@ -o bin/$@.@SHLIBEXT@ $(LIBSMBCLIENT_PICOBJS) $(LIBS); \
fi
@echo Linking libsmbclient non-shared library bin/$@.a
-$(AR) -rc bin/$@.a $(LIBSMBCLIENT_PICOBJS)
bin/libsmbclient.@SHLIBEXT@: $(LIBSMBCLIENT_PICOBJS)
echo Linking libsmbclient shared library $@
$(SHLD) @LDSHFLAGS@ -o $@ $(LIBSMBCLIENT_PICOBJS) $(LIBS)
bin/libsmbclient.a: $(LIBSMBCLIENT_PICOBJS)
@echo Linking libsmbclient non-shared library $@
-$(AR) -rc $@ $(LIBSMBCLIENT_PICOBJS)
libsmbclient: bin/libsmbclient.a @LIBSMBCLIENT_SHARED@
bin/smbsh: $(SMBSH_OBJ) bin/.dummy
@echo Linking $@
@ -702,30 +701,27 @@ winbindd_proto:
-h _WINBINDD_PROTO_H_ nsswitch/winbindd_proto.h \
$(WINBINDD_OBJ1)
delproto:
@/bin/rm -f $(srcdir)/include/proto.h
delheaders:
@/bin/rm -f $(srcdir)/include/proto.h $(srcdir)/include/build_env.h
# we want proto.h to be rebuilt if it doesn't exist, but not rebuilt every time
.proto.stamp: include/proto.h
# we want our generated headers to be rebuilt if they don't exist, but not rebuilt every time
.headers.stamp: include/proto.h include/build_env.h
@[ -f $@ ] || touch $@
$(PROTO_OBJ) : .proto.stamp
$(PROTO_OBJ) : .headers.stamp
include/proto.h:
@echo rebuilding include/proto.h
@cd $(srcdir) && $(AWK) -f script/mkproto.awk `echo $(PROTO_OBJ) | tr ' ' '\n' | sed -e 's/\.o/\.c/g' | sort -u | egrep -v 'ubiqx/|wrapped'` > include/proto.h
proto: delproto include/proto.h
delbuild_env:
@/bin/rm -f include/build_env.h
include/build_env.h:
@echo rebuilding include/build_env.h
@cd $(srcdir) && $(SHELL) script/build_env.sh $(srcdir) $(builddir) $(CC) > include/build_env.h
build_env: delbuild_env include/build_env.h
@rm -f smbd/build_options.o
headers: delheaders include/proto.h include/build_env.h
proto: headers
etags:
etags `find $(srcdir) -name "*.[ch]" | grep -v /CVS/`

1244
source/configure vendored

File diff suppressed because it is too large Load Diff

View File

@ -18,7 +18,7 @@ AC_SUBST(PICFLAG)
AC_SUBST(PICSUFFIX)
AC_SUBST(POBAD_CC)
AC_SUBST(SHLIBEXT)
AC_SUBST(BLDSHARED)
AC_SUBST(LIBSMBCLIENT_SHARED)
# compile with optimisation and without debugging by default
CFLAGS="-O ${CFLAGS}"
@ -739,6 +739,13 @@ case "$host_os" in
;;
esac
# this updates our target list if we can build shared libs
if test $BLDSHARED = true; then
LIBSMBCLIENT_SHARED=bin/libsmbclient.$SHLIBEXT
else
LIBSMBCLIENT_SHARED=
fi
################
AC_CACHE_CHECK([for long long],samba_cv_have_longlong,[

View File

@ -1,4 +1,4 @@
/* include/config.h.in. Generated automatically from configure.in by autoheader. */
/* include/config.h.in. Generated automatically from configure.in by autoheader 2.13. */
/* Define if on AIX 3.
System headers sometimes define this.