#494 Missing :linux feature on Linux

closed-invalid
clisp (525)
5
2014-08-22
2008-07-29
No

On Linux clisp's *features* do not include :LINUX (as most/all? other CLs do). Using #+ linux to mark Linux-specific code thus does not work for clisp.

My Clisp is built from Gentoo portage.

% uname -a
Linux tabernacle 2.6.25.4 #15 SMP PREEMPT Thu Jul 3 22:11:18 CEST 2008 i686 Intel(R) Core(TM) Duo CPU L2400 @ 1.66GHz GenuineIntel GNU/Linux

% clisp --version
GNU CLISP 2.46 (2008-07-02) (built 3424546950) (memory 3424547349)
Software: GNU-C 4.1.2 (Gentoo 4.1.2 p1.1)
gcc -O2 -march=pentium-m -pipe -W -Wswitch -Wcomment -Wpointer-arith -Wimplicit -Wreturn-type -Wmissing-declarations -Wno-sign-compare -O2 -fexpensive-optimizations -falign-functions=4 -DUNICODE -DDYNAMIC_FFI -DDYNAMIC_MODULES -I. -x none /usr/lib/libreadline.so -lncurses -ldl /usr/lib/libavcall.a /usr/lib/libcallback.a -L/usr/lib -lsigsegv -L/usr/lib -lc
SAFETY=0 HEAPCODES LINUX_NOEXEC_HEAPCODES GENERATIONAL_GC SPVW_BLOCKS SPVW_MIXED TRIVIALMAP_MEMORY
libsigsegv 2.4
libreadline 5.2
Features:
(READLINE REGEXP SYSCALLS I18N LOOP COMPILER CLOS MOP CLISP ANSI-CL COMMON-LISP LISP=CL INTERPRETER SOCKETS GENERIC-STREAMS LOGICAL-PATHNAMES
SCREEN FFI GETTEXT UNICODE BASE-CHAR=CHARACTER PC386 UNIX)
C Modules: (clisp i18n syscalls regexp readline)
Installation directory: /usr/lib/clisp-2.46/
User language: ENGLISH
Machine: I686 (I686) localhost [127.0.0.1]

Discussion

  • Sam Steingold

    Sam Steingold - 2008-07-30
    • assigned_to: haible --> sds
    • status: open --> pending-invalid
     
  • Sam Steingold

    Sam Steingold - 2008-07-30

    Logged In: YES
    user_id=5735
    Originator: NO

    This bug report is now marked as "pending"/"invalid".
    This means that we think that the problem you report
    is not a problem with CLISP.
    Unless you - the reporter - act within 2 weeks,
    the bug will be permanently closed.
    Sorry about the inconvenience -
    we hope your silence means that
    you agree that this is not a bug in CLISP.

     
  • Julian Stecklina

    • status: pending-invalid --> open-invalid
     
  • Julian Stecklina

    Logged In: YES
    user_id=448338
    Originator: YES

    Linux-specific code would be code that wants to use sysfs or execute some Linux specific command. stumpwm has code that does:

    #+ linux (read-value-via-sysfs)
    #+ freebsd (read-value-via-sysctl)

    This code runs fine on any CL, I can find right now: ECL, SBCL, CMUCL. Our current workaround is to generate platform features for clisp manually which is quite ugly.

     
  • Sam Steingold

    Sam Steingold - 2008-07-30

    Logged In: YES
    user_id=5735
    Originator: NO

    *features* are intended for implementations to advertise their capabilities.
    clisp capabilities on linux and freebsd are identical,
    so clisp does not have :linux or :freebsd in *features*.

    E.g., I imagine that the /proc FS in linux 2.4 and linux 2.6 are sufficiently different so that you will have to write separate functions to process them. Would you also want me to ass :linux-2.4 or :linux-2.6 to *features* as well?

    what you want to do is
    (fcase equalp (uname-sysname (uname))
    ("linux" (read-value-via-sysfs))
    ("freebsd" (read-value-via-sysctl))
    (....))
    again, it is WRONG to massage :linux into *features*.
    it is not a good idea to rely on this abuse of *features*,
    even if some implementations do that.

     
  • Sam Steingold

    Sam Steingold - 2008-07-30
    • status: open-invalid --> pending-invalid
     
  • SourceForge Robot

    Logged In: YES
    user_id=1312539
    Originator: NO

    This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     
  • SourceForge Robot

    • status: pending-invalid --> closed-invalid
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks