On 22/04/2015 2:33 am, Hesham ALMatary wrote: > This patch adds support for building Epiphany tools.
Great to see this support being adding. > Currently some tools > are fetched from my repositories (until my pull requests get merged), and > other tools are fetched from Adapteva repositories. In the future, the > tools should be fetched from GNU upstreams when Adapteva folks push > their latest changes there. Have you posted your changes to Adapteva ? Would they accept them ? > --- > rtems/config/4.11/rtems-epiphany.bset | 43 > ++++++++++++++++++++++++++++++++++ > source-builder/config/binutils-2-1.cfg | 4 ++-- > source-builder/config/gcc-common-1.cfg | 5 ++-- > source-builder/config/gdb-7-1.cfg | 4 ++-- > 4 files changed, 50 insertions(+), 6 deletions(-) > create mode 100644 rtems/config/4.11/rtems-epiphany.bset > > diff --git a/rtems/config/4.11/rtems-epiphany.bset > b/rtems/config/4.11/rtems-epiphany.bset > new file mode 100644 > index 0000000..429031f > --- /dev/null > +++ b/rtems/config/4.11/rtems-epiphany.bset > @@ -0,0 +1,43 @@ > +# > +# Tools Set for RTEMS Epiphany 4.11 Stable > +# > + > +%define release 1 > + > +%define rtems_arch epiphany > + > +# > +# Get GNU tools from external repositories. > +# > +%define binutils_external 1 > +%define gcc_external 1 > +%define gdb_external 1 > + > +# > +# Expanded names of the GNU tools > +# > +%define binutils_expand_name > epiphany-binutils-gdb-epiphany-binutils-2.23-software-cache > +%define gcc_expand_name epiphany-gcc-epiphany-gcc-4.9 > +%define gdb_expand_name epiphany-binutils-gdb-epiphany-gdb-7.8 > + Is this really 'binutils_source_name' or 'binutils_source_top' ? > +# > +# Fetch GNU tools from external repos (temporarly). > +# > +%source set binutils > https://github.com/adapteva/epiphany-binutils-gdb/archive/epiphany-binutils-2.23-software-cache.zip Is the expanded tree in the ZIP file not the same as the file name ? > +%source set gcc > https://github.com/heshamelmatary/epiphany-gcc/archive/epiphany-gcc-4.9.zip > +%source set gdb > https://github.com/heshamelmatary/epiphany-binutils-gdb/archive/epiphany-gdb-7.8.zip > + > +# > +# The RTEMS 4.11 base defines. > +# > +%include rtems-4.11-base.bset > + > +# > +# Tools configuration. > +# > +4.11/rtems-autotools > +devel/expat-2.1.0-1 > +tools/rtems-binutils-2.23.1-1 > +tools/rtems-gcc-4.9.1-newlib-git-1 > +tools/rtems-gdb-7.8.1-1 > +tools/rtems-tools-4.11-1 > diff --git a/source-builder/config/binutils-2-1.cfg > b/source-builder/config/binutils-2-1.cfg > index c74a2c7..d37674d 100644 > --- a/source-builder/config/binutils-2-1.cfg > +++ b/source-builder/config/binutils-2-1.cfg > @@ -37,8 +37,8 @@ BuildRoot: %{_tmppath}/%{name}-root-%(%{__id_u} -n) > %prep > build_top=$(pwd) > > - source_dir_binutils="binutils-%{binutils_version}" > - %source setup binutils -q -n binutils-%{binutils_version} > + > source_dir_binutils=%{?binutils_external:%{binutils_expand_name}}%{!?binutils_external:"binutils-%{binutils_version}"} > + %source setup binutils -q -n > %{?binutils_external:%{binutils_expand_name}}%{!?binutils_external:binutils-%{binutils_version}} Can this be simplified with something like: %binutils_sources=%{?binutils_source_name:%{binutils_source_name}}%{!?binutils_source_name:"binutils-%{binutils_version}"} source_dir_binutils=%{binutils_sources} %source setup binutils -q -n %{binutils_sources} The same would go for the other tools. Chris > %patch setup binutils -p1 > > cd ${build_top} > diff --git a/source-builder/config/gcc-common-1.cfg > b/source-builder/config/gcc-common-1.cfg > index dd0cf4c..b6fa4bd 100644 > --- a/source-builder/config/gcc-common-1.cfg > +++ b/source-builder/config/gcc-common-1.cfg > @@ -41,8 +41,9 @@ BuildRoot: %{_tmppath}/%{name}-root-%(%{__id_u} -n) > build_top=$(pwd) > > # gcc and optional the g++ core if separate packages > - source_dir_gcc="gcc-%{gcc_version}" > - %source setup gcc -q -n gcc-%{gcc_version} > + > source_dir_gcc=%{?gcc_external:%{gcc_expand_name}}%{!?gcc_external:"gcc-%{gcc_version}"} > + %source setup gcc -q -n > %{?gcc_external:%{gcc_expand_name}}%{!?gcc_external:gcc-%{gcc_version}} > + > %patch setup gcc -p1 > cd ${build_top} > > diff --git a/source-builder/config/gdb-7-1.cfg > b/source-builder/config/gdb-7-1.cfg > index 6e84375..792db50 100644 > --- a/source-builder/config/gdb-7-1.cfg > +++ b/source-builder/config/gdb-7-1.cfg > @@ -66,8 +66,8 @@ BuildRoot: %{_tmppath}/%{name}-root-%(%{__id_u} -n) > %prep > build_top=$(pwd) > > - source_dir_gdb="gdb-%{gdb_version}" > - %source setup gdb -q -n gdb-%{gdb_version} > + > source_dir_gdb=%{?gdb_external:%{gdb_expand_name}}%{!?gdb_external:"gdb-%{gdb_version}"} > + %source setup gdb -q -n > %{?gdb_external:%{gdb_expand_name}}%{!?gdb_external:gdb-%{gdb_version}} > %patch setup gdb -p1 > > cd ${build_top} > _______________________________________________ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel