From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thien-Thi Nguyen Newsgroups: gmane.lisp.guile.user Subject: request: libguile to wrap getsid(2) Date: Sat, 26 Dec 2009 19:50:52 +0100 Message-ID: <87ws09y3g3.fsf@ambire.localdomain> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1261853611 3191 80.91.229.12 (26 Dec 2009 18:53:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 26 Dec 2009 18:53:31 +0000 (UTC) To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Sat Dec 26 19:53:24 2009 Return-path: Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NOblT-0005J8-JI for guile-user@m.gmane.org; Sat, 26 Dec 2009 19:53:23 +0100 Original-Received: from localhost ([127.0.0.1]:48010 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NOblT-0005de-NY for guile-user@m.gmane.org; Sat, 26 Dec 2009 13:53:23 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NOblP-0005ca-5K for guile-user@gnu.org; Sat, 26 Dec 2009 13:53:19 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NOblK-0005Wl-FU for guile-user@gnu.org; Sat, 26 Dec 2009 13:53:18 -0500 Original-Received: from [199.232.76.173] (port=40151 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NOblK-0005Wd-A7 for guile-user@gnu.org; Sat, 26 Dec 2009 13:53:14 -0500 Original-Received: from smtp-out112.alice.it ([85.37.17.112]:3172) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NOblH-0007xJ-Rn for guile-user@gnu.org; Sat, 26 Dec 2009 13:53:12 -0500 Original-Received: from FBCMMO02.fbc.local ([192.168.68.196]) by smtp-out112.alice.it with Microsoft SMTPSVC(6.0.3790.3959); Sat, 26 Dec 2009 19:53:08 +0100 Original-Received: from FBCMCL01B03.fbc.local ([192.168.69.84]) by FBCMMO02.fbc.local with Microsoft SMTPSVC(6.0.3790.3959); Sat, 26 Dec 2009 19:53:08 +0100 Original-Received: from ambire.localdomain ([79.21.71.78]) by FBCMCL01B03.fbc.local with Microsoft SMTPSVC(6.0.3790.3959); Sat, 26 Dec 2009 19:53:08 +0100 Original-Received: from ttn by ambire.localdomain with local (Exim 4.63) (envelope-from ) id 1NObj2-0007T7-M0 for guile-user@gnu.org; Sat, 26 Dec 2009 19:50:52 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) X-OriginalArrivalTime: 26 Dec 2009 18:53:08.0624 (UTC) FILETIME=[AA543900:01CA865C] X-detected-operating-system: by monty-python.gnu.org: Windows 2000 SP4, XP SP1+ X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:7563 Archived-At: I've just about finished porting ratpoison (a CVS snapshot prior to its author's abandoning it in favor of stumpwm) to Guile (1.4.x) scheme. This means no more Xlib (et al)! However, the last bit of C glue (outside of ttn-do) it needs is getsid(2). Here is the Guile 1.4.x-flavored wrapping: GH_DEFPROC (rpx_getsid, "getsid", 1, 0, 0, (SCM pid), doc: /*********** Return the session id associated with @var{pid}. */) { return gh_int2scm (getsid (gh_scm2int (pid))); } I'm sure it would be no trouble to adapt this to other Guile versions. This function will go into Guile 1.4.1.119, so i'm hereby requesting that a future Guile 1.9.x include it, as well. This way, i can release rpx (working name of the port -- kind of like "ratpoison exhumed") with only ttn-do as its dependency, and no C bits whatsoever. "But ttn, why do you care about any Guile other than 1.4.x?" Well, why not? thi