diff options
author | 2006-01-07 16:25:28 +0000 | |
---|---|---|
committer | 2006-01-07 16:25:28 +0000 | |
commit | fcbcba027a150a7774cec4cae37dcfc15dc17dce (patch) | |
tree | afba302563e95f24bc20c0d743ac480327de4c46 /qsearch.c | |
parent | - update manpages (diff) | |
download | portage-utils-fcbcba027a150a7774cec4cae37dcfc15dc17dce.tar.gz portage-utils-fcbcba027a150a7774cec4cae37dcfc15dc17dce.tar.bz2 portage-utils-fcbcba027a150a7774cec4cae37dcfc15dc17dce.zip |
- make some applets optional for embedded systems where one might not have a full PORTDIR=
Diffstat (limited to 'qsearch.c')
-rw-r--r-- | qsearch.c | 13 |
1 files changed, 11 insertions, 2 deletions
@@ -1,12 +1,14 @@ /* * Copyright 2005-2006 Gentoo Foundation * Distributed under the terms of the GNU General Public License v2 - * $Header: /var/cvsroot/gentoo-projects/portage-utils/qsearch.c,v 1.25 2006/01/05 03:35:43 vapier Exp $ + * $Header: /var/cvsroot/gentoo-projects/portage-utils/qsearch.c,v 1.26 2006/01/07 16:25:28 solar Exp $ * * Copyright 2005-2006 Ned Ludd - <solar@gentoo.org> * Copyright 2005-2006 Mike Frysinger - <vapier@gentoo.org> */ +#ifdef APPLET_qsearch + #define QSEARCH_FLAGS "acsSNH" COMMON_FLAGS static struct option const qsearch_long_opts[] = { {"all", no_argument, NULL, 'a'}, @@ -26,7 +28,7 @@ static const char *qsearch_opts_help[] = { "Show homepage info", COMMON_OPTS_HELP }; -static const char qsearch_rcsid[] = "$Id: qsearch.c,v 1.25 2006/01/05 03:35:43 vapier Exp $"; +static const char qsearch_rcsid[] = "$Id: qsearch.c,v 1.26 2006/01/07 16:25:28 solar Exp $"; #define qsearch_usage(ret) usage(ret, QSEARCH_FLAGS, qsearch_long_opts, qsearch_opts_help, lookup_applet_idx("qsearch")) @@ -154,3 +156,10 @@ int qsearch_main(int argc, char **argv) fclose(fp); return EXIT_SUCCESS; } + + +#else /* ! APPLET_qsearch */ +int qsearch_main(int argc, char **argv) { + errf("%s", err_noapplet); +} +#endif /* APPLET_qsearch */ |