Xref: utzoo comp.unix.questions:31307 comp.lang.perl:5294 comp.unix.programmer:1821 Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!lll-winken!sun-barr!newstop!central!convex!mic!ernest!shibaya!afc From: afc@shibaya.lonestar.org (Augustine Cano) Newsgroups: comp.unix.questions,comp.lang.perl,comp.unix.programmer Subject: HELP!!! Metaconfig expert needed! Message-ID: <1991May13.182956.23088@shibaya.lonestar.org> Date: 13 May 91 18:29:56 GMT Organization: Multidisciplinary Designs Unlimited Lines: 140 I'm trying to write a package to be configured with metaconfig. I did fix metaconfig 2 to work with perl 3 (044) (I no longer get syntax errors, but I might not have fixed everything that needed fixing.) I created a test "package" consisting of just one *.U unit and one *.SH file (included below). Metaconfig runs to completion but then I'm left with empty Configure and config.h.SH files. This is the output of metaconfig: $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle $! nulled, predecessor circle This is mytest.U: ?RCS:$Header: mytest.c.U,v 1.1 91/02/14 00:00:00 afc Exp $ ?X: ?X: Test unit. ?X: ?RCS: $Log: mytest.c.U,v $ ?RCS: ?RCS: Revision 1.1 91/05/04 00:00:00 afc ?RCS: Baseline. ?RCS: ?MAKE:mytest.c var1 var2 var3 c1 c2 : test cat echo n c Myread mansrc Mcc Guess Oldconfig Loc ?MAKE: -pick add $@ %* ?S:var1: ?S: Test variable # 1. ?S:. ?S:var2: ?S: Test variable # 2. ?S:. ?S:var3: ?S: Test variable # 3. ?S:. ?S:c1: ?S: Test variable # 4. ?S:. ?S:c2: ?S: Test variable # 5. ?S:. : q_no1="Input a number " q_no2="Input yes/no " q_no3="Enter a string " q_no4="Enter another string " q_no5="Enter another string " $echo $n "$q_no1$c" . myread var1 if test $var1 -gt 1; then var2=false dflt=n $echo $n "$q_no2 [$dflt] $c" . myread case "$ans" in y*) var2=true;; esac fi $echo $n "$q_no3$c" . myread var3 $echo $n "$q_no4$c" . myread c1 $echo $n "$q_no5$c" . myread c2 And this is mytest.c.SH: case $CONFIG in '') if test ! -f config.sh; then ln ../config.sh . || \ ln ../../config.sh . || \ ln ../../../config.sh . || \ (echo "Can't find config.sh."; exit 1) fi . config.sh ;; esac : This forces SH files to create target in same directory as SH file. : This is so that make depend always knows where to find SH derivatives. case "$0" in */*) cd `expr X$0 : 'X\(.*\)/'` ;; esac echo "Extracting fdmtron.c (with variable substitutions)" : This section of the file will have variable substitutions done on it. : Move anything that needs config subs from !NO!SUBS! section to !GROK!THIS!. : Protect any dollar signs and backticks that you do not want interpreted : by putting a backslash in front. You may delete these comments. $spitshell >mytest.c <>mytest.c <>mytest.c <>mytest.c <>mytest.c <<'!NO!SUBS!' !NO!SUBS! chmod 755 mytest.c $eunicefix mytest.c Any solution, hint or even documentation for dist 3 would be most welcome. What am I doing wrong? This is driving me nuts! Thanks in advance. I'll post a summary of e-mail responses if there's interest. -- Augustine Cano INTERNET: afc@shibaya.lonestar.org UUCP: ...!{ernest,egsner}!shibaya!afc