From 200fbe924466720bd2a8c5eb05b05d67b0a2414c Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Thu, 14 Mar 2013 15:42:19 +0100 Subject: Added support for ENEA OSE This port has support for both non-smp and smp. It contains a new way to do io checking in which erts_poll_wait receives the payload of the polled entity. This has implications for all linked-in drivers. --- xcomp/erl-xcomp-powerpc-ose5.conf | 305 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 305 insertions(+) create mode 100644 xcomp/erl-xcomp-powerpc-ose5.conf (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf new file mode 100644 index 0000000000..f640c3f3fb --- /dev/null +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -0,0 +1,305 @@ +## -*-shell-script-*- +## +## %CopyrightBegin% +## +## Copyright Ericsson AB 2009-2012. All Rights Reserved. +## +## The contents of this file are subject to the Erlang Public License, +## Version 1.1, (the "License"); you may not use this file except in +## compliance with the License. You should have received a copy of the +## Erlang Public License along with this software. If not, it can be +## retrieved online at http://www.erlang.org/. +## +## Software distributed under the License is distributed on an "AS IS" +## basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See +## the License for the specific language governing rights and limitations +## under the License. +## +## %CopyrightEnd% +## +## File: erl-xcomp-sfk-linux-ose5.conf +## Author: Petre Pircalabu +## +## ----------------------------------------------------------------------------- +## When cross compiling Erlang/OTP using `otp_build', copy this file and set +## the variables needed below. Then pass the path to the copy of this file as +## an argument to `otp_build' in the configure stage: +## `otp_build configure --xcomp-conf=' +## ----------------------------------------------------------------------------- + +## Note that you cannot define arbitrary variables in a cross compilation +## configuration file. Only the ones listed below will be guaranteed to be +## visible throughout the whole execution of all `configure' scripts. Other +## variables needs to be defined as arguments to `configure' or exported in +## the environment. + +## -- Variables needed for an OSE5 build --------------------------------------- +OSEROOT="/vobs/ose5/system" +HOST="linux" +GCCVERSION="4.6.3" +GCCROOT="${OSEROOT}/gcc_linux_powerpc_${GCCVERSION}" +GCCTARGET="powerpc-ose-eabi" + +## -- Variables for `otp_build' Only ------------------------------------------- + +## Variables in this section are only used, when configuring Erlang/OTP for +## cross compilation using `$ERL_TOP/otp_build configure'. + +## *NOTE*! These variables currently have *no* effect if you configure using +## the `configure' script directly. + +# * `erl_xcomp_build' - The build system used. This value will be passed as +# `--build=$erl_xcomp_build' argument to the `configure' script. It does +# not have to be a full `CPU-VENDOR-OS' triplet, but can be. The full +# `CPU-VENDOR-OS' triplet will be created by +# `$ERL_TOP/erts/autoconf/config.sub $erl_xcomp_build'. If set to `guess', +# the build system will be guessed using +# `$ERL_TOP/erts/autoconf/config.guess'. +erl_xcomp_build=guess + +# * `erl_xcomp_host' - Cross host/target system to build for. This value will +# be passed as `--host=$erl_xcomp_host' argument to the `configure' script. +# It does not have to be a full `CPU-VENDOR-OS' triplet, but can be. The +# full `CPU-VENDOR-OS' triplet will be created by +# `$ERL_TOP/erts/autoconf/config.sub $erl_xcomp_host'. +erl_xcomp_host="powerpc-ose" + +# * `erl_xcomp_configure_flags' - Extra configure flags to pass to the +# `configure' script. +erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termcap --without-javac --disable-dynamic-ssl-lib --disable-shared-zlib --without-ssl --enable-static-nifs=$ERL_TOP/lib/asn1/priv/lib/powerpc-unknown-ose/asn1rt_nif.a" + +## -- Cross Compiler and Other Tools ------------------------------------------- + +## If the cross compilation tools are prefixed by `-' you probably do +## not need to set these variables (where `' is what has been passed as +## `--host=' argument to `configure'). + +## All variables in this section can also be used when native compiling. + +# * `CC' - C compiler. +CC="$GCCROOT/bin/$GCCTARGET-gcc" + +# * `CFLAGS' - C compiler flags. +CFLAGS="-g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" + + +# * `STATIC_CFLAGS' - Static C compiler flags. +#STATIC_CFLAGS= + +# * `CFLAG_RUNTIME_LIBRARY_PATH' - This flag should set runtime library +# search path for the shared libraries. Note that this actually is a +# linker flag, but it needs to be passed via the compiler. +#CFLAG_RUNTIME_LIBRARY_PATH= + +# * `CPP' - C pre-processor. +CPP="$GCCROOT/bin/$GCCTARGET-cpp" + +# * `CPPFLAGS' - C pre-processor flags. +CPPFLAGS="-g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" + + +# * `CXX' - C++ compiler. +CXX="$GCCROOT/bin/$GCCTARGET-g++" + +# * `CXXFLAGS' - C++ compiler flags. +CXXFLAGS="-g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/gcc -O2" + +# * `LD' - Linker. +LD="${GCCROOT}/bin/${GCCTARGET}-ld" + +# * `LDFLAGS' - Linker flags. +LDFLAGS="-Wl,-ecrt0_lm -Wl,-T,${ERL_TOP}/erts/emulator/sys/ose/gcc_lm_ppc.lcf" + +# * `LIBS' - Libraries. +LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/libgcc.a" + +## -- *D*ynamic *E*rlang *D*river Linking -- + +## *NOTE*! Either set all or none of the `DED_LD*' variables. + +# * `DED_LD' - Linker for Dynamically loaded Erlang Drivers. +DED_LD= + +# * `DED_LDFLAGS' - Linker flags to use with `DED_LD'. +DED_LDFLAGS= + +# * `DED_LD_FLAG_RUNTIME_LIBRARY_PATH' - This flag should set runtime library +# search path for shared libraries when linking with `DED_LD'. +DED_LD_FLAG_RUNTIME_LIBRARY_PATH= + +## -- Large File Support -- + +## *NOTE*! Either set all or none of the `LFS_*' variables. + +# * `LFS_CFLAGS' - Large file support C compiler flags. +#LFS_CFLAGS= + +# * `LFS_LDFLAGS' - Large file support linker flags. +#LFS_LDFLAGS= + +# * `LFS_LIBS' - Large file support libraries. +#LFS_LIBS= + +## -- Other Tools -- + +# * `RANLIB' - `ranlib' archive index tool. +RANLIB="$GCCROOT/bin/$GCCTARGET-ranlib" + +# * `AR' - `ar' archiving tool. +AR="$GCCROOT/bin/$GCCTARGET-ar" + +# * `STRIP' - `strip +STRIP="$GCCROOT/bin/$GCCTARGET-strip" + +# * `GETCONF' - `getconf' system configuration inspection tool. `getconf' is +# currently used for finding out large file support flags to use, and +# on Linux systems for finding out if we have an NPTL thread library or +# not. +#GETCONF= + +## -- Cross System Root Locations ---------------------------------------------- + +# * `erl_xcomp_sysroot' - The absolute path to the system root of the cross +# compilation environment. Currently, the `crypto', `odbc', `ssh' and +# `ssl' applications need the system root. These applications will be +# skipped if the system root has not been set. The system root might be +# needed for other things too. If this is the case and the system root +# has not been set, `configure' will fail and request you to set it. +erl_xcomp_sysroot="$OSEROOT" + +# * `erl_xcomp_isysroot' - The absolute path to the system root for includes +# of the cross compilation environment. If not set, this value defaults +# to `$erl_xcomp_sysroot', i.e., only set this value if the include system +# root path is not the same as the system root path. +erl_xcomp_isysroot="$OSEROOT/include" + +## -- Optional Feature, and Bug Tests ------------------------------------------ + +## These tests cannot (always) be done automatically when cross compiling. You +## usually do not need to set these variables. Only set these if you really +## know what you are doing. + +## Note that some of these values will override results of tests performed +## by `configure', and some will not be used until `configure' is sure that +## it cannot figure the result out. + +## The `configure' script will issue a warning when a default value is used. +## When a variable has been set, no warning will be issued. + +# * `erl_xcomp_after_morecore_hook' - `yes|no'. Defaults to `no'. If `yes', +# the target system must have a working `__after_morecore_hook' that can be +# used for tracking used `malloc()' implementations core memory usage. +# This is currently only used by unsupported features. +#erl_xcomp_after_morecore_hook= + +# * `erl_xcomp_bigendian' - `yes|no'. No default. If `yes', the target system +# must be big endian. If `no', little endian. This can often be +# automatically detected, but not always. If not automatically detected, +# `configure' will fail unless this variable is set. Since no default +# value is used, `configure' will try to figure this out automatically. +#erl_xcomp_bigendian= + +# * `erl_xcomp_double_middle` - `yes|no`. No default. If `yes`, the +# target system must have doubles in "middle-endian" format. If +# `no`, it has "regular" endianness. This can often be automatically +# detected, but not always. If not automatically detected, +# `configure` will fail unless this variable is set. Since no +# default value is used, `configure` will try to figure this out +# automatically. +#erl_xcomp_double_middle_endian + +# * `erl_xcomp_clock_gettime_cpu_time' - `yes|no'. Defaults to `no'. If `yes', +# the target system must have a working `clock_gettime()' implementation +# that can be used for retrieving process CPU time. +#erl_xcomp_clock_gettime_cpu_time= + +# * `erl_xcomp_getaddrinfo' - `yes|no'. Defaults to `no'. If `yes', the target +# system must have a working `getaddrinfo()' implementation that can +# handle both IPv4 and IPv6. +#erl_xcomp_getaddrinfo= + +# * `erl_xcomp_gethrvtime_procfs_ioctl' - `yes|no'. Defaults to `no'. If `yes', +# the target system must have a working `gethrvtime()' implementation and +# is used with procfs `ioctl()'. +#erl_xcomp_gethrvtime_procfs_ioctl= + +# * `erl_xcomp_dlsym_brk_wrappers' - `yes|no'. Defaults to `no'. If `yes', the +# target system must have a working `dlsym(RTLD_NEXT, )' implementation +# that can be used on `brk' and `sbrk' symbols used by the `malloc()' +# implementation in use, and by this track the `malloc()' implementations +# core memory usage. This is currently only used by unsupported features. +#erl_xcomp_dlsym_brk_wrappers= + +# * `erl_xcomp_kqueue' - `yes|no'. Defaults to `no'. If `yes', the target +# system must have a working `kqueue()' implementation that returns a file +# descriptor which can be used by `poll()' and/or `select()'. If `no' and +# the target system has not got `epoll()' or `/dev/poll', the kernel-poll +# feature will be disabled. +#erl_xcomp_kqueue= + +# * `erl_xcomp_linux_clock_gettime_correction' - `yes|no'. Defaults to `yes' on +# Linux; otherwise, `no'. If `yes', `clock_gettime(CLOCK_MONOTONIC, _)' on +# the target system must work. This variable is recommended to be set to +# `no' on Linux systems with kernel versions less than 2.6. +#erl_xcomp_linux_clock_gettime_correction= + +# * `erl_xcomp_linux_nptl' - `yes|no'. Defaults to `yes' on Linux; otherwise, +# `no'. If `yes', the target system must have NPTL (Native POSIX Thread +# Library). Older Linux systems have LinuxThreads instead of NPTL (Linux +# kernel versions typically less than 2.6). +#erl_xcomp_linux_nptl= + +# * `erl_xcomp_linux_usable_sigaltstack' - `yes|no'. Defaults to `yes' on Linux; +# otherwise, `no'. If `yes', `sigaltstack()' must be usable on the target +# system. `sigaltstack()' on Linux kernel versions less than 2.4 are +# broken. +#erl_xcomp_linux_usable_sigaltstack= + +# * `erl_xcomp_linux_usable_sigusrx' - `yes|no'. Defaults to `yes'. If `yes', +# the `SIGUSR1' and `SIGUSR2' signals must be usable by the ERTS. Old +# LinuxThreads thread libraries (Linux kernel versions typically less than +# 2.2) used these signals and made them unusable by the ERTS. +#erl_xcomp_linux_usable_sigusrx= + +# * `erl_xcomp_poll' - `yes|no'. Defaults to `no' on Darwin/MacOSX; otherwise, +# `yes'. If `yes', the target system must have a working `poll()' +# implementation that also can handle devices. If `no', `select()' will be +# used instead of `poll()'. +erl_xcomp_poll=no + +# * `erl_xcomp_putenv_copy' - `yes|no'. Defaults to `no'. If `yes', the target +# system must have a `putenv()' implementation that stores a copy of the +# key/value pair. +#erl_xcomp_putenv_copy= + +# * `erl_xcomp_reliable_fpe' - `yes|no'. Defaults to `no'. If `yes', the target +# system must have reliable floating point exceptions. +#erl_xcomp_reliable_fpe= +# * `erl_xcomp_ose_ldflags_pass1` - Linker flags for the OSE module (pass 1) +erl_xcomp_ose_ldflags_pass1="-r --no-omagic" + +# * `erl_xcomp_ose_ldflags_pass2` - Linker flags for the OSE module (pass 2) +erl_xcomp_ose_ldflags_pass2="-n --emit-relocs -ecrt0_lm --no-omagic" + +# * `erl_xcomp_ose_OSEROOT` - OSE installation root directory +erl_xcomp_ose_OSEROOT="${OSEROOT}" + +# * `erl_xcomp_ose_STRIP` - Strip utility shipped with the OSE distribution +erl_xcomp_ose_STRIP="${GCCROOT}/bin/${GCCTARGET}-strip" + +# * `erl_xcomp_ose_LM_POST_LINK` - OSE postlink tool +erl_xcomp_ose_LM_POST_LINK="${OSEROOT}/bin/${HOST}/lm_post_link" + +# * `erl_xcomp_ose_LM_SET_CONF` - Sets the configuration for an OSE load module +erl_xcomp_ose_LM_SET_CONF="${OSEROOT}/bin/${HOST}/lm_set_conf" + +# * `erl_xcomp_ose_LM_ELF_SIZE` - OSE load module elf size tool +erl_xcomp_ose_LM_ELF_SIZE="${OSEROOT}/bin/${HOST}/lm_elf_size" + +# * `erl_xcomp_ose_LM_LCF` - OSE load module linker configuration file +erl_xcomp_ose_LM_LCF="${ERL_TOP}/erts/emulator/sys/ose/gcc_lm_ppc.lcf" + +# * `erl_xcomp_ose_LM_CONF` - OSE load module default configuration file +erl_xcomp_ose_LM_CONF="${ERL_TOP}/erts/emulator/sys/ose/default.lmconf" + +## ----------------------------------------------------------------------------- -- cgit v1.2.3 From 67c5954250d8a07e3b6ddb9851f33a16fd631a0f Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Fri, 23 Aug 2013 17:58:55 +0200 Subject: ose: Use the swfp when compiling for OSE The hwfp has been tested as well and seem to work, but most processors that OSE will run on does not have a fpu. --- xcomp/erl-xcomp-powerpc-ose5.conf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index f640c3f3fb..564f1df2a7 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -80,7 +80,7 @@ erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termca CC="$GCCROOT/bin/$GCCTARGET-gcc" # * `CFLAGS' - C compiler flags. -CFLAGS="-g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" +CFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" # * `STATIC_CFLAGS' - Static C compiler flags. @@ -95,14 +95,14 @@ CFLAGS="-g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pr CPP="$GCCROOT/bin/$GCCTARGET-cpp" # * `CPPFLAGS' - C pre-processor flags. -CPPFLAGS="-g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" +CPPFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" # * `CXX' - C++ compiler. CXX="$GCCROOT/bin/$GCCTARGET-g++" # * `CXXFLAGS' - C++ compiler flags. -CXXFLAGS="-g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/gcc -O2" +CXXFLAGS="-msoft-float -g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/gcc -O2" # * `LD' - Linker. LD="${GCCROOT}/bin/${GCCTARGET}-ld" @@ -111,7 +111,7 @@ LD="${GCCROOT}/bin/${GCCTARGET}-ld" LDFLAGS="-Wl,-ecrt0_lm -Wl,-T,${ERL_TOP}/erts/emulator/sys/ose/gcc_lm_ppc.lcf" # * `LIBS' - Libraries. -LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/libgcc.a" +LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/nof/libgcc.a" ## -- *D*ynamic *E*rlang *D*river Linking -- -- cgit v1.2.3 From 51a07bb5770ddbbf10c5be969985c5f6b36e4a4c Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Tue, 22 Oct 2013 17:49:17 +0200 Subject: ose: Add link conf for gcc 4.4.3 --- xcomp/erl-xcomp-powerpc-ose5.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index 564f1df2a7..be2944618c 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -108,7 +108,7 @@ CXXFLAGS="-msoft-float -g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCC LD="${GCCROOT}/bin/${GCCTARGET}-ld" # * `LDFLAGS' - Linker flags. -LDFLAGS="-Wl,-ecrt0_lm -Wl,-T,${ERL_TOP}/erts/emulator/sys/ose/gcc_lm_ppc.lcf" +LDFLAGS="-Wl,-ecrt0_lm -Wl,-T,${ERL_TOP}/erts/emulator/sys/ose/gcc_${GCCVERSION}_lm_ppc.lcf" # * `LIBS' - Libraries. LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/nof/libgcc.a" @@ -297,7 +297,7 @@ erl_xcomp_ose_LM_SET_CONF="${OSEROOT}/bin/${HOST}/lm_set_conf" erl_xcomp_ose_LM_ELF_SIZE="${OSEROOT}/bin/${HOST}/lm_elf_size" # * `erl_xcomp_ose_LM_LCF` - OSE load module linker configuration file -erl_xcomp_ose_LM_LCF="${ERL_TOP}/erts/emulator/sys/ose/gcc_lm_ppc.lcf" +erl_xcomp_ose_LM_LCF="${ERL_TOP}/erts/emulator/sys/ose/gcc_${GCCVERSION}_lm_ppc.lcf" # * `erl_xcomp_ose_LM_CONF` - OSE load module default configuration file erl_xcomp_ose_LM_CONF="${ERL_TOP}/erts/emulator/sys/ose/default.lmconf" -- cgit v1.2.3 From a6788ea337a2319a2d1a42ee4618553a1c7765bf Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Wed, 30 Oct 2013 17:56:37 +0100 Subject: ose: Fix various build environment issues --- xcomp/erl-xcomp-powerpc-ose5.conf | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index be2944618c..03e3b81e64 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -302,4 +302,11 @@ erl_xcomp_ose_LM_LCF="${ERL_TOP}/erts/emulator/sys/ose/gcc_${GCCVERSION}_lm_ppc. # * `erl_xcomp_ose_LM_CONF` - OSE load module default configuration file erl_xcomp_ose_LM_CONF="${ERL_TOP}/erts/emulator/sys/ose/default.lmconf" +# * `erl_xcomp_ose_CONFD` - OSE confd source file +erl_xcomp_ose_CONFD="${OSEROOT}/src/ose_confd.c" + +# * `erl_xcomp_ose_CRT0_LM` - OSE crt0 lm source file +erl_xcomp_ose_CRT0_LM="${OSEROOT}/src/crt0_lm.c" + + ## ----------------------------------------------------------------------------- -- cgit v1.2.3 From 6552935ee7ef4f267d71cce90b1c848cb9800f32 Mon Sep 17 00:00:00 2001 From: Robert Paal Date: Thu, 28 Nov 2013 13:49:01 +0100 Subject: ose: Add xcomp env variables to OSE xcomp Use these to switch inbetween debug and non-debug emulators and 4.4.3 and 4.6.3 versions of gcc. --- xcomp/erl-xcomp-powerpc-ose5.conf | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index 03e3b81e64..6cf4b2f9fb 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -36,9 +36,30 @@ ## -- Variables needed for an OSE5 build --------------------------------------- OSEROOT="/vobs/ose5/system" HOST="linux" -GCCVERSION="4.6.3" + +GCCVERSION="4.4.3" GCCROOT="${OSEROOT}/gcc_linux_powerpc_${GCCVERSION}" -GCCTARGET="powerpc-ose-eabi" + +OSEDEBUG="yes" + +case ${GCCVERSION} in +4.4.3) + GCCTARGET="powerpc-eabi" + ;; +4.6.3) + GCCTARGET="powerpc-ose-eabi" + ;; +*) + echo "Error: Unknown GCCVERSION: ${GCCVERSION}" + exit 1 +esac + +if [ ${OSEDEBUG} != "yes" ]; +then +OPT_LEVEL="-O2" +else +OPT_LEVEL="" +fi ## -- Variables for `otp_build' Only ------------------------------------------- @@ -80,7 +101,7 @@ erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termca CC="$GCCROOT/bin/$GCCTARGET-gcc" # * `CFLAGS' - C compiler flags. -CFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" +CFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 ${OPT_LEVEL}" # * `STATIC_CFLAGS' - Static C compiler flags. @@ -95,14 +116,14 @@ CFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -W CPP="$GCCROOT/bin/$GCCTARGET-cpp" # * `CPPFLAGS' - C pre-processor flags. -CPPFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 -O2" +CPPFLAGS="-msoft-float -g -fno-strict-aliasing -fno-builtin -fshort-wchar -Wall -Wno-unknown-pragmas -mpowerpc -nostdlib -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/ose_spi -I$OSEROOT/include/gcc -MD -MP -D__OSE__ -DBIG_ENDIAN -DCF_CONF_SIZE=0x800 ${OPT_LEVEL}" # * `CXX' - C++ compiler. CXX="$GCCROOT/bin/$GCCTARGET-g++" # * `CXXFLAGS' - C++ compiler flags. -CXXFLAGS="-msoft-float -g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/gcc -O2" +CXXFLAGS="-msoft-float -g -fno-strict-aliasing -ansi -I$GCCROOT/include/c++/$GCCVERSION -I$OSEROOT/include -I$OSEROOT/include/gcc ${OPT_LEVEL}" # * `LD' - Linker. LD="${GCCROOT}/bin/${GCCTARGET}-ld" -- cgit v1.2.3 From 455f6ea4f04a2289f3ee6b39cdd415513a42f759 Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Wed, 11 Dec 2013 18:06:22 +0100 Subject: ose: Disable non-ose relevant apps --- xcomp/erl-xcomp-powerpc-ose5.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index 6cf4b2f9fb..63c64b1efd 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -85,9 +85,11 @@ erl_xcomp_build=guess # `$ERL_TOP/erts/autoconf/config.sub $erl_xcomp_host'. erl_xcomp_host="powerpc-ose" +disabled_apps="--without-ssl --without-erl_interface --without-os_mon --without-megaco --without-observer --without-wx --without-appmon --without-cosEvent --without-cosEventDomain --without-cosFileTransfer --without-cosNotification --without-cosProperty --without-cosTime --without-cosTransactions --without-debugger --without-dialyzer --without-edoc --without-erl_docgen --without-eunit --without-gs --without-hipe --without-ic --without-orber --without-pman --without-toolbar --without-tv --without-webtool --without-typer" + # * `erl_xcomp_configure_flags' - Extra configure flags to pass to the # `configure' script. -erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termcap --without-javac --disable-dynamic-ssl-lib --disable-shared-zlib --without-ssl --enable-static-nifs=$ERL_TOP/lib/asn1/priv/lib/powerpc-unknown-ose/asn1rt_nif.a" +erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termcap --without-javac --disable-dynamic-ssl-lib --disable-shared-zlib ${disabled_apps} --enable-static-nifs=$ERL_TOP/lib/asn1/priv/lib/powerpc-unknown-ose/asn1rt_nif.a" ## -- Cross Compiler and Other Tools ------------------------------------------- -- cgit v1.2.3 From 6c4ee8337dff6e9b680dbff0796038948d718b5a Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Thu, 13 Feb 2014 17:16:42 +0100 Subject: ose: Fix support for crypto To enable it you have to modify the OSESSL variable in the ose xcomp file. --- xcomp/erl-xcomp-powerpc-ose5.conf | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index 63c64b1efd..4998aff80c 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -41,6 +41,7 @@ GCCVERSION="4.4.3" GCCROOT="${OSEROOT}/gcc_linux_powerpc_${GCCVERSION}" OSEDEBUG="yes" +OSESSL="no" case ${GCCVERSION} in 4.4.3) @@ -61,6 +62,21 @@ else OPT_LEVEL="" fi +if [ ${OSESSL} = "yes" ]; +then +## If your crypto is not in OSEROOT then you have to use --with-ssl to +## point to the correct place. Also CRYPTO_LIB_PATH has to be modified to +## point there as well. +CRYPTO_CONFIG_OPTION="--disable-dynamic-ssl-lib" +CRYPTO_NIF_PATH=",$ERL_TOP/lib/crypto/priv/lib/powerpc-unknown-ose/crypto.a" +CRYPTO_LIB_PATH="${OSEROOT}/lib/powerpc/libsslcrypto.a" +else +CRYPTO_CONFIG_OPTION="--without-ssl" +CRYPTO_NIF_PATH="" +CRYPTO_LIB_PATH="" +fi + + ## -- Variables for `otp_build' Only ------------------------------------------- ## Variables in this section are only used, when configuring Erlang/OTP for @@ -85,11 +101,11 @@ erl_xcomp_build=guess # `$ERL_TOP/erts/autoconf/config.sub $erl_xcomp_host'. erl_xcomp_host="powerpc-ose" -disabled_apps="--without-ssl --without-erl_interface --without-os_mon --without-megaco --without-observer --without-wx --without-appmon --without-cosEvent --without-cosEventDomain --without-cosFileTransfer --without-cosNotification --without-cosProperty --without-cosTime --without-cosTransactions --without-debugger --without-dialyzer --without-edoc --without-erl_docgen --without-eunit --without-gs --without-hipe --without-ic --without-orber --without-pman --without-toolbar --without-tv --without-webtool --without-typer" +disabled_apps="--without-erl_interface --without-os_mon --without-megaco --without-observer --without-wx --without-appmon --without-cosEvent --without-cosEventDomain --without-cosFileTransfer --without-cosNotification --without-cosProperty --without-cosTime --without-cosTransactions --without-debugger --without-dialyzer --without-edoc --without-erl_docgen --without-eunit --without-gs --without-hipe --without-ic --without-orber --without-pman --without-toolbar --without-tv --without-webtool --without-typer" # * `erl_xcomp_configure_flags' - Extra configure flags to pass to the # `configure' script. -erl_xcomp_configure_flags="--disable-kernel-poll --disable-hipe --without-termcap --without-javac --disable-dynamic-ssl-lib --disable-shared-zlib ${disabled_apps} --enable-static-nifs=$ERL_TOP/lib/asn1/priv/lib/powerpc-unknown-ose/asn1rt_nif.a" +erl_xcomp_configure_flags="${CRYPTO_CONFIG_OPTION} --disable-kernel-poll --disable-hipe --without-termcap --without-javac ${disabled_apps} --enable-static-nifs=$ERL_TOP/lib/asn1/priv/lib/powerpc-unknown-ose/asn1rt_nif.a${CRYPTO_NIF_PATH}" ## -- Cross Compiler and Other Tools ------------------------------------------- @@ -134,7 +150,7 @@ LD="${GCCROOT}/bin/${GCCTARGET}-ld" LDFLAGS="-Wl,-ecrt0_lm -Wl,-T,${ERL_TOP}/erts/emulator/sys/ose/gcc_${GCCVERSION}_lm_ppc.lcf" # * `LIBS' - Libraries. -LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/nof/libgcc.a" +LIBS="${OSEROOT}/lib/powerpc/libcrt.a ${OSEROOT}/lib/powerpc/libm.a ${GCCROOT}/lib/gcc/${GCCTARGET}/${GCCVERSION}/nof/libgcc.a ${CRYPTO_LIB_PATH}" ## -- *D*ynamic *E*rlang *D*river Linking -- @@ -194,7 +210,7 @@ erl_xcomp_sysroot="$OSEROOT" # of the cross compilation environment. If not set, this value defaults # to `$erl_xcomp_sysroot', i.e., only set this value if the include system # root path is not the same as the system root path. -erl_xcomp_isysroot="$OSEROOT/include" +#erl_xcomp_isysroot="$OSEROOT" ## -- Optional Feature, and Bug Tests ------------------------------------------ -- cgit v1.2.3 From b0c0057661a634ac410d41d2e6cd8123c95acad5 Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Fri, 21 Feb 2014 18:29:12 +0100 Subject: ose: Use -O2 when building --- xcomp/erl-xcomp-powerpc-ose5.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xcomp/erl-xcomp-powerpc-ose5.conf') diff --git a/xcomp/erl-xcomp-powerpc-ose5.conf b/xcomp/erl-xcomp-powerpc-ose5.conf index 4998aff80c..60b75b36c1 100644 --- a/xcomp/erl-xcomp-powerpc-ose5.conf +++ b/xcomp/erl-xcomp-powerpc-ose5.conf @@ -40,7 +40,7 @@ HOST="linux" GCCVERSION="4.4.3" GCCROOT="${OSEROOT}/gcc_linux_powerpc_${GCCVERSION}" -OSEDEBUG="yes" +OSEDEBUG="no" OSESSL="no" case ${GCCVERSION} in -- cgit v1.2.3