From 3779776fd4c281f704bd4cbfa3130aa37e34b9cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Groenvall?= Date: Tue, 23 Apr 1996 18:42:57 +0000 Subject: [PATCH] Fix make environment git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@427 ec53bebd-3082-4978-b11e-865c3cabbd6b --- appl/ftp/common/Makefile.in | 6 ++-- appl/ftp/configure | 66 ++++++++++++++++++++++++++++--------- appl/ftp/configure.in | 1 + appl/ftp/ftp/Makefile.in | 12 ++++--- appl/ftp/ftpd/Makefile.in | 12 ++++--- 5 files changed, 70 insertions(+), 27 deletions(-) diff --git a/appl/ftp/common/Makefile.in b/appl/ftp/common/Makefile.in index 5a9fd24b5..3e449ee4b 100644 --- a/appl/ftp/common/Makefile.in +++ b/appl/ftp/common/Makefile.in @@ -17,14 +17,16 @@ prefix = @prefix@ exec_prefix = $(prefix) libdir = $(exec_prefix)/lib -ATHENA = /usr/athena +ATHENA = ../../.. + +INCTOP = $(ATHENA)/include libcommon_OBJS = base64.o glob.o all: libcommon.a .c.o: - $(CC) -c $(CFLAGS) -I. -I.. -I$(ATHENA)/include $(DEFS) $< + $(CC) -c $(CFLAGS) -I$(srcdir) -I.. -I$(INCTOP) $(DEFS) $< libcommon.a: $(libcommon_OBJS) ar cr libcommon.a $(libcommon_OBJS) diff --git a/appl/ftp/configure b/appl/ftp/configure index 34ce3b8c4..e9003e09b 100755 --- a/appl/ftp/configure +++ b/appl/ftp/configure @@ -725,6 +725,39 @@ else fi echo "$ac_t""$CPP" 1>&6 +for ac_prog in 'bison -y' byacc +do +# Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_YACC="$ac_prog" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +YACC="$ac_cv_prog_YACC" +if test -n "$YACC"; then + echo "$ac_t""$YACC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$YACC" && break +done +test -n "$YACC" || YACC="yacc" + # If we cannot run a trivial program, we must be cross compiling. echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6 @@ -735,11 +768,11 @@ else ac_cv_c_cross=yes else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } +{ (eval echo configure:776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } if test -s conftest && (./conftest; exit) 2>/dev/null; then ac_cv_c_cross=no else @@ -762,12 +795,12 @@ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:771: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:804: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* @@ -807,7 +840,7 @@ if eval "test \"\$ac_cv_func_socket\" != yes" ; then LIBS="$ac_lib $ac_save_LIBS" fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; }; then +if { (eval echo configure:852: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then rm -rf conftest* eval "if test -n \"$ac_lib\";then ac_cv_funclib_socket=$ac_lib; else ac_cv_funclib_socket=yes; fi";break fi @@ -885,7 +918,7 @@ if eval "test \"\$ac_cv_func_gethostbyname\" != yes" ; then LIBS="$ac_lib $ac_save_LIBS" fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; }; then +if { (eval echo configure:930: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then rm -rf conftest* eval "if test -n \"$ac_lib\";then ac_cv_funclib_gethostbyname=$ac_lib; else ac_cv_funclib_gethostbyname=yes; fi";break fi @@ -955,7 +988,7 @@ if eval "test \"`echo '$''{'ac_cv_struct_ut_host'+set}'`\" = set"; then else cat > conftest.$ac_ext < @@ -970,7 +1003,7 @@ p = ut.ut_host; ; return 0; } EOF -if { (eval echo configure:974: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1007: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_ut_host=yes else @@ -998,7 +1031,7 @@ if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; }; then +if { (eval echo configure:1057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -1055,7 +1088,7 @@ if test "$cross_compiling" = yes; then : else cat > conftest.$ac_ext < @@ -1077,7 +1110,7 @@ int main() } EOF -{ (eval echo configure:1081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } +{ (eval echo configure:1114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } if test -s conftest && (./conftest; exit) 2>/dev/null; then ac_cv_func_getcwd_broken=yes else @@ -1104,7 +1137,7 @@ if eval "test \"`echo '$''{'ac_cv_var___progname'+set}'`\" = set"; then else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; }; then +if { (eval echo configure:1149: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then rm -rf conftest* ac_cv_var___progname=yes else @@ -1251,6 +1284,7 @@ s%@mandir@%$mandir%g s%@CC@%$CC%g s%@RANLIB@%$RANLIB%g s%@CPP@%$CPP%g +s%@YACC@%$YACC%g CEOF EOF diff --git a/appl/ftp/configure.in b/appl/ftp/configure.in index 4d97137f1..095987602 100644 --- a/appl/ftp/configure.in +++ b/appl/ftp/configure.in @@ -14,6 +14,7 @@ AC_PREFIX_DEFAULT(/usr/athena) AC_PROG_CC AC_PROG_RANLIB AC_PROG_CPP +AC_PROG_YACC AC_C_CROSS diff --git a/appl/ftp/ftp/Makefile.in b/appl/ftp/ftp/Makefile.in index c92ddd2fa..c0b118745 100644 --- a/appl/ftp/ftp/Makefile.in +++ b/appl/ftp/ftp/Makefile.in @@ -10,6 +10,7 @@ CC = @CC@ RANLIB = @RANLIB@ DEFS = @DEFS@ CFLAGS = @CFLAGS@ +LIBS = @LIBS@ INSTALL = @INSTALL@ @@ -17,23 +18,24 @@ prefix = @prefix@ exec_prefix = $(prefix) libdir = $(exec_prefix)/lib -ATHENA = /usr/athena -LIBTOP = ../../../lib +ATHENA = ../../.. -LIBS = -L$(LIBTOP)/krb -lkrb -L$(LIBTOP)/des -ldes $(LIBTOP)/roken/libroken.a +INCTOP = $(ATHENA)/include + +LIBTOP = $(ATHENA)/lib ftp_OBJS = cmds.o cmdtab.o ftp.o krb4.o main.o ruserpass.o domacro.o globals.o kauth.o all: ftp .c.o: - $(CC) -c $(CFLAGS) -I.. -I$(srcdir)/.. -I../common -I$(srcdir)/../common -I$(ATHENA)/include $(DEFS) $< + $(CC) -c $(CFLAGS) -I$(srcdir) -I.. -I$(srcdir)/../common -I$(INCTOP) $(DEFS) $< install: ftp: $(ftp_OBJS) ../common/libcommon.a - $(CC) -o ftp $(ftp_OBJS) ../common/libcommon.a -L$(ATHENA)/lib -lkrb -ldes $(LIBS) + $(CC) -o ftp $(ftp_OBJS) ../common/libcommon.a -L$(LIBTOP)/krb -lkrb -L$(LIBTOP)/des -ldes -L$(LIBTOP)/roken -lroken $(LIBS) clean cleandir: rm -f *~ *.o core ftp \#* diff --git a/appl/ftp/ftpd/Makefile.in b/appl/ftp/ftpd/Makefile.in index 4954d9ccb..81607dcae 100644 --- a/appl/ftp/ftpd/Makefile.in +++ b/appl/ftp/ftpd/Makefile.in @@ -7,9 +7,11 @@ VPATH = @srcdir@ SHELL = /bin/sh CC = @CC@ +YACC = @YACC@ RANLIB = @RANLIB@ DEFS = @DEFS@ CFLAGS = @CFLAGS@ +LIBS = @LIBS@ INSTALL = @INSTALL@ @@ -17,22 +19,24 @@ prefix = @prefix@ exec_prefix = $(prefix) libdir = $(exec_prefix)/lib -LIBTOP = ../../../lib +ATHENA = ../../.. -LIBS = ../common/libcommon.a -L$(LIBTOP)/kafs -lkafs -L$(LIBTOP)/krb -lkrb -L$(LIBTOP)/des -ldes $(LIBTOP)/roken/libroken.a +INCTOP = $(ATHENA)/include + +LIBTOP = $(ATHENA)/lib ftpd_OBJS = ftpd.o ftpcmd.o logwtmp.o popen.o auth.o krb4.o kauth.o klogin.o all: ftpd .c.o: - $(CC) -c $(CFLAGS) -I. -I$(srcdir) -I.. -I$(srcdir)/.. -I../common -I$(srcdir)/../common -I$(srcdir)/include $(DEFS) $< + $(CC) -c $(CFLAGS) -I$(srcdir) -I.. -I$(srcdir)/../common -I$(INCTOP) $(DEFS) $< install: ftpd: $(ftpd_OBJS) - $(CC) -o ftpd $(ftpd_OBJS) $(LIBS) + $(CC) -o ftpd $(ftpd_OBJS) ../common/libcommon.a -L$(LIBTOP)/kafs -lkafs -L$(LIBTOP)/krb -lkrb -L$(LIBTOP)/des -ldes -L$(LIBTOP)/roken -lroken $(LIBS) ftpcmd.c: ftpcmd.y $(YACC) $(YFLAGS) $<