> -----Original Message----- > From: Christophe Alexandre [mailto:Christophe.Alexandre@lip6.fr] > Sent: Friday, January 11, 2002 6:28 AM ... > For the ocp and ocr installation, Just ask if you've got problems. > The multi architecture build should be quite easy for those two. > For your add to the autogen.sh script, could you please explain > me more the use of your add, so I can add it to the script. > > Christophe. Actually, my problem with multi-architecture may be due my lack of familiarity with automake and libtools. Specifically, "aclocal", called by "autogen.sh" did not know to load "/usr/local/share/aclocal" files, until I add the "-I" option to reference this directory (see below). I installed autoconf, et al from the Cygwin web site, then libtools from the GNU site. I just wanted to kludge the build process with a minimum disturbance to the source tree, so I didn't modify the multi-architecture code to take SRCDIR and BUILDIR as independent trees. Instead, I created links from the BUILDIR tree to the SRCDIR tree to access all source and control (Makefile, configure.in, etc) file. Once I did this, the build proceeded normally with only derived files being created in the BUILDIR. Comments and feedback is appreciated. Art Note: aclocal.m4 was regenerated by aclocal 1.5 vs original 1.4. I only posted the ocp changes, since ocr is similar. I am only posting changes to the Makefiles for alcban,algue, amg,simut,asimut/cst,asimut/scheduler,asimut/simulad,asimut/tests. The entire diff files is 700 KB (19916 lines), but it includes the aclocal.m4 files which were regenerated and a few immaterial changes. The main changes in the Makefiles is the replacement of implicit and explicit rules with pattern rules and simpler Bison and Flex command options vs the old YACC and LEX in some of the original Makefiles. They also rely a lot on mkdir and symlink creation to the source. --- changes to ocp and ocr control files -- "diff -c" format --- Index: sources/ocp/Makefile =================================================================== RCS file: /cvs/alliance/sources/ocp/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/ocp/Makefile 3 Jan 2002 19:17:44 -0000 1.1 --- sources/ocp/Makefile 11 Jan 2002 06:25:20 -0000 *************** *** 1,17 **** # # Copyright (C) 1996-1998 Olivier Sirol ! # $Id: Makefile,v 1.1 2002/01/03 19:17:44 pinaar Exp $ # ! all : ! ./autogen.sh ! mkdir $(ALLIANCE_OS)_tmp ! cd $(ALLIANCE_OS)_tmp && ../configure --prefix=$(ALLIANCE_INSTALL_DIR) && gm ake install clean : rm -fr $(ALLIANCE_OS)_tmp .PHONY : list_files --- 1,34 ---- # # Copyright (C) 1996-1998 Olivier Sirol ! # $Id: Makefile,v 1.4 2002/01/04 17:31:15 czo Exp $ # + include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk + include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/ocp ! # Creating a link for configure.in, but modifying autogen.sh ! # may be simpler ! # Do not re-build Makefiles if configured all : ! @if [ -f $(ALLIANCE_OS)_tmp/config.status ]; then\ ! cd $(ALLIANCE_OS)_tmp && make install;\ ! else\ ! if [ ! -L configure.in ]; then ln -s $(sdir)/configure.in;fi;\ ! if [ ! -L Makefile.am ]; then ln -s $(sdir)/Makefile.am;fi;\ ! if [ ! -L aclocal.m4 ]; then ln -s $(sdir)/aclocal.m4;fi;\ ! if [ ! -L ltconfig ]; then ln -s $(SRCDIR)/distrib/autoconf/ltconfig;fi;\ ! if [ ! -L src ]; then ln -s $(sdir)/src;fi;\ ! $(sdir)/autogen.sh;\ ! mkdir -p $(ALLIANCE_OS)_tmp;\ ! cd $(ALLIANCE_OS)_tmp && ../configure --prefix=$(ALLIANCE_INSTALL_DIR) && make install;\ ! fi clean : rm -fr $(ALLIANCE_OS)_tmp + + realclean: clean + $(RM) -f $(TARGET_BIN)/ocp .PHONY : list_files Index: sources/ocp/autogen.sh =================================================================== RCS file: /cvs/alliance/sources/ocp/autogen.sh,v retrieving revision 1.1 diff -b -i -c -r1.1 autogen.sh *** sources/ocp/autogen.sh 3 Jan 2002 19:17:42 -0000 1.1 --- sources/ocp/autogen.sh 11 Jan 2002 04:23:04 -0000 *************** *** 53,59 **** fi echo "Running aclocal ..." ! aclocal -I . if grep "^AM_CONFIG_HEADER" configure.in >/dev/null; then echo "Running autoheader..." autoheader --- 53,59 ---- fi echo "Running aclocal ..." ! aclocal -I . -I /usr/local/share/aclocal if grep "^AM_CONFIG_HEADER" configure.in >/dev/null; then echo "Running autoheader..." autoheader Index: sources/alcban/Makefile =================================================================== RCS file: /cvs/alliance/sources/alcban/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/alcban/Makefile 3 Jan 2002 19:17:38 -0000 1.1 --- sources/alcban/Makefile 7 Jan 2002 03:23:26 -0000 *************** *** 26,37 **** # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.1 2002/01/03 19:17:38 pinaar Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk #TARGET_BIN =. --- 26,38 ---- # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.3 1999/11/05 16:43:22 czo Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/alcban #TARGET_BIN =. *************** *** 59,73 **** LOCAL_OBJ = alcbanner.o ! .c.o: ! $(CC) -c -o $@ $(LOCAL_CFLAGS) $(LOCAL_INC) $< all : $(EXEC) $(EXEC) : $(LOCAL_OBJ) ! $(CC) -o $(EXEC) $(LOCAL_CFLAGS) $(LOCAL_OBJ) $(LOCAL_LIB) -lm clean : --- 60,74 ---- LOCAL_OBJ = alcbanner.o ! %.o: $(sdir)/%.c ! $(CC) -c $(LOCAL_CFLAGS) $(LOCAL_INC) $< all : $(EXEC) $(EXEC) : $(LOCAL_OBJ) ! $(CC) -o $(EXEC) $(LOCAL_CFLAGS) $< $(LOCAL_LIB) -lm clean : Index: sources/algue/Makefile =================================================================== RCS file: /cvs/alliance/sources/algue/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/algue/Makefile 3 Jan 2002 19:22:12 -0000 1.1 --- sources/algue/Makefile 9 Jan 2002 09:39:18 -0000 *************** *** 26,38 **** # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.1 2002/01/03 19:22:12 pinaar Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk ! #TARGET_BIN =. --- 26,38 ---- # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.5 2001/05/22 15:11:51 czo Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk ! sdir=$(SRCDIR)/algue #TARGET_BIN =. *************** *** 41,51 **** all : $(TARGET_BIN)/algue $(TARGET_BIN)/ale ! $(TARGET_BIN)/algue : algue ! $(CP) algue $(TARGET_BIN)/algue ! $(TARGET_BIN)/ale : ale ! $(CP) ale $(TARGET_BIN)/ale clean : --- 41,51 ---- all : $(TARGET_BIN)/algue $(TARGET_BIN)/ale ! $(TARGET_BIN)/algue : $(sdir)/algue ! $(CP) $< $(TARGET_BIN)/algue ! $(TARGET_BIN)/ale : $(sdir)/ale ! $(CP) $< $(TARGET_BIN)/ale clean : Index: sources/amg/Makefile =================================================================== RCS file: /cvs/alliance/sources/amg/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/amg/Makefile 3 Jan 2002 19:22:13 -0000 1.1 --- sources/amg/Makefile 7 Jan 2002 03:25:06 -0000 *************** *** 25,30 **** --- 25,31 ---- include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/amg LOCAL_TRGBIN = $(TARGET_BIN) LOCAL_TRGLIB = $(TARGET_LIB) *************** *** 87,116 **** $(STRIP) $(LOCAL_TRGBIN)/amg $(LOCAL_TRGLIB)/$(AMG_LIB) : $(OBJ) ! $(CP) $(AMG_INC) $(LOCAL_TRGINC)/ $(AR) $(ARFLAGS) $(LOCAL_TRGLIB)/$(AMG_LIB) $(OBJ) $(RANLIB) $(LOCAL_TRGLIB)/$(AMG_LIB) ! main.o : main.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c main.c ! ! dispatch.o : dispatch.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c dispatch.c ! ! amg_layout.o : amg_layout.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c amg_layout.c ! ! amg_data.o : amg_data.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c amg_data.c ! ! amg_vhdl.o : amg_vhdl.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c amg_vhdl.c ! ! amg_icon.o : amg_icon.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c amg_icon.c ! ! amg_pat.o : amg_pat.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c amg_pat.c checkin : echo "y" > 1 --- 88,99 ---- $(STRIP) $(LOCAL_TRGBIN)/amg $(LOCAL_TRGLIB)/$(AMG_LIB) : $(OBJ) ! $(CP) $(sdir)/$(AMG_INC) $(LOCAL_TRGINC)/ $(AR) $(ARFLAGS) $(LOCAL_TRGLIB)/$(AMG_LIB) $(OBJ) $(RANLIB) $(LOCAL_TRGLIB)/$(AMG_LIB) ! %.o : $(sdir)/%.c ! $(CC) $(CFLAGS) $(LOCAL_CFLAGS) -c $< checkin : echo "y" > 1 Index: sources/asimut/Makefile =================================================================== RCS file: /cvs/alliance/sources/asimut/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/asimut/Makefile 3 Jan 2002 19:22:20 -0000 1.1 --- sources/asimut/Makefile 7 Jan 2002 03:27:10 -0000 *************** *** 23,30 **** --- 23,43 ---- include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/asimut all : + @if [ ! -L cst/Makefile ]; then mkdir cst ;\ + ln -s $(sdir)/cst/Makefile cst ;\ + fi + @if [ ! -L scheduler/Makefile ]; then mkdir scheduler ;\ + ln -s $(sdir)/scheduler/Makefile scheduler ;\ + fi + @if [ ! -L simulad/Makefile ]; then mkdir simulad ;\ + ln -s $(sdir)/simulad/Makefile simulad ;\ + fi + @if [ ! -L tests/Makefile ]; then mkdir tests ;\ + ln -s $(sdir)/tests/Makefile tests ;\ + fi cd cst ; $(MAKE) cd scheduler ; $(MAKE) cd simulad ; $(MAKE) Index: sources/asimut/cst/Makefile =================================================================== RCS file: /cvs/alliance/sources/asimut/cst/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/asimut/cst/Makefile 3 Jan 2002 19:22:21 -0000 1.1 --- sources/asimut/cst/Makefile 7 Jan 2002 21:38:48 -0000 *************** *** 1,5 **** --- 1,6 ---- include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/asimut/cst VERSION = 100 *************** *** 27,37 **** distrib : $(TARGET_LIB)/libCst$(VERSION).a \ $(TARGET_INCLUDE)/cst$(VERSION).h ! .c.o : $(CC) $(LOCAL_CFLAGS) $(LOCAL_CPPFLAGS) $< ! $(TARGET_INCLUDE)/cst$(VERSION).h : cst$(VERSION).h ! $(CP) cst$(VERSION).h $(TARGET_INCLUDE) $(TARGET_LIB)/libCst$(VERSION).a : $(LOCAL_OBJECTS) $(AR) $(ARFLAGS) $(TARGET_LIB)/libCst$(VERSION).a $(LOCAL_OBJECTS) --- 28,38 ---- distrib : $(TARGET_LIB)/libCst$(VERSION).a \ $(TARGET_INCLUDE)/cst$(VERSION).h ! %.o : $(sdir)/%.c $(CC) $(LOCAL_CFLAGS) $(LOCAL_CPPFLAGS) $< ! $(TARGET_INCLUDE)/cst$(VERSION).h : $(sdir)/cst$(VERSION).h ! $(CP) $(sdir)/cst$(VERSION).h $(TARGET_INCLUDE) $(TARGET_LIB)/libCst$(VERSION).a : $(LOCAL_OBJECTS) $(AR) $(ARFLAGS) $(TARGET_LIB)/libCst$(VERSION).a $(LOCAL_OBJECTS) Index: sources/asimut/scheduler/Makefile =================================================================== RCS file: /cvs/alliance/sources/asimut/scheduler/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/asimut/scheduler/Makefile 3 Jan 2002 19:22:23 -0000 1.1 --- sources/asimut/scheduler/Makefile 7 Jan 2002 21:34:34 -0000 *************** *** 1,5 **** --- 1,6 ---- include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/asimut/scheduler LOCAL_CPPFLAGS = $(CPPFLAGS) -c -g -I$(ALLIANCE_INCLUDE) \ -DMUT_H='<$(MUT_H)>' \ *************** *** 13,26 **** sch_GetCTim.o sch_GetCTra.o sch_GetNTim.o \ sch_GoNTim.o sch_SetCTim.o ! .c.o : $(CC) $(LOCAL_CPPFLAGS) $< distrib : $(TARGET_LIB)/libSch110.a \ $(TARGET_INCLUDE)/sch110.h ! $(TARGET_INCLUDE)/sch110.h : sch110.h ! $(CP) sch110.h $(TARGET_INCLUDE) $(TARGET_LIB)/libSch110.a : $(LOCAL_OBJECTS) $(AR) $(ARFLAGS) $(TARGET_LIB)/libSch110.a $(LOCAL_OBJECTS) --- 14,27 ---- sch_GetCTim.o sch_GetCTra.o sch_GetNTim.o \ sch_GoNTim.o sch_SetCTim.o ! %.o : $(sdir)/%.c $(CC) $(LOCAL_CPPFLAGS) $< distrib : $(TARGET_LIB)/libSch110.a \ $(TARGET_INCLUDE)/sch110.h ! $(TARGET_INCLUDE)/sch110.h : $(sdir)/sch110.h ! $(CP) $(sdir)/sch110.h $(TARGET_INCLUDE) $(TARGET_LIB)/libSch110.a : $(LOCAL_OBJECTS) $(AR) $(ARFLAGS) $(TARGET_LIB)/libSch110.a $(LOCAL_OBJECTS) Index: sources/asimut/simulad/Makefile =================================================================== RCS file: /cvs/alliance/sources/asimut/simulad/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/asimut/simulad/Makefile 3 Jan 2002 19:22:31 -0000 1.1 --- sources/asimut/simulad/Makefile 7 Jan 2002 20:50:02 -0000 *************** *** 23,28 **** --- 23,29 ---- include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/asimut/simulad #TARGET_BIN = . *************** *** 70,76 **** vh_lspec.o vh_simulad.o vh_util.o \ vh_xcomm.o vh_xspec.o ! .c.o : $(CC) $(LOCAL_CFLAGS) $(LOCAL_CPPFLAGS) $< distrib : $(TARGET_BIN)/asimut --- 71,77 ---- vh_lspec.o vh_simulad.o vh_util.o \ vh_xcomm.o vh_xspec.o ! %.o : $(sdir)/%.c $(CC) $(LOCAL_CFLAGS) $(LOCAL_CPPFLAGS) $< distrib : $(TARGET_BIN)/asimut *************** *** 78,84 **** $(TARGET_BIN)/asimut : $(LOCAL_OBJECTS) $(CC) $(LOCAL_CFLAGS) -o $(TARGET_BIN)/asimut \ $(LOCAL_OBJECTS) $(LOCAL_LDFLAGS) $(LOCAL_LIBS) ! $(STRIP) $(TARGET_BIN)/asimut clean : $(RM) -f $(LOCAL_OBJECTS) --- 79,85 ---- $(TARGET_BIN)/asimut : $(LOCAL_OBJECTS) $(CC) $(LOCAL_CFLAGS) -o $(TARGET_BIN)/asimut \ $(LOCAL_OBJECTS) $(LOCAL_LDFLAGS) $(LOCAL_LIBS) ! $(STRIP) $@ clean : $(RM) -f $(LOCAL_OBJECTS) Index: sources/asimut/tests/Makefile =================================================================== RCS file: /cvs/alliance/sources/asimut/tests/Makefile,v retrieving revision 1.1 diff -b -i -c -r1.1 Makefile *** sources/asimut/tests/Makefile 3 Jan 2002 19:23:01 -0000 1.1 --- sources/asimut/tests/Makefile 9 Jan 2002 03:46:26 -0000 *************** *** 26,42 **** # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.1 2002/01/03 19:23:01 pinaar Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk ! all : asimut -zd stick_bit stick_bit res_stick_bit asimut -bdd -zd stick_bit stick_bit res_stick_bit clean : $(RM) -f *.bak .*.bak *~ .*~ core res_* --- 26,53 ---- # Date : 1996,97 # Author : Czo <Olivier.Sirol@lip6.fr> # ! # $Id: Makefile,v 1.2 2000/11/07 15:26:43 czo Exp $ # include $(ALLIANCE_TOP)/etc/$(ALLIANCE_OS).mk include $(ALLIANCE_TOP)/etc/libraries.mk + sdir=$(SRCDIR)/asimut/tests + VST=stick_bit.vst + PAT=stick_bit.pat + # Do not run again if it passed + all : nomore ! nomore: ! @if [ ! -L $(VST) ]; then ln -s $(sdir)/$(VST); fi ! @if [ ! -L $(PAT) ]; then ln -s $(sdir)/$(PAT); fi ! touch failed asimut -zd stick_bit stick_bit res_stick_bit asimut -bdd -zd stick_bit stick_bit res_stick_bit + touch passed + if [ -f passed ]; then touch nomore; fi + if [ -f failed ]; then touch nomore; fi clean : $(RM) -f *.bak .*.bak *~ .*~ core res_*