if (r) {
// Drop to a shell for debugging
if (flags & PAKFIRE_BUILD_INTERACTIVE)
- pakfire_shell(pakfire);
+ pakfire_execute_shell(pakfire);
goto ERROR;
}
}
PAKFIRE_EXPORT int pakfire_shell(struct pakfire* pakfire) {
- const char* argv[] = {
- "/bin/bash", "--login", NULL,
- };
+ int r;
- const int flags =
- PAKFIRE_EXECUTE_INTERACTIVE | PAKFIRE_EXECUTE_ENABLE_NETWORK;
+ // Setup build environment
+ r = pakfire_build_setup(pakfire);
+ if (r)
+ return r;
- return pakfire_execute(pakfire, argv, NULL, flags, NULL, NULL);
+ return pakfire_execute_shell(pakfire);
}
return r;
}
+int pakfire_execute_shell(struct pakfire* pakfire) {
+ const char* argv[] = {
+ "/bin/bash", "--login", NULL,
+ };
+
+ const int flags =
+ PAKFIRE_EXECUTE_INTERACTIVE | PAKFIRE_EXECUTE_ENABLE_NETWORK;
+
+ return pakfire_execute(pakfire, argv, NULL, flags, NULL, NULL);
+}
+
int pakfire_execute_ldconfig(struct pakfire* pakfire) {
char path[PATH_MAX];
const char* line, size_t length);
int pakfire_execute_capture_stdout_to_array(struct pakfire* pakfire, void* data, int priority,
const char* line, size_t length);
+int pakfire_execute_shell(struct pakfire* pakfire);
int pakfire_execute_ldconfig(struct pakfire* pakfire);
#endif