Date: Mon, 29 Sep 1997 19:59:51 +0200 From: Edouard Ritz X-Mailer: Mozilla 3.01SGoldC-SGI (X11; I; IRIX 6.3 IP32) MIME-Version: 1.0 To: "Ptolemy users' newsgroup" Subject: Building Pt0.7 under SGI IRIX 6.x: missing file config-irix6.mk Content-Type: multipart/mixed; boundary="------------1CFB3F54FF6" Sender: owner-ptolemy-hackers@EECS.Berkeley.EDU Precedence: bulk This is a multi-part message in MIME format. --------------1CFB3F54FF6 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit I have successfully compiled Ptolemy 0.7 fom scratch under SGI Irix 6.3, after a week of hard work and thanks to the help of Dominique Ragot. The two main problems I have met have been: 1. the compilation of gnu make3.75 2. the master makefile $PTOLEMY/mk/config-irix6.mk missing from the distribution Here is some helpful hints for other users who want to compile Ptolemy 0.7 from scratch under IRIX6.3 (and more generally under IRIX 6.x) without losing their temper To recompile Ptolemy0.7 from scratch under SGi IRIX 6.x you need: 1) to download the tar files: pt0.7.src.tar.gz pt0.7.other.tar.gz pt0.7.gnu.tar.gz only for gnu make3.75 2) to decompress these three files using the commands: gzcat pt0.7.src.tar.gz | tar xf - gzcat pt0.7.other.tar.gz | tar xf - gzcat pt0.7.gnu.tar.gz | tar xf - 3) modify the $PTOLEMY/bin/ptarch file and add those lines at line 87: *:IRIX:6.*:*) echo irix6 exit 0 ;; 4) to add the following lines to your .cshrc file: (case of non ptolemy user installation but in the dirctory $HOME/ptolemy) # Home directory of the Ptolemy installation setenv PTOLEMY $HOME/ptolemy setenv PT_DEBUG ptgdb setenv TYCHO $PTOLEMY/tycho # The arch script figures out what type of machine we are on. setenv PTARCH ` $PTOLEMY/bin/ptarch` modify your PATH so that it begins by $PTOLEMY/bin then $PTOLEMY/bin.$PTARCH and then $PTOLEMY/vendors/bin. THIS ORDER IS VERY IMPORTANT. to do that type in your .cshrc file: setenv PATH $PTOLEMY/bin setenv PATH $PATH":"$PTOLEMY/bin"."$PTARCH setenv PATH $PATH":"$PTOLEMY/vendors/bin and then your own path to the other bin directory. for example: setenv PATH $PATH":"/usr/sbin setenv PATH $PATH":"$HOME/bin:/usr/local/bin:/usr/X11/bin:/usr/openwin/bin setenv PATH $PATH":"/usr/bin:/bin:/usr/ucb:/usr/bsd setenv PATH $PATH":"/usr/bin/X11:/usr/ccs/bin:/usr/freeware/bin Once your path is well defined, add those lines in the .cshrc file: # If your $PTOLEMY does not equal /users/ptdesign and you # are running from prebuilt binaries, then you will need to set an # environment variable so that the runtime linker can find the libraries if ($PTOLEMY != /users/ptolemy) then setenv LD_LIBRARY_PATH $PTOLEMY/lib.${PTARCH}:$PTOLEMY/octtools/lib.${PTARCH}:$PTOLEMY/gnu/$PTARCH/lib endif save your .cshrc. NB: dont forget to do source .cshrc after this or to leave the current winterm window and open a new one check your path is OK by typing the command: echo $PATH: you should obtain something like this $HOME/ptolemy/bin:$HOME/ptolemy/bin.irix6:$HOME/ptolemy/vendors/bin:/usr/sbin:$HOME/bin:/usr/local/bin:/usr/X11/bin:/usr/openwin/bin:/usr/bin:/bin:/usr/ucb:/usr/bsd:/usr/bin/X11:/usr/ccs/bin:/usr/freeware/bin 5) add the file config-irix6.mk in $PTOLEMY/mk/ (this file is missing from the original distribution, which is stupid because without it, you haven't got the slightest chance to succeed in building Pt0.7. Anyway, you will find this file as an attachment file of this mail) 6) Build Gnu make3.75: This task may be very difficult if you don't proceed as follows: in your current winterm window type cd $PTOLEMY/src/gnu/src/make3.75 setenv CC "cc -32" ./configure /bin/make (to force the use of IRIX make and not GNU make) mkdir $PTOLEMY/bin.irix6 cp ./make $PTOLEMY/bin.irix6 rehash 7) at that stage you should have only "make" in the directory $PTOLEMY/bin.irix6 directory. We have bypassed the worthless gnu tools installation (only GNU make is used to compile Ptolemy) 8) Ptolemy installation: very easy if you have done the previous steps successfully. cd $PTOLEMY make everything >& filename where filename is a logfile receiving all the installation information. The installation might take a while (over 3 hours for an O2 with 64 Mb of RAM). finally check the installation happened correctly by editing the logfile "filename" and looking at the end of the file. If everything is OK, type pigi and the miracle should occur on your screen. Hope this will avoid a lot of work for the others. Edouard RITZ, Institut National de l'Audiovisuel 28 av. des Freres Lumiere, 94366 Bry sur Marne Cedex, France Tel 33 (0)1 4983 2093, Fax 33 (0)1 4983 2929, Email ritz@ina.fr --------------1CFB3F54FF6 Content-Type: text/plain; charset=us-ascii; name="config-irix6.mk" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="config-irix6.mk" # Configuration makefile to make on an SGI machine with CC -64 or CC # using SGI CC (note that the term 'cfront' is historical, the SGI CC # probably is not cfront based) # # @(#)config-irix6.cfront.mk 1.6 04/07/97 # Copyright (c) 1996-1997 The Regents of the University of California. # All rights reserved. # # Permission is hereby granted, without written agreement and without # license or royalty fees, to use, copy, modify, and distribute this # software and its documentation for any purpose, provided that the # above copyright notice and the following two paragraphs appear in all # copies of this software. # # IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY # FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES # ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF # THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, # INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE # PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE UNIVERSITY OF # CALIFORNIA HAS NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, # ENHANCEMENTS, OR MODIFICATIONS. # # PT_COPYRIGHT_VERSION_2 # COPYRIGHTENDKEY # # Programmer: Dominique Ragot # -------------------------------------------------------------------- # | Please see the file ´´config-default.mk'' in this directory! | # -------------------------------------------------------------------- include $(ROOT)/mk/config-default.mk # common.mk looks at this variable to decide how to build shared libraries USE_SHARED_LIBS = yes # #ifeq ($(USE_SHARED_LIBS),yes) # Use Position Independent Code to build shared libraries C_SHAREDFLAGS = CC_SHAREDFLAGS = # mk/userstars.mk uses these vars USER_C_SHAREDFLAGS = $(C_SHAREDFLAGS) USER_CC_SHAREDFLAGS = $(CC_SHAREDFLAGS) LIBSUFFIX = so # Location of SGI C++ shared libraries SHARED_COMPILERDIR = SHARED_COMPILERDIR_FLAG = #SHARED_COMPILERDIR_FLAG = -L$(SHARED_COMPILERDIR) # Command to build C++ shared libraries SHARED_LIBRARY_COMMAND = CC -32 -shared -set_version 'vanillaUCB\#sgi7.0' $(SHARED_COMPILERDIR_FLAG) -o # Command to build C shared libraries CSHARED_LIBRARY_COMMAND = cc -32 -shared -set_version 'vanillaUCB\#sgi7.0' $(SHARED_COMPILERDIR_FLAG) -o # List of libraries to search, obviating the need to set LD_LIBRARY_PATH # See the ld man page for more information. These path names must # be absolute pathnames, not relative pathnames. SHARED_LIBRARY_PATH = $(PTOLEMY)/lib.$(PTARCH):$(PTOLEMY)/octtools/lib.$(PTARCH):$(X11_LIBDIR):$(SHARED_COMPILERDIR):$(PTOLEMY)/tcltk/itcl.$(PTARCH)/lib/itcl SHARED_LIBRARY_R_LIST = -Wl,-R,$(SHARED_LIBRARY_PATH) #endif # # Programs to use # # Define the C++ compiler - always have compat/cfront includes as 1st choice CPLUSPLUS = CC -32 -I$(ROOT)/src/compat/cfront # IRIX6.x does not have a ranlib RANLIB = true CC = cc -32 # OCT_CC is used in src/octtools/vem-{lib,bin}.mk OCT_CC = cc -32 # In config-$PTARCH.mk, we set the following variables. We need to # use only the following variables so that we can use them elsewhere, say # for non-optimized compiles. # OPTIMIZER - The setting for the optimizer, usually -O2. # MEMLOG - Formerly used to log memory allocation and deallocation. # WARNINGS - Flags that print warnings. # ARCHFLAGS - Architecture dependent flags, useful for determining which # OS we are on. Often of the form -DPTSOL2_4. # LOCALCCFLAGS - Other architecture dependent flags that apply to all releases # of the OS for this architecture for c++ # LOCALCFLAGS - Other architecture dependent flags that apply to all releases # of the OS for this architecture for c++ # USERFLAGS - Ptolemy makefiles should never set this, but the user can set it. OPTIMIZER = -g # -Wsynth is new in g++-2.6.x # Under gxx-2.7.0 -Wcast-qual will drown you with warnings from libg++ includes #WARNINGS = -Wall -Wsynth #-Wcast-qual WARNINGS = ARCHFLAGS = -DIRIX5 -DIRIX6 # Use -D_BSD_SIGNALS for src/kernel/SimControl.cc # see /usr/include/sys/signals.h for more info. # Use -D_BSD_TIME for src/kernel/Clock.cc, see /usr/include/sys/time.h # dpwe: -G 0 is to disable accessing data off 'the global pointer' # (according to man CC); this is known to result in global space # overflow in large programs; (man CC also suggests that # unless -nonshared is also specified, it is ignored anyway.) ## -xgot is the SGI hack to avoid overflows in the GOT by allowing # 32 bit offsets, or something. GOTFLAG = -G 0 -xgot LOCALCCFLAGS = $(GOTFLAG) -D_BSD_SIGNALS -D_BSD_TIME GPPFLAGS = $(OPTIMIZER) $(MEMLOG) $(WARNINGS) \ $(ARCHFLAGS) $(LOCALCCFLAGS) $(USERFLAGS) LOCALCFLAGS = $(GOTFLAG) #-cckr CFLAGS = $(OPTIMIZER) $(MEMLOG) $(WARNINGS) \ $(ARCHFLAGS) $(LOCALCFLAGS) $(USERFLAGS) # command to generate dependencies (cfront users can try CC -M) ##DEPEND=g++ -MM DEPEND=CC -32 -M # # Variables for the linker # # linker to use for pigi and interpreter. LINKER = CC -32 -quickstart_info # C linker CLINKER = cc -32 # system libraries for linking .o files from C files only CSYSLIBS = -lm -lmld # system libraries (libraries from the environment) for c++ files SYSLIBS = $(CSYSLIBS) # -Xlinker -s strips out debugging information, otherwise we get a 30Mb # pigiRpc. -s seems to cause core dumps inside collect, so we leave it out # -x is also useful, it removed local symbols, see the ld man page LINKFLAGS = -L$(LIBDIR) $(GOTFLAG) # -Xlinker -s LINKFLAGS_D = -L$(LIBDIR) $(GOTFLAG) # # Directories to use # X11_INCSPEC = -I/usr/X11/include X11_LIBSPEC = -L/usr/X11/lib -lX11 # # Variables for miscellaneous programs # # Used by xv #XV_RAND= RAND="-DNO_RANDOM -Drandom=rand" XV_INSTALL = /usr/bin/X11/bsdinst XV_CC = $(CC) -cckr -DSVR4 -DXLIB_ILLEGAL_ACCESS # Used by tcltk to build the X pixmap extension XPM_DEFINES = -DZPIPE # Matlab architecture MATARCH = sgi --------------1CFB3F54FF6-- ---------------------------------------------------------------------------- Posted to the ptolemy-hackers mailing list. Please send administrative mail for this list to: ptolemy-hackers-request@ptolemy.eecs.berkeley.edu