Compare commits

..

1 Commits

Author SHA1 Message Date
morganamilo
5e52dc0906 libalpm: free trans before databases
When releasing the handle, alpm tries to do some self clean up by
freeing the databases and transaction.

However, databases refuse to unregister is there is an in progress
transaction. Causing them to leak if the handle is released while
a transaction is active.
2023-09-20 14:59:39 +01:00
111 changed files with 354 additions and 509 deletions

View File

@@ -3,4 +3,4 @@
# This script serves as a trampoline for running scripts which depend on
# libmakepkg with the libmakepkg within the build tree.
MAKEPKG_LIBRARY=@BUILDDIR@/libmakepkg exec @BASH@ -$- @REAL_PROGPATH@ "$@"
LIBRARY=@BUILDDIR@/libmakepkg exec @BASH@ -$- @REAL_PROGPATH@ "$@"

View File

@@ -336,13 +336,6 @@ function.
the optional functions listed below. The packaging stage is run using
fakeroot to ensure correct file permissions in the resulting package.
All other functions will be run as the user calling makepkg.
This function is run inside `$srcdir`.
*verify() Function*::
An optional `verify()` function can be specified to implement arbitrary
source authentication. The function should return a non-zero exit code when
verification fails. This function is run before sources are extracted.
This function is run inside `$startdir`.
*prepare() Function*::
An optional `prepare()` function can be specified in which operations to
@@ -350,19 +343,16 @@ function.
function is run after the source extraction and before the `build()`
function. The `prepare()` function is skipped when source extraction
is skipped.
This function is run inside `$srcdir`.
*build() Function*::
The optional `build()` function is used to compile and/or adjust the source
files in preparation to be installed by the `package()` function.
This function is run inside `$srcdir`.
*check() Function*::
An optional `check()` function can be specified in which a package's
test-suite may be run. This function is run between the `build()` and
`package()` functions. Be sure any exotic commands used are covered by the
`checkdepends` array.
This function is run inside `$srcdir`.
All of the above variables such as `$pkgname` and `$pkgver` are available for
use in the packaging functions. In addition, makepkg defines the following
@@ -372,6 +362,7 @@ variables:
This contains the directory where makepkg extracts, or copies, all source
files.
+
All of the packaging functions defined above are run starting inside `$srcdir`
*pkgdir*::
This contains the directory where makepkg bundles the installed package.

View File

@@ -171,9 +171,6 @@ Options
*\--noprepare*::
Do not run the prepare() function in the PKGBUILD.
*\--noverify*::
Do not run the verify() function in the PKGBUILD.
*\--sign*::
Sign the resulting package with gpg, overriding the setting in
linkman:makepkg.conf[5].
@@ -233,9 +230,6 @@ before building.
Environment Variables
---------------------
**MAKEPKG_LIBRARY**="/path/to/directory"::
Use an alternative libmakepkg path instead of the {libmakepkgdir} default.
**PACMAN**::
The command that will be used to check for missing dependencies and to
install and remove packages. Pacman's '-Qq', '-Rns', '-S', '-T', and '-U'

View File

@@ -35,7 +35,6 @@ asciidoc_opts = [
'-a', 'sysconfdir=@0@'.format(SYSCONFDIR),
'-a', 'datarootdir=@0@'.format(DATAROOTDIR),
'-a', 'rootdir=@0@'.format(ROOTDIR),
'-a', 'libmakepkgdir=@0@'.format(LIBMAKEPKGDIR),
]
html_targets = []

View File

