index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Jason St. John <jstjohn@purdue.edu> | 2013-09-03 15:20:50 -0400 |
---|---|---|
committer | Allan McRae <allan@archlinux.org> | 2013-09-04 09:51:20 +1000 |
commit | a86015f73fdda878287a2ad21011594862bf506a (patch) | |
tree | 61a580ebc898312361abe79f5bfa99441698ddec /src/util/vercmp.c | |
parent | 4245c6b222703dda7bd6000e180c777f480e4420 (diff) |
-rw-r--r-- | src/util/vercmp.c | 17 |
diff --git a/src/util/vercmp.c b/src/util/vercmp.c index f4356fb4..41a4f8e2 100644 --- a/src/util/vercmp.c +++ b/src/util/vercmp.c @@ -1,5 +1,6 @@ /* - * vercmp.c + * vercmp.c - Compare package version numbers using pacman's version + * comparison logic * * Copyright (c) 2006-2011 Pacman Development Team <pacman-dev@archlinux.org> * Copyright (c) 2002-2005 by Judd Vinet <jvinet@zeroflux.org> @@ -22,19 +23,19 @@ #include <stdio.h> /* printf */ #include <string.h> -#define BASENAME "vercmp" - /* forward declaration, comes from version.o in libalpm source that is linked * in directly so we don't have any library deps */ int alpm_pkg_vercmp(const char *a, const char *b); static void usage(void) { - fprintf(stderr, "usage: %s <ver1> <ver2>\n\n", BASENAME); - fprintf(stderr, "output values:\n"); - fprintf(stderr, " < 0 : if ver1 < ver2\n"); - fprintf(stderr, " 0 : if ver1 == ver2\n"); - fprintf(stderr, " > 0 : if ver1 > ver2\n"); + fprintf(stderr, "vercmp (pacman) v" PACKAGE_VERSION "\n\n" + "Compare package version numbers using pacman's version comparison logic.\n\n" + "Usage: vercmp <ver1> <ver2>\n\n" + "Output values:\n" + " < 0 : if ver1 < ver2\n" + " 0 : if ver1 == ver2\n" + " > 0 : if ver1 > ver2\n"); } int main(int argc, char *argv[]) |