VirtualBox

Changeset 3141 in kBuild for trunk/src


Ignore:
Timestamp:
Mar 14, 2018 9:58:32 PM (7 years ago)
Author:
bird
Message:

kmk: linux merge fixes.

Location:
trunk/src/kmk
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk/alloccache.c

    r3140 r3141  
    3939*******************************************************************************/
    4040#include "makeint.h"
     41#include "filedef.h"
    4142#include "dep.h"
    4243#include "debug.h"
  • trunk/src/kmk/config.h.linux

    r3140 r3141  
    11/* config.h.  Generated from config.h.in by configure.  */
    22/* config.h.in.  Generated from configure.in by autoheader.  */
     3
     4/*
     5 * bird: Move up this bunch so we can include features.h early.
     6 */
     7
     8/* Enable extensions on AIX 3, Interix.  */
     9#ifndef _ALL_SOURCE
     10# define _ALL_SOURCE 1
     11#endif
     12/* Enable GNU extensions on systems that have them.  */
     13#ifndef _GNU_SOURCE
     14# define _GNU_SOURCE 1
     15#endif
     16/* Enable threading extensions on Solaris.  */
     17#ifndef _POSIX_PTHREAD_SEMANTICS
     18# define _POSIX_PTHREAD_SEMANTICS 1
     19#endif
     20/* Enable extensions on HP NonStop.  */
     21#ifndef _TANDEM_SOURCE
     22# define _TANDEM_SOURCE 1
     23#endif
     24/* Enable general extensions on Solaris.  */
     25#ifndef __EXTENSIONS__
     26# define __EXTENSIONS__ 1
     27#endif
     28
     29#include <features.h> /* bird */
     30
    331
    432/* Define to 1 if the `closedir' function returns void instead of `int'. */
     
    397425
    398426
    399 /* Enable extensions on AIX 3, Interix.  */
    400 #ifndef _ALL_SOURCE
    401 # define _ALL_SOURCE 1
    402 #endif
    403 /* Enable GNU extensions on systems that have them.  */
    404 #ifndef _GNU_SOURCE
    405 # define _GNU_SOURCE 1
    406 #endif
    407 /* Enable threading extensions on Solaris.  */
    408 #ifndef _POSIX_PTHREAD_SEMANTICS
    409 # define _POSIX_PTHREAD_SEMANTICS 1
    410 #endif
    411 /* Enable extensions on HP NonStop.  */
    412 #ifndef _TANDEM_SOURCE
    413 # define _TANDEM_SOURCE 1
    414 #endif
    415 /* Enable general extensions on Solaris.  */
    416 #ifndef __EXTENSIONS__
    417 # define __EXTENSIONS__ 1
    418 #endif
    419 
    420 
    421427/* Version number of package */
    422428#define VERSION "3.82"
  • trunk/src/kmk/expreval.c

    r3140 r3141  
    3333#include <glob.h>
    3434
     35#include "filedef.h"
    3536#include "dep.h"
    36 #include "filedef.h"
    3737#include "job.h"
    3838#include "commands.h"
  • trunk/src/kmk/function.c

    r3140 r3141  
    21502150      struct variable *v = lookup_variable (argv[i], strlen (argv[i]));
    21512151# ifdef CONFIG_WITH_RDONLY_VARIABLE_VALUE
    2152       if (v && !v->origin != o_automatic && !v->rdonly_val)
     2152      if (v && v->origin != o_automatic && !v->rdonly_val)
    21532153# else
    2154       if (v && !v->origin != o_automatic)
     2154      if (v && v->origin != o_automatic)
    21552155# endif
    21562156        {
  • trunk/src/kmk/incdep.c

    r3140 r3141  
    551551      /* bail out */
    552552
    553       error (f, "%s: read: %s", cur->name, strerror (errno));
     553      OSS (error, f, "%s: read: %s", cur->name, strerror (errno));
    554554      incdep_xfree (cur, cur->file_base);
    555555    }
    556556  else
    557     error (f, "%s: fstat: %s", cur->name, strerror (errno));
     557    OSS (error, f, "%s: fstat: %s", cur->name, strerror (errno));
    558558
    559559  close (fd);
  • trunk/src/kmk/job.c

    r3140 r3141  
    10851085  if (!jobserver_tokens)
    10861086    ONS (fatal, NILF, "INTERNAL: Freeing child %p (%s) but no tokens left!\n",
    1087          child, child->file->name);
     1087         (void *)child, child->file->name);
    10881088
    10891089  /* If we're using the jobserver and this child is not the only outstanding
     
    11741174#else
    11751175  char **argv;
    1176 # if !defined(__MSDOS__) && !defined(_AMIGA) && !defined(WINDOWS32) && !defined(VMS)
    1177   char ** volatile volatile_argv;
    1178   int volatile volatile_flags;
    1179 # endif
    11801176#endif
    11811177
     
    28002796  static const char *sh_chars_sh =  "#;\"*?[]&|<>(){}$`^~!";
    28012797# endif  /* HAVE_DOS_PATHS */
    2802   char*  sh_chars = sh_chars_sh;                                                /* kmk: +_sh */
    2803   char** sh_cmds = sh_cmds_sh;                                                  /* kmk: +_sh */
     2798  char const *  sh_chars = sh_chars_sh;                                                /* kmk: +_sh +const */
     2799  char const * const * sh_cmds = sh_cmds_sh;                                           /* kmk: +_sh +const*2 */
    28042800#endif
    28052801#ifdef KMK
    2806   static char sh_chars_kash[] = "#;*?[]&|<>(){}$`^~!";                          /* note: no \" - good idea? */
    2807   static char *sh_cmds_kash[] = {
     2802  static const char sh_chars_kash[] = "#;*?[]&|<>(){}$`^~!";                          /* note: no \" - good idea? */
     2803  static const char * const sh_cmds_kash[] = {
    28082804      ".", ":", "break", "case", "cd", "continue", "echo", "eval", "exec", "exit",
    28092805      "export", "for", "if", "login", "logout", "read", "readonly", "set",
  • trunk/src/kmk/kbuild-object.c

    r3140 r3141  
    465465        else
    466466            error(pFileLoc, 20, _("The '$([%.*s...' accessor can only be used in the context of a kBuild object"),
    467                   MAX(cchLeft, 20), pchLeft);
     467                  (int)MIN(cchLeft, 20), pchLeft);
    468468    }
    469469
  • trunk/src/kmk/kmkbuiltin/append.c

    r3140 r3141  
    8383    int fVariables = 0;
    8484    int fCommands = 0;
     85#ifndef kmk_builtin_append
    8586    int fLookForInserts = 0;
     87#endif
    8688
    8789    g_progname = argv[0];
  • trunk/src/kmk/kmkbuiltin/kDepObj.c

    r3064 r3141  
    601601        if (off + sizeof(*pHdr) >= cbSyms)
    602602        {
    603             fprintf(stderr, "%s: CV symbol table entry at %08" KX32_PRI " is too long; cbSyms=%#" KSIZE_PRI "\n",
     603            fprintf(stderr, "%s: CV symbol table entry at %08" KX32_PRI " is too long; cbSyms=%#" KX32_PRI "\n",
    604604                    argv0, off, cbSyms);
    605605            return 1; /* FIXME */
     
    609609        if (off + cbData + sizeof(*pHdr) > cbSyms)
    610610        {
    611             fprintf(stderr, "%s: CV symbol table entry at %08" KX32_PRI " is too long; cbData=%#" KX32_PRI " cbSyms=%#" KSIZE_PRI "\n",
     611            fprintf(stderr, "%s: CV symbol table entry at %08" KX32_PRI " is too long; cbData=%#" KX32_PRI " cbSyms=%#" KX32_PRI "\n",
    612612                    argv0, off, cbData, cbSyms);
    613613            return 1; /* FIXME */
  • trunk/src/kmk/main.c

    r3140 r3141  
    32333233         _("warning:  Clock skew detected.  Your build may be incomplete."));
    32343234
    3235     MAKE_STATS_2(if (uStartTick) printf("main ticks elapsed: %ull\n", (unsigned long long)(CURRENT_CLOCK_TICK() - uStartTick)) );
     3235    MAKE_STATS_2(if (uStartTick) printf("main ticks elapsed: %llu\n", (unsigned long long)(CURRENT_CLOCK_TICK() - uStartTick)) );
    32363236    /* Exit.  */
    32373237    die (makefile_status);
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette