Portable use of uint64_t

From: Kasper Dupont (kasperd_at_daimi.au.dk)
Date: 04/12/05

  • Next message: Vijay: "too slow server...."
    Date: Tue, 12 Apr 2005 14:21:15 +0200
    
    

    I have an application that needs to use uint64_t. On
    Linux I can include <stdint.h> and then it works fine.

    But I would like this code to be as portable as
    possible. I found that on IRIX and Solaris there is
    no <stdint.h>. If I remove the include line, the code
    compiles and works as intended.

    But without <stdint.h> the code no longer compiles on
    Linux. So how do I write the code such that it works
    in both cases?

    I don't want to generate header files and Make files,
    I want to keep it simple and just write the .c file in
    a portable way.

    Another problem I ran into is the fact that I use
    /dev/urandom to generate random bytes. That doesn't
    exist on IRIX, is there a portable way to generate
    random bytes?

    -- 
    Kasper Dupont
    

  • Next message: Vijay: "too slow server...."

    Relevant Pages

    • Re: GPL vs non-GPL device drivers
      ... linux cross for Irix removal), MIPS embedded (including the port to Linux ... of Algorithmics toolchain) for Sonix then 3COM routers. ... IRIX, ConvexOS, embedded MIPS and ARM and x86. ... all of them to be contributed upstream because I ...
      (Linux-Kernel)
    • Re: LINUX vs AIX
      ... That is really the last issue that sets AIX (and maybe IRIX?) ... 99% of kernel development done by at-home ... I wish Linux would take a few tips from the *BSDs at the same time. ... SGI) ...
      (comp.unix.aix)
    • Re: Another one bites the dust
      ... SGI is pushing the Linux thing ... ... or her (or SGI as a whole) to sign an NDA or non-compete. ... in supercomputing os'es due to their years of experience with Irix. ... dispute with IBM is based on a conflicting reading of the original AT&T ...
      (comp.sys.sgi.misc)
    • Re: Project Ultraviolet: No IRIX?
      ... > Comicness aside, why no mention of IRIX in the article, or in the PR? ... IRIX has been shown NOT to be FLEXIBLE since it can't be ported to INTEL. ... for the companies that SGI needs to inform, ... and "intel", and "linux". ...
      (comp.sys.sgi.misc)
    • Re: Another one bites the dust
      ... > Linux to make it handle SMP better. ... SGI is pushing the Linux thing ... ... in supercomputing os'es due to their years of experience with Irix. ... IBM isn't in this position. ...
      (comp.sys.sgi.misc)