diff options
author | Timo Teras <timo.teras@iki.fi> | 2008-04-17 14:09:13 +0000 |
---|---|---|
committer | Timo Teras <timo.teras@iki.fi> | 2008-04-17 14:09:13 +0000 |
commit | d6c74352427367a334d37469962bbcf1b9ae364c (patch) | |
tree | 81ebcf6fc8abf08baea3f0015bc2f7a08768fb1f /src/apk_applet.h | |
parent | 45d2c702fc8a47bc3f5ab4698de2bf1e377301c4 (diff) | |
download | apk-tools-d6c74352427367a334d37469962bbcf1b9ae364c.tar.bz2 apk-tools-d6c74352427367a334d37469962bbcf1b9ae364c.tar.xz |
Initial commit of some stuff written so far. Still in state of flux. Expect
breakage and major changes.
Diffstat (limited to 'src/apk_applet.h')
-rw-r--r-- | src/apk_applet.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/apk_applet.h b/src/apk_applet.h new file mode 100644 index 0000000..d243d65 --- /dev/null +++ b/src/apk_applet.h @@ -0,0 +1,27 @@ +/* apk_applet.h - Alpine Package Keeper (APK) + * + * Copyright (C) 2005-2008 Natanael Copa <n@tanael.org> + * Copyright (C) 2008 Timo Teräs <timo.teras@iki.fi> + * All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 as published + * by the Free Software Foundation. See http://www.gnu.org/ for details. + */ + +#ifndef APK_APPLET_H +#define APK_APPLET_H + +struct apk_applet { + const char *name; + const char *usage; + int (*main)(int argc, char **argv); +}; + +extern struct apk_applet *__start_apkapplets, *__stop_apkapplets; + +#define APK_DEFINE_APPLET(x) \ + static struct apk_applet *__applet_##x \ + __attribute__((__section__("apkapplets") used)) = &x; + +#endif |