Branch :
| Author | Commit | Date | CI | Message |
|---|---|---|---|---|
| 40aab05e | 2019-12-27 13:03:20 | build: include config.h manually Previously we included it with an `-include` compiler directive. But that's not portable. And it's better to be explicit anyway. Every .c file should have `include "config.h"` first thing. Signed-off-by: Ran Benita <ran@unusedvar.com> | ||
| 869c9b58 | 2013-08-13 09:57:07 | xkbcomp: improve a few log messages Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| ec9a02a2 | 2013-07-24 10:05:02 | Get rid of the usage of PATH_MAX PATH_MAX is optional in POSIX, so avoid its unconditional usage allocating and freeing buffers as needed. To avoid too many malloc/free in the for loop in FindFileInXkbPath, a buffer is grown according to the size needed at each iteration. | ||
| 614f60e3 | 2013-03-03 00:11:27 | xkbcomp: handle XKB file include's better The 'merge_mode' situation is quite messy, and we've introduced a regression compared to original xkbcomp: when handling a composite include statement, such as replace "foo(bar)+baz(bla)|doo:dee" and merging the entire resulting *Info back into the including *Info, we actually use the merge mode that is set by the last part (here it is "augment" because of the '|'), when we should be using the one set for the whole statement (here "replace"). We also take the opportunity to clean up a bit. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| 1c880887 | 2012-09-30 11:55:11 | Don't scan and parse useless maps One physical xkb file may (and usually does) contain multiple maps. For example, the us symbols file contains a map for every variant. Currently, when we need a map from a file (specific or default), we parse the entire file into a list of XkbFile's, find the map we want and discard the others. This happens for every include statement. This is a lot of unnecessary work; this commit is a first step at making it better. What we do now is make yyparse return one map at a time; if we find what we want, we can stop looking and avoid processing the rest of the file. This moves some logic from include.c to parser.y (i.e. finding the correct map, named or default). It also necessarily removes the CheckDefaultMap check, which warned about a file which contains multiple default maps. We can live without it. Some stats with test/rulecomp (under valgrind and the benchmark): Before: ==2280== total heap usage: 288,665 allocs, 288,665 frees, 13,121,349 bytes allocated compiled 1000 keymaps in 10.849487353s After: ==1070== total heap usage: 100,197 allocs, 100,197 frees, 9,329,900 bytes allocated compiled 1000 keymaps in 5.258960549s Pretty good. Note: we still do some unnecessary work, by parsing and discarding the maps before the one we want. However dealing with this is more complicated (maybe using bison's push-parser and sniffing the token stream). Probably not worth it. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| ee4ab30e | 2012-09-28 10:15:27 | scanner: share code in XkbParse{File,String} Some refactoring to prepare for changes in the parse() function. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| 9aee332e | 2012-09-18 17:31:55 | Fix a couple of mistakes from previous commits Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| e670d084 | 2012-09-16 13:33:09 | include: improve file-not-found error reporting Only report it once, and not only for rules. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| b4b40d73 | 2012-09-12 16:54:07 | Copyright updates With Dan Nicholson's permission (via email), update his copyright and license statements to the standard X.Org boilerplate MIT license, as both myself and Ran have been using. Clean up my copyright declarations (in some cases to correct ownership), and add copyright/license statements from myself and/or Ran where appropriate. Signed-off-by: Daniel Stone <daniel@fooishbar.org> | ||
| b6e04571 | 2012-09-10 20:16:05 | kbproto unentanglement: XkbLC_* Signed-off-by: Daniel Stone <daniel@fooishbar.org> | ||
| 8d7d9792 | 2012-08-28 00:42:59 | log: replace "priority" by "level" everywhere Now that we don't use syslog, "level" does sound more commonplace. We should change it while there is still nobody using it. Also leave some space between the integers of the xkb_log_level enum values, if we ever need to shove more in between. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| 8e6fce9b | 2012-08-29 00:44:58 | include: document ParseIncludeMap better The format of the include statment is not explained anywhere, the code is confusing and the comments misleading. Try to explain it better. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| 799cc064 | 2012-08-28 15:05:01 | include: properly use the default map if none is found For some reason this piece of code wasn't copied from xkbcomp, which causes all of the warnings like these: Warning: No map in include statement, but "pc" contains several; Using first defined map, "pc105" Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| 591df115 | 2012-08-27 19:20:41 | Move enum xkb_file_type to xkbcomp/ast.h This is a more suitable place for this enum, since it's internal to xkbcomp. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| efc2d741 | 2012-08-27 18:58:36 | xkbcomp: clean up compile_keymap function We make the xkb_file_type enum sequential instead of masks, and then we don't have to repeat the file types several times in the function. Makes the code cleaner. Signed-off-by: Ran Benita <ran234@gmail.com> | ||
| cdc228ea | 2012-08-13 11:00:43 | Organize xkbcomp/ header files Various non-functional changes: - Re-add keycodes.h and move some stuff there. - Add parser-priv.h for internal bison/flex stuff. - Don't include headers from other headers, such that file dependencies are immediate in each file. - Rename xkbcomp.h -> ast.h, parseutils.{c,h} -> ast-build.{c,h} - Rename path.{c,h} -> include.{c,h} - Rename keytypes.c -> types.c - Make the naming of XkbFile-related functions more consistent. - Move xkb_map_{new,ref,unref} to map.c. - Remove most extern keyword from function declarations, it's just noise (XKB_EXPORT is what's important here). - Append XKBCOMP_ to include guards. - Shuffle some code around to make all of this work. Splitting this would be a headache.. Signed-off-by: Ran Benita <ran234@gmail.com> |