From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Colin S. Miller" Newsgroups: gmane.emacs.help Subject: Re: Waiting for Asynchronous Process Date: Wed, 27 Aug 2008 19:39:55 +0100 Organization: SunSITE.dk - Supporting Open source Message-ID: <48b59f7b$0$90271$14726298@news.sunsite.dk> References: <089da2d2-c201-48ea-b49e-21966e4637f8@i76g2000hsf.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1219862525 22397 80.91.229.12 (27 Aug 2008 18:42:05 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 27 Aug 2008 18:42:05 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Aug 27 20:42:58 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KYPyq-0005Y0-7D for geh-help-gnu-emacs@m.gmane.org; Wed, 27 Aug 2008 20:42:56 +0200 Original-Received: from localhost ([127.0.0.1]:60867 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KYPxr-0006ay-GO for geh-help-gnu-emacs@m.gmane.org; Wed, 27 Aug 2008 14:41:55 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!newshub.sdsu.edu!feeder.erje.net!goblin2!goblin.stu.neva.ru!news.net.uni-c.dk!dotsrc.org!filter.dotsrc.org!news.dotsrc.org!not-for-mail User-Agent: Icedove 1.5.0.14eol (X11/20080724) Original-Newsgroups: gnu.emacs.help In-Reply-To: <089da2d2-c201-48ea-b49e-21966e4637f8@i76g2000hsf.googlegroups.com> Original-Lines: 24 Original-NNTP-Posting-Host: 62.56.70.22 Original-X-Trace: news.sunsite.dk DXC=S^CZaFade9lj?5fOS\LBAnYSB=nbEKnkkebg1>^?UCAjG1[Bg<0aH5`\VT\m5_SIbfU_42Df:PaKhTcL2h5ahoTokF_>m>CYcVo6FGchXCha7gF@=6c]Zb]Xi Original-X-Complaints-To: staff@sunsite.dk Original-Xref: news.stanford.edu gnu.emacs.help:161694 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:57034 Archived-At: Eric wrote: > Suppose I'm writing a function that will compile 4 files (A, B, C, and > D). The first three can compile in any order, but D must come last. > I want the user to have a responsive Emacs while the compilations are > going on. > > I could do (call-process "theCompiler" .... "A") > (call-process "theCompiler" .... "B") ... > but then Emacs is "frozen" until all files are compiled. > > I could do (start-process ...), but then I can't seem to wait for the > processes to all exit without causing Emacs to hang. > > I know that ELisp doesn't do multithreading. Is it possible to do what > I want without creating a separate script outside of Emacs? BTW, "make -j" from M-x compile will do this, if you are using a Unix-based system. HTH, Colin S. Miller -- Replace the obvious in my email address with the first three letters of the hostname to reply.