Skip to content

Commit

Permalink
build: Fix USER_DIR_MODE value in config.h
Browse files Browse the repository at this point in the history
meson defines `USER_DIR_MODE` with a raw octal value to be used as
the default permissions when creating the user's configuration
directory.

However, meson does not support raw octal values[0], so the define
misses the initial `0` value. Due to this, the directory is created
with wrong permissions.

This has been changed to use the octal value as a string in meson,
so the definition has the proper value.

Fixes #49

[0] mesonbuild/meson#2047
  • Loading branch information
inigomartinez authored and GeorgesStavracas committed Apr 17, 2018
1 parent 897e91e commit 37a6b94
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion meson.build
Expand Up @@ -44,7 +44,9 @@ foreach define: set_defines
config_h.set_quoted(define[0], define[1])
endforeach

config_h.set('USER_DIR_MODE', 0700,
# meson does not support octal values, so it must be handled as a
# string. See: https://github.com/mesonbuild/meson/issues/2047
config_h.set('USER_DIR_MODE', '0700',
description: 'Permissions for creating the user\'s config, cache and data directories')

# compiler flags
Expand Down

0 comments on commit 37a6b94

Please sign in to comment.