1. 23 Nov, 2017 5 commits
    • Masahiro Yamada's avatar
      kbuild: rpm: prompt to use "rpm-pkg" if "rpm" target is used · ebaad7d3
      Masahiro Yamada authored
      The "rpm" has been kept for backward compatibility since pre-git era.
      I am planning to remove it after the Linux 4.18 release.  Annouce the
      end of the support, prompting to use "rpm-pkg" instead.
      
      If you use "rpm", it will work like "rpm-pkg", but warning messages
      will be displayed as follows:
      
        WARNING: "rpm" target will be removed after Linux 4.18
                 Please use "rpm-pkg" instead.
      Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      ebaad7d3
    • Masahiro Yamada's avatar
      kbuild: pkg: use --transform option to prefix paths in tar · 2dbc644a
      Masahiro Yamada authored
      For rpm-pkg and deb-pkg, a source tar file is created.  All paths in
      the archive must be prefixed with the base name of the tar so that
      everything is contained in the directory when you extract it.
      
      Currently, scripts/package/Makefile uses a symlink for that, and
      removes it after the tar is created.
      
      If you terminate the build during the tar creation, the symlink is
      left over.  Then, at the next package build, you will see a warning
      like follows:
      
        ln: '.' and 'kernel-4.14.0+/.' are the same file
      
      It is possible to fix it by adding -n (--no-dereference) option to
      the "ln" command, but a cleaner way is to use --transform option
      of "tar" command.  This option is GNU extension, but it should not
      hurt to use it in the Linux build system.
      
      The 'S' flag is needed to exclude symlinks from the path fixup.
      Without it, symlinks in the kernel are broken.
      Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      2dbc644a
    • Masahiro Yamada's avatar
      coccinelle: fix parallel build with CHECK=scripts/coccicheck · d7059ca0
      Masahiro Yamada authored
      The command "make -j8 C=1 CHECK=scripts/coccicheck" produces
      lots of "coccicheck failed" error messages.
      
      Julia Lawall explained the Coccinelle behavior as follows:
      "The problem on the Coccinelle side is that it uses a subdirectory
      with the name of the semantic patch to store standard output and
      standard error for the different threads.  I didn't want to use a
      name with the pid, so that one could easily find this information
      while Coccinelle is running.  Normally the subdirectory is cleaned
      up when Coccinelle completes, so there is only one of them at a time.
      Maybe it is best to just add the pid.  There is the risk that these
      subdirectories will accumulate if Coccinelle crashes in a way such
      that they don't get cleaned up, but Coccinelle could print a warning
      if it detects this case, rather than failing."
      
      When scripts/coccicheck is used as CHECK tool and -j option is given
      to Make, the whole of build process runs in parallel.  So, multiple
      processes try to get access to the same subdirectory.
      
      I notice spatch creates the subdirectory only when it runs in parallel
      (i.e. --jobs <N> is given and <N> is greater than 1).
      
      Setting NPROC=1 is a reasonable solution; spatch does not create the
      subdirectory.  Besides, ONLINE=1 mode takes a single file input for
      each spatch invocation, so there is no reason to parallelize it in
      the first place.
      Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      Acked-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
      d7059ca0
    • Heinrich Schuchardt's avatar
      kconfig/symbol.c: use correct pointer type argument for sizeof · 88127dae
      Heinrich Schuchardt authored
      sym_arr is of type struct symbol **.
      So in malloc we need sizeof(struct symbol *).
      
      The problem was indicated by coccinelle.
      Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
      Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      88127dae
    • Chris Fries's avatar
      kbuild: Set KBUILD_CFLAGS before incl. arch Makefile · ae6b289a
      Chris Fries authored
      Set the clang KBUILD_CFLAGS up before including arch/ Makefiles,
      so that ld-options (etc.) can work correctly.
      
      This fixes errors with clang such as ld-options trying to CC
      against your host architecture, but LD trying to link against
      your target architecture.
      Signed-off-by: default avatarChris Fries <cfries@google.com>
      Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      Reviewed-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Tested-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
      ae6b289a
  2. 18 Nov, 2017 35 commits