Changes in / [d856110:bdae198] in mainline


Ignore:
Files:
5 added
10 edited

Legend:

Unmodified
Added
Removed
  • HelenOS.config

    rd856110 rbdae198  
    291291@ "gcc_cross" GNU C Compiler (cross-compiler)
    292292@ "gcc_native" GNU C Compiler (native)
     293@ "gcc_helenos" GNU C Compiler (HelenOS-specific cross-compiler)
    293294@ "icc" Intel C Compiler
    294295@ "clang" Clang
     
    299300@ "gcc_native" GNU C Compiler (native)
    300301@ "icc" Intel C Compiler
     302@ "gcc_helenos" GNU C Compiler (HelenOS-specific cross-compiler)
    301303! [PLATFORM=ia64] COMPILER (choice)
    302304
     
    304306@ "gcc_cross" GNU C Compiler (cross-compiler)
    305307@ "gcc_native" GNU C Compiler (native)
     308@ "gcc_helenos" GNU C Compiler (HelenOS-specific cross-compiler)
    306309! [PLATFORM=mips32|PLATFORM=mips64|PLATFORM=ppc32] COMPILER (choice)
    307310
     
    309312@ "gcc_cross" GNU C Compiler (cross-compiler)
    310313@ "gcc_native" GNU C Compiler (native)
     314@ "gcc_helenos" GNU C Compiler (HelenOS-specific cross-compiler)
    311315@ "clang" Clang
    312316! [PLATFORM=abs32le|PLATFORM=arm32|PLATFORM=sparc64] COMPILER (choice)
     
    319323@ "ia32" Intel IA-32
    320324@ "mips32" MIPS 32-bit
    321 ! [PLATFORM=abs32le&COMPILER=gcc_cross] CROSS_TARGET (choice)
     325! [PLATFORM=abs32le&(COMPILER=gcc_cross|COMPILER=gcc_helenos)] CROSS_TARGET (choice)
    322326
    323327
  • boot/Makefile.build

    rd856110 rbdae198  
    7575endif
    7676
     77ifeq ($(COMPILER),gcc_helenos)
     78        CFLAGS = $(GCC_CFLAGS) $(EXTRA_CFLAGS)
     79        DEPEND_DEFS = $(DEFS) $(CONFIG_DEFS)
     80endif
     81
     82
    7783ifeq ($(COMPILER),icc)
    7884        CFLAGS = $(ICC_CFLAGS) $(EXTRA_CFLAGS)
  • kernel/Makefile

    rd856110 rbdae198  
    167167
    168168ifeq ($(COMPILER),gcc_cross)
     169        CFLAGS = $(GCC_CFLAGS)
     170        DEPEND_DEFS = $(DEFS) $(CONFIG_DEFS)
     171        INSTRUMENTATION = -finstrument-functions
     172endif
     173
     174ifeq ($(COMPILER),gcc_helenos)
    169175        CFLAGS = $(GCC_CFLAGS)
    170176        DEPEND_DEFS = $(DEFS) $(CONFIG_DEFS)
  • tools/autotool.py

    rd856110 rbdae198  
    186186        gnu_target = None
    187187        clang_target = None
     188        helenos_target = None
    188189        cc_args = []
    189190       
     
    195196                        gnu_target = "arm-linux-gnueabi"
    196197                        clang_target = "arm-unknown-linux"
     198                        helenos_target = "arm-helenos-gnueabi"
    197199               
    198200                if (config['CROSS_TARGET'] == "ia32"):
    199201                        gnu_target = "i686-pc-linux-gnu"
    200202                        clang_target = "i386-unknown-linux"
     203                        helenos_target = "i686-pc-helenos"
    201204               
    202205                if (config['CROSS_TARGET'] == "mips32"):
    203206                        gnu_target = "mipsel-linux-gnu"
    204207                        clang_target = "mipsel-unknown-linux"
     208                        helenos_target = "mipsel-helenos"
    205209                        common['CC_ARGS'].append("-mabi=32")
    206210       
     
    209213                gnu_target = "amd64-linux-gnu"
    210214                clang_target = "x86_64-unknown-linux"
     215                helenos_target = "amd64-helenos"
    211216       
    212217        if (config['PLATFORM'] == "arm32"):
     
    214219                gnu_target = "arm-linux-gnueabi"
    215220                clang_target = "arm-unknown-linux"
     221                helenos_target = "arm-helenos-gnueabi"
    216222       
    217223        if (config['PLATFORM'] == "ia32"):
     
    219225                gnu_target = "i686-pc-linux-gnu"
    220226                clang_target = "i386-unknown-linux"
     227                helenos_target = "i686-pc-helenos"
    221228       
    222229        if (config['PLATFORM'] == "ia64"):
    223230                target = config['PLATFORM']
    224231                gnu_target = "ia64-pc-linux-gnu"
     232                helenos_target = "ia64-pc-helenos"
    225233       
    226234        if (config['PLATFORM'] == "mips32"):
     
    232240                        gnu_target = "mipsel-linux-gnu"
    233241                        clang_target = "mipsel-unknown-linux"
     242                        helenos_target = "mipsel-helenos"
    234243               
    235244                if ((config['MACHINE'] == "bmalta")):
     
    237246                        gnu_target = "mips-linux-gnu"
    238247                        clang_target = "mips-unknown-linux"
     248                        helenos_target = "mips-helenos"
    239249       
    240250        if (config['PLATFORM'] == "mips64"):
     
    246256                        gnu_target = "mips64el-linux-gnu"
    247257                        clang_target = "mips64el-unknown-linux"
     258                        helenos_target = "mips64el-helenos"
    248259       
    249260        if (config['PLATFORM'] == "ppc32"):
     
    251262                gnu_target = "ppc-linux-gnu"
    252263                clang_target = "powerpc-unknown-linux"
     264                helenos_target = "ppc-helenos"
    253265       
    254266        if (config['PLATFORM'] == "sparc64"):
     
    256268                gnu_target = "sparc64-linux-gnu"
    257269                clang_target = "sparc-unknown-linux"
    258        
    259         return (target, cc_args, gnu_target, clang_target)
     270                helenos_target = "sparc64-helenos"
     271       
     272        return (target, cc_args, gnu_target, clang_target, helenos_target)
    260273
    261274def check_app(args, name, details):
     
    697710                cross_prefix = "/usr/local/cross"
    698711       
     712        # HelenOS cross-compiler prefix
     713        if ('CROSS_HELENOS_PREFIX' in os.environ):
     714                cross_helenos_prefix = os.environ['CROSS_HELENOS_PREFIX']
     715        else:
     716                cross_helenos_prefix = "/usr/local/cross-helenos"
     717       
    699718        # Prefix binutils tools on Solaris
    700719        if (os.uname()[0] == "SunOS"):
     
    719738                common['CC_ARGS'] = []
    720739                if (config['COMPILER'] == "gcc_cross"):
    721                         target, cc_args, gnu_target, clang_target = get_target(config)
     740                        target, cc_args, gnu_target, clang_target, helenos_target = get_target(config)
    722741                       
    723742                        if (target is None) or (gnu_target is None):
     
    727746                        path = "%s/%s/bin" % (cross_prefix, target)
    728747                        prefix = "%s-" % gnu_target
     748                       
     749                        check_gcc(path, prefix, common, PACKAGE_CROSS)
     750                        check_binutils(path, prefix, common, PACKAGE_CROSS)
     751                       
     752                        check_common(common, "GCC")
     753                        common['CC'] = common['GCC']
     754                        common['CC_ARGS'].extend(cc_args)
     755               
     756                if (config['COMPILER'] == "gcc_helenos"):
     757                        target, cc_args, gnu_target, clang_target, helenos_target = get_target(config)
     758                       
     759                        if (target is None) or (helenos_target is None):
     760                                print_error(["Unsupported compiler target for GNU GCC.",
     761                                             "Please contact the developers of HelenOS."])
     762                       
     763                        path = "%s/%s/bin" % (cross_helenos_prefix, target)
     764                        prefix = "%s-" % helenos_target
    729765                       
    730766                        check_gcc(path, prefix, common, PACKAGE_CROSS)
  • tools/toolchain.sh

    rd856110 rbdae198  
    5555BINUTILS_VERSION="2.23.1"
    5656BINUTILS_RELEASE=""
     57BINUTILS_PATCHES="toolchain-binutils-2.23.1.patch"
    5758GCC_VERSION="4.8.1"
     59GCC_PATCHES="toolchain-gcc-4.8.1-targets.patch toolchain-gcc-4.8.1-headers.patch"
    5860GDB_VERSION="7.6"
     61GDB_PATCHES="toolchain-gdb-7.6.patch"
    5962
    6063BASEDIR="`pwd`"
     
    6265GCC="gcc-${GCC_VERSION}.tar.bz2"
    6366GDB="gdb-${GDB_VERSION}.tar.bz2"
     67
     68REAL_INSTALL=true
     69USE_HELENOS_TARGET=false
     70INSTALL_DIR="${BASEDIR}/PKG"
    6471
    6572#
     
    135142        echo
    136143        echo "Syntax:"
    137         echo " $0 <platform>"
     144        echo " $0 [--no-install] [--helenos-target] <platform>"
    138145        echo
    139146        echo "Possible target platforms are:"
     
    152159        echo " 2-way      same as 'all', but 2-way parallel"
    153160        echo
    154         echo "The toolchain will be installed to the directory specified by"
    155         echo "the CROSS_PREFIX environment variable. If the variable is not"
    156         echo "defined, /usr/local/cross will be used by default."
     161        echo "The toolchain is installed into directory specified by the"
     162        echo "CROSS_PREFIX environment variable. If the variable is not"
     163        echo "defined, /usr/local/cross/ is used as default."
     164        echo
     165        echo "If --no-install is present, the toolchain still uses the"
     166        echo "CROSS_PREFIX as the target directory but the installation"
     167        echo "copies the files into PKG/ subdirectory without affecting"
     168        echo "the actual root file system. That is only useful if you do"
     169        echo "not want to run the script under the super user."
     170        echo
     171        echo "The --helenos-target will build HelenOS-specific toolchain"
     172        echo "(i.e. it will use *-helenos-* triplet instead of *-linux-*)."
     173        echo "This toolchain is installed into /usr/local/cross-helenos by"
     174        echo "default. The settings can be changed by setting environment"
     175        echo "variable CROSS_HELENOS_PREFIX."
    157176        echo
    158177       
     
    265284}
    266285
     286patch_sources() {
     287        PATCH_FILE="$1"
     288        PATCH_STRIP="$2"
     289        DESC="$3"
     290       
     291        change_title "Patching ${DESC}"
     292        echo " >>> Patching ${DESC} with ${PATCH_FILE}"
     293       
     294        patch -t "-p${PATCH_STRIP}" <"$PATCH_FILE"
     295        check_error $? "Error patching ${DESC}."
     296}
     297
    267298prepare() {
    268299        show_dependencies
     
    279310}
    280311
     312set_target_from_platform() {
     313        case "$1" in
     314                "amd64")
     315                        LINUX_TARGET="amd64-linux-gnu"
     316                        HELENOS_TARGET="amd64-helenos"
     317                        ;;
     318                "arm32")
     319                        LINUX_TARGET="arm-linux-gnueabi"
     320                        HELENOS_TARGET="arm-helenos-gnueabi"
     321                        ;;
     322                "ia32")
     323                        LINUX_TARGET="i686-pc-linux-gnu"
     324                        HELENOS_TARGET="i686-pc-helenos"
     325                        ;;
     326                "ia64")
     327                        LINUX_TARGET="ia64-pc-linux-gnu"
     328                        HELENOS_TARGET="ia64-pc-helenos"
     329                        ;;
     330                "mips32")
     331                        LINUX_TARGET="mipsel-linux-gnu"
     332                        HELENOS_TARGET="mipsel-helenos"
     333                        ;;
     334                "mips32eb")
     335                        LINUX_TARGET="mips-linux-gnu"
     336                        HELENOS_TARGET="mips-helenos"
     337                        ;;
     338                "mips64")
     339                        LINUX_TARGET="mips64el-linux-gnu"
     340                        HELENOS_TARGET="mips64el-helenos"
     341                        ;;
     342                "ppc32")
     343                        LINUX_TARGET="ppc-linux-gnu"
     344                        HELENOS_TARGET="ppc-helenos"
     345                        ;;
     346                "ppc64")
     347                        LINUX_TARGET="ppc64-linux-gnu"
     348                        HELENOS_TARGET="ppc64-helenos"
     349                        ;;
     350                "sparc64")
     351                        LINUX_TARGET="sparc64-linux-gnu"
     352                        HELENOS_TARGET="sparc64-helenos"
     353                        ;;
     354                *)
     355                        check_error 1 "No target known for $1."
     356                        ;;
     357        esac
     358}
     359
    281360build_target() {
    282361        PLATFORM="$1"
    283         TARGET="$2"
     362        # This sets the *_TARGET variables
     363        set_target_from_platform "$PLATFORM"
     364        if $USE_HELENOS_TARGET; then
     365                TARGET="$HELENOS_TARGET"
     366        else
     367                TARGET="$LINUX_TARGET"
     368        fi
    284369       
    285370        WORKDIR="${BASEDIR}/${PLATFORM}"
     
    292377                CROSS_PREFIX="/usr/local/cross"
    293378        fi
    294        
    295         PREFIX="${CROSS_PREFIX}/${PLATFORM}"
     379        if [ -z "${CROSS_HELENOS_PREFIX}" ] ; then
     380                CROSS_HELENOS_PREFIX="/usr/local/cross-helenos"
     381        fi
     382       
     383        if $USE_HELENOS_TARGET; then
     384                PREFIX="${CROSS_HELENOS_PREFIX}/${PLATFORM}"
     385        else
     386                PREFIX="${CROSS_PREFIX}/${PLATFORM}"
     387        fi
    296388       
    297389        echo ">>> Downloading tarballs"
     
    301393       
    302394        echo ">>> Removing previous content"
    303         cleanup_dir "${PREFIX}"
     395        $REAL_INSTALL && cleanup_dir "${PREFIX}"
    304396        cleanup_dir "${WORKDIR}"
    305397       
    306         create_dir "${PREFIX}" "destination directory"
     398        $REAL_INSTALL && create_dir "${PREFIX}" "destination directory"
    307399        create_dir "${OBJDIR}" "GCC object directory"
    308400       
     
    315407        unpack_tarball "${BASEDIR}/${GDB}" "GDB"
    316408       
     409        echo ">>> Applying patches"
     410        for p in $BINUTILS_PATCHES; do
     411                patch_sources "${BASEDIR}/${p}" 0 "binutils"
     412        done
     413        for p in $GCC_PATCHES; do
     414                patch_sources "${BASEDIR}/${p}" 0 "GCC"
     415        done
     416        for p in $GDB_PATCHES; do
     417                patch_sources "${BASEDIR}/${p}" 0 "GDB"
     418        done
     419       
    317420        echo ">>> Processing binutils (${PLATFORM})"
    318421        cd "${BINUTILSDIR}"
     
    320423       
    321424        change_title "binutils: configure (${PLATFORM})"
    322         CFLAGS=-Wno-error ./configure "--target=${TARGET}" "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" --disable-nls --disable-werror
     425        CFLAGS=-Wno-error ./configure \
     426                "--target=${TARGET}" \
     427                "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" \
     428                --disable-nls --disable-werror
    323429        check_error $? "Error configuring binutils."
    324430       
    325431        change_title "binutils: make (${PLATFORM})"
    326         make all install
    327         check_error $? "Error compiling/installing binutils."
     432        make all
     433        check_error $? "Error compiling binutils."
     434       
     435        change_title "binutils: install (${PLATFORM})"
     436        if $REAL_INSTALL; then
     437                make install
     438        else
     439                make install "DESTDIR=${INSTALL_DIR}"
     440        fi
     441        check_error $? "Error installing binutils."
     442       
    328443       
    329444        echo ">>> Processing GCC (${PLATFORM})"
     
    332447       
    333448        change_title "GCC: configure (${PLATFORM})"
    334         "${GCCDIR}/configure" "--target=${TARGET}" "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" --with-gnu-as --with-gnu-ld --disable-nls --disable-threads --enable-languages=c,objc,c++,obj-c++ --disable-multilib --disable-libgcj --without-headers --disable-shared --enable-lto --disable-werror
     449        PATH="$PATH:${INSTALL_DIR}/${PREFIX}/bin" "${GCCDIR}/configure" \
     450                "--target=${TARGET}" \
     451                "--prefix=${PREFIX}" "--program-prefix=${TARGET}-" \
     452                --with-gnu-as --with-gnu-ld --disable-nls --disable-threads \
     453                --enable-languages=c,objc,c++,obj-c++ \
     454                --disable-multilib --disable-libgcj --without-headers \
     455                --disable-shared --enable-lto --disable-werror
    335456        check_error $? "Error configuring GCC."
    336457       
    337458        change_title "GCC: make (${PLATFORM})"
    338         PATH="${PATH}:${PREFIX}/bin" make all-gcc install-gcc
    339         check_error $? "Error compiling/installing GCC."
     459        PATH="${PATH}:${PREFIX}/bin:${INSTALL_DIR}/${PREFIX}/bin" make all-gcc
     460        check_error $? "Error compiling GCC."
     461       
     462        change_title "GCC: install (${PLATFORM})"
     463        if $REAL_INSTALL; then
     464                PATH="${PATH}:${PREFIX}/bin" make install-gcc
     465        else
     466                PATH="${PATH}:${INSTALL_DIR}/${PREFIX}/bin" make install-gcc "DESTDIR=${INSTALL_DIR}"
     467        fi
     468        check_error $? "Error installing GCC."
     469       
    340470       
    341471        echo ">>> Processing GDB (${PLATFORM})"
     
    344474       
    345475        change_title "GDB: configure (${PLATFORM})"
    346         ./configure "--target=${TARGET}" "--prefix=${PREFIX}" "--program-prefix=${TARGET}-"
     476        PATH="$PATH:${INSTALL_DIR}/${PREFIX}/bin" ./configure \
     477                "--target=${TARGET}" \
     478                "--prefix=${PREFIX}" "--program-prefix=${TARGET}-"
    347479        check_error $? "Error configuring GDB."
    348480       
    349481        change_title "GDB: make (${PLATFORM})"
    350         make all install
    351         check_error $? "Error compiling/installing GDB."
     482        PATH="${PATH}:${PREFIX}/bin:${INSTALL_DIR}/${PREFIX}/bin" make all
     483        check_error $? "Error compiling GDB."
     484       
     485        change_title "GDB: make (${PLATFORM})"
     486        if $REAL_INSTALL; then
     487                PATH="${PATH}:${PREFIX}/bin" make install
     488        else
     489                PATH="${PATH}:${INSTALL_DIR}/${PREFIX}/bin" make install "DESTDIR=${INSTALL_DIR}"
     490        fi
     491        check_error $? "Error installing GDB."
     492       
    352493       
    353494        cd "${BASEDIR}"
     
    360501        echo ">>> Cross-compiler for ${TARGET} installed."
    361502}
     503
     504while [ "$#" -gt 1 ]; do
     505        case "$1" in
     506                --no-install)
     507                        REAL_INSTALL=false
     508                        shift
     509                        ;;
     510                --helenos-target)
     511                        USE_HELENOS_TARGET=true
     512                        shift
     513                        ;;
     514                *)
     515                        show_usage
     516                        ;;
     517        esac
     518done
    362519
    363520if [ "$#" -lt "1" ]; then
     
    366523
    367524case "$1" in
    368         "amd64")
     525        amd64|arm32|ia32|ia64|mips32|mips32eb|mips64|ppc32|ppc64|sparc64)
    369526                prepare
    370                 build_target "amd64" "amd64-linux-gnu"
    371                 ;;
    372         "arm32")
    373                 prepare
    374                 build_target "arm32" "arm-linux-gnueabi"
    375                 ;;
    376         "ia32")
    377                 prepare
    378                 build_target "ia32" "i686-pc-linux-gnu"
    379                 ;;
    380         "ia64")
    381                 prepare
    382                 build_target "ia64" "ia64-pc-linux-gnu"
    383                 ;;
    384         "mips32")
    385                 prepare
    386                 build_target "mips32" "mipsel-linux-gnu"
    387                 ;;
    388         "mips32eb")
    389                 prepare
    390                 build_target "mips32eb" "mips-linux-gnu"
    391                 ;;
    392         "mips64")
    393                 prepare
    394                 build_target "mips64" "mips64el-linux-gnu"
    395                 ;;
    396         "ppc32")
    397                 prepare
    398                 build_target "ppc32" "ppc-linux-gnu"
    399                 ;;
    400         "ppc64")
    401                 prepare
    402                 build_target "ppc64" "ppc64-linux-gnu"
    403                 ;;
    404         "sparc64")
    405                 prepare
    406                 build_target "sparc64" "sparc64-linux-gnu"
     527                build_target "$1"
    407528                ;;
    408529        "all")
    409530                prepare
    410                 build_target "amd64" "amd64-linux-gnu"
    411                 build_target "arm32" "arm-linux-gnueabi"
    412                 build_target "ia32" "i686-pc-linux-gnu"
    413                 build_target "ia64" "ia64-pc-linux-gnu"
    414                 build_target "mips32" "mipsel-linux-gnu"
    415                 build_target "mips32eb" "mips-linux-gnu"
    416                 build_target "mips64" "mips64el-linux-gnu"
    417                 build_target "ppc32" "ppc-linux-gnu"
    418                 build_target "ppc64" "ppc64-linux-gnu"
    419                 build_target "sparc64" "sparc64-linux-gnu"
     531                build_target "amd64"
     532                build_target "arm32"
     533                build_target "ia32"
     534                build_target "ia64"
     535                build_target "mips32"
     536                build_target "mips32eb"
     537                build_target "mips64"
     538                build_target "ppc32"
     539                build_target "ppc64"
     540                build_target "sparc64"
    420541                ;;
    421542        "parallel")
    422543                prepare
    423                 build_target "amd64" "amd64-linux-gnu" &
    424                 build_target "arm32" "arm-linux-gnueabi" &
    425                 build_target "ia32" "i686-pc-linux-gnu" &
    426                 build_target "ia64" "ia64-pc-linux-gnu" &
    427                 build_target "mips32" "mipsel-linux-gnu" &
    428                 build_target "mips32eb" "mips-linux-gnu" &
    429                 build_target "mips64" "mips64el-linux-gnu" &
    430                 build_target "ppc32" "ppc-linux-gnu" &
    431                 build_target "ppc64" "ppc64-linux-gnu" &
    432                 build_target "sparc64" "sparc64-linux-gnu" &
     544                build_target "amd64" &
     545                build_target "arm32" &
     546                build_target "ia32" &
     547                build_target "ia64" &
     548                build_target "mips32" &
     549                build_target "mips32eb" &
     550                build_target "mips64" &
     551                build_target "ppc32" &
     552                build_target "ppc64" &
     553                build_target "sparc64" &
    433554                wait
    434555                ;;
    435556        "2-way")
    436557                prepare
    437                 build_target "amd64" "amd64-linux-gnu" &
    438                 build_target "arm32" "arm-linux-gnueabi" &
     558                build_target "amd64" &
     559                build_target "arm32" &
    439560                wait
    440561               
    441                 build_target "ia32" "i686-pc-linux-gnu" &
    442                 build_target "ia64" "ia64-pc-linux-gnu" &
     562                build_target "ia32" &
     563                build_target "ia64" &
    443564                wait
    444565               
    445                 build_target "mips32" "mipsel-linux-gnu" &
    446                 build_target "mips32eb" "mips-linux-gnu" &
     566                build_target "mips32" &
     567                build_target "mips32eb" &
    447568                wait
    448569               
    449                 build_target "mips64" "mips64el-linux-gnu" &
    450                 build_target "ppc32" "ppc-linux-gnu" &
     570                build_target "mips64" &
     571                build_target "ppc32" &
    451572                wait
    452573               
    453                 build_target "ppc64" "ppc64-linux-gnu" &
    454                 build_target "sparc64" "sparc64-linux-gnu" &
     574                build_target "ppc64" &
     575                build_target "sparc64" &
    455576                wait
    456577                ;;
  • uspace/Makefile.common

    rd856110 rbdae198  
    243243endif
    244244
     245ifeq ($(COMPILER),gcc_helenos)
     246        CFLAGS += $(GCC_CFLAGS) $(EXTRA_CFLAGS)
     247        DEPEND_DEFS = $(DEFS) $(CONFIG_DEFS)
     248endif
     249
    245250ifeq ($(COMPILER),gcc_native)
    246251        CFLAGS += $(GCC_CFLAGS) $(EXTRA_CFLAGS)
  • uspace/lib/posix/include/posix/float.h

    rd856110 rbdae198  
    6161        #undef FLT_RADIX
    6262        #define FLT_RADIX __FLT_RADIX__
     63        #undef FLT_MIN
     64        #define FLT_MIN __FLT_MIN__
     65        #undef FLT_MAX
     66        #define FLT_MAX __FLT_MAX__
     67        #undef FLT_EPSILON
     68        #define FLT_EPSILON __FLT_EPSILON__
     69        #undef FLT_MANT_DIG
     70        #define FLT_MANT_DIG __FLT_MANT_DIG__
     71        #undef LDBL_MANT_DIG
     72        #define LDBL_MANT_DIG __LDBL_MANT_DIG__
    6373#else
    6474/* For something else than GCC, following definitions are provided.
  • uspace/lib/posix/include/posix/stdint.h

    rd856110 rbdae198  
    108108
    109109
     110/*
     111 * Fast* and least* integer types.
     112 *
     113 * The definitions below are definitely safe if not the best.
     114 */
     115typedef uint8_t uint_least8_t;
     116typedef uint16_t uint_least16_t;
     117typedef uint32_t uint_least32_t;
     118typedef uint64_t uint_least64_t;
     119
     120typedef int8_t int_least8_t;
     121typedef int16_t int_least16_t;
     122typedef int32_t int_least32_t;
     123typedef int64_t int_least64_t;
     124
     125typedef uint8_t uint_fast8_t;
     126typedef uint16_t uint_fast16_t;
     127typedef uint32_t uint_fast32_t;
     128typedef uint64_t uint_fast64_t;
     129
     130typedef int8_t int_fast8_t;
     131typedef int16_t int_fast16_t;
     132typedef int32_t int_fast32_t;
     133typedef int64_t int_fast64_t;
     134
    110135#endif /* POSIX_STDINT_H_ */
    111136
  • uspace/lib/posix/include/posix/stdio.h

    rd856110 rbdae198  
    123123
    124124extern void setvbuf(FILE *, void *, int, size_t);
    125 
     125extern void setbuf(FILE *, void *);
    126126
    127127/* POSIX specific stuff. */
  • uspace/lib/posix/include/posix/time.h

    rd856110 rbdae198  
    101101extern char *__POSIX_DEF__(ctime_r)(const time_t *timer, char *buf);
    102102extern char *__POSIX_DEF__(ctime)(const time_t *timer);
     103extern time_t time(time_t *t);
    103104
    104105/* Clocks */
Note: See TracChangeset for help on using the changeset viewer.