aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lua_state.c3
-rw-r--r--src/recipes.c8
2 files changed, 4 insertions, 7 deletions
diff --git a/src/lua_state.c b/src/lua_state.c
index cf46760..df4839f 100644
--- a/src/lua_state.c
+++ b/src/lua_state.c
@@ -18,8 +18,7 @@ static void lua_path_push(const char *new_path) {
lua_getfield(L, -1, "path");
const char *current_path = lua_tostring(L, -1);
- if (!current_path)
- current_path = "";
+ if (!current_path) current_path = "";
lua_pop(L, 1);
lua_pushfstring(L, "%s;%s", current_path, new_path);
diff --git a/src/recipes.c b/src/recipes.c
index ae3adda..debfa62 100644
--- a/src/recipes.c
+++ b/src/recipes.c
@@ -162,14 +162,13 @@ bool pkg_build(package_t *pkg) {
bool pkg_full_build(package_t *pkg) {
if (flags.force) pkg_remove_status(pkg);
if (!pkg_enter(pkg)) return false;
- if (!pkg_setup(pkg)) return false;
+ pkg_setup(pkg);
if (!pkg_build(pkg)) return false;
return true;
}
bool pkg_install(package_t *pkg) {
if (is_pkg_installed(pkg) && !flags.force) return true;
- if (flags.force) pkg_remove_status(pkg);
if (!pkg_enter(pkg)) return false;
try_pkg_fn(pkg_hook_install, pkg, "install", 'i');
return true;
@@ -177,10 +176,9 @@ bool pkg_install(package_t *pkg) {
bool pkg_full_install(package_t *pkg) {
if (is_pkg_installed(pkg) && !flags.force) return true;
+ if (flags.force) pkg_remove_status(pkg);
try_pkg_fn(pkg_fetch_sources, pkg, "fetch", 'f');
- if (!pkg_enter(pkg)) return false;
- if (!pkg_setup(pkg)) return false;
- if (!pkg_build(pkg)) return false;
+ if (!pkg_full_build(pkg)) return false;
if (!pkg_install(pkg)) return false;
return true;
}