carl9170: Update based on commit cd76b7b483731dc5cb467c28cc70478179fbffd5 dated Feb...
authorJason Self <j@jxself.org>
Sat, 17 Feb 2018 02:32:24 +0000 (18:32 -0800)
committerJason Self <j@jxself.org>
Sat, 17 Feb 2018 02:32:24 +0000 (18:32 -0800)
carl9170fw/carlfw/CMakeLists.txt
carl9170fw/config/expr.c
carl9170fw/config/list.h
carl9170fw/config/lkc_proto.h
carl9170fw/config/symbol.c
carl9170fw/extra/GCCVersion.cmake [deleted file]
carl9170fw/toolchain/Makefile
carl9170fw/toolchain/SHA256SUMS
carl9170fw/tools/CMakeLists.txt
carl9170fw/tools/src/CMakeLists.txt

index 02c80bf138badd45cb9611e1eddb5b4f5a806869..8647a759d3e17a89d5883420a75c1c3b4ace1c30 100644 (file)
@@ -7,7 +7,7 @@ include("../config.cmake")
 
 set(CARL9170_FW_ELF carl9170.elf)
 set(CARLFW_CFLAGS_WARNING "-W -Wall -Wextra -Wunreachable-code -Winline -Wlogical-op -Wno-packed-bitfield-compat -Winit-self -Wshadow -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wformat=2 -Wcast-align -Wmissing-format-attribute -Wmissing-prototypes -Wtype-limits -Wmissing-declarations -Wmissing-noreturn -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wpointer-arith -Wvolatile-register-var -Waddress -Wbad-function-cast -Wunsafe-loop-optimizations")
-set(CARLFW_CFLAGS_EXTRA "-mbitops -std=gnu99 -ffunction-sections -Wframe-larger-than=128 -Werror")
+set(CARLFW_CFLAGS_EXTRA "-mbitops -ffunction-sections -Wframe-larger-than=128 -Werror")
 set(CARLFW_CFLAGS_DEF "-D__CARL9170FW__")
 if (CONFIG_CARL9170FW_AGGRESSIVE_CFLAGS)
        set(CARLFW_CFLAGS_AGGRESSIVE "-fomit-frame-pointer -fsee -frename-registers -ftree-vectorize -flto -fstrict-volatile-bitfields -fmodulo-sched -fwhole-program")
