Path: news.cs.au.dk!news.net.uni-c.dk!uninett.no!newsfeed.nacamar.de!newsfeed.nacamar.de!news.fh-hannover.de!news-han1.dfn.de!news-koe1.dfn.de!Uni-Dortmund.DE!news From: Arne =?iso-8859-1?Q?H=FCggenberg?= Newsgroups: comp.lang.beta Subject: problems with processes Date: Sat, 27 Feb 1999 20:16:53 +0100 Organization: University of Dortmund, Germany Lines: 138 Message-ID: <36D844A5.CFAAFEF4@nef.wh.uni-dortmund.de> NNTP-Posting-Host: emil.nef.wh.uni-dortmund.de Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Mailer: Mozilla 4.5 [en] (X11; I; Linux 2.2.1 i586) X-Accept-Language: en Cache-Post-Path: emil.nef.wh.uni-dortmund.de!arne@darkwing.nef.wh.uni-dortmund.de X-Cache: nntpcache 2.3.2.1 (see http://www.nntpcache.org/) Xref: news.cs.au.dk comp.lang.beta:11842 Hello everyone, i have a problem im hoping someone here can me help with Using the PE for Linux im trying to do something like this: lprtest.bet: ORIGIN '~beta/basiclib/current/systemenv'; INCLUDE 'lpr'; -- program:descriptor -- systemenv (# TextToPrint: ^TEXT; do &text[]->TextToPrint[]; 'this is a test'->TextToPrint.putline; 'wonder if this works'->TextToPrint.putline; TextToPrint[]->&lpr_process; #) with lpr.bet being: ORIGIN '~beta/basiclib/current/systemenv'; INCLUDE '~beta/process/current/processmanager'; -- Systemlib: Attributes -- lpr_process: Systemenv (# PrintMe: ^TEXT; exec: (# name: ^text; child: @process; = enter name[] = do name[]->child.init; printme[]->child.RedirectFromChannel; child.start; child.awaitStopped; #); = enter PrintMe[] do 'starting lpr_process'->putline; ('/usr/bin/lpr')->exec; = #); now what happens is that an execution of lprtest.bet results in: arne@darkwing:~/code > ./lprtest ******************************************************************* * Note: This program was compiled using a Personal Edition of the * * Mjolner BETA System and may not be used for commercial purposes * ******************************************************************* FORK FAILURE: Only newly created systems may be forked. # Beta execution aborted: Stop is called. # Look at 'lprtest.dump' with the dump file being = arne@darkwing:~/code > cat lprtest.dump Beta execution aborted: Stop is called. Call chain: (linux) item in ~beta/basiclib/v1.6/private/betaenvbody -- stop# in ~beta/basiclib/v1.6/betaenv item in ~beta/basiclib/v1.6/betaenv -- BETAENV-~ in ~beta/basiclib/v1.6/betaenv item in ~beta/basiclib/v1.6/private/basicsystemenvbody -- fork# in ~beta/basiclib/v1.6/basicsystemenv item in ~beta/basiclib/v1.6/basicsystemenv -- lpr_process#SystemEnv#SysHead# in /home/arne/code/lpr item in ~beta/basiclib/v1.6/private/basicsystemenvbody -- BASICSYSTEMENVPRIVATE-~ in ~beta/basiclib/v1.6/private/basicsystemenvbody item in ~beta/basiclib/v1.6/private/basicsystemenvbody -- lpr_process#SystemEnv#SysHead# in /home/arne/code/lpr item lpr_process#SysHead# in ~beta/basiclib/v1.6/basicsystemenv -- BETAENV-~ in ~beta/basiclib/v1.6/betaenv comp SystemEnv#SysHead# in /home/arne/code/lprtest -- BETAENV-~ in ~beta/basiclib/v1.6/betaenv item realValue# in ~beta/basiclib/v1.6/private/basicsystemenvbody -- BASICSYSTEMENVPRIVATE-~ in ~beta/basiclib/v1.6/private/basicsystemenvbody item <*>cycle# in ~beta/basiclib/v1.6/private/systemenv_unixbody -- BASICSCHEDULER-~ in ~beta/basiclib/v1.6/private/systemenv_unixbody comp in ~beta/basiclib/v1.6/private/systemenv_unixbody -- PROGRAM-~SystemEnv#SysHead# in /home/arne/code/lprtest basic component in ~beta/basiclib/v1.6/betaenv and im dont quite understand why this doesent work as i expect. Also, when putting it all in one file it seems to work fine, except for the fact that = PrintMe[]->RedirectFromChannel; = results in : # Beta execution aborted: Qualification error in reference assignment. # Look at 'lpr.dump' trying to be clever i then did PrintMe[]->qua(# as::< stream #)->RedirectFromChannel; but to no avail, still dumps with the same qualification error in reference assignment anyone know what im doing wrong? any help would be appreciated :-) Arne H=FCggenberg