Building without /home/${user} directory possible?

Trying to build on a host where there is no /home/${user} directory.

Conf set


The build then fails with

ccache: error: Failed to create directory /home/${user}/.ccache/tmp: Permission denied/

which in itself is logical since there is no /home/${user} in attendance. However, with the conf set to specific patch it would not expected that /home/${user} is being sought.

/logs/target/linux/compile.txt does not really provide further info which script/conf is causing this, even when being run in debug mode.

Is a home dir mandatory for the build process, there is nothing mentioned about it though in, or elsewhere?

Perhaps it's a result of the ccache default, from the man page:

       cache_dir (CCACHE_DIR)
           This setting specifies where ccache will keep its cached compiler outputs. It will only take effect if set in the system-wide configuration file or as an
           environment variable. The default is $HOME/.ccache.
1 Like

Thanks for the pointer. I would have expected that


would have taken care of it...

Will try now with CCACHE_DIR, see if gets parsed || applied by the build script

Might have to set it in the environment explicitly, or in the ccache config file.

1 Like

Depending on /home/${USER} is wrong.
On the other hand, ${USER} should have access to ${HOME}.

1 Like

Well, that is not my invention but printed in the log and I cannot find where it stems from and thus the issue/question

that dir exists and is accessible by the user.

1 Like

Try something like this:

grep -r -e /home /path/to/src

There is plenty to sift through, that will take moment.

Meantime ran a grep on the git for CCACHE_DIR but that did not produce a meaningful result

1 Like

That did not work, same error. Will have to look into

1 Like

Nothing in the output that hints @ /home/${user}

according to man ccache -p would

Print current configuration options and from where they originate (environment variable, configuration file or compile-time default) in human-readable format.

But works only when invoked as ccache but that does not work since it does not get build that way but only as linked in compiler...

If would not have been for an error in the script it would have worked from the start, meaning /home/${user} is not required to be in residence.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.