Professional Web Applications Themes

How to determine available system calls on a Unix/Linux system - Linux / Unix Administration

Hi, There are more than 1000 defined system calls in the Unix standard specification, however, a majority of them are optional and the availability of system calls are dependent on the OS implementation itself. The question I have is: How do you determine which system calls are available on any Unix/Linux machine? The same question goes for determening available C library functions on any Unix/Linux machine? Best regards...

  1. #1

    Default How to determine available system calls on a Unix/Linux system

    Hi,

    There are more than 1000 defined system calls in the Unix standard
    specification, however, a majority of them are optional and the
    availability of system calls are dependent on the OS implementation
    itself.

    The question I have is: How do you determine which system calls are
    available on any Unix/Linux machine?

    The same question goes for determening available C library functions
    on any Unix/Linux machine?

    Best regards
    markus Guest

  2. #2

    Default Re: How to determine available system calls on a Unix/Linux system

    com (markus) wrote:
     

    If the computer has a conforming C implementation, _all_ C library
    functions must be available; otherwise it simply isn't a C
    implementation.
    As for determining what is present, that's OS-specific, hence off-topic
    on comp.lang.c.

    Richard
    Richard Guest

  3. #3

    Default Re: How to determine available system calls on a Unix/Linux system

    Richard Bos <nl> wrote: [/ref]

    You don't. It's none of your business. It's the C library's business to
    interface between you and the system calls.

    But if you wanted to, you would read the kernel's syscall
    implementation list in the source code.
     [/ref]
     

    Well, whther the functions work or not also enters into it. However ...
     

    In the last 20 years, I have never seen anything that is on topic on
    comp.lang.c, which is why I have avoided going there like the plague
    during the last 20 years. If you want language lawyery, it's an
    excellent place to hang out and pick nits.

    It's sort of like Wittgenstein. Anything you asked him he told you was
    some other disciplines kind of problem, not philosophy.

    Peter
    P.T. Guest

  4. #4

    Default Re: How to determine available system calls on a Unix/Linux system

    markus wrote: 

    ALL the functions specified in the ISO C standard should be
    available on any hosted machine. Anything else is system
    dependant and off-topic on c.l.c.

    Thus code that uses such non-standard calls should be in an
    isolated system dependant module, and discussed only on system
    specific newsgroups. Above all they should not be cross-posted to
    groups where they are OT.

    --
    Chuck F (com) (att.net)
    Available for consulting/temporary embedded and systems.
    <http://cbfalconer.home.att.net> USE worldnet address!


    CBFalconer Guest

  5. #5

    Default Re: How to determine available system calls on a Unix/Linux system

    com (markus) writes:
     

    That is what the "configure" script in most UNIX source code packages
    does. If you tell us what you are trying to do, you might get a more
    useful answer.
    Dan Guest

  6. #6

    Default Re: How to determine available system calls on a Unix/Linux system

    com (markus) writes:
     

    First, all linux implement the same subset of posix (for a given
    version), and all MacOSX implement their own same subset. So when you
    write a program for a given target (system class), you can count on
    the features present.

    Otherwise, if you have the API in the /usr/include header, there's a
    high probability that they're actually present in the system.

    Finally, this is usually done at compilation time with utilities such
    as autoconf/automake and the generated configure script.

    It's rarely done at run-time. You could scan /usr/include, /usr/lib,
    and play with dlopen (if it's available :-).
     

    --
    __Pascal Bourguignon__ http://www.informatimago.com/

    Our enemies are innovative and resourceful, and so are we. They never
    stop thinking about new ways to harm our country and our people, and
    neither do we.
    Pascal Guest

  7. #7

    Default Re: How to determine available system calls on a Unix/Linux system

    com (markus) wrote:
    # Hi,
    #
    # There are more than 1000 defined system calls in the Unix standard
    # specification, however, a majority of them are optional and the
    # availability of system calls are dependent on the OS implementation
    # itself.
    #
    # The question I have is: How do you determine which system calls are
    # available on any Unix/Linux machine?

    Trial and error, unfortunately, is too often the case. On a proper system you should be
    able to look at /usr/share/man/man2 and man3 or the section 2 and 3 portion of xman to
    get a rough idea. However many systems anywhere are inadequately doented. You can also
    try nm /usr/lib/libc.so or similar files.

    --
    SM Ryan http://www.rawbw.com/~wyrmwif/
    Mention something out of a Charleton Heston movie, and suddenly
    everybody's a theology scholar.
    SM Guest

  8. #8

    Default Re: How to determine available system calls on a Unix/Linux system

    com (markus) wrote in message news:<google.com>... 

    you can try
    apropos '(3)' for library functions
    apropos '(2)' for system calls

    This should give you a list, at least for those functions that have a
    man page in the system I suppose...
    Zian Guest

  9. #9

    Default Re: How to determine available system calls on a Unix/Linux system

    P.T. Breuer wrote:
     


    Pure lies. We handle many questions and problems each day, as long as
    they fit the topicality of the newsgroup.



    Brian Rodenborn
    Default Guest

  10. #10

    Default Re: How to determine available system calls on a Unix/Linux system

    Default User <com.invalid> wrote: [/ref]
     

    There you are!

    Peter
    P.T. Guest

  11. #11

    Default Re: How to determine available system calls on a Unix/Linux system

    P.T. Breuer wrote:
     [/ref]

    >
    > There you are![/ref]

    Quite a non-sequitur. Do you deny that we (comp.lang.c) handle many
    questions and problems each day? Do I need to post examples and make
    you look foolish?




    Brian Rodenborn
    Default Guest

  12. #12

    Default Re: How to determine available system calls on a Unix/Linux system

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1
    NotDashEscaped: You need GnuPG to verify this message

    In comp.os.linux.misc Default User <com.invalid> suggested: 
     
    >> 
    >>
    >> There you are![/ref][/ref]
     

    Mh, looks like both have made their points and seem to have a
    quite different opinion about clc. Nothing unusual, or anything
    that would make it reasonable to begin insulting each other,
    while wasting bandwidth. Probably the only thing a large thread
    would change are this weeks stats of colm/cua and clc (if there
    is such a thing).;)

    Thx for reading

    --
    Michael Heiming (GPG-Key ID: 0xEDD27B94)
    mail: echo qr | perl -pe 'y/a-z/n-za-m/'
    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.2.4 (GNU/Linux)

    iD8DBQFBTzB+AkPEju3Se5QRAnp4AKCMpv33rr3JD6yK0l2jGD s0FHV1qACgsxTE
    8P+pDbYLOjC+WlXKNZELMU0=
    =QbXo
    -----END PGP SIGNATURE-----
    Michael Guest

  13. #13

    Default Re: How to determine available system calls on a Unix/Linux system

    Default User <com.invalid> wrote: 
     
    > > 
    > >
    > > There you are![/ref][/ref]
     

    :-) !!!!

    Yay! They haven't changed!

    It's like stepping into a time warp, except I daresay a whole new load
    of lusers questons about library functions are nowadays consigned to the
    bin of null. Threading anyone? Reentrancy?

    Yo ho ho.

    Peter
    P.T. Guest

  14. #14

    Default Re: How to determine available system calls on a Unix/Linux system

    ["Followup-To:" header set to comp.unix.admin.]
    On Mon, 20 Sep 2004 11:53:52 GMT, P.T. Breuer
    <it.uc3m.es> wrote: 
    If you avoid going to comp.lang.c, you probably only see articles which
    are crossposted to that group, and anything crossposted is almost
    certain to be considered off-topic.

    --
    System Events
    =-=-=-=-=-=-=
    Sep 16 03:31:11 don kernel: lp0 on fire

    Bill Guest

  15. #15

    Default Re: How to determine available system calls on a Unix/Linux system

    P.T. Breuer wrote:

     


    You continue to dodge the question. Obviously, you've realized that
    your lies are exposed.




    Brian Rodenborn
    Default Guest

  16. #16

    Default Re: How to determine available system calls on a Unix/Linux system

    Default User <com.invalid> wrote: 
     [/ref]
     

    Ooooh, yes! It's just as I recalled!

    May I go back to arguing on the kernel list now? I really would like to
    tell you all about my problems parsing gnu C extensions, but I have an
    urgent appointment with a paper clip.

    Peter
    P.T. Guest

  17. #17

    Default Re: How to determine available system calls on a Unix/Linux system

    Bill Mar <com.urgent> wrote: 

    Hypothetically exactly so. Of course, to all intents and purposes, and
    a close approximation that a microbe would say !whew! to, I NEVER see
    articles posted to that group, crossposted or not.

    Peter
    P.T. Guest

  18. #18

    Default Re: How to determine available system calls on a Unix/Linux system

    P.T. Breuer wrote:
     


    Be my guest.



    Default Guest

  19. #19

    Default Re: How to determine available system calls on a Unix/Linux system

    On Mon, 20 Sep 2004 22:35:33 GMT, in comp.lang.c , it.uc3m.es
    (P.T. Breuer) wrote:
     
    >
    >Hypothetically exactly so. Of course, to all intents and purposes, and
    >a close approximation that a microbe would say !whew! to, I NEVER see
    >articles posted to that group, crossposted or not.[/ref]

    It would seem, from the brief exchange I've observed, that you ought to
    crawl back under your rock about now, to avoid having your mind polluted
    further. Thanks for playing.
    --
    Mark McIntyre
    CLC FAQ <http://www.eskimo.com/~scs/C-faq/top.html>
    CLC readme: <http://www.ungerhu.com/jxh/clc.welcome.txt>


    ----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==----
    http://www.newsfeed.com The #1 Newsgroup Service in the World! >100,000 Newsgroups
    ---= 19 East/West-Coast Specialized Servers - Total Privacy via Encryption =---
    Mark Guest

  20. #20

    Default Re: How to determine available system calls on a Unix/Linux system

    On Mon, 20 Sep 2004 11:53:52 +0000, P.T. Breuer wrote:

    [ Deleted comp.lang.c stuff to avoid needless flamming. ]
     [/ref][/ref]

    [ ... ]
     

    But not everything might be baked-in on some box, or a LKM could have
    overwritten/disabled them calls?
    CMIIW i would think something like:

    awk '!/__/{print $2}' /proc/ksyms |less

    --
    -Menno.

    Menno Guest

Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 1
    Last Post: May 30th, 09:28 AM
  2. Zip &amp; unzip using system calls
    By MAR in forum PHP Development
    Replies: 3
    Last Post: April 25th, 10:25 AM
  3. system alert for phone calls?
    By MotherScratcher in forum Mac Networking
    Replies: 0
    Last Post: August 5th, 06:51 PM
  4. Finding system data with system calls.
    By Dr. David Kirkby in forum AIX
    Replies: 2
    Last Post: July 25th, 02:46 PM
  5. Apache/Perl segfaulting on system calls
    By J. Gleixner in forum PERL Miscellaneous
    Replies: 2
    Last Post: July 7th, 03:42 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139