index cbf4996dd9c1045ecc7ffa66a9ec79edd99b1038..8cee597d33a594d3d7380390aa2b697218034578 100644 (file)
@@ -893,7 +893,10 @@ static enum string_value_kind expr_parse_string(const char *str,
        switch (type) {
        case S_BOOLEAN:
        case S_TRISTATE:
-               return k_string;
+               val->s = !strcmp(str, "n") ? 0 :
+                        !strcmp(str, "m") ? 1 :
+                        !strcmp(str, "y") ? 2 : -1;
+               return k_signed;
        case S_INT:
                val->s = strtoll(str, &tail, 10);
                kind = k_signed;
index 2cf23f002d3f48f6b51ac9898fde7681ea39cf53..45cb237ab7ef7a9f17779647220da6a30afd06fc 100644 (file)
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 #ifndef LIST_H
 #define LIST_H
 
index d5398718ec2ae3337dac3cb3d19654c8508c3007..5d86e2dfae59da1cc187dbd579b74757075f2280 100644 (file)
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 #include <stdarg.h>
 
 /* confdata.c */
index 20136ffefb23b814fa8b300b70a07b821b3ec71f..3c8bd9bb4267a874cd1fa112d4a21b569bd56296 100644 (file)
@@ -1061,7 +1061,7 @@ struct symbol **sym_re_search(const char *pattern)
        }
        if (sym_match_arr) {
                qsort(sym_match_arr, cnt, sizeof(struct sym_match), sym_rel_comp);
-               sym_arr = malloc((cnt+1) * sizeof(struct symbol));
+               sym_arr = malloc((cnt+1) * sizeof(struct symbol *));
                if (!sym_arr)
                        goto sym_re_search_free;
                for (i = 0; i < cnt; i++)
diff --git a/carl9170fw/extra/GCCVersion.cmake b/carl9170fw/extra/GCCVersion.cmake
deleted file mode 100644 (file)
index bb5fef3..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-#=============================================================================
-# Copyright 2006-2009 Kitware, Inc.
-# Copyright 2006-2008 Andreas Schneider <mail@cynapses.org>
-# Copyright 2007      Wengo
-# Copyright 2007      Mike Jackson
-# Copyright 2008      Andreas Pakulat <apaku@gmx.de>
-# Copyright 2008-2009 Philip Lowman <philip@yhbt.com>
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-#
-# * Redistributions of source code must retain the above copyright
-#   notice, this list of conditions and the following disclaimer.
-#
-# * Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in the
-#   documentation and/or other materials provided with the distribution.
-#
-# * Neither the names of Kitware, Inc., the Insight Software Consortium,
-#   nor the names of their contributors may be used to endorse or promote
-#   products derived from this software without specific prior written
-#   permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-# HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-#-------------------------------------------------------------------------------
-
-#
-# Runs compiler with "-dumpversion" and parses major/minor
-# version with a regex.
-#
-FUNCTION(_COMPILER_DUMPVERSION _OUTPUT_VERSION)
-
-  EXEC_PROGRAM(${CMAKE_C_COMPILER}
-    ARGS ${CMAKE_C_COMPILER_ARG1} -dumpversion
-    OUTPUT_VARIABLE _COMPILER_VERSION
-  )
-  STRING(REGEX REPLACE "([0-9])\\.([0-9])(\\.[0-9])?" "\\1\\2"
-    _COMPILER_VERSION ${_COMPILER_VERSION})
-
-  SET(${_OUTPUT_VERSION} ${_COMPILER_VERSION} PARENT_SCOPE)
-ENDFUNCTION()
-
-#
-# End functions/macros
-#
-#-------------------------------------------------------------------------------
-
-
index 0b10de39abd58ced00c5723f281affe98984c2ee..3ee93a9f5dae313cce162021b522abfb8792bc8f 100644 (file)
@@ -1,16 +1,16 @@
-BINUTILS_VER=2.29
+BINUTILS_VER=2.30
 BINUTILS_TAR=binutils-$(BINUTILS_VER).tar.xz
 BINUTILS_URL="http://ftpmirror.gnu.org/gnu/binutils/$(BINUTILS_TAR)"
 
-NEWLIB_VER=2.5.0
+NEWLIB_VER=3.0.0
 NEWLIB_TAR=newlib-$(NEWLIB_VER).tar.gz
 NEWLIB_URL="ftp://sourceware.org/pub/newlib/$(NEWLIB_TAR)"
 
-GCC_VER=7.2.0
+GCC_VER=7.3.0
 GCC_TAR=gcc-$(GCC_VER).tar.xz
 GCC_URL="http://ftpmirror.gnu.org/gnu/gcc/gcc-$(GCC_VER)/$(GCC_TAR)"
 
-MPFR_VER=3.1.6
+MPFR_VER=4.0.1
 MPFR_TAR=mpfr-$(MPFR_VER).tar.xz
 MPFR_URL="http://ftpmirror.gnu.org/gnu/mpfr/$(MPFR_TAR)"
 
@@ -18,7 +18,7 @@ GMP_VER=6.1.2
 GMP_TAR=gmp-$(GMP_VER).tar.xz
 GMP_URL="http://ftpmirror.gnu.org/gnu/gmp/$(GMP_TAR)"
 
-MPC_VER=1.0.3
+MPC_VER=1.1.0
 MPC_TAR=mpc-$(MPC_VER).tar.gz
 MPC_URL="http://ftpmirror.gnu.org/gnu/mpc/$(MPC_TAR)"
 
index 788588de051fa52c3d9052fcdf21d11dd930e8cc..99505e4e57274677a4b2c28be2b454b360d6bd35 100644 (file)
@@ -4,4 +4,11 @@
 87b565e89a9a684fe4ebeeddb8399dce2599f9c9049854ca8c0dfbdea0e21912  src/gmp-6.1.2.tar.xz
 617decc6ea09889fb08ede330917a00b16809b8db88c29c31bfbb49cbf88ecc3  src/mpc-1.0.3.tar.gz
 7a62ac1a04408614fccdc506e4844b10cf0ad2c2b1677097f8f35d3a1344a950  src/mpfr-3.1.6.tar.xz
+6985c538143c1208dcb1ac42cedad6ff52e267b47e5f970183a3e75125b43c2e  src/mpc-1.1.0.tar.gz
+fbe2cd1418b321f5c899ce4f0f0f4e73f5ecc7d02145b0e1fd096f5c3afb8a1d  src/mpfr-4.0.0.tar.xz
+c8566335ee74e5fcaeb8595b4ebd0400c4b043d6acb3263ecb1314f8f5501332  src/newlib-3.0.0.tar.gz
+832ca6ae04636adbb430e865a1451adf6979ab44ca1c8374f61fba65645ce15c  src/gcc-7.3.0.tar.xz
+e7010a46969f9d3e53b650a518663f98a5dde3c3ae21b7d71e5e6803bc36b577  src/binutils-2.29.1.tar.xz
+67874a60826303ee2fb6affc6dc0ddd3e749e9bfcb4c8655e3953d0458a6e16e  src/mpfr-4.0.1.tar.xz
+6e46b8aeae2f727a36f0bd9505e405768a72218f1796f0d09757d45209871ae6  src/binutils-2.30.tar.xz
 
index 1c21fefd3629736360ee472e1958955ff748ae23..13262d695de8597a11e49747474d32453eeaa510 100644 (file)
@@ -8,13 +8,8 @@ endif (CONFIG_CARL9170FW_MAKE_RELEASE)
 
 set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/extra)
 
-include(GCCVersion)
 include("../config.cmake")
 
-if (("${CMAKE_C_COMPILER_VERSION}" VERSION_GREATER 4.4) OR
-    ("${CMAKE_C_COMPILER_VERSION}" VERSION_EQUAL 4.4))
-
-       include_directories (../include/linux ../include/shared ../include lib include)
-       add_subdirectory(lib)
-       add_subdirectory(src)
-endif ()
+include_directories (../include/linux ../include/shared ../include lib include)
+add_subdirectory(lib)
+add_subdirectory(src)
index d141521e9652ea231984c12637f34d1fbf43acdf..637a788575ab453c056d435035886d4631a9968c 100644 (file)
@@ -8,6 +8,6 @@ set(tools fwinfo miniboot checksum)
 
 foreach(tool ${tools})
        add_executable( ${tool} ${tool}.c )
-       add_definitions("-std=gnu99 -Wall -Wextra -Wshadow")
+       add_definitions("-Wall -Wextra -Wshadow")
        target_link_libraries( ${tool} carlfw )
 endforeach()