Tom Carley writes:

> I have been having trouble installing ptolemy version 1.0.1 on
> Unix. My system is an Ultra10 running Solaris2.6 with java 1.3. I have
> attached a log of my attempted install.
> 
> 
> Thank you,
>     Tom Carley
> 
> ....
> 
> 
> adding: ptolemy/domains/sdf/lib/vq/VQDecode.class(in = 5384) (out=
> 2952)(deflated 45%)
> adding: ptolemy/domains/sdf/lib/vq/sdfvqentities.xml(in = 1019) (out=
> 343)(deflated 66%)
> mv ptjar_tmpdir/tmp.jar domains.jar
> rm -rf ptjar_tmpdir
> # Building Auxiliary jar file
> rm -rf ptjar_tmpdir experimentalDomains.jar
> mkdir ptjar_tmpdir
> # Copy any class files from this directory
> mkdir -p ptjar_tmpdir/ptolemy/domains
> cp *.class  ptjar_tmpdir/ptolemy/domains
> cp: cannot access *.class
> *** Error code 2 (ignored)
> for jar in ; do \
>         echo "Unjarring $jar"; \
>         (cd ptjar_tmpdir; jar -xf ../$jar); \
> done
> sh: syntax error at line 1: `;' unexpected
> *** Error code 2
> make: Fatal error: Command failed for target `experimentalDomains.jar'
> Current working directory
> /export/software/serts6/ptII1.0.1/ptolemy/domains
> *** Error code 1
> make: Fatal error: Command failed for target `subinstall'
> Current working directory /export/software/serts6/ptII1.0.1/ptolemy
> *** Error code 1
> make: Fatal error: Command failed for target `subinstall'
> serts6:/software/serts6/ptII1.0.1: exit


Sorry for the delay in getting back to you, I was out of the office,
and I needed access to a Solaris box to track this down.

It looks like $PTII/mk/ptcommon.mk is not portable.

It works fine under GNU make, but fails under Solaris /usr/ccs/bin/make.
>From your output, it looks like you are running /usr/ccs/bin/make.

The problem is that the $^ operator is not present in Solaris
/usr/ccs/bin/make.

Below is a test case, where I have two empty files and a makefile:
      cxh@maury 4% ls -l
      total 1
      -rw-r--r--   1 cxh             0 Jul 26 12:56 a
      -rw-r--r--   1 cxh             0 Jul 26 12:56 b
      -rw-r--r--   1 cxh            39 Jul 26 13:09 makefile
      cxh@maury 5% cat makefile
      all: a b
        echo "The variable is: '$^'"

GNU make echoes $^
      cxh@maury 6% /usr/sww/bin/gmake
      echo "The variable is: 'a b'"
      The variable is: 'a b'

Solaris make does not:
      cxh@maury 7% /usr/ccs/bin/make
      echo "The variable is: ''"
      The variable is: ''
      cxh@maury 8% 

The fix is to either use GNU make or do the following patch
to $PTII/mk/ptcommon.mk:

cxh@maury 107% diff -c mk/ptcommon.mk.orig mk/ptcommon.mk
*** mk/ptcommon.mk.orig Thu Jul 26 12:49:33 2001
--- mk/ptcommon.mk      Thu Jul 26 13:02:07 2001
***************
*** 394,400 ****
        # Copy any class files from this directory
        mkdir -p $(PTJAR_TMPDIR)/$(ME)
        -cp *.class $(OTHER_FILES_TO_BE_JARED) $(PTJAR_TMPDIR)/$(ME)
!       for jar in $^; do \
                echo "Unjarring $$jar"; \
                (cd $(PTJAR_TMPDIR); jar -xf ../$$jar); \
        done
--- 394,400 ----
        # Copy any class files from this directory
        mkdir -p $(PTJAR_TMPDIR)/$(ME)
        -cp *.class $(OTHER_FILES_TO_BE_JARED) $(PTJAR_TMPDIR)/$(ME)
!       for jar in $(PTAUXALLJARS) $(JCLASS) $(OTHER_FILES_TO_BE_JARED); do \
                echo "Unjarring $$jar"; \
                (cd $(PTJAR_TMPDIR); jar -xf ../$$jar); \
        done
cxh@maury 108% 

Thanks for reporting this!

-Christopher

----------------------------------------------------------------------------
Posted to the ptolemy-hackers mailing list.  Please send administrative
mail for this list to: [EMAIL PROTECTED]

Reply via email to