@@ -469,7 +469,7 @@ static int commit_single_pkg(alpm_handle_t *handle, alpm_pkg_t *newpkg,
!(trans->flags & ALPM_TRANS_FLAG_NOSCRIPTLET)) {
const char *scriptlet_name = is_upgrade ? "pre_upgrade" : "pre_install";
_alpm_runscriptlet(handle, newpkg->name, pkgfile, scriptlet_name,
_alpm_runscriptlet(handle, pkgfile, scriptlet_name,
newpkg->version, oldpkg ? oldpkg->version : NULL, 1);
}
@@ -641,7 +641,7 @@ static int commit_single_pkg(alpm_handle_t *handle, alpm_pkg_t *newpkg,
char *scriptlet = _alpm_local_db_pkgpath(db, newpkg, "install");
const char *scriptlet_name = is_upgrade ? "post_upgrade" : "post_install";
_alpm_runscriptlet(handle, newpkg->name, scriptlet, scriptlet_name,
_alpm_runscriptlet(handle, scriptlet, scriptlet_name,
newpkg->version, oldpkg ? oldpkg->version : NULL, 0);
free(scriptlet);
}

View File

@@ -100,6 +100,11 @@ int SYMEXPORT alpm_release(alpm_handle_t *myhandle)
CHECK_HANDLE(myhandle, return -1);
/* free transaction memory */
if(myhandle->trans && alpm_trans_release(myhandle) == -1) {
return -1;
}
/* close local database */
db = myhandle->db_local;
if(db) {

View File

@@ -750,10 +750,6 @@ typedef enum _alpm_event_type_t {
ALPM_EVENT_LOAD_START,
/** Target package is finished loading. */
ALPM_EVENT_LOAD_DONE,
/** An install file is about to be ran */
ALPM_EVENT_INSTALL_RUN_START,
/** An install file has finished running */
ALPM_EVENT_INSTALL_RUN_DONE,
/** Scriptlet has printed information; See alpm_event_scriptlet_info_t for
* arguments. */
ALPM_EVENT_SCRIPTLET_INFO,
@@ -844,32 +840,10 @@ typedef struct _alpm_event_optdep_removal_t {
alpm_depend_t *optdep;
} alpm_event_optdep_removal_t;
/** Enum of the kinds of scriptlets */
typedef enum _alpm_scriptlet_kind_t {
/** We are running an install file */
ALPM_SCRIPTLET_KIND_INSTALL_FILE,
/** We are running a hook */
ALPM_SCRIPTLET_KIND_HOOK,
/** We are running a command */
ALPM_SCRIPTLET_KIND_COMMAND,
} alpm_scriptlet_kind_t;
/** We are running an install file. */
typedef struct _alpm_event_install_run_t {
/** Type of event */
alpm_event_type_t type;
/** The name of the package */
const char *pkgname;
} alpm_event_install_run_t;
/** A scriptlet was ran. */
typedef struct _alpm_event_scriptlet_info_t {
/** Type of event */
alpm_event_type_t type;
/** The kind of scriptlet being ran */
alpm_scriptlet_kind_t kind;
/** The name of the scriptlet **/
const char *name;
/** Line of scriptlet output */
const char *line;
} alpm_event_scriptlet_info_t;
@@ -972,8 +946,6 @@ typedef union _alpm_event_t {
alpm_event_package_operation_t package_operation;
/** An optdept was remove */
alpm_event_optdep_removal_t optdep_removal;
/** An install file is about to be run */
alpm_event_install_run_t install_run;
/** A scriptlet was ran */
alpm_event_scriptlet_info_t scriptlet_info;
/** A database is missing */

View File

@@ -522,10 +522,10 @@ static int _alpm_hook_run_hook(alpm_handle_t *handle, struct _alpm_hook_t *hook)
alpm_list_count(hook->matches), (alpm_list_fn_cmp)strcmp);
/* hooks with multiple triggers could have duplicate matches */
ctx = hook->matches = _alpm_strlist_dedup(hook->matches);
return _alpm_run_chroot(handle, hook->name, ALPM_SCRIPTLET_KIND_HOOK, hook->cmd[0], hook->cmd,
return _alpm_run_chroot(handle, hook->cmd[0], hook->cmd,
(_alpm_cb_io) _alpm_hook_feed_targets, &ctx);
} else {
return _alpm_run_chroot(handle, hook->name, ALPM_SCRIPTLET_KIND_HOOK, hook->cmd[0], hook->cmd, NULL, NULL);
return _alpm_run_chroot(handle, hook->cmd[0], hook->cmd, NULL, NULL);
}
}

View File

@@ -692,7 +692,7 @@ int _alpm_remove_single_package(alpm_handle_t *handle,
!(handle->trans->flags & ALPM_TRANS_FLAG_NOSCRIPTLET)) {
char *scriptlet = _alpm_local_db_pkgpath(handle->db_local,
oldpkg, "install");
_alpm_runscriptlet(handle, oldpkg->name, scriptlet, "pre_remove", pkgver, NULL, 0);
_alpm_runscriptlet(handle, scriptlet, "pre_remove", pkgver, NULL, 0);
free(scriptlet);
}
}
@@ -712,7 +712,7 @@ int _alpm_remove_single_package(alpm_handle_t *handle,
!(handle->trans->flags & ALPM_TRANS_FLAG_NOSCRIPTLET)) {
char *scriptlet = _alpm_local_db_pkgpath(handle->db_local,
oldpkg, "install");
_alpm_runscriptlet(handle, oldpkg->name, scriptlet, "post_remove", pkgver, NULL, 0);
_alpm_runscriptlet(handle, scriptlet, "post_remove", pkgver, NULL, 0);
free(scriptlet);
}

View File

@@ -995,13 +995,6 @@ static int check_validity(alpm_handle_t *handle,
current_bytes += v.pkg->size;
v.path = _alpm_filecache_find(handle, v.pkg->filename);
if(!v.path) {
_alpm_log(handle, ALPM_LOG_ERROR,
_("%s: could not find package in cache\n"), v.pkg->name);
RET_ERR(handle, ALPM_ERR_PKG_NOT_FOUND, -1);
}
v.siglevel = alpm_db_get_siglevel(alpm_pkg_get_db(v.pkg));
if(_alpm_pkg_validate_internal(handle, v.path, v.pkg,
@@ -1093,12 +1086,6 @@ static int load_packages(alpm_handle_t *handle, alpm_list_t **data,
current_bytes += spkg->size;
filepath = _alpm_filecache_find(handle, spkg->filename);
if(!filepath) {
_alpm_log(handle, ALPM_LOG_ERROR,
_("%s: could not find package in cache\n"), spkg->name);
RET_ERR(handle, ALPM_ERR_PKG_NOT_FOUND, -1);
}
/* load the package file and replace pkgcache entry with it in the target list */
/* TODO: alpm_pkg_get_db() will not work on this target anymore */
_alpm_log(handle, ALPM_LOG_DEBUG,

View File

@@ -334,7 +334,7 @@ static int grep(const char *fn, const char *needle)
return 0;
}
int _alpm_runscriptlet(alpm_handle_t *handle, const char *pkgname, const char *filepath,
int _alpm_runscriptlet(alpm_handle_t *handle, const char *filepath,
const char *script, const char *ver, const char *oldver, int is_archive)
{
char arg0[64], arg1[3], cmdline[PATH_MAX];
@@ -407,16 +407,7 @@ int _alpm_runscriptlet(alpm_handle_t *handle, const char *pkgname, const char *f
_alpm_log(handle, ALPM_LOG_DEBUG, "executing \"%s\"\n", cmdline);
alpm_event_install_run_t event = {
.type = ALPM_EVENT_INSTALL_RUN_START,
.pkgname = pkgname,
};
EVENT(handle, &event);
retval = _alpm_run_chroot(handle, pkgname, ALPM_SCRIPTLET_KIND_INSTALL_FILE, SCRIPTLET_SHELL, argv, NULL, NULL);
event.type = ALPM_EVENT_INSTALL_RUN_DONE;
EVENT(handle, &event);
retval = _alpm_run_chroot(handle, SCRIPTLET_SHELL, argv, NULL, NULL);
cleanup:
if(scriptfn && unlink(scriptfn)) {

View File

@@ -49,7 +49,7 @@ typedef struct _alpm_trans_t {
void _alpm_trans_free(alpm_trans_t *trans);
/* flags is a bitfield of alpm_transflag_t flags */
int _alpm_trans_init(alpm_trans_t *trans, int flags);
int _alpm_runscriptlet(alpm_handle_t *handle, const char *name, const char *filepath,
int _alpm_runscriptlet(alpm_handle_t *handle, const char *filepath,
const char *script, const char *ver, const char *oldver, int is_archive);
#endif /* ALPM_TRANS_H */

View File

@@ -31,7 +31,6 @@
#include <limits.h>
#include <sys/wait.h>
#include <sys/socket.h>
#include <fcntl.h>
#include <fnmatch.h>
#include <poll.h>
#include <signal.h>
@@ -497,21 +496,18 @@ static int _alpm_chroot_write_to_child(alpm_handle_t *handle, int fd,
return 0;
}
static void _alpm_chroot_process_output(alpm_handle_t *handle, const char *name,
alpm_scriptlet_kind_t kind, const char *line)
static void _alpm_chroot_process_output(alpm_handle_t *handle, const char *line)
{
alpm_event_scriptlet_info_t event = {
.type = ALPM_EVENT_SCRIPTLET_INFO,
.kind = kind,
.name = name,
.line = line
};
alpm_logaction(handle, "ALPM-SCRIPTLET", "%s", line);
EVENT(handle, &event);
}
static int _alpm_chroot_read_from_child(alpm_handle_t *handle, int fd, const char *name,
alpm_scriptlet_kind_t kind, char *buf, ssize_t *buf_size, ssize_t buf_limit)
static int _alpm_chroot_read_from_child(alpm_handle_t *handle, int fd,
char *buf, ssize_t *buf_size, ssize_t buf_limit)
{
ssize_t space = buf_limit - *buf_size - 2; /* reserve 2 for "\n\0" */
ssize_t nread = read(fd, buf + *buf_size, space);
@@ -523,7 +519,7 @@ static int _alpm_chroot_read_from_child(alpm_handle_t *handle, int fd, const cha
size_t linelen = newline - buf + 1;
char old = buf[linelen];
buf[linelen] = '\0';
_alpm_chroot_process_output(handle, name, kind, buf);
_alpm_chroot_process_output(handle, buf);
buf[linelen] = old;
*buf_size -= linelen;
@@ -533,14 +529,14 @@ static int _alpm_chroot_read_from_child(alpm_handle_t *handle, int fd, const cha
} else if(nread == space) {
/* we didn't read a full line, but we're out of space */
strcpy(buf + *buf_size, "\n");
_alpm_chroot_process_output(handle, name, kind, buf);
_alpm_chroot_process_output(handle, buf);
*buf_size = 0;
}
} else if(nread == 0) {
/* end-of-file */
if(*buf_size) {
strcpy(buf + *buf_size, "\n");
_alpm_chroot_process_output(handle, name, kind, buf);
_alpm_chroot_process_output(handle, buf);
}
return -1;
} else if(should_retry(errno)) {
@@ -549,7 +545,7 @@ static int _alpm_chroot_read_from_child(alpm_handle_t *handle, int fd, const cha
/* read error */
if(*buf_size) {
strcpy(buf + *buf_size, "\n");
_alpm_chroot_process_output(handle, name, kind, buf);
_alpm_chroot_process_output(handle, buf);
}
_alpm_log(handle, ALPM_LOG_ERROR,
_("unable to read from pipe (%s)\n"), strerror(errno));
@@ -585,16 +581,14 @@ static void _alpm_reset_signals(void)
/** Execute a command with arguments in a chroot.
* @param handle the context handle
* @param name a human readable name to describe the command
* @param kind what kind of scriptlet is running
* @param cmd command to execute
* @param argv arguments to pass to cmd
* @param stdin_cb callback to provide input to the chroot on stdin
* @param stdin_ctx context to be passed to @a stdin_cb
* @return 0 on success, 1 on error
*/
int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kind_t kind,
const char *cmd, char *const argv[], _alpm_cb_io stdin_cb, void *stdin_ctx)
int _alpm_run_chroot(alpm_handle_t *handle, const char *cmd, char *const argv[],
_alpm_cb_io stdin_cb, void *stdin_ctx)
{
pid_t pid;
int child2parent_pipefd[2], parent2child_pipefd[2];
@@ -655,15 +649,12 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
close(parent2child_pipefd[HEAD]);
close(child2parent_pipefd[TAIL]);
close(child2parent_pipefd[HEAD]);
if(cwdfd >= 0) {
close(cwdfd);
}
/* use fprintf instead of _alpm_log to send output through the parent */
/* don't chroot() to "/": this allows running with less caps when the
* caller puts us in the right root */
if(strcmp(handle->root, "/") != 0 && chroot(handle->root) != 0) {
if(chroot(handle->root) != 0) {
fprintf(stderr, _("could not change the root directory (%s)\n"), strerror(errno));
exit(1);
}
@@ -683,38 +674,24 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
_alpm_reset_signals();
execv(cmd, argv);
/* execv only returns if there was an error */
fprintf(stderr, _("%s: failed to execv '%s' (%s)\n"), name, cmd, strerror(errno));
fprintf(stderr, _("call to execv failed (%s)\n"), strerror(errno));
exit(1);
} else {
/* this code runs for the parent only (wait on the child) */
int status;
char obuf[PIPE_BUF]; /* writes <= PIPE_BUF are guaranteed atomic */
char ibuf[LINE_MAX];
char sciptlet_name[32];
ssize_t olen = 0, ilen = 0;
nfds_t nfds = 2;
struct pollfd fds[2], *child2parent = &(fds[0]), *parent2child = &(fds[1]);
int poll_ret;
switch(kind) {
case ALPM_SCRIPTLET_KIND_HOOK:
snprintf(sciptlet_name, 32, "hook '%s'", name);
break;
case ALPM_SCRIPTLET_KIND_INSTALL_FILE:
snprintf(sciptlet_name, 32, "'%s.install'", name);
break;
case ALPM_SCRIPTLET_KIND_COMMAND:
strncpy(sciptlet_name, "ldconfig", 32);
break;
}
child2parent->fd = child2parent_pipefd[TAIL];
child2parent->events = POLLIN;
fcntl(child2parent->fd, F_SETFL, O_NONBLOCK);
close(child2parent_pipefd[HEAD]);
close(parent2child_pipefd[TAIL]);
if(stdin_cb) {
parent2child->fd = parent2child_pipefd[HEAD];
parent2child->events = POLLOUT;
@@ -737,7 +714,7 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
}
}
if(child2parent->revents & POLLIN) {
if(_alpm_chroot_read_from_child(handle, child2parent->fd, name, kind,
if(_alpm_chroot_read_from_child(handle, child2parent->fd,
ibuf, &ilen, sizeof(ibuf)) != 0) {
/* we encountered end-of-file or an error */
STOP_POLLING(child2parent);
@@ -760,7 +737,7 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
if(ilen) {
/* buffer would have already been flushed if it had a newline */
strcpy(ibuf + ilen, "\n");
_alpm_chroot_process_output(handle, name, kind, ibuf);
_alpm_chroot_process_output(handle, ibuf);
}
#undef STOP_POLLING
@@ -776,7 +753,7 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
while(waitpid(pid, &status, 0) == -1) {
if(errno != EINTR) {
_alpm_log(handle, ALPM_LOG_ERROR, _("failed to run %s: call to waitpid failed (%s)\n"), sciptlet_name, strerror(errno));
_alpm_log(handle, ALPM_LOG_ERROR, _("call to waitpid failed (%s)\n"), strerror(errno));
retval = 1;
goto cleanup;
}
@@ -786,8 +763,7 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
if(WIFEXITED(status)) {
_alpm_log(handle, ALPM_LOG_DEBUG, "call to waitpid succeeded\n");
if(WEXITSTATUS(status) != 0) {
_alpm_log(handle, ALPM_LOG_ERROR, _("%s did not complete sucessfully (%s exited %d)\n"),
sciptlet_name, cmd, WEXITSTATUS(status));
_alpm_log(handle, ALPM_LOG_ERROR, _("command failed to execute correctly\n"));
retval = 1;
}
} else if(WIFSIGNALED(status) != 0) {
@@ -796,8 +772,8 @@ int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kin
if(signal_description == NULL) {
signal_description = _("Unknown signal");
}
_alpm_log(handle, ALPM_LOG_ERROR, _("%s terminated by signal %d: %s\n"),
sciptlet_name, WTERMSIG(status), signal_description);
_alpm_log(handle, ALPM_LOG_ERROR, _("command terminated by signal %d: %s\n"),
WTERMSIG(status), signal_description);
retval = 1;
}
}
@@ -828,9 +804,10 @@ int _alpm_ldconfig(alpm_handle_t *handle)
if(access(line, F_OK) == 0) {
snprintf(line, PATH_MAX, "%s%s", handle->root, LDCONFIG);
if(access(line, X_OK) == 0) {
char *arg0 = strdup(LDCONFIG);
char arg0[32];
char *argv[] = { arg0, NULL };
return _alpm_run_chroot(handle, "ldconfig", ALPM_SCRIPTLET_KIND_COMMAND, LDCONFIG, argv, NULL, NULL);
strcpy(arg0, "ldconfig");
return _alpm_run_chroot(handle, LDCONFIG, argv, NULL, NULL);
}
}
@@ -865,17 +842,10 @@ char *_alpm_filecache_find(alpm_handle_t *handle, const char *filename)
for(i = handle->cachedirs; i; i = i->next) {
snprintf(path, PATH_MAX, "%s%s", (char *)i->data,
filename);
if(stat(path, &buf) == 0) {
if(S_ISREG(buf.st_mode)) {
retpath = strdup(path);
_alpm_log(handle, ALPM_LOG_DEBUG, "found cached pkg: %s\n", retpath);
return retpath;
} else {
_alpm_log(handle, ALPM_LOG_WARNING,
"cached pkg '%s' is not a regular file: mode=%i\n", path, buf.st_mode);
}
} else if(errno != ENOENT) {
_alpm_log(handle, ALPM_LOG_WARNING, "could not open '%s'\n: %s", path, strerror(errno));
if(stat(path, &buf) == 0 && S_ISREG(buf.st_mode)) {
retpath = strdup(path);
_alpm_log(handle, ALPM_LOG_DEBUG, "found cached pkg: %s\n", retpath);
return retpath;
}
}
/* package wasn't found in any cachedir */
@@ -1382,11 +1352,6 @@ int _alpm_access(alpm_handle_t *handle, const char *dir, const char *file, int a
size_t len = 0;
int ret = 0;
int flag = 0;
#ifdef AT_SYMLINK_NOFOLLOW
flag |= AT_SYMLINK_NOFOLLOW;
#endif
if(dir) {
char *check_path;
@@ -1394,11 +1359,11 @@ int _alpm_access(alpm_handle_t *handle, const char *dir, const char *file, int a
CALLOC(check_path, len, sizeof(char), RET_ERR(handle, ALPM_ERR_MEMORY, -1));
snprintf(check_path, len, "%s%s", dir, file);
ret = faccessat(AT_FDCWD, check_path, amode, flag);
ret = access(check_path, amode);
free(check_path);
} else {
dir = "";
ret = faccessat(AT_FDCWD, file, amode, flag);
ret = access(file, amode);
}
if(ret != 0) {

View File

@@ -129,8 +129,8 @@ ssize_t _alpm_files_in_directory(alpm_handle_t *handle, const char *path, int fu
typedef ssize_t (*_alpm_cb_io)(void *buf, ssize_t len, void *ctx);
int _alpm_run_chroot(alpm_handle_t *handle, const char *name, alpm_scriptlet_kind_t kind,
const char *cmd, char *const argv[], _alpm_cb_io in_cb, void *in_ctx);
int _alpm_run_chroot(alpm_handle_t *handle, const char *cmd, char *const argv[],
_alpm_cb_io in_cb, void *in_ctx);
int _alpm_ldconfig(alpm_handle_t *handle);
int _alpm_str_cmp(const void *s1, const void *s2);
char *_alpm_filecache_find(alpm_handle_t *handle, const char *filename);

View File

@@ -553,7 +553,7 @@ _pacman_conf_directive() {
_pacman_conf_commands=(
{-l,--repo-list}'[List configured repositories]:*: :->repo_list'
{-h,--help}'[Output syntax and command line options]:*: :->complete'
{-h,--help}'[Output systax and command line options]:*: :->complete'
{-V,--version}'[Display version and exit]:*: :->complete'
)
@@ -564,7 +564,7 @@ _pacman_conf_options=(
_pacman_conf_options_common=(
'*'{-c,--config=}'[Specify an alternate configuration file]: :_files'
'*'{-R,--rootdir=}'[Specify an alternate installation root]: :_files'
'*'{-R,--rootdir=}'[Specify an alternate insallation root]: :_files'
)
_pacman_conf() {

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_AUTODEP_SH" ]] && return
LIBMAKEPKG_AUTODEP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
declare -a autodep_functions
for lib in "$MAKEPKG_LIBRARY/autodep/"*.sh; do
for lib in "$LIBRARY/autodep/"*.sh; do
source "$lib"
done

View File

@@ -21,7 +21,7 @@
[[ -n "$LIBMAKEPKG_AUTODEP_LIBRARY_DEPENDS_SH" ]] && return
LIBMAKEPKG_AUTODEP_LIBRARY_DEPENDS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
autodep_functions+=('library_depends')

View File

@@ -21,7 +21,7 @@
[[ -n "$LIBMAKEPKG_AUTODEP_LIBRARY_PROVIDES_SH" ]] && return
LIBMAKEPKG_AUTODEP_LIBRARY_PROVIDES_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
autodep_functions+=('library_provides')

View File

@@ -22,12 +22,12 @@
[[ -n "$LIBMAKEPKG_BUILDENV_SH" ]] && return
LIBMAKEPKG_BUILDENV_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
declare -a buildenv_functions build_options
buildenv_vars=('CPPFLAGS' 'CFLAGS' 'CXXFLAGS' 'LDFLAGS' 'MAKEFLAGS' 'CHOST')
for lib in "$MAKEPKG_LIBRARY/buildenv/"*.sh; do
for lib in "$LIBRARY/buildenv/"*.sh; do
source "$lib"
done

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_BUILDENV_BUILDFLAGS_SH" ]] && return
LIBMAKEPKG_BUILDENV_BUILDFLAGS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/option.sh"
build_options+=('buildflags')

View File

@@ -23,9 +23,9 @@
[[ -n "$LIBMAKEPKG_BUILDENV_COMPILER_SH" ]] && return
LIBMAKEPKG_BUILDENV_COMPILER_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/option.sh"
build_options+=('ccache' 'distcc')
buildenv_functions+=('buildenv_ccache' 'buildenv_distcc')

View File

@@ -22,18 +22,17 @@
[[ -n "$LIBMAKEPKG_BUILDENV_DEBUGFLAGS_SH" ]] && return
LIBMAKEPKG_BUILDENV_DEBUGFLAGS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/option.sh"
buildenv_functions+=('buildenv_debugflags')
buildenv_debugflags() {
if check_option "debug" "y" && ! check_option "buildflags" "n"; then
append_once DEBUG_CFLAGS "-ffile-prefix-map=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
append_once DEBUG_CXXFLAGS "-ffile-prefix-map=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
append_once CFLAGS "$DEBUG_CFLAGS"
append_once CXXFLAGS "$DEBUG_CXXFLAGS"
DEBUG_CFLAGS+=" -ffile-prefix-map=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
DEBUG_CXXFLAGS+=" -ffile-prefix-map=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
CFLAGS+=" $DEBUG_CFLAGS"
CXXFLAGS+=" $DEBUG_CXXFLAGS"
fi
}

View File

@@ -22,18 +22,17 @@
[[ -n "$LIBMAKEPKG_BUILDENV_LTO_SH" ]] && return
LIBMAKEPKG_BUILDENV_LTO_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/option.sh"
build_options+=('lto')
buildenv_functions+=('buildenv_lto')
buildenv_lto() {
if check_option "lto" "y" && ! check_option "buildflags" "n"; then
append_once CFLAGS "${LTOFLAGS:--flto}"
append_once CXXFLAGS "${LTOFLAGS:--flto}"
append_once LDFLAGS "${LTOFLAGS:--flto}"
CFLAGS+=" ${LTOFLAGS:--flto}"
CXXFLAGS+=" ${LTOFLAGS:--flto}"
LDFLAGS+=" ${LTOFLAGS:--flto}"
fi
}

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_BUILDENV_MAKEFLAGS_SH" ]] && return
LIBMAKEPKG_BUILDENV_MAKEFLAGS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/option.sh"
build_options+=('makeflags')
buildenv_functions+=('buildenv_makeflags')

View File

@@ -21,17 +21,16 @@
[[ -n "$LIBMAKEPKG_BUILDENV_RUST_SH" ]] && return
LIBMAKEPKG_BUILDENV_RUST_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/option.sh"
buildenv_var+=('RUSTFLAGS' 'DEBUG_RUSTFLAGS')
buildenv_functions+=('buildenv_rust')
buildenv_rust() {
if check_option "debug" "y" && ! check_option "buildflags" "n"; then
append_once DEBUG_RUSTFLAGS "--remap-path-prefix=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
append_once RUSTFLAGS "$DEBUG_RUSTFLAGS"
DEBUG_RUSTFLAGS+=" --remap-path-prefix=$srcdir=${DBGSRCDIR:-/usr/src/debug}/${pkgbase}"
RUSTFLAGS+=" $DEBUG_RUSTFLAGS"
fi
}

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
declare -a executable_functions
for lib in "$MAKEPKG_LIBRARY/executable/"*.sh; do
for lib in "$LIBRARY/executable/"*.sh; do
source "$lib"
done

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_CCACHE_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_CCACHE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_ccache')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_CHECKSUM_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_CHECKSUM_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
executable_functions+=('executable_checksum')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_DEBUGEDIT_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_DEBUGEDIT_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_debugedit')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_DISTCC_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_DISTCC_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_distcc')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_FAKEROOT_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_FAKEROOT_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
executable_functions+=('executable_fakeroot')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_GPG_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_GPG_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_gpg')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_GZIP_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_GZIP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_gzip')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_PACMAN_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_PACMAN_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
executable_functions+=('executable_pacman')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_STRIP_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_STRIP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
executable_functions+=('executable_strip')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_SUDO_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_SUDO_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
executable_functions+=('executable_sudo')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_EXECUTABLE_VCS_SH" ]] && return
LIBMAKEPKG_EXECUTABLE_VCS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/error.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/error.sh"
source "$LIBRARY/util/message.sh"
executable_functions+=('executable_vcs')

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_INTEGRITY_SH" ]] && return
LIBMAKEPKG_INTEGRITY_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
for lib in "$MAKEPKG_LIBRARY/integrity/"*.sh; do
for lib in "$LIBRARY/integrity/"*.sh; do
source "$lib"
done
@@ -42,7 +42,4 @@ check_source_integrity() {
check_checksums "$@"
check_pgpsigs "$@"
fi
if (( VERIFYFUNC )); then
run_verify
fi
}

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_INTEGRITY_GENERATE_CHECKSUM_SH" ]] && return
LIBMAKEPKG_INTEGRITY_GENERATE_CHECKSUM_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
generate_one_checksum() {
local integ=$1 arch=$2 sources numsrc indentsz idx

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_INTEGRITY_GENERATE_SIGNATURE_SH" ]] && return
LIBMAKEPKG_INTEGRITY_GENERATE_SIGNATURE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
create_signature() {
local ret=0

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_INTEGRITY_VERIFY_CHECKSUM_SH" ]] && return
LIBMAKEPKG_INTEGRITY_CHECKSUM_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$MAKEPKG_LIBRARY/source.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
source "$LIBRARY/source.sh"
check_checksums() {
local integ a

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_INTEGRITY_VERIFY_SIGNATURE_SH" ]] && return
LIBMAKEPKG_INTEGRITY_VERIFY_SIGNATURE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
check_pgpsigs() {
(( SKIPPGPCHECK )) && return 0

View File

@@ -21,15 +21,15 @@
[[ -n "$LIBMAKEPKG_LINT_CONFIG_SH" ]] && return
LIBMAKEPKG_LINT_CONFIG_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'/usr/share/makepkg'}
LIBRARY=${LIBRARY:-'/usr/share/makepkg'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/util.sh"
declare -a lint_config_functions
for lib in "$MAKEPKG_LIBRARY/lint_config/"*.sh; do
for lib in "$LIBRARY/lint_config/"*.sh; do
source "$lib"
done

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_CONFIG_EXT_SH" ]] && return
LIBMAKEPKG_LINT_CONFIG_EXT_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_config_functions+=('lint_ext')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_CONFIG_PATHS_SH" ]] && return
LIBMAKEPKG_LINT_CONFIG_PATHS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_config_functions+=('lint_paths')

View File

@@ -21,9 +21,9 @@
[[ -n $LIBMAKEPKG_LINT_CONFIG_SOURCE_DATE_EPOCH_SH ]] && return
LIBMAKEPKG_LINT_CONFIG_SOURCE_DATE_EPOCH_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_config_functions+=('lint_source_date_epoch')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_CONFIG_VARIABLE_SH" ]] && return
LIBMAKEPKG_LINT_CONFIG_VARIABLE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_config_functions+=('lint_config_variables')

View File

@@ -21,15 +21,15 @@
[[ -n "$LIBMAKEPKG_LINT_PACKAGE_SH" ]] && return
LIBMAKEPKG_LINT_PACKAGE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/util.sh"
declare -a lint_package_functions
for lib in "$MAKEPKG_LIBRARY/lint_package/"*.sh; do
for lib in "$LIBRARY/lint_package/"*.sh; do
source "$lib"
done

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PACKAGE_BUILD_REFERENCES_SH" ]] && return
LIBMAKEPKG_LINT_PACKAGE_BUILD_REFERENCES_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_package_functions+=('warn_build_references')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PACKAGE_DOTFILES_SH" ]] && return
LIBMAKEPKG_LINT_PACKAGE_DOTFILES_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_package_functions+=('check_dotfiles')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PACKAGE_FILE_NAMES_SH" ]] && return
LIBMAKEPKG_LINT_PACKAGE_FILE_NAMES_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_package_functions+=('lint_file_names')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PACKAGE_MISSING_BACKUP_SH" ]] && return
LIBMAKEPKG_LINT_PACKAGE_MISSING_BACKUP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_package_functions+=('warn_missing_backup')

View File

@@ -21,14 +21,14 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
declare -a lint_pkgbuild_functions
for lib in "$MAKEPKG_LIBRARY/lint_pkgbuild/"*.sh; do
for lib in "$LIBRARY/lint_pkgbuild/"*.sh; do
source "$lib"
done

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_ARCH_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_ARCH_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_arch')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_ARCH_SPECIFIC_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_ARCH_SPECIFIC_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
source "$LIBRARY/util/util.sh"
lint_pkgbuild_functions+=('lint_arch_specific')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_BACKUP_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_BACKUP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_backup')

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_CHANGELOG_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_CHANGELOG_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/util.sh"
lint_pkgbuild_functions+=('lint_changelog')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_CHECKDEPENDS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_CHECKDEPENDS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_checkdepends')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_CONFLICTS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_CONFLICTS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_conflicts')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_DEPENDS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_DEPENDS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_depends')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_EPOCH_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_EPOCH_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_epoch')

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_FULLPKGVER_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_FULLPKGVER_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/epoch.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgrel.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgver.sh"
source "$LIBRARY/lint_pkgbuild/epoch.sh"
source "$LIBRARY/lint_pkgbuild/pkgrel.sh"
source "$LIBRARY/lint_pkgbuild/pkgver.sh"
check_fullpkgver() {

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_INSTALL_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_INSTALL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/util.sh"
lint_pkgbuild_functions+=('lint_install')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_MAKEDEPENDS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_MAKEDEPENDS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_makedepends')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_OPTDEPENDS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_OPTDEPENDS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_optdepends')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_OPTIONS_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_OPTIONS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_options')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PACKAGE_FUNCTION_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PACKAGE_FUNCTION_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_package_function')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PACKAGE_FUNCTION_VARIABLE_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PACKAGE_FUNCTION_VARIABLE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
source "$LIBRARY/util/util.sh"
lint_pkgbuild_functions+=('lint_package_function_variable')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PKGBASE_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PKGBASE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_pkgbase')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PKGLIST_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PKGLIST_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/util.sh"
lint_pkgbuild_functions+=('lint_pkglist')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PKGNAME_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PKGNAME_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_pkgname')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PKGREL_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PKGREL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_pkgrel')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PKGVER_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PKGVER_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_pkgver')

View File

@@ -21,12 +21,12 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_PROVIDES_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_PROVIDES_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$MAKEPKG_LIBRARY/lint_pkgbuild/pkgname.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/lint_pkgbuild/fullpkgver.sh"
source "$LIBRARY/lint_pkgbuild/pkgname.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
lint_pkgbuild_functions+=('lint_provides')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_SOURCE_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_SOURCE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
lint_pkgbuild_functions+=('lint_source')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_UTIL_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_UTIL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
check_files_exist() {

View File

@@ -21,11 +21,11 @@
[[ -n "$LIBMAKEPKG_LINT_PKGBUILD_VARIABLE_SH" ]] && return
LIBMAKEPKG_LINT_PKGBUILD_VARIABLE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
lint_pkgbuild_functions+=('lint_variable')
lint_pkgbuild_functions+=('lint_array')

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_REPRODUCIBLE_SH" ]] && return
LIBMAKEPKG_REPRODUCIBLE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
for lib in "$MAKEPKG_LIBRARY/reproducible/"*.sh; do
for lib in "$LIBRARY/reproducible/"*.sh; do
source "$lib"
done

View File

@@ -22,7 +22,7 @@
LIBMAKEPKG_REPRODUCIBLE_PYTHON_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
# disable hash randomization when creating .pyc files

View File

@@ -21,14 +21,14 @@
[[ -n "$LIBMAKEPKG_SOURCE_SH" ]] && return
LIBMAKEPKG_SOURCE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/source.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/source.sh"
for lib in "$MAKEPKG_LIBRARY/source/"*.sh; do
for lib in "$LIBRARY/source/"*.sh; do
source "$lib"
done

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_BZR_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_bzr() {

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_FILE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_file() {

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_FOSSIL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_fossil() {
# abort early if parent says not to fetch

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_GIT_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_git() {
@@ -56,8 +56,7 @@ download_git() {
elif (( ! HOLDVER )); then
cd_safe "$dir"
# Make sure we are fetching the right repo
local remote_url="$(git config --get remote.origin.url)"
if [[ "${url%%.git}" != "${remote_url%%.git}" ]] ; then
if [[ "$url" != "$(git config --get remote.origin.url)" ]] ; then
error "$(gettext "%s is not a clone of %s")" "$dir" "$url"
plainerr "$(gettext "Aborting...")"
exit 1

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_HG_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_hg() {

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_LOCAL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_local() {

View File

@@ -22,10 +22,10 @@
LIBMAKEPKG_SOURCE_SVN_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
download_svn() {

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_SRCINFO_SH" ]] && return
LIBMAKEPKG_SRCINFO_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/schema.sh"
srcinfo_open_section() {
printf '%s = %s\n' "$1" "$2"

View File

@@ -22,14 +22,14 @@
[[ -n "$LIBMAKEPKG_TIDY_SH" ]] && return
LIBMAKEPKG_TIDY_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$LIBRARY/util/message.sh"
declare -a packaging_options tidy_remove tidy_modify
for lib in "$MAKEPKG_LIBRARY/tidy/"*.sh; do
for lib in "$LIBRARY/tidy/"*.sh; do
source "$lib"
done

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_DOCS_SH" ]] && return
LIBMAKEPKG_TIDY_DOCS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('docs')
tidy_remove+=('tidy_docs')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_EMPTYDIRS_SH" ]] && return
LIBMAKEPKG_TIDY_EMPTYDIRS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('emptydirs')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_LIBTOOL_SH" ]] && return
LIBMAKEPKG_TIDY_LIBTOOL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('libtool')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_PURGE_SH" ]] && return
LIBMAKEPKG_TIDY_PURGE_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('purge')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_STATICLIBS_SH" ]] && return
LIBMAKEPKG_TIDY_STATICLIBS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('staticlibs')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_STRIP_SH" ]] && return
LIBMAKEPKG_TIDY_STRIP_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('strip' 'debug')

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_TIDY_ZIPMAN_SH" ]] && return
LIBMAKEPKG_TIDY_ZIPMAN_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/option.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/option.sh"
packaging_options+=('zipman')

View File

@@ -21,8 +21,8 @@
[[ -n "$LIBMAKEPKG_UTIL_SH" ]] && return
LIBMAKEPKG_UTIL_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
for lib in "$MAKEPKG_LIBRARY/util/"*.sh; do
for lib in "$LIBRARY/util/"*.sh; do
source "$lib"
done

View File

@@ -21,10 +21,10 @@
[[ -n "$LIBMAKEPKG_UTIL_COMPRESS_SH" ]] && return
LIBMAKEPKG_UTIL_COMPRESS_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/pkgbuild.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/pkgbuild.sh"
# Wrapper around many stream compression formats, for use in the middle of a

View File

@@ -22,11 +22,11 @@
[[ -n "$LIBMAKEPKG_UTIL_CONFIG_SH" ]] && return
LIBMAKEPKG_UTIL_CONFIG_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/error.sh"
source "$MAKEPKG_LIBRARY/util/message.sh"
source "$MAKEPKG_LIBRARY/util/util.sh"
source "$LIBRARY/util/error.sh"
source "$LIBRARY/util/message.sh"
source "$LIBRARY/util/util.sh"
# correctly source makepkg.conf, respecting user precedence and the system conf
source_makepkg_config() {

View File

@@ -21,9 +21,9 @@
[[ -n "$LIBMAKEPKG_UTIL_PKGBUILD_SH" ]] && return
LIBMAKEPKG_UTIL_PKGBUILD_SH=1
MAKEPKG_LIBRARY=${MAKEPKG_LIBRARY:-'@libmakepkgdir@'}
LIBRARY=${LIBRARY:-'@libmakepkgdir@'}
source "$MAKEPKG_LIBRARY/util/schema.sh"
source "$LIBRARY/util/schema.sh"
have_function() {

Some files were not shown because too many files have changed in this diff Show More