Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mkimage-profiles
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Anton Palgunov
mkimage-profiles
Commits
4ea5959f
Commit
4ea5959f
authored
Jul 17, 2012
by
Michael Shigorin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bin/mktmpdir: hasher might be unconfigured yet
No need to just go ahead and source files in potentially unavailable directories, really.
parent
1b62f94b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
mktmpdir
bin/mktmpdir
+9
-9
No files found.
bin/mktmpdir
View file @
4ea5959f
...
...
@@ -12,7 +12,7 @@ try_source() { [ -f "$1" ] && . "$1"; }
# hasher accepted ones
get_prefices
()
{
try_source /etc/hasher-priv/system
try_source /etc/hasher-priv/system
||
exit
1
try_source
`
/usr/libexec/hasher-priv/getconf.sh
`
echo
"
$prefix
"
|
tr
':'
'\n'
|
while
read
i
;
do
realpath
"
$i
"
;
done
}
...
...
@@ -61,19 +61,19 @@ choose_tmpdir() {
# bringing it all together
TMPDIRS
=
"
`
contemplate_dirs
$DIRS
`
"
if
[
-z
"
$TMPDIRS
"
]
;
then
echo
"error: no suitable directories found;"
>
&2
echo
"please check
docs, filesystem and hasher setup"
>
&2
echo
"(mount enough tmpfs into /tmp or fix hasher-priv prefix?)"
>
&2
echo
"error: no suitable directories found;"
echo
"please check
QUICKSTART, filesystem and hasher setup"
echo
"(mount enough tmpfs into /tmp or fix hasher-priv prefix?)"
exit
1
fi
fi
>
&2
TEMP
=
"
`
choose_tmpdir
$TMPDIRS
`
"
if
[
-z
"
$TEMP
"
]
;
then
echo
"error: no suitable directories found;"
>
&2
echo
"please check hasher docs and filesystem setup"
>
&2
echo
"(nodev and/or noexec on an otherwise suitable filesystem?)"
>
&2
echo
"error: no suitable directories found;"
echo
"please check hasher docs and filesystem setup"
echo
"(nodev and/or noexec on an otherwise suitable filesystem?)"
exit
1
fi
fi
>
&2
DIR
=
"
$TEMP
/
`
dirname
"
$1
"
`
"
NAME
=
"
`
basename
"
${
1
:-
tmpdir
}
"
`
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment