Commit Graph

550 Commits

Author SHA1 Message Date
Gregory Nutt 8ed0d21b73 tools/tesbuild.sh: Correct help test. 2019-03-28 12:12:15 -06:00
Gregory Nutt 04fe412414 tools/nxstyle.c: Costmetic alignment and corrections to comments. 2019-03-13 07:05:31 -06:00
Gregory Nutt 4802eb65c5 tools/nxstyle.c: Fix a bacward test in the previous commit. 2019-03-12 14:48:43 -06:00
Gregory Nutt ba859ad302 tools/nxstyle.c: Don't complain about certain lowercase characters in otherwise uppercase pre-processor identifers: IPv6, IPv4, ICMPv6, IGMPv2, p as a decimal point, d signifying a divisor. It was a bad idea to let the door open a crack for there. While they improve readability, the inconsistently also causes other problems. 2019-03-12 14:22:52 -06:00
Gregory Nutt f6b00e1966 tools/nxstyle.c: Fix logic error that prevent detecion of '/' and '/=' as operators. net/: Minor updates resulting from testing tools/nxstyle. 2019-03-11 12:48:39 -06:00
Gregory Nutt aa4f7c9ba7 graphics/nxmu/nxmu_start.c: Extend nxmu_start so that receives a display number as an argument. This makes it possible to have multiple instances of the NX server running on boards that support multiple displays. Also includes updates to boardctl() to accept display number paramters. 2019-03-10 13:50:05 -06:00
Gregory Nutt f6b9fe5b14 tools/nxstyle.c: Add logic to detect a blank line following a left brace or a blank line preceding a right brace. 2019-03-10 09:53:33 -06:00
Gregory Nutt cf0f0e69f8 tools/nxstyle.c: Was confusing hex constants with strings staring with 'x'. Added logic to complain about hex constants containing upper case characters. 2019-03-09 09:21:12 -06:00
Gregory Nutt c8004c7e00 tools/nxstyle.c: Add capability to detect CamelCase identifiers. 2019-03-05 13:08:57 -06:00
Alan Carvalho de Assis 7133f89cc2 tools/Makefile.unix, .win, and all defconfig files: Modify tools/Makefiles to add warning on defconfig files 2019-03-03 08:31:03 -06:00
Gregory Nutt f914ec6e2b tools/nxstyle.c: Fix logic that detects if an operator is correctly delimited with spaces. sched/: Various changes because sched/ C files were used as Guinea Pigs to test nstyle.c. 2019-03-01 10:50:02 -06:00
David Sidrane 6d0d712b9c tools/.gitignore: Ignore rmcr binary 2019-02-27 14:22:32 -06:00
Gregory Nutt c13afc29e6 Trivial, Costmetic, ... 2019-02-27 14:02:53 -06:00
Gregory Nutt dc8c814ca3 Squashed commit of the following:
Fixed coding standard error in several files.  Use of while( is incorrect; a space is required between while and (.  Also ran tools/nxstyle and fix thoses complaints as well in most files.

    Changes to comply with coding standard.  Mostly focused on files with missing space after keyword in if(, switch(, and for(.  Offending files also got changes to comply with tools nxstyle.  If there were logs of nxstyle complaints, the file also got a taste of tools/indent.sh.  Still need to fix occurrences of while( with missing space.  There are a lot of them.
2019-02-27 08:41:08 -06:00
Gregory Nutt d9d2042f75 Revert "tools/check-hash.sh: Add a tool check hash on downloaded packages."
This tool was supposed to go to apps/tools, not nuttx/tools.

This reverts commit 41245f421e.
2019-02-18 07:20:41 -06:00
Gregory Nutt bc5908d9fd tools/nxstyle.c: Beef up logic that detects multiple variable definitions per line. 2019-02-17 10:57:28 -06:00
Michał Łyszczek 41245f421e tools/check-hash.sh: Add a tool check hash on downloaded packages. 2019-02-15 07:08:44 -06:00
Gregory Nutt b5e6af60ac tools/nxstyle.c: Add check for multiple definitions of local variables on a line. 2019-02-14 18:33:23 -06:00
Gregory Nutt efe65749ce Fix condition logic: The setup seems to support a network without sockets. That is not the case.
Squashed commit of the following:

    sched/sched/sched_getsockets.c:  Fix an error in conditional compilation.
    fs/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    Documentation/:  Remove all references to CONFIG_NSOCKET_DESCRIPTORS == 0
    include/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    libs/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    net/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    sched/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    syscall/:  Remove all conditional logic based on CONFIG_NSOCKET_DESCRIPTORS == 0
    tools/:  Fixups for CONFIG_NSOCKET_DESCRIPTORS no longer used to disable sockets.
2019-02-11 15:47:25 -06:00
Gregory Nutt a64869aa67 CONFIG_NFILE_DESCRIPTORS=0 can no longer be used to disable the file system. NuttX with no file system does not make sense.
Squashed commit of the following:

    configs/:  The few configurations that formerly set CONFIG_NFILE_DESCRIPTORS=0 should not default, rather they should set the number of descriptors to 3.
    fs/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    tools/:  Tools updates for changes to usage of CONFIG_NFILE_DESCRIPTORS.
    syscall/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    libs/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    include/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    drivers/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    Documentation/:  Remove all references to CONFIG_NFILE_DESCRIPTORS == 0
    binfmt/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    arch/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    net/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    sched/:  Remove all conditional logic based on CONFIG_NFILE_DESCRIPTORS == 0
    sched/Kconfig:  CONFIG_NFILE_DESCRIPTORS may no longer to set to a value less than 3
    configs/:  Remove all settings for CONFIG_NFILE_DESCRIPTORS < 3
2019-02-11 12:09:26 -06:00
Gregory Nutt 3ba777bb27 include/: Correct naming of standard header file. Should be dlfcn.h, not dllfcn.h. I am surprised no one ever noticed before now. 2019-02-09 14:09:28 -06:00
Gregory Nutt 411057b59c Update README files. 2019-02-09 07:19:10 -06:00
Gregory Nutt d280b0651f tools/nxstyle.c: Make sure that all files begin with a comment on line 1 (which should be the file header). 2019-02-08 08:30:06 -06:00
Gregory Nutt 0191117747 tools/nxstyle.c: Can not detect if the C comment closing is not on a separate line. 2019-02-08 07:59:22 -06:00
Gregory Nutt 713b3e3760 tools/rmcr.c: Add a tools to remove carriage returns and dangline whitespace at the end of lines. 2019-02-07 12:11:40 -06:00
Gregory Nutt a1304f494a tools/lowhex.c: Fix an initialization problem that was causing some odd behavior at the beginning of lines. 2019-02-07 11:28:04 -06:00
David Sidrane 754b485ce9 tools/.gitignore: Ignore new tool binaries. 2019-01-24 06:58:26 -06:00
Gregory Nutt a8da0e977a Addition of trivial comment 2019-01-22 13:04:02 -06:00
Gregory Nutt b4373e21e7 tools/convert-comments.c: Fix an error in handling of a blank C++ comment before a comment block. For example, this testfile:
1
2  //
3  // Multi-line comment
4  // The second line
5

Was generating this output:

1
2
3   * Multi-line comment
4   * The second line
5   */
6

Now correctly generates:

1
2  /* Multi-line comment
3   * The second line
4   */
5
2019-01-22 10:45:06 -06:00
Alan Carvalho de Assis 7127df3e38 drivers/power/mcp73871.c: Fix MCP73871 driver to register correctly as a battery charger. The first element of a 'struct battery_charger_dev_s' should be a pointer to operations structure. 2019-01-05 11:49:18 -06:00
Gregory Nutt d1979ace8f tools/mkconfig.c: Add definitions to distinguish between tristate 'y' and 'm' options. 2019-01-05 08:44:17 -06:00
David Sidrane 39ac045cff tools/gencromfs.c: Fix build on macOS 2018-12-26 14:35:20 -06:00
David Sidrane 7fef81ea94 gencromfs.c:1171:3: warning: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Wunused-result] 2018-12-13 12:40:40 -06:00
Gregory Nutt 4a501de6b1 tools/detab.c: Fix a strange (but functional) conditional test noted by Alan Carvalho de Assis. 2018-12-03 13:25:14 -06:00
Gregory Nutt fc744fb9b1 tools/: Add detab.c which will convert all tabs in a file to spaces. Add lowhex.c that will convert hexadecimal constants in a file to use lower case representation. 2018-12-03 08:45:05 -06:00
Gregory Nutt e0608386f3 tools/convert-comments.c: Add a tool to convert C++-style comments to C89 C-style comments. 2018-12-01 19:15:54 -06:00
Matous Pokorny 7a4fb66192 Merged in ehiker/nuttx/fix_readme_typo (pull request #764)
Fix readme typo

* readme.txt: Fix typo

* tools/readme.txt: Fix typo

    There is no file called cmdconfig.

Approved-by: GregoryN <gnutt@nuttx.org>
2018-11-21 14:06:51 +00:00
Gregory Nutt f9fc2131b0 tools/nxstyle.c: Add -h for help. 2018-11-19 08:05:55 -06:00
Gregory Nutt 655904f342 tools/nxstyle.c: Add logic to detect long lines. 2018-11-19 07:50:59 -06:00
Gregory Nutt 0d13cb5055 Remove deletion of Eclipse project files from make distclean target per request of David Sidrane. 2018-11-09 10:39:18 -06:00
Xiang Xiao acb83cfc61 tools/csvparser.h: Extend MAX_PARMSIZE to 256. Fixes this issue: 70: Parameter too long: ... 2018-11-08 07:36:02 -06:00
nchao 6509a0c0ca binfmt/ and libs/libc: Make exepath_*() more common:
1. Move exepath_*() related code to libc/misc
  1. Rename exepath_ to envpath_
  2. Rename BINFMT_EXEPATH to LIB_ENVPATH

libs/libc/modlib:  Add pre module library symbol table support
2018-11-08 07:27:14 -06:00
Gregory Nutt 12a500fcb6 tools/Makefile.win/unix: staging directory (and its libraries) should be removed on 'make clean' (issue noted by Dave Marples). Also updates TODO list 2018-11-06 07:37:02 -06:00
Anatol Ivanov e748bb8cd3 tools/Config.mk and tools/Makefile.win: Force use 'cmd' for shell with windows native build 2018-11-06 06:34:00 -06:00
Anatol Ivanov 1dad62d3b7 Squashed commit of the following:
tools/configure.c: Add missing '\n' in printf statement

    tools/configure.c: Add missed -g option to getopt() string

    tools/configure.c and tools/configure.sh:  Fix Windows native pre-build kconfig-conf incompability.  Looks like prebuilt Windows native kconfig-conf interprets "..\apps" as "..apps" (possibly '\a' as escape-sequence) so expand winnative path to double-backslashed variant "..\\apps".

    tools/mkdeps.c:  Fix '\0' missing in MinGW.  Implicit bug. There are 2 cases.

    1. Under Linux.  The code works as planned: '\n' is always replaced with '\0' due to sprintf fills n-1 bytes and reaches buffer length limit.

    2. Under Windows/MinGW. There is memory corruption.  Seems like it`s a bug inside MinGW/snprintf.  Snprintf fills consecutively "oldbase",' ',"str",'\n', but does not inserts trailing '\0' instead of '\n'.  And when next append() occurs, strlen() returns garbage-appended "oldbase".

    So the fix just removes '\n' and reserves space for '\0'.

    tools/link.bat: Fix .fakelink creation

    configs/Makefile and tools/Config.mk:  Move single file copy to the new function COPYFILE.  This fixes the Windows native build case when there is no cp or cp does not recognize Windows paths.
2018-11-05 16:35:28 -06:00
Gregory Nutt b51e77829e tools/nxstyle.c: Remove some logic added in previous change. Causes too many false alarms. 2018-10-31 12:42:18 -06:00
Gregory Nutt 6ac4681233 tools/nxstyle.c: Fix detection of blank line at beginning for file. Fix detection of whitespace at the end of a line. 2018-10-30 16:33:41 -06:00
Gregory Nutt de764af9aa tools/nxstyle: Back out part of last commit. Logic to avoid some false alarms was causing real style problems from being reported. 2018-10-30 08:36:30 -06:00
Gregory Nutt 88130a996a net/: Fixes for more coding standard issues detected by nxstyle. 2018-10-29 18:00:30 -06:00
Gregory Nutt dcb7ce8afd tools/nxstyle.c: Add logic to catch another formatting error and to eliminate some false alarms. Includes cosmetic changes to several files ... mostly as a result of testing nxstyle and finding issues. 2018-10-29 16:25:57 -06:00