Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge branch 'jb52287' into 'master'
Fix host-gcc use

See merge request mer-core/scratchbox2!41
  • Loading branch information
martyone committed Dec 17, 2020
2 parents c0c79d3 + 44824ec commit d93761c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 146 deletions.
10 changes: 5 additions & 5 deletions scratchbox2/execs/sb_exec.c
Expand Up @@ -1535,15 +1535,15 @@ static int prepare_exec(const char *exec_fn_name,
exec_policy_name,
&mapped_file, &my_file, binaryname,
(const char **)my_argv, &my_new_argv,
(const char **)*new_envp, &my_new_envp,
(const char **)my_envp, &my_new_envp,
"target");
} else {
postprocess_result = exec_postprocess_native_executable(
exec_policy_name,
&mapped_file, &my_file, binaryname,
&info,
(const char **)my_argv, &my_new_argv,
(const char **)*new_envp, &my_new_envp);
(const char **)my_envp, &my_new_envp);
}
my_envp = (char**)my_new_envp; /* FIXME */
my_argv = (char**)my_new_argv; /* FIXME */
Expand All @@ -1570,7 +1570,7 @@ static int prepare_exec(const char *exec_fn_name,
exec_policy_name,
&mapped_file, &my_file, binaryname,
(const char **)my_argv, &my_new_argv,
(const char **)*new_envp, &my_new_envp,
(const char **)my_envp, &my_new_envp,
"native");
my_envp = (char**)my_new_envp; /* FIXME */
my_argv = (char**)my_new_argv; /* FIXME */
Expand Down Expand Up @@ -1609,7 +1609,7 @@ static int prepare_exec(const char *exec_fn_name,
exec_policy_name,
&mapped_file, &my_file, binaryname,
(const char **)my_argv, &my_new_argv,
(const char **)*new_envp, &my_new_envp);
(const char **)my_envp, &my_new_envp);
my_envp = (char**)my_new_envp; /* FIXME */
my_argv = (char**)my_new_argv; /* FIXME */
}
Expand Down Expand Up @@ -1639,7 +1639,7 @@ static int prepare_exec(const char *exec_fn_name,
postprocess_result = exec_postprocess_cpu_transparency_executable(
exec_policy_name,
&mapped_file, &my_file, binaryname,
(const char **)my_argv, &my_new_argv, (const char **)*new_envp, &my_new_envp,
(const char **)my_argv, &my_new_argv, (const char **)my_envp, &my_new_envp,
"target");
my_envp = (char**)my_new_envp; /* FIXME */
my_argv = (char**)my_new_argv; /* FIXME */
Expand Down
18 changes: 8 additions & 10 deletions scratchbox2/lua_scripts/argvenvp_gcc.lua
Expand Up @@ -73,17 +73,15 @@ function register_gcc_component_path(tmp, gccrule)
table.insert(gcc_tools_path_prefixes, x)
end

if gccrule == nil then
return
end

if gccrule.cross_gcc_dir ~= nil then
table.insert(gcc_tools_path_prefixes, gccrule.cross_gcc_dir)
end
if gccrule ~= nil then
if gccrule.cross_gcc_dir ~= nil then
table.insert(gcc_tools_path_prefixes, gccrule.cross_gcc_dir)
end

if gccrule.cross_gcc_progs_path ~= nil then
for path in string.gmatch(gccrule.cross_gcc_progs_path,"[^:]+") do
table.insert(gcc_tools_path_prefixes, path)
if gccrule.cross_gcc_progs_path ~= nil then
for path in string.gmatch(gccrule.cross_gcc_progs_path,"[^:]+") do
table.insert(gcc_tools_path_prefixes, path)
end
end
end

Expand Down
131 changes: 0 additions & 131 deletions scratchbox2/lua_scripts/create_argvmods_usr_bin_rules.lua

This file was deleted.

0 comments on commit d93761c

Please sign in to comment.