apt-dater-0.9.0/0000755000175000017500000000000011761142645012760 5ustar thomasthomasapt-dater-0.9.0/ABOUT-NLS0000644000175000017500000022532611760757134014225 0ustar thomasthomas1 Notes on the Free Translation Project *************************************** Free software is going international! The Free Translation Project is a way to get maintainers of free software, translators, and users all together, so that free software will gradually become able to speak many languages. A few packages already provide translations for their messages. If you found this `ABOUT-NLS' file inside a distribution, you may assume that the distributed package does use GNU `gettext' internally, itself available at your nearest GNU archive site. But you do _not_ need to install GNU `gettext' prior to configuring, installing or using this package with messages translated. Installers will find here some useful hints. These notes also explain how users should proceed for getting the programs to use the available translations. They tell how people wanting to contribute and work on translations can contact the appropriate team. When reporting bugs in the `intl/' directory or bugs which may be related to internationalization, you should tell about the version of `gettext' which is used. The information can be found in the `intl/VERSION' file, in internationalized packages. 1.1 Quick configuration advice ============================== If you want to exploit the full power of internationalization, you should configure it using ./configure --with-included-gettext to force usage of internationalizing routines provided within this package, despite the existence of internationalizing capabilities in the operating system where this package is being installed. So far, only the `gettext' implementation in the GNU C library version 2 provides as many features (such as locale alias, message inheritance, automatic charset conversion or plural form handling) as the implementation here. It is also not possible to offer this additional functionality on top of a `catgets' implementation. Future versions of GNU `gettext' will very likely convey even more functionality. So it might be a good idea to change to GNU `gettext' as soon as possible. So you need _not_ provide this option if you are using GNU libc 2 or you have installed a recent copy of the GNU gettext package with the included `libintl'. 1.2 INSTALL Matters =================== Some packages are "localizable" when properly installed; the programs they contain can be made to speak your own native language. Most such packages use GNU `gettext'. Other packages have their own ways to internationalization, predating GNU `gettext'. By default, this package will be installed to allow translation of messages. It will automatically detect whether the system already provides the GNU `gettext' functions. If not, the included GNU `gettext' library will be used. This library is wholly contained within this package, usually in the `intl/' subdirectory, so prior installation of the GNU `gettext' package is _not_ required. Installers may use special options at configuration time for changing the default behaviour. The commands: ./configure --with-included-gettext ./configure --disable-nls will, respectively, bypass any pre-existing `gettext' to use the internationalizing routines provided within this package, or else, _totally_ disable translation of messages. When you already have GNU `gettext' installed on your system and run configure without an option for your new package, `configure' will probably detect the previously built and installed `libintl.a' file and will decide to use this. This might not be desirable. You should use the more recent version of the GNU `gettext' library. I.e. if the file `intl/VERSION' shows that the library which comes with this package is more recent, you should use ./configure --with-included-gettext to prevent auto-detection. The configuration process will not test for the `catgets' function and therefore it will not be used. The reason is that even an emulation of `gettext' on top of `catgets' could not provide all the extensions of the GNU `gettext' library. Internationalized packages usually have many `po/LL.po' files, where LL gives an ISO 639 two-letter code identifying the language. Unless translations have been forbidden at `configure' time by using the `--disable-nls' switch, all available translations are installed together with the package. However, the environment variable `LINGUAS' may be set, prior to configuration, to limit the installed set. `LINGUAS' should then contain a space separated list of two-letter codes, stating which languages are allowed. 1.3 Using This Package ====================== As a user, if your language has been installed for this package, you only have to set the `LANG' environment variable to the appropriate `LL_CC' combination. If you happen to have the `LC_ALL' or some other `LC_xxx' environment variables set, you should unset them before setting `LANG', otherwise the setting of `LANG' will not have the desired effect. Here `LL' is an ISO 639 two-letter language code, and `CC' is an ISO 3166 two-letter country code. For example, let's suppose that you speak German and live in Germany. At the shell prompt, merely execute `setenv LANG de_DE' (in `csh'), `export LANG; LANG=de_DE' (in `sh') or `export LANG=de_DE' (in `bash'). This can be done from your `.login' or `.profile' file, once and for all. You might think that the country code specification is redundant. But in fact, some languages have dialects in different countries. For example, `de_AT' is used for Austria, and `pt_BR' for Brazil. The country code serves to distinguish the dialects. The locale naming convention of `LL_CC', with `LL' denoting the language and `CC' denoting the country, is the one use on systems based on GNU libc. On other systems, some variations of this scheme are used, such as `LL' or `LL_CC.ENCODING'. You can get the list of locales supported by your system for your language by running the command `locale -a | grep '^LL''. Not all programs have translations for all languages. By default, an English message is shown in place of a nonexistent translation. If you understand other languages, you can set up a priority list of languages. This is done through a different environment variable, called `LANGUAGE'. GNU `gettext' gives preference to `LANGUAGE' over `LANG' for the purpose of message handling, but you still need to have `LANG' set to the primary language; this is required by other parts of the system libraries. For example, some Swedish users who would rather read translations in German than English for when Swedish is not available, set `LANGUAGE' to `sv:de' while leaving `LANG' to `sv_SE'. Special advice for Norwegian users: The language code for Norwegian bokma*l changed from `no' to `nb' recently (in 2003). During the transition period, while some message catalogs for this language are installed under `nb' and some older ones under `no', it's recommended for Norwegian users to set `LANGUAGE' to `nb:no' so that both newer and older translations are used. In the `LANGUAGE' environment variable, but not in the `LANG' environment variable, `LL_CC' combinations can be abbreviated as `LL' to denote the language's main dialect. For example, `de' is equivalent to `de_DE' (German as spoken in Germany), and `pt' to `pt_PT' (Portuguese as spoken in Portugal) in this context. 1.4 Translating Teams ===================== For the Free Translation Project to be a success, we need interested people who like their own language and write it well, and who are also able to synergize with other translators speaking the same language. Each translation team has its own mailing list. The up-to-date list of teams can be found at the Free Translation Project's homepage, `http://translationproject.org/', in the "Teams" area. If you'd like to volunteer to _work_ at translating messages, you should become a member of the translating team for your own language. The subscribing address is _not_ the same as the list itself, it has `-request' appended. For example, speakers of Swedish can send a message to `sv-request@li.org', having this message body: subscribe Keep in mind that team members are expected to participate _actively_ in translations, or at solving translational difficulties, rather than merely lurking around. If your team does not exist yet and you want to start one, or if you are unsure about what to do or how to get started, please write to `coordinator@translationproject.org' to reach the coordinator for all translator teams. The English team is special. It works at improving and uniformizing the terminology in use. Proven linguistic skills are praised more than programming skills, here. 1.5 Available Packages ====================== Languages are not equally supported in all packages. The following matrix shows the current state of internationalization, as of November 2007. The matrix shows, in regard of each package, for which languages PO files have been submitted to translation coordination, with a translation percentage of at least 50%. Ready PO files af am ar az be bg bs ca cs cy da de el en en_GB eo +----------------------------------------------------+ Compendium | [] [] [] [] | a2ps | [] [] [] [] [] | aegis | () | ant-phone | () | anubis | [] | ap-utils | | aspell | [] [] [] [] [] | bash | [] | bfd | | bibshelf | [] | binutils | | bison | [] [] | bison-runtime | [] | bluez-pin | [] [] [] [] [] | cflow | [] | clisp | [] [] [] | console-tools | [] [] | coreutils | [] [] [] [] | cpio | | cpplib | [] [] [] | cryptonit | [] | dialog | | diffutils | [] [] [] [] [] [] | doodle | [] | e2fsprogs | [] [] | enscript | [] [] [] [] | fetchmail | [] [] () [] [] | findutils | [] | findutils_stable | [] [] [] | flex | [] [] [] | fslint | | gas | | gawk | [] [] [] | gcal | [] | gcc | [] | gettext-examples | [] [] [] [] [] | gettext-runtime | [] [] [] [] [] | gettext-tools | [] [] | gip | [] | gliv | [] [] | glunarclock | [] | gmult | [] [] | gnubiff | () | gnucash | [] [] () () [] | gnuedu | | gnulib | [] | gnunet | | gnunet-gtk | | gnutls | [] | gpe-aerial | [] [] | gpe-beam | [] [] | gpe-calendar | | gpe-clock | [] [] | gpe-conf | [] [] | gpe-contacts | | gpe-edit | [] | gpe-filemanager | | gpe-go | [] | gpe-login | [] [] | gpe-ownerinfo | [] [] | gpe-package | | gpe-sketchbook | [] [] | gpe-su | [] [] | gpe-taskmanager | [] [] | gpe-timesheet | [] | gpe-today | [] [] | gpe-todo | | gphoto2 | [] [] [] [] | gprof | [] [] | gpsdrive | | gramadoir | [] [] | grep | [] [] | gretl | () | gsasl | | gss | | gst-plugins-bad | [] [] | gst-plugins-base | [] [] | gst-plugins-good | [] [] [] | gst-plugins-ugly | [] [] | gstreamer | [] [] [] [] [] [] [] | gtick | () | gtkam | [] [] [] [] | gtkorphan | [] [] | gtkspell | [] [] [] [] | gutenprint | [] | hello | [] [] [] [] [] | herrie | [] | hylafax | | idutils | [] [] | indent | [] [] [] [] | iso_15924 | | iso_3166 | [] [] [] [] [] [] [] [] [] [] [] | iso_3166_2 | | iso_4217 | [] [] [] | iso_639 | [] [] [] [] | jpilot | [] | jtag | | jwhois | | kbd | [] [] [] [] | keytouch | [] [] | keytouch-editor | [] | keytouch-keyboa... | [] | latrine | () | ld | [] | leafpad | [] [] [] [] [] | libc | [] [] [] [] | libexif | [] | libextractor | [] | libgpewidget | [] [] [] | libgpg-error | [] | libgphoto2 | [] [] | libgphoto2_port | [] [] | libgsasl | | libiconv | [] [] | libidn | [] [] [] | lifelines | [] () | lilypond | [] | lingoteach | | lprng | | lynx | [] [] [] [] | m4 | [] [] [] [] | mailfromd | | mailutils | [] | make | [] [] | man-db | [] [] [] | minicom | [] [] [] | nano | [] [] [] | opcodes | [] | parted | [] [] | pilot-qof | | popt | [] [] [] | psmisc | [] | pwdutils | | qof | | radius | [] | recode | [] [] [] [] [] [] | rpm | [] | screem | | scrollkeeper | [] [] [] [] [] [] [] [] | sed | [] [] [] | shared-mime-info | [] [] [] [] () [] [] [] | sharutils | [] [] [] [] [] [] | shishi | | skencil | [] () | solfege | | soundtracker | [] [] | sp | [] | system-tools-ba... | [] [] [] [] [] [] [] [] [] | tar | [] [] | texinfo | [] [] [] | tin | () () | tuxpaint | [] [] [] [] [] [] | unicode-han-tra... | | unicode-transla... | | util-linux | [] [] [] [] | util-linux-ng | [] [] [] [] | vorbis-tools | [] | wastesedge | () | wdiff | [] [] [] [] | wget | [] [] [] | xchat | [] [] [] [] [] [] [] | xkeyboard-config | [] | xpad | [] [] [] | +----------------------------------------------------+ af am ar az be bg bs ca cs cy da de el en en_GB eo 6 0 2 1 8 26 2 40 48 2 56 88 15 1 15 18 es et eu fa fi fr ga gl gu he hi hr hu id is it +--------------------------------------------------+ Compendium | [] [] [] [] [] | a2ps | [] [] [] () | aegis | | ant-phone | [] | anubis | [] | ap-utils | [] [] | aspell | [] [] [] | bash | [] | bfd | [] [] | bibshelf | [] [] [] | binutils | [] [] [] | bison | [] [] [] [] [] [] | bison-runtime | [] [] [] [] [] | bluez-pin | [] [] [] [] [] | cflow | [] | clisp | [] [] | console-tools | | coreutils | [] [] [] [] [] [] | cpio | [] [] [] | cpplib | [] [] | cryptonit | [] | dialog | [] [] [] | diffutils | [] [] [] [] [] [] [] [] [] | doodle | [] [] | e2fsprogs | [] [] [] | enscript | [] [] [] | fetchmail | [] | findutils | [] [] [] | findutils_stable | [] [] [] [] | flex | [] [] [] | fslint | | gas | [] [] | gawk | [] [] [] [] () | gcal | [] [] | gcc | [] | gettext-examples | [] [] [] [] [] [] [] | gettext-runtime | [] [] [] [] [] [] | gettext-tools | [] [] [] [] | gip | [] [] [] [] | gliv | () | glunarclock | [] [] [] | gmult | [] [] [] | gnubiff | () () | gnucash | () () () | gnuedu | [] | gnulib | [] [] [] | gnunet | | gnunet-gtk | | gnutls | | gpe-aerial | [] [] | gpe-beam | [] [] | gpe-calendar | | gpe-clock | [] [] [] [] | gpe-conf | [] | gpe-contacts | [] [] | gpe-edit | [] [] [] [] | gpe-filemanager | [] | gpe-go | [] [] [] | gpe-login | [] [] [] | gpe-ownerinfo | [] [] [] [] [] | gpe-package | [] | gpe-sketchbook | [] [] | gpe-su | [] [] [] [] | gpe-taskmanager | [] [] [] | gpe-timesheet | [] [] [] [] | gpe-today | [] [] [] [] | gpe-todo | [] | gphoto2 | [] [] [] [] [] | gprof | [] [] [] [] [] | gpsdrive | [] | gramadoir | [] [] | grep | [] [] [] | gretl | [] [] [] () | gsasl | [] [] | gss | [] [] | gst-plugins-bad | [] [] [] [] | gst-plugins-base | [] [] [] [] | gst-plugins-good | [] [] [] [] [] | gst-plugins-ugly | [] [] [] [] | gstreamer | [] [] [] | gtick | [] [] [] | gtkam | [] [] [] [] | gtkorphan | [] [] | gtkspell | [] [] [] [] [] [] [] | gutenprint | [] | hello | [] [] [] [] [] [] [] [] [] [] [] [] [] | herrie | [] | hylafax | | idutils | [] [] [] [] [] | indent | [] [] [] [] [] [] [] [] [] [] | iso_15924 | [] | iso_3166 | [] [] [] [] [] [] [] [] [] [] [] [] [] | iso_3166_2 | [] | iso_4217 | [] [] [] [] [] [] | iso_639 | [] [] [] [] [] [] | jpilot | [] [] | jtag | [] | jwhois | [] [] [] [] [] | kbd | [] [] | keytouch | [] [] [] | keytouch-editor | [] | keytouch-keyboa... | [] [] | latrine | [] [] | ld | [] [] [] [] | leafpad | [] [] [] [] [] [] | libc | [] [] [] [] [] | libexif | [] | libextractor | [] | libgpewidget | [] [] [] [] [] | libgpg-error | [] | libgphoto2 | [] [] [] | libgphoto2_port | [] [] | libgsasl | [] [] | libiconv | [] [] [] | libidn | [] [] | lifelines | () | lilypond | [] [] [] | lingoteach | [] [] [] | lprng | | lynx | [] [] [] | m4 | [] [] [] [] | mailfromd | | mailutils | [] [] | make | [] [] [] [] [] [] [] [] | man-db | [] | minicom | [] [] [] [] | nano | [] [] [] [] [] [] [] | opcodes | [] [] [] [] | parted | [] [] [] | pilot-qof | | popt | [] [] [] [] | psmisc | [] [] | pwdutils | | qof | [] | radius | [] [] | recode | [] [] [] [] [] [] [] [] | rpm | [] [] | screem | | scrollkeeper | [] [] [] | sed | [] [] [] [] [] | shared-mime-info | [] [] [] [] [] [] | sharutils | [] [] [] [] [] [] [] [] | shishi | [] | skencil | [] [] | solfege | [] | soundtracker | [] [] [] | sp | [] | system-tools-ba... | [] [] [] [] [] [] [] [] [] | tar | [] [] [] [] [] | texinfo | [] [] [] | tin | [] () | tuxpaint | [] [] | unicode-han-tra... | | unicode-transla... | [] [] | util-linux | [] [] [] [] [] [] [] | util-linux-ng | [] [] [] [] [] [] [] | vorbis-tools | | wastesedge | () | wdiff | [] [] [] [] [] [] [] [] | wget | [] [] [] [] [] [] [] [] | xchat | [] [] [] [] [] [] [] | xkeyboard-config | [] [] [] [] | xpad | [] [] [] | +--------------------------------------------------+ es et eu fa fi fr ga gl gu he hi hr hu id is it 85 22 14 2 48 101 61 12 2 8 2 6 53 29 1 52 ja ka ko ku ky lg lt lv mk mn ms mt nb ne nl nn +--------------------------------------------------+ Compendium | [] | a2ps | () [] [] | aegis | () | ant-phone | [] | anubis | [] [] [] | ap-utils | [] | aspell | [] [] | bash | [] | bfd | | bibshelf | [] | binutils | | bison | [] [] [] | bison-runtime | [] [] [] | bluez-pin | [] [] [] | cflow | | clisp | [] | console-tools | | coreutils | [] | cpio | [] | cpplib | [] | cryptonit | [] | dialog | [] [] | diffutils | [] [] [] | doodle | | e2fsprogs | [] | enscript | [] | fetchmail | [] [] | findutils | [] | findutils_stable | [] | flex | [] [] | fslint | | gas | | gawk | [] [] | gcal | | gcc | | gettext-examples | [] [] [] | gettext-runtime | [] [] [] | gettext-tools | [] [] | gip | [] [] | gliv | [] | glunarclock | [] [] | gmult | [] [] [] | gnubiff | | gnucash | () () () | gnuedu | | gnulib | [] [] | gnunet | | gnunet-gtk | | gnutls | [] | gpe-aerial | [] | gpe-beam | [] | gpe-calendar | [] | gpe-clock | [] [] [] | gpe-conf | [] [] [] | gpe-contacts | [] | gpe-edit | [] [] [] | gpe-filemanager | [] [] | gpe-go | [] [] [] | gpe-login | [] [] [] | gpe-ownerinfo | [] [] | gpe-package | [] [] | gpe-sketchbook | [] [] | gpe-su | [] [] [] | gpe-taskmanager | [] [] [] [] | gpe-timesheet | [] | gpe-today | [] [] | gpe-todo | [] | gphoto2 | [] [] | gprof | [] | gpsdrive | [] | gramadoir | () | grep | [] [] | gretl | | gsasl | [] | gss | | gst-plugins-bad | [] | gst-plugins-base | [] | gst-plugins-good | [] | gst-plugins-ugly | [] | gstreamer | [] | gtick | [] | gtkam | [] [] | gtkorphan | [] | gtkspell | [] [] | gutenprint | [] | hello | [] [] [] [] [] [] [] | herrie | [] | hylafax | | idutils | [] | indent | [] [] | iso_15924 | [] | iso_3166 | [] [] [] [] [] [] [] [] | iso_3166_2 | [] | iso_4217 | [] [] [] | iso_639 | [] [] [] [] | jpilot | () () | jtag | | jwhois | [] | kbd | [] | keytouch | [] | keytouch-editor | [] | keytouch-keyboa... | | latrine | [] | ld | | leafpad | [] [] | libc | [] [] [] | libexif | | libextractor | | libgpewidget | [] | libgpg-error | | libgphoto2 | [] | libgphoto2_port | [] | libgsasl | [] | libiconv | [] | libidn | [] [] | lifelines | [] | lilypond | [] | lingoteach | [] | lprng | | lynx | [] [] | m4 | [] [] | mailfromd | | mailutils | | make | [] [] [] | man-db | | minicom | [] | nano | [] [] [] | opcodes | [] | parted | [] [] | pilot-qof | | popt | [] [] [] | psmisc | [] [] [] | pwdutils | | qof | | radius | | recode | [] | rpm | [] [] | screem | [] | scrollkeeper | [] [] [] [] | sed | [] [] | shared-mime-info | [] [] [] [] [] [] [] | sharutils | [] [] | shishi | | skencil | | solfege | () () | soundtracker | | sp | () | system-tools-ba... | [] [] [] [] | tar | [] [] [] | texinfo | [] [] | tin | | tuxpaint | () [] [] | unicode-han-tra... | | unicode-transla... | | util-linux | [] [] | util-linux-ng | [] [] | vorbis-tools | | wastesedge | [] | wdiff | [] [] | wget | [] [] | xchat | [] [] [] [] | xkeyboard-config | [] [] [] | xpad | [] [] [] | +--------------------------------------------------+ ja ka ko ku ky lg lt lv mk mn ms mt nb ne nl nn 51 2 25 3 2 0 6 0 2 2 20 0 11 1 103 6 or pa pl pt pt_BR rm ro ru rw sk sl sq sr sv ta +--------------------------------------------------+ Compendium | [] [] [] [] [] | a2ps | () [] [] [] [] [] [] | aegis | () () | ant-phone | [] [] | anubis | [] [] [] | ap-utils | () | aspell | [] [] [] | bash | [] [] | bfd | | bibshelf | [] | binutils | [] [] | bison | [] [] [] [] [] | bison-runtime | [] [] [] [] [] | bluez-pin | [] [] [] [] [] [] [] [] [] | cflow | [] | clisp | [] | console-tools | [] | coreutils | [] [] [] [] | cpio | [] [] [] | cpplib | [] | cryptonit | [] [] | dialog | [] | diffutils | [] [] [] [] [] [] | doodle | [] [] | e2fsprogs | [] [] | enscript | [] [] [] [] [] | fetchmail | [] [] [] | findutils | [] [] [] | findutils_stable | [] [] [] [] [] [] | flex | [] [] [] [] [] | fslint | [] | gas | | gawk | [] [] [] [] | gcal | [] | gcc | [] [] | gettext-examples | [] [] [] [] [] [] [] [] | gettext-runtime | [] [] [] [] [] [] [] [] | gettext-tools | [] [] [] [] [] [] [] | gip | [] [] [] [] | gliv | [] [] [] [] [] [] | glunarclock | [] [] [] [] [] [] | gmult | [] [] [] [] | gnubiff | () [] | gnucash | () [] | gnuedu | | gnulib | [] [] [] | gnunet | | gnunet-gtk | [] | gnutls | [] [] | gpe-aerial | [] [] [] [] [] [] [] | gpe-beam | [] [] [] [] [] [] [] | gpe-calendar | [] [] [] [] | gpe-clock | [] [] [] [] [] [] [] [] | gpe-conf | [] [] [] [] [] [] [] | gpe-contacts | [] [] [] [] [] | gpe-edit | [] [] [] [] [] [] [] [] [] | gpe-filemanager | [] [] | gpe-go | [] [] [] [] [] [] [] [] | gpe-login | [] [] [] [] [] [] [] [] | gpe-ownerinfo | [] [] [] [] [] [] [] [] | gpe-package | [] [] | gpe-sketchbook | [] [] [] [] [] [] [] [] | gpe-su | [] [] [] [] [] [] [] [] | gpe-taskmanager | [] [] [] [] [] [] [] [] | gpe-timesheet | [] [] [] [] [] [] [] [] | gpe-today | [] [] [] [] [] [] [] [] | gpe-todo | [] [] [] [] | gphoto2 | [] [] [] [] [] [] | gprof | [] [] [] | gpsdrive | [] [] | gramadoir | [] [] | grep | [] [] [] [] | gretl | [] [] [] | gsasl | [] [] [] | gss | [] [] [] [] | gst-plugins-bad | [] [] [] | gst-plugins-base | [] [] | gst-plugins-good | [] [] | gst-plugins-ugly | [] [] [] | gstreamer | [] [] [] [] | gtick | [] | gtkam | [] [] [] [] [] | gtkorphan | [] | gtkspell | [] [] [] [] [] [] [] [] | gutenprint | [] | hello | [] [] [] [] [] [] [] [] | herrie | [] [] [] | hylafax | | idutils | [] [] [] [] [] | indent | [] [] [] [] [] [] [] | iso_15924 | | iso_3166 | [] [] [] [] [] [] [] [] [] [] [] [] [] | iso_3166_2 | | iso_4217 | [] [] [] [] [] [] [] | iso_639 | [] [] [] [] [] [] [] | jpilot | | jtag | [] | jwhois | [] [] [] [] | kbd | [] [] [] | keytouch | [] | keytouch-editor | [] | keytouch-keyboa... | [] | latrine | | ld | [] | leafpad | [] [] [] [] [] [] | libc | [] [] [] [] | libexif | [] [] | libextractor | [] [] | libgpewidget | [] [] [] [] [] [] [] [] | libgpg-error | [] [] [] | libgphoto2 | [] | libgphoto2_port | [] [] [] | libgsasl | [] [] [] [] | libiconv | [] [] [] | libidn | [] [] () | lifelines | [] [] | lilypond | | lingoteach | [] | lprng | [] | lynx | [] [] [] | m4 | [] [] [] [] [] | mailfromd | [] | mailutils | [] [] [] | make | [] [] [] [] | man-db | [] [] [] [] | minicom | [] [] [] [] [] | nano | [] [] [] [] | opcodes | [] [] | parted | [] | pilot-qof | | popt | [] [] [] [] | psmisc | [] [] | pwdutils | [] [] | qof | [] [] | radius | [] [] | recode | [] [] [] [] [] [] [] | rpm | [] [] [] [] | screem | | scrollkeeper | [] [] [] [] [] [] [] | sed | [] [] [] [] [] [] [] [] [] | shared-mime-info | [] [] [] [] [] [] | sharutils | [] [] [] [] | shishi | [] | skencil | [] [] [] | solfege | [] | soundtracker | [] [] | sp | | system-tools-ba... | [] [] [] [] [] [] [] [] [] | tar | [] [] [] [] | texinfo | [] [] [] [] | tin | () | tuxpaint | [] [] [] [] [] [] | unicode-han-tra... | | unicode-transla... | | util-linux | [] [] [] [] | util-linux-ng | [] [] [] [] | vorbis-tools | [] | wastesedge | | wdiff | [] [] [] [] [] [] [] | wget | [] [] [] [] | xchat | [] [] [] [] [] [] [] | xkeyboard-config | [] [] [] | xpad | [] [] [] | +--------------------------------------------------+ or pa pl pt pt_BR rm ro ru rw sk sl sq sr sv ta 0 5 77 31 53 4 58 72 3 45 46 9 45 122 3 tg th tk tr uk ven vi wa xh zh_CN zh_HK zh_TW zu +---------------------------------------------------+ Compendium | [] [] [] [] | 19 a2ps | [] [] [] | 19 aegis | [] | 1 ant-phone | [] [] | 6 anubis | [] [] [] | 11 ap-utils | () [] | 4 aspell | [] [] [] | 16 bash | [] | 6 bfd | | 2 bibshelf | [] | 7 binutils | [] [] [] [] | 9 bison | [] [] [] [] | 20 bison-runtime | [] [] [] [] | 18 bluez-pin | [] [] [] [] [] [] | 28 cflow | [] [] | 5 clisp | | 9 console-tools | [] [] | 5 coreutils | [] [] [] | 18 cpio | [] [] [] [] | 11 cpplib | [] [] [] [] [] | 12 cryptonit | [] | 6 dialog | [] [] [] | 9 diffutils | [] [] [] [] [] | 29 doodle | [] | 6 e2fsprogs | [] [] | 10 enscript | [] [] [] | 16 fetchmail | [] [] | 12 findutils | [] [] [] | 11 findutils_stable | [] [] [] [] | 18 flex | [] [] | 15 fslint | [] | 2 gas | [] | 3 gawk | [] [] [] | 16 gcal | [] | 5 gcc | [] [] [] | 7 gettext-examples | [] [] [] [] [] [] | 29 gettext-runtime | [] [] [] [] [] [] | 28 gettext-tools | [] [] [] [] [] | 20 gip | [] [] | 13 gliv | [] [] | 11 glunarclock | [] [] [] | 15 gmult | [] [] [] [] | 16 gnubiff | [] | 2 gnucash | () [] | 5 gnuedu | [] | 2 gnulib | [] | 10 gnunet | | 0 gnunet-gtk | [] [] | 3 gnutls | | 4 gpe-aerial | [] [] | 14 gpe-beam | [] [] | 14 gpe-calendar | [] [] | 7 gpe-clock | [] [] [] [] | 21 gpe-conf | [] [] [] | 16 gpe-contacts | [] [] | 10 gpe-edit | [] [] [] [] [] | 22 gpe-filemanager | [] [] | 7 gpe-go | [] [] [] [] | 19 gpe-login | [] [] [] [] [] | 21 gpe-ownerinfo | [] [] [] [] | 21 gpe-package | [] | 6 gpe-sketchbook | [] [] | 16 gpe-su | [] [] [] [] | 21 gpe-taskmanager | [] [] [] [] | 21 gpe-timesheet | [] [] [] [] | 18 gpe-today | [] [] [] [] [] | 21 gpe-todo | [] [] | 8 gphoto2 | [] [] [] [] | 21 gprof | [] [] | 13 gpsdrive | [] | 5 gramadoir | [] | 7 grep | [] | 12 gretl | | 6 gsasl | [] [] [] | 9 gss | [] | 7 gst-plugins-bad | [] [] [] | 13 gst-plugins-base | [] [] | 11 gst-plugins-good | [] [] [] [] [] | 16 gst-plugins-ugly | [] [] [] | 13 gstreamer | [] [] [] | 18 gtick | [] [] | 7 gtkam | [] | 16 gtkorphan | [] | 7 gtkspell | [] [] [] [] [] [] | 27 gutenprint | | 4 hello | [] [] [] [] [] | 38 herrie | [] [] | 8 hylafax | | 0 idutils | [] [] | 15 indent | [] [] [] [] [] | 28 iso_15924 | [] [] | 4 iso_3166 | [] [] [] [] [] [] [] [] [] | 54 iso_3166_2 | [] [] | 4 iso_4217 | [] [] [] [] [] | 24 iso_639 | [] [] [] [] [] | 26 jpilot | [] [] [] [] | 7 jtag | [] | 3 jwhois | [] [] [] | 13 kbd | [] [] [] | 13 keytouch | [] | 8 keytouch-editor | [] | 5 keytouch-keyboa... | [] | 5 latrine | [] [] | 5 ld | [] [] [] [] | 10 leafpad | [] [] [] [] [] | 24 libc | [] [] [] | 19 libexif | [] | 5 libextractor | [] | 5 libgpewidget | [] [] [] | 20 libgpg-error | [] | 6 libgphoto2 | [] [] | 9 libgphoto2_port | [] [] [] | 11 libgsasl | [] | 8 libiconv | [] [] | 11 libidn | [] [] | 11 lifelines | | 4 lilypond | [] | 6 lingoteach | [] | 6 lprng | [] | 2 lynx | [] [] [] | 15 m4 | [] [] [] | 18 mailfromd | [] [] | 3 mailutils | [] [] | 8 make | [] [] [] | 20 man-db | [] | 9 minicom | [] | 14 nano | [] [] [] | 20 opcodes | [] [] | 10 parted | [] [] [] | 11 pilot-qof | [] | 1 popt | [] [] [] [] | 18 psmisc | [] [] | 10 pwdutils | [] | 3 qof | [] | 4 radius | [] [] | 7 recode | [] [] [] | 25 rpm | [] [] [] [] | 13 screem | [] | 2 scrollkeeper | [] [] [] [] | 26 sed | [] [] [] [] | 23 shared-mime-info | [] [] [] | 29 sharutils | [] [] [] | 23 shishi | [] | 3 skencil | [] | 7 solfege | [] | 3 soundtracker | [] [] | 9 sp | [] | 3 system-tools-ba... | [] [] [] [] [] [] [] | 38 tar | [] [] [] | 17 texinfo | [] [] [] | 15 tin | | 1 tuxpaint | [] [] [] | 19 unicode-han-tra... | | 0 unicode-transla... | | 2 util-linux | [] [] [] | 20 util-linux-ng | [] [] [] | 20 vorbis-tools | [] [] | 4 wastesedge | | 1 wdiff | [] [] | 23 wget | [] [] [] | 20 xchat | [] [] [] [] | 29 xkeyboard-config | [] [] [] | 14 xpad | [] [] [] | 15 +---------------------------------------------------+ 76 teams tg th tk tr uk ven vi wa xh zh_CN zh_HK zh_TW zu 163 domains 0 3 1 74 51 0 143 21 1 57 7 45 0 2036 Some counters in the preceding matrix are higher than the number of visible blocks let us expect. This is because a few extra PO files are used for implementing regional variants of languages, or language dialects. For a PO file in the matrix above to be effective, the package to which it applies should also have been internationalized and distributed as such by its maintainer. There might be an observable lag between the mere existence a PO file and its wide availability in a distribution. If November 2007 seems to be old, you may fetch a more recent copy of this `ABOUT-NLS' file on most GNU archive sites. The most up-to-date matrix with full percentage details can be found at `http://translationproject.org/extra/matrix.html'. 1.6 Using `gettext' in new packages =================================== If you are writing a freely available program and want to internationalize it you are welcome to use GNU `gettext' in your package. Of course you have to respect the GNU Library General Public License which covers the use of the GNU `gettext' library. This means in particular that even non-free programs can use `libintl' as a shared library, whereas only free software can use `libintl' as a static library or use modified versions of `libintl'. Once the sources are changed appropriately and the setup can handle the use of `gettext' the only thing missing are the translations. The Free Translation Project is also available for packages which are not developed inside the GNU project. Therefore the information given above applies also for every other Free Software Project. Contact `coordinator@translationproject.org' to make the `.pot' files available to the translation teams. apt-dater-0.9.0/AUTHORS0000644000175000017500000000032311760757134014032 0ustar thomasthomasapt-dater ========= Andre Ellguth * main programmer * maintainer Thomas Liske * main programmer * maintainer Jens Haser * fixed some UI glitches apt-dater-0.9.0/COPYING0000644000175000017500000004312211760757134014021 0ustar thomasthomas GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. , 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Library General Public License instead of this License. apt-dater-0.9.0/ChangeLog0000644000175000017500000002454311761137633014543 0ustar thomasthomasapt-dater (0.9.0) unstable; urgency=low * Add 'failure diagnostic' screen. (Closes Debian Bug#646902 by Markus Raab) * Document ErrPattern statement in apt-dater.conf. (Closes SF Bug by Herman van Rink) * Remove depreciated Tcl_Interp access (required for Tcl8.6+). * Include config.h before using HAVE_LOCALE_H (provided by Patrick Matthäi). * New feature: cluster support (README.clusters) * Sync to apt-dater-host 0.9.0-adp0.6: - cluster support - depend on ImVirt.pm on Debian -- Thomas Liske Tue, 29 May 2012 14:22:41 +0200 apt-dater (0.8.6) stable; urgency=low * zypper: - Fixed: zypper did not report any updates (reported by Ivan De Masi). - Use 'zypper refresh' for refreshing package repositories. * Add RELEASE header to version string on RPM queries. * Update apt-dater.conf man page. * Fix two hardening compile warnings (provided by Patrick Matthäi). * Include locale.h if available. (Closes Debian Bug#642696 by Mònica Ramírez Arceda) * Use apt-get as default package manager. (Closes Debian Bug#635048 by Felix Bartels) * Add dummy man page apt-dater-host.1 (contributed by Patrick Matthäi). -- Thomas Liske Tue, 27 Sep 2011 15:37:03 +0200 apt-dater (0.8.5) unstable; urgency=low * Fixed a key mismatch in the history view. * Fixed a selector positioning bug. * Don't use sudo on apt-dater-host status w/ aptitude. (Fixes Debian Bug#596723 by "chrysn") * Configure should check if popt.h is available. (Closes SF Bug#3045502 by Henri Salo) * Drop "[screen] enabled" config option, it doesn't work any more. (Reported by Daniel Baumann due Debian Bug#597941) * Fix unknown yum based hosts (reported on Fedora) due bad package status interpretation. (Reported by Patrick Matthäi) * Some pedantic stuff (use long options for aptitude and apt-get to ease code reading). Don't fail on untrusted/unauthenticated packages when checking for upgrades (still check for the upgrade itself). (Contributed by Mathieu PARENT due SF Bug#3158198) * Check for updates (refresh) using dist-upgrade. This show ABI-incompatible upgrades (like the recent bind9 one: http://www.debian.org/security/2010/dsa-2130.en.html). (Contributed by Mathieu PARENT due SF Bug#3158198) * Make upgrade method customizable. (Inspired by Mathieu PARENT due SF Bug#3158198) * Fixed a key mismatch in the history view. * Fixed a selector positioning bug. * Allow apt-dater-host to be used with ssh keys. (Inspired by 'Chromosom' due SF Bug#2862139) -- Andre Ellguth Tue, 01 Feb 2011 09:04:25 +0100 apt-dater (0.8.4) unstable; urgency=low * Add UUID host field to report output. * Don't fail if apt-dater-host could not get the installed kernel packages; fallback to unknown reboot status. (Closes SF Bug#2991717 by Karoly Molnar) * Use $DPKGTOOL to detect packages with updates. (Contributed by Alexandre Anriot) * Update german localization. -- Andre Ellguth Mon, 05 Jul 2010 12:51:58 +0200 apt-dater (0.8.3) unstable; urgency=low * Parameters on 'apt-dater-host install' must not be interpreted by the shell, thanks to Henri Salo. * Remove obsolete DefaultUser/DefaultPort lines from conf/apt-dater.conf.example. (Closes SF Bug#2946417 by Mathieu PARENT) * Handle fwrite return values in keyfiles.c. * Add apt-dater-host zypper version (using zypper in rug compatibility mode). (Contributed by Chris Liles) * Detect screen's socket path during configure. (Closes SF Bug#2950721 by Chris Liles) * Add .spec files for rpm packaging. * Add '-o Aptitude::Delete-Unused=false' to aptitude safe-upgrade calls. (Contributed by Patrick Matthäi) -- Andre Ellguth Mon, 29 Mar 2010 08:35:03 +0200 apt-dater (0.8.2) unstable; urgency=low * Fix apt-dater not working on PPC (Closes Debian Bug#563159 by Gefried Fuchs; thanks to Simon Richter). * Fix hotkey l for expanding not working (Closes Debian Bug#564450 by Gefried Fuchs) * Fix pressing C for file transfer gives error message (Closes Debian Bug#564459 by Gefried Fuchs) The SFTPCmd config parameter should be set to /usr/bin/sftp - the old default value does not work any more. * Fix translated confirmation questions. (Closes Debian Bug#565931 by Patrick Matthäi). * Fix Debian hosts got 'Unknown' if the had upgrades which depends on broken packages. * apt-dater-host: add --assume-yes on safe-upgrade as suggested by Stephan Sürken. This is now default but could disabled in the apt-dater-host.conf file. (Closes Debian Bug#565930) * Fix German localisation typos. (Closes SF Bug#2941509 by Micha vor dem Berge) * Fix Debian hosts become 'Unknown' if they hadn't a stock Debian kernel installed. (Closes SF Bug#2933741 by alma@arwin.hu) -- Andre Ellguth Wed, 03 Feb 2010 15:27:39 +0100 apt-dater (0.8.1) unstable; urgency=low * Add hooks on connect/install/refresh/upgrade. * Run external commands via shell script helper. * Add host history data to XML reports. * Add -n command line argument (report w/o refresh). * Extended tagging by host flags. * Fixes: - upgrade & install on filtered categories - pass --as-needed to ld - minor ui glitches (no more flicker) * Add Italian translation - contributed by Milo Casagrande . * Drop DefaultUser and DefaultPort configuration. If a host has no username or port given, let ssh select the right one. (Closes Debian Bug#559366 by "chrysn") * Update adproto to version 0.5. -- Andre Ellguth Fri, 18 Dec 2009 13:39:52 +0100 apt-dater (0.8.0) unstable; urgency=low * Add gettext support. * Hosts can now be tagged (like in mutt). * Support mutt like navigation. * Add uname fields to apt-dater-host proto. * Apply 01-aptitude_safe-upgrade.dpatch from Debian. * Improve auto refresh feature. * History feature (record ssh session with script). * Remove "Status file missing" category ("Unkown" is used instead). * apt-dater-host (debian/yum): optional cleanup after install/upgrade * apt-dater-host protocol 0.3: - broken packages support * Debug feature (adds some assertions to the code). * Fixes: - KERNELINFO status flag on Debian Lenny - documentation - set FD_CLOEXEC on lockfiles - don't use hardcoded screen dump filenames - reduce CPU cycles use by refreshing the screen more than needed - don't pass MAINTAINER on commandline, use SSH's SendEnv/AcceptEnv instead (Debian Bug#529200 by Alexander Barton) - set LC_ALL=C on apt-dater-host rather than clear LANG env variable (SF bug #2786495 by Sebastian Heinlein and #2793663 by "kepi") -- Thomas Liske Tue, 26 May 2009 16:31:41 +0200 apt-dater (0.7.0) unstable; urgency=low * New auto refresh feature * Improved search function * Improved more info page * Basic WUA client * Removed memory leak -- Andre Ellguth Wed, 21 Jan 2009 15:17:18 +0100 apt-dater (0.6.4) unstable; urgency=low * Fixed sf bugs #2308347, #2308369, #2308370 * Add host details window. -- Andre Ellguth Tue, 25 Nov 2008 15:11:55 +0100 apt-dater (0.6.3) unstable; urgency=low * The getnLine() function can now handle a input of 4096 characters. * Added support for ssh identity file per group. * Add new VIRT line to apt-dater-host protocol. -- Andre Ellguth Mon, 17 Nov 2008 15:59:30 +0100 apt-dater (0.6.2) unstable; urgency=low * Fixed 2 bugs in the dump screen function. * Add RPM only apt-dater-host script. -- Andre Ellguth Fri, 08 Aug 2008 15:19:47 +0200 apt-dater (0.6.1) unstable; urgency=low * Fixed some bugs in the search function * Changes in the XML report: - Renamed root element - Supply DTD file - Added another XSLT sample -- Andre Ellguth Tue, 05 Aug 2008 11:14:42 +0200 apt-dater (0.6.0) unstable; urgency=low * New feature: TCL host filter function (README.tclfilter) * New feature: XML report function (apt-dater -r) * A better character input function -- Andre Ellguth Tue, 29 Jul 2008 16:38:10 +0200 apt-dater (0.5.8) unstable; urgency=medium * Terminal resize handler works now correctly. * Added the scrolling function to the help page. * Global definition of control and function keys. * Preparations for TCL host filters. -- Andre Ellguth Wed, 23 Jul 2008 16:16:58 +0200 apt-dater (0.5.7-ibh1) unstable; urgency=medium * Fixed a bug in apt-dater-host which let it die on Debian Etch. -- Thomas Liske Mon, 21 Jul 2008 19:31:06 +0200 apt-dater (0.5.7) unstable; urgency=low * Fixed some bugs in the status file detection. -- Andre Ellguth Mon, 21 Jul 2008 16:49:40 +0200 apt-dater (0.5.6) unstable; urgency=low * Fixed a bug in the lock function. -- Andre Ellguth Thu, 17 Jul 2008 15:24:05 +0200 apt-dater (0.5.5.1) unstable; urgency=low * Added lsb-release as debian package dependency * Check if the LSBREL status information is empty -- Andre Ellguth Wed, 16 Jul 2008 16:58:32 +0200 apt-dater (0.5.5) unstable; urgency=low * Added support for rug, yum based distributions. * New additional informations (lsb_release, kernel release). -- Andre Ellguth Wed, 16 Jul 2008 16:58:32 +0200 apt-dater (0.5.4) unstable; urgency=low * New upstream version -- Andre Ellguth Mon, 14 Jul 2008 15:40:42 +0200 apt-dater (0.5.3-ibh1) unstable; urgency=low * Fix typo in apt-dater-host preventing 'apt-dater-host install' to work. -- Thomas Liske Thu, 10 Jul 2008 10:48:27 +0200 apt-dater (0.5.3) unstable; urgency=low * added generic apt/aptitude interface in apt-dater-host (still needed some work to support non-dpkg-based systems) -- Thomas Liske Wed, 09 Jul 2008 09:37:42 +0200 apt-dater (0.5.2) unstable; urgency=low * Added apt-dater.conf manpage. * Fixed some locking issues. -- Thomas Liske Tue, 08 Jul 2008 09:38:32 +0200 apt-dater (0.5.1) unstable; urgency=low * Documentation fixes. -- Thomas Liske Fri, 04 Jul 2008 14:50:34 +0200 apt-dater (0.5.0) unstable; urgency=low * Initial Release. -- Thomas Liske Thu, 3 Jul 2008 13:56:44 +0200 apt-dater-0.9.0/INSTALL0000644000175000017500000002243211760757134014020 0ustar thomasthomasInstallation Instructions ************************* Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free Software Foundation, Inc. This file is free documentation; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. Basic Installation ================== These are generic installation instructions. The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses those values to create a `Makefile' in each directory of the package. It may also create one or more `.h' files containing system-dependent definitions. Finally, it creates a shell script `config.status' that you can run in the future to recreate the current configuration, and a file `config.log' containing compiler output (useful mainly for debugging `configure'). It can also use an optional file (typically called `config.cache' and enabled with `--cache-file=config.cache' or simply `-C') that saves the results of its tests to speed up reconfiguring. (Caching is disabled by default to prevent problems with accidental use of stale cache files.) If you need to do unusual things to compile the package, please try to figure out how `configure' could check whether to do them, and mail diffs or instructions to the address given in the `README' so they can be considered for the next release. If you are using the cache, and at some point `config.cache' contains results you don't want to keep, you may remove or edit it. The file `configure.ac' (or `configure.in') is used to create `configure' by a program called `autoconf'. You only need `configure.ac' if you want to change it or regenerate `configure' using a newer version of `autoconf'. The simplest way to compile this package is: 1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. If you're using `csh' on an old version of System V, you might need to type `sh ./configure' instead to prevent `csh' from trying to execute `configure' itself. Running `configure' takes awhile. While running, it prints some messages telling which features it is checking for. 2. Type `make' to compile the package. 3. Optionally, type `make check' to run any self-tests that come with the package. 4. Type `make install' to install the programs and any data files and documentation. 5. You can remove the program binaries and object files from the source code directory by typing `make clean'. To also remove the files that `configure' created (so you can compile the package for a different kind of computer), type `make distclean'. There is also a `make maintainer-clean' target, but that is intended mainly for the package's developers. If you use it, you may have to get all sorts of other programs in order to regenerate files that came with the distribution. Compilers and Options ===================== Some systems require unusual options for compilation or linking that the `configure' script does not know about. Run `./configure --help' for details on some of the pertinent environment variables. You can give `configure' initial values for configuration parameters by setting variables in the command line or in the environment. Here is an example: ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix *Note Defining Variables::, for more details. Compiling For Multiple Architectures ==================================== You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you must use a version of `make' that supports the `VPATH' variable, such as GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'. If you have to use a `make' that does not support the `VPATH' variable, you have to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use `make distclean' before reconfiguring for another architecture. Installation Names ================== By default, `make install' installs the package's commands under `/usr/local/bin', include files under `/usr/local/include', etc. You can specify an installation prefix other than `/usr/local' by giving `configure' the option `--prefix=PREFIX'. You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you pass the option `--exec-prefix=PREFIX' to `configure', the package uses PREFIX as the prefix for installing programs and libraries. Documentation and other data files still use the regular prefix. In addition, if you use an unusual directory layout you can give options like `--bindir=DIR' to specify different values for particular kinds of files. Run `configure --help' for a list of the directories you can set and what kinds of files go in them. If the package supports it, you can cause programs to be installed with an extra prefix or suffix on their names by giving `configure' the option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. Optional Features ================= Some packages pay attention to `--enable-FEATURE' options to `configure', where FEATURE indicates an optional part of the package. They may also pay attention to `--with-PACKAGE' options, where PACKAGE is something like `gnu-as' or `x' (for the X Window System). The `README' should mention any `--enable-' and `--with-' options that the package recognizes. For packages that use the X Window System, `configure' can usually find the X include and library files automatically, but if it doesn't, you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations. Specifying the System Type ========================== There may be some features `configure' cannot figure out automatically, but needs to determine by the type of machine the package will run on. Usually, assuming the package is built to be run on the _same_ architectures, `configure' can figure that out, but if it prints a message saying it cannot guess the machine type, give it the `--build=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name which has the form: CPU-COMPANY-SYSTEM where SYSTEM can have one of these forms: OS KERNEL-OS See the file `config.sub' for the possible values of each field. If `config.sub' isn't included in this package, then this package doesn't need to know the machine type. If you are _building_ compiler tools for cross-compiling, you should use the option `--target=TYPE' to select the type of system they will produce code for. If you want to _use_ a cross compiler, that generates code for a platform different from the build platform, you should specify the "host" platform (i.e., that on which the generated programs will eventually be run) with `--host=TYPE'. Sharing Defaults ================ If you want to set default values for `configure' scripts to share, you can create a site shell script called `config.site' that gives default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. A warning: not all `configure' scripts look for a site script. Defining Variables ================== Variables not defined in a site shell script can be set in the environment passed to `configure'. However, some packages may run configure again during the build, and the customized values of these variables may be lost. In order to avoid this problem, you should set them in the `configure' command line, using `VAR=value'. For example: ./configure CC=/usr/local2/bin/gcc causes the specified `gcc' to be used as the C compiler (unless it is overridden in the site shell script). Here is a another example: /bin/bash ./configure CONFIG_SHELL=/bin/bash Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent configuration-related scripts to be executed by `/bin/bash'. `configure' Invocation ====================== `configure' recognizes the following options to control how it operates. `--help' `-h' Print a summary of the options to `configure', and exit. `--version' `-V' Print the version of Autoconf used to generate the `configure' script, and exit. `--cache-file=FILE' Enable the cache: use and save the results of the tests in FILE, traditionally `config.cache'. FILE defaults to `/dev/null' to disable caching. `--config-cache' `-C' Alias for `--cache-file=config.cache'. `--quiet' `--silent' `-q' Do not print messages saying which checks are being made. To suppress all normal output, redirect it to `/dev/null' (any error messages will still be shown). `--srcdir=DIR' Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically. `configure' also accepts some other, not widely useful, options. Run `configure --help' for more details. apt-dater-0.9.0/Makefile.am0000644000175000017500000000231511761141340015004 0ustar thomasthomasSUBDIRS = po man src lib AUTOMAKE_OPTIONS = \ 1.9 \ dist-bzip2 distclean-local: rm -rf *.cache *~ .project .settings .cdtproject ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = config.rpath m4/ChangeLog mkinstalldirs check-gettext: @if test x$(USE_NLS) != "xyes" ; then echo "Missing gettext. Rerun configure and check for" \ "'checking whether to use NLS... yes'!" ; exit 1 ; fi update-po: check-gettext @find $(srcdir)/src/ -name "*.c" -print | sort > $(srcdir)/po/POTFILES.in.2 ; \ if diff $(srcdir)/po/POTFILES.in $(srcdir)/po/POTFILES.in.2 >/dev/null 2>&1 ; then \ rm -f $(srcdir)/po/POTFILES.in.2 ; \ else \ mv $(srcdir)/po/POTFILES.in.2 $(srcdir)/po/POTFILES.in ; \ fi cd po && $(MAKE) $(AM_MAKEFLAGS) update-po update-gmo: check-gettext cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo: check-gettext touch po/*.po cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo-%: check-gettext @language=`echo $@ | sed s/force-update-gmo-//` ; \ if test ! -f po/$$language.po ; then echo "file po/$$language.po does not exist" ; exit 1 ; fi ; \ touch po/$$language.po ; \ cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo .PHONY: check-gettext update-po update-gmo force-update-gmo apt-dater-0.9.0/NEWS0000644000175000017500000000000011760757134013451 0ustar thomasthomasapt-dater-0.9.0/README0000644000175000017500000000200711760757134013643 0ustar thomasthomasREADME for apt-dater ==================== With apt-dater you can easily keep one ore more (Debian) GNU/Linux hosts up to date. Pre-configuration on your management server: Copy and modify the apt-dater.conf: cp conf/apt-dater.conf.example $HOME/.config/apt-dater/apt-dater.conf Copy and modify the hosts.conf: cp conf/hosts.conf.example $HOME/.config/apt-dater/hosts.conf Copy and modify the screenrc: cp conf/screenrc.example $HOME/.config/apt-dater/screenrc Managed hosts by apt-dater: You need a SSH server and sudo installed. Create a user which will be used to install updates (using root is NOT recommended). Modify the /etc/sudoers: Defaults env_reset,env_keep=MAINTAINER the-user ALL=NOPASSWD: /usr/bin/apt-get, /usr/bin/aptitude Management server: Create a user on your management server which perform updates on your Debian hosts. Generate a SSH keypair: ssh-keygen [-t TYPE] Distribute the public key(s) e.g.: ssh-copy-id -i ~/.ssh/your-public-key managed-host apt-dater-0.9.0/README.autoref0000644000175000017500000000163211760757134015312 0ustar thomasthomasAuto Refresh ============ Since version 0.6.5, apt-dater has a 'auto refresh' feature. This gives two advantages: * If one host is refreshed and got some updates, one should refresh other hosts which are running the same distribution and have the same (or atleast some) packages installed, too. * There are some fundamental problems on replay attacks on todays package managers[1]. If one has several hosts (using different repository mirrors and different uplinks etc.), there is a chance that some of your hosts got recent package lists. apt-dater collects update informations over SSH on trusted hosts. If apt-dater compares those information it could detect such replay attacks. Links ===== [1] Attacks on Package Managers (Justin Cappos, Justin Samuel, Scott Baker, John H. Hartman) http://www.cs.arizona.edu/people/justin/packagemanagersecurity/attacks-on-package-managers.html apt-dater-0.9.0/README.clusters0000644000175000017500000000136511760757134015514 0ustar thomasthomasClusters ======== Since version 0.9.0, apt-dater has special support of cluster hosts - apt-dater can be configured to do not install updates on hosts part of a cluster simultaneously. You need to specify a symbolic name of the cluster on each cluster in /etc/apt-dater-host.conf: # If this host is part of (multiple) cluster(s), you might set a # symbolic name. Hosts with the same cluster name won't be upgraded # simultaneously by apt-dater (requires apt-dater 0.9 or above). @CLUSTERS = qw(my-db-cluster); The cluster name should be unique. Hosts may be part of multiple clusters (or cluster resources). This feature requires the lockfile-progs or procmail package. apt-dater uses their lockfile(-create|-remove) commands to realize mutexing. apt-dater-0.9.0/README.history0000644000175000017500000000013411760757134015342 0ustar thomasthomasHistory ======= apt-dater could use `script' from the bsdutils package to record sessions. apt-dater-0.9.0/README.hooks0000644000175000017500000000256411760757134014775 0ustar thomasthomasHooks ===== Since version 0.8.1, apt-dater can call hooks before and after doing an action on a host. Hooks executables are located in: +---------+---------------------------+ | action | path | +---------+---------------------------+ | connect | /etc/apt-dater/pre-con.d | | | /etc/apt-dater/post-con.d | | install | /etc/apt-dater/pre-ins.d | | | /etc/apt-dater/post-ins.d | | refresh | /etc/apt-dater/pre-ref.d | | | /etc/apt-dater/post-ref.d | | update | /etc/apt-dater/pre-upd.d | | | /etc/apt-dater/post-upd.d | +---------+---------------------------+ The executables are run by run-parts(8). The environment contains informations about the action, the host and the configuration of apt-dater. action: AD_ACTION AD_PARAM host data: AD_HIST_PATH AD_HOSTNAME AD_GROUP AD_SSH_ID AD_SSH_PORT AD_SSH_USER AD_STATSFILE AD_KERNEL AD_LSB_DISTRI AD_LSB_RELEASE AD_LSB_CODENAME AD_UNAME_KERNEL AD_UNAME_MACHINE AD_UUID AD_VIRT apt-dater configuration: AD_CMD_INSTALL AD_CMD_REFRESH AD_CMD_UPGRADE AD_HIST_ERRPATTERN AD_HIST_RECORD AD_HOOK_POST_CONNECT AD_HOOK_POST_INSTALL AD_HOOK_POST_REFRESH AD_HOOK_POST_UPDATE AD_HOOK_PRE_CONNECT AD_HOOK_PRE_INSTALL AD_HOOK_PRE_REFRESH AD_HOOK_PRE_UPDATE AD_HOSTSFILE AD_SCREENRCFILE AD_SFTP_CMD AD_SSH_CMD AD_SSH_OPTFLAGS AD_STATSDIR AD_CLUSTERS AD_CLUSTER%d apt-dater-0.9.0/README.tagging0000644000175000017500000000201611760757134015262 0ustar thomasthomasHost tagging ============ apt-dater has a 'tagging' feature like the MUA mutt (a poor man's host filter ;). Usage ===== You can tag or untag a single host by pressing the `t' key. Tag multiple hosts matching a pattern by pressing the `T' key. Hosts can be untagged by a pattern using the Ctrl + `T' key combination. The pattern is a regular expression matching the hostname. The pattern might be pretended by a tokens to apply the regex on the following host's values: ~c codename ~d distributor ~f host flags ~g group ~p package ~u update ~A all hosts After you have done your selection you can do some actions with the tagged hosts by pressing the `;' key: ; i install a package ; g refresh the hosts ; u upgrade the hosts w/ pending updates Examples ======== Tag all hosts which have installed the package apt-dater-host: ~p apt-dater-host Tag all hosts which are start with the word inet in their hostname: ^inet Tag all hosts which have set the flag `x' and `R': ~f xR apt-dater-0.9.0/README.tclfilter0000644000175000017500000000411711760757134015636 0ustar thomasthomasTCL Filter ========== Since version 0.5.9, apt-dater can be configured with TCL filter support. This feature is disabled by default, enable it with configure: $ ./configure --enable-tclfilter You need a recent TCL version installed to succeed, the Debian packages have TCL filter support enabled. Usage ===== TCL filters can be used to group hosts by your own filter definition. For each host configured, apt-dater evals your TCL filter and adds the host to the category "Filtered" in the main screen if the return value is non-zero. If you have a large number of hosts, it becomes hard i.e. to find out which hosts have a certain package installed/running an obsolete release... . TCL filter helps to filter alle hosts by such conditions. Variables ========= Before evaluating a TCL filter expression for a host, apt-dater sets the following variables in the TCL environment: -------------+------------------------------------------------------- Variable | Description -------------+------------------------------------------------------- $cat | category index (0=Updates pending, 1=Up to date, ...) $group | name of the group the hosts belongs to $hostname | hostname $kernel | kernel release (uname -r) $lsb_cname | "Codename"-field of lsb_release -a $lsb_distri | "Release"-field of lsb_release -a $lsb_rel | "Distributer ID"-field of lsb_release -a $extras | array of extra packages $flags | array of host flags (h x R K) $holds | array of packages hold back $installed | array of installed packages $updates | array of packages w/ update available $clusters | array of cluster names -------------+------------------------------------------------------- The filter has the full power of TCL. Examples ======== Filter all Debian hosts: return [expr [string compare $lsb_distri "Debian"] == 0] Filter all Debian hosts running a release older than Etch: return [expr [string compare $lsb_distri "Debian"] == 0 && $lsb_rel < 4.0] Filter add hosts which have bind installed: return [llength [array names installed "bind*"]] apt-dater-0.9.0/README.xmlreport0000644000175000017500000000147111760757134015702 0ustar thomasthomasXML Report ========== Since version 0.6.0, apt-dater can be compiled with XML report support. This feature is disabled by default, enable it with configure: $ ./configure --enable-xmlreport You need libxml2 installed to succeed, the Debian packages have XML report support enabled. Usage ===== To create a XML report, start apt-dater with command line parameter -r: $ apt-dater -r > report.xml This will refresh all hosts and reports the hosts status as XML formated output. This output can be formated to your needs using a XSLT program. You could find examples in the xmlreport directory. To process the XML file you could use xsltproc: $ xsltproc xmlreport/overview.xsl report.xml You could do anything with the results XML file. The report should be valid according the DTD found at xmlreport/report.dtd. apt-dater-0.9.0/RELTEST0000644000175000017500000000144611760757134014036 0ustar thomasthomasCheck the following functionalities of apt-dater before you take a release: Basic functions: - Use of cursor keys in the tree of nodes - Expand/Shrink a node - The help page (Key `?') - The search function Mangement functions: - Refresh a host (Key `g') with the correct return of the host status - Install a single package (Key `i') - Upgrade the whole host (Key `u') - Connect to a host (Key `c') Handling of the screen utility: - Attach/Detach a active session (Key `a') - Session cycling (Key `N') - Toggle dumps (Key `d') TCL Filter: - Basic functionality of the TCL filter Report: - Basic functionality of the report function (`apt-dater -r') Miscellaneous: - Compilation (configure && make) - The correct operation of the lock file handling - Check for memory leaks, etc... - Package building apt-dater-0.9.0/TODO0000644000175000017500000000032711760757134013456 0ustar thomasthomasTODO ==== - make apt-dater-host package available for more Linux distributions (non apt/dpkg based) - fix UI glitches or better rewrite the code - change UI to show all informations gathered from the clients apt-dater-0.9.0/aclocal.m40000644000175000017500000011477311761141267014634 0ustar thomasthomas# generated automatically by aclocal 1.9.6 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. # intlmacosx.m4 serial 3 (gettext-0.18) dnl Copyright (C) 2004-2010 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public dnl License but which still want to provide support for the GNU gettext dnl functionality. dnl Please note that the actual code of the GNU gettext library is covered dnl by the GNU Library General Public License, and the rest of the GNU dnl gettext package package is covered by the GNU General Public License. dnl They are *not* in the public domain. dnl Checks for special options needed on MacOS X. dnl Defines INTL_MACOSX_LIBS. AC_DEFUN([gt_INTL_MACOSX], [ dnl Check for API introduced in MacOS X 10.2. AC_CACHE_CHECK([for CFPreferencesCopyAppValue], [gt_cv_func_CFPreferencesCopyAppValue], [gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" AC_TRY_LINK([#include ], [CFPreferencesCopyAppValue(NULL, NULL)], [gt_cv_func_CFPreferencesCopyAppValue=yes], [gt_cv_func_CFPreferencesCopyAppValue=no]) LIBS="$gt_save_LIBS"]) if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1], [Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework.]) fi dnl Check for API introduced in MacOS X 10.3. AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent], [gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" AC_TRY_LINK([#include ], [CFLocaleCopyCurrent();], [gt_cv_func_CFLocaleCopyCurrent=yes], [gt_cv_func_CFLocaleCopyCurrent=no]) LIBS="$gt_save_LIBS"]) if test $gt_cv_func_CFLocaleCopyCurrent = yes; then AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1], [Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework.]) fi INTL_MACOSX_LIBS= if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" fi AC_SUBST([INTL_MACOSX_LIBS]) ]) # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- # serial 1 (pkg-config-0.24) # # Copyright © 2004 Scott James Remnant . # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # PKG_PROG_PKG_CONFIG([MIN-VERSION]) # ---------------------------------- AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi if test -n "$PKG_CONFIG"; then _pkg_min_version=m4_default([$1], [0.9.0]) AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) PKG_CONFIG="" fi fi[]dnl ])# PKG_PROG_PKG_CONFIG # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) # # Check to see whether a particular set of modules exists. Similar # to PKG_CHECK_MODULES(), but does not set variables or print errors. # # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) # only at the first occurence in configure.ac, so if the first place # it's called might be skipped (such as if it is within an "if", you # have to call PKG_CHECK_EXISTS manually # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then m4_default([$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) # --------------------------------------------- m4_define([_PKG_CONFIG], [if test -n "$$1"; then pkg_cv_[]$1="$$1" elif test -n "$PKG_CONFIG"; then PKG_CHECK_EXISTS([$3], [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes ], [pkg_failed=yes]) else pkg_failed=untried fi[]dnl ])# _PKG_CONFIG # _PKG_SHORT_ERRORS_SUPPORTED # ----------------------------- AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], [AC_REQUIRE([PKG_PROG_PKG_CONFIG]) if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi[]dnl ])# _PKG_SHORT_ERRORS_SUPPORTED # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], # [ACTION-IF-NOT-FOUND]) # # # Note that if there is a possibility the first call to # PKG_CHECK_MODULES might not happen, you should be sure to include an # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac # # # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_MODULES], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl pkg_failed=no AC_MSG_CHECKING([for $1]) _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) _PKG_CONFIG([$1][_LIBS], [libs], [$2]) m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` else $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD m4_default([$4], [AC_MSG_ERROR( [Package requirements ($2) were not met: $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. _PKG_TEXT])[]dnl ]) elif test $pkg_failed = untried; then AC_MSG_RESULT([no]) m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT To get pkg-config, see .])[]dnl ]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) $3 fi[]dnl ])# PKG_CHECK_MODULES # Copyright (C) 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.9"]) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION so it can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.9.6])]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to # `$srcdir', `$srcdir/..', or `$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is `.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [dnl Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50])dnl # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 7 # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE]) AC_SUBST([$1_FALSE]) if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "GCJ", or "OBJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl ifelse([$1], CC, [depcc="$CC" am_compiler_list=], [$1], CXX, [depcc="$CXX" am_compiler_list=], [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking, [ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH]) ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. #serial 3 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` AS_MKDIR_P([$dirpart/$fdir]) # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking # is enabled. FIXME. This creates each `.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 12 # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.58])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) AM_MISSING_PROG(AUTOCONF, autoconf) AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) AM_MISSING_PROG(AUTOHEADER, autoheader) AM_MISSING_PROG(MAKEINFO, makeinfo) AM_PROG_INSTALL_SH AM_PROG_INSTALL_STRIP AC_REQUIRE([AM_PROG_MKDIR_P])dnl # We need awk for the "check" target. The system "awk" is bad on # some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES(CC)], [define([AC_PROG_CC], defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES(CXX)], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl ]) ]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $1 | $1:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl install_sh=${install_sh-"$am_aux_dir/install-sh"} AC_SUBST(install_sh)]) # Copyright (C) 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi AC_SUBST([am__include]) AC_SUBST([am__quote]) AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it supports --run. # If it does, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= AC_MSG_WARN([`missing' script is too old or missing]) fi ]) # Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_MKDIR_P # --------------- # Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise. # # Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories # created by `make install' are always world readable, even if the # installer happens to have an overly restrictive umask (e.g. 077). # This was a mistake. There are at least two reasons why we must not # use `-m 0755': # - it causes special bits like SGID to be ignored, # - it may be too restrictive (some setups expect 775 directories). # # Do not use -m 0755 and let people choose whatever they expect by # setting umask. # # We cannot accept any implementation of `mkdir' that recognizes `-p'. # Some implementations (such as Solaris 8's) are not thread-safe: if a # parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c' # concurrently, both version can detect that a/ is missing, but only # one can create it and the other will error out. Consequently we # restrict ourselves to GNU make (using the --version option ensures # this.) AC_DEFUN([AM_PROG_MKDIR_P], [if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi AC_SUBST([mkdir_p])]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # ------------------------------ # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), 1)]) # _AM_SET_OPTIONS(OPTIONS) # ---------------------------------- # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT(yes)]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor `install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in `make install-strip', and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be `maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of `v7', `ustar', or `pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. AM_MISSING_PROG([AMTAR], [tar]) m4_if([$1], [v7], [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], [m4_case([$1], [ustar],, [pax],, [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' _am_tools=${am_cv_prog_tar_$1-$_am_tools} # Do not fold the above two line into one, because Tru64 sh and # Solaris sh will not grok spaces in the rhs of `-'. for _am_tool in $_am_tools do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR m4_include([m4/gettext.m4]) m4_include([m4/iconv.m4]) m4_include([m4/lib-ld.m4]) m4_include([m4/lib-link.m4]) m4_include([m4/lib-prefix.m4]) m4_include([m4/nls.m4]) m4_include([m4/po.m4]) m4_include([m4/progtest.m4]) apt-dater-0.9.0/build/0000755000175000017500000000000011761142205014047 5ustar thomasthomasapt-dater-0.9.0/build/apt-dater.spec.in0000644000175000017500000000523411760757134017231 0ustar thomasthomas # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2010-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # %define name @PACKAGE@ %define version @PACKAGE_VERSION@ %define release 1 Name: %{name} Summary: Terminal-based remote package update manager Version: %{version} Release: %{release} URL: http://www.ibh.de/apt-dater/ Source: %{name}-%{version}.tar.gz License: GPL Group: System/Management Icon: apt-dater.xpm Requires: screen Requires: tcl BuildRequires: gettext-devel BuildRequires: glib2-devel BuildRequires: libxml2-devel BuildRequires: ncurses-devel BuildRequires: popt-devel BuildRequires: screen BuildRequires: tcl-devel BuildRequires: automake BuildRequires: autoconf BuildRequires: perl Buildroot: %{_tmppath}/%{name}-buildroot Vendor: IBH IT-Service GmbH (http://www.ibh.de/) %description apt-dater provides an easy to use ncurses frontend for managing package updates on a large number of remote hosts using SSH. It supports Debian-based managed hosts as well as OpenSUSE and CentOS based systems. %prep %setup %build %configure --prefix=%{_prefix} --libexec=%{_libexecdir}/apt-dater --disable-rpath --enable-tclfilter --enable-xmlreport --enable-autoref --enable-history --enable-debug make %install (cd src && make install DESTDIR=$RPM_BUILD_ROOT) (cd lib && make install DESTDIR=$RPM_BUILD_ROOT) (cd po && make install DESTDIR=$RPM_BUILD_ROOT) (cd man && make install DESTDIR=$RPM_BUILD_ROOT) %clean rm -rf $RPM_BUILD_ROOT make clean %files %defattr(-,root,root) %{_bindir}/apt-dater %dir %{_libdir}/apt-dater %{_libdir}/apt-dater/* %doc AUTHORS COPYING ChangeLog README* TODO %{_mandir}/man5/*.5* %{_mandir}/man8/*.8* %dir %{_mandir}/manh %{_mandir}/manh/* %lang(de) %{_datadir}/locale/de/LC_MESSAGES/apt-dater.mo %lang(it) %{_datadir}/locale/it/LC_MESSAGES/apt-dater.mo %{_datadir}/locale/*/LC_MESSAGES/apt-dater.mo apt-dater-0.9.0/build/screen_sockpath0000755000175000017500000000222511760757134017165 0ustar thomasthomas#!/bin/sh # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2010-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # # Tries to get the path where screen stores it's sockets. screen=$1 if [ -x "$screen" ]; then $screen -list | perl -ne 'print "$2\n" if(/^\S+ Sockets? (found )?in (\/.+)\/[^\/]+\.$/);' fi apt-dater-0.9.0/conf/0000755000175000017500000000000011760757134013711 5ustar thomasthomasapt-dater-0.9.0/conf/apt-dater.conf.example0000644000175000017500000000303511760757134020074 0ustar thomasthomas# Config file of apt-dater in the form of the glib GKeyFile required [Paths] # Default: $XDG_CONFIG_HOME/apt-dater/hosts.conf #HostsFile=path-to/hosts.conf # Default: $XDG_DATA_HOME/apt-dater #StatsDir=path-to/stats [SSH] # SSH binary Cmd=/usr/bin/ssh OptionalCmdFlags=-t # SFTP binary SFTPCmd=/usr/bin/mc /#sh:%u@%h:C/ #[Screen] ## Default: $XDG_CONFIG_HOME/apt-dater/screenrc #RCFile=path-to/screenrc # ## Default: %m # %u@%h:%p #Title=%m # %u@%h:%p # # These values requires apt-dater-host to be installed on the target host. # You could call apt/aptitude directly (see apt-dater-host source), # but this is not recommended. [Commands] CmdRefresh=apt-dater-host refresh CmdUpgrade=apt-dater-host upgrade CmdInstall=apt-dater-host install %s # 'Auto Refresh' feature configuration [AutoRef] # Refresh hosts if the are outdated. enabled=true [Appearance] # Colors = (COMPONENT FG BG ';')* # COMPONENT ::= 'default' | 'menu' | 'status' | 'selector' | 'hoststatus' | # 'query' | 'input' # FG ::= COLOR # BG ::= COLOR # COLOR ::= 'black' | 'blue' | 'cyan' | 'green' | 'magenta' | 'red' | # 'white' | 'yellow' Colors=menu brightgreen blue;status brightgreen blue;selector black red; #[TCLFilter] #Predefined filter expression on startup. #FilterExp=return [expr [string compare $lsb_distri \"Debian\"] == 0 && $lsb_rel < 4.0] #Load this TCL file on startup in the same context as the FilterExp. #FilterFile=/patch/to/file.tcl # Notify user by... [Notify] # terminal bell beep=true # screen flash flash=true apt-dater-0.9.0/conf/hosts.conf.example0000644000175000017500000000035411760757134017354 0ustar thomasthomas# Syntax: # # [Customer Name] # Hosts=([OptionalUser@]host.domain[:OptionalPort];)* # [IdentityFile=path_to_identity_file] # [localdomain] Hosts=localhost; [IBH] Hosts=example1.ibh.net;example2.ibh.net;test@example3.ibh.net:62222; apt-dater-0.9.0/conf/screenrc.example0000644000175000017500000000361411760757134017076 0ustar thomasthomas# ------------------------------------------------------------------------------ # SCREEN SETTINGS # ------------------------------------------------------------------------------ startup_message off #defflow on # will force screen to process ^S/^Q deflogin on autodetach on # turn visual bell on vbell on # define a bigger scrollback, default is 100 lines defscrollback 2048 # ------------------------------------------------------------------------------ # SCREEN KEYBINDINGS # ------------------------------------------------------------------------------ # Remove some stupid / dangerous key bindings bind ^k #bind L bind ^\ # Make them better bind \\ quit bind K kill bind I login on bind O login off bind } history # Sessions should stay until destroyed by pressing q zombie 'q' # ------------------------------------------------------------------------------ # TERMINAL SETTINGS # ------------------------------------------------------------------------------ # The vt100 description does not mention "dl". *sigh* termcapinfo vt100 dl=5\E[M # Set the hardstatus prop on gui terms to set the titlebar/icon title termcapinfo xterm*|rxvt*|kterm*|Eterm* hs:ts=\E]0;:fs=\007:ds=\E]0;\007:OP # set these terminals up to be 'optimal' instead of vt100 #termcapinfo xterm*|linux*|rxvt*|Eterm* OP # Change the xterm initialization string from is2=\E[!p\E[?3;4l\E[4l\E> # (This fixes the "Aborted because of window size change" konsole symptoms found # in bug #134198) termcapinfo xterm 'is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;4;6l' # To get screen to add lines to xterm's scrollback buffer, uncomment the # following termcapinfo line which tells xterm to use the normal screen buffer # (which has scrollback), not the alternate screen buffer. # termcapinfo xterm|xterms|xs|rxvt ti@:te@ # Add caption line with clock, window title and window flags. caption always "%{b bG}%c%=%t%=%f" # Catch zmodem file transfers zmodem catch apt-dater-0.9.0/config.guess0000755000175000017500000012753411760757134015320 0ustar thomasthomas#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. timestamp='2008-01-23' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Per Bothner . # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > $dummy.c ; for c in cc gcc c89 c99 ; do if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ /usr/sbin/$sysctl 2>/dev/null || echo unknown)` case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE_ARCH}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep __ELF__ >/dev/null then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} exit ;; *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; *:SolidBSD:*:*) echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} exit ;; macppc:MirBSD:*:*) echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE="alpha" ;; "EV4.5 (21064)") UNAME_MACHINE="alpha" ;; "LCA4 (21066/21068)") UNAME_MACHINE="alpha" ;; "EV5 (21164)") UNAME_MACHINE="alphaev5" ;; "EV5.6 (21164A)") UNAME_MACHINE="alphaev56" ;; "EV5.6 (21164PC)") UNAME_MACHINE="alphapca56" ;; "EV5.7 (21164PC)") UNAME_MACHINE="alphapca57" ;; "EV6 (21264)") UNAME_MACHINE="alphaev6" ;; "EV6.7 (21264A)") UNAME_MACHINE="alphaev67" ;; "EV6.8CB (21264C)") UNAME_MACHINE="alphaev68" ;; "EV6.8AL (21264B)") UNAME_MACHINE="alphaev68" ;; "EV6.8CX (21264D)") UNAME_MACHINE="alphaev68" ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE="alphaev69" ;; "EV7 (21364)") UNAME_MACHINE="alphaev7" ;; "EV7.9 (21364A)") UNAME_MACHINE="alphaev79" ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition exit ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit ;; *:OS400:*:*) echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; arm:riscos:*:*|arm:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`$dummy $dummyarg` && { echo "$SYSTEM_NAME"; exit; } echo mips-mips-riscos${UNAME_RELEASE} exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` then echo "$SYSTEM_NAME" else echo rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit ;; *:AIX:*:[456]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "${sc_kernel_bits}" in 32) HP_ARCH="hppa2.0n" ;; 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 esac ;; esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ ${HP_ARCH} = "hppa2.0w" ] then eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | grep __LP64__ >/dev/null then HP_ARCH="hppa2.0w" else HP_ARCH="hppa64" fi fi echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit ;; 3050*:HI-UX:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) case ${UNAME_MACHINE} in pc98) echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) # uname -m includes "-pc" on this system. echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; *:Interix*:[3456]*) case ${UNAME_MACHINE} in x86) echo i586-pc-interix${UNAME_RELEASE} exit ;; EM64T | authenticamd) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; IA64) echo ia64-unknown-interix${UNAME_RELEASE} exit ;; esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i586-pc-interix exit ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; *:GNU:*:*) # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu exit ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; arm*:Linux:*:*) eval $set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then echo ${UNAME_MACHINE}-unknown-linux-gnu else echo ${UNAME_MACHINE}-unknown-linux-gnueabi fi exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit ;; crisv32:Linux:*:*) echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) echo frv-unknown-linux-gnu exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m32r*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; mips:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips #undef mipsel #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mipsel #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips64 #undef mips64el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mips64el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips64 #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) echo or32-unknown-linux-gnu exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; xtensa*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. # Set LC_ALL=C to ensure ld outputs messages in English. ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit ;; coff-i386) echo "${UNAME_MACHINE}-pc-linux-gnucoff" exit ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. echo "${UNAME_MACHINE}-pc-linux-gnuoldld" exit ;; esac # Determine whether the default compiler is a.out or elf eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 LIBC=gnu # else LIBC=gnulibc1 # endif # else LIBC=gnulibc1 # endif #else #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) LIBC=gnu #else LIBC=gnuaout #endif #endif #ifdef __dietlibc__ LIBC=dietlibc #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^LIBC/{ s: ::g p }'`" test x"${LIBC}" != x && { echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit } test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit ;; i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit ;; i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i386. echo i386-pc-msdosdjgpp exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; paragon:*:*:*) echo i860-intel-osf1 exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. echo ${UNAME_MACHINE}-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; SX-7:SUPER-UX:*:*) echo sx7-nec-superux${UNAME_RELEASE} exit ;; SX-8:SUPER-UX:*:*) echo sx8-nec-superux${UNAME_RELEASE} exit ;; SX-8R:SUPER-UX:*:*) echo sx8r-nec-superux${UNAME_RELEASE} exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = "386"; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit ;; *:ITS:*:*) echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit ;; i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; i*86:rdos:*:*) echo ${UNAME_MACHINE}-pc-rdos exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 eval $set_cc_for_build cat >$dummy.c < # include #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix\n"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) # if !defined (ultrix) # include # if defined (BSD) # if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); # else # if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); # else printf ("vax-dec-bsd\n"); exit (0); # endif # endif # else printf ("vax-dec-bsd\n"); exit (0); # endif # else printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; c34*) echo c34-convex-bsd exit ;; c38*) echo c38-convex-bsd exit ;; c4*) echo c4-convex-bsd exit ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = ${UNAME_MACHINE} UNAME_RELEASE = ${UNAME_RELEASE} UNAME_SYSTEM = ${UNAME_SYSTEM} UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: apt-dater-0.9.0/config.h.in0000644000175000017500000001142711761141276015007 0ustar thomasthomas/* config.h.in. Generated from configure.in by autoheader. */ /* Define if Darwin or Mac OS X */ #undef DARWIN /* Define to 1 if translation of program messages to the user's native language is requested. */ #undef ENABLE_NLS /* Where is the command env located. */ #undef ENV_BINARY /* Define if you want 'auto refresh' support included. */ #undef FEAT_AUTOREF /* Define if you want 'clusters' support included. */ #undef FEAT_CLUSTERS /* Define if you want 'history' support included. */ #undef FEAT_HISTORY /* Define if you want TCL filter support included. */ #undef FEAT_TCLFILTER /* Define if you want XML report support included. */ #undef FEAT_XMLREPORT /* Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework. */ #undef HAVE_CFLOCALECOPYCURRENT /* Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework. */ #undef HAVE_CFPREFERENCESCOPYAPPVALUE /* Define if your curses library supports color. */ #undef HAVE_COLOR /* Define to 1 if you have the header file. */ #undef HAVE_CURSES_H /* Define if the GNU dcgettext() function is already present or preinstalled. */ #undef HAVE_DCGETTEXT /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H /* Define if funtion flock avaible. */ #undef HAVE_FLOCK /* Define if the GNU gettext() function is already present or preinstalled. */ #undef HAVE_GETTEXT /* Define if your GLIB supports the g_timeout_add_seconds call. */ #undef HAVE_GLIB_TIMEOUT_ADD_SECONDS /* Define if you have the iconv() function and it works. */ #undef HAVE_ICONV /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the `glib-2.0' library (-lglib-2.0). */ #undef HAVE_LIBGLIB_2_0 /* Define to 1 if you have the `popt' library (-lpopt). */ #undef HAVE_LIBPOPT /* Define to 1 if you have the header file. */ #undef HAVE_LOCALE_H /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H /* Define to 1 if you have the `memset' function. */ #undef HAVE_MEMSET /* Define to 1 if you have the header file. */ #undef HAVE_NCURSES_H /* Define to 1 if you have the header file. */ #undef HAVE_POPT_H /* Define to 1 if `stat' has the bug that it succeeds when given the zero-length file name argument. */ #undef HAVE_STAT_EMPTY_STRING_BUG /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the `strchr' function. */ #undef HAVE_STRCHR /* Define to 1 if you have the `strdup' function. */ #undef HAVE_STRDUP /* Define to 1 if you have the `strerror' function. */ #undef HAVE_STRERROR /* Define to 1 if you have the `strftime' function. */ #undef HAVE_STRFTIME /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_FILE_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Define if your curses library supports function use_default_colors. */ #undef HAVE_USE_DEFAULT_COLORS /* Define to 1 if `lstat' dereferences a symlink specified with a trailing slash. */ #undef LSTAT_FOLLOWS_SLASHED_SYMLINK /* Define if you want no debug code included. */ #undef NDEBUG /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the home page for this package. */ #undef PACKAGE_URL /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Define as the return type of signal handlers (`int' or `void'). */ #undef RETSIGTYPE /* Where is the command screen located. */ #undef SCREEN_BINARY /* Where screen stores the sockets. */ #undef SCREEN_SOCKPATH /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Define to 1 if your declares `struct tm'. */ #undef TM_IN_SYS_TIME /* Version number of package */ #undef VERSION /* Define to empty if `const' does not conform to ANSI C. */ #undef const /* Define to `__inline__' or `__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif apt-dater-0.9.0/config.sub0000755000175000017500000010115311760757134014750 0ustar thomasthomas#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. timestamp='2008-01-16' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # This file is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ -apple | -axis | -knuth | -cray) os= basic_machine=$1 ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco6) os=-sco5v6 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5v6*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ | maxq | mb | microblaze | mcore | mep \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ | mips64vr | mips64vrel \ | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ | mips64vr5900 | mips64vr5900el \ | mipsisa32 | mipsisa32el \ | mipsisa32r2 | mipsisa32r2el \ | mipsisa64 | mipsisa64el \ | mipsisa64r2 | mipsisa64r2el \ | mipsisa64sb1 | mipsisa64sb1el \ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | mt \ | msp430 \ | nios | nios2 \ | ns16k | ns32k \ | or32 \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | score \ | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ | spu | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; ms1) basic_machine=mt-unknown ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64vr-* | mips64vrel-* \ | mips64orion-* | mips64orionel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mips64vr5900-* | mips64vr5900el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | mt-* \ | msp430-* \ | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa*-* \ | ymp-* \ | z8k-*) ;; # Recognize the basic CPU types without company name, with glob match. xtensa*) basic_machine=$basic_machine-unknown ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; blackfin) basic_machine=bfin-unknown os=-linux ;; blackfin-*) basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; c90) basic_machine=c90-cray os=-unicos ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16) basic_machine=cr16-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m68knommu) basic_machine=m68k-unknown os=-linux ;; m68knommu-*) basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; mingw32ce) basic_machine=arm-unknown os=-mingw32ce ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; msdos) basic_machine=i386-pc os=-msdos ;; ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; openrisc | openrisc-*) basic_machine=or32-unknown ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; parisc) basic_machine=hppa-unknown os=-linux ;; parisc-*) basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pc98) basic_machine=i386-pc ;; pc98-*) basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rdos) basic_machine=i386-pc os=-rdos ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sde) basic_machine=mipsisa32-sde os=-elf ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sh5el) basic_machine=sh5le-unknown ;; sh64) basic_machine=sh64-unknown ;; sparclite-wrs | simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tic55x | c55x*) basic_machine=tic55x-unknown os=-coff ;; tic6x | c6x*) basic_machine=tic6x-unknown os=-coff ;; tile*) basic_machine=tile-unknown os=-linux-gnu ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; ymp) basic_machine=ymp-cray os=-unicos ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers* | -drops*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -aros*) os=-aros ;; -kaos*) os=-kaos ;; -zvmoe) os=-zvmoe ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in score-*) os=-elf ;; spu-*) os=-elf ;; *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mep-*) os=-elf ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-haiku) os=-haiku ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: apt-dater-0.9.0/configure0000755000175000017500000110617211761141270014670 0ustar thomasthomas#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.69 for apt-dater 0.9.0. # # Report bugs to . # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then _as_can_reexec=no; export _as_can_reexec; # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 as_fn_exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test \$(( 1 + 1 )) = 2 || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : export CONFIG_SHELL # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org and apt-dater@ibh.de $0: about your system, including any error possibly output $0: before this message. Then install a modern shell, or $0: manually run the script under such a shell if you do $0: have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall # in an infinite loop. This has already happened in practice. _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME='apt-dater' PACKAGE_TARNAME='apt-dater' PACKAGE_VERSION='0.9.0' PACKAGE_STRING='apt-dater 0.9.0' PACKAGE_BUGREPORT='apt-dater@ibh.de' PACKAGE_URL='' ac_unique_file="src/apt-dater.c" gt_needs= # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='LTLIBOBJS LIBOBJS DBXSL XSLTPROC TCL_LIBS TCL_CFLAGS cv_path_tcl CURSES_LIB LIBXML2_LIBS LIBXML2_CFLAGS GLIB_LIBS GLIB_CFLAGS PKG_CONFIG_LIBDIR PKG_CONFIG_PATH PKG_CONFIG EGREP GREP CPP POSUB LTLIBINTL LIBINTL INTLLIBS LTLIBICONV LIBICONV INTL_MACOSX_LIBS am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__quote am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC XGETTEXT_EXTRA_OPTIONS MSGMERGE XGETTEXT_015 XGETTEXT GMSGFMT_015 MSGFMT_015 GMSGFMT MSGFMT GETTEXT_MACRO_VERSION USE_NLS FREEBSD_FALSE FREEBSD_TRUE LINUX_FALSE LINUX_TRUE am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM target_os target_vendor target_cpu target host_os host_vendor host_cpu host build_os build_vendor build_cpu build target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking enable_nls enable_dependency_tracking with_gnu_ld enable_rpath with_libiconv_prefix with_libintl_prefix enable_debug enable_xmlreport enable_autoref enable_history enable_clusters enable_tclfilter with_tclsh ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP PKG_CONFIG PKG_CONFIG_PATH PKG_CONFIG_LIBDIR GLIB_CFLAGS GLIB_LIBS LIBXML2_CFLAGS LIBXML2_LIBS' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures apt-dater 0.9.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/apt-dater] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] --target=TARGET configure for building compilers for TARGET [HOST] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of apt-dater 0.9.0:";; esac cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-nls do not use Native Language Support --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --disable-rpath do not hardcode runtime library paths --enable-debug Enable debug code. --enable-xmlreport Include XML reports. --enable-autoref Include 'auto refresh' support. --enable-history Include 'history' support. --enable-clusters Include 'clusters' support. --enable-tclfilter Include Tcl interpreter. Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-gnu-ld assume the C compiler uses GNU ld default=no --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib --without-libiconv-prefix don't search for libiconv in includedir and libdir --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib --without-libintl-prefix don't search for libintl in includedir and libdir --with-tclsh=PATH which tclsh to use (default: tclsh8.5) Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor PKG_CONFIG path to pkg-config utility PKG_CONFIG_PATH directories to add to pkg-config's search path PKG_CONFIG_LIBDIR path overriding pkg-config's built-in search path GLIB_CFLAGS C compiler flags for GLIB, overriding pkg-config GLIB_LIBS linker flags for GLIB, overriding pkg-config LIBXML2_CFLAGS C compiler flags for LIBXML2, overriding pkg-config LIBXML2_LIBS linker flags for LIBXML2, overriding pkg-config Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF apt-dater configure 0.9.0 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_try_run LINENO # ---------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes # that executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ( $as_echo "## ------------------------------- ## ## Report this to apt-dater@ibh.de ## ## ------------------------------- ##" ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case declares $2. For example, HP-UX 11i declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by apt-dater $as_me 0.9.0, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo $as_echo "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo $as_echo "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then $as_echo "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then $as_echo "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then # We do not want a PATH search for config.site. case $CONFIG_SITE in #(( -*) ac_site_file1=./$CONFIG_SITE;; */*) ac_site_file1=$CONFIG_SITE;; *) ac_site_file1=./$CONFIG_SITE;; esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file See \`config.log' for more details" "$LINENO" 5; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi gt_needs="$gt_needs " # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Environment ac_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 $as_echo_n "checking target system type... " >&6; } if ${ac_cv_target+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$target_alias" = x; then ac_cv_target=$ac_cv_host else ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 $as_echo "$ac_cv_target" >&6; } case $ac_cv_target in *-*-*) ;; *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; esac target=$ac_cv_target ac_save_IFS=$IFS; IFS='-' set x $ac_cv_target shift target_cpu=$1 target_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: target_os=$* IFS=$ac_save_IFS case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac # The aliases save the names the user supplied, while $host etc. # will get canonicalized. test -n "$target_alias" && test "$program_prefix$program_suffix$program_transform_name" = \ NONENONEs,x,x, && program_prefix=${target_alias}- am__api_version="1.9" # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error $? "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi test "$2" = conftest.file ) then # Ok. : else as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='apt-dater' VERSION='0.9.0' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} install_sh=${install_sh-"$am_aux_dir/install-sh"} # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' case "${target_os}" in darwin*) $as_echo "#define DARWIN 1" >>confdefs.h ;; linux*) linux="yes" ;; freebsd*) freebsd="yes" ;; esac if test x"$linux" = x"yes"; then LINUX_TRUE= LINUX_FALSE='#' else LINUX_TRUE='#' LINUX_FALSE= fi if test x"$freebsd" = x"yes"; then FREEBSD_TRUE= FREEBSD_FALSE='#' else FREEBSD_TRUE='#' FREEBSD_FALSE= fi ac_config_headers="$ac_config_headers config.h" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 $as_echo_n "checking whether NLS is requested... " >&6; } # Check whether --enable-nls was given. if test "${enable_nls+set}" = set; then : enableval=$enable_nls; USE_NLS=$enableval else USE_NLS=yes fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 $as_echo "$USE_NLS" >&6; } GETTEXT_MACRO_VERSION=0.17 # Prepare PATH_SEPARATOR. # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Find out how to test for executable files. Don't use a zero-byte file, # as systems may use methods other than mode bits to determine executability. cat >conf$$.file <<_ASEOF #! /bin/sh exit 0 _ASEOF chmod +x conf$$.file if test -x conf$$.file >/dev/null 2>&1; then ac_executable_p="test -x" else ac_executable_p="test -f" fi rm -f conf$$.file # Extract the first word of "msgfmt", so it can be a program name with args. set dummy msgfmt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_MSGFMT+:} false; then : $as_echo_n "(cached) " >&6 else case "$MSGFMT" in [\\/]* | ?:[\\/]*) ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ;; *) ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$ac_save_IFS" test -z "$ac_dir" && ac_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then echo "$as_me: trying $ac_dir/$ac_word..." >&5 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 && (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" break 2 fi fi done done IFS="$ac_save_IFS" test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" ;; esac fi MSGFMT="$ac_cv_path_MSGFMT" if test "$MSGFMT" != ":"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 $as_echo "$MSGFMT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi # Extract the first word of "gmsgfmt", so it can be a program name with args. set dummy gmsgfmt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_GMSGFMT+:} false; then : $as_echo_n "(cached) " >&6 else case $GMSGFMT in [\\/]* | ?:[\\/]*) ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ;; esac fi GMSGFMT=$ac_cv_path_GMSGFMT if test -n "$GMSGFMT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 $as_echo "$GMSGFMT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;; *) MSGFMT_015=$MSGFMT ;; esac case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;; *) GMSGFMT_015=$GMSGFMT ;; esac # Prepare PATH_SEPARATOR. # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Find out how to test for executable files. Don't use a zero-byte file, # as systems may use methods other than mode bits to determine executability. cat >conf$$.file <<_ASEOF #! /bin/sh exit 0 _ASEOF chmod +x conf$$.file if test -x conf$$.file >/dev/null 2>&1; then ac_executable_p="test -x" else ac_executable_p="test -f" fi rm -f conf$$.file # Extract the first word of "xgettext", so it can be a program name with args. set dummy xgettext; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_XGETTEXT+:} false; then : $as_echo_n "(cached) " >&6 else case "$XGETTEXT" in [\\/]* | ?:[\\/]*) ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ;; *) ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$ac_save_IFS" test -z "$ac_dir" && ac_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then echo "$as_me: trying $ac_dir/$ac_word..." >&5 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 && (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" break 2 fi fi done done IFS="$ac_save_IFS" test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ;; esac fi XGETTEXT="$ac_cv_path_XGETTEXT" if test "$XGETTEXT" != ":"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 $as_echo "$XGETTEXT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi rm -f messages.po case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;; *) XGETTEXT_015=$XGETTEXT ;; esac # Prepare PATH_SEPARATOR. # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Find out how to test for executable files. Don't use a zero-byte file, # as systems may use methods other than mode bits to determine executability. cat >conf$$.file <<_ASEOF #! /bin/sh exit 0 _ASEOF chmod +x conf$$.file if test -x conf$$.file >/dev/null 2>&1; then ac_executable_p="test -x" else ac_executable_p="test -f" fi rm -f conf$$.file # Extract the first word of "msgmerge", so it can be a program name with args. set dummy msgmerge; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_MSGMERGE+:} false; then : $as_echo_n "(cached) " >&6 else case "$MSGMERGE" in [\\/]* | ?:[\\/]*) ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. ;; *) ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$ac_save_IFS" test -z "$ac_dir" && ac_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then echo "$as_me: trying $ac_dir/$ac_word..." >&5 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" break 2 fi fi done done IFS="$ac_save_IFS" test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" ;; esac fi MSGMERGE="$ac_cv_path_MSGMERGE" if test "$MSGMERGE" != ":"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5 $as_echo "$MSGMERGE" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$localedir" || localedir='${datadir}/locale' test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS= ac_config_commands="$ac_config_commands po-directories" if test "X$prefix" = "XNONE"; then acl_final_prefix="$ac_default_prefix" else acl_final_prefix="$prefix" fi if test "X$exec_prefix" = "XNONE"; then acl_final_exec_prefix='${prefix}' else acl_final_exec_prefix="$exec_prefix" fi acl_save_prefix="$prefix" prefix="$acl_final_prefix" eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" prefix="$acl_save_prefix" DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 $as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 $as_echo "$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no fi # Prepare PATH_SEPARATOR. # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 $as_echo_n "checking for ld used by GCC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | [A-Za-z]:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the path of ld ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${acl_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then acl_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some GNU ld's only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in *GNU* | *'with BFD'*) test "$with_gnu_ld" != no && break ;; *) test "$with_gnu_ld" != yes && break ;; esac fi done IFS="$ac_save_ifs" else acl_cv_path_LD="$LD" # Let the user override the test with a path. fi fi LD="$acl_cv_path_LD" if test -n "$LD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${acl_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU ld's only accept -v. case `$LD -v 2>&1 &5 $as_echo "$acl_cv_prog_gnu_ld" >&6; } with_gnu_ld=$acl_cv_prog_gnu_ld { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 $as_echo_n "checking for shared library run path origin... " >&6; } if ${acl_cv_rpath+:} false; then : $as_echo_n "(cached) " >&6 else CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh . ./conftest.sh rm -f ./conftest.sh acl_cv_rpath=done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 $as_echo "$acl_cv_rpath" >&6; } wl="$acl_cv_wl" acl_libext="$acl_cv_libext" acl_shlibext="$acl_cv_shlibext" acl_libname_spec="$acl_cv_libname_spec" acl_library_names_spec="$acl_cv_library_names_spec" acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" acl_hardcode_direct="$acl_cv_hardcode_direct" acl_hardcode_minus_L="$acl_cv_hardcode_minus_L" # Check whether --enable-rpath was given. if test "${enable_rpath+set}" = set; then : enableval=$enable_rpath; : else enable_rpath=yes fi acl_libdirstem=lib searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'` if test -n "$searchpath"; then acl_save_IFS="${IFS= }"; IFS=":" for searchdir in $searchpath; do if test -d "$searchdir"; then case "$searchdir" in */lib64/ | */lib64 ) acl_libdirstem=lib64 ;; *) searchdir=`cd "$searchdir" && pwd` case "$searchdir" in */lib64 ) acl_libdirstem=lib64 ;; esac ;; esac fi done IFS="$acl_save_IFS" fi use_additional=yes acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" # Check whether --with-libiconv-prefix was given. if test "${with_libiconv_prefix+set}" = set; then : withval=$with_libiconv_prefix; if test "X$withval" = "Xno"; then use_additional=no else if test "X$withval" = "X"; then acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" else additional_includedir="$withval/include" additional_libdir="$withval/$acl_libdirstem" fi fi fi LIBICONV= LTLIBICONV= INCICONV= LIBICONV_PREFIX= rpathdirs= ltrpathdirs= names_already_handled= names_next_round='iconv ' while test -n "$names_next_round"; do names_this_round="$names_next_round" names_next_round= for name in $names_this_round; do already_handled= for n in $names_already_handled; do if test "$n" = "$name"; then already_handled=yes break fi done if test -z "$already_handled"; then names_already_handled="$names_already_handled $name" uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` eval value=\"\$HAVE_LIB$uppername\" if test -n "$value"; then if test "$value" = yes; then eval value=\"\$LIB$uppername\" test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" eval value=\"\$LTLIB$uppername\" test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" else : fi else found_dir= found_la= found_so= found_a= eval libname=\"$acl_libname_spec\" # typically: libname=lib$name if test -n "$acl_shlibext"; then shrext=".$acl_shlibext" # typically: shrext=.so else shrext= fi if test $use_additional = yes; then dir="$additional_libdir" if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi fi if test "X$found_dir" = "X"; then for x in $LDFLAGS $LTLIBICONV; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" case "$x" in -L*) dir=`echo "X$x" | sed -e 's/^X-L//'` if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi ;; esac if test "X$found_dir" != "X"; then break fi done fi if test "X$found_dir" != "X"; then LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" if test "X$found_so" != "X"; then if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" else haveit= for x in $ltrpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $found_dir" fi if test "$acl_hardcode_direct" = yes; then LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" else if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" haveit= for x in $rpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $found_dir" fi else haveit= for x in $LDFLAGS $LIBICONV; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" fi if test "$acl_hardcode_minus_L" != no; then LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" else LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" fi fi fi fi else if test "X$found_a" != "X"; then LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" else LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" fi fi additional_includedir= case "$found_dir" in */$acl_libdirstem | */$acl_libdirstem/) basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` LIBICONV_PREFIX="$basedir" additional_includedir="$basedir/include" ;; esac if test "X$additional_includedir" != "X"; then if test "X$additional_includedir" != "X/usr/include"; then haveit= if test "X$additional_includedir" = "X/usr/local/include"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then for x in $CPPFLAGS $INCICONV; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-I$additional_includedir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_includedir"; then INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" fi fi fi fi fi if test -n "$found_la"; then save_libdir="$libdir" case "$found_la" in */* | *\\*) . "$found_la" ;; *) . "./$found_la" ;; esac libdir="$save_libdir" for dep in $dependency_libs; do case "$dep" in -L*) additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then haveit= if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then haveit= for x in $LDFLAGS $LIBICONV; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" fi fi haveit= for x in $LDFLAGS $LTLIBICONV; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" fi fi fi fi ;; -R*) dir=`echo "X$dep" | sed -e 's/^X-R//'` if test "$enable_rpath" != no; then haveit= for x in $rpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $dir" fi haveit= for x in $ltrpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $dir" fi fi ;; -l*) names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` ;; *.la) names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` ;; *) LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" ;; esac done fi else LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" fi fi fi done done if test "X$rpathdirs" != "X"; then if test -n "$acl_hardcode_libdir_separator"; then alldirs= for found_dir in $rpathdirs; do alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir" done acl_save_libdir="$libdir" libdir="$alldirs" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" else for found_dir in $rpathdirs; do acl_save_libdir="$libdir" libdir="$found_dir" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" done fi fi if test "X$ltrpathdirs" != "X"; then for found_dir in $ltrpathdirs; do LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" done fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; } if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then : $as_echo_n "(cached) " >&6 else gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { CFPreferencesCopyAppValue(NULL, NULL) ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_CFPreferencesCopyAppValue=yes else gt_cv_func_CFPreferencesCopyAppValue=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$gt_save_LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; } if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; } if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then : $as_echo_n "(cached) " >&6 else gt_save_LIBS="$LIBS" LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { CFLocaleCopyCurrent(); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : gt_cv_func_CFLocaleCopyCurrent=yes else gt_cv_func_CFLocaleCopyCurrent=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$gt_save_LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5 $as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; } if test $gt_cv_func_CFLocaleCopyCurrent = yes; then $as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h fi INTL_MACOSX_LIBS= if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" fi LIBINTL= LTLIBINTL= POSUB= case " $gt_needs " in *" need-formatstring-macros "*) gt_api_version=3 ;; *" need-ngettext "*) gt_api_version=2 ;; *) gt_api_version=1 ;; esac gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc" gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl" if test "$USE_NLS" = "yes"; then gt_use_preinstalled_gnugettext=no if test $gt_api_version -ge 3; then gt_revision_test_code=' #ifndef __GNU_GETTEXT_SUPPORTED_REVISION #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) #endif typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; ' else gt_revision_test_code= fi if test $gt_api_version -ge 2; then gt_expression_test_code=' + * ngettext ("", "", 0)' else gt_expression_test_code= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5 $as_echo_n "checking for GNU gettext in libc... " >&6; } if eval \${$gt_func_gnugettext_libc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern int *_nl_domain_bindings; int main () { bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$gt_func_gnugettext_libc=yes" else eval "$gt_func_gnugettext_libc=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$gt_func_gnugettext_libc { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then am_save_CPPFLAGS="$CPPFLAGS" for element in $INCICONV; do haveit= for x in $CPPFLAGS; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X$element"; then haveit=yes break fi done if test -z "$haveit"; then CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" fi done { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 $as_echo_n "checking for iconv... " >&6; } if ${am_cv_func_iconv+:} false; then : $as_echo_n "(cached) " >&6 else am_cv_func_iconv="no, consider installing GNU libiconv" am_cv_lib_iconv=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL); iconv_close(cd); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : am_cv_func_iconv=yes fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test "$am_cv_func_iconv" != yes; then am_save_LIBS="$LIBS" LIBS="$LIBS $LIBICONV" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL); iconv_close(cd); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : am_cv_lib_iconv=yes am_cv_func_iconv=yes fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS="$am_save_LIBS" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 $as_echo "$am_cv_func_iconv" >&6; } if test "$am_cv_func_iconv" = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5 $as_echo_n "checking for working iconv... " >&6; } if ${am_cv_func_iconv_works+:} false; then : $as_echo_n "(cached) " >&6 else am_save_LIBS="$LIBS" if test $am_cv_lib_iconv = yes; then LIBS="$LIBS $LIBICONV" fi if test "$cross_compiling" = yes; then : case "$host_os" in aix* | hpux*) am_cv_func_iconv_works="guessing no" ;; *) am_cv_func_iconv_works="guessing yes" ;; esac else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { /* Test against AIX 5.1 bug: Failures are not distinguishable from successful returns. */ { iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8"); if (cd_utf8_to_88591 != (iconv_t)(-1)) { static const char input[] = "\342\202\254"; /* EURO SIGN */ char buf[10]; const char *inptr = input; size_t inbytesleft = strlen (input); char *outptr = buf; size_t outbytesleft = sizeof (buf); size_t res = iconv (cd_utf8_to_88591, (char **) &inptr, &inbytesleft, &outptr, &outbytesleft); if (res == 0) return 1; } } #if 0 /* This bug could be worked around by the caller. */ /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */ { iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591"); if (cd_88591_to_utf8 != (iconv_t)(-1)) { static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337"; char buf[50]; const char *inptr = input; size_t inbytesleft = strlen (input); char *outptr = buf; size_t outbytesleft = sizeof (buf); size_t res = iconv (cd_88591_to_utf8, (char **) &inptr, &inbytesleft, &outptr, &outbytesleft); if ((int)res > 0) return 1; } } #endif /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is provided. */ if (/* Try standardized names. */ iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1) /* Try IRIX, OSF/1 names. */ && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1) /* Try AIX names. */ && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1) /* Try HP-UX names. */ && iconv_open ("utf8", "eucJP") == (iconv_t)(-1)) return 1; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : am_cv_func_iconv_works=yes else am_cv_func_iconv_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi LIBS="$am_save_LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5 $as_echo "$am_cv_func_iconv_works" >&6; } case "$am_cv_func_iconv_works" in *no) am_func_iconv=no am_cv_lib_iconv=no ;; *) am_func_iconv=yes ;; esac else am_func_iconv=no am_cv_lib_iconv=no fi if test "$am_func_iconv" = yes; then $as_echo "#define HAVE_ICONV 1" >>confdefs.h fi if test "$am_cv_lib_iconv" = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 $as_echo_n "checking how to link with libiconv... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 $as_echo "$LIBICONV" >&6; } else CPPFLAGS="$am_save_CPPFLAGS" LIBICONV= LTLIBICONV= fi use_additional=yes acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" # Check whether --with-libintl-prefix was given. if test "${with_libintl_prefix+set}" = set; then : withval=$with_libintl_prefix; if test "X$withval" = "Xno"; then use_additional=no else if test "X$withval" = "X"; then acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" else additional_includedir="$withval/include" additional_libdir="$withval/$acl_libdirstem" fi fi fi LIBINTL= LTLIBINTL= INCINTL= LIBINTL_PREFIX= rpathdirs= ltrpathdirs= names_already_handled= names_next_round='intl ' while test -n "$names_next_round"; do names_this_round="$names_next_round" names_next_round= for name in $names_this_round; do already_handled= for n in $names_already_handled; do if test "$n" = "$name"; then already_handled=yes break fi done if test -z "$already_handled"; then names_already_handled="$names_already_handled $name" uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` eval value=\"\$HAVE_LIB$uppername\" if test -n "$value"; then if test "$value" = yes; then eval value=\"\$LIB$uppername\" test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" eval value=\"\$LTLIB$uppername\" test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" else : fi else found_dir= found_la= found_so= found_a= eval libname=\"$acl_libname_spec\" # typically: libname=lib$name if test -n "$acl_shlibext"; then shrext=".$acl_shlibext" # typically: shrext=.so else shrext= fi if test $use_additional = yes; then dir="$additional_libdir" if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi fi if test "X$found_dir" = "X"; then for x in $LDFLAGS $LTLIBINTL; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" case "$x" in -L*) dir=`echo "X$x" | sed -e 's/^X-L//'` if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi ;; esac if test "X$found_dir" != "X"; then break fi done fi if test "X$found_dir" != "X"; then LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" if test "X$found_so" != "X"; then if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" else haveit= for x in $ltrpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $found_dir" fi if test "$acl_hardcode_direct" = yes; then LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" else if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" haveit= for x in $rpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $found_dir" fi else haveit= for x in $LDFLAGS $LIBINTL; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" fi if test "$acl_hardcode_minus_L" != no; then LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" else LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" fi fi fi fi else if test "X$found_a" != "X"; then LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" else LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" fi fi additional_includedir= case "$found_dir" in */$acl_libdirstem | */$acl_libdirstem/) basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` LIBINTL_PREFIX="$basedir" additional_includedir="$basedir/include" ;; esac if test "X$additional_includedir" != "X"; then if test "X$additional_includedir" != "X/usr/include"; then haveit= if test "X$additional_includedir" = "X/usr/local/include"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then for x in $CPPFLAGS $INCINTL; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-I$additional_includedir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_includedir"; then INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" fi fi fi fi fi if test -n "$found_la"; then save_libdir="$libdir" case "$found_la" in */* | *\\*) . "$found_la" ;; *) . "./$found_la" ;; esac libdir="$save_libdir" for dep in $dependency_libs; do case "$dep" in -L*) additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then haveit= if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then haveit= for x in $LDFLAGS $LIBINTL; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" fi fi haveit= for x in $LDFLAGS $LTLIBINTL; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" fi fi fi fi ;; -R*) dir=`echo "X$dep" | sed -e 's/^X-R//'` if test "$enable_rpath" != no; then haveit= for x in $rpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $dir" fi haveit= for x in $ltrpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $dir" fi fi ;; -l*) names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` ;; *.la) names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` ;; *) LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" ;; esac done fi else LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" fi fi fi done done if test "X$rpathdirs" != "X"; then if test -n "$acl_hardcode_libdir_separator"; then alldirs= for found_dir in $rpathdirs; do alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir" done acl_save_libdir="$libdir" libdir="$alldirs" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" else for found_dir in $rpathdirs; do acl_save_libdir="$libdir" libdir="$found_dir" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" done fi fi if test "X$ltrpathdirs" != "X"; then for found_dir in $ltrpathdirs; do LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" done fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5 $as_echo_n "checking for GNU gettext in libintl... " >&6; } if eval \${$gt_func_gnugettext_libintl+:} false; then : $as_echo_n "(cached) " >&6 else gt_save_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $INCINTL" gt_save_LIBS="$LIBS" LIBS="$LIBS $LIBINTL" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern #ifdef __cplusplus "C" #endif const char *_nl_expand_alias (const char *); int main () { bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("") ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$gt_func_gnugettext_libintl=yes" else eval "$gt_func_gnugettext_libintl=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then LIBS="$LIBS $LIBICONV" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern #ifdef __cplusplus "C" #endif const char *_nl_expand_alias (const char *); int main () { bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("") ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : LIBINTL="$LIBINTL $LIBICONV" LTLIBINTL="$LTLIBINTL $LTLIBICONV" eval "$gt_func_gnugettext_libintl=yes" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi CPPFLAGS="$gt_save_CPPFLAGS" LIBS="$gt_save_LIBS" fi eval ac_res=\$$gt_func_gnugettext_libintl { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \ || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \ && test "$PACKAGE" != gettext-runtime \ && test "$PACKAGE" != gettext-tools; }; then gt_use_preinstalled_gnugettext=yes else LIBINTL= LTLIBINTL= INCINTL= fi if test -n "$INTL_MACOSX_LIBS"; then if test "$gt_use_preinstalled_gnugettext" = "yes" \ || test "$nls_cv_use_gnu_gettext" = "yes"; then LIBINTL="$LIBINTL $INTL_MACOSX_LIBS" LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS" fi fi if test "$gt_use_preinstalled_gnugettext" = "yes" \ || test "$nls_cv_use_gnu_gettext" = "yes"; then $as_echo "#define ENABLE_NLS 1" >>confdefs.h else USE_NLS=no fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5 $as_echo_n "checking whether to use NLS... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 $as_echo "$USE_NLS" >&6; } if test "$USE_NLS" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5 $as_echo_n "checking where the gettext function comes from... " >&6; } if test "$gt_use_preinstalled_gnugettext" = "yes"; then if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then gt_source="external libintl" else gt_source="libc" fi else gt_source="included intl directory" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5 $as_echo "$gt_source" >&6; } fi if test "$USE_NLS" = "yes"; then if test "$gt_use_preinstalled_gnugettext" = "yes"; then if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5 $as_echo_n "checking how to link with libintl... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5 $as_echo "$LIBINTL" >&6; } for element in $INCINTL; do haveit= for x in $CPPFLAGS; do acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" eval x=\"$x\" exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" if test "X$x" = "X$element"; then haveit=yes break fi done if test -z "$haveit"; then CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" fi done fi $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h fi POSUB=po fi INTLLIBS="$LIBINTL" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in locale.h do : ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default" if test "x$ac_cv_header_locale_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LOCALE_H 1 _ACEOF fi done glib_module="glib-2.0 >= 2.3.6" if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_pt_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_pt_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_path_PKG_CONFIG" fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLIB" >&5 $as_echo_n "checking for GLIB... " >&6; } if test -n "$GLIB_CFLAGS"; then pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"\$glib_module\"\""; } >&5 ($PKG_CONFIG --exists --print-errors ""$glib_module"") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags ""$glib_module"" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$GLIB_LIBS"; then pkg_cv_GLIB_LIBS="$GLIB_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"\$glib_module\"\""; } >&5 ($PKG_CONFIG --exists --print-errors ""$glib_module"") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs ""$glib_module"" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs ""$glib_module"" 2>&1` else GLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs ""$glib_module"" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$GLIB_PKG_ERRORS" >&5 enable_glib_=no elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } enable_glib_=no else GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS GLIB_LIBS=$pkg_cv_GLIB_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } enable_glib_=yes fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-debug argument" >&5 $as_echo_n "checking --enable-debug argument... " >&6; } # Check whether --enable-debug was given. if test "${enable_debug+set}" = set; then : enableval=$enable_debug; enable_debug="yes" else enable_debug="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_debug" >&5 $as_echo "$enable_debug" >&6; } if test "$enable_debug" = "no"; then $as_echo "#define NDEBUG 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-xmlreport argument" >&5 $as_echo_n "checking --enable-xmlreport argument... " >&6; } # Check whether --enable-xmlreport was given. if test "${enable_xmlreport+set}" = set; then : enableval=$enable_xmlreport; enable_xmlreport="yes" else enable_xmlreport="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_xmlreport" >&5 $as_echo "$enable_xmlreport" >&6; } if test "$enable_xmlreport" = "yes"; then pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBXML2" >&5 $as_echo_n "checking for LIBXML2... " >&6; } if test -n "$LIBXML2_CFLAGS"; then pkg_cv_LIBXML2_CFLAGS="$LIBXML2_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"libxml-2.0\"\""; } >&5 ($PKG_CONFIG --exists --print-errors ""libxml-2.0"") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_LIBXML2_CFLAGS=`$PKG_CONFIG --cflags ""libxml-2.0"" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$LIBXML2_LIBS"; then pkg_cv_LIBXML2_LIBS="$LIBXML2_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"libxml-2.0\"\""; } >&5 ($PKG_CONFIG --exists --print-errors ""libxml-2.0"") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_LIBXML2_LIBS=`$PKG_CONFIG --libs ""libxml-2.0"" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then LIBXML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs ""libxml-2.0"" 2>&1` else LIBXML2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs ""libxml-2.0"" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$LIBXML2_PKG_ERRORS" >&5 skip_xmlreport=yes elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } skip_xmlreport=yes else LIBXML2_CFLAGS=$pkg_cv_LIBXML2_CFLAGS LIBXML2_LIBS=$pkg_cv_LIBXML2_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } skip_xmlreport=no fi if test "$skip_xmlreport" = "no"; then $as_echo "#define FEAT_XMLREPORT 1" >>confdefs.h fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-autoref argument" >&5 $as_echo_n "checking --enable-autoref argument... " >&6; } # Check whether --enable-autoref was given. if test "${enable_autoref+set}" = set; then : enableval=$enable_autoref; enable_autoref="yes" else enable_autoref="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_autoref" >&5 $as_echo "$enable_autoref" >&6; } if test "$enable_autoref" = "yes"; then $as_echo "#define FEAT_AUTOREF 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-history argument" >&5 $as_echo_n "checking --enable-history argument... " >&6; } # Check whether --enable-history was given. if test "${enable_history+set}" = set; then : enableval=$enable_history; enable_history="yes" else enable_history="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_history" >&5 $as_echo "$enable_history" >&6; } if test "$enable_history" = "yes"; then $as_echo "#define FEAT_HISTORY 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-clusters argument" >&5 $as_echo_n "checking --enable-clusters argument... " >&6; } # Check whether --enable-clusters was given. if test "${enable_clusters+set}" = set; then : enableval=$enable_clusters; enable_clusters="yes" else enable_clusters="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_clusters" >&5 $as_echo "$enable_clusters" >&6; } if test "$enable_clusters" = "yes"; then $as_echo "#define FEAT_CLUSTERS 1" >>confdefs.h fi # Some additional definitions $as_echo "#define HAVE_COLOR 1" >>confdefs.h $as_echo "#define HAVE_USE_DEFAULT_COLORS 1" >>confdefs.h $as_echo "#define HAVE_FLOCK 1" >>confdefs.h # Checks for programs. ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Checks for libraries. if eval "test x$CURSES_LIB_NAME = x"; then for ac_header in ncurses.h do : ac_fn_c_check_header_mongrel "$LINENO" "ncurses.h" "ac_cv_header_ncurses_h" "$ac_includes_default" if test "x$ac_cv_header_ncurses_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_NCURSES_H 1 _ACEOF fi done if test x$enable_utf8 != xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for get_wch in -lncursesw" >&5 $as_echo_n "checking for get_wch in -lncursesw... " >&6; } if ${ac_cv_lib_ncursesw_get_wch+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lncursesw $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char get_wch (); int main () { return get_wch (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ncursesw_get_wch=yes else ac_cv_lib_ncursesw_get_wch=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncursesw_get_wch" >&5 $as_echo "$ac_cv_lib_ncursesw_get_wch" >&6; } if test "x$ac_cv_lib_ncursesw_get_wch" = xyes; then : CURSES_LIB="-lncursesw" CPPFLAGS="-I/usr/include/ncursesw $CPPFLAGS" CURSES_LIB_NAME=ncursesw CURSES_LIB_WIDE=yes fi fi if eval "test x$CURSES_LIB_NAME = x"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lncurses" >&5 $as_echo_n "checking for initscr in -lncurses... " >&6; } if ${ac_cv_lib_ncurses_initscr+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lncurses $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char initscr (); int main () { return initscr (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_ncurses_initscr=yes else ac_cv_lib_ncurses_initscr=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_initscr" >&5 $as_echo "$ac_cv_lib_ncurses_initscr" >&6; } if test "x$ac_cv_lib_ncurses_initscr" = xyes; then : CURSES_LIB="-lncurses" CURSES_LIB_NAME=ncurses fi fi fi if eval "test x$CURSES_LIB_NAME = x"; then for ac_header in curses.h do : ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default" if test "x$ac_cv_header_curses_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_CURSES_H 1 _ACEOF fi done if test x$enable_utf8 != xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for get_wch in -lcurses" >&5 $as_echo_n "checking for get_wch in -lcurses... " >&6; } if ${ac_cv_lib_curses_get_wch+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lcurses $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char get_wch (); int main () { return get_wch (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_curses_get_wch=yes else ac_cv_lib_curses_get_wch=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_get_wch" >&5 $as_echo "$ac_cv_lib_curses_get_wch" >&6; } if test "x$ac_cv_lib_curses_get_wch" = xyes; then : CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses CURSES_LIB_WIDE=yes fi fi if eval "test x$CURSES_LIB_NAME = x"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lcurses" >&5 $as_echo_n "checking for initscr in -lcurses... " >&6; } if ${ac_cv_lib_curses_initscr+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lcurses $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char initscr (); int main () { return initscr (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_curses_initscr=yes else ac_cv_lib_curses_initscr=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_initscr" >&5 $as_echo "$ac_cv_lib_curses_initscr" >&6; } if test "x$ac_cv_lib_curses_initscr" = xyes; then : CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses fi fi fi if eval "test x$CURSES_LIB_NAME = x"; then as_fn_error $? " *** No curses lib available. Consider getting the official ncurses *** distribution from ftp://ftp.gnu.org/pub/gnu/ncurses if you get *** errors compiling nano." "$LINENO" 5 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using $CURSES_LIB_NAME as the curses library" >&5 $as_echo "Using $CURSES_LIB_NAME as the curses library" >&6; } fi LIBS="$LIBS $CURSES_LIB" for ac_header in popt.h do : ac_fn_c_check_header_mongrel "$LINENO" "popt.h" "ac_cv_header_popt_h" "$ac_includes_default" if test "x$ac_cv_header_popt_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_POPT_H 1 _ACEOF fi done { $as_echo "$as_me:${as_lineno-$LINENO}: checking for poptParseArgvString in -lpopt" >&5 $as_echo_n "checking for poptParseArgvString in -lpopt... " >&6; } if ${ac_cv_lib_popt_poptParseArgvString+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpopt $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char poptParseArgvString (); int main () { return poptParseArgvString (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_popt_poptParseArgvString=yes else ac_cv_lib_popt_poptParseArgvString=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_popt_poptParseArgvString" >&5 $as_echo "$ac_cv_lib_popt_poptParseArgvString" >&6; } if test "x$ac_cv_lib_popt_poptParseArgvString" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBPOPT 1 _ACEOF LIBS="-lpopt $LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for g_main_loop_run in -lglib-2.0" >&5 $as_echo_n "checking for g_main_loop_run in -lglib-2.0... " >&6; } if ${ac_cv_lib_glib_2_0_g_main_loop_run+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lglib-2.0 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char g_main_loop_run (); int main () { return g_main_loop_run (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_glib_2_0_g_main_loop_run=yes else ac_cv_lib_glib_2_0_g_main_loop_run=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_glib_2_0_g_main_loop_run" >&5 $as_echo "$ac_cv_lib_glib_2_0_g_main_loop_run" >&6; } if test "x$ac_cv_lib_glib_2_0_g_main_loop_run" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBGLIB_2_0 1 _ACEOF LIBS="-lglib-2.0 $LIBS" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for g_timeout_add_seconds in -lglib-2.0" >&5 $as_echo_n "checking for g_timeout_add_seconds in -lglib-2.0... " >&6; } if ${ac_cv_lib_glib_2_0_g_timeout_add_seconds+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lglib-2.0 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char g_timeout_add_seconds (); int main () { return g_timeout_add_seconds (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_glib_2_0_g_timeout_add_seconds=yes else ac_cv_lib_glib_2_0_g_timeout_add_seconds=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_glib_2_0_g_timeout_add_seconds" >&5 $as_echo "$ac_cv_lib_glib_2_0_g_timeout_add_seconds" >&6; } if test "x$ac_cv_lib_glib_2_0_g_timeout_add_seconds" = xyes; then : $as_echo "#define HAVE_GLIB_TIMEOUT_ADD_SECONDS 1" >>confdefs.h fi # Checks for header files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi for ac_header in fcntl.h stdlib.h string.h sys/file.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # Checks for typedefs, structures, and compiler characteristics. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 $as_echo_n "checking for an ANSI C-conforming const... " >&6; } if ${ac_cv_c_const+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __cplusplus /* Ultrix mips cc rejects this sort of thing. */ typedef int charset[2]; const charset cs = { 0, 0 }; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this sort of thing. */ char tx; char *t = &tx; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; } bx; struct s *b = &bx; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_const=yes else ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 $as_echo "$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then $as_echo "#define const /**/" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 $as_echo_n "checking for inline... " >&6; } if ${ac_cv_c_inline+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_inline=$ac_kw fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 $as_echo "$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } if ${ac_cv_struct_tm+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { struct tm tm; int *p = &tm.tm_sec; return !p; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_struct_tm=time.h else ac_cv_struct_tm=sys/time.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 $as_echo "$ac_cv_struct_tm" >&6; } if test $ac_cv_struct_tm = sys/time.h; then $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h fi # Check for TCL { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-tclfilter argument" >&5 $as_echo_n "checking --enable-tclfilter argument... " >&6; } # Check whether --enable-tclfilter was given. if test "${enable_tclfilter+set}" = set; then : enableval=$enable_tclfilter; else enable_tclfilter="no" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_tclfilter" >&5 $as_echo "$enable_tclfilter" >&6; } if test "$enable_tclfilter" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-tclsh argument" >&5 $as_echo_n "checking --with-tclsh argument... " >&6; } # Check whether --with-tclsh was given. if test "${with_tclsh+set}" = set; then : withval=$with_tclsh; tclsh_name="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tclsh_name" >&5 $as_echo "$tclsh_name" >&6; } else tclsh_name="tclsh8.5"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi # Extract the first word of "$tclsh_name", so it can be a program name with args. set dummy $tclsh_name; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_cv_path_tcl+:} false; then : $as_echo_n "(cached) " >&6 else case $cv_path_tcl in [\\/]* | ?:[\\/]*) ac_cv_path_cv_path_tcl="$cv_path_tcl" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi cv_path_tcl=$ac_cv_path_cv_path_tcl if test -n "$cv_path_tcl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cv_path_tcl" >&5 $as_echo "$cv_path_tcl" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "X$cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.4"; then tclsh_name="tclsh8.2" # Extract the first word of "$tclsh_name", so it can be a program name with args. set dummy $tclsh_name; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_cv_path_tcl+:} false; then : $as_echo_n "(cached) " >&6 else case $cv_path_tcl in [\\/]* | ?:[\\/]*) ac_cv_path_cv_path_tcl="$cv_path_tcl" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi cv_path_tcl=$ac_cv_path_cv_path_tcl if test -n "$cv_path_tcl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cv_path_tcl" >&5 $as_echo "$cv_path_tcl" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test "X$cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.2"; then tclsh_name="tclsh8.0" # Extract the first word of "$tclsh_name", so it can be a program name with args. set dummy $tclsh_name; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_cv_path_tcl+:} false; then : $as_echo_n "(cached) " >&6 else case $cv_path_tcl in [\\/]* | ?:[\\/]*) ac_cv_path_cv_path_tcl="$cv_path_tcl" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi cv_path_tcl=$ac_cv_path_cv_path_tcl if test -n "$cv_path_tcl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cv_path_tcl" >&5 $as_echo "$cv_path_tcl" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test "X$cv_path_tcl" = "X"; then tclsh_name="tclsh" # Extract the first word of "$tclsh_name", so it can be a program name with args. set dummy $tclsh_name; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_cv_path_tcl+:} false; then : $as_echo_n "(cached) " >&6 else case $cv_path_tcl in [\\/]* | ?:[\\/]*) ac_cv_path_cv_path_tcl="$cv_path_tcl" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_cv_path_tcl="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi cv_path_tcl=$ac_cv_path_cv_path_tcl if test -n "$cv_path_tcl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cv_path_tcl" >&5 $as_echo "$cv_path_tcl" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test "X$cv_path_tcl" != "X"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking Tcl version" >&5 $as_echo_n "checking Tcl version... " >&6; } if echo 'exit [expr [info tclversion] < 8.0]' | $cv_path_tcl - ; then tclver=`echo 'puts [info tclversion]' | $cv_path_tcl -` { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tclver - OK" >&5 $as_echo "$tclver - OK" >&6; }; tclloc=`echo 'set l [info library];set i [string last lib $l];incr i -2;puts [string range $l 0 $i]' | $cv_path_tcl -` { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of Tcl include" >&5 $as_echo_n "checking for location of Tcl include... " >&6; } if test "x$MACOSX" != "xyes"; then tclinc="$tclloc/include $tclloc/include/tcl $tclloc/include/tcl$tclver /usr/local/include /usr/include /usr/local/include/tcl$tclver /usr/include/tcl$tclver" else tclinc="/System/Library/Frameworks/Tcl.framework/Headers" fi for try in $tclinc; do if test -f "$try/tcl.h"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/tcl.h" >&5 $as_echo "$try/tcl.h" >&6; } TCL_INC=$try break fi done if test -z "$TCL_INC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5 $as_echo "" >&6; } SKIP_TCL=YES fi if test -z "$SKIP_TCL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for location of tclConfig.sh script" >&5 $as_echo_n "checking for location of tclConfig.sh script... " >&6; } if test "x$MACOSX" != "xyes"; then tclcnf=`echo $tclinc | sed s/include/lib/g`" $tclinc" else tclcnf="/System/Library/Frameworks/Tcl.framework" fi for try in $tclcnf; do if test -f $try/tclConfig.sh; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/tclConfig.sh" >&5 $as_echo "$try/tclConfig.sh" >&6; } . $try/tclConfig.sh TCL_LIBS=`eval echo "$TCL_LIB_SPEC $TCL_LIBS"` TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\\\ /\\\\X/g' | tr ' ' '\012' | sed -e '/^-[^D]/d' -e '/-D[^_]/d' -e 's/-D_/ -D_/' | tr '\012' ' ' | sed -e 's/\\\\X/\\\\ /g'` break fi done if test -z "$TCL_LIBS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5 $as_echo "" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl library by myself" >&5 $as_echo_n "checking for Tcl library by myself... " >&6; } tcllib=`echo $tclinc | sed s/include/lib/g` for ext in .so .a ; do for ver in "" $tclver ; do for try in $tcllib ; do trylib=tcl$ver$ext if test -f $try/lib$trylib ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $try/lib$trylib" >&5 $as_echo "$try/lib$trylib" >&6; } TCL_LIBS="-L$try -ltcl$ver" if test "`(uname) 2>/dev/null`" = SunOS && uname -r | grep '^5' >/dev/null; then TCL_LIBS="$TCL_LIBS -R $try" fi break 3 fi done done done if test -z "$TCL_LIBS"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5 $as_echo "" >&6; } SKIP_TCL=YES fi fi if test -z "$SKIP_TCL"; then $as_echo "#define FEAT_TCLFILTER 1" >>confdefs.h TCL_CFLAGS="-I$TCL_INC $TCL_DEFS" fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: result: too old; need Tcl version 8.0 or later" >&5 $as_echo "too old; need Tcl version 8.0 or later" >&6; } fi fi fi # Check if `screen' is installed on your system echo -n "checking for screen... " if test -x /usr/bin/screen; then screen_binary="/usr/bin/screen" elif test -x /usr/local/bin/screen; then screen_binary="/usr/local/bin/screen" elif test -x /bin/screen; then screen_binary="/bin/screen" else echo "not found at configure time." echo "Using mostly common systemdefault /usr/bin/screen." screen_binary="/usr/bin/screen" fi cat >>confdefs.h <<_ACEOF #define SCREEN_BINARY "$screen_binary" _ACEOF echo "$screen_binary" # Try to find out where screen stores the sockets echo -n "checking for screen socket path... " if test -x $screen_binary; then screen_sockpath=`build/screen_sockpath "$screen_binary"` if test ! -d "$screen_sockpath"; then echo "Got invalid path '$screen_sockpath' - fallback to common systemdefault." screen_sockpath="/var/run/screen" fi else echo "No screen binary available during build - fallback to common systemdefault." screen_sockpath="/var/run/screen" fi cat >>confdefs.h <<_ACEOF #define SCREEN_SOCKPATH "$screen_sockpath" _ACEOF echo "$screen_sockpath" # Check if `env' is installed on your system (used by history feature) if test "$enable_history" = "yes"; then echo -n "checking for env... " if test -x /usr/bin/env; then $as_echo "#define ENV_BINARY \"/usr/bin/env\"" >>confdefs.h echo "/usr/bin/env" elif test -x /usr/local/bin/env; then $as_echo "#define ENV_BINARY \"/usr/local/bin/env\"" >>confdefs.h echo "/usr/local/bin/env" elif test -x /bin/env; then $as_echo "#define ENV_BINARY \"/bin/env\"" >>confdefs.h echo "/bin/env" else echo "not found at configure time." echo "Using mostly common systemdefault /usr/bin/env." $as_echo "#define ENV_BINARY \"/usr/bin/env\"" >>confdefs.h echo "/usr/bin/env" fi fi # Check if `xsltproc' is installed on your system echo -n "checking for xsltproc... " if test -x /usr/bin/xsltproc ; then XSLTPROC="/usr/bin/xsltproc" echo $XSLTPROC elif test -x /usr/local/bin/xsltproc; then XSLTPROC="/usr/local/bin/xsltproc" echo $XSLTPROC elif test -x /bin/xsltproc; then XSLTPROC="/bin/xsltproc" echo $XSLTPROC else XSLTPROC="/bin/true" echo "not found." fi # Check if `docbook-xsl' is installed on your system echo -n "checking for docbook-xsl... " if test -d /usr/share/xml/docbook/stylesheet/nwalsh ; then DBXSL="/usr/share/xml/docbook/stylesheet/nwalsh" echo $DBXSL else DBXSL= echo "not found." fi # Checks for library functions. { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 $as_echo_n "checking return type of signal handlers... " >&6; } if ${ac_cv_type_signal+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include int main () { return *(signal (0, 0)) (0) == 1; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_type_signal=int else ac_cv_type_signal=void fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 $as_echo "$ac_cv_type_signal" >&6; } cat >>confdefs.h <<_ACEOF #define RETSIGTYPE $ac_cv_type_signal _ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; } if ${ac_cv_func_lstat_dereferences_slashed_symlink+:} false; then : $as_echo_n "(cached) " >&6 else rm -f conftest.sym conftest.file echo >conftest.file if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then if test "$cross_compiling" = yes; then : ac_cv_func_lstat_dereferences_slashed_symlink=no else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; /* Linux will dereference the symlink and fail, as required by POSIX. That is better in the sense that it means we will not have to compile and use the lstat wrapper. */ return lstat ("conftest.sym/", &sbuf) == 0; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_lstat_dereferences_slashed_symlink=yes else ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi else # If the `ln -s' command failed, then we probably don't even # have an lstat function. ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f conftest.sym conftest.file fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 $as_echo "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; } test $ac_cv_func_lstat_dereferences_slashed_symlink = yes && cat >>confdefs.h <<_ACEOF #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 _ACEOF if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then case " $LIBOBJS " in *" lstat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS lstat.$ac_objext" ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat accepts an empty string" >&5 $as_echo_n "checking whether stat accepts an empty string... " >&6; } if ${ac_cv_func_stat_empty_string_bug+:} false; then : $as_echo_n "(cached) " >&6 else if test "$cross_compiling" = yes; then : ac_cv_func_stat_empty_string_bug=yes else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; return stat ("", &sbuf) == 0; ; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_stat_empty_string_bug=no else ac_cv_func_stat_empty_string_bug=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_stat_empty_string_bug" >&5 $as_echo "$ac_cv_func_stat_empty_string_bug" >&6; } if test $ac_cv_func_stat_empty_string_bug = yes; then case " $LIBOBJS " in *" stat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS stat.$ac_objext" ;; esac cat >>confdefs.h <<_ACEOF #define HAVE_STAT_EMPTY_STRING_BUG 1 _ACEOF fi for ac_func in strftime do : ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" if test "x$ac_cv_func_strftime" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_STRFTIME 1 _ACEOF else # strftime is in -lintl on SCO UNIX. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5 $as_echo_n "checking for strftime in -lintl... " >&6; } if ${ac_cv_lib_intl_strftime+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char strftime (); int main () { return strftime (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_strftime=yes else ac_cv_lib_intl_strftime=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5 $as_echo "$ac_cv_lib_intl_strftime" >&6; } if test "x$ac_cv_lib_intl_strftime" = xyes; then : $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h LIBS="-lintl $LIBS" fi fi done for ac_func in memset strchr strdup strerror do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_config_files="$ac_config_files po/Makefile.in Makefile lib/Makefile man/Makefile src/Makefile build/apt-dater.spec" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else case $cache_file in #( */* | ?:*) mv -f confcache "$cache_file"$$ && mv -f "$cache_file"$$ "$cache_file" ;; #( *) mv -f confcache "$cache_file" ;; esac fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${LINUX_TRUE}" && test -z "${LINUX_FALSE}"; then as_fn_error $? "conditional \"LINUX\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${FREEBSD_TRUE}" && test -z "${FREEBSD_FALSE}"; then as_fn_error $? "conditional \"FREEBSD\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error $? "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by apt-dater $as_me 0.9.0, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ apt-dater config.status 0.9.0 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Copyright (C) 2012 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error $? "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # # Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it # from automake < 1.5. eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' # Capture the value of LINGUAS because we need it to compute CATALOGS. LINGUAS="${LINGUAS-%UNSET%}" AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;; "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "build/apt-dater.spec") CONFIG_FILES="$CONFIG_FILES build/apt-dater.spec" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap 'exit_status=$? : "${ac_tmp:=$tmp}" { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do ac_tt=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_tt"; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" case $ac_file in -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" } >"$ac_tmp/config.h" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in "$ac_file" | "$ac_file":* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for "$ac_file"" >`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "po-directories":C) for ac_file in $CONFIG_FILES; do # Support "outfile[:infile[:infile...]]" case "$ac_file" in *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; esac # PO directories have a Makefile.in generated from Makefile.in.in. case "$ac_file" in */Makefile.in) # Adjust a relative srcdir. ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` # In autoconf-2.13 it is called $ac_given_srcdir. # In autoconf-2.50 it is called $srcdir. test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" case "$ac_given_srcdir" in .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; /*) top_srcdir="$ac_given_srcdir" ;; *) top_srcdir="$ac_dots$ac_given_srcdir" ;; esac # Treat a directory as a PO directory if and only if it has a # POTFILES.in file. This allows packages to have multiple PO # directories under different names or in different locations. if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then rm -f "$ac_dir/POTFILES" test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" POMAKEFILEDEPS="POTFILES.in" # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend # on $ac_dir but don't depend on user-specified configuration # parameters. if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then # The LINGUAS file contains the set of available languages. if test -n "$OBSOLETE_ALL_LINGUAS"; then test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" fi ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"` # Hide the ALL_LINGUAS assigment from automake < 1.5. eval 'ALL_LINGUAS''=$ALL_LINGUAS_' POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" else # The set of available languages was given in configure.in. # Hide the ALL_LINGUAS assigment from automake < 1.5. eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' fi # Compute POFILES # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po) # Compute UPDATEPOFILES # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update) # Compute DUMMYPOFILES # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop) # Compute GMOFILES # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo) case "$ac_given_srcdir" in .) srcdirpre= ;; *) srcdirpre='$(srcdir)/' ;; esac POFILES= UPDATEPOFILES= DUMMYPOFILES= GMOFILES= for lang in $ALL_LINGUAS; do POFILES="$POFILES $srcdirpre$lang.po" UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" DUMMYPOFILES="$DUMMYPOFILES $lang.nop" GMOFILES="$GMOFILES $srcdirpre$lang.gmo" done # CATALOGS depends on both $ac_dir and the user's LINGUAS # environment variable. INST_LINGUAS= if test -n "$ALL_LINGUAS"; then for presentlang in $ALL_LINGUAS; do useit=no if test "%UNSET%" != "$LINGUAS"; then desiredlanguages="$LINGUAS" else desiredlanguages="$ALL_LINGUAS" fi for desiredlang in $desiredlanguages; do # Use the presentlang catalog if desiredlang is # a. equal to presentlang, or # b. a variant of presentlang (because in this case, # presentlang can be used as a fallback for messages # which are not translated in the desiredlang catalog). case "$desiredlang" in "$presentlang"*) useit=yes;; esac done if test $useit = yes; then INST_LINGUAS="$INST_LINGUAS $presentlang" fi done fi CATALOGS= if test -n "$INST_LINGUAS"; then for lang in $INST_LINGUAS; do CATALOGS="$CATALOGS $lang.gmo" done fi test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do if test -f "$f"; then case "$f" in *.orig | *.bak | *~) ;; *) cat "$f" >> "$ac_dir/Makefile" ;; esac fi done fi ;; esac done ;; "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir=$dirpart/$fdir; as_fn_mkdir_p # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi apt-dater-0.9.0/configure.in0000644000175000017500000002615311761141262015272 0ustar thomasthomas# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. PACKAGE=apt-dater AC_PREREQ(2.61) AC_INIT(apt-dater, 0.9.0, apt-dater@ibh.de) # Environment AC_CANONICAL_HOST AC_CANONICAL_TARGET AM_INIT_AUTOMAKE case "${target_os}" in darwin*) AC_DEFINE([DARWIN], [1], [Define if Darwin or Mac OS X]) ;; linux*) linux="yes" ;; freebsd*) freebsd="yes" ;; esac AM_CONDITIONAL(LINUX, test x"$linux" = x"yes") AM_CONDITIONAL(FREEBSD, test x"$freebsd" = x"yes") AC_CONFIG_SRCDIR([src/apt-dater.c]) AC_CONFIG_HEADER([config.h]) AM_GNU_GETTEXT([external]) AC_CHECK_HEADERS(locale.h) glib_module="glib-2.0 >= 2.3.6" PKG_CHECK_MODULES(GLIB, "$glib_module", enable_glib_=yes, enable_glib_=no) AC_MSG_CHECKING(--enable-debug argument) AC_ARG_ENABLE(debug, [ --enable-debug Enable debug code.], [enable_debug="yes"], [enable_debug="no"]) AC_MSG_RESULT($enable_debug) if test "$enable_debug" = "no"; then AC_DEFINE(NDEBUG, 1, [ Define if you want no debug code included. ]) fi AC_MSG_CHECKING(--enable-xmlreport argument) AC_ARG_ENABLE(xmlreport, [ --enable-xmlreport Include XML reports.], [enable_xmlreport="yes"], [enable_xmlreport="no"]) AC_MSG_RESULT($enable_xmlreport) if test "$enable_xmlreport" = "yes"; then PKG_CHECK_MODULES(LIBXML2, "libxml-2.0", skip_xmlreport=no, skip_xmlreport=yes) if test "$skip_xmlreport" = "no"; then AC_DEFINE(FEAT_XMLREPORT, 1, [ Define if you want XML report support included. ]) fi fi AC_MSG_CHECKING(--enable-autoref argument) AC_ARG_ENABLE(autoref, [ --enable-autoref Include 'auto refresh' support.], [enable_autoref="yes"], [enable_autoref="no"]) AC_MSG_RESULT($enable_autoref) if test "$enable_autoref" = "yes"; then AC_DEFINE(FEAT_AUTOREF, 1, [ Define if you want 'auto refresh' support included. ]) fi AC_MSG_CHECKING(--enable-history argument) AC_ARG_ENABLE(history, [ --enable-history Include 'history' support.], [enable_history="yes"], [enable_history="no"]) AC_MSG_RESULT($enable_history) if test "$enable_history" = "yes"; then AC_DEFINE(FEAT_HISTORY, 1, [ Define if you want 'history' support included. ]) fi AC_MSG_CHECKING(--enable-clusters argument) AC_ARG_ENABLE(clusters, [ --enable-clusters Include 'clusters' support.], [enable_clusters="yes"], [enable_clusters="no"]) AC_MSG_RESULT($enable_clusters) if test "$enable_clusters" = "yes"; then AC_DEFINE(FEAT_CLUSTERS, 1, [ Define if you want 'clusters' support included. ]) fi AC_SUBST(VERSION) AC_SUBST(PACKAGE) AC_SUBST(GLIB_CFLAGS) AC_SUBST(GLIB_LIBS) AC_SUBST(LIBXML2_CFLAGS) AC_SUBST(LIBXML2_LIBS) AC_PROG_INSTALL # Some additional definitions AC_DEFINE(HAVE_COLOR,1,[ Define if your curses library supports color. ]) AC_DEFINE(HAVE_USE_DEFAULT_COLORS,1, [ Define if your curses library supports function use_default_colors. ]) AC_DEFINE(HAVE_FLOCK,1,[ Define if funtion flock avaible. ]) # Checks for programs. AC_PROG_CC # Checks for libraries. if eval "test x$CURSES_LIB_NAME = x"; then AC_CHECK_HEADERS(ncurses.h) if test x$enable_utf8 != xno; then AC_CHECK_LIB(ncursesw, get_wch, [CURSES_LIB="-lncursesw" CPPFLAGS="-I/usr/include/ncursesw $CPPFLAGS" CURSES_LIB_NAME=ncursesw CURSES_LIB_WIDE=yes]) fi if eval "test x$CURSES_LIB_NAME = x"; then AC_CHECK_LIB(ncurses, initscr, [CURSES_LIB="-lncurses" CURSES_LIB_NAME=ncurses]) fi fi if eval "test x$CURSES_LIB_NAME = x"; then AC_CHECK_HEADERS(curses.h) if test x$enable_utf8 != xno; then AC_CHECK_LIB(curses, get_wch, [CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses CURSES_LIB_WIDE=yes]) fi if eval "test x$CURSES_LIB_NAME = x"; then AC_CHECK_LIB(curses, initscr, [CURSES_LIB="-lcurses" CURSES_LIB_NAME=curses]) fi fi if eval "test x$CURSES_LIB_NAME = x"; then AC_MSG_ERROR([ *** No curses lib available. Consider getting the official ncurses *** distribution from ftp://ftp.gnu.org/pub/gnu/ncurses if you get *** errors compiling nano.]) else AC_MSG_RESULT([Using $CURSES_LIB_NAME as the curses library]) fi LIBS="$LIBS $CURSES_LIB" AC_SUBST(CURSES_LIB) AC_CHECK_HEADERS(popt.h) AC_CHECK_LIB([popt], [poptParseArgvString]) AC_CHECK_LIB([glib-2.0], [g_main_loop_run]) AC_CHECK_LIB([glib-2.0], [g_timeout_add_seconds], AC_DEFINE(HAVE_GLIB_TIMEOUT_ADD_SECONDS, 1, [ Define if your GLIB supports the g_timeout_add_seconds call. ])) # Checks for header files. AC_HEADER_STDC AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/file.h unistd.h]) # Checks for typedefs, structures, and compiler characteristics. AC_C_CONST AC_C_INLINE AC_STRUCT_TM # Check for TCL AC_MSG_CHECKING(--enable-tclfilter argument) AC_ARG_ENABLE(tclfilter, [ --enable-tclfilter Include Tcl interpreter.], , [enable_tclfilter="no"]) AC_MSG_RESULT($enable_tclfilter) if test "$enable_tclfilter" = "yes"; then dnl on FreeBSD tclsh is a silly script, look for tclsh8.[420] AC_MSG_CHECKING(--with-tclsh argument) AC_ARG_WITH(tclsh, [ --with-tclsh=PATH which tclsh to use (default: tclsh8.5)], tclsh_name="$withval"; AC_MSG_RESULT($tclsh_name), tclsh_name="tclsh8.5"; AC_MSG_RESULT(no)) AC_PATH_PROG(cv_path_tcl, $tclsh_name) AC_SUBST(cv_path_tcl) dnl when no specific version specified, also try 8.2 and 8.0 if test "X$cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.4"; then tclsh_name="tclsh8.2" AC_PATH_PROG(cv_path_tcl, $tclsh_name) fi if test "X$cv_path_tcl" = "X" -a $tclsh_name = "tclsh8.2"; then tclsh_name="tclsh8.0" AC_PATH_PROG(cv_path_tcl, $tclsh_name) fi dnl still didn't find it, try without version number if test "X$cv_path_tcl" = "X"; then tclsh_name="tclsh" AC_PATH_PROG(cv_path_tcl, $tclsh_name) fi if test "X$cv_path_tcl" != "X"; then AC_MSG_CHECKING(Tcl version) if echo 'exit [[expr [info tclversion] < 8.0]]' | $cv_path_tcl - ; then tclver=`echo 'puts [[info tclversion]]' | $cv_path_tcl -` AC_MSG_RESULT($tclver - OK); tclloc=`echo 'set l [[info library]];set i [[string last lib $l]];incr i -2;puts [[string range $l 0 $i]]' | $cv_path_tcl -` AC_MSG_CHECKING(for location of Tcl include) if test "x$MACOSX" != "xyes"; then tclinc="$tclloc/include $tclloc/include/tcl $tclloc/include/tcl$tclver /usr/local/include /usr/include /usr/local/include/tcl$tclver /usr/include/tcl$tclver" else dnl For Mac OS X 10.3, use the OS-provided framework location tclinc="/System/Library/Frameworks/Tcl.framework/Headers" fi for try in $tclinc; do if test -f "$try/tcl.h"; then AC_MSG_RESULT($try/tcl.h) TCL_INC=$try break fi done if test -z "$TCL_INC"; then AC_MSG_RESULT() SKIP_TCL=YES fi if test -z "$SKIP_TCL"; then AC_MSG_CHECKING(for location of tclConfig.sh script) if test "x$MACOSX" != "xyes"; then tclcnf=`echo $tclinc | sed s/include/lib/g`" $tclinc" else dnl For Mac OS X 10.3, use the OS-provided framework location tclcnf="/System/Library/Frameworks/Tcl.framework" fi for try in $tclcnf; do if test -f $try/tclConfig.sh; then AC_MSG_RESULT($try/tclConfig.sh) . $try/tclConfig.sh dnl use eval, because tcl 8.2 includes ${TCL_DBGX} TCL_LIBS=`eval echo "$TCL_LIB_SPEC $TCL_LIBS"` dnl Use $TCL_DEFS for -D_THREAD_SAFE et al. But only use the dnl "-D_ABC" items. Watch out for -DFOO=long\ long. TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\\\ /\\\\X/g' | tr ' ' '\012' | sed -e '/^-[[^D]]/d' -e '/-D[[^_]]/d' -e 's/-D_/ -D_/' | tr '\012' ' ' | sed -e 's/\\\\X/\\\\ /g'` break fi done if test -z "$TCL_LIBS"; then AC_MSG_RESULT() AC_MSG_CHECKING(for Tcl library by myself) tcllib=`echo $tclinc | sed s/include/lib/g` for ext in .so .a ; do for ver in "" $tclver ; do for try in $tcllib ; do trylib=tcl$ver$ext if test -f $try/lib$trylib ; then AC_MSG_RESULT($try/lib$trylib) TCL_LIBS="-L$try -ltcl$ver" if test "`(uname) 2>/dev/null`" = SunOS && uname -r | grep '^5' >/dev/null; then TCL_LIBS="$TCL_LIBS -R $try" fi break 3 fi done done done if test -z "$TCL_LIBS"; then AC_MSG_RESULT() SKIP_TCL=YES fi fi if test -z "$SKIP_TCL"; then AC_DEFINE(FEAT_TCLFILTER, 1, [ Define if you want TCL filter support included. ]) TCL_CFLAGS="-I$TCL_INC $TCL_DEFS" fi fi else AC_MSG_RESULT(too old; need Tcl version 8.0 or later) fi fi fi AC_SUBST(TCL_CFLAGS) AC_SUBST(TCL_LIBS) # Check if `screen' is installed on your system echo -n "checking for screen... " if test -x /usr/bin/screen; then screen_binary="/usr/bin/screen" elif test -x /usr/local/bin/screen; then screen_binary="/usr/local/bin/screen" elif test -x /bin/screen; then screen_binary="/bin/screen" else echo "not found at configure time." echo "Using mostly common systemdefault /usr/bin/screen." screen_binary="/usr/bin/screen" fi AC_DEFINE_UNQUOTED(SCREEN_BINARY,"$screen_binary",[ Where is the command screen located. ]) echo "$screen_binary" # Try to find out where screen stores the sockets echo -n "checking for screen socket path... " if test -x $screen_binary; then screen_sockpath=`build/screen_sockpath "$screen_binary"` if test ! -d "$screen_sockpath"; then echo "Got invalid path '$screen_sockpath' - fallback to common systemdefault." screen_sockpath="/var/run/screen" fi else echo "No screen binary available during build - fallback to common systemdefault." screen_sockpath="/var/run/screen" fi AC_DEFINE_UNQUOTED(SCREEN_SOCKPATH,"$screen_sockpath",[ Where screen stores the sockets. ]) echo "$screen_sockpath" # Check if `env' is installed on your system (used by history feature) if test "$enable_history" = "yes"; then echo -n "checking for env... " if test -x /usr/bin/env; then AC_DEFINE(ENV_BINARY,"/usr/bin/env",[ Where is the command env located. ]) echo "/usr/bin/env" elif test -x /usr/local/bin/env; then AC_DEFINE(ENV_BINARY,"/usr/local/bin/env",[ Where is the command env located. ]) echo "/usr/local/bin/env" elif test -x /bin/env; then AC_DEFINE(ENV_BINARY,"/bin/env",[ Where is the command env located. ]) echo "/bin/env" else echo "not found at configure time." echo "Using mostly common systemdefault /usr/bin/env." AC_DEFINE(ENV_BINARY,"/usr/bin/env",[ Where is the command env located. ]) echo "/usr/bin/env" fi fi # Check if `xsltproc' is installed on your system echo -n "checking for xsltproc... " if test -x /usr/bin/xsltproc ; then XSLTPROC="/usr/bin/xsltproc" echo $XSLTPROC elif test -x /usr/local/bin/xsltproc; then XSLTPROC="/usr/local/bin/xsltproc" echo $XSLTPROC elif test -x /bin/xsltproc; then XSLTPROC="/bin/xsltproc" echo $XSLTPROC else XSLTPROC="/bin/true" echo "not found." fi AC_SUBST(XSLTPROC) # Check if `docbook-xsl' is installed on your system echo -n "checking for docbook-xsl... " if test -d /usr/share/xml/docbook/stylesheet/nwalsh ; then DBXSL="/usr/share/xml/docbook/stylesheet/nwalsh" echo $DBXSL else DBXSL= echo "not found." fi AC_SUBST(DBXSL) # Checks for library functions. AC_TYPE_SIGNAL AC_FUNC_STAT AC_FUNC_STRFTIME AC_CHECK_FUNCS([memset strchr strdup strerror]) AC_CONFIG_FILES([ po/Makefile.in Makefile lib/Makefile man/Makefile src/Makefile build/apt-dater.spec ]) AC_OUTPUT apt-dater-0.9.0/depcomp0000755000175000017500000003710011760757134014342 0ustar thomasthomas#! /bin/sh # depcomp - compile a program generating dependencies as side-effects scriptversion=2005-07-09.11 # Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva . case $1 in '') echo "$0: No command. Try \`$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: depcomp [--help] [--version] PROGRAM [ARGS] Run PROGRAMS ARGS to compile a file, generating dependencies as side-effects. Environment variables: depmode Dependency tracking mode. source Source file read by `PROGRAMS ARGS'. object Object file output by `PROGRAMS ARGS'. DEPDIR directory where to store dependencies. depfile Dependency file to output. tmpdepfile Temporary file to use when outputing dependencies. libtool Whether libtool is used (yes/no). Report bugs to . EOF exit $? ;; -v | --v*) echo "depcomp $scriptversion" exit $? ;; esac if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. depfile=${depfile-`echo "$object" | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like `#:fec' to the end of the # dependency line. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. In older versions, this file always lives in the # current directory. Also, the AIX compiler puts `$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test -f "$tmpdepfile"; then : else stripped=`echo "$stripped" | sed 's,^.*/,,'` tmpdepfile="$stripped.u" fi if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then outname="$stripped.o" # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; icc) # Intel's C compiler understands `-MD -MF file'. However on # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c # ICC 7.0 will fill foo.d with something like # foo.o: sub/foo.c # foo.o: sub/foo.h # which is wrong. We want: # sub/foo.o: sub/foo.c # sub/foo.o: sub/foo.h # sub/foo.c: # sub/foo.h: # ICC 7.1 will output # foo.o: sub/foo.c sub/foo.h # and will wrap long lines using \ : # foo.o: sub/foo.c ... \ # sub/foo.h ... \ # ... "$@" -MD -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each line is of the form `foo.o: dependent.h', # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this invocation # correctly. Breaking it into two sed invocations is a workaround. sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in `foo.d' instead, so we check for that too. # Subdirectories are respected. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then # With Tru64 cc, shared objects can also be used to make a # static library. This mecanism is used in libtool 1.4 series to # handle both shared and static libraries in a single compilation. # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. # # With libtool 1.5 this exception was removed, and libtool now # generates 2 separate objects for the 2 libraries. These two # compilations output dependencies in in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is # automatically cleaned when .libs/ is deleted, while ignoring # the former would cause a distcleancheck panic. tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4 tmpdepfile2=$dir$base.o.d # libtool 1.5 tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5 tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504 "$@" -Wc,-MD else tmpdepfile1=$dir$base.o.d tmpdepfile2=$dir$base.d tmpdepfile3=$dir$base.d tmpdepfile4=$dir$base.d "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a tab and a space in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M # Require at least two characters before searching for `:' # in the target name. This is to cope with DOS-style filenames: # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise. "$@" $dashmflag | sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # X makedepend shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes ;; esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" sed '1,2d' "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. "$@" || exit $? IFS=" " for arg do case "$arg" in "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: apt-dater-0.9.0/images/0000755000175000017500000000000011760757134014231 5ustar thomasthomasapt-dater-0.9.0/images/apt-dater.svg0000644000175000017500000001256311760757134016642 0ustar thomasthomas image/svg+xml 0 Hosts in status... q:quit ?:help /:search [ ] Updates pending[ ] Up to date[ ] Status file missing[ ] Refresh required[ ] In refresh[ ] Sessions[ ] Unknown apt-dater-0.9.0/images/apt-dater.xpm0000644000175000017500000001317711760757134016651 0ustar thomasthomas/* XPM */ static char *apt-dater[] = { /* columns rows colors chars-per-pixel */ "32 32 220 2", " c black", ". c #010101", "X c #020202", "o c gray1", "O c #040404", "+ c gray3", "@ c #090909", "# c gray4", "$ c #0B0B0B", "% c #0C0C0C", "& c gray5", "* c #0E0E0E", "= c #101010", "- c #111111", "; c gray7", ": c #131313", "> c #151515", ", c #1B1B1B", "< c gray11", "1 c gray12", "2 c #00013F", "3 c #3F011E", "4 c #3D081E", "5 c #3D0A1D", "6 c #3C1F1F", "7 c #36271A", "8 c #39261D", "9 c #202020", "0 c #222222", "q c #232323", "w c #252525", "e c gray15", "r c #272727", "t c #282828", "y c gray16", "u c gray17", "i c #2C2C2C", "p c #2D2D2D", "a c gray18", "s c #2F2F2F", "d c gray19", "f c #313131", "g c #323232", "h c gray20", "j c #353535", "k c gray21", "l c gray22", "z c #3A3A3A", "x c gray23", "c c #3C3C3C", "v c #3F3F3F", "b c #000040", "n c #00067C", "m c #00087B", "M c #00097B", "N c #000A7A", "B c #000B7A", "V c #000C79", "C c #000D79", "Z c #000E78", "A c #001077", "S c #001177", "D c #001276", "F c #001475", "G c #001B72", "H c #001C71", "J c #001D71", "K c #001E70", "L c #00206F", "P c #00216F", "I c #00236E", "U c #00246D", "Y c #00276C", "T c #00296B", "R c #002A6A", "E c #002B6A", "W c #002D69", "Q c #002F68", "! c #003167", "~ c #003266", "^ c #003366", "/ c #003664", "( c #003A62", ") c #003D61", "_ c #00415F", "` c #00475C", "' c #00604F", "] c #00624E", "[ c #00654D", "{ c #00664C", "} c #00684B", "| c #006B4A", " . c #006C49", ".. c #006E48", "X. c #007047", "o. c #007147", "O. c #007545", "+. c #007644", "@. c #007744", "#. c #007943", "$. c #007B42", "%. c #007D41", "&. c #007E40", "*. c #40001F", "=. c #40011F", "-. c #410220", ";. c #420321", ":. c #434343", ">. c #444444", ",. c gray27", "<. c #464646", "1. c gray28", "2. c #484848", "3. c gray29", "4. c #4B4B4B", "5. c #4C4C4C", "6. c #4E4E4E", "7. c #505050", "8. c #515151", "9. c gray33", "0. c gray34", "q. c #585858", "w. c #5A5A5A", "e. c #5B5B5B", "r. c gray36", "t. c #5D5D5D", "y. c gray37", "u. c #5F5F5F", "i. c #606060", "p. c gray38", "a. c #626262", "s. c gray39", "d. c #646464", "f. c #656565", "g. c gray40", "h. c #676767", "j. c DimGray", "k. c #6A6A6A", "l. c #6C6C6C", "z. c gray43", "x. c #6F6F6F", "c. c #717171", "v. c #727272", "b. c gray45", "n. c #747474", "m. c gray46", "M. c #777777", "N. c gray48", "B. c #7C7C7C", "V. c gray50", "C. c navy", "Z. c #00803F", "A. c #00823E", "S. c #00843D", "D. c #00893B", "F. c #008F38", "G. c #009236", "H. c #009B32", "J. c #009C31", "K. c #00A12F", "L. c #00A72C", "P. c #00B027", "I. c #00B127", "U. c #00B923", "Y. c #800000", "T. c #850B0B", "R. c #850C0C", "E. c #942929", "W. c #952C2C", "Q. c #962E2E", "!. c #973030", "~. c #983131", "^. c #993333", "/. c #9A3535", "(. c #9A3636", "). c #9D3B3B", "_. c #9E3D3D", "`. c #A04242", "'. c #A14343", "]. c #A14444", "[. c #A24646", "{. c #A34747", "}. c #A44949", "|. c #A44A4A", " X c #A54B4B", ".X c #A54C4C", "XX c #A74F4F", "oX c #A85151", "OX c #A95353", "+X c #AC5A5A", "@X c #AD5C5C", "#X c #AE5D5D", "$X c #AF6060", "%X c #B26565", "&X c #B36767", "*X c #B46969", "=X c #B56B6B", "-X c #B56C6C", ";X c #B87171", ":X c #B97373", ">X c #BA7676", ",X c #808080", "X+XXXE.'.].=XOXXX:X&X#XXXQ.Y.Y.Y.Y.Y.Y.Y.Y.", "Y.}.R.].W./.uX_.].#X_.'.^.!.#X_.oX^.}.}.].].>X(.Y.Y.Y.Y.Y.Y.Y.Y.", " z & p p p ; f $ ; p % f $ ", " 8. e.e.d.tXq V.8Xr 5XN..l.& ", " 4.% :.p j :.8.z 8.z p p f :.x q k >.k c <.3.s 0X$ ", " z % f z p $ :.; $ O p > O & & $ * + u $ $ q > ", " 6. e.z.k.tXz.M.0Xb.V.1Xu d.wX6X * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _ADPROTO_H #define _ADPROTO_H #define _ADP_QUOTE(x) #x #define ADP_QUOTE(x) _ADP_QUOTE(x) /* Version history. */ #define ADP_VERSION_0_1 0.1 #define ADP_VERSION_0_2 0.2 #define ADP_VERSION_0_3 0.3 #define ADP_VERSION_0_4 0.4 #define ADP_VERSION_0_5 0.5 #define ADP_VERSION_0_6 0.6 /* Most current protocol version. */ #define ADP_CURRENT_VERSION ADP_VERSION_0_5 /* Features since protocol version 0.1 */ #define ADP_FEATVER_ADPROTO ADP_VERSION_0_1 #define ADP_FEATVER_KERNELINFO ADP_VERSION_0_1 #define ADP_FEATVER_LSBREL ADP_VERSION_0_1 #define ADP_FEATVER_STATUS ADP_VERSION_0_1 /* Features since protocol version 0.2 */ #define ADP_FEATVER_FORBID ADP_VERSION_0_2 #define ADP_FEATVER_VIRT ADP_VERSION_0_2 /* Features since protocol version 0.3 */ #define ADP_FEATVER_UNAME ADP_VERSION_0_3 /* Features since protocol version 0.4 */ #define ADP_FEATVER_UUID ADP_VERSION_0_4 /* Features since protocol version 0.5 */ #define ADP_FEATVER_ADPERR ADP_VERSION_0_5 /* Features since protocol version 0.6 */ #define ADP_FEATVER_CLUSTER ADP_VERSION_0_6 /* Patterns */ #define ADP_STRLEN_ADPERR 255 #define ADP_PATTERN_ADPERR "ADPERR: %"ADP_QUOTE(ADP_STRLEN_ADPERR)"s" #define ADP_PATTERN_ADPROTO "ADPROTO: %f" #define ADP_PATTERN_FORBID "FORBID: %d" #define ADP_STRLEN_KERNELINFO 255 #define ADP_PATTERN_KERNELINFO "KERNELINFO: %d %"ADP_QUOTE(ADP_STRLEN_KERNELINFO)"s" #define ADP_STRLEN_UNAME 255 #define ADP_PATTERN_UNAME "UNAME: %"ADP_QUOTE(ADP_STRLEN_UNAME)"s" #define ADP_STRLEN_UUID 36 #define ADP_PATTERN_UUID "UUID: %"ADP_QUOTE(ADP_STRLEN_UUID)"s" #define ADP_STRLEN_VIRT 255 #define ADP_PATTERN_VIRT "VIRT: %"ADP_QUOTE(ADP_STRLEN_VIRT)"s" #define ADP_STRLEN_CLUSTER 255 #define ADP_PATTERN_CLUSTER "CLUSTER: %"ADP_QUOTE(ADP_STRLEN_CLUSTER)"s" #define ADP_STRLEN_ADPERR 255 #define ADP_PATTERN_ADPERR "ADPERR: %"ADP_QUOTE(ADP_STRLEN_ADPERR)"s" #endif /* _ADPROTO_H */ apt-dater-0.9.0/install-sh0000755000175000017500000002202111760757134014765 0ustar thomasthomas#!/bin/sh # install - install a program, script, or datafile scriptversion=2005-05-14.22 # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. It can only install one file at a time, a restriction # shared with many OS's install programs. # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" # put in absolute paths if you don't have them in your path; or use env. vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" chmodcmd="$chmodprog 0755" chowncmd= chgrpcmd= stripcmd= rmcmd="$rmprog -f" mvcmd="$mvprog" src= dst= dir_arg= dstarg= no_target_directory= usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: -c (ignored) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -s $stripprog installed files. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. --help display this help and exit. --version display version info and exit. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG " while test -n "$1"; do case $1 in -c) shift continue;; -d) dir_arg=true shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; --help) echo "$usage"; exit $?;; -m) chmodcmd="$chmodprog $2" shift shift continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -s) stripcmd=$stripprog shift continue;; -t) dstarg=$2 shift shift continue;; -T) no_target_directory=true shift continue;; --version) echo "$0 $scriptversion"; exit $?;; *) # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. test -n "$dir_arg$dstarg" && break # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dstarg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dstarg" shift # fnord fi shift # arg dstarg=$arg done break;; esac done if test -z "$1"; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call `install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi for src do # Protect names starting with `-'. case $src in -*) src=./$src ;; esac if test -n "$dir_arg"; then dst=$src src= if test -d "$dst"; then mkdircmd=: chmodcmd= else mkdircmd=$mkdirprog fi else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dstarg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dstarg # Protect names starting with `-'. case $dst in -*) dst=./$dst ;; esac # If destination is a directory, append the input filename; won't work # if double slashes aren't ignored. if test -d "$dst"; then if test -n "$no_target_directory"; then echo "$0: $dstarg: Is a directory" >&2 exit 1 fi dst=$dst/`basename "$src"` fi fi # This sed command emulates the dirname command. dstdir=`echo "$dst" | sed -e 's,/*$,,;s,[^/]*$,,;s,/*$,,;s,^$,.,'` # Make sure that the destination directory exists. # Skip lots of stat calls in the usual case. if test ! -d "$dstdir"; then defaultIFS=' ' IFS="${IFS-$defaultIFS}" oIFS=$IFS # Some sh's can't handle IFS=/ for some reason. IFS='%' set x `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'` shift IFS=$oIFS pathcomp= while test $# -ne 0 ; do pathcomp=$pathcomp$1 shift if test ! -d "$pathcomp"; then $mkdirprog "$pathcomp" # mkdir can fail with a `File exist' error in case several # install-sh are creating the directory concurrently. This # is OK. test -d "$pathcomp" || exit fi pathcomp=$pathcomp/ done fi if test -n "$dir_arg"; then $doit $mkdircmd "$dst" \ && { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; } else dstfile=`basename "$dst"` # Make a couple of temp file names in the proper directory. dsttmp=$dstdir/_inst.$$_ rmtmp=$dstdir/_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 trap '(exit $?); exit' 1 2 13 15 # Copy the file name to the temp name. $doit $cpprog "$src" "$dsttmp" && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } && # Now rename the file to the real destination. { $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \ || { # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { if test -f "$dstdir/$dstfile"; then $doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \ || $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \ || { echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2 (exit 1); exit 1 } else : fi } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dstdir/$dstfile" } } fi || { (exit 1); exit 1; } done # The final little trick to "correctly" pass the exit status to the exit trap. { (exit 0); exit 0 } # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: apt-dater-0.9.0/lib/0000755000175000017500000000000011761142205013516 5ustar thomasthomasapt-dater-0.9.0/lib/Makefile.am0000644000175000017500000000017711760757134015573 0ustar thomasthomas EXTRA_DISTS=cmd cmd: cmd install-exec-hook: $(mkinstalldirs) $(DESTDIR)$(pkglibdir) $(INSTALL) cmd $(DESTDIR)$(pkglibdir) apt-dater-0.9.0/lib/cmd0000755000175000017500000001131311760757134014222 0ustar thomasthomas#!/bin/sh # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2009-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # run_hist_cmd () { echo -n > "$AD_HIST_PATH/command" for i in "$@"; do echo -n "\"$i\" " >> "$AD_HIST_PATH/command" done chmod +x "$AD_HIST_PATH/command" script -c "$AD_HIST_PATH/command" -t "$AD_HIST_PATH/typescript" 2> "$AD_HIST_PATH/timingfile" echo -n "Duration=" >> "$AD_HIST_PATH/meta" cat "$AD_HIST_PATH/timingfile" | cut '-d ' -f1 | awk '{ s += $1 } END { print s }' >> "$AD_HIST_PATH/meta" if (egrep -aiqse "$AD_HIST_ERRPATTERN" "$AD_HIST_PATH/typescript"); then echo "ERRPATTERN=$AD_HIST_ERRPATTERN" >> "$AD_HIST_PATH/meta" touch "$AD_HIST_PATH/failed" fi } run_cmd () { $@ } run_hook () { if [ -n "$1" -a -d "$1" ]; then run-parts "$1" fi } if [ -x /usr/bin/lockfile-create -a -x /usr/bin/lockfile-remove ]; then LOCK_ACQ=/usr/bin/lockfile-create LOCK_REL=/usr/bin/lockfile-remove else if [ -x /usr/bin/lockfile ]; then LOCK_ACQ=/usr/bin/lockfile LOCK_REL="rm -f" fi fi lock_acq () { if [ -z "$LOCK_ACQ" ]; then echo echo "FATAL ERROR" echo "===========" echo echo "Your environment does not have lockfile(-create|-remove) available!" echo "You need to install lockfile-progs or procmail before using" echo "apt-dater-host clusters (see README.clusters)!" echo exit 1 fi $LOCK_ACQ $1 } lock_rel () { $LOCK_REL $1 } lock_cluster () { if [ "$AD_CLUSTERS" != "0" ]; then echo echo Acquiring cluster locks: REL="" for i in `seq 1 $AD_CLUSTERS`; do CLUSTER=`eval echo "\\\$AD_CLUSTER$i"` echo " $CLUSTER" LOCK_FILE="$AD_STATSDIR/_cluster_$CLUSTER" lock_acq $LOCK_FILE REL="echo ' $CLUSTER';lock_rel $LOCK_FILE;$REL" trap "echo;echo Releasing cluster locks:;$REL echo .Done.;echo" INT TERM EXIT done echo "Done." echo fi } if [ "$AD_HIST_RECORD" = "true" -a "$AD_ACTION" != 'refresh' ]; then WRAP="run_hist_cmd" else WRAP="run_cmd" fi handle_generic_ssh () { if [ -n "$AD_SSH_USER" ]; then my_ssh_user="-l $AD_SSH_USER"; else my_ssh_user="" fi if [ -n "$AD_SSH_PORT" ]; then my_ssh_port="-p $AD_SSH_PORT"; else my_ssh_port="" fi case "$AD_ACTION" in connect) run_hook "$AD_HOOK_PRE_CONNECT" $WRAP $AD_SSH_CMD $AD_SSH_ID $AD_SSH_OPTFLAGS $my_ssh_user $my_ssh_port "$AD_HOSTNAME" run_hook "$AD_HOOK_POST_CONNECT" ;; transfer) if [ -n "$AD_SSH_USER" ]; then my_sftp_user="$AD_SSH_USER@"; else my_sftp_user="" fi if [ -n "$AD_SSH_PORT" ]; then my_sftp_port="-oPort=$AD_SSH_PORT"; else my_sftp_port="" fi run_hook "$AD_HOOK_PRE_CONNECT" $WRAP $AD_SFTP_CMD $AD_SSH_ID $my_ssh_port $my_sftp_user"$AD_HOSTNAME" run_hook "$AD_HOOK_POST_CONNECT" ;; install) lock_cluster run_hook "$AD_HOOK_PRE_INSTALL" $WRAP $AD_SSH_CMD $AD_SSH_ID $AD_SSH_OPTFLAGS $my_ssh_user $my_ssh_port "$AD_HOSTNAME" `printf "$AD_CMD_INSTALL" "$AD_PARAM"` run_hook "$AD_HOOK_POST_INSTALL" ;; upgrade) lock_cluster run_hook "$AD_HOOK_PRE_UPGRADE" $WRAP $AD_SSH_CMD $AD_SSH_ID $AD_SSH_OPTFLAGS $my_ssh_user $my_ssh_port "$AD_HOSTNAME" $AD_CMD_UPGRADE run_hook "$AD_HOOK_POST_UPGRADE" ;; refresh) run_hook "$AD_HOOK_PRE_REFRESH" $AD_SSH_CMD $AD_SSH_ID -n -o BatchMode=yes -o ConnectTimeout=5 $my_ssh_user $my_ssh_port "$AD_HOSTNAME" $AD_CMD_REFRESH 2>&1 run_hook "$AD_HOOK_POST_REFRESH" ;; *) echo "Unhandled action '$AD_ACTION'!" 1>&2 echo 1>&2 set | grep ^AD_ 1>&2 echo 1>&2 exit 1; ;; esac } if [ -z "$AD_TYPE" -o "$AD_TYPE" = 'generic-ssh' ]; then handle_generic_ssh else if [ -x "$AD_PLUGINDIR/$AD_TYPE/cmd" ]; then $WRAP "$AD_PLUGINDIR/$AD_TYPE/cmd" else echo "No plugin to handle type '$AD_TYPE'!" 1>&2 echo 1>&2 set | grep ^AD_ 1>&2 echo 1>&2 exit 2; fi fi apt-dater-0.9.0/lib/Makefile.in0000644000175000017500000002233211761141270015566 0ustar thomasthomas# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ subdir = lib DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = SOURCES = DIST_SOURCES = DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CURSES_LIB = @CURSES_LIB@ CYGPATH_W = @CYGPATH_W@ DBXSL = @DBXSL@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FREEBSD_FALSE = @FREEBSD_FALSE@ FREEBSD_TRUE = @FREEBSD_TRUE@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLIB_CFLAGS = @GLIB_CFLAGS@ GLIB_LIBS = @GLIB_LIBS@ GMSGFMT = @GMSGFMT@ GMSGFMT_015 = @GMSGFMT_015@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ LDFLAGS = @LDFLAGS@ LIBICONV = @LIBICONV@ LIBINTL = @LIBINTL@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBXML2_CFLAGS = @LIBXML2_CFLAGS@ LIBXML2_LIBS = @LIBXML2_LIBS@ LINUX_FALSE = @LINUX_FALSE@ LINUX_TRUE = @LINUX_TRUE@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ TCL_CFLAGS = @TCL_CFLAGS@ TCL_LIBS = @TCL_LIBS@ USE_NLS = @USE_NLS@ VERSION = @VERSION@ XGETTEXT = @XGETTEXT@ XGETTEXT_015 = @XGETTEXT_015@ XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ XSLTPROC = @XSLTPROC@ ac_ct_CC = @ac_ct_CC@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ cv_path_tcl = @cv_path_tcl@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ EXTRA_DISTS = cmd all: all-am .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lib/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu lib/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh uninstall-info-am: tags: TAGS TAGS: ctags: CTAGS CTAGS: distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-exec-am: @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-info-am .PHONY: all all-am check check-am clean clean-generic distclean \ distclean-generic distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-exec \ install-exec-am install-exec-hook install-info install-info-am \ install-man install-strip installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic pdf pdf-am ps ps-am uninstall \ uninstall-am uninstall-info-am cmd: cmd install-exec-hook: $(mkinstalldirs) $(DESTDIR)$(pkglibdir) $(INSTALL) cmd $(DESTDIR)$(pkglibdir) # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: apt-dater-0.9.0/m4/0000755000175000017500000000000011760757134013304 5ustar thomasthomasapt-dater-0.9.0/m4/ChangeLog0000644000175000017500000000061511760757134015060 0ustar thomasthomas2009-03-02 gettextize * gettext.m4: New file, from gettext-0.17. * iconv.m4: New file, from gettext-0.17. * lib-ld.m4: New file, from gettext-0.17. * lib-link.m4: New file, from gettext-0.17. * lib-prefix.m4: New file, from gettext-0.17. * nls.m4: New file, from gettext-0.17. * po.m4: New file, from gettext-0.17. * progtest.m4: New file, from gettext-0.17. apt-dater-0.9.0/m4/gettext.m40000644000175000017500000003457011760757134015243 0ustar thomasthomas# gettext.m4 serial 60 (gettext-0.17) dnl Copyright (C) 1995-2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public dnl License but which still want to provide support for the GNU gettext dnl functionality. dnl Please note that the actual code of the GNU gettext library is covered dnl by the GNU Library General Public License, and the rest of the GNU dnl gettext package package is covered by the GNU General Public License. dnl They are *not* in the public domain. dnl Authors: dnl Ulrich Drepper , 1995-2000. dnl Bruno Haible , 2000-2006. dnl Macro to add for using GNU gettext. dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]). dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The dnl default (if it is not specified or empty) is 'no-libtool'. dnl INTLSYMBOL should be 'external' for packages with no intl directory, dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory. dnl If INTLSYMBOL is 'use-libtool', then a libtool library dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static, dnl depending on --{enable,disable}-{shared,static} and on the presence of dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library dnl $(top_builddir)/intl/libintl.a will be created. dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext dnl implementations (in libc or libintl) without the ngettext() function dnl will be ignored. If NEEDSYMBOL is specified and is dnl 'need-formatstring-macros', then GNU gettext implementations that don't dnl support the ISO C 99 formatstring macros will be ignored. dnl INTLDIR is used to find the intl libraries. If empty, dnl the value `$(top_builddir)/intl/' is used. dnl dnl The result of the configuration is one of three cases: dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled dnl and used. dnl Catalog format: GNU --> install in $(datadir) dnl Catalog extension: .mo after installation, .gmo in source tree dnl 2) GNU gettext has been found in the system's C library. dnl Catalog format: GNU --> install in $(datadir) dnl Catalog extension: .mo after installation, .gmo in source tree dnl 3) No internationalization, always use English msgid. dnl Catalog format: none dnl Catalog extension: none dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur. dnl The use of .gmo is historical (it was needed to avoid overwriting the dnl GNU format catalogs when building on a platform with an X/Open gettext), dnl but we keep it in order not to force irrelevant filename changes on the dnl maintainers. dnl AC_DEFUN([AM_GNU_GETTEXT], [ dnl Argument checking. ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], , [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT ])])])])]) ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], , [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT ])])])]) define([gt_included_intl], ifelse([$1], [external], ifdef([AM_GNU_GETTEXT_][INTL_SUBDIR], [yes], [no]), [yes])) define([gt_libtool_suffix_prefix], ifelse([$1], [use-libtool], [l], [])) gt_NEEDS_INIT AM_GNU_GETTEXT_NEED([$2]) AC_REQUIRE([AM_PO_SUBDIRS])dnl ifelse(gt_included_intl, yes, [ AC_REQUIRE([AM_INTL_SUBDIR])dnl ]) dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) AC_REQUIRE([AC_LIB_RPATH]) dnl Sometimes libintl requires libiconv, so first search for libiconv. dnl Ideally we would do this search only after the dnl if test "$USE_NLS" = "yes"; then dnl if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT dnl the configure script would need to contain the same shell code dnl again, outside any 'if'. There are two solutions: dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'. dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE. dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not dnl documented, we avoid it. ifelse(gt_included_intl, yes, , [ AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) ]) dnl Sometimes, on MacOS X, libintl requires linking with CoreFoundation. gt_INTL_MACOSX dnl Set USE_NLS. AC_REQUIRE([AM_NLS]) ifelse(gt_included_intl, yes, [ BUILD_INCLUDED_LIBINTL=no USE_INCLUDED_LIBINTL=no ]) LIBINTL= LTLIBINTL= POSUB= dnl Add a version number to the cache macros. case " $gt_needs " in *" need-formatstring-macros "*) gt_api_version=3 ;; *" need-ngettext "*) gt_api_version=2 ;; *) gt_api_version=1 ;; esac gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc" gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl" dnl If we use NLS figure out what method if test "$USE_NLS" = "yes"; then gt_use_preinstalled_gnugettext=no ifelse(gt_included_intl, yes, [ AC_MSG_CHECKING([whether included gettext is requested]) AC_ARG_WITH(included-gettext, [ --with-included-gettext use the GNU gettext library included here], nls_cv_force_use_gnu_gettext=$withval, nls_cv_force_use_gnu_gettext=no) AC_MSG_RESULT($nls_cv_force_use_gnu_gettext) nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" if test "$nls_cv_force_use_gnu_gettext" != "yes"; then ]) dnl User does not insist on using GNU NLS library. Figure out what dnl to use. If GNU gettext is available we use this. Else we have dnl to fall back to GNU NLS library. if test $gt_api_version -ge 3; then gt_revision_test_code=' #ifndef __GNU_GETTEXT_SUPPORTED_REVISION #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) #endif changequote(,)dnl typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; changequote([,])dnl ' else gt_revision_test_code= fi if test $gt_api_version -ge 2; then gt_expression_test_code=' + * ngettext ("", "", 0)' else gt_expression_test_code= fi AC_CACHE_CHECK([for GNU gettext in libc], [$gt_func_gnugettext_libc], [AC_TRY_LINK([#include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern int *_nl_domain_bindings;], [bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings], [eval "$gt_func_gnugettext_libc=yes"], [eval "$gt_func_gnugettext_libc=no"])]) if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then dnl Sometimes libintl requires libiconv, so first search for libiconv. ifelse(gt_included_intl, yes, , [ AM_ICONV_LINK ]) dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv]) dnl because that would add "-liconv" to LIBINTL and LTLIBINTL dnl even if libiconv doesn't exist. AC_LIB_LINKFLAGS_BODY([intl]) AC_CACHE_CHECK([for GNU gettext in libintl], [$gt_func_gnugettext_libintl], [gt_save_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $INCINTL" gt_save_LIBS="$LIBS" LIBS="$LIBS $LIBINTL" dnl Now see whether libintl exists and does not depend on libiconv. AC_TRY_LINK([#include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern #ifdef __cplusplus "C" #endif const char *_nl_expand_alias (const char *);], [bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")], [eval "$gt_func_gnugettext_libintl=yes"], [eval "$gt_func_gnugettext_libintl=no"]) dnl Now see whether libintl exists and depends on libiconv. if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then LIBS="$LIBS $LIBICONV" AC_TRY_LINK([#include $gt_revision_test_code extern int _nl_msg_cat_cntr; extern #ifdef __cplusplus "C" #endif const char *_nl_expand_alias (const char *);], [bindtextdomain ("", ""); return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")], [LIBINTL="$LIBINTL $LIBICONV" LTLIBINTL="$LTLIBINTL $LTLIBICONV" eval "$gt_func_gnugettext_libintl=yes" ]) fi CPPFLAGS="$gt_save_CPPFLAGS" LIBS="$gt_save_LIBS"]) fi dnl If an already present or preinstalled GNU gettext() is found, dnl use it. But if this macro is used in GNU gettext, and GNU dnl gettext is already preinstalled in libintl, we update this dnl libintl. (Cf. the install rule in intl/Makefile.in.) if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \ || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \ && test "$PACKAGE" != gettext-runtime \ && test "$PACKAGE" != gettext-tools; }; then gt_use_preinstalled_gnugettext=yes else dnl Reset the values set by searching for libintl. LIBINTL= LTLIBINTL= INCINTL= fi ifelse(gt_included_intl, yes, [ if test "$gt_use_preinstalled_gnugettext" != "yes"; then dnl GNU gettext is not found in the C library. dnl Fall back on included GNU gettext library. nls_cv_use_gnu_gettext=yes fi fi if test "$nls_cv_use_gnu_gettext" = "yes"; then dnl Mark actions used to generate GNU NLS library. BUILD_INCLUDED_LIBINTL=yes USE_INCLUDED_LIBINTL=yes LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV $LIBTHREAD" LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV $LTLIBTHREAD" LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` fi CATOBJEXT= if test "$gt_use_preinstalled_gnugettext" = "yes" \ || test "$nls_cv_use_gnu_gettext" = "yes"; then dnl Mark actions to use GNU gettext tools. CATOBJEXT=.gmo fi ]) if test -n "$INTL_MACOSX_LIBS"; then if test "$gt_use_preinstalled_gnugettext" = "yes" \ || test "$nls_cv_use_gnu_gettext" = "yes"; then dnl Some extra flags are needed during linking. LIBINTL="$LIBINTL $INTL_MACOSX_LIBS" LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS" fi fi if test "$gt_use_preinstalled_gnugettext" = "yes" \ || test "$nls_cv_use_gnu_gettext" = "yes"; then AC_DEFINE(ENABLE_NLS, 1, [Define to 1 if translation of program messages to the user's native language is requested.]) else USE_NLS=no fi fi AC_MSG_CHECKING([whether to use NLS]) AC_MSG_RESULT([$USE_NLS]) if test "$USE_NLS" = "yes"; then AC_MSG_CHECKING([where the gettext function comes from]) if test "$gt_use_preinstalled_gnugettext" = "yes"; then if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then gt_source="external libintl" else gt_source="libc" fi else gt_source="included intl directory" fi AC_MSG_RESULT([$gt_source]) fi if test "$USE_NLS" = "yes"; then if test "$gt_use_preinstalled_gnugettext" = "yes"; then if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then AC_MSG_CHECKING([how to link with libintl]) AC_MSG_RESULT([$LIBINTL]) AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL]) fi dnl For backward compatibility. Some packages may be using this. AC_DEFINE(HAVE_GETTEXT, 1, [Define if the GNU gettext() function is already present or preinstalled.]) AC_DEFINE(HAVE_DCGETTEXT, 1, [Define if the GNU dcgettext() function is already present or preinstalled.]) fi dnl We need to process the po/ directory. POSUB=po fi ifelse(gt_included_intl, yes, [ dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL dnl to 'yes' because some of the testsuite requires it. if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then BUILD_INCLUDED_LIBINTL=yes fi dnl Make all variables we use known to autoconf. AC_SUBST(BUILD_INCLUDED_LIBINTL) AC_SUBST(USE_INCLUDED_LIBINTL) AC_SUBST(CATOBJEXT) dnl For backward compatibility. Some configure.ins may be using this. nls_cv_header_intl= nls_cv_header_libgt= dnl For backward compatibility. Some Makefiles may be using this. DATADIRNAME=share AC_SUBST(DATADIRNAME) dnl For backward compatibility. Some Makefiles may be using this. INSTOBJEXT=.mo AC_SUBST(INSTOBJEXT) dnl For backward compatibility. Some Makefiles may be using this. GENCAT=gencat AC_SUBST(GENCAT) dnl For backward compatibility. Some Makefiles may be using this. INTLOBJS= if test "$USE_INCLUDED_LIBINTL" = yes; then INTLOBJS="\$(GETTOBJS)" fi AC_SUBST(INTLOBJS) dnl Enable libtool support if the surrounding package wishes it. INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX) ]) dnl For backward compatibility. Some Makefiles may be using this. INTLLIBS="$LIBINTL" AC_SUBST(INTLLIBS) dnl Make all documented variables known to autoconf. AC_SUBST(LIBINTL) AC_SUBST(LTLIBINTL) AC_SUBST(POSUB) ]) dnl gt_NEEDS_INIT ensures that the gt_needs variable is initialized. m4_define([gt_NEEDS_INIT], [ m4_divert_text([DEFAULTS], [gt_needs=]) m4_define([gt_NEEDS_INIT], []) ]) dnl Usage: AM_GNU_GETTEXT_NEED([NEEDSYMBOL]) AC_DEFUN([AM_GNU_GETTEXT_NEED], [ m4_divert_text([INIT_PREPARE], [gt_needs="$gt_needs $1"]) ]) dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) apt-dater-0.9.0/m4/iconv.m40000644000175000017500000001375311760757134014675 0ustar thomasthomas# iconv.m4 serial AM6 (gettext-0.17) dnl Copyright (C) 2000-2002, 2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl From Bruno Haible. AC_DEFUN([AM_ICONV_LINKFLAGS_BODY], [ dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) AC_REQUIRE([AC_LIB_RPATH]) dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV dnl accordingly. AC_LIB_LINKFLAGS_BODY([iconv]) ]) AC_DEFUN([AM_ICONV_LINK], [ dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and dnl those with the standalone portable GNU libiconv installed). AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV dnl accordingly. AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) dnl Add $INCICONV to CPPFLAGS before performing the following checks, dnl because if the user has installed libiconv and not disabled its use dnl via --without-libiconv-prefix, he wants to use it. The first dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed. am_save_CPPFLAGS="$CPPFLAGS" AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV]) AC_CACHE_CHECK([for iconv], am_cv_func_iconv, [ am_cv_func_iconv="no, consider installing GNU libiconv" am_cv_lib_iconv=no AC_TRY_LINK([#include #include ], [iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL); iconv_close(cd);], am_cv_func_iconv=yes) if test "$am_cv_func_iconv" != yes; then am_save_LIBS="$LIBS" LIBS="$LIBS $LIBICONV" AC_TRY_LINK([#include #include ], [iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL); iconv_close(cd);], am_cv_lib_iconv=yes am_cv_func_iconv=yes) LIBS="$am_save_LIBS" fi ]) if test "$am_cv_func_iconv" = yes; then AC_CACHE_CHECK([for working iconv], am_cv_func_iconv_works, [ dnl This tests against bugs in AIX 5.1 and HP-UX 11.11. am_save_LIBS="$LIBS" if test $am_cv_lib_iconv = yes; then LIBS="$LIBS $LIBICONV" fi AC_TRY_RUN([ #include #include int main () { /* Test against AIX 5.1 bug: Failures are not distinguishable from successful returns. */ { iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8"); if (cd_utf8_to_88591 != (iconv_t)(-1)) { static const char input[] = "\342\202\254"; /* EURO SIGN */ char buf[10]; const char *inptr = input; size_t inbytesleft = strlen (input); char *outptr = buf; size_t outbytesleft = sizeof (buf); size_t res = iconv (cd_utf8_to_88591, (char **) &inptr, &inbytesleft, &outptr, &outbytesleft); if (res == 0) return 1; } } #if 0 /* This bug could be worked around by the caller. */ /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */ { iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591"); if (cd_88591_to_utf8 != (iconv_t)(-1)) { static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337"; char buf[50]; const char *inptr = input; size_t inbytesleft = strlen (input); char *outptr = buf; size_t outbytesleft = sizeof (buf); size_t res = iconv (cd_88591_to_utf8, (char **) &inptr, &inbytesleft, &outptr, &outbytesleft); if ((int)res > 0) return 1; } } #endif /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is provided. */ if (/* Try standardized names. */ iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1) /* Try IRIX, OSF/1 names. */ && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1) /* Try AIX names. */ && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1) /* Try HP-UX names. */ && iconv_open ("utf8", "eucJP") == (iconv_t)(-1)) return 1; return 0; }], [am_cv_func_iconv_works=yes], [am_cv_func_iconv_works=no], [case "$host_os" in aix* | hpux*) am_cv_func_iconv_works="guessing no" ;; *) am_cv_func_iconv_works="guessing yes" ;; esac]) LIBS="$am_save_LIBS" ]) case "$am_cv_func_iconv_works" in *no) am_func_iconv=no am_cv_lib_iconv=no ;; *) am_func_iconv=yes ;; esac else am_func_iconv=no am_cv_lib_iconv=no fi if test "$am_func_iconv" = yes; then AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function and it works.]) fi if test "$am_cv_lib_iconv" = yes; then AC_MSG_CHECKING([how to link with libiconv]) AC_MSG_RESULT([$LIBICONV]) else dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV dnl either. CPPFLAGS="$am_save_CPPFLAGS" LIBICONV= LTLIBICONV= fi AC_SUBST(LIBICONV) AC_SUBST(LTLIBICONV) ]) AC_DEFUN([AM_ICONV], [ AM_ICONV_LINK if test "$am_cv_func_iconv" = yes; then AC_MSG_CHECKING([for iconv declaration]) AC_CACHE_VAL(am_cv_proto_iconv, [ AC_TRY_COMPILE([ #include #include extern #ifdef __cplusplus "C" #endif #if defined(__STDC__) || defined(__cplusplus) size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); #else size_t iconv(); #endif ], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const") am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"]) am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` AC_MSG_RESULT([$]{ac_t:- }[$]am_cv_proto_iconv) AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1, [Define as const if the declaration of iconv() needs const.]) fi ]) apt-dater-0.9.0/m4/lib-ld.m40000644000175000017500000000653111760757134014716 0ustar thomasthomas# lib-ld.m4 serial 3 (gettext-0.13) dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl Subroutines of libtool.m4, dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision dnl with libtool.m4. dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no. AC_DEFUN([AC_LIB_PROG_LD_GNU], [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld, [# I'd rather use --version here, but apparently some GNU ld's only accept -v. case `$LD -v 2>&1 conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by GCC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]* | [A-Za-z]:[\\/]*)] [re_direlt='/[^/][^/]*/\.\./'] # Canonicalize the path of ld ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(acl_cv_path_LD, [if test -z "$LD"; then IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then acl_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some GNU ld's only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in *GNU* | *'with BFD'*) test "$with_gnu_ld" != no && break ;; *) test "$with_gnu_ld" != yes && break ;; esac fi done IFS="$ac_save_ifs" else acl_cv_path_LD="$LD" # Let the user override the test with a path. fi]) LD="$acl_cv_path_LD" if test -n "$LD"; then AC_MSG_RESULT($LD) else AC_MSG_RESULT(no) fi test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) AC_LIB_PROG_LD_GNU ]) apt-dater-0.9.0/m4/lib-link.m40000644000175000017500000007205511760757134015260 0ustar thomasthomas# lib-link.m4 serial 13 (gettext-0.17) dnl Copyright (C) 2001-2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl From Bruno Haible. AC_PREREQ(2.54) dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and dnl the libraries corresponding to explicit and implicit dependencies. dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and dnl augments the CPPFLAGS variable. dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. AC_DEFUN([AC_LIB_LINKFLAGS], [ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) AC_REQUIRE([AC_LIB_RPATH]) define([Name],[translit([$1],[./-], [___])]) define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [ AC_LIB_LINKFLAGS_BODY([$1], [$2]) ac_cv_lib[]Name[]_libs="$LIB[]NAME" ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME" ac_cv_lib[]Name[]_cppflags="$INC[]NAME" ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX" ]) LIB[]NAME="$ac_cv_lib[]Name[]_libs" LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs" INC[]NAME="$ac_cv_lib[]Name[]_cppflags" LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix" AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) AC_SUBST([LIB]NAME) AC_SUBST([LTLIB]NAME) AC_SUBST([LIB]NAME[_PREFIX]) dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the dnl results of this search when this library appears as a dependency. HAVE_LIB[]NAME=yes undefine([Name]) undefine([NAME]) ]) dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode) dnl searches for libname and the libraries corresponding to explicit and dnl implicit dependencies, together with the specified include files and dnl the ability to compile and link the specified testcode. If found, it dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], [ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) AC_REQUIRE([AC_LIB_RPATH]) define([Name],[translit([$1],[./-], [___])]) define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME dnl accordingly. AC_LIB_LINKFLAGS_BODY([$1], [$2]) dnl Add $INC[]NAME to CPPFLAGS before performing the following checks, dnl because if the user has installed lib[]Name and not disabled its use dnl via --without-lib[]Name-prefix, he wants to use it. ac_save_CPPFLAGS="$CPPFLAGS" AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ ac_save_LIBS="$LIBS" LIBS="$LIBS $LIB[]NAME" AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no]) LIBS="$ac_save_LIBS" ]) if test "$ac_cv_lib[]Name" = yes; then HAVE_LIB[]NAME=yes AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.]) AC_MSG_CHECKING([how to link with lib[]$1]) AC_MSG_RESULT([$LIB[]NAME]) else HAVE_LIB[]NAME=no dnl If $LIB[]NAME didn't lead to a usable library, we don't need dnl $INC[]NAME either. CPPFLAGS="$ac_save_CPPFLAGS" LIB[]NAME= LTLIB[]NAME= LIB[]NAME[]_PREFIX= fi AC_SUBST([HAVE_LIB]NAME) AC_SUBST([LIB]NAME) AC_SUBST([LTLIB]NAME) AC_SUBST([LIB]NAME[_PREFIX]) undefine([Name]) undefine([NAME]) ]) dnl Determine the platform dependent parameters needed to use rpath: dnl acl_libext, dnl acl_shlibext, dnl acl_hardcode_libdir_flag_spec, dnl acl_hardcode_libdir_separator, dnl acl_hardcode_direct, dnl acl_hardcode_minus_L. AC_DEFUN([AC_LIB_RPATH], [ dnl Tell automake >= 1.10 to complain if config.rpath is missing. m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])]) AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [ CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh . ./conftest.sh rm -f ./conftest.sh acl_cv_rpath=done ]) wl="$acl_cv_wl" acl_libext="$acl_cv_libext" acl_shlibext="$acl_cv_shlibext" acl_libname_spec="$acl_cv_libname_spec" acl_library_names_spec="$acl_cv_library_names_spec" acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" acl_hardcode_direct="$acl_cv_hardcode_direct" acl_hardcode_minus_L="$acl_cv_hardcode_minus_L" dnl Determine whether the user wants rpath handling at all. AC_ARG_ENABLE(rpath, [ --disable-rpath do not hardcode runtime library paths], :, enable_rpath=yes) ]) dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and dnl the libraries corresponding to explicit and implicit dependencies. dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables. dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem. AC_DEFUN([AC_LIB_LINKFLAGS_BODY], [ AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) dnl Autoconf >= 2.61 supports dots in --with options. define([N_A_M_E],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit([$1],[.],[_])],[$1])]) dnl By default, look in $includedir and $libdir. use_additional=yes AC_LIB_WITH_FINAL_PREFIX([ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) AC_LIB_ARG_WITH([lib]N_A_M_E[-prefix], [ --with-lib]N_A_M_E[-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib --without-lib]N_A_M_E[-prefix don't search for lib$1 in includedir and libdir], [ if test "X$withval" = "Xno"; then use_additional=no else if test "X$withval" = "X"; then AC_LIB_WITH_FINAL_PREFIX([ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) else additional_includedir="$withval/include" additional_libdir="$withval/$acl_libdirstem" fi fi ]) dnl Search the library and its dependencies in $additional_libdir and dnl $LDFLAGS. Using breadth-first-seach. LIB[]NAME= LTLIB[]NAME= INC[]NAME= LIB[]NAME[]_PREFIX= rpathdirs= ltrpathdirs= names_already_handled= names_next_round='$1 $2' while test -n "$names_next_round"; do names_this_round="$names_next_round" names_next_round= for name in $names_this_round; do already_handled= for n in $names_already_handled; do if test "$n" = "$name"; then already_handled=yes break fi done if test -z "$already_handled"; then names_already_handled="$names_already_handled $name" dnl See if it was already located by an earlier AC_LIB_LINKFLAGS dnl or AC_LIB_HAVE_LINKFLAGS call. uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` eval value=\"\$HAVE_LIB$uppername\" if test -n "$value"; then if test "$value" = yes; then eval value=\"\$LIB$uppername\" test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value" eval value=\"\$LTLIB$uppername\" test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value" else dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined dnl that this library doesn't exist. So just drop it. : fi else dnl Search the library lib$name in $additional_libdir and $LDFLAGS dnl and the already constructed $LIBNAME/$LTLIBNAME. found_dir= found_la= found_so= found_a= eval libname=\"$acl_libname_spec\" # typically: libname=lib$name if test -n "$acl_shlibext"; then shrext=".$acl_shlibext" # typically: shrext=.so else shrext= fi if test $use_additional = yes; then dir="$additional_libdir" dnl The same code as in the loop below: dnl First look for a shared library. if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi dnl Then look for a static library. if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi fi if test "X$found_dir" = "X"; then for x in $LDFLAGS $LTLIB[]NAME; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) case "$x" in -L*) dir=`echo "X$x" | sed -e 's/^X-L//'` dnl First look for a shared library. if test -n "$acl_shlibext"; then if test -f "$dir/$libname$shrext"; then found_dir="$dir" found_so="$dir/$libname$shrext" else if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ver=`(cd "$dir" && \ for f in "$libname$shrext".*; do echo "$f"; done \ | sed -e "s,^$libname$shrext\\\\.,," \ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ | sed 1q ) 2>/dev/null` if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then found_dir="$dir" found_so="$dir/$libname$shrext.$ver" fi else eval library_names=\"$acl_library_names_spec\" for f in $library_names; do if test -f "$dir/$f"; then found_dir="$dir" found_so="$dir/$f" break fi done fi fi fi dnl Then look for a static library. if test "X$found_dir" = "X"; then if test -f "$dir/$libname.$acl_libext"; then found_dir="$dir" found_a="$dir/$libname.$acl_libext" fi fi if test "X$found_dir" != "X"; then if test -f "$dir/$libname.la"; then found_la="$dir/$libname.la" fi fi ;; esac if test "X$found_dir" != "X"; then break fi done fi if test "X$found_dir" != "X"; then dnl Found the library. LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name" if test "X$found_so" != "X"; then dnl Linking with a shared library. We attempt to hardcode its dnl directory into the executable's runpath, unless it's the dnl standard /usr/lib. if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then dnl No hardcoding is needed. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" else dnl Use an explicit option to hardcode DIR into the resulting dnl binary. dnl Potentially add DIR to ltrpathdirs. dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. haveit= for x in $ltrpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $found_dir" fi dnl The hardcoding into $LIBNAME is system dependent. if test "$acl_hardcode_direct" = yes; then dnl Using DIR/libNAME.so during linking hardcodes DIR into the dnl resulting binary. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" else if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then dnl Use an explicit option to hardcode DIR into the resulting dnl binary. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" dnl Potentially add DIR to rpathdirs. dnl The rpathdirs will be appended to $LIBNAME at the end. haveit= for x in $rpathdirs; do if test "X$x" = "X$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $found_dir" fi else dnl Rely on "-L$found_dir". dnl But don't add it if it's already contained in the LDFLAGS dnl or the already constructed $LIBNAME haveit= for x in $LDFLAGS $LIB[]NAME; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-L$found_dir"; then haveit=yes break fi done if test -z "$haveit"; then LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir" fi if test "$acl_hardcode_minus_L" != no; then dnl FIXME: Not sure whether we should use dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" dnl here. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" else dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH dnl here, because this doesn't fit in flags passed to the dnl compiler. So give up. No hardcoding. This affects only dnl very old systems. dnl FIXME: Not sure whether we should use dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" dnl here. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" fi fi fi fi else if test "X$found_a" != "X"; then dnl Linking with a static library. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a" else dnl We shouldn't come here, but anyway it's good to have a dnl fallback. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name" fi fi dnl Assume the include files are nearby. additional_includedir= case "$found_dir" in */$acl_libdirstem | */$acl_libdirstem/) basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` LIB[]NAME[]_PREFIX="$basedir" additional_includedir="$basedir/include" ;; esac if test "X$additional_includedir" != "X"; then dnl Potentially add $additional_includedir to $INCNAME. dnl But don't add it dnl 1. if it's the standard /usr/include, dnl 2. if it's /usr/local/include and we are using GCC on Linux, dnl 3. if it's already present in $CPPFLAGS or the already dnl constructed $INCNAME, dnl 4. if it doesn't exist as a directory. if test "X$additional_includedir" != "X/usr/include"; then haveit= if test "X$additional_includedir" = "X/usr/local/include"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then for x in $CPPFLAGS $INC[]NAME; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-I$additional_includedir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_includedir"; then dnl Really add $additional_includedir to $INCNAME. INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir" fi fi fi fi fi dnl Look for dependencies. if test -n "$found_la"; then dnl Read the .la file. It defines the variables dnl dlname, library_names, old_library, dependency_libs, current, dnl age, revision, installed, dlopen, dlpreopen, libdir. save_libdir="$libdir" case "$found_la" in */* | *\\*) . "$found_la" ;; *) . "./$found_la" ;; esac libdir="$save_libdir" dnl We use only dependency_libs. for dep in $dependency_libs; do case "$dep" in -L*) additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME. dnl But don't add it dnl 1. if it's the standard /usr/lib, dnl 2. if it's /usr/local/lib and we are using GCC on Linux, dnl 3. if it's already present in $LDFLAGS or the already dnl constructed $LIBNAME, dnl 4. if it doesn't exist as a directory. if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then haveit= if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then haveit= for x in $LDFLAGS $LIB[]NAME; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then dnl Really add $additional_libdir to $LIBNAME. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir" fi fi haveit= for x in $LDFLAGS $LTLIB[]NAME; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test -d "$additional_libdir"; then dnl Really add $additional_libdir to $LTLIBNAME. LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir" fi fi fi fi ;; -R*) dir=`echo "X$dep" | sed -e 's/^X-R//'` if test "$enable_rpath" != no; then dnl Potentially add DIR to rpathdirs. dnl The rpathdirs will be appended to $LIBNAME at the end. haveit= for x in $rpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then rpathdirs="$rpathdirs $dir" fi dnl Potentially add DIR to ltrpathdirs. dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. haveit= for x in $ltrpathdirs; do if test "X$x" = "X$dir"; then haveit=yes break fi done if test -z "$haveit"; then ltrpathdirs="$ltrpathdirs $dir" fi fi ;; -l*) dnl Handle this in the next round. names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` ;; *.la) dnl Handle this in the next round. Throw away the .la's dnl directory; it is already contained in a preceding -L dnl option. names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` ;; *) dnl Most likely an immediate library name. LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep" LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep" ;; esac done fi else dnl Didn't find the library; assume it is in the system directories dnl known to the linker and runtime loader. (All the system dnl directories known to the linker should also be known to the dnl runtime loader, otherwise the system is severely misconfigured.) LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name" fi fi fi done done if test "X$rpathdirs" != "X"; then if test -n "$acl_hardcode_libdir_separator"; then dnl Weird platform: only the last -rpath option counts, the user must dnl pass all path elements in one option. We can arrange that for a dnl single library, but not when more than one $LIBNAMEs are used. alldirs= for found_dir in $rpathdirs; do alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir" done dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl. acl_save_libdir="$libdir" libdir="$alldirs" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" else dnl The -rpath options are cumulative. for found_dir in $rpathdirs; do acl_save_libdir="$libdir" libdir="$found_dir" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" done fi fi if test "X$ltrpathdirs" != "X"; then dnl When using libtool, the option that works for both libraries and dnl executables is -R. The -R options are cumulative. for found_dir in $ltrpathdirs; do LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir" done fi ]) dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR, dnl unless already present in VAR. dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes dnl contains two or three consecutive elements that belong together. AC_DEFUN([AC_LIB_APPENDTOVAR], [ for element in [$2]; do haveit= for x in $[$1]; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X$element"; then haveit=yes break fi done if test -z "$haveit"; then [$1]="${[$1]}${[$1]:+ }$element" fi done ]) dnl For those cases where a variable contains several -L and -l options dnl referring to unknown libraries and directories, this macro determines the dnl necessary additional linker options for the runtime path. dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL]) dnl sets LDADDVAR to linker options needed together with LIBSVALUE. dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed, dnl otherwise linking without libtool is assumed. AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS], [ AC_REQUIRE([AC_LIB_RPATH]) AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) $1= if test "$enable_rpath" != no; then if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then dnl Use an explicit option to hardcode directories into the resulting dnl binary. rpathdirs= next= for opt in $2; do if test -n "$next"; then dir="$next" dnl No need to hardcode the standard /usr/lib. if test "X$dir" != "X/usr/$acl_libdirstem"; then rpathdirs="$rpathdirs $dir" fi next= else case $opt in -L) next=yes ;; -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'` dnl No need to hardcode the standard /usr/lib. if test "X$dir" != "X/usr/$acl_libdirstem"; then rpathdirs="$rpathdirs $dir" fi next= ;; *) next= ;; esac fi done if test "X$rpathdirs" != "X"; then if test -n ""$3""; then dnl libtool is used for linking. Use -R options. for dir in $rpathdirs; do $1="${$1}${$1:+ }-R$dir" done else dnl The linker is used for linking directly. if test -n "$acl_hardcode_libdir_separator"; then dnl Weird platform: only the last -rpath option counts, the user dnl must pass all path elements in one option. alldirs= for dir in $rpathdirs; do alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir" done acl_save_libdir="$libdir" libdir="$alldirs" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" $1="$flag" else dnl The -rpath options are cumulative. for dir in $rpathdirs; do acl_save_libdir="$libdir" libdir="$dir" eval flag=\"$acl_hardcode_libdir_flag_spec\" libdir="$acl_save_libdir" $1="${$1}${$1:+ }$flag" done fi fi fi fi fi AC_SUBST([$1]) ]) apt-dater-0.9.0/m4/lib-prefix.m40000644000175000017500000001503611760757134015614 0ustar thomasthomas# lib-prefix.m4 serial 5 (gettext-0.15) dnl Copyright (C) 2001-2005 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl From Bruno Haible. dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't dnl require excessive bracketing. ifdef([AC_HELP_STRING], [AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])], [AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])]) dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed dnl to access previously installed libraries. The basic assumption is that dnl a user will want packages to use other packages he previously installed dnl with the same --prefix option. dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate dnl libraries, but is otherwise very convenient. AC_DEFUN([AC_LIB_PREFIX], [ AC_BEFORE([$0], [AC_LIB_LINKFLAGS]) AC_REQUIRE([AC_PROG_CC]) AC_REQUIRE([AC_CANONICAL_HOST]) AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) dnl By default, look in $includedir and $libdir. use_additional=yes AC_LIB_WITH_FINAL_PREFIX([ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) AC_LIB_ARG_WITH([lib-prefix], [ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib --without-lib-prefix don't search for libraries in includedir and libdir], [ if test "X$withval" = "Xno"; then use_additional=no else if test "X$withval" = "X"; then AC_LIB_WITH_FINAL_PREFIX([ eval additional_includedir=\"$includedir\" eval additional_libdir=\"$libdir\" ]) else additional_includedir="$withval/include" additional_libdir="$withval/$acl_libdirstem" fi fi ]) if test $use_additional = yes; then dnl Potentially add $additional_includedir to $CPPFLAGS. dnl But don't add it dnl 1. if it's the standard /usr/include, dnl 2. if it's already present in $CPPFLAGS, dnl 3. if it's /usr/local/include and we are using GCC on Linux, dnl 4. if it doesn't exist as a directory. if test "X$additional_includedir" != "X/usr/include"; then haveit= for x in $CPPFLAGS; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-I$additional_includedir"; then haveit=yes break fi done if test -z "$haveit"; then if test "X$additional_includedir" = "X/usr/local/include"; then if test -n "$GCC"; then case $host_os in linux* | gnu* | k*bsd*-gnu) haveit=yes;; esac fi fi if test -z "$haveit"; then if test -d "$additional_includedir"; then dnl Really add $additional_includedir to $CPPFLAGS. CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir" fi fi fi fi dnl Potentially add $additional_libdir to $LDFLAGS. dnl But don't add it dnl 1. if it's the standard /usr/lib, dnl 2. if it's already present in $LDFLAGS, dnl 3. if it's /usr/local/lib and we are using GCC on Linux, dnl 4. if it doesn't exist as a directory. if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then haveit= for x in $LDFLAGS; do AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) if test "X$x" = "X-L$additional_libdir"; then haveit=yes break fi done if test -z "$haveit"; then if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then if test -n "$GCC"; then case $host_os in linux*) haveit=yes;; esac fi fi if test -z "$haveit"; then if test -d "$additional_libdir"; then dnl Really add $additional_libdir to $LDFLAGS. LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir" fi fi fi fi fi ]) dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix, dnl acl_final_exec_prefix, containing the values to which $prefix and dnl $exec_prefix will expand at the end of the configure script. AC_DEFUN([AC_LIB_PREPARE_PREFIX], [ dnl Unfortunately, prefix and exec_prefix get only finally determined dnl at the end of configure. if test "X$prefix" = "XNONE"; then acl_final_prefix="$ac_default_prefix" else acl_final_prefix="$prefix" fi if test "X$exec_prefix" = "XNONE"; then acl_final_exec_prefix='${prefix}' else acl_final_exec_prefix="$exec_prefix" fi acl_save_prefix="$prefix" prefix="$acl_final_prefix" eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" prefix="$acl_save_prefix" ]) dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the dnl variables prefix and exec_prefix bound to the values they will have dnl at the end of the configure script. AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX], [ acl_save_prefix="$prefix" prefix="$acl_final_prefix" acl_save_exec_prefix="$exec_prefix" exec_prefix="$acl_final_exec_prefix" $1 exec_prefix="$acl_save_exec_prefix" prefix="$acl_save_prefix" ]) dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing dnl the basename of the libdir, either "lib" or "lib64". AC_DEFUN([AC_LIB_PREPARE_MULTILIB], [ dnl There is no formal standard regarding lib and lib64. The current dnl practice is that on a system supporting 32-bit and 64-bit instruction dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit dnl libraries go under $prefix/lib. We determine the compiler's default dnl mode by looking at the compiler's library search path. If at least dnl of its elements ends in /lib64 or points to a directory whose absolute dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the dnl default, namely "lib". acl_libdirstem=lib searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'` if test -n "$searchpath"; then acl_save_IFS="${IFS= }"; IFS=":" for searchdir in $searchpath; do if test -d "$searchdir"; then case "$searchdir" in */lib64/ | */lib64 ) acl_libdirstem=lib64 ;; *) searchdir=`cd "$searchdir" && pwd` case "$searchdir" in */lib64 ) acl_libdirstem=lib64 ;; esac ;; esac fi done IFS="$acl_save_IFS" fi ]) apt-dater-0.9.0/m4/nls.m40000644000175000017500000000226611760757134014350 0ustar thomasthomas# nls.m4 serial 3 (gettext-0.15) dnl Copyright (C) 1995-2003, 2005-2006 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public dnl License but which still want to provide support for the GNU gettext dnl functionality. dnl Please note that the actual code of the GNU gettext library is covered dnl by the GNU Library General Public License, and the rest of the GNU dnl gettext package package is covered by the GNU General Public License. dnl They are *not* in the public domain. dnl Authors: dnl Ulrich Drepper , 1995-2000. dnl Bruno Haible , 2000-2003. AC_PREREQ(2.50) AC_DEFUN([AM_NLS], [ AC_MSG_CHECKING([whether NLS is requested]) dnl Default is enabled NLS AC_ARG_ENABLE(nls, [ --disable-nls do not use Native Language Support], USE_NLS=$enableval, USE_NLS=yes) AC_MSG_RESULT($USE_NLS) AC_SUBST(USE_NLS) ]) apt-dater-0.9.0/m4/po.m40000644000175000017500000004460611760757134014176 0ustar thomasthomas# po.m4 serial 15 (gettext-0.17) dnl Copyright (C) 1995-2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public dnl License but which still want to provide support for the GNU gettext dnl functionality. dnl Please note that the actual code of the GNU gettext library is covered dnl by the GNU Library General Public License, and the rest of the GNU dnl gettext package package is covered by the GNU General Public License. dnl They are *not* in the public domain. dnl Authors: dnl Ulrich Drepper , 1995-2000. dnl Bruno Haible , 2000-2003. AC_PREREQ(2.50) dnl Checks for all prerequisites of the po subdirectory. AC_DEFUN([AM_PO_SUBDIRS], [ AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl AC_REQUIRE([AM_PROG_MKDIR_P])dnl defined by automake AC_REQUIRE([AM_NLS])dnl dnl Release version of the gettext macros. This is used to ensure that dnl the gettext macros and po/Makefile.in.in are in sync. AC_SUBST([GETTEXT_MACRO_VERSION], [0.17]) dnl Perform the following tests also if --disable-nls has been given, dnl because they are needed for "make dist" to work. dnl Search for GNU msgfmt in the PATH. dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions. dnl The second test excludes FreeBSD msgfmt. AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 && (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], :) AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) dnl Test whether it is GNU msgfmt >= 0.15. changequote(,)dnl case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;; *) MSGFMT_015=$MSGFMT ;; esac changequote([,])dnl AC_SUBST([MSGFMT_015]) changequote(,)dnl case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;; *) GMSGFMT_015=$GMSGFMT ;; esac changequote([,])dnl AC_SUBST([GMSGFMT_015]) dnl Search for GNU xgettext 0.12 or newer in the PATH. dnl The first test excludes Solaris xgettext and early GNU xgettext versions. dnl The second test excludes FreeBSD xgettext. AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 && (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], :) dnl Remove leftover from FreeBSD xgettext call. rm -f messages.po dnl Test whether it is GNU xgettext >= 0.15. changequote(,)dnl case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;; *) XGETTEXT_015=$XGETTEXT ;; esac changequote([,])dnl AC_SUBST([XGETTEXT_015]) dnl Search for GNU msgmerge 0.11 or newer in the PATH. AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge, [$ac_dir/$ac_word --update -q /dev/null /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1], :) dnl Installation directories. dnl Autoconf >= 2.60 defines localedir. For older versions of autoconf, we dnl have to define it here, so that it can be used in po/Makefile. test -n "$localedir" || localedir='${datadir}/locale' AC_SUBST([localedir]) dnl Support for AM_XGETTEXT_OPTION. test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS= AC_SUBST([XGETTEXT_EXTRA_OPTIONS]) AC_CONFIG_COMMANDS([po-directories], [[ for ac_file in $CONFIG_FILES; do # Support "outfile[:infile[:infile...]]" case "$ac_file" in *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; esac # PO directories have a Makefile.in generated from Makefile.in.in. case "$ac_file" in */Makefile.in) # Adjust a relative srcdir. ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` # In autoconf-2.13 it is called $ac_given_srcdir. # In autoconf-2.50 it is called $srcdir. test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" case "$ac_given_srcdir" in .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; /*) top_srcdir="$ac_given_srcdir" ;; *) top_srcdir="$ac_dots$ac_given_srcdir" ;; esac # Treat a directory as a PO directory if and only if it has a # POTFILES.in file. This allows packages to have multiple PO # directories under different names or in different locations. if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then rm -f "$ac_dir/POTFILES" test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" POMAKEFILEDEPS="POTFILES.in" # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend # on $ac_dir but don't depend on user-specified configuration # parameters. if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then # The LINGUAS file contains the set of available languages. if test -n "$OBSOLETE_ALL_LINGUAS"; then test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" fi ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"` # Hide the ALL_LINGUAS assigment from automake < 1.5. eval 'ALL_LINGUAS''=$ALL_LINGUAS_' POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" else # The set of available languages was given in configure.in. # Hide the ALL_LINGUAS assigment from automake < 1.5. eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' fi # Compute POFILES # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po) # Compute UPDATEPOFILES # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update) # Compute DUMMYPOFILES # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop) # Compute GMOFILES # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo) case "$ac_given_srcdir" in .) srcdirpre= ;; *) srcdirpre='$(srcdir)/' ;; esac POFILES= UPDATEPOFILES= DUMMYPOFILES= GMOFILES= for lang in $ALL_LINGUAS; do POFILES="$POFILES $srcdirpre$lang.po" UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" DUMMYPOFILES="$DUMMYPOFILES $lang.nop" GMOFILES="$GMOFILES $srcdirpre$lang.gmo" done # CATALOGS depends on both $ac_dir and the user's LINGUAS # environment variable. INST_LINGUAS= if test -n "$ALL_LINGUAS"; then for presentlang in $ALL_LINGUAS; do useit=no if test "%UNSET%" != "$LINGUAS"; then desiredlanguages="$LINGUAS" else desiredlanguages="$ALL_LINGUAS" fi for desiredlang in $desiredlanguages; do # Use the presentlang catalog if desiredlang is # a. equal to presentlang, or # b. a variant of presentlang (because in this case, # presentlang can be used as a fallback for messages # which are not translated in the desiredlang catalog). case "$desiredlang" in "$presentlang"*) useit=yes;; esac done if test $useit = yes; then INST_LINGUAS="$INST_LINGUAS $presentlang" fi done fi CATALOGS= if test -n "$INST_LINGUAS"; then for lang in $INST_LINGUAS; do CATALOGS="$CATALOGS $lang.gmo" done fi test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do if test -f "$f"; then case "$f" in *.orig | *.bak | *~) ;; *) cat "$f" >> "$ac_dir/Makefile" ;; esac fi done fi ;; esac done]], [# Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it # from automake < 1.5. eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' # Capture the value of LINGUAS because we need it to compute CATALOGS. LINGUAS="${LINGUAS-%UNSET%}" ]) ]) dnl Postprocesses a Makefile in a directory containing PO files. AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE], [ # When this code is run, in config.status, two variables have already been # set: # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in, # - LINGUAS is the value of the environment variable LINGUAS at configure # time. changequote(,)dnl # Adjust a relative srcdir. ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` # In autoconf-2.13 it is called $ac_given_srcdir. # In autoconf-2.50 it is called $srcdir. test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" case "$ac_given_srcdir" in .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; /*) top_srcdir="$ac_given_srcdir" ;; *) top_srcdir="$ac_dots$ac_given_srcdir" ;; esac # Find a way to echo strings without interpreting backslash. if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then gt_echo='echo' else if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then gt_echo='printf %s\n' else echo_func () { cat < "$ac_file.tmp" if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then # Add dependencies that cannot be formulated as a simple suffix rule. for lang in $ALL_LINGUAS; do frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'` cat >> "$ac_file.tmp" < /dev/null; then # Add dependencies that cannot be formulated as a simple suffix rule. for lang in $ALL_LINGUAS; do frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'` cat >> "$ac_file.tmp" <> "$ac_file.tmp" <, 1996. AC_PREREQ(2.50) # Search path for a program which passes the given test. dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) AC_DEFUN([AM_PATH_PROG_WITH_TEST], [ # Prepare PATH_SEPARATOR. # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Find out how to test for executable files. Don't use a zero-byte file, # as systems may use methods other than mode bits to determine executability. cat >conf$$.file <<_ASEOF #! /bin/sh exit 0 _ASEOF chmod +x conf$$.file if test -x conf$$.file >/dev/null 2>&1; then ac_executable_p="test -x" else ac_executable_p="test -f" fi rm -f conf$$.file # Extract the first word of "$2", so it can be a program name with args. set dummy $2; ac_word=[$]2 AC_MSG_CHECKING([for $ac_word]) AC_CACHE_VAL(ac_cv_path_$1, [case "[$]$1" in [[\\/]]* | ?:[[\\/]]*) ac_cv_path_$1="[$]$1" # Let the user override the test with a path. ;; *) ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in ifelse([$5], , $PATH, [$5]); do IFS="$ac_save_IFS" test -z "$ac_dir" && ac_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD if [$3]; then ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext" break 2 fi fi done done IFS="$ac_save_IFS" dnl If no 4th arg is given, leave the cache variable unset, dnl so AC_PATH_PROGS will keep looking. ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" ])dnl ;; esac])dnl $1="$ac_cv_path_$1" if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then AC_MSG_RESULT([$]$1) else AC_MSG_RESULT(no) fi AC_SUBST($1)dnl ]) apt-dater-0.9.0/man/0000755000175000017500000000000011761142205013523 5ustar thomasthomasapt-dater-0.9.0/man/Makefile.am0000644000175000017500000000054611760757134015600 0ustar thomasthomasman_MANS=apt-dater.8 apt-dater.html apt-dater.conf.5 apt-dater.conf.html apt-dater-host.1 XSLTPROC=@XSLTPROC@ DBXSL=@DBXSL@ EXTRA_DIST=$(man_MANS) %.html: %.xml $(XSLTPROC) -o $@ -''-nonet $(DBXSL)/html/docbook.xsl $< %.5: %.xml $(XSLTPROC) -''-nonet $(DBXSL)/manpages/docbook.xsl $< %.8: %.xml $(XSLTPROC) -''-nonet $(DBXSL)/manpages/docbook.xsl $< apt-dater-0.9.0/man/apt-dater-host.10000644000175000017500000000122311760757134016453 0ustar thomasthomas.TH "APT-DATER-HOST" "1" .SH "NAME" apt\-dater\-host \- a network system supporting team. .SH "SYNOPSIS" \fBapt\-dater\-host\fR .SH "DESCRIPTION" This manual page documents briefly the \fBapt\-dater\-host\fR helper. \fBapt\-dater\-host\fR is the host helper application for apt\-dater for watching and updating the targeted application about apt\-dater. .SH "AUTHOR" This manual page was written by Patrick Matth\[:a]i for apt\-dater\-host. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 2 any later version published by the Free Software Foundation. apt-dater-0.9.0/man/apt-dater.80000644000175000017500000000604311761142005015476 0ustar thomasthomas'\" t .\" Title: APT-DATER .\" Author: Andre Ellguth .\" Generator: DocBook XSL Stylesheets v1.76.1 .\" Date: May 29, 2012 .\" Manual: [FIXME: manual] .\" Source: [FIXME: source] .\" Language: English .\" .TH "APT\-DATER" "8" "May 29, 2012" "[FIXME: source]" "[FIXME: manual]" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" apt-dater \- terminal\-based remote package update manager .SH "SYNOPSIS" .HP \w'\fBapt\-dater\fR\ 'u \fBapt\-dater\fR [\fB[\-(c\ \fR\fB\fIconfig\fR\fR\fB|v|[n]r)]\fR] .SH "DESCRIPTION" .PP This manual page documents briefly the \fBapt\-dater\fR command\&. .PP \fBapt\-dater\fR is a program to manage package updats on a large number of remote hosts using SSH\&. .SH "OPTIONS" .PP \fBapt\-dater\fR accepts the following command parameters: .PP \fB\-c \fR\fB\fIconfig\fR\fR .RS 4 Use alternative config file\&. Default is \fI$XDG_CONFIG_HOME/apt\-dater/apt\-dater\&.conf\fR\&. .RE .PP \fB\-v\fR .RS 4 Show apt\-dater version and copyright statement\&. .RE .PP \fB\-r\fR .RS 4 Refresh hosts and create XML report on stdout\&. apt\-dater must be compiled with XMLREPORT feature\&. .RE .PP \fB\-n\fR .RS 4 Prevent hosts to be refreshed before create XML report (useful for cronjobs which do not have access to SSH key(s))\&. .RE .SH "ENVIRONMENT" .PP \fBMAINTAINER\fR .RS 4 The maintainer\*(Aqs name (i\&.e\&. used by \fBdebtrack\fR)\&. If not set, the GECOS entry for the current user will be used\&. This environment variable could be forwarded to remote hosts with the ssh(1) SendEnv+AcceptEnv options\&. .RE .SH "FILES" .PP \fI~/\&.config/apt\-dater/apt\-dater\&.conf\fR .RS 4 The configuration file of apt\-dater .RE .PP \fI~/\&.config/apt\-dater/hosts\&.conf\fR .RS 4 Contains all hosts you would like to manage .RE .SH "SEE ALSO" .PP apt\-dater\&.conf(5), aptitude(1), apt\-get(1), debtrack, screen(1), ssh(1)\&. .SH "AUTHORS" .PP \fBAndre Ellguth\fR <\&ellguth@ibh\&.de\&> .RS 4 Maintainer\&. .RE .PP \fBThomas Liske\fR <\&liske@ibh\&.de\&> .RS 4 Maintainer\&. .RE .PP \fBJens Haser\fR <\&jens_dd@hotmail\&.de\&> .RS 4 Fixed some UI glitches\&. .RE .SH "COPYRIGHT" .br Copyright \(co 2008-2012 IBH IT-Service GmbH [\m[blue]\fBhttp://www\&.ibh\&.de/\fR\m[]] .br apt-dater-0.9.0/man/apt-dater.conf.50000644000175000017500000001506611761142006016425 0ustar thomasthomas'\" t .\" Title: APT-DATER .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.76.1 .\" Date: May 29, 2012 .\" Manual: [FIXME: manual] .\" Source: [FIXME: source] .\" Language: English .\" .TH "APT\-DATER" "5" "May 29, 2012" "[FIXME: source]" "[FIXME: manual]" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" apt-dater.conf \- configuration file of apt\-dater(8) .SH "SYNOPSIS" .PP .RS 4 [Section] .RE .PP .RS 4 parameter=\fIvalue\fR .RE .PP .RS 4 parameter=\fIvalue;value;\&.\&.\&.;\fR .RE .SH "DESCRIPTION" .PP The file \fIapt\-dater\&.conf\fR is the configuration file for \fBapt\-dater\fR(8)\&. \fBapt\-dater\fR(8) is a program to manage package updats on a large number of remote hosts using SSH\&. This man page descripes briefly the parameters of the file \fIapt\-dater\&.conf\fR\&. The default location of this file is \fI$XDG_CONFIG_HOME/apt\-dater/hosts\&.conf\fR\&. .PP The syntax of the configuration file is the syntax of glib keyfiles\&. .SH "OPTIONS" .SS "Section [Paths]" .PP HostsFile=\fI$XDG_CONFIG_HOME/apt\-dater/hosts\&.conf\fR .RS 4 The location of the file contains all host which will be managed with \fBapt\-dater\fR\&. (optional) .RE .PP StatsDir=\fI$XDG_DATA_HOME/apt\-dater\fR .RS 4 The location of the directory which contains the status files of any host\&. (optional) .RE .SS "Section [Screen]" .PP RCFile=\fI$XDG_CONFIG_HOME/apt\-dater/screenrc\fR .RS 4 Location of screen(1) config file\&. (optional) .RE .PP Title=\fI%m # %u@%h:%p\fR .RS 4 Template for screen titles using string escapes\&. (optional) .RE .PP NoDumps=\fIfalse\fR .RS 4 Enables/disables support of screen dumps\&. (optional) .RE .PP QueryMaintainer=\fI0\fR .RS 4 If set to 1, apt\-dater will ask for the maintainers name on startup\&. If set to 2, apt\-dater will only ask if no MAINTAINER environment variable is set\&. .RE .SS "Section [SSH]" .PP Cmd=\fI/usr/bin/ssh\fR .RS 4 The location of ssh\-client binary\&. .RE .PP SFTPCmd .RS 4 The command to initiate sftp file transfer e\&.g\&. \fB/usr/bin/sftp\fR .RE .PP OptionalCmdFlags .RS 4 Additional ssh\-client command flags, which will be appended\&. .RE .PP SpawnAgent=\fIfalse\fR .RS 4 If enabled, apt\-dater tries to spawn ssh\-agent(1) if none is already running\&. ssh\-add(1) will be called to load your private keys\&. .RE .PP AddKeys .RS 4 List of private keys which should be loaded when apt\-dater calls ssh\-add(1)\&. .RE .SS "Section [Commands]" .PP CmdRefresh=\fIapt\-dater\-host refresh\fR .RS 4 The command which will be used to refresh the status of the managed host\&. .RE .PP CmdUpgrade=\fIapt\-dater\-host upgrade\fR .RS 4 The command which will be used to intitate a upgrade of a managed host\&. .RE .PP CmdInstall=\fIapt\-dater\-host install %s\fR .RS 4 The command which will be used to update a single package\&. \fI%s\fR will be replaced by the name of the package\&. .RE .SS "Section [Appearance]" .PP Colors .RS 4 Set your own color style of the ui components\&. To highlight colors you can use the \fIbright\fR* keyword\&. Example: Colors=menu brightgreen blue;status brightgreen blue;selector black red; .sp \&. Components are: .PP .RS 4 default .RE .PP .RS 4 menu .RE .PP .RS 4 status .RE .PP .RS 4 selector .RE .PP .RS 4 hoststatus .RE .PP .RS 4 query .RE .PP .RS 4 input .RE .sp Colors are: .PP .RS 4 \fBdefault\fR .RE .PP .RS 4 \fBblack\fR .RE .PP .RS 4 \fBcyan\fR .RE .PP .RS 4 \fBgreen\fR .RE .PP .RS 4 \fBmagenta\fR .RE .PP .RS 4 \fBred\fR .RE .PP .RS 4 \fBwhite\fR .RE .PP .RS 4 \fByellow\fR .RE .RE .SS "Section [AutoRef]" .PP enabled=\fItrue\fR .RS 4 Enabled the auto refresh feature if compiled in (see README\&.autoref)\&. .RE .SS "Section [Notify]" .PP bell=\fItrue\fR .RS 4 Enables user notification by terminal bell\&. .RE .PP flash=\fItrue\fR .RS 4 Enables user notification by terminal flashing\&. .RE .SS "Section [History]" .PP ErrPattern=\fI(error|warning|fail)\fR .RS 4 A regular expression pattern to match the screen output\&. A match indicates the user should be asked to review the output (using less)\&. (Optional) .RE .PP record=\fItrue\fR .RS 4 Enables session recording using script(1)\&. (Optional) .RE .SS "Section [Hooks]" .PP PreUpdate=\fI/etc/apt\-dater/pre\-upg\&.d\fR, PreRefresh=\fI/etc/apt\-dater/pre\-ref\&.d\fR, PreInstall=\fI/etc/apt\-dater/pre\-ins\&.d\fR, PreConnect=\fI/etc/apt\-dater/pre\-con\&.d\fR, PostUpdate=\fI/etc/apt\-dater/post\-upg\&.d\fR, PostRefresh=\fI/etc/apt\-dater/post\-ref\&.d\fR, PostInstall=\fI/etc/apt\-dater/post\-ins\&.d\fR, PostConnect=\fI/etc/apt\-dater/post\-con\&.d\fR .RS 4 Hooks to be run before and after an action on a host is done\&. The values should be path names, any executable script within these directories will be run by \fBrun\-parts\fR(8)\&. .RE .SH "STRING ESCAPES" \fBapt\-dater\fR(8) provides an string escape mechanism\&. The escape character is \*(Aq%\*(Aq\&. .sp .it 1 an-trap .nr an-no-space-flag 1 .nr an-break-flag 1 .br .B Table\ \&1.\ \&List of supported escapes. .TS allbox tab(:); l l. T{ escape T}:T{ replaced by T} .T& l l l l l l l l l l. T{ % T}:T{ escape character T} T{ h T}:T{ hostname T} T{ m T}:T{ maintainer name T} T{ p T}:T{ SSH port number T} T{ u T}:T{ SSH username T} .TE .sp 1 .SH "FILES" .PP \fIapt\-dater\&.conf\fR .RS 4 The configuration file of apt\-dater\&. .RE .PP \fIhosts\&.conf\fR .RS 4 Contains all hosts you would like to manage\&. .RE .SH "SEE ALSO" .PP apt\-dater(8), aptitude(1), apt\-get(1), debtrack, screen(1), script(1), ssh(1), \m[blue]\fBXDG Base Directory Specification\fR\m[]\&\s-2\u[1]\d\s+2\&. .SH "COPYRIGHT" .br Copyright \(co 2008-2012 IBH IT-Service GmbH [\m[blue]\fBhttp://www\&.ibh\&.de/\fR\m[]] .br .SH "NOTES" .IP " 1." 4 XDG Base Directory Specification .RS 4 \%http://www.freedesktop.org/Standards/basedir-spec .RE apt-dater-0.9.0/man/apt-dater.conf.html0000644000175000017500000002517411761142007017227 0ustar thomasthomasAPT-DATER

Name

apt-dater.conf — configuration file of apt-dater(8)

Synopsis

[Section]

parameter=value

parameter=value;value;...;

DESCRIPTION

The file apt-dater.conf is the configuration file for apt-dater(8). apt-dater(8) is a program to manage package updats on a large number of remote hosts using SSH. This man page descripes briefly the parameters of the file apt-dater.conf. The default location of this file is $XDG_CONFIG_HOME/apt-dater/hosts.conf.

The syntax of the configuration file is the syntax of glib keyfiles.

OPTIONS

Section [Paths]

HostsFile=$XDG_CONFIG_HOME/apt-dater/hosts.conf

The location of the file contains all host which will be managed with apt-dater. (optional)

StatsDir=$XDG_DATA_HOME/apt-dater

The location of the directory which contains the status files of any host. (optional)

Section [Screen]

RCFile=$XDG_CONFIG_HOME/apt-dater/screenrc

Location of screen(1) config file. (optional)

Title=%m # %u@%h:%p

Template for screen titles using string escapes. (optional)

NoDumps=false

Enables/disables support of screen dumps. (optional)

QueryMaintainer=0

If set to 1, apt-dater will ask for the maintainers name on startup. If set to 2, apt-dater will only ask if no MAINTAINER environment variable is set.

Section [SSH]

Cmd=/usr/bin/ssh

The location of ssh-client binary.

SFTPCmd

The command to initiate sftp file transfer e.g. /usr/bin/sftp

OptionalCmdFlags

Additional ssh-client command flags, which will be appended.

SpawnAgent=false

If enabled, apt-dater tries to spawn ssh-agent(1) if none is already running. ssh-add(1) will be called to load your private keys.

AddKeys

List of private keys which should be loaded when apt-dater calls ssh-add(1).

Section [Commands]

CmdRefresh=apt-dater-host refresh

The command which will be used to refresh the status of the managed host.

CmdUpgrade=apt-dater-host upgrade

The command which will be used to intitate a upgrade of a managed host.

CmdInstall=apt-dater-host install %s

The command which will be used to update a single package. %s will be replaced by the name of the package.

Section [Appearance]

Colors

Set your own color style of the ui components. To highlight colors you can use the bright* keyword. Example: Colors=menu brightgreen blue;status brightgreen blue;selector black red;

.

Components are:

Colors are:

Section [AutoRef]

enabled=true

Enabled the auto refresh feature if compiled in (see README.autoref).

Section [Notify]

bell=true

Enables user notification by terminal bell.

flash=true

Enables user notification by terminal flashing.

Section [History]

ErrPattern=(error|warning|fail)

A regular expression pattern to match the screen output. A match indicates the user should be asked to review the output (using less). (Optional)

record=true

Enables session recording using script(1). (Optional)

Section [Hooks]

PreUpdate=/etc/apt-dater/pre-upg.d, PreRefresh=/etc/apt-dater/pre-ref.d, PreInstall=/etc/apt-dater/pre-ins.d, PreConnect=/etc/apt-dater/pre-con.d, PostUpdate=/etc/apt-dater/post-upg.d, PostRefresh=/etc/apt-dater/post-ref.d, PostInstall=/etc/apt-dater/post-ins.d, PostConnect=/etc/apt-dater/post-con.d

Hooks to be run before and after an action on a host is done. The values should be path names, any executable script within these directories will be run by run-parts(8).

STRING ESCAPES

apt-dater(8) provides an string escape mechanism. The escape character is '%'. List of supported escapes.
escape replaced by
% escape character
h hostname
m maintainer name
p SSH port number
u SSH username

FILES

apt-dater.conf

The configuration file of apt-dater.

hosts.conf

Contains all hosts you would like to manage.

SEE ALSO

apt-dater(8), aptitude(1), apt-get(1), debtrack, screen(1), script(1), ssh(1), XDG Base Directory Specification.

apt-dater-0.9.0/man/apt-dater.conf.xml0000644000175000017500000003372411761141770017071 0ustar thomasthomas .
will be generated. You may view the manual page with: nroff -man .
| less'. A typical entry in a Makefile or Makefile.am is: DB2MAN=/usr/share/sgml/docbook/stylesheet/xsl/nwalsh/\ manpages/docbook.xsl XP=xsltproc -''-nonet manpage.1: manpage.dbk $(XP) $(DB2MAN) $< The xsltproc binary is found in the xsltproc package. The XSL files are in docbook-xsl. Please remember that if you create the nroff version in one of the debian/rules file targets (such as build), you will need to include xsltproc and docbook-xsl in your Build-Depends control field. --> Andre"> Ellguth"> May 29, 2012"> 5"> ellguth@ibh.de"> APT-DATER"> Debian"> GNU"> GPL"> ]>
&dhemail;
2008-2012 IBH IT-Service GmbH [http://www.ibh.de/] &dhdate;
&dhucpackage; &dhsection; &dhpackage;.conf configuration file of &dhpackage;(8) [Section] parameter=value parameter=value;value;...; DESCRIPTION The file &dhpackage;.conf is the configuration file for &dhpackage;(8). &dhpackage;(8) is a program to manage package updats on a large number of remote hosts using SSH. This man page descripes briefly the parameters of the file &dhpackage;.conf. The default location of this file is $XDG_CONFIG_HOME/apt-dater/hosts.conf. The syntax of the configuration file is the syntax of glib keyfiles. OPTIONS Section <symbol>[Paths]</symbol> HostsFile=$XDG_CONFIG_HOME/apt-dater/hosts.conf The location of the file contains all host which will be managed with &dhpackage;. (optional) StatsDir=$XDG_DATA_HOME/apt-dater The location of the directory which contains the status files of any host. (optional) Section <symbol>[Screen]</symbol> RCFile=$XDG_CONFIG_HOME/apt-dater/screenrc Location of screen(1) config file. (optional) Title=%m # %u@%h:%p Template for screen titles using string escapes. (optional) NoDumps=false Enables/disables support of screen dumps. (optional) QueryMaintainer=0 If set to 1, apt-dater will ask for the maintainers name on startup. If set to 2, apt-dater will only ask if no MAINTAINER environment variable is set. Section <symbol>[SSH]</symbol> Cmd=/usr/bin/ssh The location of ssh-client binary. SFTPCmd The command to initiate sftp file transfer e.g. /usr/bin/sftp OptionalCmdFlags Additional ssh-client command flags, which will be appended. SpawnAgent=false If enabled, apt-dater tries to spawn ssh-agent(1) if none is already running. ssh-add(1) will be called to load your private keys. AddKeys List of private keys which should be loaded when apt-dater calls ssh-add(1). Section <symbol>[Commands]</symbol> CmdRefresh=apt-dater-host refresh The command which will be used to refresh the status of the managed host. CmdUpgrade=apt-dater-host upgrade The command which will be used to intitate a upgrade of a managed host. CmdInstall=apt-dater-host install %s The command which will be used to update a single package. %s will be replaced by the name of the package. Section <symbol>[Appearance]</symbol> Colors Set your own color style of the ui components. To highlight colors you can use the bright* keyword. Example: Colors=menu brightgreen blue;status brightgreen blue;selector black red;. Components are: default menu status selector hoststatus query input Colors are: default black cyan green magenta red white yellow Section <symbol>[AutoRef]</symbol> enabled=true Enabled the auto refresh feature if compiled in (see README.autoref). Section <symbol>[Notify]</symbol> bell=true Enables user notification by terminal bell. flash=true Enables user notification by terminal flashing. Section <symbol>[History]</symbol> ErrPattern=(error|warning|fail) A regular expression pattern to match the screen output. A match indicates the user should be asked to review the output (using less). (Optional) record=true Enables session recording using script(1). (Optional) Section <symbol>[Hooks]</symbol> PreUpdate=/etc/apt-dater/pre-upg.d PreRefresh=/etc/apt-dater/pre-ref.d PreInstall=/etc/apt-dater/pre-ins.d PreConnect=/etc/apt-dater/pre-con.d PostUpdate=/etc/apt-dater/post-upg.d PostRefresh=/etc/apt-dater/post-ref.d PostInstall=/etc/apt-dater/post-ins.d PostConnect=/etc/apt-dater/post-con.d Hooks to be run before and after an action on a host is done. The values should be path names, any executable script within these directories will be run by run-parts(8). STRING ESCAPES &dhpackage;(8) provides an string escape mechanism. The escape character is '%'. List of supported escapes.
escape replaced by
% escape character
h hostname
m maintainer name
p SSH port number
u SSH username
FILES apt-dater.conf The configuration file of apt-dater. hosts.conf Contains all hosts you would like to manage. SEE ALSO apt-dater(8), aptitude(1), apt-get(1), debtrack, screen(1), script(1), ssh(1), XDG Base Directory Specification.
apt-dater-0.9.0/man/apt-dater.html0000644000175000017500000000614511761142006016277 0ustar thomasthomasAPT-DATER

Name

apt-dater — terminal-based remote package update manager

Synopsis

apt-dater [[-(c config|v|[n]r)]]

DESCRIPTION

This manual page documents briefly the apt-dater command.

apt-dater is a program to manage package updats on a large number of remote hosts using SSH.

OPTIONS

apt-dater accepts the following command parameters:

-c config

Use alternative config file. Default is $XDG_CONFIG_HOME/apt-dater/apt-dater.conf.

-v

Show apt-dater version and copyright statement.

-r

Refresh hosts and create XML report on stdout. apt-dater must be compiled with XMLREPORT feature.

-n

Prevent hosts to be refreshed before create XML report (useful for cronjobs which do not have access to SSH key(s)).

ENVIRONMENT

MAINTAINER

The maintainer's name (i.e. used by debtrack). If not set, the GECOS entry for the current user will be used. This environment variable could be forwarded to remote hosts with the ssh(1) SendEnv+AcceptEnv options.

FILES

~/.config/apt-dater/apt-dater.conf

The configuration file of apt-dater

~/.config/apt-dater/hosts.conf

Contains all hosts you would like to manage

SEE ALSO

apt-dater.conf(5), aptitude(1), apt-get(1), debtrack, screen(1), ssh(1).

apt-dater-0.9.0/man/apt-dater.xml0000644000175000017500000001261311761142004016126 0ustar thomasthomas .
will be generated. You may view the manual page with: nroff -man .
| less'. A typical entry in a Makefile or Makefile.am is: DB2MAN=/usr/share/sgml/docbook/stylesheet/xsl/nwalsh/\ manpages/docbook.xsl XP=xsltproc -''-nonet manpage.1: manpage.dbk $(XP) $(DB2MAN) $< The xsltproc binary is found in the xsltproc package. The XSL files are in docbook-xsl. Please remember that if you create the nroff version in one of the debian/rules file targets (such as build), you will need to include xsltproc and docbook-xsl in your Build-Depends control field. --> Thomas"> Liske"> May 29, 2012"> 8"> liske@ibh.de"> APT-DATER"> Debian"> GNU"> GPL"> ]>
&dhemail;
Andre Ellguth ellguth@ibh.de Maintainer. &dhfirstname; &dhsurname; &dhemail; Maintainer. Jens Haser jens_dd@hotmail.de Fixed some UI glitches. 2008-2012 IBH IT-Service GmbH [http://www.ibh.de/] &dhdate;
&dhucpackage; &dhsection; &dhpackage; terminal-based remote package update manager &dhpackage; DESCRIPTION This manual page documents briefly the &dhpackage; command. &dhpackage; is a program to manage package updats on a large number of remote hosts using SSH. OPTIONS &dhpackage; accepts the following command parameters: Use alternative config file. Default is $XDG_CONFIG_HOME/apt-dater/apt-dater.conf. Show apt-dater version and copyright statement. Refresh hosts and create XML report on stdout. apt-dater must be compiled with XMLREPORT feature. Prevent hosts to be refreshed before create XML report (useful for cronjobs which do not have access to SSH key(s)). ENVIRONMENT MAINTAINER The maintainer's name (i.e. used by debtrack). If not set, the GECOS entry for the current user will be used. This environment variable could be forwarded to remote hosts with the ssh(1) SendEnv+AcceptEnv options. FILES ~/.config/apt-dater/apt-dater.conf The configuration file of apt-dater ~/.config/apt-dater/hosts.conf Contains all hosts you would like to manage SEE ALSO apt-dater.conf(5), aptitude(1), apt-get(1), debtrack, screen(1), ssh(1).
apt-dater-0.9.0/man/Makefile.in0000644000175000017500000003735611761141270015607 0ustar thomasthomas# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ subdir = man DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = SOURCES = DIST_SOURCES = man1dir = $(mandir)/man1 am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \ "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(manhdir)" man5dir = $(mandir)/man5 man8dir = $(mandir)/man8 manhdir = $(mandir)/manh NROFF = nroff MANS = $(man_MANS) DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CURSES_LIB = @CURSES_LIB@ CYGPATH_W = @CYGPATH_W@ DBXSL = @DBXSL@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FREEBSD_FALSE = @FREEBSD_FALSE@ FREEBSD_TRUE = @FREEBSD_TRUE@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLIB_CFLAGS = @GLIB_CFLAGS@ GLIB_LIBS = @GLIB_LIBS@ GMSGFMT = @GMSGFMT@ GMSGFMT_015 = @GMSGFMT_015@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ LDFLAGS = @LDFLAGS@ LIBICONV = @LIBICONV@ LIBINTL = @LIBINTL@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBXML2_CFLAGS = @LIBXML2_CFLAGS@ LIBXML2_LIBS = @LIBXML2_LIBS@ LINUX_FALSE = @LINUX_FALSE@ LINUX_TRUE = @LINUX_TRUE@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ TCL_CFLAGS = @TCL_CFLAGS@ TCL_LIBS = @TCL_LIBS@ USE_NLS = @USE_NLS@ VERSION = @VERSION@ XGETTEXT = @XGETTEXT@ XGETTEXT_015 = @XGETTEXT_015@ XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ XSLTPROC = @XSLTPROC@ ac_ct_CC = @ac_ct_CC@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ cv_path_tcl = @cv_path_tcl@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ man_MANS = apt-dater.8 apt-dater.html apt-dater.conf.5 apt-dater.conf.html apt-dater-host.1 EXTRA_DIST = $(man_MANS) all: all-am .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu man/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu man/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh uninstall-info-am: install-man1: $(man1_MANS) $(man_MANS) @$(NORMAL_INSTALL) test -z "$(man1dir)" || $(mkdir_p) "$(DESTDIR)$(man1dir)" @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.1*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ else file=$$i; fi; \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 1*) ;; \ *) ext='1' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst"; \ done uninstall-man1: @$(NORMAL_UNINSTALL) @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.1*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 1*) ;; \ *) ext='1' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " rm -f '$(DESTDIR)$(man1dir)/$$inst'"; \ rm -f "$(DESTDIR)$(man1dir)/$$inst"; \ done install-man5: $(man5_MANS) $(man_MANS) @$(NORMAL_INSTALL) test -z "$(man5dir)" || $(mkdir_p) "$(DESTDIR)$(man5dir)" @list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.5*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ else file=$$i; fi; \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 5*) ;; \ *) ext='5' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst"; \ done uninstall-man5: @$(NORMAL_UNINSTALL) @list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.5*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 5*) ;; \ *) ext='5' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " rm -f '$(DESTDIR)$(man5dir)/$$inst'"; \ rm -f "$(DESTDIR)$(man5dir)/$$inst"; \ done install-man8: $(man8_MANS) $(man_MANS) @$(NORMAL_INSTALL) test -z "$(man8dir)" || $(mkdir_p) "$(DESTDIR)$(man8dir)" @list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.8*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ else file=$$i; fi; \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 8*) ;; \ *) ext='8' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst"; \ done uninstall-man8: @$(NORMAL_UNINSTALL) @list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.8*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ 8*) ;; \ *) ext='8' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " rm -f '$(DESTDIR)$(man8dir)/$$inst'"; \ rm -f "$(DESTDIR)$(man8dir)/$$inst"; \ done install-manh: $(manh_MANS) $(man_MANS) @$(NORMAL_INSTALL) test -z "$(manhdir)" || $(mkdir_p) "$(DESTDIR)$(manhdir)" @list='$(manh_MANS) $(dist_manh_MANS) $(nodist_manh_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.h*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ else file=$$i; fi; \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ h*) ;; \ *) ext='h' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(manhdir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(manhdir)/$$inst"; \ done uninstall-manh: @$(NORMAL_UNINSTALL) @list='$(manh_MANS) $(dist_manh_MANS) $(nodist_manh_MANS)'; \ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ for i in $$l2; do \ case "$$i" in \ *.h*) list="$$list $$i" ;; \ esac; \ done; \ for i in $$list; do \ ext=`echo $$i | sed -e 's/^.*\\.//'`; \ case "$$ext" in \ h*) ;; \ *) ext='h' ;; \ esac; \ inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ inst=`echo $$inst | sed -e 's/^.*\///'`; \ inst=`echo $$inst | sed '$(transform)'`.$$ext; \ echo " rm -f '$(DESTDIR)$(manhdir)/$$inst'"; \ rm -f "$(DESTDIR)$(manhdir)/$$inst"; \ done tags: TAGS TAGS: ctags: CTAGS CTAGS: distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(MANS) installdirs: for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(manhdir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-man install-exec-am: install-info: install-info-am install-man: install-man1 install-man5 install-man8 install-manh installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-info-am uninstall-man uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8 \ uninstall-manh .PHONY: all all-am check check-am clean clean-generic distclean \ distclean-generic distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-exec \ install-exec-am install-info install-info-am install-man \ install-man1 install-man5 install-man8 install-manh \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-generic pdf pdf-am ps ps-am uninstall uninstall-am \ uninstall-info-am uninstall-man uninstall-man1 uninstall-man5 \ uninstall-man8 uninstall-manh %.html: %.xml $(XSLTPROC) -o $@ -''-nonet $(DBXSL)/html/docbook.xsl $< %.5: %.xml $(XSLTPROC) -''-nonet $(DBXSL)/manpages/docbook.xsl $< %.8: %.xml $(XSLTPROC) -''-nonet $(DBXSL)/manpages/docbook.xsl $< # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: apt-dater-0.9.0/missing0000755000175000017500000002540611760757134014372 0ustar thomasthomas#! /bin/sh # Common stub for a few missing GNU programs while installing. scriptversion=2005-06-08.21 # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi msg="missing on your system" case "$1" in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 # Exit code 63 means version mismatch. This often happens # when the user try to use an ancient version of a tool on # a file that requires a minimum version. In this case we # we should proceed has if the program had been absent, or # if --run hadn't been passed. if test $? = 63; then run=: msg="probably too old" fi ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch] Send bug reports to ." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; esac # Now exit if we have it, but it failed. Also exit now if we # don't have it and --version was passed (most likely to detect # the program). case "$1" in lex|yacc) # Not GNU programs, they don't have --version. ;; tar) if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then exit 1 fi ;; *) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then # Could not run --version or --help. This is probably someone # running `$TOOL --version' or `$TOOL --help' to check whether # $TOOL exists and not knowing $TOOL uses missing. exit 1 fi ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case "$1" in aclocal*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case "$f" in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) echo 1>&2 "\ WARNING: \`$1' is needed, but is $msg. You might have modified some files without having the proper tools for further handling them. You can get \`$1' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' $msg. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.h fi ;; esac fi if [ ! -f y.tab.h ]; then echo >y.tab.h fi if [ ! -f y.tab.c ]; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if [ ! -f lex.yy.c ]; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` fi if [ -f "$file" ]; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $infile` # ... or it is derived from the source name (dir/f.texi becomes f.info) test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info fi # If the file does not exist, the user really needs makeinfo; # let's fail without touching anything. test -f $file || exit 1 touch $file ;; tar) shift # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case "$firstarg" in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case "$firstarg" in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and is $msg. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequisites for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: apt-dater-0.9.0/mkinstalldirs0000755000175000017500000000662211760757134015600 0ustar thomasthomas#! /bin/sh # mkinstalldirs --- make directory hierarchy scriptversion=2005-06-29.22 # Original author: Noah Friedman # Created: 1993-05-16 # Public domain. # # This file is maintained in Automake, please report # bugs to or send patches to # . errstatus=0 dirmode= usage="\ Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ... Create each directory DIR (with mode MODE, if specified), including all leading file name components. Report bugs to ." # process command line arguments while test $# -gt 0 ; do case $1 in -h | --help | --h*) # -h for help echo "$usage" exit $? ;; -m) # -m PERM arg shift test $# -eq 0 && { echo "$usage" 1>&2; exit 1; } dirmode=$1 shift ;; --version) echo "$0 $scriptversion" exit $? ;; --) # stop option processing shift break ;; -*) # unknown option echo "$usage" 1>&2 exit 1 ;; *) # first non-opt arg break ;; esac done for file do if test -d "$file"; then shift else break fi done case $# in 0) exit 0 ;; esac # Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and # mkdir -p a/c at the same time, both will detect that a is missing, # one will create a, then the other will try to create a and die with # a "File exists" error. This is a problem when calling mkinstalldirs # from a parallel make. We use --version in the probe to restrict # ourselves to GNU mkdir, which is thread-safe. case $dirmode in '') if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then echo "mkdir -p -- $*" exec mkdir -p -- "$@" else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. test -d ./-p && rmdir ./-p test -d ./--version && rmdir ./--version fi ;; *) if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 && test ! -d ./--version; then echo "mkdir -m $dirmode -p -- $*" exec mkdir -m "$dirmode" -p -- "$@" else # Clean up after NextStep and OpenStep mkdir. for d in ./-m ./-p ./--version "./$dirmode"; do test -d $d && rmdir $d done fi ;; esac for file do case $file in /*) pathcomp=/ ;; *) pathcomp= ;; esac oIFS=$IFS IFS=/ set fnord $file shift IFS=$oIFS for d do test "x$d" = x && continue pathcomp=$pathcomp$d case $pathcomp in -*) pathcomp=./$pathcomp ;; esac if test ! -d "$pathcomp"; then echo "mkdir $pathcomp" mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then errstatus=$lasterr else if test ! -z "$dirmode"; then echo "chmod $dirmode $pathcomp" lasterr= chmod "$dirmode" "$pathcomp" || lasterr=$? if test ! -z "$lasterr"; then errstatus=$lasterr fi fi fi fi pathcomp=$pathcomp/ done done exit $errstatus # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: apt-dater-0.9.0/po/0000755000175000017500000000000011761142205013366 5ustar thomasthomasapt-dater-0.9.0/po/ChangeLog0000644000175000017500000000071611760757134015160 0ustar thomasthomas2009-03-02 gettextize * Makefile.in.in: New file, from gettext-0.17. * boldquot.sed: New file, from gettext-0.17. * en@boldquot.header: New file, from gettext-0.17. * en@quot.header: New file, from gettext-0.17. * insert-header.sin: New file, from gettext-0.17. * quot.sed: New file, from gettext-0.17. * remove-potcdate.sin: New file, from gettext-0.17. * Rules-quot: New file, from gettext-0.17. * POTFILES.in: New file. apt-dater-0.9.0/po/LINGUAS0000644000175000017500000000000611760757134014423 0ustar thomasthomasde it apt-dater-0.9.0/po/Makefile.in.in0000644000175000017500000003552411760757134016065 0ustar thomasthomas# Makefile for PO directory in any package using GNU gettext. # Copyright (C) 1995-1997, 2000-2007 by Ulrich Drepper # # This file can be copied and used freely without restrictions. It can # be used in projects which are not available under the GNU General Public # License but which still want to provide support for the GNU gettext # functionality. # Please note that the actual code of GNU gettext is covered by the GNU # General Public License and is *not* in the public domain. # # Origin: gettext-0.17 GETTEXT_MACRO_VERSION = 0.17 PACKAGE = @PACKAGE@ VERSION = @VERSION@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ SHELL = /bin/sh @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ datarootdir = @datarootdir@ datadir = @datadir@ localedir = @localedir@ gettextsrcdir = $(datadir)/gettext/po INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ # We use $(mkdir_p). # In automake <= 1.9.x, $(mkdir_p) is defined either as "mkdir -p --" or as # "$(mkinstalldirs)" or as "$(install_sh) -d". For these automake versions, # @install_sh@ does not start with $(SHELL), so we add it. # In automake >= 1.10, @mkdir_p@ is derived from ${MKDIR_P}, which is defined # either as "/path/to/mkdir -p" or ".../install-sh -c -d". For these automake # versions, $(mkinstalldirs) and $(install_sh) are unused. mkinstalldirs = $(SHELL) @install_sh@ -d install_sh = $(SHELL) @install_sh@ MKDIR_P = @MKDIR_P@ mkdir_p = @mkdir_p@ GMSGFMT_ = @GMSGFMT@ GMSGFMT_no = @GMSGFMT@ GMSGFMT_yes = @GMSGFMT_015@ GMSGFMT = $(GMSGFMT_$(USE_MSGCTXT)) MSGFMT_ = @MSGFMT@ MSGFMT_no = @MSGFMT@ MSGFMT_yes = @MSGFMT_015@ MSGFMT = $(MSGFMT_$(USE_MSGCTXT)) XGETTEXT_ = @XGETTEXT@ XGETTEXT_no = @XGETTEXT@ XGETTEXT_yes = @XGETTEXT_015@ XGETTEXT = $(XGETTEXT_$(USE_MSGCTXT)) MSGMERGE = msgmerge MSGMERGE_UPDATE = @MSGMERGE@ --update MSGINIT = msginit MSGCONV = msgconv MSGFILTER = msgfilter POFILES = @POFILES@ GMOFILES = @GMOFILES@ UPDATEPOFILES = @UPDATEPOFILES@ DUMMYPOFILES = @DUMMYPOFILES@ DISTFILES.common = Makefile.in.in remove-potcdate.sin \ $(DISTFILES.common.extra1) $(DISTFILES.common.extra2) $(DISTFILES.common.extra3) DISTFILES = $(DISTFILES.common) Makevars POTFILES.in \ $(POFILES) $(GMOFILES) \ $(DISTFILES.extra1) $(DISTFILES.extra2) $(DISTFILES.extra3) POTFILES = \ CATALOGS = @CATALOGS@ # Makevars gets inserted here. (Don't remove this line!) .SUFFIXES: .SUFFIXES: .po .gmo .mo .sed .sin .nop .po-create .po-update .po.mo: @echo "$(MSGFMT) -c -o $@ $<"; \ $(MSGFMT) -c -o t-$@ $< && mv t-$@ $@ .po.gmo: @lang=`echo $* | sed -e 's,.*/,,'`; \ test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o $${lang}.gmo $${lang}.po"; \ cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo .sin.sed: sed -e '/^#/d' $< > t-$@ mv t-$@ $@ all: check-macro-version all-@USE_NLS@ all-yes: stamp-po all-no: # Ensure that the gettext macros and this Makefile.in.in are in sync. check-macro-version: @test "$(GETTEXT_MACRO_VERSION)" = "@GETTEXT_MACRO_VERSION@" \ || { echo "*** error: gettext infrastructure mismatch: using a Makefile.in.in from gettext version $(GETTEXT_MACRO_VERSION) but the autoconf macros are from gettext version @GETTEXT_MACRO_VERSION@" 1>&2; \ exit 1; \ } # $(srcdir)/$(DOMAIN).pot is only created when needed. When xgettext finds no # internationalized messages, no $(srcdir)/$(DOMAIN).pot is created (because # we don't want to bother translators with empty POT files). We assume that # LINGUAS is empty in this case, i.e. $(POFILES) and $(GMOFILES) are empty. # In this case, stamp-po is a nop (i.e. a phony target). # stamp-po is a timestamp denoting the last time at which the CATALOGS have # been loosely updated. Its purpose is that when a developer or translator # checks out the package via CVS, and the $(DOMAIN).pot file is not in CVS, # "make" will update the $(DOMAIN).pot and the $(CATALOGS), but subsequent # invocations of "make" will do nothing. This timestamp would not be necessary # if updating the $(CATALOGS) would always touch them; however, the rule for # $(POFILES) has been designed to not touch files that don't need to be # changed. stamp-po: $(srcdir)/$(DOMAIN).pot test ! -f $(srcdir)/$(DOMAIN).pot || \ test -z "$(GMOFILES)" || $(MAKE) $(GMOFILES) @test ! -f $(srcdir)/$(DOMAIN).pot || { \ echo "touch stamp-po" && \ echo timestamp > stamp-poT && \ mv stamp-poT stamp-po; \ } # Note: Target 'all' must not depend on target '$(DOMAIN).pot-update', # otherwise packages like GCC can not be built if only parts of the source # have been downloaded. # This target rebuilds $(DOMAIN).pot; it is an expensive operation. # Note that $(DOMAIN).pot is not touched if it doesn't need to be changed. $(DOMAIN).pot-update: $(POTFILES) $(srcdir)/POTFILES.in remove-potcdate.sed if LC_ALL=C grep 'GNU @PACKAGE@' $(top_srcdir)/* 2>/dev/null | grep -v 'libtool:' >/dev/null; then \ package_gnu='GNU '; \ else \ package_gnu=''; \ fi; \ if test -n '$(MSGID_BUGS_ADDRESS)' || test '$(PACKAGE_BUGREPORT)' = '@'PACKAGE_BUGREPORT'@'; then \ msgid_bugs_address='$(MSGID_BUGS_ADDRESS)'; \ else \ msgid_bugs_address='$(PACKAGE_BUGREPORT)'; \ fi; \ case `$(XGETTEXT) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \ '' | 0.[0-9] | 0.[0-9].* | 0.1[0-5] | 0.1[0-5].* | 0.16 | 0.16.[0-1]*) \ $(XGETTEXT) --default-domain=$(DOMAIN) --directory=$(top_srcdir) \ --add-comments=TRANSLATORS: $(XGETTEXT_OPTIONS) @XGETTEXT_EXTRA_OPTIONS@ \ --files-from=$(srcdir)/POTFILES.in \ --copyright-holder='$(COPYRIGHT_HOLDER)' \ --msgid-bugs-address="$$msgid_bugs_address" \ ;; \ *) \ $(XGETTEXT) --default-domain=$(DOMAIN) --directory=$(top_srcdir) \ --add-comments=TRANSLATORS: $(XGETTEXT_OPTIONS) @XGETTEXT_EXTRA_OPTIONS@ \ --files-from=$(srcdir)/POTFILES.in \ --copyright-holder='$(COPYRIGHT_HOLDER)' \ --package-name="$${package_gnu}@PACKAGE@" \ --package-version='@VERSION@' \ --msgid-bugs-address="$$msgid_bugs_address" \ ;; \ esac test ! -f $(DOMAIN).po || { \ if test -f $(srcdir)/$(DOMAIN).pot; then \ sed -f remove-potcdate.sed < $(srcdir)/$(DOMAIN).pot > $(DOMAIN).1po && \ sed -f remove-potcdate.sed < $(DOMAIN).po > $(DOMAIN).2po && \ if cmp $(DOMAIN).1po $(DOMAIN).2po >/dev/null 2>&1; then \ rm -f $(DOMAIN).1po $(DOMAIN).2po $(DOMAIN).po; \ else \ rm -f $(DOMAIN).1po $(DOMAIN).2po $(srcdir)/$(DOMAIN).pot && \ mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \ fi; \ else \ mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \ fi; \ } # This rule has no dependencies: we don't need to update $(DOMAIN).pot at # every "make" invocation, only create it when it is missing. # Only "make $(DOMAIN).pot-update" or "make dist" will force an update. $(srcdir)/$(DOMAIN).pot: $(MAKE) $(DOMAIN).pot-update # This target rebuilds a PO file if $(DOMAIN).pot has changed. # Note that a PO file is not touched if it doesn't need to be changed. $(POFILES): $(srcdir)/$(DOMAIN).pot @lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \ if test -f "$(srcdir)/$${lang}.po"; then \ test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \ cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot; \ else \ $(MAKE) $${lang}.po-create; \ fi install: install-exec install-data install-exec: install-data: install-data-@USE_NLS@ if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkdir_p) $(DESTDIR)$(gettextsrcdir); \ for file in $(DISTFILES.common) Makevars.template; do \ $(INSTALL_DATA) $(srcdir)/$$file \ $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ for file in Makevars; do \ rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ else \ : ; \ fi install-data-no: all install-data-yes: all $(mkdir_p) $(DESTDIR)$(datadir) @catalogs='$(CATALOGS)'; \ for cat in $$catalogs; do \ cat=`basename $$cat`; \ lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \ dir=$(localedir)/$$lang/LC_MESSAGES; \ $(mkdir_p) $(DESTDIR)$$dir; \ if test -r $$cat; then realcat=$$cat; else realcat=$(srcdir)/$$cat; fi; \ $(INSTALL_DATA) $$realcat $(DESTDIR)$$dir/$(DOMAIN).mo; \ echo "installing $$realcat as $(DESTDIR)$$dir/$(DOMAIN).mo"; \ for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \ if test -n "$$lc"; then \ if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \ link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \ mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \ mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \ (cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \ for file in *; do \ if test -f $$file; then \ ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \ fi; \ done); \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \ else \ if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \ :; \ else \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \ mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \ fi; \ fi; \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \ ln -s ../LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \ ln $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \ cp -p $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \ echo "installing $$realcat link as $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo"; \ fi; \ done; \ done install-strip: install installdirs: installdirs-exec installdirs-data installdirs-exec: installdirs-data: installdirs-data-@USE_NLS@ if test "$(PACKAGE)" = "gettext-tools"; then \ $(mkdir_p) $(DESTDIR)$(gettextsrcdir); \ else \ : ; \ fi installdirs-data-no: installdirs-data-yes: $(mkdir_p) $(DESTDIR)$(datadir) @catalogs='$(CATALOGS)'; \ for cat in $$catalogs; do \ cat=`basename $$cat`; \ lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \ dir=$(localedir)/$$lang/LC_MESSAGES; \ $(mkdir_p) $(DESTDIR)$$dir; \ for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \ if test -n "$$lc"; then \ if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \ link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \ mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \ mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \ (cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \ for file in *; do \ if test -f $$file; then \ ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \ fi; \ done); \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \ else \ if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \ :; \ else \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \ mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \ fi; \ fi; \ fi; \ done; \ done # Define this as empty until I found a useful application. installcheck: uninstall: uninstall-exec uninstall-data uninstall-exec: uninstall-data: uninstall-data-@USE_NLS@ if test "$(PACKAGE)" = "gettext-tools"; then \ for file in $(DISTFILES.common) Makevars.template; do \ rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \ done; \ else \ : ; \ fi uninstall-data-no: uninstall-data-yes: catalogs='$(CATALOGS)'; \ for cat in $$catalogs; do \ cat=`basename $$cat`; \ lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \ for lc in LC_MESSAGES $(EXTRA_LOCALE_CATEGORIES); do \ rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \ done; \ done check: all info dvi ps pdf html tags TAGS ctags CTAGS ID: mostlyclean: rm -f remove-potcdate.sed rm -f stamp-poT rm -f core core.* $(DOMAIN).po $(DOMAIN).1po $(DOMAIN).2po *.new.po rm -fr *.o clean: mostlyclean distclean: clean rm -f Makefile Makefile.in POTFILES *.mo maintainer-clean: distclean @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." rm -f stamp-po $(GMOFILES) distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) dist distdir: $(MAKE) update-po @$(MAKE) dist2 # This is a separate target because 'update-po' must be executed before. dist2: stamp-po $(DISTFILES) dists="$(DISTFILES)"; \ if test "$(PACKAGE)" = "gettext-tools"; then \ dists="$$dists Makevars.template"; \ fi; \ if test -f $(srcdir)/$(DOMAIN).pot; then \ dists="$$dists $(DOMAIN).pot stamp-po"; \ fi; \ if test -f $(srcdir)/ChangeLog; then \ dists="$$dists ChangeLog"; \ fi; \ for i in 0 1 2 3 4 5 6 7 8 9; do \ if test -f $(srcdir)/ChangeLog.$$i; then \ dists="$$dists ChangeLog.$$i"; \ fi; \ done; \ if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS"; fi; \ for file in $$dists; do \ if test -f $$file; then \ cp -p $$file $(distdir) || exit 1; \ else \ cp -p $(srcdir)/$$file $(distdir) || exit 1; \ fi; \ done update-po: Makefile $(MAKE) $(DOMAIN).pot-update test -z "$(UPDATEPOFILES)" || $(MAKE) $(UPDATEPOFILES) $(MAKE) update-gmo # General rule for creating PO files. .nop.po-create: @lang=`echo $@ | sed -e 's/\.po-create$$//'`; \ echo "File $$lang.po does not exist. If you are a translator, you can create it through 'msginit'." 1>&2; \ exit 1 # General rule for updating PO files. .nop.po-update: @lang=`echo $@ | sed -e 's/\.po-update$$//'`; \ if test "$(PACKAGE)" = "gettext-tools"; then PATH=`pwd`/../src:$$PATH; fi; \ tmpdir=`pwd`; \ echo "$$lang:"; \ test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ echo "$${cdcmd}$(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$lang.new.po"; \ cd $(srcdir); \ if $(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$tmpdir/$$lang.new.po; then \ if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \ rm -f $$tmpdir/$$lang.new.po; \ else \ if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \ :; \ else \ echo "msgmerge for $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \ exit 1; \ fi; \ fi; \ else \ echo "msgmerge for $$lang.po failed!" 1>&2; \ rm -f $$tmpdir/$$lang.new.po; \ fi $(DUMMYPOFILES): update-gmo: Makefile $(GMOFILES) @: Makefile: Makefile.in.in Makevars $(top_builddir)/config.status @POMAKEFILEDEPS@ cd $(top_builddir) \ && $(SHELL) ./config.status $(subdir)/$@.in po-directories force: # Tell versions [3.59,3.63) of GNU make not to export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: apt-dater-0.9.0/po/Makevars0000644000175000017500000000342411760757134015101 0ustar thomasthomas# Makefile variables for PO directory in any package using GNU gettext. # Usually the message domain is the same as the package name. DOMAIN = $(PACKAGE) # These two variables depend on the location of this directory. subdir = po top_builddir = .. # These options get passed to xgettext. XGETTEXT_OPTIONS = --keyword=_ --keyword=N_ # This is the copyright holder that gets inserted into the header of the # $(DOMAIN).pot file. Set this to the copyright holder of the surrounding # package. (Note that the msgstr strings, extracted from the package's # sources, belong to the copyright holder of the package.) Translators are # expected to transfer the copyright for their translations to this person # or entity, or to disclaim their copyright. The empty string stands for # the public domain; in this case the translators are expected to disclaim # their copyright. COPYRIGHT_HOLDER = IBH IT-Service GmbH # This is the email address or URL to which the translators shall report # bugs in the untranslated strings: # - Strings which are not entire sentences, see the maintainer guidelines # in the GNU gettext documentation, section 'Preparing Strings'. # - Strings which use unclear terms or require additional context to be # understood. # - Strings which make invalid assumptions about notation of date, time or # money. # - Pluralisation problems. # - Incorrect English spelling. # - Incorrect formatting. # It can be your email address, or a mailing list address where translators # can write to without being subscribed, or the URL of a web page through # which the translators can contact you. MSGID_BUGS_ADDRESS = apt-dater@ibh.de # This is the list of locale categories, beyond LC_MESSAGES, for which the # message catalogs shall be used. It is usually empty. EXTRA_LOCALE_CATEGORIES = apt-dater-0.9.0/po/POTFILES.in0000644000175000017500000000026711760757134015164 0ustar thomasthomas./src/apt-dater.c ./src/autoref.c ./src/colors.c ./src/exec.c ./src/keyfiles.c ./src/lock.c ./src/parsecmd.c ./src/report.c ./src/screen.c ./src/sighandler.c ./src/stats.c ./src/ui.c apt-dater-0.9.0/po/Rules-quot0000644000175000017500000000337611760757134015416 0ustar thomasthomas# Special Makefile rules for English message catalogs with quotation marks. DISTFILES.common.extra1 = quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot .SUFFIXES: .insert-header .po-update-en en@quot.po-create: $(MAKE) en@quot.po-update en@boldquot.po-create: $(MAKE) en@boldquot.po-update en@quot.po-update: en@quot.po-update-en en@boldquot.po-update: en@boldquot.po-update-en .insert-header.po-update-en: @lang=`echo $@ | sed -e 's/\.po-update-en$$//'`; \ if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; GETTEXTLIBDIR=`cd $(top_srcdir)/src && pwd`; export GETTEXTLIBDIR; fi; \ tmpdir=`pwd`; \ echo "$$lang:"; \ ll=`echo $$lang | sed -e 's/@.*//'`; \ LC_ALL=C; export LC_ALL; \ cd $(srcdir); \ if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$ll -o - 2>/dev/null | sed -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | $(MSGFILTER) sed -f `echo $$lang | sed -e 's/.*@//'`.sed 2>/dev/null > $$tmpdir/$$lang.new.po; then \ if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \ rm -f $$tmpdir/$$lang.new.po; \ else \ if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \ :; \ else \ echo "creation of $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \ exit 1; \ fi; \ fi; \ else \ echo "creation of $$lang.po failed!" 1>&2; \ rm -f $$tmpdir/$$lang.new.po; \ fi en@quot.insert-header: insert-header.sin sed -e '/^#/d' -e 's/HEADER/en@quot.header/g' $(srcdir)/insert-header.sin > en@quot.insert-header en@boldquot.insert-header: insert-header.sin sed -e '/^#/d' -e 's/HEADER/en@boldquot.header/g' $(srcdir)/insert-header.sin > en@boldquot.insert-header mostlyclean: mostlyclean-quot mostlyclean-quot: rm -f *.insert-header apt-dater-0.9.0/po/apt-dater.pot0000644000175000017500000002512411760757134016013 0ustar thomasthomas# SOME DESCRIPTIVE TITLE. # Copyright (C) YEAR IBH IT-Service GmbH # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. # #, fuzzy msgid "" msgstr "" "Project-Id-Version: apt-dater 0.9.0\n" "Report-Msgid-Bugs-To: apt-dater@ibh.de\n" "POT-Creation-Date: 2011-11-15 21:53+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "Language: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=CHARSET\n" "Content-Transfer-Encoding: 8bit\n" #: src/apt-dater.c:82 src/apt-dater.c:85 src/apt-dater.c:124 #: src/keyfiles.c:107 src/keyfiles.c:118 src/ui.c:3449 msgid "Out of memory." msgstr "" #: src/apt-dater.c:91 #, c-format msgid "Failed to create initial configuration file %s." msgstr "" #: src/apt-dater.c:107 msgid "Sorry, apt-dater was compiled w/o report feature!" msgstr "" #: src/apt-dater.c:117 #, c-format msgid "Usage: %s [-(c config|v|[n]r)]\n" msgstr "" #: src/apt-dater.c:119 #, c-format msgid "Usage: %s [-(c config|v)]\n" msgstr "" #: src/apt-dater.c:127 src/apt-dater.c:132 #, c-format msgid "Error on loading config file %s\n" msgstr "" #: src/apt-dater.c:184 msgid "Cannot open your terminal /proc/self/fd/0 - please check." msgstr "" #: src/colors.c:153 msgid "Wrong color definition!" msgstr "" #: src/keyfiles.c:109 src/keyfiles.c:120 src/keyfiles.c:131 #, c-format msgid "Creating file %s" msgstr "" #: src/keyfiles.c:111 src/keyfiles.c:122 src/keyfiles.c:132 #, c-format msgid "Could not write to file %s." msgstr "" #: src/lock.c:56 msgid "Can't get the name of the lock file!" msgstr "" #: src/lock.c:77 #, c-format msgid "Failed to get lockfile %s: %s" msgstr "" #: src/lock.c:81 #, c-format msgid "Can't lock to file %s because function flock() is missing!" msgstr "" #: src/report.c:58 msgid "Error creating the xml output." msgstr "" #: src/report.c:63 #, c-format msgid "apt-dater is refreshing %d hosts, please standby...\n" msgstr "" #: src/stats.c:495 msgid "Auto refresh triggered..." msgstr "" #: src/ui.c:55 msgid "Updates pending" msgstr "" #: src/ui.c:56 msgid "Up to date" msgstr "" #: src/ui.c:57 msgid "Broken packages" msgstr "" #: src/ui.c:58 src/ui.c:1382 #, c-format msgid "Refresh required" msgstr "" #: src/ui.c:59 src/ui.c:1385 #, c-format msgid "In refresh" msgstr "" #: src/ui.c:60 msgid "Sessions" msgstr "" #: src/ui.c:62 msgid "Filtered" msgstr "" #: src/ui.c:64 msgid "Unknown" msgstr "" #: src/ui.c:149 msgid "" msgstr "" #: src/ui.c:149 src/ui.c:150 msgid "shrink node" msgstr "" #: src/ui.c:151 msgid "" msgstr "" #: src/ui.c:151 src/ui.c:152 msgid "expand node" msgstr "" #: src/ui.c:153 msgid "" msgstr "" #: src/ui.c:153 src/ui.c:154 src/ui.c:155 src/ui.c:164 msgid "shrink/expand node" msgstr "" #: src/ui.c:154 msgid "" msgstr "" #: src/ui.c:155 msgid "" msgstr "" #: src/ui.c:156 msgid "" msgstr "" #: src/ui.c:156 src/ui.c:157 msgid "move up" msgstr "" #: src/ui.c:158 msgid "" msgstr "" #: src/ui.c:158 src/ui.c:159 msgid "move down" msgstr "" #: src/ui.c:160 msgid "" msgstr "" #: src/ui.c:160 msgid "move to the top" msgstr "" #: src/ui.c:161 msgid "" msgstr "" #: src/ui.c:161 msgid "move to the end" msgstr "" #: src/ui.c:162 msgid "" msgstr "" #: src/ui.c:162 msgid "previous page" msgstr "" #: src/ui.c:163 msgid "" msgstr "" #: src/ui.c:163 msgid "next page" msgstr "" #: src/ui.c:165 msgid "quit" msgstr "" #: src/ui.c:166 msgid "help" msgstr "" #: src/ui.c:167 msgid "search host" msgstr "" #: src/ui.c:169 msgid "filter hosts" msgstr "" #: src/ui.c:171 msgid "attach session" msgstr "" #: src/ui.c:172 msgid "connect host" msgstr "" #: src/ui.c:173 msgid "file transfer" msgstr "" #: src/ui.c:174 msgid "toggle dumps" msgstr "" #: src/ui.c:175 msgid "refresh host" msgstr "" #: src/ui.c:176 msgid "failure diagnostic" msgstr "" #: src/ui.c:177 msgid "install pkg" msgstr "" #: src/ui.c:178 msgid "upgrade host(s)" msgstr "" #: src/ui.c:179 msgid "host details" msgstr "" #: src/ui.c:181 msgid "host history" msgstr "" #: src/ui.c:182 msgid "play" msgstr "" #: src/ui.c:183 msgid "display with less" msgstr "" #: src/ui.c:185 msgid "next detached session" msgstr "" #: src/ui.c:186 msgid "cycle detached sessions" msgstr "" #: src/ui.c:187 msgid "tag current host" msgstr "" #: src/ui.c:188 msgid "tag all hosts matching" msgstr "" #: src/ui.c:189 msgid " ~c tag by codename" msgstr "" #: src/ui.c:190 msgid " ~d tag by distribution" msgstr "" #: src/ui.c:191 msgid " ~f tag by host flags" msgstr "" #: src/ui.c:192 msgid " ~g tag by group" msgstr "" #: src/ui.c:193 msgid " ~p tag by packages" msgstr "" #: src/ui.c:194 msgid " ~u tag by updates" msgstr "" #: src/ui.c:195 msgid " ~A tag all hosts" msgstr "" #: src/ui.c:196 msgid "untag all hosts matching" msgstr "" #: src/ui.c:197 msgid "apply next function to tagged hosts" msgstr "" #: src/ui.c:202 msgid "some packages are kept back" msgstr "" #: src/ui.c:203 msgid "extra packages are installed" msgstr "" #: src/ui.c:204 msgid "running kernel is not the latest (reboot required)" msgstr "" #: src/ui.c:205 msgid "a selfbuild kernel is running" msgstr "" #: src/ui.c:206 msgid "this is a virtualized machine" msgstr "" #: src/ui.c:580 msgid "FLAG" msgstr "" #: src/ui.c:581 src/ui.c:594 msgid "DESCRIPTION" msgstr "" #: src/ui.c:593 msgid "KEY" msgstr "" #: src/ui.c:642 msgid "HOST DETAILS" msgstr "" #: src/ui.c:645 msgid "Group:" msgstr "" #: src/ui.c:647 msgid "Hostname:" msgstr "" #: src/ui.c:650 msgid "Machine Type:" msgstr "" #: src/ui.c:654 msgid "Architecture:" msgstr "" #: src/ui.c:658 msgid "UUID:" msgstr "" #: src/ui.c:662 msgid "Forbidden:" msgstr "" #: src/ui.c:666 msgid "refresh" msgstr "" #: src/ui.c:673 msgid "upgrade" msgstr "" #: src/ui.c:680 msgid "install" msgstr "" #: src/ui.c:688 msgid "Distri:" msgstr "" #: src/ui.c:694 msgid "Release:" msgstr "" #: src/ui.c:698 msgid "Kernel name:" msgstr "" #: src/ui.c:702 msgid "Kernel version:" msgstr "" #: src/ui.c:707 msgid "(reboot required)" msgstr "" #: src/ui.c:710 msgid "(selfbuild kernel)" msgstr "" #: src/ui.c:724 msgid "Packages: " msgstr "" #: src/ui.c:735 msgid "BROKEN PACKAGES" msgstr "" #: src/ui.c:756 msgid "UPDATE PACKAGES" msgstr "" #: src/ui.c:777 msgid "HOLD BACK PACKAGES" msgstr "" #: src/ui.c:797 msgid "EXTRA PACKAGES" msgstr "" #: src/ui.c:817 msgid "INSTALLED PACKAGES" msgstr "" #: src/ui.c:878 msgid "FAILURE DIAGNOSTIC" msgstr "" #: src/ui.c:918 msgid " [Oldest: %D %H:%M]" msgstr "" #: src/ui.c:1004 msgid "c" msgstr "" #: src/ui.c:1004 msgid "C" msgstr "" #: src/ui.c:1007 msgid "y" msgstr "" #: src/ui.c:1007 msgid "Y" msgstr "" #: src/ui.c:1082 msgid "No history data available!" msgstr "" #: src/ui.c:1088 #, c-format msgid "History of %s (%d entry available)" msgstr "" #: src/ui.c:1089 #, c-format msgid "History of %s (%d entries available)" msgstr "" #: src/ui.c:1171 msgid "replay terminated, press any key to continue" msgstr "" #: src/ui.c:1230 src/ui.c:1261 #, c-format msgid "%d Hosts in status \"%s\"" msgstr "" #: src/ui.c:1233 src/ui.c:1264 #, c-format msgid "%d Host in status \"%s\"" msgstr "" #: src/ui.c:1361 #, c-format msgid "%d Updates required" msgstr "" #: src/ui.c:1364 #, c-format msgid "%d Update required" msgstr "" #: src/ui.c:1369 #, c-format msgid "No update required" msgstr "" #: src/ui.c:1374 #, c-format msgid "%d Broken packages" msgstr "" #: src/ui.c:1377 #, c-format msgid "%d Broken package" msgstr "" #: src/ui.c:1390 #, c-format msgid "%d sessions running" msgstr "" #: src/ui.c:1393 #, c-format msgid "%d session running" msgstr "" #: src/ui.c:1399 #, c-format msgid "Status is unknown" msgstr "" #: src/ui.c:1402 #, c-format msgid "Error: %s" msgstr "" #: src/ui.c:1408 msgid " - host locked by another process" msgstr "" #: src/ui.c:1464 #, c-format msgid "Running session %s [%5d]:" msgstr "" #: src/ui.c:1490 src/ui.c:1563 msgid "%D %H:%M " msgstr "" #: src/ui.c:1493 src/ui.c:1566 msgid "Attached" msgstr "" #: src/ui.c:1493 src/ui.c:1566 msgid "Detached" msgstr "" #: src/ui.c:1505 msgid "Could not read session dump." msgstr "" #: src/ui.c:1508 msgid "attached" msgstr "" #: src/ui.c:1508 msgid "detached" msgstr "" #: src/ui.c:1837 msgid "Maintainer name:" msgstr "" #: src/ui.c:2458 msgid "Search: " msgstr "" #: src/ui.c:2631 msgid "Matches:" msgstr "" #: src/ui.c:2648 msgid "Matches: -" msgstr "" #: src/ui.c:2713 msgid "Internal error: unhandled TCL TCLM_STRING mapping!" msgstr "" #: src/ui.c:2728 msgid "Internal error: unhandled TCL TCLM_INT mapping!" msgstr "" #: src/ui.c:2738 msgid "Internal error: unknown TCL mapping type!" msgstr "" #: src/ui.c:2797 msgid "Scalars:" msgstr "" #: src/ui.c:2819 msgid "Arrays:" msgstr "" #: src/ui.c:2840 msgid "Examples:" msgstr "" #: src/ui.c:2853 msgid "Enter filter expression:" msgstr "" #: src/ui.c:2887 #, c-format msgid "An error at %s:%d has been detected [Less/ignore/connect]: " msgstr "" #: src/ui.c:2889 #, c-format msgid "An error at %s has been detected [Less/ignore/connect]: " msgstr "" #: src/ui.c:3066 #, c-format msgid "Refresh %d tagged hosts? [y/N]: " msgstr "" #: src/ui.c:3101 msgid "tag-" msgstr "" #: src/ui.c:3115 src/ui.c:3141 src/ui.c:3269 msgid "There are running sessions on this host! Continue? [y/N]: " msgstr "" #: src/ui.c:3164 msgid "Run update for the whole category? [y/N]: " msgstr "" #: src/ui.c:3165 msgid "Run update for the whole group? [y/N]: " msgstr "" #: src/ui.c:3209 #, c-format msgid "Run update for %d tagged and updatable hosts? [y/N]: " msgstr "" #: src/ui.c:3239 #, c-format msgid "Install package `%s' [y/N]: " msgstr "" #: src/ui.c:3245 src/ui.c:3274 src/ui.c:3290 msgid "Install package: " msgstr "" #: src/ui.c:3294 msgid "Run install for the whole category? [y/N]: " msgstr "" #: src/ui.c:3295 msgid "Run install for the whole group? [y/N]: " msgstr "" #: src/ui.c:3340 #, c-format msgid "Install package on %d tagged hosts: " msgstr "" #: src/ui.c:3368 msgid "Tag hosts matching: " msgstr "" #: src/ui.c:3369 msgid "Untag hosts matching: " msgstr "" #: src/ui.c:3444 #, c-format msgid "Attach host %s session %d (%d %s left) [Y/n/c]: " msgstr "" #: src/ui.c:3446 msgid "session" msgstr "" #: src/ui.c:3446 msgid "sessions" msgstr "" #: src/ui.c:3518 msgid "Already attached - share session? [y/N]: " msgstr "" #: src/ui.c:3546 msgid "Session dumps enabled." msgstr "" #: src/ui.c:3548 msgid "Session dumps disabled." msgstr "" #: src/ui.c:3646 #, c-format msgid "There are %d hosts in status refresh state, quit apt-dater? [y/N]: " msgstr "" #: src/ui.c:3649 #, c-format msgid "There is %d host in status refresh state, quit apt-dater? [y/N]: " msgstr "" apt-dater-0.9.0/po/boldquot.sed0000644000175000017500000000033111760757134015725 0ustar thomasthomass/"\([^"]*\)"/“\1”/g s/`\([^`']*\)'/‘\1’/g s/ '\([^`']*\)' / ‘\1’ /g s/ '\([^`']*\)'$/ ‘\1’/g s/^'\([^`']*\)' /‘\1’ /g s/“”/""/g s/“/“/g s/”/”/g s/‘/‘/g s/’/’/g apt-dater-0.9.0/po/de.po0000644000175000017500000003425011760757134014336 0ustar thomasthomas# SOME DESCRIPTIVE TITLE. # Copyright (C) YEAR IBH IT-Service GmbH # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. # msgid "" msgstr "" "Project-Id-Version: apt-dater 0.8.1\n" "Report-Msgid-Bugs-To: apt-dater@ibh.de\n" "POT-Creation-Date: 2011-11-15 21:53+0100\n" "PO-Revision-Date: 2009-11-14 09:26+0100\n" "Last-Translator: Thomas Liske \n" "Language-Team: apt-dater@ibh.de\n" "Language: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #: src/apt-dater.c:82 src/apt-dater.c:85 src/apt-dater.c:124 #: src/keyfiles.c:107 src/keyfiles.c:118 src/ui.c:3449 msgid "Out of memory." msgstr "Nicht genügend Speicher." #: src/apt-dater.c:91 #, c-format msgid "Failed to create initial configuration file %s." msgstr "Die initiale Konfigurationsdatei %s konnte nicht erstellt werden." #: src/apt-dater.c:107 msgid "Sorry, apt-dater was compiled w/o report feature!" msgstr "Leider wurde apt-dater ohne Report-Merkmal übersetzt." #: src/apt-dater.c:117 #, c-format msgid "Usage: %s [-(c config|v|[n]r)]\n" msgstr "Aufruf: %s [-(c config|v|[n]r)]\n" #: src/apt-dater.c:119 #, c-format msgid "Usage: %s [-(c config|v)]\n" msgstr "Aufruf: %s [-(c config|v)]\n" #: src/apt-dater.c:127 src/apt-dater.c:132 #, c-format msgid "Error on loading config file %s\n" msgstr "Fehler beim Laden der Konfigurationsdatei %s\n" #: src/apt-dater.c:184 msgid "Cannot open your terminal /proc/self/fd/0 - please check." msgstr "Kann Terminal /proc/self/fd/0 nicht öffnen - bitte überprüfen." #: src/colors.c:153 msgid "Wrong color definition!" msgstr "Fehlerhafte Farbdefinition!" #: src/keyfiles.c:109 src/keyfiles.c:120 src/keyfiles.c:131 #, c-format msgid "Creating file %s" msgstr "Erstelle Datei %s" #: src/keyfiles.c:111 src/keyfiles.c:122 src/keyfiles.c:132 #, c-format msgid "Could not write to file %s." msgstr "Kann nicht in Datei %s schreiben." #: src/lock.c:56 msgid "Can't get the name of the lock file!" msgstr "Kann Namen der Lock-Datei nicht ermitteln!" #: src/lock.c:77 #, c-format msgid "Failed to get lockfile %s: %s" msgstr "Fehler beim Anlegen der Lock-Datei %s: %s" #: src/lock.c:81 #, c-format msgid "Can't lock to file %s because function flock() is missing!" msgstr "Kann Datei %s nicht sperren da flock() nicht zur Verfügung steht!" #: src/report.c:58 msgid "Error creating the xml output." msgstr "Fehler beim Erstellen der XML-Ausgabe." #: src/report.c:63 #, c-format msgid "apt-dater is refreshing %d hosts, please standby...\n" msgstr "apt-dater aktualisiert %d Hosts, bitte warten...\n" #: src/stats.c:495 msgid "Auto refresh triggered..." msgstr "Aktualisierung ausgelöst..." #: src/ui.c:55 msgid "Updates pending" msgstr "Updates vorhanden" #: src/ui.c:56 msgid "Up to date" msgstr "Aktuell" #: src/ui.c:57 msgid "Broken packages" msgstr "Defekte Pakete" #: src/ui.c:58 src/ui.c:1382 #, c-format msgid "Refresh required" msgstr "Aktualisierung benötigt" #: src/ui.c:59 src/ui.c:1385 #, c-format msgid "In refresh" msgstr "Wird aktualisiert" #: src/ui.c:60 msgid "Sessions" msgstr "Sitzungen" #: src/ui.c:62 msgid "Filtered" msgstr "Gefiltert" #: src/ui.c:64 msgid "Unknown" msgstr "Unbekannt" #: src/ui.c:149 msgid "" msgstr "" #: src/ui.c:149 src/ui.c:150 msgid "shrink node" msgstr "Baum zusammenklappen" #: src/ui.c:151 msgid "" msgstr "" #: src/ui.c:151 src/ui.c:152 msgid "expand node" msgstr "Baum aufklappen" #: src/ui.c:153 msgid "" msgstr "" #: src/ui.c:153 src/ui.c:154 src/ui.c:155 src/ui.c:164 msgid "shrink/expand node" msgstr "Baum auf-/zusammenklappen" #: src/ui.c:154 msgid "" msgstr "" #: src/ui.c:155 msgid "" msgstr "" #: src/ui.c:156 msgid "" msgstr "" #: src/ui.c:156 src/ui.c:157 msgid "move up" msgstr "nach oben" #: src/ui.c:158 msgid "" msgstr "" #: src/ui.c:158 src/ui.c:159 msgid "move down" msgstr "nach unten" #: src/ui.c:160 msgid "" msgstr "" #: src/ui.c:160 msgid "move to the top" msgstr "an den Anfang" #: src/ui.c:161 msgid "" msgstr "" #: src/ui.c:161 msgid "move to the end" msgstr "an das Ende" #: src/ui.c:162 msgid "" msgstr "Bild hoch" #: src/ui.c:162 msgid "previous page" msgstr "vorherige Seite" #: src/ui.c:163 msgid "" msgstr "Bild runter" #: src/ui.c:163 msgid "next page" msgstr "nächste Seite" #: src/ui.c:165 msgid "quit" msgstr "Beenden" #: src/ui.c:166 msgid "help" msgstr "Hilfe" #: src/ui.c:167 msgid "search host" msgstr "Host suchen" #: src/ui.c:169 msgid "filter hosts" msgstr "Hosts filtern" #: src/ui.c:171 msgid "attach session" msgstr "mit Sitzung verbinden" #: src/ui.c:172 msgid "connect host" msgstr "Host verbinden" #: src/ui.c:173 msgid "file transfer" msgstr "Dateiübertragung" #: src/ui.c:174 msgid "toggle dumps" msgstr "Ausgabe an/aus" #: src/ui.c:175 msgid "refresh host" msgstr "Host aktualisieren" #: src/ui.c:176 msgid "failure diagnostic" msgstr "Fehler Diagnose" #: src/ui.c:177 msgid "install pkg" msgstr "Paket installieren" #: src/ui.c:178 msgid "upgrade host(s)" msgstr "Host(s) upgraden" #: src/ui.c:179 msgid "host details" msgstr "Host Details" #: src/ui.c:181 msgid "host history" msgstr "Host Historie" #: src/ui.c:182 msgid "play" msgstr "wiedergeben" #: src/ui.c:183 msgid "display with less" msgstr "mit less anzeigen" #: src/ui.c:185 msgid "next detached session" msgstr "nächste ungenutzt Sitzung" #: src/ui.c:186 msgid "cycle detached sessions" msgstr "ungenutzt Sitzungen durchgehen" #: src/ui.c:187 msgid "tag current host" msgstr "Host markieren" #: src/ui.c:188 msgid "tag all hosts matching" msgstr "Hosts suchen und markieren" #: src/ui.c:189 msgid " ~c tag by codename" msgstr " ~c markieren nach Codename" #: src/ui.c:190 msgid " ~d tag by distribution" msgstr " ~d markieren nach Distribution" #: src/ui.c:191 msgid " ~f tag by host flags" msgstr " ~f markieren nach Host Flags" #: src/ui.c:192 msgid " ~g tag by group" msgstr " ~g markieren nach Gruppe" #: src/ui.c:193 msgid " ~p tag by packages" msgstr " ~p markieren nach Paketen" #: src/ui.c:194 msgid " ~u tag by updates" msgstr " ~u markieren nach Updates" #: src/ui.c:195 msgid " ~A tag all hosts" msgstr " ~A alle Hosts markieren" #: src/ui.c:196 msgid "untag all hosts matching" msgstr "Hosts suchen und demarkieren" #: src/ui.c:197 msgid "apply next function to tagged hosts" msgstr "folgende Funktion auf markierte Hosts anwenden" #: src/ui.c:202 msgid "some packages are kept back" msgstr "Pakete wurden zurückgehalten" #: src/ui.c:203 msgid "extra packages are installed" msgstr "extra Pakete installiert" #: src/ui.c:204 msgid "running kernel is not the latest (reboot required)" msgstr "aktueller Kernel läuft nicht (neustart nötig)" #: src/ui.c:205 msgid "a selfbuild kernel is running" msgstr "läuft selbstgebauter Kernel" #: src/ui.c:206 msgid "this is a virtualized machine" msgstr "Host ist virtualisiert" #: src/ui.c:580 msgid "FLAG" msgstr "FLAG" #: src/ui.c:581 src/ui.c:594 msgid "DESCRIPTION" msgstr "BESCHREIBUNG" #: src/ui.c:593 msgid "KEY" msgstr "TASTE" #: src/ui.c:642 msgid "HOST DETAILS" msgstr "HOST DETAILS" #: src/ui.c:645 msgid "Group:" msgstr "Gruppe:" #: src/ui.c:647 msgid "Hostname:" msgstr "Hostname:" #: src/ui.c:650 msgid "Machine Type:" msgstr "Rechner Typ:" #: src/ui.c:654 msgid "Architecture:" msgstr "Architektur:" #: src/ui.c:658 msgid "UUID:" msgstr "UUID:" #: src/ui.c:662 msgid "Forbidden:" msgstr "Untersagt:" #: src/ui.c:666 msgid "refresh" msgstr "Host(s) aktuallisieren" #: src/ui.c:673 msgid "upgrade" msgstr "Host(s) upgraden" #: src/ui.c:680 msgid "install" msgstr "Paket installieren" #: src/ui.c:688 msgid "Distri:" msgstr "Distri:" #: src/ui.c:694 msgid "Release:" msgstr "Release:" #: src/ui.c:698 msgid "Kernel name:" msgstr "Kernel-Name:" #: src/ui.c:702 msgid "Kernel version:" msgstr "Kernel-Version:" #: src/ui.c:707 msgid "(reboot required)" msgstr "(neustart nötig)" #: src/ui.c:710 msgid "(selfbuild kernel)" msgstr "(eigener Kernel)" #: src/ui.c:724 msgid "Packages: " msgstr "Pakete: " #: src/ui.c:735 msgid "BROKEN PACKAGES" msgstr "DEFEKTE PAKETE" #: src/ui.c:756 msgid "UPDATE PACKAGES" msgstr "UPDATE PAKETE" #: src/ui.c:777 msgid "HOLD BACK PACKAGES" msgstr "ZURÜCKGEHALTENE PAKETE" #: src/ui.c:797 msgid "EXTRA PACKAGES" msgstr "EXTRA PAKETE" #: src/ui.c:817 msgid "INSTALLED PACKAGES" msgstr "INSTALLIERTE PAKETE" #: src/ui.c:878 msgid "FAILURE DIAGNOSTIC" msgstr "FEHLER DIAGNOSE" #: src/ui.c:918 msgid " [Oldest: %D %H:%M]" msgstr " [Ältester: %D %H:%M]" #: src/ui.c:1004 msgid "c" msgstr "a" #: src/ui.c:1004 msgid "C" msgstr "A" #: src/ui.c:1007 msgid "y" msgstr "j" #: src/ui.c:1007 msgid "Y" msgstr "J" #: src/ui.c:1082 msgid "No history data available!" msgstr "Keine Historiendaten verfügbar!" #: src/ui.c:1088 #, c-format msgid "History of %s (%d entry available)" msgstr "Historie von %s (%d Eintrag verfügbar)" #: src/ui.c:1089 #, c-format msgid "History of %s (%d entries available)" msgstr "Historie von %s (%d Einträge verfügbar)" #: src/ui.c:1171 msgid "replay terminated, press any key to continue" msgstr "Wiedergabe beendet, bel. Taste drücken um fortzufahren" #: src/ui.c:1230 src/ui.c:1261 #, c-format msgid "%d Hosts in status \"%s\"" msgstr "%d Hosts mit Status \"%s\"" #: src/ui.c:1233 src/ui.c:1264 #, c-format msgid "%d Host in status \"%s\"" msgstr "%d Host in Status \"%s\"" #: src/ui.c:1361 #, c-format msgid "%d Updates required" msgstr "%d Updates benötigt" #: src/ui.c:1364 #, c-format msgid "%d Update required" msgstr "%d Update benötigt" #: src/ui.c:1369 #, c-format msgid "No update required" msgstr "Kein Update nötig" #: src/ui.c:1374 #, c-format msgid "%d Broken packages" msgstr "%d defekte Pakete" #: src/ui.c:1377 #, c-format msgid "%d Broken package" msgstr "%d defektes Paket" #: src/ui.c:1390 #, c-format msgid "%d sessions running" msgstr "%d Sitzungen aktiv" #: src/ui.c:1393 #, c-format msgid "%d session running" msgstr "%d Sitzung aktiv" #: src/ui.c:1399 #, c-format msgid "Status is unknown" msgstr "Status ist unbekannt" #: src/ui.c:1402 #, c-format msgid "Error: %s" msgstr "Fehler: %s" #: src/ui.c:1408 msgid " - host locked by another process" msgstr " - Host durch anderen Prozess gesperrt" #: src/ui.c:1464 #, c-format msgid "Running session %s [%5d]:" msgstr "Laufende Sitzung %s [%d]:" #: src/ui.c:1490 src/ui.c:1563 msgid "%D %H:%M " msgstr "%D %H:%M " #: src/ui.c:1493 src/ui.c:1566 msgid "Attached" msgstr "verbunden" #: src/ui.c:1493 src/ui.c:1566 msgid "Detached" msgstr "nicht verbunden" #: src/ui.c:1505 msgid "Could not read session dump." msgstr "Kann Sitzungsausgabe nicht lesen." #: src/ui.c:1508 msgid "attached" msgstr "verbunden" #: src/ui.c:1508 msgid "detached" msgstr "nicht verbunden" #: src/ui.c:1837 msgid "Maintainer name:" msgstr "Betreuer-Name:" #: src/ui.c:2458 msgid "Search: " msgstr "Suche: " #: src/ui.c:2631 msgid "Matches:" msgstr "Treffer:" #: src/ui.c:2648 msgid "Matches: -" msgstr "Treffer: -" #: src/ui.c:2713 msgid "Internal error: unhandled TCL TCLM_STRING mapping!" msgstr "Interner Fehler: unbekannte TCL TCLM_STRING Zuordnung!" #: src/ui.c:2728 msgid "Internal error: unhandled TCL TCLM_INT mapping!" msgstr "Interner Fehler: unbekannte TCL TCLM_INT Zuordnung!" #: src/ui.c:2738 msgid "Internal error: unknown TCL mapping type!" msgstr "Interner Fehler: unbekannter TCL Zuordnungstyp!" #: src/ui.c:2797 msgid "Scalars:" msgstr "Skalare:" #: src/ui.c:2819 msgid "Arrays:" msgstr "Felder:" #: src/ui.c:2840 msgid "Examples:" msgstr "Beispiele:" #: src/ui.c:2853 msgid "Enter filter expression:" msgstr "Filterausdruck:" #: src/ui.c:2887 #, c-format msgid "An error at %s:%d has been detected [Less/ignore/connect]: " msgstr "Ein Fehler bei %s:%d wurde gefunden [Less/ignore/connect]: " #: src/ui.c:2889 #, c-format msgid "An error at %s has been detected [Less/ignore/connect]: " msgstr "Ein Fehler bei %s wurde gefunden [Less/ignore/connect]: " # c-format #: src/ui.c:3066 #, c-format msgid "Refresh %d tagged hosts? [y/N]: " msgstr "Update von %d markierten Hosts? [j/N]: " #: src/ui.c:3101 msgid "tag-" msgstr "tag-" #: src/ui.c:3115 src/ui.c:3141 src/ui.c:3269 msgid "There are running sessions on this host! Continue? [y/N]: " msgstr "Host hat aktive Sitzungen! Weiter? [j/N]: " #: src/ui.c:3164 msgid "Run update for the whole category? [y/N]: " msgstr "Die ganze Kategorie updaten? [j/N]: " #: src/ui.c:3165 msgid "Run update for the whole group? [y/N]: " msgstr "Die ganze Gruppe updaten? [j/N]: " #: src/ui.c:3209 #, c-format msgid "Run update for %d tagged and updatable hosts? [y/N]: " msgstr "Update von %d markierten Hosts? [j/N]: " #: src/ui.c:3239 #, c-format msgid "Install package `%s' [y/N]: " msgstr "Paket '%s' installieren [j/N]: " #: src/ui.c:3245 src/ui.c:3274 src/ui.c:3290 msgid "Install package: " msgstr "Paket installieren: " #: src/ui.c:3294 msgid "Run install for the whole category? [y/N]: " msgstr "Installation für die ganze Kategorie durchführen? [j/N]: " #: src/ui.c:3295 msgid "Run install for the whole group? [y/N]: " msgstr "Installation für die ganze Gruppe durchführen? [j/N]: " #: src/ui.c:3340 #, c-format msgid "Install package on %d tagged hosts: " msgstr "Paket auf %d markierte Hosts installieren: " #: src/ui.c:3368 msgid "Tag hosts matching: " msgstr "Markiere Hosts mit: " #: src/ui.c:3369 msgid "Untag hosts matching: " msgstr "Demarkiere Hosts mit: " #: src/ui.c:3444 #, c-format msgid "Attach host %s session %d (%d %s left) [Y/n/c]: " msgstr "Verbinde mit Host %s Sitzung %d (%d %s übrig) [J/n/a]: " #: src/ui.c:3446 msgid "session" msgstr "Sitzungen" #: src/ui.c:3446 msgid "sessions" msgstr "Sitzungen" #: src/ui.c:3518 msgid "Already attached - share session? [y/N]: " msgstr "Bereits verbunden - geteilte Sitzung? [j/N]: " #: src/ui.c:3546 msgid "Session dumps enabled." msgstr "Sitzungsausgabe aktiviert." #: src/ui.c:3548 msgid "Session dumps disabled." msgstr "Sitzungsausgabe deaktiviert." #: src/ui.c:3646 #, c-format msgid "There are %d hosts in status refresh state, quit apt-dater? [y/N]: " msgstr "Es werden %d Hosts aktuallisiert, apt-dater beenden? [j/N]: " #: src/ui.c:3649 #, c-format msgid "There is %d host in status refresh state, quit apt-dater? [y/N]: " msgstr "Es wird %d Host aktuallisiert, apt-dater beenden? [j/N]: " apt-dater-0.9.0/po/en@boldquot.header0000644000175000017500000000247111760757134017034 0ustar thomasthomas# All this catalog "translates" are quotation characters. # The msgids must be ASCII and therefore cannot contain real quotation # characters, only substitutes like grave accent (0x60), apostrophe (0x27) # and double quote (0x22). These substitutes look strange; see # http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html # # This catalog translates grave accent (0x60) and apostrophe (0x27) to # left single quotation mark (U+2018) and right single quotation mark (U+2019). # It also translates pairs of apostrophe (0x27) to # left single quotation mark (U+2018) and right single quotation mark (U+2019) # and pairs of quotation mark (0x22) to # left double quotation mark (U+201C) and right double quotation mark (U+201D). # # When output to an UTF-8 terminal, the quotation characters appear perfectly. # When output to an ISO-8859-1 terminal, the single quotation marks are # transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to # grave/acute accent (by libiconv), and the double quotation marks are # transliterated to 0x22. # When output to an ASCII terminal, the single quotation marks are # transliterated to apostrophes, and the double quotation marks are # transliterated to 0x22. # # This catalog furthermore displays the text between the quotation marks in # bold face, assuming the VT100/XTerm escape sequences. # apt-dater-0.9.0/po/en@quot.header0000644000175000017500000000226311760757134016172 0ustar thomasthomas# All this catalog "translates" are quotation characters. # The msgids must be ASCII and therefore cannot contain real quotation # characters, only substitutes like grave accent (0x60), apostrophe (0x27) # and double quote (0x22). These substitutes look strange; see # http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html # # This catalog translates grave accent (0x60) and apostrophe (0x27) to # left single quotation mark (U+2018) and right single quotation mark (U+2019). # It also translates pairs of apostrophe (0x27) to # left single quotation mark (U+2018) and right single quotation mark (U+2019) # and pairs of quotation mark (0x22) to # left double quotation mark (U+201C) and right double quotation mark (U+201D). # # When output to an UTF-8 terminal, the quotation characters appear perfectly. # When output to an ISO-8859-1 terminal, the single quotation marks are # transliterated to apostrophes (by iconv in glibc 2.2 or newer) or to # grave/acute accent (by libiconv), and the double quotation marks are # transliterated to 0x22. # When output to an ASCII terminal, the single quotation marks are # transliterated to apostrophes, and the double quotation marks are # transliterated to 0x22. # apt-dater-0.9.0/po/insert-header.sin0000644000175000017500000000124011760757134016644 0ustar thomasthomas# Sed script that inserts the file called HEADER before the header entry. # # At each occurrence of a line starting with "msgid ", we execute the following # commands. At the first occurrence, insert the file. At the following # occurrences, do nothing. The distinction between the first and the following # occurrences is achieved by looking at the hold space. /^msgid /{ x # Test if the hold space is empty. s/m/m/ ta # Yes it was empty. First occurrence. Read the file. r HEADER # Output the file's contents by reading the next line. But don't lose the # current line while doing this. g N bb :a # The hold space was nonempty. Following occurrences. Do nothing. x :b } apt-dater-0.9.0/po/it.po0000644000175000017500000003513411760757134014364 0ustar thomasthomas# Italian translations for apt-dater package # Copyright (C) 2009 THE apt-dater'S COPYRIGHT HOLDER # This file is distributed under the same license as the apt-dater package. # Milo Casagrande , 2009. # msgid "" msgstr "" "Project-Id-Version: apt-dater 0.8.0\n" "Report-Msgid-Bugs-To: apt-dater@ibh.de\n" "POT-Creation-Date: 2011-11-15 21:53+0100\n" "PO-Revision-Date: 2009-11-11 22:34+0100\n" "Last-Translator: Milo Casagrande \n" "Language-Team: Italian \n" "Language: it\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #: src/apt-dater.c:82 src/apt-dater.c:85 src/apt-dater.c:124 #: src/keyfiles.c:107 src/keyfiles.c:118 src/ui.c:3449 msgid "Out of memory." msgstr "Memoria esaurita." #: src/apt-dater.c:91 #, c-format msgid "Failed to create initial configuration file %s." msgstr "Creazione del file di configurazione iniziale %s non riuscita." #: src/apt-dater.c:107 msgid "Sorry, apt-dater was compiled w/o report feature!" msgstr "apt-dater è stato compilato senza la funzionalità di rapporto." #: src/apt-dater.c:117 #, fuzzy, c-format msgid "Usage: %s [-(c config|v|[n]r)]\n" msgstr "Uso: %s [-(c config|v|r)]\n" #: src/apt-dater.c:119 #, fuzzy, c-format msgid "Usage: %s [-(c config|v)]\n" msgstr "Uso: %s [-(c config|v|r)]\n" #: src/apt-dater.c:127 src/apt-dater.c:132 #, c-format msgid "Error on loading config file %s\n" msgstr "Errore nel caricare il file di configurazione %s\n" #: src/apt-dater.c:184 msgid "Cannot open your terminal /proc/self/fd/0 - please check." msgstr "Impossibile aprire il terminale /proc/self/fd/0 - controllare." #: src/colors.c:153 msgid "Wrong color definition!" msgstr "Definizione colore errata." #: src/keyfiles.c:109 src/keyfiles.c:120 src/keyfiles.c:131 #, c-format msgid "Creating file %s" msgstr "Creazione del file %s" #: src/keyfiles.c:111 src/keyfiles.c:122 src/keyfiles.c:132 #, c-format msgid "Could not write to file %s." msgstr "" #: src/lock.c:56 msgid "Can't get the name of the lock file!" msgstr "Impossibile ottenere il nome del file di blocco." #: src/lock.c:77 #, c-format msgid "Failed to get lockfile %s: %s" msgstr "Impossibile ottenere il file di blocco %s: %s" #: src/lock.c:81 #, c-format msgid "Can't lock to file %s because function flock() is missing!" msgstr "Impossibile bloccare il file %s perché manca la funzione flock()." #: src/report.c:58 msgid "Error creating the xml output." msgstr "Errore nel creare l'ouput XML." #: src/report.c:63 #, c-format msgid "apt-dater is refreshing %d hosts, please standby...\n" msgstr "apt-dater sta aggiornando %d host, attendere...\n" #: src/stats.c:495 msgid "Auto refresh triggered..." msgstr "Aggiornamento automatico avviato..." #: src/ui.c:55 msgid "Updates pending" msgstr "Aggiornamenti in attesa" #: src/ui.c:56 msgid "Up to date" msgstr "Aggiornato" #: src/ui.c:57 msgid "Broken packages" msgstr "Pacchetti danneggiati" #: src/ui.c:58 src/ui.c:1382 #, c-format msgid "Refresh required" msgstr "Aggiornamento richiesto" #: src/ui.c:59 src/ui.c:1385 #, c-format msgid "In refresh" msgstr "Aggiornamento in corso" #: src/ui.c:60 msgid "Sessions" msgstr "Sessioni" #: src/ui.c:62 msgid "Filtered" msgstr "Filtrato" #: src/ui.c:64 msgid "Unknown" msgstr "Sconosciuto" #: src/ui.c:149 msgid "" msgstr "" #: src/ui.c:149 src/ui.c:150 msgid "shrink node" msgstr "riduce il nodo" #: src/ui.c:151 msgid "" msgstr "" #: src/ui.c:151 src/ui.c:152 msgid "expand node" msgstr "espande il nodo" #: src/ui.c:153 msgid "" msgstr "" #: src/ui.c:153 src/ui.c:154 src/ui.c:155 src/ui.c:164 msgid "shrink/expand node" msgstr "riduce/espande il nodo" #: src/ui.c:154 msgid "" msgstr "" #: src/ui.c:155 msgid "" msgstr "" #: src/ui.c:156 msgid "" msgstr "" #: src/ui.c:156 src/ui.c:157 msgid "move up" msgstr "muove in su" #: src/ui.c:158 msgid "" msgstr "" #: src/ui.c:158 src/ui.c:159 msgid "move down" msgstr "muove in giù" #: src/ui.c:160 msgid "" msgstr "" #: src/ui.c:160 msgid "move to the top" msgstr "muove in alto" #: src/ui.c:161 msgid "" msgstr "" #: src/ui.c:161 msgid "move to the end" msgstr "muove in basso" #: src/ui.c:162 msgid "" msgstr "" #: src/ui.c:162 msgid "previous page" msgstr "pagina precedente" #: src/ui.c:163 msgid "" msgstr "" #: src/ui.c:163 msgid "next page" msgstr "pagina successiva" #: src/ui.c:165 msgid "quit" msgstr "chiude" #: src/ui.c:166 msgid "help" msgstr "aiuto" #: src/ui.c:167 msgid "search host" msgstr "cerca host" #: src/ui.c:169 msgid "filter hosts" msgstr "filtra gli host" #: src/ui.c:171 msgid "attach session" msgstr "collega sessione" #: src/ui.c:172 msgid "connect host" msgstr "connetti host" #: src/ui.c:173 msgid "file transfer" msgstr "trasferimento file" #: src/ui.c:174 msgid "toggle dumps" msgstr "commuta i dump" #: src/ui.c:175 msgid "refresh host" msgstr "aggiorna host" #: src/ui.c:176 msgid "failure diagnostic" msgstr "" #: src/ui.c:177 msgid "install pkg" msgstr "installa pkg" #: src/ui.c:178 msgid "upgrade host(s)" msgstr "aggiorna host" #: src/ui.c:179 msgid "host details" msgstr "dettagli host" #: src/ui.c:181 msgid "host history" msgstr "cronologia host" #: src/ui.c:182 msgid "play" msgstr "riproduce" #: src/ui.c:183 msgid "display with less" msgstr "visualizza con less" #: src/ui.c:185 msgid "next detached session" msgstr "sessione scollegata successiva" #: src/ui.c:186 msgid "cycle detached sessions" msgstr "cicla tra le sessione scollegate" #: src/ui.c:187 msgid "tag current host" msgstr "etichetta l'host attuale" #: src/ui.c:188 msgid "tag all hosts matching" msgstr "etichetta tutti gli host corrispondenti" #: src/ui.c:189 msgid " ~c tag by codename" msgstr "" #: src/ui.c:190 msgid " ~d tag by distribution" msgstr "" #: src/ui.c:191 msgid " ~f tag by host flags" msgstr "" #: src/ui.c:192 msgid " ~g tag by group" msgstr "" #: src/ui.c:193 msgid " ~p tag by packages" msgstr "" #: src/ui.c:194 msgid " ~u tag by updates" msgstr "" #: src/ui.c:195 #, fuzzy msgid " ~A tag all hosts" msgstr "etichetta tutti gli host corrispondenti" #: src/ui.c:196 msgid "untag all hosts matching" msgstr "toglie l'etichetta da tutti gli host corrispondenti" #: src/ui.c:197 msgid "apply next function to tagged hosts" msgstr "applica la funzione successiva agli host etichettati" #: src/ui.c:202 msgid "some packages are kept back" msgstr "alcuni pacchetti sono bloccati" #: src/ui.c:203 msgid "extra packages are installed" msgstr "pacchetti aggiuntivi sono installati" #: src/ui.c:204 msgid "running kernel is not the latest (reboot required)" msgstr "il kernel in esecuzione non è il più rencente (riavvio richiesto)" #: src/ui.c:205 msgid "a selfbuild kernel is running" msgstr "è in esecuzione un kernel generato manualmente" #: src/ui.c:206 msgid "this is a virtualized machine" msgstr "questa è una macchina virtualizzata" #: src/ui.c:580 msgid "FLAG" msgstr "FLAG" #: src/ui.c:581 src/ui.c:594 msgid "DESCRIPTION" msgstr "DESCRIZIONE" #: src/ui.c:593 msgid "KEY" msgstr "CHIAVE" #: src/ui.c:642 msgid "HOST DETAILS" msgstr "DETTAGLI HOST" #: src/ui.c:645 msgid "Group:" msgstr "Gruppo:" #: src/ui.c:647 msgid "Hostname:" msgstr "Nome host:" #: src/ui.c:650 msgid "Machine Type:" msgstr "Tipo computer:" #: src/ui.c:654 msgid "Architecture:" msgstr "Architettura:" #: src/ui.c:658 msgid "UUID:" msgstr "UUID:" #: src/ui.c:662 msgid "Forbidden:" msgstr "Proibito:" #: src/ui.c:666 #, fuzzy msgid "refresh" msgstr "Aggiornamento in corso" #: src/ui.c:673 #, fuzzy msgid "upgrade" msgstr "aggiorna host" #: src/ui.c:680 #, fuzzy msgid "install" msgstr "installa pkg" #: src/ui.c:688 msgid "Distri:" msgstr "Distri:" #: src/ui.c:694 msgid "Release:" msgstr "Rilascio:" #: src/ui.c:698 msgid "Kernel name:" msgstr "Nome kernel:" #: src/ui.c:702 msgid "Kernel version:" msgstr "Versione kernel:" #: src/ui.c:707 msgid "(reboot required)" msgstr "(riavvio richiesto)" #: src/ui.c:710 msgid "(selfbuild kernel)" msgstr "(kernel generato manualmente)" #: src/ui.c:724 msgid "Packages: " msgstr "Pacchetti:" #: src/ui.c:735 msgid "BROKEN PACKAGES" msgstr "PACCHETTI DANNEGGIATI" #: src/ui.c:756 msgid "UPDATE PACKAGES" msgstr "PACCHETTI AGGIORNATI" #: src/ui.c:777 msgid "HOLD BACK PACKAGES" msgstr "PACCHETTI BLOCCATI" #: src/ui.c:797 msgid "EXTRA PACKAGES" msgstr "PACCHETTI EXTRA" #: src/ui.c:817 msgid "INSTALLED PACKAGES" msgstr "PACCHETTI INSTALLATI" #: src/ui.c:878 msgid "FAILURE DIAGNOSTIC" msgstr "" #: src/ui.c:918 #, fuzzy msgid " [Oldest: %D %H:%M]" msgstr " [Più vecchio: %D %H.%M]" #: src/ui.c:1004 msgid "c" msgstr "c" #: src/ui.c:1004 msgid "C" msgstr "C" #: src/ui.c:1007 msgid "y" msgstr "y" #: src/ui.c:1007 msgid "Y" msgstr "Y" #: src/ui.c:1082 msgid "No history data available!" msgstr "Nessun dato di cronologia." #: src/ui.c:1088 #, c-format msgid "History of %s (%d entry available)" msgstr "Cronologia di %s (%d voce disponibile)" #: src/ui.c:1089 #, c-format msgid "History of %s (%d entries available)" msgstr "Cronologia di %s (%d voci disponibili)" #: src/ui.c:1171 msgid "replay terminated, press any key to continue" msgstr "riproduzione terminata, premere un tasto per continuare" #: src/ui.c:1230 src/ui.c:1261 #, c-format msgid "%d Hosts in status \"%s\"" msgstr "%d host nello stato \"%s\"" #: src/ui.c:1233 src/ui.c:1264 #, c-format msgid "%d Host in status \"%s\"" msgstr "%d host nello stato \"%s\"" #: src/ui.c:1361 #, c-format msgid "%d Updates required" msgstr "%d aggiornamenti richiesti" #: src/ui.c:1364 #, c-format msgid "%d Update required" msgstr "%d aggiornamento richiesto" #: src/ui.c:1369 #, c-format msgid "No update required" msgstr "Aggiornamento non richiesto" #: src/ui.c:1374 #, c-format msgid "%d Broken packages" msgstr "%d pacchetti danneggiati" #: src/ui.c:1377 #, c-format msgid "%d Broken package" msgstr "%d pacchetto danneggiato" #: src/ui.c:1390 #, c-format msgid "%d sessions running" msgstr "%d sessioni in esecuzione" #: src/ui.c:1393 #, c-format msgid "%d session running" msgstr "%d sessione in esecuzione" #: src/ui.c:1399 #, c-format msgid "Status is unknown" msgstr "Lo stato è sconosciuto" #: src/ui.c:1402 #, c-format msgid "Error: %s" msgstr "" #: src/ui.c:1408 msgid " - host locked by another process" msgstr " - host bloccato da un altro processo" #: src/ui.c:1464 #, fuzzy, c-format msgid "Running session %s [%5d]:" msgstr "Esecuzione sessione %s [%5d]:" #: src/ui.c:1490 src/ui.c:1563 msgid "%D %H:%M " msgstr "%D %H.%M " #: src/ui.c:1493 src/ui.c:1566 msgid "Attached" msgstr "Collegato" #: src/ui.c:1493 src/ui.c:1566 msgid "Detached" msgstr "Scollegato" #: src/ui.c:1505 msgid "Could not read session dump." msgstr "Impossibile leggere il dump della sessione." #: src/ui.c:1508 #, fuzzy msgid "attached" msgstr "Collegato" #: src/ui.c:1508 #, fuzzy msgid "detached" msgstr "Scollegato" #: src/ui.c:1837 msgid "Maintainer name:" msgstr "Nome maintainer:" #: src/ui.c:2458 msgid "Search: " msgstr "Cerca:" #: src/ui.c:2631 msgid "Matches:" msgstr "Corrispondenze:" #: src/ui.c:2648 msgid "Matches: -" msgstr "Corrispondenze:-" #: src/ui.c:2713 #, fuzzy msgid "Internal error: unhandled TCL TCLM_STRING mapping!" msgstr "Errore interno: mappatura TCL TCLM_STRING non gestita." #: src/ui.c:2728 #, fuzzy msgid "Internal error: unhandled TCL TCLM_INT mapping!" msgstr "Errore interno: mappatura TCL TCLM_INT." #: src/ui.c:2738 #, fuzzy msgid "Internal error: unknown TCL mapping type!" msgstr "Errore interno: tipologia di mappatura TCL sconosciuta." #: src/ui.c:2797 msgid "Scalars:" msgstr "Scalari:" #: src/ui.c:2819 msgid "Arrays:" msgstr "Array:" #: src/ui.c:2840 msgid "Examples:" msgstr "Esempi:" #: src/ui.c:2853 msgid "Enter filter expression:" msgstr "Inserire espressione di filtro:" #: src/ui.c:2887 #, fuzzy, c-format msgid "An error at %s:%d has been detected [Less/ignore/connect]: " msgstr "È stato rilevato un errore presso %s:%d [Lic]: " #: src/ui.c:2889 #, fuzzy, c-format msgid "An error at %s has been detected [Less/ignore/connect]: " msgstr "È stato rilevato un errore presso %s [Lic]: " #: src/ui.c:3066 #, c-format msgid "Refresh %d tagged hosts? [y/N]: " msgstr "Aggiornare %d host etichettati? [y/N]: " #: src/ui.c:3101 msgid "tag-" msgstr "tag-" #: src/ui.c:3115 src/ui.c:3141 src/ui.c:3269 msgid "There are running sessions on this host! Continue? [y/N]: " msgstr "" "Su questo host sono presenti sessioni in esecuzione. Continuare? [y/N]:" #: src/ui.c:3164 msgid "Run update for the whole category? [y/N]: " msgstr "Eseguire l'aggiornamento per l'intera categoria? [y/N]:" #: src/ui.c:3165 msgid "Run update for the whole group? [y/N]: " msgstr "Eseguire l'aggiornamento per l'intero gruppo? [y/N]:" #: src/ui.c:3209 #, c-format msgid "Run update for %d tagged and updatable hosts? [y/N]: " msgstr "" "Eseguire l'aggiornamento per gli host etichettati e aggiornabili (%d)? [y/N]:" #: src/ui.c:3239 #, c-format msgid "Install package `%s' [y/N]: " msgstr "Installare il pacchetto \"%s\" [y/N]:" #: src/ui.c:3245 src/ui.c:3274 src/ui.c:3290 msgid "Install package: " msgstr "Installare il pacchetto:" #: src/ui.c:3294 msgid "Run install for the whole category? [y/N]: " msgstr "Eseguire l'installazione per l'intera categoria? [y/N]:" #: src/ui.c:3295 msgid "Run install for the whole group? [y/N]: " msgstr "Eseguire l'installazione per l'intero gruppo? [y/N]:" #: src/ui.c:3340 #, fuzzy, c-format msgid "Install package on %d tagged hosts: " msgstr "Installare il pacchetto su %d host etichettati:" #: src/ui.c:3368 msgid "Tag hosts matching: " msgstr "Etichettare host corrispondenti:" #: src/ui.c:3369 msgid "Untag hosts matching: " msgstr "Togliere etichetta a host corrispondenti:" #: src/ui.c:3444 #, fuzzy, c-format msgid "Attach host %s session %d (%d %s left) [Y/n/c]: " msgstr "Collegare host %s sessione %d (%d %s mancanti) [Y/n/c]:" #: src/ui.c:3446 msgid "session" msgstr "sessione" #: src/ui.c:3446 msgid "sessions" msgstr "sessioni" #: src/ui.c:3518 msgid "Already attached - share session? [y/N]: " msgstr "Già collegato, condividere la sessione? [y/N]:" #: src/ui.c:3546 msgid "Session dumps enabled." msgstr "Dump della sessione abilitati." #: src/ui.c:3548 msgid "Session dumps disabled." msgstr "Dump della sessione disabilitati." #: src/ui.c:3646 #, c-format msgid "There are %d hosts in status refresh state, quit apt-dater? [y/N]: " msgstr "" #: src/ui.c:3649 #, c-format msgid "There is %d host in status refresh state, quit apt-dater? [y/N]: " msgstr "" #, fuzzy #~ msgid "install pkg on tagged host(s)" #~ msgstr "Installare il pacchetto su %d host etichettati:" #, fuzzy #~ msgid "upgrade tagged host(s)" #~ msgstr "aggiorna host" apt-dater-0.9.0/po/quot.sed0000644000175000017500000000023111760757134015063 0ustar thomasthomass/"\([^"]*\)"/“\1”/g s/`\([^`']*\)'/‘\1’/g s/ '\([^`']*\)' / ‘\1’ /g s/ '\([^`']*\)'$/ ‘\1’/g s/^'\([^`']*\)' /‘\1’ /g s/“”/""/g apt-dater-0.9.0/po/remove-potcdate.sin0000644000175000017500000000066011760757134017215 0ustar thomasthomas# Sed script that remove the POT-Creation-Date line in the header entry # from a POT file. # # The distinction between the first and the following occurrences of the # pattern is achieved by looking at the hold space. /^"POT-Creation-Date: .*"$/{ x # Test if the hold space is empty. s/P/P/ ta # Yes it was empty. First occurrence. Remove the line. g d bb :a # The hold space was nonempty. Following occurrences. Do nothing. x :b } apt-dater-0.9.0/src/0000755000175000017500000000000011761142205013537 5ustar thomasthomasapt-dater-0.9.0/src/Makefile.am0000644000175000017500000000140211760757134015604 0ustar thomasthomasbin_PROGRAMS = apt-dater apt_dater_SOURCES = \ adproto.h \ apt-dater.c \ apt-dater.h \ colors.c \ colors.h \ exec.c \ exec.h \ extern.h \ keyfiles.c \ keyfiles.h \ lock.c \ lock.h \ parsecmd.c \ parsecmd.h \ report.c \ report.h \ screen.c \ screen.h \ sighandler.c \ sighandler.h \ stats.c \ stats.h \ ui.c \ ui.h \ autoref.c \ autoref.h \ tag.c \ tag.h \ history.c \ history.h \ env.c \ env.h \ clusters.c \ clusters.h apt_dater_LDADD = $(GLIB_LIBS) $(TCL_LIBS) $(LIBXML2_LIBS) AM_CFLAGS = -Wall -DPKGLIBDIR='"'$(pkglibdir)'"' if LINUX AM_LDFLAGS = -Wl,--as-needed else AM_LDFLAGS = -Wl endif INCLUDES = $(GLIB_CFLAGS) $(TCL_CFLAGS) $(LIBXML2_CFLAGS) apt-dater-0.9.0/src/apt-dater.c0000644000175000017500000001270111760757134015601 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifdef HAVE_CONFIG_H # include "config.h" #endif #include #include #include #ifdef HAVE_LOCALE_H #include #endif #include "apt-dater.h" #include "keyfiles.h" #include "ui.h" #include "stats.h" #include "sighandler.h" #include "lock.h" #include "env.h" #ifdef FEAT_XMLREPORT #include "report.h" #endif #define VERSTEXT PACKAGE_STRING " - " __DATE__ " " __TIME__ "\n\n" \ "Copyright Holder: IBH IT-Service GmbH [http://www.ibh.net/]\n\n" \ "This program is free software; you can redistribute it and/or modify\n" \ "it under the terms of the GNU General Public License as published by\n" \ "the Free Software Foundation; either version 2 of the License, or\n" \ "(at your option) any later version.\n\n" \ "Send bug reports to " PACKAGE_BUGREPORT ".\n\n" CfgFile *cfg = NULL; GMainLoop *loop = NULL; gboolean rebuilddl = FALSE; time_t oldest_st_mtime; int main(int argc, char **argv, char **envp) { int opts; gchar *cfgfilename = NULL; gchar *cfgdirname = NULL; GList *hosts = NULL; #ifdef FEAT_XMLREPORT gboolean report = FALSE; gboolean refresh = TRUE; #endif #ifdef HAVE_GETTEXT setlocale(LC_ALL, ""); textdomain(PACKAGE); #endif cfgdirname = g_strdup_printf("%s/%s", g_get_user_config_dir(), PACKAGE); if(!cfgdirname) g_error(_("Out of memory.")); cfgfilename = g_strdup_printf("%s/%s", cfgdirname, CFGFILENAME); if(!cfgfilename) g_error(_("Out of memory.")); g_set_prgname(PACKAGE); g_set_application_name(PACKAGE_STRING); if(chkForInitialConfig(cfgdirname, cfgfilename)) g_warning(_("Failed to create initial configuration file %s."), cfgfilename); while ((opts = getopt(argc, argv, "c:vrn")) != EOF) { switch(opts) { case 'c': if(cfgfilename) free(cfgfilename); cfgfilename = (char *) strdup(optarg); break; case 'v': g_print(VERSTEXT); exit(0); break; case 'r': #ifdef FEAT_XMLREPORT report = TRUE; #else g_error(_("Sorry, apt-dater was compiled w/o report feature!")); #endif break; #ifdef FEAT_XMLREPORT case 'n': refresh = FALSE; break; #endif default: #ifdef FEAT_XMLREPORT g_printerr(_("Usage: %s [-(c config|v|[n]r)]\n"), g_get_prgname()); #else g_printerr(_("Usage: %s [-(c config|v)]\n"), g_get_prgname()); #endif exit(EXIT_FAILURE); } } if(!cfgfilename) g_error(_("Out of memory.")); if(!(cfg = (CfgFile *) loadConfig(cfgfilename))) { g_error(_("Error on loading config file %s\n"), cfgfilename); exit(EXIT_FAILURE); } if(!(hosts = (GList *) loadHosts(cfg->hostsfile))) { g_printerr(_("Error on loading config file %s\n"), cfg->hostsfile); exit(EXIT_FAILURE); } if(cfg->ssh_agent #ifdef FEAT_XMLREPORT && (!report || refresh) #endif ) { /* Spawn ssh-agent if needed */ if(getenv("SSH_AGENT_PID") == NULL) { gint i; gchar **agent_argv = g_new0(gchar *, argc+2); agent_argv[0] = "ssh-agent"; for(i=0; issh_numadd+2); add_argv[0] = "ssh-add"; for(i=0; issh_numadd; i++) add_argv[i+1] = cfg->ssh_add[i]; GError *error; if(g_spawn_sync(NULL, add_argv, NULL, G_SPAWN_SEARCH_PATH | G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error) == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } g_free(add_argv); } } env_init(envp); #ifdef FEAT_XMLREPORT if(!report) { #endif #ifdef __linux__ /* Test if we are the owner of the TTY or die. */ if(g_access("/proc/self/fd/0", R_OK|W_OK)) { g_error(_("Cannot open your terminal /proc/self/fd/0 - please check.")); exit(EXIT_FAILURE); } #endif getOldestMtime(hosts); doUI(hosts); setSigHandler(); #ifdef FEAT_XMLREPORT } else { if(refresh) initReport(hosts); else initReport(NULL); } #endif loop = g_main_loop_new (NULL, FALSE); #ifdef HAVE_GLIB_TIMEOUT_ADD_SECONDS g_timeout_add_seconds(1, (GSourceFunc) refreshStats, hosts); #else g_timeout_add(1000, (GSourceFunc) refreshStats, hosts); #endif #ifdef FEAT_XMLREPORT if(report) g_idle_add ((GSourceFunc) ctrlReport, hosts); else #endif g_idle_add ((GSourceFunc) ctrlUI, hosts); /* Startup the main loop */ g_main_loop_run (loop); g_main_loop_unref (loop); cleanUI(); cleanupLocks(); freeConfig(cfg); g_free(cfgfilename); g_free(cfgdirname); exit(EXIT_SUCCESS); } apt-dater-0.9.0/src/apt-dater.h0000644000175000017500000001212111760757134015602 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _APT_DATER_H #define _APT_DATER_H #define _GNU_SOURCE #include #include #include #include #include #include #include #include #include #include #include "../config.h" #include "../include/adproto.h" #ifdef HAVE_GETTEXT #include #define _(x) gettext(x) #else #define _(x) x #endif #define N_(x) x #define STATS_MAX_LINE_LEN 1000 #define INPUT_MAX 4096 #define BUF_MAX_LEN 256 #define PROG_NAME PACKAGE #define CFGFILENAME "apt-dater.conf" #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifndef NDEBUG typedef enum { T_CFGFILE=1, T_DRAWNODE=2, T_SESSNODE=3, T_HOSTNODE=4, T_PKGNODE=5, T_MAPPING=6, T_VERSION=7, T_DISTRI=8, } etype; #define ASSERT_TYPE(p,t) \ if ((p)->_type != (t)) \ g_error("Unexpected type %d for " #p " in " __FILE__ ":%d" \ ", should be " #t "(%d)!\n", (p)->_type, __LINE__, (t)); #else #define ASSERT_TYPE(p,t) #endif typedef struct _cfgfile { #ifndef NDEBUG etype _type; #endif gchar *hostsfile; gchar *screenrcfile; gchar *screentitle; gchar *statsdir; gchar *plugindir; gchar *ssh_cmd; gchar *sftp_cmd; gchar *ssh_optflags; gboolean ssh_agent; gchar **ssh_add; gsize ssh_numadd; gchar *cmd_refresh; gchar *cmd_upgrade; gchar *cmd_install; gboolean dump_screen; gboolean query_maintainer; gboolean beep; gboolean flash; #ifdef FEAT_HISTORY gboolean record_history; gchar *history_errpattern; #endif gchar **colors; #ifdef FEAT_TCLFILTER gchar *filterexp; gchar *filterfile; #endif #ifdef FEAT_AUTOREF gboolean auto_refresh; #endif gchar *hook_pre_upgrade; gchar *hook_pre_refresh; gchar *hook_pre_install; gchar *hook_pre_connect; gchar *hook_post_upgrade; gchar *hook_post_refresh; gchar *hook_post_install; gchar *hook_post_connect; } CfgFile; typedef struct _update { #ifndef NDEBUG etype _type; #endif gchar *package; gchar *version; gint flag; gchar *data; } PkgNode; typedef struct _session { #ifndef NDEBUG etype _type; #endif gint pid; struct stat st; } SessNode; typedef enum { C_UPDATES_PENDING = 0, C_UP_TO_DATE = 1, C_BROKEN_PKGS = 2, C_REFRESH_REQUIRED = 3, C_REFRESH = 4, C_SESSIONS = 5, #ifdef FEAT_TCLFILTER C_FILTERED = 6, C_UNKNOWN = 7, #else C_UNKNOWN = 6, #endif } Category; #define HOST_STATUS_PKGUPDATE 1 #define HOST_STATUS_PKGKEPTBACK 2 #define HOST_STATUS_PKGEXTRA 4 #define HOST_STATUS_PKGBROKEN 8 #define HOST_STATUS_KERNELNOTMATCH 16 #define HOST_STATUS_KERNELSELFBUILD 32 #define HOST_STATUS_VIRTUALIZED 64 #define HOST_STATUS_LOCKED 128 #ifdef FEAT_CLUSTERS #define HOST_STATUS_CLUSTERED 256 #endif #define HOST_FORBID_REFRESH 1 #define HOST_FORBID_UPGRADE 2 #define HOST_FORBID_INSTALL 4 #define HOST_FORBID_MASK (HOST_FORBID_REFRESH | HOST_FORBID_UPGRADE | HOST_FORBID_INSTALL) #define _QUOTE(x) #x #define QUOTE(x) _QUOTE(x) #define UUID_STRLEN 36 typedef struct _hostnode { #ifndef NDEBUG etype _type; #endif gchar *hostname; gchar *group; gchar *type; gchar *ssh_user; gint ssh_port; #ifdef FEAT_AUTOREF time_t last_upd; #endif guint status; gboolean keptback; #ifdef FEAT_TCLFILTER gboolean filtered; #endif #ifdef FEAT_HISTORY gboolean parse_result; gint hist_ts; #endif Category category; GList *packages; gint nupdates; gint nholds; gint nextras; gint nbrokens; GList *screens; gint fdlock; FILE *fpstat; gchar *statsfile; gchar *lsb_distributor; gchar *lsb_release; gchar *lsb_codename; gchar *uname_kernel; gchar *uname_machine; gchar *kernelrel; gchar *virt; gchar *adperr; gchar *identity_file; gint forbid; gboolean tagged; gchar uuid[UUID_STRLEN+1]; #ifdef FEAT_CLUSTERS GList *clusters; #endif } HostNode; #define HOST_SSHPORT_SET(n) \ ((n)->ssh_port != 0) struct mapping_t { gchar *name; gint value; }; #include "extern.h" #endif /* _APT_DATER_H */ apt-dater-0.9.0/src/autoref.c0000644000175000017500000002703311760757134015371 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_AUTOREF /** * We record installed/updatable packages on the hosts. When a host has been * refreshed, we look at each package and put it in the following tree (this * will be used later to detect if some hosts are outdated running the same * distri): * * [ht_distris] * | * +--[Debian/4.0/etch] * | +--[package1] * | | +--(version1)->(host1, host2, host3) * | | +--(version2)->(host5, host6, ...) * | | | * | | ... * | +--[package2] * | | * | ... * +--[CentOS/4.7/Final] * | * ... * * [ ]: GHashTable * ( ): GList * **/ #include typedef struct _distri { #ifndef NDEBUG etype _type; #endif gchar *lsb_distributor; gchar *lsb_release; gchar *lsb_codename; gchar *uname_kernel; gchar *uname_machine; } Distri; typedef struct _version { #ifndef NDEBUG etype _type; #endif gchar *version; time_t ts_first; GList *nodes; } Version; static GHashTable *ht_distris = NULL; /* ====================[ begin: stuff taken from libdpkg.a ]==================== */ struct versionrevision { unsigned long epoch; const char *version; const char *revision; }; static inline int cisdigit(int c) { return (c>='0') && (c<='9'); } static int cisalpha(int c) { return ((c>='a') && (c<='z')) || ((c>='A') && (c<='Z')); } /* assume ascii; warning: evaluates x multiple times! */ #define order(x) ((x) == '~' ? -1 \ : cisdigit((x)) ? 0 \ : !(x) ? 0 \ : cisalpha((x)) ? (x) \ : (x) + 256) static int verrevcmp(const char *val, const char *ref) { if (!val) val= ""; if (!ref) ref= ""; while (*val || *ref) { int first_diff= 0; while ( (*val && !cisdigit(*val)) || (*ref && !cisdigit(*ref)) ) { int vc= order(*val), rc= order(*ref); if (vc != rc) return vc - rc; val++; ref++; } while ( *val == '0' ) val++; while ( *ref == '0' ) ref++; while (cisdigit(*val) && cisdigit(*ref)) { if (!first_diff) first_diff= *val - *ref; val++; ref++; } if (cisdigit(*val)) return 1; if (cisdigit(*ref)) return -1; if (first_diff) return first_diff; } return 0; } /* =====================[ end: stuff taken from libdpkg.a ]===================== */ /* Creates a string from LSB fields used for the hashtable. */ static inline gchar *distri2str(const Distri *d, gchar *buf, const gint bsize) { snprintf(buf, bsize-1, "%s|%s|%s|%s|%s", d->lsb_distributor, d->lsb_release, d->lsb_codename, d->uname_kernel, d->uname_machine); return buf; } /* Compares to distris. */ static gboolean distri_equal(gconstpointer a, gconstpointer b) { gchar da[0x1ff]; gchar db[0x1ff]; return g_str_equal(distri2str(a, da, sizeof(da)), distri2str(b, db, sizeof(db))); } /* Hash a distri. */ static guint distri_hash(gconstpointer key) { Distri *distri = (Distri *)key; gchar b[0x1ff]; ASSERT_TYPE(distri, T_DISTRI); return g_str_hash(distri2str(distri, b, sizeof(b))); } static gint cmp_vers(gconstpointer a, gconstpointer b) { ASSERT_TYPE((Version *)a, T_VERSION); ASSERT_TYPE((Version *)b, T_VERSION); return -verrevcmp(((Version *)a)->version, ((Version *)b)->version); } static inline int test_pkg(const PkgNode *pkg) { return (pkg->flag & (HOST_STATUS_PKGEXTRA | HOST_STATUS_PKGBROKEN)) == 0; } /* Add PkgNode to package hashtable */ static void add_pkg(gpointer data, gpointer user_data) { PkgNode *pkg = (PkgNode *)data; GHashTable *ht_packages = (GHashTable *)(((gpointer *)user_data)[0]); HostNode *node = (HostNode *)(((gpointer *)user_data)[1]); ASSERT_TYPE(pkg, T_PKGNODE); ASSERT_TYPE(node, T_HOSTNODE); if (!test_pkg(pkg)) return; gchar *v; if(((pkg->flag & HOST_STATUS_PKGUPDATE) || (pkg->flag & HOST_STATUS_PKGKEPTBACK)) && (pkg->data)) v = pkg->data; else v = pkg->version; if(!v) return; /* Create packages hashtable if needed. */ GList *l_versions = g_hash_table_lookup(ht_packages, pkg->package); Version _v; #ifndef NDEBUG _v._type = T_VERSION; #endif _v.version = v; /* Create version entry if needed. */ Version *vers = NULL; GList *l_v = g_list_find_custom(l_versions, &_v, cmp_vers); if (l_v) { vers = (Version *)l_v->data; ASSERT_TYPE(vers, T_VERSION); } if(!vers) { vers = g_malloc(sizeof(Version)); #ifndef NDEBUG vers->_type = T_VERSION; #endif vers->version = strdup(v); vers->ts_first = node->last_upd; vers->nodes = NULL; l_versions = g_list_prepend(l_versions, vers); g_hash_table_insert(ht_packages, g_strdup(pkg->package), l_versions); } else if (vers->ts_first > node->last_upd) { vers->ts_first = node->last_upd; } vers->nodes = g_list_prepend(vers->nodes, node); } /* Test if host should be observed by autoref. */ static inline int test_hostnode(const HostNode *node) { return (node->lsb_distributor && node->lsb_release && node->lsb_codename && node->uname_kernel && node->uname_machine); } /* Fetch package data from HostNode and feed it into the hashtables. */ void autoref_add_host_info(HostNode *node) { Distri distri; if(!test_hostnode(node)) return; if (!ht_distris) ht_distris = g_hash_table_new(distri_hash, distri_equal); #ifdef NDEBUG #define ASSIGN_DIST(d, n, f) \ (d).lsb_distributor = f((n)->lsb_distributor); \ (d).lsb_release = f((n)->lsb_release); \ (d).lsb_codename = f((n)->lsb_codename); \ (d).uname_kernel = f((n)->uname_kernel); \ (d).uname_machine = f((n)->uname_machine); #else #define ASSIGN_DIST(d, n, f) \ (d)._type = T_DISTRI; \ (d).lsb_distributor = f((n)->lsb_distributor); \ (d).lsb_release = f((n)->lsb_release); \ (d).lsb_codename = f((n)->lsb_codename); \ (d).uname_kernel = f((n)->uname_kernel); \ (d).uname_machine = f((n)->uname_machine); #endif ASSIGN_DIST(distri, node, ); /* Create distri hashtable if needed. */ GHashTable *ht_packages = g_hash_table_lookup(ht_distris, &distri); if(!ht_packages) { ht_packages = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL); Distri *ndistri = g_malloc(sizeof(Distri)); #ifndef NDEBUG ndistri->_type = T_DISTRI; #endif ASSIGN_DIST(*ndistri, node, g_strdup); g_hash_table_insert(ht_distris, ndistri, ht_packages); } /* Traverse package list and count installed versions. */ gpointer data[2]; data[0] = ht_packages; data[1] = node; g_list_foreach(node->packages, add_pkg, data); } /* Remove PkgNode from package hashtable */ static void rem_pkg(gpointer data, gpointer user_data) { PkgNode *pkg = (PkgNode *)data; GHashTable *ht_packages = (GHashTable *)(((gpointer *)user_data)[0]); HostNode *node = (HostNode *)(((gpointer *)user_data)[1]); ASSERT_TYPE(pkg, T_PKGNODE); ASSERT_TYPE(node, T_HOSTNODE); if (!test_pkg(pkg)) return; /* Lookup packages hashtable. */ GList *l_versions = g_hash_table_lookup(ht_packages, pkg->package); if(!l_versions) return; /* Lookup version list. */ gchar *v = NULL; if(((pkg->flag & HOST_STATUS_PKGUPDATE) || (pkg->flag & HOST_STATUS_PKGKEPTBACK)) && (pkg->data)) v = pkg->data; else v = pkg->version; Version _v; #ifndef NDEBUG _v._type = T_VERSION; #endif _v.version = v; Version *vers = NULL; GList *l_v = g_list_find_custom(l_versions, &_v, cmp_vers); if (l_v) { vers = (Version *)l_v->data; ASSERT_TYPE(vers, T_VERSION); } if(!vers) return; vers->nodes = g_list_remove(vers->nodes, node); } /* Remove package data of HostNode from the hashtable leaves. */ void autoref_rem_host_info(HostNode *node) { Distri distri; if(!test_hostnode(node)) return; if (!ht_distris) return; ASSIGN_DIST(distri, node, ); /* Lookup distri hashtable. */ GHashTable *ht_packages = g_hash_table_lookup(ht_distris, &distri); if(!ht_packages) return; /* Traverse package list and count installed versions. */ gpointer data[2]; data[0] = ht_packages; data[1] = node; g_list_foreach(node->packages, rem_pkg, data); } /* Put a HostNode into refresh. */ static void trigger_refresh(gpointer data, gpointer user_data) { HostNode *node = (HostNode *)data; node->category = C_REFRESH_REQUIRED; } /* Record list of nodes which needs to be refreshed. */ GList *refresh_nodes = NULL; /** * Add node to refresh list if: * - last refresh is older than the time this version was * seen by apt-dater first * - the node is allowed to refresh **/ static void check_refresh(gpointer data, gpointer user_data) { HostNode *node = (HostNode *)data; int *ts_first = (int *)user_data; ASSERT_TYPE(node, T_HOSTNODE); if(node && (node->last_upd < *ts_first) && ((node->forbid & HOST_FORBID_REFRESH) == 0) && (g_list_find(refresh_nodes, node) == NULL)) refresh_nodes = g_list_prepend(refresh_nodes, node); } /* Trigger refresh for any node which has older version data. */ static void add_refresh(gpointer value, gpointer user_data) { Version *version = (Version *)value; ASSERT_TYPE(version, T_VERSION); g_list_foreach(version->nodes, check_refresh, user_data); } /* Check if refresh is needed for each package. */ static void trigger_package(gpointer key, gpointer value, gpointer user_data) { GList *l_versions = (GList *)value; GHashTable *ht_packages = (GHashTable *)user_data; if(l_versions == NULL) return; l_versions = g_list_sort(l_versions, cmp_vers); if (value != l_versions) g_hash_table_insert(ht_packages, g_strdup(key), l_versions); Version *newest = (Version *)(l_versions->data); ASSERT_TYPE(newest, T_VERSION); GList *l_oldvers = g_list_next(l_versions); /* Only one version known => nothing todo. */ if(l_oldvers == NULL) return; /* Any host, which has last_upd < version->ts_first needs to be refreshed. */ g_list_foreach(l_oldvers, add_refresh, &( newest -> ts_first )); } /* Start refresh stuff for each distri. */ static void trigger_distri(gpointer key, gpointer value, gpointer user_data) { GHashTable *ht_packages = (GHashTable *)value; g_hash_table_foreach(ht_packages, trigger_package, ht_packages); } /** * This function is called by refreshStats when no * host remains in IN_REFRESH state. **/ guint autoref_trigger_auto() { if (ht_distris) { g_hash_table_foreach(ht_distris, trigger_distri, NULL); guint ret = g_list_length(refresh_nodes); if (ret) { /* Refresh now! */ g_list_foreach(refresh_nodes, trigger_refresh, NULL); g_list_free(refresh_nodes); refresh_nodes = NULL; return ret; } } return 0; } #endif apt-dater-0.9.0/src/autoref.h0000644000175000017500000000233711760757134015376 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _AUTOREF_H #define _AUTOREF_H #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_AUTOREF void autoref_add_host_info(HostNode *node); void autoref_rem_host_info(HostNode *node); guint autoref_trigger_auto(); #endif #endif /* _AUTOREF_H */ apt-dater-0.9.0/src/clusters.c0000644000175000017500000000342611760757134015570 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "clusters.h" #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif #include #ifdef FEAT_CLUSTERS static gint findCluster(gconstpointer a, gconstpointer b) { return g_ascii_strcasecmp(a, b); } void cluster_host_add(HostNode *n, const gchar *c) { if(g_list_find_custom(n->clusters, c, findCluster) == NULL) { n->clusters = g_list_insert_sorted(n->clusters, g_strdup(c), findCluster); n->status = n->status | HOST_STATUS_CLUSTERED; } } static void freeCluster(gchar *data, gpointer *user_data) { if(data) g_free(data); } void cluster_host_reset(HostNode *n) { if(n && n->clusters) { g_list_foreach(n->clusters, (GFunc) freeCluster, NULL); g_list_free(n->clusters); n->clusters = NULL; } } #endif /* FEAT_CLUSTERS */ apt-dater-0.9.0/src/clusters.h0000644000175000017500000000230011760757134015563 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _CLUSTERS_H #define _CLUSTERS_H #include "apt-dater.h" #ifdef FEAT_CLUSTERS void cluster_host_add(HostNode *, const gchar *); void cluster_host_reset(HostNode *); #endif /* FEAT_CLUSTERS */ #endif /* _CLUSTERS_H */ apt-dater-0.9.0/src/colors.c0000644000175000017500000000755411760757134015233 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "colors.h" #include "ui.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif int uicolors[UI_COLOR_MAX]; #ifdef HAVE_COLOR static struct mapping_t Colors[] = { { "black", COLOR_BLACK }, { "blue", COLOR_BLUE }, { "cyan", COLOR_CYAN }, { "green", COLOR_GREEN }, { "magenta", COLOR_MAGENTA }, { "red", COLOR_RED }, { "white", COLOR_WHITE }, { "yellow", COLOR_YELLOW }, #ifdef HAVE_USE_DEFAULT_COLORS { "default", COLOR_DEFAULT }, #endif { NULL, 0 }, }; static struct mapping_t Components[] = { { "default", UI_COLOR_DEFAULT }, { "menu", UI_COLOR_MENU }, { "status", UI_COLOR_STATUS }, { "selector", UI_COLOR_SELECTOR }, { "hoststatus", UI_COLOR_HOSTSTATUS }, { "query", UI_COLOR_QUERY }, { "input", UI_COLOR_INPUT }, { NULL, 0 }, }; gboolean setColorForComponent(const gchar *component, const gchar *fg, const gchar *bg) { int i, pos = 0; short setfg, setbg, setcomp; gboolean isbright; setfg = setbg = setcomp = -1; if((isbright = g_str_has_prefix (fg, PREFIX_COLOR_BRIGHT)) == TRUE) pos = strlen(PREFIX_COLOR_BRIGHT); for(i = 0; Components[i].name; i++) { if(!g_ascii_strcasecmp(Components[i].name, component)) { setcomp = i; break; } } for(i = 0; Colors[i].name; i++) { if(!g_ascii_strcasecmp(Colors[i].name, &fg[pos])) { setfg = i; } if(!g_ascii_strcasecmp(Colors[i].name, bg)) { setbg = i; } } if(setfg == -1 || setbg == -1 || setcomp == -1) return(FALSE); init_pair(setcomp+1, Colors[setfg].value, Colors[setbg].value); uicolors[setcomp] = COLOR_PAIR(setcomp+1) | ((isbright == TRUE) ? A_BOLD : 0); return(TRUE); } gboolean setColors(const gchar **colors) { gint i, j; gchar **colordef; gboolean r = TRUE; if(has_colors() == FALSE) return(FALSE); i = 0; while(*(colors+i)) { if((colordef = g_strsplit(colors[i++], " ", 3))) { j = 0; while(*(colordef+j++)); if(j == 4) r&= setColorForComponent(colordef[0], colordef[1], colordef[2]); g_strfreev(colordef); } } return(r); } #endif /* HAVE_COLOR */ void ui_start_color () { short fg, bg; memset (uicolors, A_NORMAL, sizeof (gint) * UI_COLOR_MAX); /* Some defaults */ uicolors[UI_COLOR_DEFAULT] = A_NORMAL; uicolors[UI_COLOR_MENU] = A_REVERSE; uicolors[UI_COLOR_STATUS] = A_REVERSE; uicolors[UI_COLOR_SELECTOR] = A_REVERSE; uicolors[UI_COLOR_QUERY] = A_BOLD; uicolors[UI_COLOR_INPUT] = A_NORMAL; uicolors[UI_COLOR_HOSTSTATUS] = A_BOLD; #ifdef HAVE_COLOR start_color(); if(cfg->colors) if(setColors((const gchar **) cfg->colors) == FALSE) g_warning(_("Wrong color definition!")); #ifdef HAVE_USE_DEFAULT_COLORS if(pair_content(UI_COLOR_DEFAULT+1, &fg, &bg) != ERR) { if(!fg && !bg) fg = bg = COLOR_DEFAULT; assume_default_colors(fg, bg); } else use_default_colors(); #endif /* HAVE_USE_DEFAULT_COLORS */ #endif /* HAVE_COLOR */ } apt-dater-0.9.0/src/colors.h0000644000175000017500000000243411760757134015230 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _COLOR_H #define _COLOR_H #define COLOR_DEFAULT -1 #define PREFIX_COLOR_BRIGHT "bright" enum { UI_COLOR_DEFAULT = 0, UI_COLOR_MENU, UI_COLOR_STATUS, UI_COLOR_SELECTOR, UI_COLOR_BODY, UI_COLOR_QUERY, UI_COLOR_INPUT, UI_COLOR_HOSTSTATUS, UI_COLOR_MAX, }; void ui_start_color(); #endif /* _COLOR_H */ apt-dater-0.9.0/src/env.c0000644000175000017500000001133511760757134014512 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2009-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "env.h" GSList *base_env = NULL; void env_init(gchar **envp) { g_assert(base_env == NULL); int i; for(i=0; envp[i]; i++) { base_env = g_slist_prepend(base_env, envp[i]); } #define ADD_GENV(name, value) \ base_env = g_slist_prepend(base_env, g_strdup_printf("AD_"name"=%s", value)) ADD_GENV("HOSTSFILE" , cfg->hostsfile); ADD_GENV("SCREENRCFILE" , cfg->screenrcfile); ADD_GENV("STATSDIR" , cfg->statsdir); ADD_GENV("SSH_CMD" , cfg->ssh_cmd); ADD_GENV("SFTP_CMD" , cfg->sftp_cmd); ADD_GENV("SSH_OPTFLAGS" , cfg->ssh_optflags); ADD_GENV("CMD_REFRESH" , cfg->cmd_refresh); ADD_GENV("CMD_UPGRADE" , cfg->cmd_upgrade); ADD_GENV("CMD_INSTALL" , cfg->cmd_install); #ifdef FEAT_HISTORY ADD_GENV("HIST_RECORD" , cfg->record_history ? "true" : "false"); ADD_GENV("HIST_ERRPATTERN" , cfg->history_errpattern); #else ADD_GENV("HIST_RECORD" , "false"); #endif ADD_GENV("HOOK_PRE_UPGRADE" , cfg->hook_pre_upgrade); ADD_GENV("HOOK_PRE_REFRESH" , cfg->hook_pre_refresh); ADD_GENV("HOOK_PRE_INSTALL" , cfg->hook_pre_install); ADD_GENV("HOOK_PRE_CONNECT" , cfg->hook_pre_connect); ADD_GENV("HOOK_POST_UPGRADE" , cfg->hook_post_upgrade); ADD_GENV("HOOK_POST_REFRESH", cfg->hook_post_refresh); ADD_GENV("HOOK_POST_INSTALL", cfg->hook_post_install); ADD_GENV("HOOK_POST_CONNECT", cfg->hook_post_connect); ADD_GENV("PLUGINDIR", cfg->plugindir); } gchar ** env_build(HostNode *n, const gchar *action, const gchar *param, const HistoryEntry *he) { gchar **new_env = (gchar **) g_new0(gchar**, g_slist_length(base_env) + 20 #ifdef FEAT_CLUSTERS + 1 + g_list_length(n->clusters) #endif ); gint i = 0; GSList *p; for(p = base_env; p; p = p->next) new_env[i++] = g_strdup(p->data); #define ADD_HENV(name, value) \ new_env[i++] = g_strdup_printf("AD_"name"=%s", value) ADD_HENV("HOSTNAME" , n->hostname); ADD_HENV("GROUP" , n->group); if(n->ssh_user) ADD_HENV("SSH_USER" , n->ssh_user); else ADD_HENV("SSH_USER" , ""); if(n->ssh_port) new_env[i++] = g_strdup_printf("AD_SSH_PORT=%d", n->ssh_port); else ADD_HENV("SSH_PORT" , ""); if(n->identity_file && strlen(n->identity_file) > 0) new_env[i++] = g_strdup_printf("AD_SSH_ID=-i %s", n->identity_file); else ADD_HENV("SSH_ID" , ""); ADD_HENV("STATSFILE" , n->statsfile); ADD_HENV("KERNEL" , n->kernelrel); ADD_HENV("LSB_DISTRI" , n->lsb_distributor); ADD_HENV("LSB_RELEASE" , n->lsb_release); ADD_HENV("LSB_CODENAME" , n->lsb_codename); ADD_HENV("UNAME_KERNEL" , n->uname_kernel); ADD_HENV("UNAME_MACHINE" , n->uname_machine); ADD_HENV("VIRT" , n->virt); ADD_HENV("TYPE" , n->type); ADD_HENV("UUID" , n->uuid); #ifdef FEAT_HISTORY if(cfg->record_history && he) { gchar *hp = history_rec_path(n); gchar *fn_meta = g_strdup_printf("%s/meta", hp); ADD_HENV("HIST_PATH" , hp); g_free(hp); history_write_meta(fn_meta, he); g_free(fn_meta); } else #endif ADD_HENV("HIST_PATH" , ""); #ifdef FEAT_CLUSTERS if(n->clusters != NULL) { new_env[i++] = g_strdup_printf("AD_CLUSTERS=%d", g_list_length(n->clusters)); int j = 1; GList *c = n->clusters; while(c != NULL) { new_env[i++] = g_strdup_printf("AD_CLUSTER%d=%s", j, (gchar *)c->data); c = c->next; j++; } } else #endif ADD_HENV("CLUSTERS" , "0"); ADD_HENV("ACTION" , action); if(param) ADD_HENV("PARAM" , param); else ADD_HENV("PARAM" , ""); return new_env; } apt-dater-0.9.0/src/env.h0000644000175000017500000000230211760757134014511 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2009-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _ENV_H #define _ENV_H #include "apt-dater.h" #include "history.h" void env_init(gchar **envp); gchar ** env_build(HostNode *n, const gchar *action, const gchar *param, const HistoryEntry *he); #endif /* _ENV_H */ apt-dater-0.9.0/src/exec.c0000644000175000017500000001401311760757134014642 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "screen.h" #include "exec.h" #include "stats.h" #include "parsecmd.h" #include "history.h" #include "env.h" #include #include #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif gboolean ssh_cmd_refresh(HostNode *n) { gboolean r; GError *error = NULL; gchar *cmd = NULL; gchar *argv[2] = {PKGLIBDIR"/cmd", NULL}; gchar *output = NULL; /* gchar *identity_file = NULL; */ GPid child_pid; gint standard_output; GIOChannel *iocstdout; g_assert(n); prepareStatsFile(n); gchar **env = env_build(n, "refresh", NULL, NULL); r = g_spawn_async_with_pipes(g_getenv ("HOME"), /* working_directory */ argv, env, /* envp */ G_SPAWN_STDERR_TO_DEV_NULL | G_SPAWN_SEARCH_PATH, /* GSpawnFlags */ NULL, /* GSpawnChildSetupFunc */ NULL, /* user_data */ &child_pid, NULL, /* standard_input */ &standard_output, /* &standard_output */ NULL, /* standard_error */ &error); g_strfreev(env); if(r == TRUE) { iocstdout = g_io_channel_unix_new (standard_output); g_io_channel_set_flags(iocstdout, G_IO_FLAG_NONBLOCK, &error); g_io_channel_set_buffer_size (iocstdout, 8192); g_io_add_watch_full (iocstdout, G_PRIORITY_DEFAULT, G_IO_PRI | G_IO_HUP | G_IO_ERR | G_IO_NVAL | G_IO_IN, setStatsFileFromIOC, n, refreshStatsOfNode); } if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } g_free(output); g_free(cmd); return r; } gboolean ssh_cmd_upgrade(HostNode *n, const gboolean detached) { gboolean r; GError *error = NULL; gchar *cmd = NULL; gchar **argv = NULL; g_assert(n); if(n->forbid & HOST_FORBID_UPGRADE) return FALSE; HistoryEntry he; he.ts = time(NULL); he.maintainer = maintainer; he.action = "upgrade"; he.data = NULL; gchar *screen = screen_new(n, detached); cmd = g_strdup_printf ("%s%s", screen, PKGLIBDIR"/cmd"); g_free(screen); #ifdef FEAT_HISTORY n->parse_result = cfg->history_errpattern && strlen(cfg->history_errpattern);; #endif argv = g_strsplit(cmd, "+", 0); g_free(cmd); gchar **env = env_build(n, "upgrade", NULL, &he); r = g_spawn_sync(g_getenv ("HOME"), argv, env, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); g_strfreev(env); g_strfreev(argv); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } #ifdef FEAT_HISTORY if(!detached && n->parse_result && !screen_get_sessions(n)) { n->parse_result = FALSE; return history_ts_failed(n); } #endif return FALSE; } gboolean ssh_cmd_install(HostNode *n, gchar *package, const gboolean detached) { gboolean r; GError *error = NULL; gchar *cmd = NULL; gchar **argv = NULL; g_assert(n); if(n->forbid & HOST_FORBID_INSTALL) return FALSE; HistoryEntry he; he.ts = time(NULL); he.maintainer = maintainer; he.action = "install"; he.data = package; gchar *screen = screen_new(n, detached); cmd = g_strdup_printf ("%s%s", screen, PKGLIBDIR"/cmd"); g_free(screen); #ifdef FEAT_HISTORY n->parse_result = cfg->history_errpattern && strlen(cfg->history_errpattern); #endif argv = g_strsplit(cmd, "+", 0); g_free(cmd); gchar **env = env_build(n, "install", package, &he); r = g_spawn_sync(g_getenv ("HOME"), argv, env, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); g_strfreev(env); g_strfreev(argv); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } #ifdef FEAT_HISTORY if(!detached && n->parse_result && !screen_get_sessions(n)) { n->parse_result = FALSE; return history_ts_failed(n); } #endif return FALSE; } void ssh_connect(HostNode *n, const gboolean detached) { gboolean r; GError *error = NULL; gchar *cmd = NULL; gchar **argv; HistoryEntry he; he.ts = time(NULL); he.maintainer = maintainer; he.action = "connect"; he.data = NULL; gchar *screen = screen_new(n, detached); cmd = g_strdup_printf ("%s%s", screen, PKGLIBDIR"/cmd"); g_free(screen); argv = g_strsplit(cmd, "+", 0); g_free(cmd); gchar **env = env_build(n, "connect", NULL, &he); r = g_spawn_sync(g_getenv("HOME"), argv, env, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); g_strfreev(env); g_strfreev(argv); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } } void sftp_connect(HostNode *n) { gboolean r; GError *error = NULL; gchar *cmd = NULL; gchar **argv; g_assert(n); HistoryEntry he; he.ts = time(NULL); he.maintainer = maintainer; he.action = "transfer"; he.data = NULL; gchar *screen = screen_new(n, FALSE); cmd = g_strdup_printf ("%s%s", screen, PKGLIBDIR"/cmd"); g_free(screen); argv = g_strsplit(cmd, "+", 0); g_free(cmd); gchar **env = env_build(n, "transfer", NULL, &he); r = g_spawn_sync(g_getenv("HOME"), argv, env, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); g_strfreev(env); g_strfreev(argv); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } } apt-dater-0.9.0/src/exec.h0000644000175000017500000000247411760757134014657 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _EXEC_H #define _EXEC_H #include "ui.h" gboolean ssh_cmd_refresh(HostNode *n); gboolean ssh_cmd_upgrade(HostNode *n, const gboolean detached); gboolean ssh_cmd_install(HostNode *n, gchar *package, const gboolean detached); void ssh_connect(HostNode *n, const gboolean detached); void sftp_connect(HostNode *n); #endif /* _EXEC_H */ apt-dater-0.9.0/src/extern.h0000644000175000017500000000223411760757134015232 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _EXTERN_H #define _EXTERN_H extern CfgFile *cfg; extern GMainLoop *loop; extern gboolean rebuilddl; extern time_t oldest_st_mtime; extern int uicolors[]; #endif /* _EXTERN_H */ apt-dater-0.9.0/src/history.c0000644000175000017500000001253311760757134015424 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "history.h" #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_HISTORY HistoryEntry *history_read_meta(const gchar *fn, const gchar *tfn) { GKeyFile *kf = g_key_file_new(); if(!g_key_file_load_from_file(kf, fn, G_KEY_FILE_NONE, NULL)) { g_key_file_free(kf); return NULL; } HistoryEntry *he = g_new(HistoryEntry, 1); he->ts = g_key_file_get_integer(kf, "Meta", "TS", NULL); he->maintainer = g_key_file_get_string(kf, "Meta", "Maintainer", NULL); he->action = g_key_file_get_string(kf, "Meta", "Action", NULL); he->data = g_key_file_get_string(kf, "Meta", "Data", NULL); he->duration = (gint) g_key_file_get_double(kf, "Meta", "Duration", NULL); he->errpattern = g_key_file_get_string(kf, "Meta", "ErrPattern", NULL); g_key_file_free(kf); return he; } void history_write_meta(const gchar *fn, const HistoryEntry *he) { GKeyFile *kf = g_key_file_new(); g_key_file_set_integer(kf, "Meta", "TS", he->ts); if(he->maintainer) g_key_file_set_string(kf, "Meta", "Maintainer", he->maintainer); if(he->action) g_key_file_set_string(kf, "Meta", "Action", he->action); if(he->data) g_key_file_set_string(kf, "Meta", "Data", he->data); gchar *data = g_key_file_to_data(kf, NULL, NULL); g_key_file_free(kf); if(!data) return; GError *error = NULL; g_file_set_contents(fn, data, -1, &error); if (error) { g_error("%s", error->message); g_clear_error(&error); } g_free(data); } static gint cmp_he(gconstpointer a, gconstpointer b) { const HistoryEntry *ha = (HistoryEntry *)a; const HistoryEntry *hb = (HistoryEntry *)b; if(ha->ts < hb->ts) return -1; if(ha->ts == hb->ts) return 0; return 1; } GList *history_get_entries(const HostNode *n) { const gchar *fn; GList *hel = NULL; gchar *path = history_path(n); GDir *dir = g_dir_open(path, 0, NULL); if(!dir) { g_free(path); return NULL; } while((fn = g_dir_read_name(dir))) { gchar *meta = g_strdup_printf("%s/%s/meta", path, fn); gchar *timing = g_strdup_printf("%s/%s/timingfile", path, fn); HistoryEntry *he = history_read_meta(meta, timing); g_free(timing); g_free(meta); if(he) { he->path = g_strdup_printf("%s/%s", path, fn); hel = g_list_insert_sorted(hel, he, cmp_he); } } g_dir_close(dir); g_free(path); return hel; } HistoryEntry *history_recent_entry(const HostNode *n) { gchar *path = history_ts_path(n); gchar *meta = g_strdup_printf("%s/meta", path); gchar *timing = g_strdup_printf("%s/timingfile", path); HistoryEntry *he = history_read_meta(meta, timing); if(he) { he->path = path; } else g_free(path); g_free(timing); g_free(meta); return he; } static void free_hel(gpointer data, gpointer user_data) { HistoryEntry *he = (HistoryEntry *)data; g_free(he->path); g_free(he->maintainer); g_free(he->action); g_free(he->data); g_free(he->errpattern); g_free(data); } void history_free_he(HistoryEntry *he) { free_hel(he, NULL); } void history_free_hel(GList *hel) { g_list_foreach(hel, free_hel, NULL); g_list_free(hel); } static void history_show_cmd(gchar *cmd, gchar *param1, gchar *param2, HistoryEntry *he) { GError *error = NULL; gchar *argv[5] = { ENV_BINARY, cmd, param1, param2, NULL}; if(g_spawn_sync(he->path, argv, NULL, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error) == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } } void history_show_less(HistoryEntry *he) { history_show_cmd("less", "-fr", "typescript", he); } void history_show_replay(HistoryEntry *he) { history_show_cmd("scriptreplay", "timingfile", NULL, he); } void history_show_less_search(HistoryEntry *he, gchar *pattern) { GError *error = NULL; gchar *argv[6] = { ENV_BINARY, "less", "-ifrp", pattern, "typescript", NULL}; if(g_spawn_sync(he->path, argv, NULL, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error) == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } } gboolean history_ts_failed(HostNode *n) { gchar *p = history_ts_path(n); gchar *fn = g_strdup_printf("%s/failed", p); g_free(p); gboolean r = g_file_test(fn, G_FILE_TEST_EXISTS); g_free(fn); return r; } #endif apt-dater-0.9.0/src/history.h0000644000175000017500000000431411760757134015427 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _HISTORY_H #define _HISTORY_H #include "apt-dater.h" typedef struct _historyEntry { time_t ts; gint duration; gchar *path; gchar *maintainer; gchar *action; gchar *data; gchar *errpattern; } HistoryEntry; #ifdef FEAT_HISTORY static inline gchar *history_path(const HostNode *n) { return g_strdup_printf("%s/%s/history/%s:%d", g_get_user_data_dir(), PACKAGE, n->hostname, n->ssh_port); } static inline gchar *history_ts_path(const HostNode *n) { return g_strdup_printf("%s/%s/history/%s:%d/%d-%d", g_get_user_data_dir(), PACKAGE, n->hostname, n->ssh_port, n->hist_ts, getpid()); } static inline gchar *history_rec_path(HostNode *n) { n->hist_ts = time(NULL); gchar *p = history_ts_path(n); g_mkdir_with_parents(p, S_IRWXU); return p; } GList *history_get_entries(const HostNode *); HistoryEntry *history_recent_entry(const HostNode *); void history_write_meta(const gchar *, const HistoryEntry *); void history_free_he(HistoryEntry *); void history_free_hel(GList *); void history_show_less(HistoryEntry *); void history_show_replay(HistoryEntry *); void history_show_less_search(HistoryEntry *, gchar *pattern); gboolean history_ts_failed(HostNode *); #endif #endif /* _HISTORY_H */ apt-dater-0.9.0/src/keyfiles.c0000644000175000017500000003432511760757134015541 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "screen.h" #include "keyfiles.h" #include "stats.h" #include "lock.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif static char apt_dater_conf[] = "# Config file of apt-dater in the form of the" " glib GKeyFile required\n\n[Paths]\n# Default: $XDG_CONFIG_HOME/apt-dater/h" "osts.conf\n#HostsFile=path-to/hosts.conf\n\n# Default: $XDG_DATA_HOME/apt-d" "ater\n#StatsDir=path-to/stats\n\n[SSH]\n# SSH binary\nCmd=/usr/bin/ssh\nOpt" "ionalCmdFlags=-t\n\n# SFTP binary\nSFTPCmd=/usr/bin/sftp\n\n" "#[Screen]\n## Default: $XDG_CONFIG_HOME" "/apt-dater/screenrc\n#RCFile=path-to/screenrc\n#\n## Default: %m # %u@%h:%p" "\n#Title=%m # %U%H\n#\n\n# These values requires apt-dater-host to be i" "nstalled on the target host.\n# You could call apt/aptitude directly (see a" "pt-dater-host source),\n# but this is not recommended.\n[Commands]\nCmdRefr" "esh=apt-dater-host refresh\nCmdUpgrade=apt-dater-host upgrade\nCmdInstall=a" "pt-dater-host install %s\n\n[Appearance]\n# Colors = (COMPONENT FG BG " "\';\')*\n# COMPONENT ::= \'default\' | \'menu\' | \'status\' | \'selector\'" " | \'hoststatus\' |\n# \'query\' | \'input\'\n# FG ::=" " COLOR\n# BG ::= COLOR\n# COLOR ::= \'black\' | \'blue\' | \'cya" "n\' | \'green\' | \'magenta\' | \'red\' |\n# \'white\' | \'ye" "llow\'\nColors=menu brightgreen blue;status brightgreen blue;selector black" " red;\n\n#[TCLFilter]\n#Predefined filter expression on startup.\n#FilterEx" "p=return [expr [string compare $lsb_distri \"Debian\"] == 0 && $lsb_rel < 5" ".0]\n#Load this TCL file on startup in the same context as the FilterExp.\n" "#FilterFile=/patch/to/file.tcl\n"; static char hosts_conf[] = "# Syntax:\n#\n# [Customer Name]\n# Hosts=([Opti" "onalUser@]host.domain[:OptionalPort];)*\n#\n\n[Localdomain]\nHosts=localhos" "t;\n\n[IBH]\nHosts=example1.ibh.net;example2.ibh.net;test@example3.ibh.net:" "62222;\n"; static char screenrc[] = "# -------------------------------------------------" "-----------------------------\n# SCREEN SETTINGS\n# -----------------------" "-------------------------------------------------------\n\nstartup_message " "off\n\n#defflow on # will force screen to process ^S/^Q\ndeflogin on\nautod" "etach on\n\n# turn visual bell on\nvbell on\n\n# define a bigger scrollback" ", default is 100 lines\ndefscrollback 2048\n\n# ---------------------------" "---------------------------------------------------\n# SCREEN KEYBINDINGS\n" "# -------------------------------------------------------------------------" "-----\n\n# Remove some stupid / dangerous key bindings\nbind ^k\n#bind L\nb" "ind ^\\\n# Make them better\nbind \\\\ quit\nbind K kill\nbind I login on\n" "bind O login off\nbind } history\n\n# Sessions should stay until destroyed " "by pressing q\nzombie \'q\'\n\n# --------------------------------------" "----------------------------------------\n# TERMINAL SETTINGS\n# ----------" "--------------------------------------------------------------------\n\n# T" "he vt100 description does not mention \"dl\". *sigh*\ntermcapinfo vt100 dl=" "5\\E[M\n\n# Set the hardstatus prop on gui terms to set the titlebar/icon t" "itle\ntermcapinfo xterm*|rxvt*|kterm*|Eterm* hs:ts=\\E]0;:fs=\\007:ds=\\E]0" ";\\007:OP\n\n# set these terminals up to be \'optimal\' instead of vt100\n#" "termcapinfo xterm*|linux*|rxvt*|Eterm* OP\n\n# Change the xterm initializat" "ion string from is2=\\E[!p\\E[?3;4l\\E[4l\\E>\n# (This fixes the \"Aborted " "because of window size change\" konsole symptoms found\n# in bug #134198)" "\ntermcapinfo xterm \'is=\\E[r\\E[m\\E[2J\\E[H\\E[?7h\\E[?1;4;6l\'\n\n# To " "get screen to add lines to xterm\'s scrollback buffer, uncomment the\n# fol" "lowing termcapinfo line which tells xterm to use the normal screen buffer\n" "# (which has scrollback), not the alternate screen buffer.\n#\ntermcapinfo " "xterm|xterms|xs|rxvt ti@:te@\n\n# Add caption line with clock, window title" " and window flags.\ncaption always \"%{b bG}%c%=%t%=%f\"\n\n# Catch zmodem " "file transfers\nzmodem catch\n"; int chkForInitialConfig(const gchar *cfgdir, const gchar *cfgfile) { FILE *fp = NULL; gchar *pathtofile = NULL; if(g_file_test (cfgfile, G_FILE_TEST_IS_REGULAR|G_FILE_TEST_EXISTS) == FALSE) { if(g_file_test(cfgdir, G_FILE_TEST_IS_DIR) == FALSE) { if(g_mkdir_with_parents (cfgdir, 0700)) return(1); /* Create a example hosts.conf */ pathtofile = g_strdup_printf("%s/hosts.conf", cfgdir); if(!pathtofile) g_error(_("Out of memory.")); fp = fopen(pathtofile, "wx"); g_message(_("Creating file %s"), pathtofile); if(fp) { if(fwrite(hosts_conf, sizeof(hosts_conf)-1, 1, fp) != 1) g_error(_("Could not write to file %s."), pathtofile); fclose(fp); } g_free(pathtofile); /* Create a the example screenrc */ pathtofile = g_strdup_printf("%s/screenrc", cfgdir); if(!pathtofile) g_error(_("Out of memory.")); fp = fopen(pathtofile, "wx"); g_message(_("Creating file %s"), pathtofile); if(fp) { if(fwrite(screenrc, sizeof(screenrc)-1, 1, fp) != 1) g_error(_("Could not write to file %s."), pathtofile); fclose(fp); } g_free(pathtofile); /* Create initial config file */ fp = fopen(cfgfile, "wx"); if(!fp) return(1); g_message(_("Creating file %s"), cfgfile); if(fwrite(apt_dater_conf, sizeof(apt_dater_conf)-1, 1, fp) != 1) g_error(_("Could not write to file %s."), cfgfile); fclose(fp); } } return(0); } static int cmpStringP(const void *p1, const void *p2) { return(g_ascii_strcasecmp (*(gchar * const *) p1, *(gchar * const *) p2)); } void freeConfig (CfgFile *cfg) { g_free(cfg->hostsfile); g_free(cfg->statsdir); g_free(cfg->ssh_cmd); g_free(cfg->ssh_optflags); g_free(cfg->sftp_cmd); g_free(cfg->cmd_refresh); g_free(cfg->cmd_upgrade); g_free(cfg->cmd_install); g_free(cfg->screenrcfile); g_free(cfg->screentitle); g_strfreev(cfg->colors); g_free(cfg); } CfgFile *loadConfig (char *filename) { GKeyFile *keyfile; GKeyFileFlags flags; GError *error = NULL; CfgFile *lcfg = NULL; keyfile = g_key_file_new (); flags = G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS; if (!g_key_file_load_from_file (keyfile, filename, flags, &error)) { g_error ("%s: %s", filename, error->message); g_key_file_free(keyfile); return (FALSE); } lcfg = g_new0(CfgFile, 1); #ifndef NDEBUG lcfg->_type = T_CFGFILE; #endif lcfg->ssh_optflags = g_key_file_get_string(keyfile, "SSH", "OptionalCmdFlags", &error); g_clear_error(&error); if(!(lcfg->hostsfile = g_key_file_get_string(keyfile, "Paths", "HostsFile", NULL))) lcfg->hostsfile = g_strdup_printf("%s/%s/%s", g_get_user_config_dir(), PROG_NAME, "hosts.conf"); if(!(lcfg->statsdir = g_key_file_get_string(keyfile, "Paths", "StatsDir", NULL))) lcfg->statsdir = g_strdup_printf("%s/%s/%s", g_get_user_cache_dir(), PROG_NAME, "stats"); g_mkdir_with_parents(lcfg->statsdir, S_IRWXU | S_IRWXG | S_IRWXO); if(!(lcfg->screenrcfile = g_key_file_get_string(keyfile, "Screen", "RCFile", NULL))) lcfg->screenrcfile = g_strdup_printf("%s/%s/%s", g_get_user_config_dir(), PROG_NAME, "screenrc"); if(!(lcfg->screentitle = g_key_file_get_string(keyfile, "Screen", "Title", NULL))) lcfg->screentitle = g_strdup("%m # %U%H"); if(!(lcfg->ssh_cmd = g_key_file_get_string(keyfile, "SSH", "Cmd", &error))) { g_error ("%s: %s", filename, error->message); return (NULL); } if(!(lcfg->sftp_cmd = g_key_file_get_string(keyfile, "SSH", "SFTPCmd", &error))) { g_error ("%s: %s", filename, error->message); return (NULL); } lcfg->ssh_agent = g_key_file_get_boolean(keyfile, "SSH", "SpawnAgent", NULL); lcfg->ssh_add = g_key_file_get_string_list(keyfile, "SSH", "AddKeys", &lcfg->ssh_numadd, NULL); if(!(lcfg->cmd_refresh = g_key_file_get_string(keyfile, "Commands", "CmdRefresh", &error))) { g_error ("%s: %s", filename, error->message); return (NULL); } if(!(lcfg->cmd_upgrade = g_key_file_get_string(keyfile, "Commands", "CmdUpgrade", &error))) { g_error ("%s: %s", filename, error->message); return (NULL); } if(!(lcfg->cmd_install = g_key_file_get_string(keyfile, "Commands", "CmdInstall", &error))) { g_error ("%s: %s", filename, error->message); return (NULL); } lcfg->dump_screen = !g_key_file_get_boolean(keyfile, "Screen", "NoDumps", &error); if (error) { lcfg->dump_screen = TRUE; g_clear_error(&error); } lcfg->query_maintainer = g_key_file_get_integer(keyfile, "Screen", "QueryMaintainer", &error); if (error) { lcfg->query_maintainer = 0; g_clear_error(&error); } if(!(lcfg->colors = g_key_file_get_string_list(keyfile, "Appearance", "Colors", NULL, &error))) { g_message ("%s: %s", filename, error->message); } #ifdef FEAT_TCLFILTER lcfg->filterexp = g_key_file_get_string(keyfile, "TCLFilter", "FilterExp", NULL); lcfg->filterfile = g_key_file_get_string(keyfile, "TCLFilter", "FilterFile", NULL); #endif #ifdef FEAT_AUTOREF lcfg->auto_refresh = g_key_file_get_boolean(keyfile, "AutoRef", "enabled", &error); if (error) { lcfg->auto_refresh = TRUE; g_clear_error(&error); } #endif lcfg->beep = g_key_file_get_boolean(keyfile, "Notify", "beep", &error); if (error) { lcfg->beep = TRUE; g_clear_error(&error); } lcfg->flash = g_key_file_get_boolean(keyfile, "Notify", "flash", &error); if (error) { lcfg->flash = TRUE; g_clear_error(&error); } #ifdef FEAT_HISTORY lcfg->flash = g_key_file_get_boolean(keyfile, "History", "record", &error); if (error) { lcfg->record_history = TRUE; g_clear_error(&error); } lcfg->history_errpattern = g_key_file_get_string(keyfile, "History", "ErrPattern", NULL); if(!lcfg->history_errpattern) lcfg->history_errpattern = "(error|warning|fail)"; #endif #define KEY_FILE_GET_STRING_DEFAULT(var, sec, val, default) \ (var) = g_key_file_get_string(keyfile, sec, val, NULL); \ if(!(var)) \ (var) = (default); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_pre_upgrade, "Hooks", "PreUpgrade" , "/etc/apt-dater/pre-upg.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_pre_refresh, "Hooks", "PreRefresh", "/etc/apt-dater/pre-ref.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_pre_install, "Hooks", "PreInstall", "/etc/apt-dater/pre-ins.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_pre_connect, "Hooks", "PreConnect", "/etc/apt-dater/pre-con.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_post_upgrade, "Hooks", "PostUpgrade" , "/etc/apt-dater/post-upg.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_post_refresh, "Hooks", "PostRefresh", "/etc/apt-dater/post-ref.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_post_install, "Hooks", "PostInstall", "/etc/apt-dater/post-ins.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->hook_post_connect, "Hooks", "PostConnect", "/etc/apt-dater/post-con.d"); KEY_FILE_GET_STRING_DEFAULT(lcfg->plugindir, "Hooks", "PluginDir", "/etc/apt-dater/plugins"); g_clear_error(&error); g_key_file_free(keyfile); return (lcfg); } GList *loadHosts (char *filename) { GKeyFile *keyfile; GKeyFileFlags flags; GError *error = NULL; GList *hosts = NULL; gchar **groups = NULL; gchar **khosts = NULL; char ssh_user[BUF_MAX_LEN]; char hostname[BUF_MAX_LEN]; int ssh_port = 0; gsize lengrp, lenkey; HostNode *hostnode; gint i, j; keyfile = g_key_file_new (); flags = G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS; if (!g_key_file_load_from_file (keyfile, filename, flags, &error)) { g_error ("%s: %s", filename, error->message); g_key_file_free(keyfile); return (FALSE); } groups = g_key_file_get_groups (keyfile, &lengrp); qsort(groups, lengrp, sizeof(gchar *), cmpStringP); for(i = 0; i < lengrp; i++) { if(!(khosts = g_key_file_get_string_list(keyfile, groups[i], "Hosts", &lenkey, &error))) { g_error ("%s: %s", filename, error->message); return(NULL); } qsort(khosts, lenkey, sizeof(gchar *), cmpStringP); gchar *host_type = g_key_file_get_string(keyfile, groups[i], "Type", NULL); if(!host_type) host_type = "generic-ssh"; for(j = 0; j < lenkey; j++) { hostnode = g_new0(HostNode, 1); #ifndef NDEBUG hostnode->_type = T_HOSTNODE; #endif *hostname = *ssh_user = 0; ssh_port = 0; if(sscanf(khosts[j], "%255[a-zA-Z0-9_-.]@%255[a-zA-Z0-9-.]:%d", ssh_user, hostname, &ssh_port) != 3) { *hostname = *ssh_user = 0; ssh_port = 0; if(sscanf(khosts[j], "%255[a-zA-Z0-9-.]:%d", hostname, &ssh_port) != 2) { *hostname = *ssh_user = 0; ssh_port = 0; if(sscanf(khosts[j], "%255[a-zA-Z0-9_-.]@%255[a-zA-Z0-9-.]", ssh_user, hostname) != 2) { *hostname = *ssh_user = 0; ssh_port = 0; sscanf(khosts[j], "%255s", hostname); } } } hostnode->hostname = g_strdup(hostname); hostnode->ssh_user = *ssh_user ? g_strdup(ssh_user) : NULL; hostnode->ssh_port = ssh_port ? ssh_port : 0; hostnode->statsfile = g_strdup_printf("%s/%s:%d.stat", cfg->statsdir, hostnode->hostname, hostnode->ssh_port); hostnode->fdlock = -1; hostnode->identity_file = g_key_file_get_string(keyfile, groups[i], "IdentityFile", &error); hostnode->tagged = FALSE; g_clear_error(&error); hostnode->group = groups[i]; hostnode->type = host_type; hostnode->uuid[0] = 0; getUpdatesFromStat(hostnode); hosts = g_list_append(hosts, hostnode); g_free(khosts[j]); } g_free(khosts); } g_free(groups); g_clear_error(&error); g_key_file_free(keyfile); return (hosts); } apt-dater-0.9.0/src/keyfiles.h0000644000175000017500000000230411760757134015536 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _KEYFILES_H #define _KEYFILES_H GList *loadHosts (char *filename); CfgFile *loadConfig (char *filename); void freeConfig (CfgFile *cfg); int chkForInitialConfig(const gchar *, const gchar *); #endif /* _KEYFILES_H */ apt-dater-0.9.0/src/lock.c0000644000175000017500000000535011760757134014652 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "lock.h" #include "stats.h" #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif static GList *lockList = NULL; static gchar *getLockFile(const HostNode *n) { gchar *lockfile = NULL; lockfile = g_strdup_printf("%s.lck", n->statsfile); return(lockfile); } int setLockForHost(HostNode *n) { int r; gchar *lockfile = NULL; if(!(lockfile = getLockFile(n))) { g_error(_("Can't get the name of the lock file!")); return(EXIT_FAILURE); } if(n->fdlock < 0) { if((n->fdlock = open(lockfile, O_CREAT|O_RDWR, S_IRUSR|S_IWUSR))< 0) { g_error("%s: %s", lockfile, strerror(errno)); g_free(lockfile); return(EXIT_FAILURE); } fcntl(n->fdlock, F_SETFD, FD_CLOEXEC | fcntl(n->fdlock, F_GETFD)); } #ifdef HAVE_FLOCK lockList = g_list_prepend(lockList, n); do { r = flock(n->fdlock, LOCK_EX | LOCK_NB); } while((r==-1) && (errno == EINTR)); if((r==-1) && (errno != EWOULDBLOCK)) { g_error(_("Failed to get lockfile %s: %s"), lockfile, g_strerror(errno)); } #else g_warning(_("Can't lock to file %s because function flock() is missing!"), lockfile); g_free(lockfile); return(EXIT_FAILURE); #endif g_free(lockfile); if(r == -1) { lockList = g_list_remove(lockList, n); close(n->fdlock); n->fdlock = -1; } return(r); } int unsetLockForHost(HostNode *n) { int r; if(n->fdlock < 0) { return(EXIT_FAILURE); } #ifdef HAVE_FLOCK r = flock(n->fdlock, LOCK_UN); lockList = g_list_remove(lockList, n); #else r = EXIT_SUCCESS; #endif close(n->fdlock); n->fdlock = -1; return(r); } static void cleanupLock(gpointer data, gpointer user_data) { unsetLockForHost((HostNode *)data); } void cleanupLocks() { g_list_foreach(lockList, cleanupLock, NULL); } apt-dater-0.9.0/src/lock.h0000644000175000017500000000215711760757134014661 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _LOCK_H #define _LOCK_H int setLockForHost(HostNode *); int unsetLockForHost(HostNode *); void cleanupLocks(); #endif /* _LOCK_H */ apt-dater-0.9.0/src/parsecmd.c0000644000175000017500000000472511760757134015525 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif #include "apt-dater.h" #include "parsecmd.h" #include "ui.h" gchar *parse_string(const gchar *src, const HostNode *n) { if(!n) return g_strdup(src); gint i = 0; GString *h = g_string_sized_new(strlen(src)); while(src[i]) { if((src[i] != '%') || (src[i+1] == 0)) { g_string_append_c(h, src[i++]); continue; } i++; switch(src[i]) { case 'h': g_string_append(h, n->hostname); break; case 'H': g_string_append(h, n->hostname); if(n->ssh_port) { g_string_append(h, ":"); g_string_append_printf(h, "%d", n->ssh_port); } break; case 'u': g_string_append(h, n->ssh_user); break; case 'U': if(n->ssh_user) { g_string_append(h, n->ssh_user); g_string_append(h, "@"); } break; case 'p': g_string_append_printf(h, "%d", n->ssh_port); break; case 'm': g_string_append(h, maintainer); break; default: g_string_append_c(h, src[i]); continue; } i++; } return g_string_free(h, FALSE); } gboolean parse_cmdline(const char *s, int *argcPtr, char ***argvPtr, const HostNode *n) { gint i; const gchar **argv; if(poptParseArgvString(s, argcPtr, &argv) < 0) return FALSE; *argvPtr = g_new0(char*, *argcPtr+1); if(n) for(i=0;i<*argcPtr;i++) (*argvPtr)[i] = parse_string(argv[i], n); return TRUE; } apt-dater-0.9.0/src/parsecmd.h0000644000175000017500000000232011760757134015517 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _PARSECMD_H #define _PARSECMD_H #include "apt-dater.h" gchar *parse_string(const gchar *src, const HostNode *n); gboolean parse_cmdline(const char *s, int *argcPtr, char *** argvPtr, const HostNode *n); #endif /* _PARSECMD_H */ apt-dater-0.9.0/src/report.c0000644000175000017500000002030311760757134015230 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "ui.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_XMLREPORT #include #include #include static xmlTextWriterPtr writer; static xmlDocPtr doc; #ifdef FEAT_HISTORY #include "history.h" #endif void initReport(GList *hosts) { /* * this initialize the library and check potential ABI mismatches * between the version it was compiled for and the actual shared * library used. */ LIBXML_TEST_VERSION writer = xmlNewTextWriterDoc(&doc, 0); if (writer == NULL) g_error(_("Error creating the xml output.")); xmlTextWriterStartDocument(writer, NULL, NULL, NULL); if(!hosts) return; fprintf(stderr, _("apt-dater is refreshing %d hosts, please standby...\n"), g_list_length(hosts)); GList *n = hosts; while(n) { ((HostNode *)n->data)->category = C_REFRESH_REQUIRED; n = g_list_next(n); } } #ifdef FEAT_HISTORY static void reportHistory(gpointer data, gpointer user_data) { HistoryEntry *h = (HistoryEntry *)data; xmlTextWriterStartElement(writer, BAD_CAST(h->action)); xmlTextWriterWriteFormatElement(writer, BAD_CAST("timestamp"), "%d", (int)h->ts); xmlTextWriterWriteFormatElement(writer, BAD_CAST("duration"), "%d", h->duration); xmlTextWriterStartElement(writer, BAD_CAST("path")); xmlTextWriterWriteString(writer, BAD_CAST(h->path)); xmlTextWriterEndElement(writer); if(h->maintainer && strlen(h->maintainer)) { xmlTextWriterStartElement(writer, BAD_CAST("maintainer")); xmlTextWriterWriteString(writer, BAD_CAST(h->maintainer)); xmlTextWriterEndElement(writer); } xmlTextWriterEndElement(writer); } #endif #ifdef FEAT_CLUSTERS static void reportCluster(gpointer data, gpointer user_data) { xmlTextWriterWriteFormatElement(writer, BAD_CAST("member-of"), "%s", (gchar *)data); } #endif static void reportPackage(gpointer data, gpointer user_data) { PkgNode *n = (PkgNode *)data; xmlTextWriterStartElement(writer, BAD_CAST("pkg")); xmlTextWriterWriteAttribute(writer, BAD_CAST("name"), BAD_CAST(n->package)); xmlTextWriterWriteAttribute(writer, BAD_CAST("version"), BAD_CAST(n->version)); if(n->flag & HOST_STATUS_PKGUPDATE) xmlTextWriterWriteAttribute(writer, BAD_CAST("hasupdate"), BAD_CAST("1")); if(n->flag & HOST_STATUS_PKGKEPTBACK) xmlTextWriterWriteAttribute(writer, BAD_CAST("onhold"), BAD_CAST("1")); if(n->flag & HOST_STATUS_PKGEXTRA) xmlTextWriterWriteAttribute(writer, BAD_CAST("extra"), BAD_CAST("1")); if(n->flag & HOST_STATUS_PKGBROKEN) xmlTextWriterWriteAttribute(writer, BAD_CAST("broken"), BAD_CAST("1")); if(n->data) xmlTextWriterWriteAttribute(writer, BAD_CAST("data"), BAD_CAST(n->data)); xmlTextWriterEndElement(writer); } static void reportHost(gpointer data, gpointer lgroup) { HostNode *n = (HostNode *)data; if(*(char **)lgroup == NULL || strcmp(*(char **)lgroup, n->group)) { if(*(char **)lgroup) xmlTextWriterEndElement(writer); xmlTextWriterStartElement(writer, BAD_CAST("group")); xmlTextWriterWriteAttribute(writer, BAD_CAST("name"), BAD_CAST(n->group)); *(char **)lgroup = n->group; } /* Begin host element. */ xmlTextWriterStartElement(writer, BAD_CAST("host")); xmlTextWriterWriteAttribute(writer, BAD_CAST("hostname"), BAD_CAST(n->hostname)); #ifdef FEAT_TCLFILTER if(n->filtered) xmlTextWriterWriteAttribute(writer, BAD_CAST("filtered"), BAD_CAST("1")); #endif /* Status */ xmlTextWriterStartElement(writer, BAD_CAST("status")); xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("status"), "%d", n->category); xmlTextWriterWriteString(writer, BAD_CAST(drawCategories[n->category])); xmlTextWriterEndElement(writer); /* SSH config */ xmlTextWriterStartElement(writer, BAD_CAST("ssh")); if(n->ssh_user) xmlTextWriterWriteElement(writer, BAD_CAST("user"), BAD_CAST(n->ssh_user)); if(n->ssh_port) xmlTextWriterWriteFormatElement(writer, BAD_CAST("port"), "%d", n->ssh_port); xmlTextWriterEndElement(writer); /* Kernel info */ xmlTextWriterStartElement(writer, BAD_CAST("kernel")); if(n->status & HOST_STATUS_KERNELNOTMATCH) xmlTextWriterWriteAttribute(writer, BAD_CAST("reboot"), BAD_CAST("1")); if(n->status & HOST_STATUS_KERNELSELFBUILD) xmlTextWriterWriteAttribute(writer, BAD_CAST("custom"), BAD_CAST("1")); if(n->kernelrel) xmlTextWriterWriteString(writer, BAD_CAST(n->kernelrel)); xmlTextWriterEndElement(writer); /* LSB info */ xmlTextWriterStartElement(writer, BAD_CAST("lsb")); if(n->lsb_distributor) xmlTextWriterWriteElement(writer, BAD_CAST("distri"), BAD_CAST(n->lsb_distributor)); if(n->lsb_release) xmlTextWriterWriteElement(writer, BAD_CAST("release"), BAD_CAST(n->lsb_release)); if(n->lsb_codename) xmlTextWriterWriteElement(writer, BAD_CAST("codename"), BAD_CAST(n->lsb_codename)); xmlTextWriterEndElement(writer); /* UNAME info */ xmlTextWriterStartElement(writer, BAD_CAST("uname")); if(n->uname_kernel) xmlTextWriterWriteElement(writer, BAD_CAST("kernel"), BAD_CAST(n->uname_kernel)); if(n->uname_machine) xmlTextWriterWriteElement(writer, BAD_CAST("machine"), BAD_CAST(n->uname_machine)); xmlTextWriterEndElement(writer); /* virtualization info */ if(n->virt) xmlTextWriterWriteElement(writer, BAD_CAST("virt"), BAD_CAST(n->virt)); else xmlTextWriterWriteElement(writer, BAD_CAST("virt"), BAD_CAST("Unknown")); /* host UUID */ if(n->uuid) xmlTextWriterWriteElement(writer, BAD_CAST("uuid"), BAD_CAST(n->uuid)); #ifdef FEAT_HISTORY /* history data */ GList *hel = history_get_entries(n); if(hel) { xmlTextWriterStartElement(writer, BAD_CAST("history")); g_list_foreach(hel, reportHistory, NULL); xmlTextWriterEndElement(writer); history_free_hel(hel); } #endif #ifdef FEAT_CLUSTERS /* clusters data */ if(n->clusters) { xmlTextWriterStartElement(writer, BAD_CAST("clusters")); g_list_foreach(n->clusters, reportCluster, NULL); xmlTextWriterEndElement(writer); } #endif /* Packages */ xmlTextWriterStartElement(writer, BAD_CAST("packages")); g_list_foreach(n->packages, reportPackage, NULL); xmlTextWriterEndElement(writer); xmlTextWriterEndElement(writer); } gboolean ctrlReport(GList *hosts) { gint torefresh = 0; char *lgroup = NULL; g_usleep(G_USEC_PER_SEC); GList *n = hosts; while(n) { if( (((HostNode *)n->data)->category == C_REFRESH_REQUIRED) || (((HostNode *)n->data)->category == C_REFRESH) ) torefresh++; n = g_list_next(n); } if(torefresh == 0) { /* Create root node. */ xmlTextWriterStartElement(writer, BAD_CAST("report")); xmlTextWriterWriteFormatElement(writer, BAD_CAST("timestamp"), "%d", (int)time(NULL)); /* Put node stats to file. */ g_list_foreach(hosts, reportHost, &lgroup); /* Close open host element. */ if(lgroup) xmlTextWriterEndElement(writer); /* Close root node and finalize document. */ xmlTextWriterEndElement(writer); xmlTextWriterEndDocument(writer); xmlFreeTextWriter(writer); xmlSaveCtxtPtr save = xmlSaveToFd(fileno(stdout), NULL, XML_SAVE_FORMAT); xmlSaveDoc(save, doc); xmlSaveClose(save); xmlFreeDoc(doc); g_main_loop_quit (loop); fprintf(stderr, "\ndone\n"); } return torefresh > 0; } #endif apt-dater-0.9.0/src/report.h0000644000175000017500000000227111760757134015241 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _REPORT_H #define _REPORT_H #include #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_XMLREPORT void initReport(GList *); gboolean ctrlReport (GList *); #endif #endif /* _REPORT_H */ apt-dater-0.9.0/src/screen.c0000644000175000017500000001062511760757134015202 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include #include #include #include #include #include #ifdef HAVE_CONFIG_H # include "config.h" #endif #include "screen.h" #include "parsecmd.h" #include "history.h" static struct passwd *pw = NULL; const static gchar * screen_get_sdir() { static gchar sdir[256]; if (!pw) pw = getpwuid(getuid()); if (!pw) return NULL; g_snprintf(sdir, sizeof(sdir), SCREEN_SDFORMT, SCREEN_SOCKPATH, pw->pw_name); return sdir; } gboolean screen_get_sessions(HostNode *n) { if (n->screens) { g_list_free(n->screens); n->screens = NULL; } const gchar *sdir = screen_get_sdir(); if (!sdir) return FALSE; GDir *d = g_dir_open(sdir, 0, NULL); if (!d) { return FALSE; } gchar *search = g_strdup_printf(SCREEN_SOCKPRE"%s_%s_%d", n->ssh_user, n->hostname, n->ssh_port); const gchar *f; while ((f = g_dir_read_name(d))) { gchar *fn = g_strdup_printf("%s/%s", sdir, f); if (g_file_test(fn, G_FILE_TEST_EXISTS)) { gint pid = atoi(f); char *name = strchr(f, '.'); if ((pid > 1) && (name) && (strcmp(name+1, search) == 0)) { SessNode *s = g_new0(SessNode, 1); #ifndef NDEBUG s->_type = T_SESSNODE; #endif s->pid = pid; stat(fn, &s->st); n->screens = g_list_prepend(n->screens, s); } } g_free(fn); } g_dir_close(d); g_free(search); return g_list_length(n->screens) > 0; } gchar * screen_new(HostNode *n, const gboolean detached) { gchar *title = parse_string(cfg->screentitle, n); gchar *cmd = g_strdup_printf(SCREEN_BINARY"+-%sS+"SCREEN_SOCKPRE"%s_%s_%d" \ "+-t+%s+-c+%s+", detached ? "dm" : "", n->ssh_user, n->hostname, n->ssh_port, title, cfg->screenrcfile); g_free(title); return cmd; } static gchar * screen_attach_cmd(const SessNode *s, const gboolean shared) { return g_strdup_printf(SCREEN_BINARY"+-r%s+%d+", shared ? "x" : "", s->pid); } gboolean screen_attach(HostNode *n, const SessNode *s, const gboolean shared) { gboolean r; GError *error = NULL; gchar *cmd = screen_attach_cmd(s, shared); gchar **argv = NULL; g_assert(n); argv = g_strsplit(cmd, "+", 0); r = g_spawn_sync(g_getenv ("HOME"), argv, NULL, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } g_free(cmd); g_strfreev(argv); #ifdef FEAT_HISTORY if(n->parse_result && !screen_get_sessions(n)) { n->parse_result = FALSE; return history_ts_failed(n); } #endif return FALSE; } static gchar * screen_dump_cmd(const SessNode *s, const gchar *fn) { return g_strdup_printf(SCREEN_BINARY"+-S+%d+-X+hardcopy+%s", s->pid, fn); } gchar * screen_get_dump(const SessNode *s) { gboolean r; GError *error = NULL; gchar **argv = NULL; gchar *dump_fn = g_strdup_printf("%s/dump-XXXXXX", g_get_tmp_dir()); gint fd = g_mkstemp(dump_fn); if(fd == -1) return NULL; gchar *cmd = screen_dump_cmd(s, dump_fn); if(!cmd) { g_unlink(dump_fn); close(fd); return NULL; } argv = g_strsplit(cmd, "+", 0); r = g_spawn_sync(g_getenv ("HOME"), argv, NULL, G_SPAWN_CHILD_INHERITS_STDIN, NULL, NULL, NULL, NULL, NULL, &error); if(r == FALSE) { g_warning("%s", error->message); g_clear_error (&error); } g_free(cmd); g_strfreev(argv); gchar *c = NULL; g_file_get_contents(dump_fn, &c, NULL, NULL); close(fd); g_unlink(dump_fn); return c; } apt-dater-0.9.0/src/screen.h0000644000175000017500000000276311760757134015213 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _SCREEN_H #define _SCREEN_H #include "apt-dater.h" #include "history.h" #define SCREEN_SDFORMT "%s/S-%s" #define SCREEN_SOCKPRE "apt-dater_" gboolean screen_get_sessions(HostNode *n); gchar *screen_new(HostNode *n, const gboolean detached); gboolean screen_attach(HostNode *n, const SessNode *s, const gboolean shared); gchar *screen_get_dump(const SessNode *s); static inline gboolean screen_is_attached(const SessNode *s) { if (s->st.st_mode & S_IXUSR) return TRUE; return FALSE; } #endif /* _SCREEN_H */ apt-dater-0.9.0/src/sighandler.c0000644000175000017500000000340411760757134016040 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "ui.h" #include "sighandler.h" #include "lock.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif static volatile int sigintcnt = 0; static gboolean ignsigint = FALSE; static RETSIGTYPE sigintSigHandler(int sig) { switch(sig) { case SIGINT: if(ignsigint == TRUE) break; if (sigintcnt++ > 1) { cleanUI(); cleanupLocks(); exit(EXIT_FAILURE); } else { cleanUI(); refreshUI(); g_main_loop_quit (loop); } break; } /* switch(sig) */ } static RETSIGTYPE sigtermSigHandler() { cleanUI(); refreshUI(); g_main_loop_quit (loop); } void setSigHandler() { signal(SIGINT, sigintSigHandler); signal(SIGTERM, sigtermSigHandler); } void ignoreSIGINT(gboolean ign) { /* Disable SIGINT for before use exec. */ ignsigint=ign; } apt-dater-0.9.0/src/sighandler.h0000644000175000017500000000216211760757134016045 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _SIGHANDLER_H #define _SIGHANDLER_H #include void setSigHandler(); void ignoreSIGINT(gboolean); #endif /* SIGHANDLER_H */ apt-dater-0.9.0/src/stats.c0000644000175000017500000002552611760757134015067 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include #include "apt-dater.h" #include "exec.h" #include "screen.h" #include "stats.h" #include "lock.h" #include "autoref.h" #include "clusters.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif gchar *getStatsFile(const HostNode *n) { if(g_file_test(n->statsfile, G_FILE_TEST_IS_REGULAR | G_FILE_TEST_EXISTS) == FALSE) return NULL; return n->statsfile; } gboolean prepareStatsFile(HostNode *n) { g_unlink(n->statsfile); n->fpstat = fopen(n->statsfile, "wx"); return n->fpstat != NULL; } void refreshStatsOfNode(gpointer n) { if( ((HostNode *)n)->fpstat ) { fclose(((HostNode *)n)->fpstat); ((HostNode *)n)->fpstat = NULL; } getUpdatesFromStat(((HostNode *) n)); unsetLockForHost((HostNode *) n); rebuilddl = TRUE; /* Trigger a DrawList rebuild */ } gboolean setStatsFileFromIOC(GIOChannel *ioc, GIOCondition condition, gpointer n) { gchar *buf = NULL; GError *error = NULL; gsize bytes; gboolean r = TRUE; GIOStatus iostatus = G_IO_STATUS_NORMAL; if(!n) return(FALSE); if (condition & (G_IO_HUP | G_IO_PRI | G_IO_IN)) { buf = (gchar *) g_malloc0 (g_io_channel_get_buffer_size (ioc) + 1); r = FALSE; while(iostatus == G_IO_STATUS_NORMAL && ((HostNode *) n)->fpstat) { iostatus = g_io_channel_read_chars (ioc, buf, g_io_channel_get_buffer_size (ioc), &bytes, NULL); if(iostatus == G_IO_STATUS_ERROR || iostatus == G_IO_STATUS_AGAIN) break; if(*buf == 0) condition = G_IO_HUP; if(fwrite(buf, sizeof(gchar), bytes, ((HostNode *) n)->fpstat) != bytes) break; r = TRUE; } if(r == TRUE) fflush(((HostNode *) n)->fpstat); g_free(buf); } if (condition & (G_IO_HUP | G_IO_ERR | G_IO_NVAL)) { g_io_channel_unref (ioc); if(g_io_channel_shutdown (ioc, TRUE, &error) == G_IO_STATUS_ERROR) { g_warning("%s", error->message); g_clear_error (&error); } r = FALSE; } return(r); } void freePkgNode(PkgNode *n) { if(n) { g_free(n->package); g_free(n->version); if(n->data) g_free(n->data); g_free(n); } } static void freePackages(HostNode *n) { if(n && n->packages) { #ifdef FEAT_AUTOREF autoref_rem_host_info(n); #endif g_list_foreach(n->packages, (GFunc) freePkgNode, NULL); g_list_free(n->packages); n->packages = NULL; } } static gint cmpPackages(gconstpointer a, gconstpointer b) { return((((PkgNode *)a)->flag != ((PkgNode *)b)->flag) ? ((PkgNode *)a)->flag - ((PkgNode *)b)->flag : g_ascii_strcasecmp(((PkgNode *)a)->package, ((PkgNode *)b)->package)); } gboolean getUpdatesFromStat(HostNode *n) { char line[STATS_MAX_LINE_LEN]; char buf[256] = "\0"; FILE *fp; PkgNode *pkgnode = NULL; gint status=0, i; gchar **argv = NULL; gboolean adproto = FALSE; gfloat adpver = 0; gboolean adperr = FALSE; if(!n) return (FALSE); if(!getStatsFile(n)) { n->category = C_UNKNOWN; return (TRUE); } #ifdef FEAT_AUTOREF struct stat sbuf; if(!stat(n->statsfile, &sbuf)) n->last_upd = sbuf.st_mtime; #endif if(!(fp = (FILE *) g_fopen(n->statsfile, "r"))) { n->category = C_UNKNOWN; return (TRUE); } n->status = 0; n->nupdates = 0; n->nextras = 0; n->nholds = 0; n->nbrokens = 0; n->forbid = 0; n->uuid[0] = 0; freePackages(n); if(n->lsb_distributor) { g_free(n->lsb_distributor); n->lsb_distributor = NULL; } if(n->lsb_release) { g_free(n->lsb_release); n->lsb_release = NULL; } if(n->lsb_codename) { g_free(n->lsb_codename); n->lsb_codename = NULL; } if(n->uname_kernel) { g_free(n->uname_kernel); n->uname_kernel = NULL; } if(n->uname_machine) { g_free(n->uname_machine); n->uname_machine = NULL; } if(n->virt) { g_free(n->virt); n->virt = NULL; } if(n->adperr) { g_free(n->adperr); n->adperr = NULL; } if(n->kernelrel) { g_free(n->kernelrel); n->kernelrel = NULL; } #ifdef FEAT_CLUSTERS cluster_host_reset(n); #endif int linesok = 0; while(fgets(line, STATS_MAX_LINE_LEN, fp)) { /* Remove any whitespace from the line. */ g_strchomp(line); if (sscanf((gchar *) line, ADP_PATTERN_KERNELINFO, &status, buf) && !n->kernelrel) { n->kernelrel = g_strdup(buf); switch(status){ case 1: n->status = n->status | HOST_STATUS_KERNELNOTMATCH; break; case 2: n->status = n->status | HOST_STATUS_KERNELSELFBUILD; break; } linesok++; continue; } if(sscanf(line, ADP_PATTERN_ADPROTO, &adpver)) { adproto = TRUE; continue; } if(!strncmp("STATUS: ", line, 8)) { argv = g_strsplit(&line[8], "|", 0); if(!argv) continue; i=0; while(argv[i]) i++; /* ignore invalid lines */ if(i < 3) { g_strfreev(argv); continue; } pkgnode = g_new0(PkgNode, 1); #ifndef NDEBUG pkgnode->_type = T_PKGNODE; #endif pkgnode->package = g_strdup(argv[0]); pkgnode->version = g_strdup(argv[1]); if (strlen(argv[2]) > 3) pkgnode->data = g_strdup(&argv[2][2]); switch(argv[2][0]) { case 'u': n->status = n->status | HOST_STATUS_PKGUPDATE; pkgnode->flag = HOST_STATUS_PKGUPDATE; n->nupdates++; break; case 'h': n->status = n->status | HOST_STATUS_PKGKEPTBACK; pkgnode->flag = HOST_STATUS_PKGKEPTBACK; n->nholds++; break; case 'x': n->status = n->status | HOST_STATUS_PKGEXTRA; pkgnode->flag = HOST_STATUS_PKGEXTRA; n->nextras++; break; case 'b': n->status = n->status | HOST_STATUS_PKGBROKEN; pkgnode->flag = HOST_STATUS_PKGBROKEN; n->nbrokens++; break; case 'i': break; default: g_free(pkgnode->package); g_free(pkgnode->version); g_free(pkgnode); g_strfreev(argv); continue; } g_strfreev(argv); n->packages = g_list_insert_sorted(n->packages, pkgnode, cmpPackages); linesok++; continue; } if(!strncmp("LSBREL: ", line, 8)) { argv = g_strsplit(&line[8], "|", 0); if(!argv) continue; i=0; while(argv[i]) i++; /* ignore invalid lines */ if(i < 3) { g_strfreev(argv); continue; } if(strlen(argv[0]) > 0) { n->lsb_distributor = g_strdup(argv[0]); n->lsb_release = g_strdup(argv[1]); n->lsb_codename = g_strdup(argv[2]); } g_strfreev(argv); linesok++; continue; } if (sscanf((gchar *) line, ADP_PATTERN_VIRT, buf)) { n->virt = g_strdup(buf); if (strcmp(n->virt, "Unknown") && strcmp(n->virt, "Physical")) n->status = n->status | HOST_STATUS_VIRTUALIZED; linesok++; continue; } if (sscanf((gchar *) line, ADP_PATTERN_ADPERR, buf)) { n->adperr = g_strdup(buf); adperr = TRUE; continue; } if (sscanf((gchar *) line, ADP_PATTERN_UNAME, buf)) { gchar *s = strchr(buf, '|'); if (s) { s[0] = 0; n->uname_kernel = g_strdup(buf); n->uname_machine = g_strdup(s+1); linesok++; } continue; } if (sscanf((gchar *) line, ADP_PATTERN_FORBID, &n->forbid)) continue; if (sscanf((gchar *) line, "UUID: %" QUOTE(UUID_STRLEN) "s", n->uuid)) { n->uuid[UUID_STRLEN-1] = 0; linesok++; continue; } #ifdef FEAT_CLUSTERS char cluster[ADP_STRLEN_CLUSTER]; if (sscanf((gchar *) line, ADP_PATTERN_CLUSTER, cluster)) { cluster[ADP_STRLEN_CLUSTER-1] = 0; cluster_host_add(n, cluster); linesok++; continue; } #endif } if((!adproto && linesok > 10) || (adproto && adpver < ADP_FEATVER_ADPERR && linesok > 10) || (adproto && adpver >= ADP_FEATVER_ADPERR && !adperr)) { if (n->status & HOST_STATUS_PKGBROKEN) n->category = C_BROKEN_PKGS; else if(n->status & HOST_STATUS_PKGUPDATE) n->category = C_UPDATES_PENDING; else n->category = C_UP_TO_DATE; #ifdef FEAT_AUTOREF autoref_add_host_info(n); #endif } else n->category = C_UNKNOWN; fclose(fp); return(TRUE); } gchar *getStatsContent(const HostNode *n) { gchar *c = NULL; if(!g_file_get_contents(n->statsfile, &c, NULL, NULL)) return NULL; return c; } gboolean refreshStats(GList *hosts) { GList *ho; gboolean r = TRUE; static gboolean upd_pending = FALSE; gboolean n_upd_pending = FALSE; ho = g_list_first(hosts); #ifdef FEAT_AUTOREF static gboolean do_autoref = TRUE; gint num_in_refresh = 0; #endif while(ho) { HostNode *n = (HostNode *) ho->data; if(screen_get_sessions(n)) { if(n->category != C_SESSIONS) { n->category = C_SESSIONS; rebuilddl = TRUE; } } else { if(n->category == C_UPDATES_PENDING) n_upd_pending = TRUE; if (n->category == C_SESSIONS) n->category = C_REFRESH_REQUIRED; if(n->category == C_REFRESH_REQUIRED) { /* Try to get a lock for the host. */ gint rsetlck = setLockForHost(n); /* We don't got the lock. */ if(rsetlck == -1) { n->status|= HOST_STATUS_LOCKED; freePackages(n); } /* We got the lock. */ else if (rsetlck == 0) { if(n->status & HOST_STATUS_LOCKED) { refreshStatsOfNode(n); /* n->status ^= HOST_STATUS_LOCKED; */ } else { n->category = C_REFRESH; rebuilddl = TRUE; freePackages(n); if(ssh_cmd_refresh(n) == FALSE) { n->category = C_UNKNOWN; } } /* Something weird happend. */ } else { n->category = C_UNKNOWN; rebuilddl = TRUE; } } } #ifdef FEAT_AUTOREF if(n->category == C_REFRESH) num_in_refresh++; #endif ho = g_list_next(ho); } #ifdef FEAT_TCLFILTER applyFilter(hosts); #endif if(n_upd_pending && !upd_pending) notifyUser(); upd_pending = n_upd_pending; #ifdef FEAT_AUTOREF if(cfg->auto_refresh) { if (num_in_refresh == 0) { if(do_autoref) { if (autoref_trigger_auto()) drawStatus (_("Auto refresh triggered..."), FALSE); do_autoref = FALSE; } } else do_autoref = TRUE; } #endif return(r); } void getOldestMtime(GList *hosts) { GList *ho; struct stat stat_p; HostNode *n; oldest_st_mtime = time(NULL); ho = g_list_first(hosts); while(ho) { n = (HostNode *) ho->data; if(getStatsFile(n)) { if(!stat(n->statsfile, &stat_p)) { if(difftime(stat_p.st_mtime, oldest_st_mtime) < 0) oldest_st_mtime = stat_p.st_mtime; } } ho = g_list_next(ho); } } apt-dater-0.9.0/src/stats.h0000644000175000017500000000267011760757134015067 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _STATS_H #define _STATS_H #include #include "apt-dater.h" void getOldestMtime(GList *hosts); void freeUpdates(GList *updates); gboolean refreshStats(GList *); gboolean setStatsFileFromIOC(GIOChannel *, GIOCondition, gpointer); gchar *getStatsFileName(const HostNode *); gboolean prepareStatsFile(HostNode *); gboolean getUpdatesFromStat(HostNode *); void refreshStatsOfNode(gpointer); gchar *getStatsContent(const HostNode *); #endif /* _STATS_H */ apt-dater-0.9.0/src/tag.c0000644000175000017500000001071511760757134014476 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include "apt-dater.h" #include "tag.h" #include "ui.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif #include typedef enum { COMPCMD_ALL, COMPCMD_CODENAME, COMPCMD_DISTRIBUTOR, COMPCMD_GROUP, COMPCMD_PACKAGE, COMPCMD_UPDATE, COMPCMD_HOSTNAME, COMPCMD_FLAG, #ifdef FEAT_CLUSTERS COMPCMD_CLUSTERS, #endif } COMPCMD; struct ValidCompCmds { gchar c; gchar *name; COMPCMD cmd; }; static struct ValidCompCmds compCmds[] = { {'A', "all", COMPCMD_ALL}, {'d', "distributor", COMPCMD_DISTRIBUTOR}, {'c', "codename", COMPCMD_CODENAME}, {'g', "group", COMPCMD_GROUP}, {'h', "hostname", COMPCMD_HOSTNAME}, {'p', "package", COMPCMD_PACKAGE}, {'u', "update" , COMPCMD_UPDATE}, {'f', "flag" , COMPCMD_FLAG}, #ifdef FEAT_CLUSTERS {'C', "cluster" , COMPCMD_CLUSTERS}, #endif { 0, NULL, 0}, }; static gboolean compStrWithPattern(const gchar *str, gchar *pattern, gsize s) { gboolean r = FALSE; if(!str || !pattern) return FALSE; #if (GLIB_MAJOR_VERSION >= 2 && GLIB_MINOR_VERSION >= 14) GRegex *regex = g_regex_new (pattern, G_REGEX_CASELESS, 0, NULL); if(regex) { r = g_regex_match (regex, str, 0, NULL); g_regex_unref (regex); } #else gsize maxsize; gint i; maxsize = s > strlen(pattern) ? strlen(pattern) : s; for(i=0; i= maxsize;i++) if(!g_ascii_strncasecmp (&str[i], pattern, maxsize)) { r = TRUE; break; } #endif return r; } gboolean compHostWithPattern(HostNode *n, gchar *in, gsize s) { gboolean r = FALSE; gchar *pattern = NULL; gint i, j, compflags = 0; COMPCMD compcmd = COMPCMD_HOSTNAME; if(!in || !n || strlen(in) < 1) return FALSE; if(g_str_has_prefix(in, "~") == TRUE && strlen(in) >= 2) { /* Check if is a valid compare command identifier. */ for(i=0; compCmds[i].name;i++) { if(compCmds[i].c == in[1]) { compcmd = compCmds[i].cmd; break; } } if(!compCmds[i].name) return FALSE; /* No valid compare command! */ else pattern = g_strdup(&in[2]); } else pattern = g_strdup(in); if(!pattern) return FALSE; g_strchug(pattern); switch(compcmd) { case COMPCMD_UPDATE: case COMPCMD_PACKAGE: { GList *p = g_list_first(n->packages); while(p) { PkgNode *pn = p->data; if((compcmd == COMPCMD_UPDATE ? pn->flag & HOST_STATUS_PKGUPDATE : TRUE) && compStrWithPattern(pn->package, pattern, s) == TRUE) { r = TRUE; break; } p = g_list_next(p); } } break; /* case COMPCMD_UPDATE */ case COMPCMD_ALL: r = TRUE; break; case COMPCMD_DISTRIBUTOR: r = n->lsb_distributor ? compStrWithPattern(n->lsb_distributor, pattern, s) : FALSE; break; case COMPCMD_CODENAME: r = n->lsb_codename ? compStrWithPattern(n->lsb_codename, pattern, s) : FALSE; break; case COMPCMD_GROUP: r = compStrWithPattern(n->group, pattern, s); break; case COMPCMD_FLAG: compflags=0; for(i = 0; i < (strlen(pattern) > s ? s : strlen(pattern)); i++) { j=0; while(hostFlags[j].code) { if(hostFlags[j].code[0] == pattern[i]) compflags |= hostFlags[j].flag; j++; } } if(n->status - (n->status ^ compflags) == compflags) r = TRUE; break; #ifdef FEAT_CLUSTERS case COMPCMD_CLUSTERS: { GList *c = n->clusters; while(c != NULL) { if(compStrWithPattern(c->data, pattern, s) == TRUE) { r = TRUE; break; } c = c->next; } } break; #endif case COMPCMD_HOSTNAME: default: r = compStrWithPattern(n->hostname, pattern, s); } /* switch */ g_free(pattern); return r; } apt-dater-0.9.0/src/tag.h0000644000175000017500000000203311760757134014475 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ gboolean compHostWithPattern(HostNode *, gchar *, gsize); apt-dater-0.9.0/src/ui.c0000644000175000017500000025046411760757134014347 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #include #include #include #include #include #include #include "apt-dater.h" #include "ui.h" #include "colors.h" #include "screen.h" #include "exec.h" #include "stats.h" #include "keyfiles.h" #include "tag.h" #include "sighandler.h" #ifdef HAVE_CONFIG_H # include "config.h" #endif #ifdef FEAT_TCLFILTER #include #endif static GList *drawlist = NULL; gchar *drawCategories[] = { N_("Updates pending"), N_("Up to date"), N_("Broken packages"), N_("Refresh required"), N_("In refresh"), N_("Sessions"), #ifdef FEAT_TCLFILTER N_("Filtered"), #endif N_("Unknown"), NULL}; static gchar *incategory = NULL; static gchar *ingroup = NULL; static HostNode *inhost = NULL; static gint bottomDrawLine; static WINDOW *win_dump = NULL; static gboolean dump_screen = FALSE; gchar maintainer[48]; #ifdef FEAT_TCLFILTER gchar filterexp[BUF_MAX_LEN]; #endif gint sc_mask = 0; static GCompletion* dlCompl = NULL; #ifdef FEAT_TCLFILTER static Tcl_Interp *tcl_interp = NULL; #endif #ifdef FEAT_TCLFILTER typedef enum { TCLM_STRING, TCLM_INT, TCLM_IGNORE, } ETCLMAPPING; typedef enum { TCLMK_CATEGORY, TCLMK_GROUP, TCLMK_HOSTNAME, TCLMK_KERNEL, TCLMK_LSBCNAME, TCLMK_LSBDISTRI, TCLMK_LSBREL, TCLMK_UNKERNEL, TCLMK_UNMACHINE, TCLMK_VIRT, TCLMK_FORBID, #ifdef FEAT_CLUSTERS TCLMK_CLUSTERS, #endif TCLMK_EXTRAS, TCLMK_FLAGS, TCLMK_HOLDS, TCLMK_INSTALLED, TCLMK_UPDATES, TCLMK_BROKENS, } ETCLMAPKEYS; struct TCLMapping { gint code; gchar *name; ETCLMAPPING type; }; const static struct TCLMapping tclmap[] = { {TCLMK_CATEGORY , "cat" , TCLM_INT}, {TCLMK_GROUP , "group" , TCLM_STRING}, {TCLMK_HOSTNAME , "hostname" , TCLM_STRING}, {TCLMK_KERNEL , "kernel" , TCLM_STRING}, {TCLMK_LSBCNAME , "lsb_cname" , TCLM_STRING}, {TCLMK_LSBDISTRI, "lsb_distri", TCLM_STRING}, {TCLMK_LSBREL , "lsb_rel" , TCLM_STRING}, {TCLMK_VIRT , "virt" , TCLM_STRING}, {TCLMK_FORBID , "forbid" , TCLM_INT}, #ifdef FEAT_CLUSTERS {TCLMK_CLUSTERS , "clusters" , TCLM_IGNORE}, #endif {TCLMK_EXTRAS , "extras" , TCLM_IGNORE}, {TCLMK_FLAGS , "flags" , TCLM_IGNORE}, {TCLMK_HOLDS , "holds" , TCLM_IGNORE}, {TCLMK_INSTALLED, "installed" , TCLM_IGNORE}, {TCLMK_UPDATES , "updates" , TCLM_IGNORE}, {TCLMK_BROKENS , "brokens" , TCLM_IGNORE}, {0 , NULL, 0}, }; #endif struct ShortCut { EShortCuts sc; int keycode; gchar *key; gchar *descr; gboolean visible; EVisKeyMask id; }; static struct ShortCut shortCuts[] = { {SC_KEY_LEFT, KEY_LEFT, N_(""), N_("shrink node") , FALSE, 0}, {SC_KEY_LEFT2, 'h', "h", N_("shrink node") , FALSE, 0}, {SC_KEY_RIGHT, KEY_RIGHT, N_(""), N_("expand node") , FALSE, 0}, {SC_KEY_RIGHT2, 'l', "l", N_("expand node") , FALSE, 0}, {SC_KEY_SPACE, ' ', N_(""), N_("shrink/expand node") , FALSE, 0}, {SC_KEY_RETURN, KEY_RETURN, N_(""), N_("shrink/expand node") , FALSE, 0}, {SC_KEY_ENTER, KEY_ENTER, N_(""), N_("shrink/expand node") , FALSE, 0}, {SC_KEY_UP, KEY_UP, N_(""), N_("move up") , FALSE, 0}, {SC_KEY_UP2, 'k', "k", N_("move up") , FALSE, 0}, {SC_KEY_DOWN, KEY_DOWN, N_(""), N_("move down") , FALSE, 0}, {SC_KEY_DOWN2, 'j', "j", N_("move down") , FALSE, 0}, {SC_KEY_HOME, KEY_HOME, N_(""), N_("move to the top") , FALSE, 0}, {SC_KEY_END, KEY_END, N_(""), N_("move to the end") , FALSE, 0}, {SC_KEY_PPAGE, KEY_PPAGE, N_(""), N_("previous page") , FALSE, 0}, {SC_KEY_NPAGE, KEY_NPAGE, N_(""), N_("next page") , FALSE, 0}, {SC_KEY_PLUS, '+', "+", N_("shrink/expand node") , FALSE, 0}, {SC_KEY_QUIT, 'q', "q" , N_("quit") , TRUE , 0}, {SC_KEY_HELP, '?', "?" , N_("help") , TRUE , 0}, {SC_KEY_FIND, '/', "/" , N_("search host") , FALSE , 0}, #ifdef FEAT_TCLFILTER {SC_KEY_FILTER, 'f', "f" , N_("filter hosts") , FALSE, 0}, #endif {SC_KEY_ATTACH, 'a', "a" , N_("attach session") , FALSE, VK_ATTACH}, {SC_KEY_CONNECT, 'c', "c" , N_("connect host") , FALSE, VK_CONNECT}, {SC_KEY_FILETRANS, 'C', "C" , N_("file transfer") , FALSE, 0}, {SC_KEY_TOGGLEDUMPS, 'd', "d" , N_("toggle dumps") , FALSE, VK_DUMP}, {SC_KEY_REFRESH, 'g', "g" , N_("refresh host") , FALSE, VK_REFRESH}, {SC_KEY_ERRDIAG, 'e', "e" , N_("failure diagnostic") , FALSE, VK_ERRDIAG}, {SC_KEY_INSTALL, 'i', "i" , N_("install pkg") , FALSE, VK_INSTALL}, {SC_KEY_UPGRADE, 'u', "u" , N_("upgrade host(s)") , FALSE, VK_UPGRADE}, {SC_KEY_MORE, 'm', "m" , N_("host details") , FALSE, 0}, #ifdef FEAT_HISTORY {SC_KEY_HISTORY, 'H', "H", N_("host history") , FALSE, 0}, {SC_KEY_PLAY, 'p', "p" , N_("play") , FALSE, VK_PLAY}, {SC_KEY_LESS, 'L', "L" , N_("display with less") , FALSE, VK_LESS}, #endif {SC_KEY_NEXTSESS, 'n', "n" , N_("next detached session") , FALSE, 0}, {SC_KEY_CYCLESESS, 'N', "N" , N_("cycle detached sessions") , FALSE, 0}, {SC_KEY_TAG, 't', "t" , N_("tag current host") , FALSE, 0}, {SC_KEY_TAGMATCH, 'T', "T" , N_("tag all hosts matching") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~c tag by codename") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~d tag by distribution") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~f tag by host flags") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~g tag by group") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~p tag by packages") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~u tag by updates") , FALSE, 0}, {SC_KEY_UNUSED, KEY_MAX, "" , N_(" ~A tag all hosts") , FALSE, 0}, {SC_KEY_UNTAGMATCH, ctrl('T'), "^T" , N_("untag all hosts matching") , FALSE, 0}, {SC_KEY_TAGACTION, ';', ";" , N_("apply next function to tagged hosts") , FALSE, 0}, {SC_MAX, 0, NULL, NULL, FALSE, 0}, }; const struct HostFlag hostFlags[] = { {HOST_STATUS_PKGKEPTBACK , "h", N_("some packages are kept back")}, {HOST_STATUS_PKGEXTRA , "x", N_("extra packages are installed")}, {HOST_STATUS_KERNELNOTMATCH , "R", N_("running kernel is not the latest (reboot required)")}, {HOST_STATUS_KERNELSELFBUILD, "k", N_("a selfbuild kernel is running")}, {HOST_STATUS_VIRTUALIZED , "v", N_("this is a virtualized machine")}, #ifdef FEAT_CLUSTERS {HOST_STATUS_CLUSTERED , "C", N_("this machine is part of a cluster")}, #endif {0 , NULL, NULL}, }; static int getKeyForShortcut(EShortCuts sc) { gint i; for(i = 0; shortCuts[i].keycode; i++) if(shortCuts[i].sc == sc) return shortCuts[i].keycode; return -1; } static gboolean freeDl(GList *dl) { if(dl) { g_list_foreach(dl, (GFunc) freeDrawNode, NULL); g_list_free(dl); } else return FALSE; return TRUE; } int getnLine(WINDOW *win, gchar *str, gint n, gboolean usews) { gint cpos = 0, slen = 0, i; int ch = 0, cy, cx, sx, sy; gchar *modstr = NULL; gboolean dobeep; WINDOW *wp = NULL; if(!str || !win || !n) return (0); if(n > INPUT_MAX) n = INPUT_MAX; modstr = g_malloc0(n+1); if(!modstr) return(0); wp = newpad(1, n); if(!wp) { g_free(modstr); return(0); } enableInput(); keypad(wp, TRUE); noecho(); wrefresh(win); getyx(win, sy, sx); getbegyx(win, cy, cx); sy += cy; sx += cx; while(ch != KEY_RETURN && ch != KEY_ENTER) { getyx(wp, cy, cx); prefresh(wp, 0, cx+sx - COLS < 0 ? 0 : cx+sx+1 - COLS, sy, sx, sy, COLS-1); ch = wgetch(wp); dobeep = TRUE; if((isascii(ch) && isprint(ch)) || (ch == '\t' && usews == TRUE)) { if(slen < n-1) { if(cpos == slen) { modstr[cpos] = ch; waddch(wp, modstr[cpos++]); slen++; } else { bcopy(&modstr[cpos], &modstr[cpos+1], slen-cpos); modstr[cpos] = ch; winsch(wp, modstr[cpos++]); wmove(wp, cy, ++cx); slen++; } dobeep = FALSE; } } else { switch(ch) { case KEY_RETURN: case KEY_ENTER: continue; case KEY_BACKSPACE: if(slen > 0 && cpos > 0) { if(cpos == slen) modstr[--cpos] = 0; else { g_strlcpy(&modstr[cpos-1], &modstr[cpos], slen-cpos+1); cpos--; } mvwdelch(wp, cy, --cx); slen = strlen(modstr); dobeep = FALSE; } break; case KEY_DC: if(slen > 0 && cpos < slen) { dobeep = FALSE; g_strlcpy(&modstr[cpos], &modstr[cpos+1], slen-cpos+1); wdelch(wp); slen = strlen(modstr); } break; case KEY_LEFT: if(cpos > 0) { cpos--; wmove(wp, cy, --cx); dobeep = FALSE; } break; case KEY_RIGHT: if(cpos < slen && slen > 0) { cpos++; wmove(wp, cy, ++cx); dobeep = FALSE; } break; case ctrl('U'): /* Delete line */ cx+=(slen-cpos); for(i=slen;i > 0;i--) mvwdelch(wp, cy, --cx); memset(modstr, 0, n); cpos=0; dobeep = FALSE; break; case ctrl('A'): case KEY_HOME: cx-=cpos; cpos = 0; wmove(wp, cy, cx); dobeep = FALSE; break; case ctrl('E'): case KEY_END: cx+=(slen-cpos); cpos = slen; wmove(wp, cy, cx); dobeep = FALSE; break; case KEY_ESC: /* Abort */ case KEY_RESIZE: case ctrl('G'): disableInput(); g_free(modstr); delwin(wp); return(0); } /* switch(ch) */ } if(dobeep == TRUE) beep(); } disableInput(); memcpy(str, modstr, n+1); g_free(modstr); delwin(wp); return(ch); } static void setMenuEntries(gint mask) { mask |= sc_mask; gint i = -1; while(shortCuts[++i].key) { if(shortCuts[i].id == 0) continue; shortCuts[i].visible = mask & shortCuts[i].id; } } static gchar *compDl(gpointer p) { gchar *ret = NULL; ret = getStrFromDrawNode((DrawNode *) p); return ret; } static gint strcompDl (const gchar *s1, const gchar *s2, gsize n) { return(g_ascii_strncasecmp(s1, s2, n)); } void freeDrawNode (DrawNode *n) { g_free(n); } void cleanBetween() { gint i; for(i=1; i < bottomDrawLine;i++) mvremln(i, 0, COLS); } DrawNode *getSelectedDrawNode() { GList *dl; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); if (!dl) return NULL; ASSERT_TYPE((DrawNode *)dl->data, T_DRAWNODE); return (DrawNode *)dl->data; } guint getCategoryNumber(gchar *category) { guint i = 0; while(*(drawCategories+i)) { if(*(drawCategories+i) == category) break; i++; } return(i); } void setHostsCategory(GList *hosts, Category matchCategory, gchar *matchGroup, Category setCategory) { GList *ho; ho = g_list_first(hosts); while(ho) { if(matchGroup) { if((((HostNode *) ho->data)->category == matchCategory) && (!g_ascii_strcasecmp(((HostNode *) ho->data)->group, matchGroup))) ((HostNode *) ho->data)->category = setCategory; } else if((((HostNode *) ho->data)->category == matchCategory)) ((HostNode *) ho->data)->category = setCategory; ho = g_list_next(ho); } } guint getHostGrpCatCnt(GList *hosts, gchar *group, Category category) { guint cnt = 0; GList *ho; ho = g_list_first(hosts); while(ho) { #ifdef FEAT_TCLFILTER if(category == C_FILTERED) { if((((HostNode *) ho->data)->filtered) && (!g_ascii_strcasecmp(((HostNode *) ho->data)->group, group))) cnt++; } else #endif if((((HostNode *) ho->data)->category == category) && (!g_ascii_strcasecmp(((HostNode *) ho->data)->group, group))) cnt++; ho = g_list_next(ho); } return(cnt); } guint getHostGrpCatTaggedCnt(GList *hosts, const gchar *group, Category category) { guint cnt = 0; GList *ho; ho = g_list_first(hosts); while(ho) { if((((HostNode *) ho->data)->category == category) && (!g_ascii_strcasecmp(((HostNode *) ho->data)->group, group)) && ((HostNode *) ho->data)->tagged == TRUE) cnt++; ho = g_list_next(ho); } return(cnt); } void disableInput() { noecho(); curs_set(0); leaveok(stdscr, TRUE); /* To slow down the idle process. */ timeout(200); } void enableInput() { echo(); curs_set(1); leaveok(stdscr, FALSE); timeout(-1); } void initUI () { printf("\033]0;" PACKAGE_STRING "\007"); initscr(); ui_start_color(); cbreak(); nonl(); disableInput(); intrflush(stdscr, FALSE); keypad(stdscr, TRUE); clear(); refresh(); bottomDrawLine = LINES-2; } void cleanUI () { clear(); refresh(); clear(); endwin(); } void blank() { printf("\033[2J"); fflush(stdout); } void drawMenu (gint mask) { setMenuEntries(mask); attron(uicolors[UI_COLOR_MENU]); move(0,0); remln(COLS); gint i=-1; gint p=COLS; while(shortCuts[++i].key) { if(!shortCuts[i].visible) continue; addnstr(shortCuts[i].key, MAX(0, p)); p -= strlen(shortCuts[i].key); addnstr(":", MAX(0, p)); p--; addnstr(_(shortCuts[i].descr), MAX(0, p)); p -= strlen(_(shortCuts[i].descr)); addnstr(" ", MAX(0, p)); p-=2; } attroff(uicolors[UI_COLOR_MENU]); } static void drawHelp () { WINDOW *wp = newpad(32+SC_MAX, COLS); gint l = 0; int wic = 0, pminrow = 0, kcquit = 'q'; keypad(wp, TRUE); wattron(wp, A_BOLD); mvwaddnstr(wp, l , 2, _("FLAG") , COLS - 2); mvwaddnstr(wp, l++, 16, _("DESCRIPTION"), COLS - 16); wattroff(wp, A_BOLD); gint i = -1; while(hostFlags[++i].flag) { mvwaddch (wp, l, 2, hostFlags[i].code[0]); mvwaddnstr(wp, l, 16, _(hostFlags[i].descr), COLS - 16); l++; } l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l , 2, _("KEY") , COLS - 2); mvwaddnstr(wp, l++, 16, _("DESCRIPTION"), COLS - 16); wattroff(wp, A_BOLD); i = -1; while(shortCuts[++i].key) { mvwaddnstr(wp, l, 2, _(shortCuts[i].key) , COLS - 2); mvwaddnstr(wp, l, 16, _(shortCuts[i].descr), COLS - 16); l++; } for(i = 0; shortCuts[i].key; i++) if(shortCuts[i].sc == SC_KEY_QUIT) kcquit = shortCuts[i].keycode; pminrow = 0; prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); while((wic = tolower(wgetch(wp))) != kcquit) { if(wic == KEY_UP && pminrow) pminrow--; else if(wic == KEY_DOWN && pminrow < l-LINES+4) pminrow++; else if(wic == KEY_HOME) pminrow=0; else if(wic == KEY_END) pminrow=l-LINES+4; else if(wic == KEY_NPAGE) pminrow = pminrow+LINES-3 > (l-LINES+4) ? l-LINES+4 : pminrow+LINES-3; else if(wic == KEY_PPAGE) pminrow = pminrow-(LINES-3) < 0 ? 0 : pminrow-(LINES-3); prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); } delwin(wp); } static void drawHostDetails(HostNode *h) { WINDOW *wp = newpad(32 + h->nupdates + h->nholds + h->nextras + h->nbrokens + g_list_length(h->packages), COLS); char buf[0x1ff]; gint l = 0; int wic = 0, pminrow = 0, kcquit = 'q', i = 0; keypad(wp, TRUE); wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("HOST DETAILS"), COLS - 1); wattroff(wp, A_BOLD); mvwaddnstr(wp, l , 2, _("Group:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->group, COLS - 20); mvwaddnstr(wp, l , 2, _("Hostname:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->hostname, COLS - 20); if (h->virt) { mvwaddnstr(wp, l , 2, _("Machine Type:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->virt, COLS - 20); } if (h->uname_machine && h->uname_machine[0]) { mvwaddnstr(wp, l , 2, _("Architecture:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->uname_machine, COLS - 20); } if (h->uuid[0]) { mvwaddnstr(wp, l , 2, _("UUID:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->uuid, COLS - 20); } if (h->forbid & HOST_FORBID_MASK) { mvwaddnstr(wp, l , 2, _("Forbidden:"), COLS - 2); strcpy(buf, " "); if (h->forbid & HOST_FORBID_REFRESH) { strcat(buf, _("refresh")); } if (h->forbid & HOST_FORBID_UPGRADE) { if(strlen(buf) > 1) { strcat(buf, ", "); } strcat(buf, _("upgrade")); } if (h->forbid & HOST_FORBID_INSTALL) { if(strlen(buf) > 1) { strcat(buf, ", "); } strcat(buf, _("install")); } mvwaddnstr(wp, l++, 15, buf , COLS - 15); } l++; if (h->lsb_distributor) { mvwaddnstr(wp, l , 2, _("Distri:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->lsb_distributor, COLS - 20); if (h->lsb_codename) snprintf(buf, sizeof(buf), "%s (%s)", h->lsb_release, h->lsb_codename); else snprintf(buf, sizeof(buf), "%s", h->lsb_release); mvwaddnstr(wp, l , 2, _("Release:"), COLS - 2); mvwaddnstr(wp, l++, 20, buf, COLS - 20); } if (h->uname_kernel && h->uname_kernel[0]) { mvwaddnstr(wp, l , 2, _("Kernel name:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->uname_kernel, COLS - 20); } if (h->kernelrel) { mvwaddnstr(wp, l , 2, _("Kernel version:"), COLS - 2); mvwaddnstr(wp, l++, 20, h->kernelrel, COLS - 20); switch(h->status & (HOST_STATUS_KERNELNOTMATCH | HOST_STATUS_KERNELSELFBUILD)) { case HOST_STATUS_KERNELNOTMATCH: strcpy(buf, _("(reboot required)")); break; case HOST_STATUS_KERNELSELFBUILD: strcpy(buf, _("(selfbuild kernel)")); break; default: buf[0] = 0; break; } if(strlen(buf) > 0) mvwaddnstr(wp, l-1, 21 + strlen(h->kernelrel), buf, COLS - 21 - strlen(h->kernelrel)); } #ifdef FEAT_CLUSTERS if(g_list_length(h->clusters)) { l++; mvwaddnstr(wp, l , 2, _("Clusters: "), COLS - 2); GList *c = h->clusters; while(c) { mvwaddnstr(wp, l++, 20, c->data, COLS - 20); c = g_list_next(c); } } #endif if (g_list_length(h->packages)) { l++; mvwaddnstr(wp, l , 2, _("Packages: "), COLS - 2); snprintf(buf, sizeof(buf), "%d installed (%d update%s, %d hold back, %d broken, %d extra)", g_list_length(h->packages), h->nupdates, h->nupdates == 1 ? "" : "s", h->nholds, h->nbrokens, h->nextras); mvwaddnstr(wp, l++, 20, buf, COLS - 20); } if (h->nbrokens) { l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("BROKEN PACKAGES"), COLS - 1); wattroff(wp, A_BOLD); GList *p = g_list_first(h->packages); while(p) { PkgNode *pn = p->data; if (pn->flag & HOST_STATUS_PKGBROKEN) { mvwaddnstr(wp, l , 2, pn->package , MIN(33, COLS - 2)); snprintf(buf, sizeof(buf), "%s (%s)", pn->version, pn->data); mvwaddnstr(wp, l++, 36, buf, COLS - 36); } p = g_list_next(p); } } if (h->nupdates) { l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("UPDATE PACKAGES") , COLS - 1); wattroff(wp, A_BOLD); GList *p = g_list_first(h->packages); while(p) { PkgNode *pn = p->data; if (pn->flag & HOST_STATUS_PKGUPDATE) { mvwaddnstr(wp, l , 2, pn->package, MIN(33, COLS - 2)); snprintf(buf, sizeof(buf), "%s -> %s", pn->version, pn->data); mvwaddnstr(wp, l++, 36, buf, COLS - 36); } p = g_list_next(p); } } if (h->nholds) { l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("HOLD BACK PACKAGES") , COLS - 1); wattroff(wp, A_BOLD); GList *p = g_list_first(h->packages); while(p) { PkgNode *pn = p->data; if (pn->flag & HOST_STATUS_PKGKEPTBACK) { mvwaddnstr(wp, l , 2, pn->package, MIN(33, COLS - 2)); mvwaddnstr(wp, l++, 36, pn->version, COLS - 36); } p = g_list_next(p); } } if (h->nextras) { l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("EXTRA PACKAGES") , COLS - 1); wattroff(wp, A_BOLD); GList *p = g_list_first(h->packages); while(p) { PkgNode *pn = p->data; if (pn->flag & HOST_STATUS_PKGEXTRA) { mvwaddnstr(wp, l , 2, pn->package , MIN(33, COLS - 2)); mvwaddnstr(wp, l++, 36, pn->version , COLS - 36); } p = g_list_next(p); } } if (g_list_length(h->packages)) { l++; wattron(wp, A_BOLD); mvwaddnstr(wp, l++, 1, _("INSTALLED PACKAGES"), COLS - 1); wattroff(wp, A_BOLD); GList *p = g_list_first(h->packages); while(p) { PkgNode *pn = p->data; mvwaddnstr(wp, l , 2, pn->package , MIN(33, COLS - 2)); mvwaddnstr(wp, l++, 36, pn->version , COLS - 36); p = g_list_next(p); } } for(i = 0; shortCuts[i].key; i++) if(shortCuts[i].sc == SC_KEY_QUIT) kcquit = shortCuts[i].keycode; pminrow = 0; prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); while((wic = tolower(wgetch(wp))) != kcquit) { if(wic == KEY_UP && pminrow) pminrow--; else if(wic == KEY_DOWN && pminrow < l-LINES+4) pminrow++; else if(wic == KEY_HOME) pminrow=0; else if(wic == KEY_END) pminrow=l-LINES+4; else if(wic == KEY_NPAGE) pminrow = pminrow+LINES-3 > (l-LINES+4) ? l-LINES+4 : pminrow+LINES-3; else if(wic == KEY_PPAGE) pminrow = pminrow-(LINES-3) < 0 ? 0 : pminrow-(LINES-3); else if(wic == '?') drawHelp(); prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); } delwin(wp); } static void drawHostErrDiag(HostNode *h) { gchar *buf = getStatsContent(h); int l = 2; if(buf != NULL) { gchar *b = buf; while((b = strchr(b, '\n'))) { l++; b++; } b = buf; while((b = strchr(b, '\r'))) { *b = ' '; } } WINDOW *wp = newpad(MAX(LINES, l+2), COLS); int wic = 0, pminrow = 0, kcquit = 'q', i; keypad(wp, TRUE); wattron(wp, A_BOLD); mvwaddnstr(wp, 0, 1, _("FAILURE DIAGNOSTIC"), COLS - 1); wattroff(wp, A_BOLD); mvwaddstr(wp, 2, 0, buf); g_free(buf); for(i = 0; shortCuts[i].key; i++) if(shortCuts[i].sc == SC_KEY_QUIT) kcquit = shortCuts[i].keycode; prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); while((wic = tolower(wgetch(wp))) != kcquit) { if(wic == KEY_UP && pminrow) pminrow--; else if(wic == KEY_DOWN && pminrow < l-LINES+4) pminrow++; else if(wic == KEY_HOME) pminrow=0; else if(wic == KEY_END) pminrow=l-LINES+4; else if(wic == KEY_NPAGE) pminrow = pminrow+LINES-3 > (l-LINES+4) ? l-LINES+4 : pminrow+LINES-3; else if(wic == KEY_PPAGE) pminrow = pminrow-(LINES-3) < 0 ? 0 : pminrow-(LINES-3); else if(wic == '?') drawHelp(); prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); } delwin(wp); } void drawStatus (char *str, gboolean drawinfo) { char strinfo[30]; struct tm *tm_mtime; int mtime_pos; if(drawinfo == TRUE) { tm_mtime = localtime(&oldest_st_mtime); strftime(strinfo, sizeof(strinfo), _(" [Oldest: %D %H:%M]"), tm_mtime); } attron(uicolors[UI_COLOR_STATUS]); move(bottomDrawLine, 0); remln(COLS); if(str) { addnstr(str, COLS); } if(drawinfo == TRUE) { mtime_pos = COLS < strlen(strinfo) ? COLS-1 : COLS-strlen(strinfo)-1; move(bottomDrawLine, mtime_pos); addnstr(strinfo, COLS-mtime_pos); } attroff(uicolors[UI_COLOR_STATUS]); } void drawQuery (const char *str, gulong display_ms) { attron(uicolors[UI_COLOR_QUERY]); mvaddstr(LINES - 1, 0, str); attroff(uicolors[UI_COLOR_QUERY]); if(display_ms) { refresh(); g_usleep(display_ms); mvremln(LINES - 1, 0, COLS); refresh(); } } gboolean queryString(const gchar *query, gchar *in, const gint size) { gint i; gboolean r; gint maxsize; enableInput(); drawQuery(query, 0); move(LINES - 1, strlen(query)); attron(uicolors[UI_COLOR_INPUT]); for(i = strlen(in)-1; i>=0; i--) ungetch(in[i]); maxsize = size > INPUT_MAX ? INPUT_MAX : size; r = getnLine(stdscr, in, maxsize, FALSE) == 0 ? FALSE : TRUE; disableInput(); attroff(uicolors[UI_COLOR_INPUT]); move(LINES - 1, 0); remln(COLS); return(r); } gboolean queryConfirm(const gchar *query, const gboolean enter_is_yes, gboolean *has_canceled) { int c; enableInput(); drawQuery(query, 0); move(LINES - 1, strlen(query)); attron(uicolors[UI_COLOR_INPUT]); c = getch(); attroff(uicolors[UI_COLOR_INPUT]); disableInput(); move(LINES - 1, 0); remln(COLS); if (has_canceled) { *has_canceled = ((c == _("c")[0]) || (c == _("C")[0]) || (c == 27)); } return ((c == _("y")[0]) || (c == _("Y")[0]) || (enter_is_yes == TRUE && (c == 0xd || c == KEY_ENTER))); } /* Reads a char from the terminal w/o ncurses stuff. */ gchar termGetChar() { struct termios to; struct termios tn; /* backup settings */ tcgetattr(STDIN_FILENO, &to); memcpy(&tn, &to, sizeof(to)); /* disable line buffer */ tn.c_lflag &= ~ICANON; tcsetattr(STDIN_FILENO, TCSANOW, &tn); gchar r = getchar(); /* restore line buffer */ tcsetattr(STDIN_FILENO, TCSANOW, &to); return r; } #ifdef FEAT_HISTORY static void drawHistoryLine(WINDOW *wp, const HistoryEntry *he, const gint l) { char buf[0x1ff]; const struct tm *ts = localtime(&(he->ts)); #define MAXCOLS(pos, s) (pos+s) <= COLS ? s : COLS-pos mvwremln(wp, l, 0, COLS); if(he->errpattern) mvwaddnstr(wp,l , 0, "F", MAXCOLS(0, 1)); snprintf(buf, sizeof(buf), "%4d", l+1); mvwaddnstr(wp, l , 1, buf, MAXCOLS(0, 4)); strftime(buf, sizeof(buf), "%x %X", ts); mvwaddnstr(wp, l , 7, buf, MAXCOLS(7, 17)); if(he->duration > 86400) snprintf(buf, sizeof(buf), "%dd", (he->duration/86400)); else if(he->duration > 3600) snprintf(buf, sizeof(buf), "%dh", (he->duration/3600)); else if(he->duration > 60) snprintf(buf, sizeof(buf), "%dmin", (he->duration/60)); else if(he->duration > 0) snprintf(buf, sizeof(buf), "%ds", he->duration); else strcpy(buf, "n/a"); mvwaddnstr(wp, l , 26, buf , MAXCOLS(26, 8)); mvwaddnstr(wp, l , 36, he->maintainer , MAXCOLS(36, 13)); mvwaddnstr(wp, l , 51, he->action , MAXCOLS(51, COLS-51)); if (he->data) mvwaddnstr(wp, l , 52+strlen(he->action), he->data, MAXCOLS(52+strlen(he->action), COLS- 52- strlen(he->action))); } static void drawHistoryEntries (HostNode *n) { gint l = 0; int wic = 0, pminrow = 0, i; guint sc = SC_MAX; char statusln[BUF_MAX_LEN]; GList *hel = NULL, *hep = NULL; WINDOW *wp = NULL; if(!n) return; hel = history_get_entries(inhost); if(!hel) { drawQuery(_("No history data available!"), G_USEC_PER_SEC); refresh(); return; } snprintf(statusln, BUF_MAX_LEN, g_list_length (hel) == 1 ? _("History of %s (%d entry available)") : _("History of %s (%d entries available)"), n->hostname ? n->hostname : "", g_list_length (hel)); drawStatus(statusln, FALSE); drawMenu(VK_PLAY|VK_LESS); refresh(); if(!(wp = newpad(g_list_length (hel) + LINES, COLS))) return; keypad(wp, TRUE); hep = g_list_first(hel); while(hep) { if(!l) wattron(wp, uicolors[UI_COLOR_SELECTOR]); drawHistoryLine(wp, (HistoryEntry *)hep->data, l++); wattroff(wp, uicolors[UI_COLOR_SELECTOR]); hep = g_list_next(hep); } gint crow = 0; gint orow = 0; gint mrow = g_list_length(hel) - 1; pminrow = 0; prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); while(sc != SC_KEY_QUIT) { wic = wgetch(wp); for(i = 0; shortCuts[i].keycode; i++) if(shortCuts[i].keycode == wic) sc = shortCuts[i].sc; orow = crow; if(sc == SC_KEY_UP && crow) { crow--; if(crow < pminrow && pminrow) pminrow--; } else if(sc == SC_KEY_DOWN && crow < mrow) { crow++; if(crow-pminrow > LINES-4 && pminrow < l-LINES+3) pminrow++; } else if(sc == SC_KEY_HOME) { crow=pminrow=0; } else if(sc == SC_KEY_END) { crow=mrow; if(pminrow+LINES-4 < mrow) pminrow=l-LINES+3; } else if(sc == SC_KEY_NPAGE) { if(mrow-crow (l-LINES+4) ? l-LINES+4 : pminrow+LINES-3; if(crow < 0) { crow=mrow; pminrow=0; } } else if(sc == SC_KEY_PPAGE) { if(crow-LINES+3<0) pminrow=crow=0; else { pminrow = pminrow-(LINES-3) < 0 ? 0 : pminrow-(LINES-3); crow=pminrow+(LINES-4); if(crow > mrow) pminrow=crow=0; } } else if(sc == SC_KEY_LESS) { ignoreSIGINT(TRUE); endwin(); blank(); HistoryEntry *he = (HistoryEntry *)(g_list_nth(hel, crow)->data); if(he->errpattern) history_show_less_search(he, he->errpattern); else history_show_less(he); ignoreSIGINT(FALSE); refresh(); } else if(sc == SC_KEY_PLAY) { ignoreSIGINT(TRUE); endwin(); blank(); history_show_replay((HistoryEntry *)(g_list_nth(hel, crow)->data)); printf("\n================[ %s ]================\n", _("replay terminated, press any key to continue")); fflush(stdout); termGetChar(); blank(); ignoreSIGINT(FALSE); } else if(sc == SC_KEY_HELP) { drawHelp(); } #ifdef KEY_RESIZE else if(wic == KEY_RESIZE) { sc = SC_KEY_QUIT; } #endif if(crow != orow) { drawHistoryLine(wp, (HistoryEntry *)(g_list_nth(hel, orow)->data), orow); orow = crow; wattron(wp, uicolors[UI_COLOR_SELECTOR]); drawHistoryLine(wp, (HistoryEntry *)(g_list_nth(hel, crow)->data), crow); wattroff(wp, uicolors[UI_COLOR_SELECTOR]); } prefresh(wp, pminrow, 0, 1, 0, LINES-3, COLS); } delwin(wp); history_free_hel(hel); } #endif void drawCategoryEntry (DrawNode *n) { char statusln[BUF_MAX_LEN]; attron(n->attrs); mvremln(n->scrpos, 0, COLS); mvaddstr(n->scrpos, 0, " ["); if(n->elements > 0) addch(n->elements > 0 && n->extended == FALSE ? '+' : '-'); else addch(' '); addstr("]"); if(n->etagged) addch('*'); else addch(' '); addnstr(_((char *) n->p), COLS); attroff(n->attrs); if(n->selected == TRUE) { if (n->elements > 1 || n->elements == 0) { snprintf(statusln, BUF_MAX_LEN, _("%d Hosts in status \"%s\""), n->elements, _((char *) n->p)); } else { snprintf(statusln, BUF_MAX_LEN, _("%d Host in status \"%s\""), n->elements, _((char *) n->p)); } drawMenu(VK_REFRESH); drawStatus(statusln, TRUE); } } void drawGroupEntry (DrawNode *n) { char statusln[BUF_MAX_LEN]; attron(n->attrs); mvremln(n->scrpos, 0, COLS); mvaddstr(n->scrpos, 2, " ["); addch(n->elements > 0 && n->extended == FALSE ? '+' : '-'); addstr("]"); if(n->etagged) addch('*'); else addch(' '); addnstr((char *) n->p, COLS); attroff(n->attrs); if(n->selected == TRUE) { if (n->elements > 1 || n->elements == 0) { snprintf(statusln, BUF_MAX_LEN, _("%d Hosts in status \"%s\""), n->elements, _(incategory)); } else { snprintf(statusln, BUF_MAX_LEN, _("%d Host in status \"%s\""), n->elements, _(incategory)); } drawMenu(VK_REFRESH); drawStatus(statusln, TRUE); } } void drawHostEntry (DrawNode *n) { char statusln[BUF_MAX_LEN]; gint mask = 0; char *hostentry; attron(n->attrs); mvremln(n->scrpos, 0, COLS); if (((HostNode *) n->p)->status & HOST_STATUS_LOCKED) { attron(uicolors[UI_COLOR_HOSTSTATUS]); mvaddstr(n->scrpos, 1, "L"); attroff(uicolors[UI_COLOR_HOSTSTATUS]); } else { move(n->scrpos, 1); attron(uicolors[UI_COLOR_HOSTSTATUS]); gint i = 0; while(hostFlags[i].flag) { if (((HostNode *) n->p)->status & hostFlags[i].flag) addch(hostFlags[i].code[0]); else addch(' '); i++; } attroff(uicolors[UI_COLOR_HOSTSTATUS]); } #ifdef FEAT_CLUSTERS mvaddstr(n->scrpos, 7, " ["); #else mvaddstr(n->scrpos, 6, " ["); #endif if(n->elements > 0) addch(n->elements > 0 && n->extended == FALSE ? '+' : '-'); else addch(' '); addstr("]"); if(((HostNode *) n->p)->tagged) addch('*'); else addch(' '); if(((HostNode *) n->p)->forbid & HOST_FORBID_MASK) attron(A_UNDERLINE); if(((HostNode *) n->p)->lsb_distributor) { if(!HOST_SSHPORT_SET((HostNode *) n->p)) hostentry = g_strdup_printf("%s (%s %s %s; %s)", ((HostNode *) n->p)->hostname, ((HostNode *) n->p)->lsb_distributor, ((HostNode *) n->p)->lsb_release, ((HostNode *) n->p)->lsb_codename, ((HostNode *) n->p)->kernelrel); else hostentry = g_strdup_printf("%s:%d (%s %s %s; %s)", ((HostNode *) n->p)->hostname, ((HostNode *) n->p)->ssh_port, ((HostNode *) n->p)->lsb_distributor, ((HostNode *) n->p)->lsb_release, ((HostNode *) n->p)->lsb_codename, ((HostNode *) n->p)->kernelrel); addnstr((char *) hostentry, COLS - 11); g_free(hostentry); } else { if(!HOST_SSHPORT_SET((HostNode *) n->p)) addnstr((char *) ((HostNode *) n->p)->hostname, COLS - 11); else { hostentry = g_strdup_printf("%s:%d", ((HostNode *) n->p)->hostname, ((HostNode *) n->p)->ssh_port); addnstr((char *) hostentry, COLS - 11); g_free(hostentry); } } if(((HostNode *) n->p)->forbid & HOST_FORBID_MASK) attroff(A_UNDERLINE); attroff(n->attrs); if(n->selected == TRUE) { switch(((HostNode *) n->p)->category) { case C_UPDATES_PENDING: mask = VK_CONNECT | VK_UPGRADE | VK_REFRESH | VK_INSTALL; if (((HostNode *) n->p)->nupdates > 1 || ((HostNode *) n->p)->nupdates == 0) { snprintf(statusln, sizeof(statusln), _("%d Updates required"), ((HostNode *) n->p)->nupdates); } else { snprintf(statusln, sizeof(statusln), _("%d Update required"), ((HostNode *) n->p)->nupdates); } break; case C_UP_TO_DATE: mask = VK_CONNECT | VK_REFRESH | VK_INSTALL; sprintf(statusln, _("No update required")); break; case C_BROKEN_PKGS: mask = VK_CONNECT | VK_REFRESH | VK_INSTALL; if (((HostNode *) n->p)->nbrokens > 1 || ((HostNode *) n->p)->nbrokens == 0) { snprintf(statusln, sizeof(statusln), _("%d Broken packages"), ((HostNode *) n->p)->nbrokens); } else { snprintf(statusln, sizeof(statusln), _("%d Broken package"), ((HostNode *) n->p)->nbrokens); } break; case C_REFRESH_REQUIRED: mask = VK_CONNECT | VK_REFRESH | VK_INSTALL; sprintf(statusln, _("Refresh required")); break; case C_REFRESH: sprintf(statusln, _("In refresh")); break; case C_SESSIONS: mask = VK_ATTACH; if (g_list_length(((HostNode *) n->p)->screens) != 1) { sprintf(statusln, _("%d sessions running"), g_list_length(((HostNode *) n->p)->screens)); } else { sprintf(statusln, _("%d session running"), g_list_length(((HostNode *) n->p)->screens)); } break; default: mask = VK_CONNECT | VK_REFRESH | VK_INSTALL | VK_ERRDIAG; if(((HostNode *) n->p)->adperr == NULL) { sprintf(statusln, _("Status is unknown")); } else { sprintf(statusln, _("Error: %s"), ((HostNode *) n->p)->adperr); } break; } if (((HostNode *) n->p)->status & HOST_STATUS_LOCKED) strcat(statusln, _(" - host locked by another process")); drawMenu(mask); drawStatus(statusln, TRUE); } } void drawPackageEntry (DrawNode *n) { char statusln[BUF_MAX_LEN]; attron(n->attrs); mvremln(n->scrpos, 0, COLS); if(((PkgNode *) n->p)->flag & HOST_STATUS_PKGUPDATE) mvaddstr(n->scrpos, 7, "u:"); else if(((PkgNode *) n->p)->flag & HOST_STATUS_PKGKEPTBACK) mvaddstr(n->scrpos, 7, "h:"); else if(((PkgNode *) n->p)->flag & HOST_STATUS_PKGEXTRA) mvaddstr(n->scrpos, 7, "x:"); else if(((PkgNode *) n->p)->flag & HOST_STATUS_PKGBROKEN) { attron(A_BOLD); mvaddstr(n->scrpos, 7, "b:"); } mvaddnstr(n->scrpos, 10, (char *) ((PkgNode *) n->p)->package, COLS-10); attroff(A_BOLD); attroff(n->attrs); if(n->selected == TRUE) { if(((PkgNode *) n->p)->data) { if (((PkgNode *) n->p)->flag & HOST_STATUS_PKGBROKEN) snprintf(statusln, BUF_MAX_LEN, "%s (%s)", ((PkgNode *) n->p)->version, ((PkgNode *) n->p)->data); else snprintf(statusln, BUF_MAX_LEN, "%s -> %s", ((PkgNode *) n->p)->version, ((PkgNode *) n->p)->data); } else snprintf(statusln, BUF_MAX_LEN, "%s", ((PkgNode *) n->p)->version); drawMenu(VK_INSTALL); drawStatus(statusln, TRUE); } } static gboolean refreshDumpWindow (DrawNode *n) { gchar *dump = n->type == SESSION ? screen_get_dump((SessNode *) n->p) : NULL; gchar *hostname = NULL; char h[BUF_MAX_LEN]; if(dump) { if (win_dump) { mvwaddstr(win_dump, 1, 0, dump); wattron(win_dump, uicolors[UI_COLOR_STATUS]); mvwremln(win_dump, 0, 0, COLS); if(n->parent && n->parent->type == HOST) hostname = ((HostNode *) n->parent->p)->hostname; snprintf(h, sizeof(h), _("Running session %s [%5d]:"), hostname ? hostname : "", ((SessNode *) n->p)->pid); mvwaddstr(win_dump, 0, 0, h); wattroff(win_dump, uicolors[UI_COLOR_STATUS]); wrefresh(win_dump); } g_free(dump); return TRUE; } else return FALSE; } void drawSessionEntry (DrawNode *n) { char h[BUF_MAX_LEN]; struct tm *tm_mtime; char statusln[BUF_MAX_LEN]; snprintf(h, sizeof(h), "%5d: ", ((SessNode *) n->p)->pid); tm_mtime = localtime(&((SessNode *) n->p)->st.st_mtime); strftime(&h[strlen(h)], sizeof(h)-strlen(h), _("%D %H:%M "), tm_mtime); snprintf(&h[strlen(h)], sizeof(h)-strlen(h), "(%s)", (screen_is_attached((SessNode *) n->p) ? _("Attached") : _("Detached"))); attron(n->attrs); mvremln(n->scrpos, 0, COLS); mvaddnstr(n->scrpos, 7, h, COLS); attroff(n->attrs); if(n->selected == TRUE) { drawMenu(VK_ATTACH | VK_DUMP); if (dump_screen) { if(refreshDumpWindow (n) == FALSE) drawQuery(_("Could not read session dump."), G_USEC_PER_SEC); } else { snprintf(statusln, sizeof(statusln), "Session is %s", (screen_is_attached((SessNode *) n->p) ? _("attached") : _("detached"))); drawStatus(statusln, TRUE); } } } void detectPos() { GList *dl; dl = g_list_first(drawlist); while(dl) { switch(((DrawNode *) dl->data)->type) { case CATEGORY: incategory = ((DrawNode *) dl->data)->p; break; case GROUP: ingroup = ((DrawNode *) dl->data)->p; break; case HOST: inhost = ((DrawNode *) dl->data)->p; break; default: break; } if(((DrawNode *) dl->data)->selected) return; dl = g_list_next(dl); } } gchar *getStrFromDrawNode (DrawNode *n) { gchar *ret = NULL; static gchar h[BUF_MAX_LEN]; struct tm *tm_mtime; switch(n->type) { case CATEGORY: ret = (gchar *) n->p; break; case GROUP: ret = (gchar *) n->p; break; case HOST: ret = (gchar * ) ((HostNode *) n->p)->hostname; break; case PKG: ret = (gchar * ) ((PkgNode *) n->p)->package; break; case SESSION: snprintf(h, sizeof(h), "%5d: ", ((SessNode *) n->p)->pid); tm_mtime = localtime(&((SessNode *) n->p)->st.st_mtime); strftime(&h[strlen(h)], sizeof(h)-strlen(h), _("%D %H:%M "), tm_mtime); snprintf(&h[strlen(h)], sizeof(h)-strlen(h), "(%s)", (screen_is_attached((SessNode *) n->p) ? _("Attached") : _("Detached"))); ret = h; break; default: break; } return ret; } void drawEntry (DrawNode *n) { if(n->scrpos == 0 || n->scrpos >= bottomDrawLine) return; switch(n->type) { case CATEGORY: drawCategoryEntry(n); break; case GROUP: drawGroupEntry(n); break; case HOST: drawHostEntry(n); break; case PKG: drawPackageEntry(n); break; case SESSION: drawSessionEntry(n); break; default: break; } } void refreshDraw() { /* clear(); Don't clear stupid the hole screen. */ cleanBetween(); detectPos(); if(dump_screen) { if(getSelectedDrawNode()->type == SESSION) { if (!win_dump) { win_dump= newwin((LINES/2),COLS, LINES-(LINES/2), 0); scrollok(win_dump, TRUE); syncok(win_dump, TRUE); reorderScrpos(1); } } else { if(win_dump) { delwin(win_dump); win_dump = NULL; reorderScrpos(1); } } } else { if(win_dump) { delwin(win_dump); win_dump = NULL; reorderScrpos(1); } } g_list_foreach(drawlist, (GFunc) drawEntry, NULL); refresh(); } void refreshUI() { refresh(); } void setEntryActiveStatus(DrawNode *n, gboolean active) { if(!n) return; if(active == TRUE) { n->selected = TRUE; n->attrs|=uicolors[UI_COLOR_SELECTOR]; } else { n->selected = FALSE; if(n->attrs & uicolors[UI_COLOR_SELECTOR]) n->attrs^=uicolors[UI_COLOR_SELECTOR]; } } guint getHostCatCnt(GList *hosts, Category category) { guint cnt = 0; GList *ho; ho = g_list_first(hosts); while(ho) { #ifdef FEAT_TCLFILTER if(category == C_FILTERED) { if(((HostNode *) ho->data)->filtered) cnt++; } else #endif if(((HostNode *) ho->data)->category == category) cnt++; ho = g_list_next(ho); } return(cnt); } guint getHostCatTaggedCnt(GList *hosts, Category category) { guint cnt = 0; GList *ho; ho = g_list_first(hosts); while(ho) { if(((HostNode *) ho->data)->category == category && ((HostNode *) ho->data)->tagged == TRUE) cnt++; ho = g_list_next(ho); } return(cnt); } void checkSelected() { DrawNode *dn; GList *dl; dn = getSelectedDrawNode(); if (!dn) { dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->scrpos < bottomDrawLine)) dl = g_list_next(dl); if (!dl) dl = g_list_last(drawlist); setEntryActiveStatus((DrawNode *) dl->data, TRUE); return; } if (dn -> scrpos == 0 || dn -> scrpos > bottomDrawLine) { dl = g_list_first(drawlist); while(dl && (dl->data != dn)) dl = g_list_next(dl); gint p = bottomDrawLine-1; while(dl && p) { ((DrawNode *)dl->data)->scrpos = p--; dl = g_list_previous(dl); } return; } } void reorderScrpos(guint startat) { guint count = 0; GList *dl; dl = g_list_first(drawlist); while(dl) { if (((DrawNode *) dl->data)->scrpos == startat) while (++count < bottomDrawLine) { if(!dl) return; ((DrawNode *) dl->data)->scrpos = count; dl = g_list_next(dl); } if(dl) ((DrawNode *) dl->data )->scrpos = 0; dl = g_list_next(dl); } checkSelected(); } void buildIntialDrawList(GList *hosts) { guint i = 0; DrawNode *drawnode; while(*(drawCategories+i)) { drawnode = g_new0(DrawNode, 1); #ifndef NDEBUG drawnode->_type = T_DRAWNODE; #endif drawnode->p = *(drawCategories+i); drawnode->type = CATEGORY; drawnode->extended = FALSE; drawnode->selected = i == 0 ? TRUE : FALSE; drawnode->scrpos = i == 0 ? 1 : 0; drawnode->elements = getHostCatCnt(hosts, i); drawnode->etagged = getHostCatTaggedCnt(hosts, i); drawnode->parent = NULL; if((i == (Category) C_UPDATES_PENDING || i == (Category) C_BROKEN_PKGS || i == (Category) C_SESSIONS ) && drawnode->elements > 0) drawnode->attrs = A_BOLD; else drawnode->attrs = A_NORMAL; if(drawnode->selected == TRUE) setEntryActiveStatus(drawnode, TRUE); drawlist = g_list_append(drawlist, drawnode); i++; } } void notifyUser() { if(cfg->beep) beep(); if(cfg->flash) flash(); } void doUI (GList *hosts) { #ifdef FEAT_TCLFILTER /* Prepare TCL interpreter */ if(cfg->filterexp) strncpy(filterexp, cfg->filterexp, BUF_MAX_LEN); else filterexp[0] = 0; tcl_interp = Tcl_CreateInterp(); if(cfg->filterfile) Tcl_EvalFile(tcl_interp, cfg->filterfile); #endif initUI(); /* Create completion list. */ /* hstCompl = g_completion_new(compHost); g_completion_add_items(hstCompl, hosts); */ /* Draw the host entries intial. */ buildIntialDrawList(hosts); reorderScrpos(1); refreshDraw(); /* Create completion list. */ dlCompl = g_completion_new(compDl); g_completion_add_items(dlCompl, drawlist); g_completion_set_compare(dlCompl, strcompDl); const gchar *m = getenv("MAINTAINER"); if (m) strncpy(maintainer, m, sizeof(maintainer)); else { struct passwd *pw = getpwuid(getuid()); if (pw && pw->pw_gecos && strlen(pw->pw_gecos)) strncpy(maintainer, pw->pw_gecos, sizeof(maintainer)); else if (pw && pw->pw_name) strncpy(maintainer, pw->pw_name, sizeof(maintainer)); else maintainer[0] = 0; setenv("MAINTAINER", maintainer, TRUE); } if ((cfg->query_maintainer == 1) || ((cfg->query_maintainer > 1) && (m == NULL))) { WINDOW *w = newwin(5, 52, LINES/2-3, (COLS-52)/2); box(w,0,0); enableInput(); wattron(w, uicolors[UI_COLOR_QUERY]); mvwaddstr(w, 1, 2, _("Maintainer name:")); wattroff(w, uicolors[UI_COLOR_QUERY]); wmove(w, 3, 2); wattron(w, uicolors[UI_COLOR_INPUT]); int i; for(i = strlen(maintainer)-1; i>=0; i--) ungetch(maintainer[i]); wgetnstr(w, maintainer, sizeof(maintainer)); disableInput(); wattroff(w, uicolors[UI_COLOR_INPUT]); delwin(w); refreshDraw(); setenv("MAINTAINER", maintainer, TRUE); } } gboolean ctrlKeyUpDown(int ic) { gboolean ret = FALSE; GList *dl; guint i = 0; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); switch (ic) { case KEY_UP: case 'k': if(!g_list_previous(dl)) return(ret); else { setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_previous(dl); setEntryActiveStatus((DrawNode *) dl->data, TRUE); if(((DrawNode *) dl->data)->scrpos == 0) { ((DrawNode *) dl->data)->scrpos = 1; reorderScrpos(1); } ret = TRUE; } break; case KEY_DOWN: case 'j': if(!g_list_next(dl)) return(ret); else { setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_next(dl); setEntryActiveStatus((DrawNode *) dl->data, TRUE); if(((DrawNode *) dl->data)->scrpos >= bottomDrawLine || ((DrawNode *) dl->data)->scrpos == 0) reorderScrpos(2); ret = TRUE; } break; case KEY_HOME: setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_first(drawlist); setEntryActiveStatus((DrawNode *) dl->data, TRUE); ((DrawNode *) dl->data)->scrpos = 1; reorderScrpos(1); ret = TRUE; break; case KEY_END : setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_last(drawlist); setEntryActiveStatus((DrawNode *) dl->data, TRUE); if(((DrawNode *) dl->data)->scrpos == 0 || ((DrawNode *) dl->data)->scrpos > bottomDrawLine) { i = 0; while (dl) { ((DrawNode *) dl->data)->scrpos = LINES-3-i; i++; i = i > LINES-3 ? LINES-3 : i; dl = g_list_previous(dl); } } ret = TRUE; break; default: break; } return (ret); } gboolean compDrawNodes(DrawNode* n1, DrawNode* n2) { if (n1->type != n2->type) return(FALSE); switch(n1->type) { case CATEGORY: case GROUP: if(!g_ascii_strcasecmp(n1->p, n2->p)) return(TRUE); break; case HOST: if (!g_ascii_strcasecmp(((HostNode *) (n1->p))->hostname, ((HostNode *)(n2->p))->hostname)) return(TRUE); break; case PKG: if (!g_ascii_strcasecmp(((PkgNode *) n1->p)->package, ((PkgNode *) n2->p)->package)) return(TRUE); break; case SESSION: if (((SessNode *) n1->p)->pid == ((SessNode *) n2->p)->pid) return(TRUE); break; default: break; } return(FALSE); } void rebuildDrawList(GList *hosts) { GList *dl_new = NULL; GList *dl_old = NULL; GList *old_drawlist = NULL; DrawNode *n_old = NULL; DrawNode *n_new = NULL; guint i=0, j=0, k=0, savesel=0; gboolean posset = FALSE, selset = FALSE; rebuilddl = FALSE; old_drawlist = drawlist; drawlist = NULL; buildIntialDrawList(hosts); dl_old = g_list_nth(old_drawlist,i); dl_new = g_list_nth(drawlist,j); while(dl_old && dl_new) { n_old = (DrawNode *) dl_old->data; n_new = (DrawNode *) dl_new->data; if (!n_old || !n_new) break; setEntryActiveStatus(n_new, FALSE); if (j==0) n_new->scrpos=0; if(compDrawNodes(n_new,n_old)) { if(!posset && n_old->scrpos == 1) { n_new->scrpos=1; posset=TRUE; } if(!selset && n_old->selected) { savesel = j; selset = TRUE; } if(n_old->extended == TRUE ) { setEntryActiveStatus(n_new, TRUE); detectPos(); ctrlKeyEnter(hosts); dl_new = g_list_nth(drawlist,j); n_new = (DrawNode *) dl_new->data; setEntryActiveStatus(n_new, FALSE); } i++; j++; dl_old = g_list_nth(old_drawlist,i); dl_new = g_list_nth(drawlist,j); } else { k=0; while (n_new->type >= n_old->type) { k++; dl_new = g_list_nth(drawlist,j+k); if (!dl_new) break; n_new = (DrawNode *) dl_new->data; if(n_new && compDrawNodes(n_old, n_new)) { if(!posset && n_old->scrpos==1) { n_new->scrpos=1; posset = TRUE; } if(!selset && n_old->selected) { savesel = j+k; selset = TRUE; } if(n_old->extended == TRUE ) { setEntryActiveStatus(n_new, TRUE); detectPos(); ctrlKeyEnter(hosts); dl_new = g_list_nth(drawlist,j+k); n_new = (DrawNode *) dl_new->data; setEntryActiveStatus(n_new, FALSE); } j+= k + 1; break; } } if (!posset && n_old->scrpos == 1) { dl_new = g_list_nth(drawlist,j); if (dl_new) { n_new = (DrawNode *) dl_new->data; if (n_new) { n_new->scrpos = 1; posset = TRUE; } } } if (!selset && n_old->selected) { savesel = j; selset = TRUE; } i++; dl_old = g_list_nth(old_drawlist,i); dl_new = g_list_nth(drawlist,j); } } dl_new = g_list_nth(drawlist,savesel); if (dl_new) { n_new = (DrawNode *) dl_new->data; if (n_new) setEntryActiveStatus(n_new, TRUE); } reorderScrpos(1); if(drawlist) freeDl(old_drawlist); else drawlist = old_drawlist; } void extDrawListCategory(gint atpos, gchar *category, GList *hosts) { guint i = 0; GList *ho; DrawNode *drawnode = NULL; DrawNode *parent = NULL; while(*(drawCategories+i)) { if(category == *(drawCategories+i)) break; i++; } if(!(*(drawCategories+i))) return; parent = g_list_nth_data(drawlist, (guint) atpos); ho = g_list_first(hosts); while(ho) { if( #ifdef FEAT_TCLFILTER (i == C_FILTERED) || #endif (((HostNode *) ho->data)->category == i) ) { if((drawnode) && (!g_ascii_strcasecmp(drawnode->p, ((HostNode *) ho->data)->group))) { if(((HostNode *) ho->data)->tagged == TRUE) drawnode->etagged++; ho = g_list_next(ho); continue; } gint elements = getHostGrpCatCnt(hosts, ((HostNode *) ho->data)->group, i); if(elements) { drawnode = g_new0(DrawNode, 1); #ifndef NDEBUG drawnode->_type = T_DRAWNODE; #endif drawnode->p = (((HostNode *) ho->data)->group); drawnode->type = GROUP; drawnode->extended = FALSE; drawnode->selected = FALSE; drawnode->scrpos = 0; drawnode->elements = elements; drawnode->attrs = A_NORMAL; drawnode->parent = parent; if(((HostNode *) ho->data)->tagged == TRUE) drawnode->etagged++; drawlist = g_list_insert(drawlist, drawnode, ++atpos); } } ho = g_list_next(ho); } reorderScrpos(1); } void extDrawListGroup(gint atpos, gchar *group, GList *hosts) { GList *ho; DrawNode *drawnode = NULL; DrawNode *parent = NULL; ho = g_list_first(hosts); parent = g_list_nth_data(drawlist, (guint) atpos); while(ho) { if(!g_ascii_strcasecmp(((HostNode *) ho->data)->group, group) && ( #ifdef FEAT_TCLFILTER (incategory == drawCategories[C_FILTERED] && ((HostNode *) ho->data)->filtered) || #endif (drawCategories[((HostNode *) ho->data)->category] == incategory) )) { drawnode = g_new0(DrawNode, 1); #ifndef NDEBUG drawnode->_type = T_DRAWNODE; #endif drawnode->p = ((HostNode *) ho->data); drawnode->type = HOST; drawnode->extended = FALSE; drawnode->selected = FALSE; drawnode->scrpos = 0; drawnode->parent = parent; if (((HostNode *) ho->data)->category != C_SESSIONS) drawnode->elements = ((HostNode *) ho->data)->nupdates + ((HostNode *) ho->data)->nholds + ((HostNode *) ho->data)->nextras + ((HostNode *) ho->data)->nbrokens; else drawnode->elements = g_list_length(((HostNode *) ho->data)->screens); drawnode->attrs = A_NORMAL; drawlist = g_list_insert(drawlist, drawnode, ++atpos); } ho = g_list_next(ho); } reorderScrpos(1); } void extDrawListHost(gint atpos, HostNode *n) { DrawNode *drawnode = NULL; DrawNode *parent = NULL; parent = g_list_nth_data(drawlist, (guint) atpos); ASSERT_TYPE(parent, T_DRAWNODE); if (n->category == C_SESSIONS) { GList *sess = g_list_first(n->screens); while(sess) { drawnode = g_new0(DrawNode, 1); #ifndef NDEBUG drawnode->_type = T_DRAWNODE; #endif drawnode->p = ((SessNode *)sess->data); drawnode->type = SESSION; drawnode->parent = parent; drawlist = g_list_insert(drawlist, drawnode, ++atpos); sess = g_list_next(sess); } reorderScrpos(1); return; } GList *upd = g_list_first(n->packages); while(upd) { if((((PkgNode *) upd->data)->flag & HOST_STATUS_PKGUPDATE) || (((PkgNode *) upd->data)->flag & HOST_STATUS_PKGKEPTBACK) || (((PkgNode *) upd->data)->flag & HOST_STATUS_PKGEXTRA) || (((PkgNode *) upd->data)->flag & HOST_STATUS_PKGBROKEN)) { drawnode = g_new0(DrawNode, 1); #ifndef NDEBUG drawnode->_type = T_DRAWNODE; #endif drawnode->type = PKG; drawnode->p = ((PkgNode *) upd->data); drawnode->attrs = (((PkgNode *) upd->data)->flag & HOST_STATUS_PKGUPDATE) ? A_BOLD : A_NORMAL; drawnode->parent = parent; drawlist = g_list_insert(drawlist, drawnode, ++atpos); } upd = g_list_next(upd); } reorderScrpos(1); } void shrinkDrawListCategory(gint atpos) { GList *dl; DrawNode *drawnode = NULL; dl = g_list_nth(drawlist, (guint) atpos+1); while(dl) { drawnode = ((DrawNode *) dl->data); if(drawnode->type != CATEGORY) { drawlist = g_list_remove(drawlist, drawnode); freeDrawNode(drawnode); } else break; dl = g_list_nth(drawlist, (guint) atpos+1); } reorderScrpos(1); } void shrinkDrawListGroup(gint atpos) { GList *dl; DrawNode *drawnode = NULL; dl = g_list_nth(drawlist, (guint) atpos+1); while(dl) { drawnode = ((DrawNode *) dl->data); if(drawnode->type != GROUP && drawnode->type != CATEGORY) { drawlist = g_list_remove(drawlist, drawnode); freeDrawNode(drawnode); } else break; dl = g_list_nth(drawlist, (guint) atpos+1); } reorderScrpos(1); } void shrinkDrawListHost(gint atpos) { GList *dl; DrawNode *drawnode = NULL; dl = g_list_nth(drawlist, (guint) atpos+1); while(dl) { drawnode = ((DrawNode *) dl->data); if(drawnode->type != GROUP && drawnode->type != CATEGORY && drawnode->type != HOST) { drawlist = g_list_remove(drawlist, drawnode); freeDrawNode(drawnode); } else break; dl = g_list_nth(drawlist, (guint) atpos+1); } reorderScrpos(1); } void extDrawList(gint atpos, gboolean extend, DrawNode *atn, GList *hosts) { if(!atn) return; if(extend == TRUE) { switch(atn->type) { case CATEGORY: extDrawListCategory(atpos, (gchar *) atn->p, hosts); break; case GROUP: extDrawListGroup(atpos, (gchar *) atn->p, hosts); break; case HOST: extDrawListHost(atpos, (HostNode *) atn->p); break; default: break; } } else { switch(atn->type) { case CATEGORY: shrinkDrawListCategory(atpos); break; case GROUP: shrinkDrawListGroup(atpos); break; case HOST: shrinkDrawListHost(atpos); break; default: break; } } } gboolean ctrlKeyEnter(GList *hosts) { gboolean ret = TRUE; gint extpos = 0; GList *dl; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) { extpos++; dl = g_list_next(dl); } if (((DrawNode *) dl->data)->elements == 0) return (ret); ((DrawNode *) dl->data)->extended = ((DrawNode *) dl->data)->extended == TRUE ? FALSE : TRUE; extDrawList(extpos, ((DrawNode *) dl->data)->extended,(DrawNode *) dl->data, hosts); return (ret); } gboolean ctrlKeyLeft(GList *hosts) { gboolean ret = TRUE; GList *dl, *dl_1; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); if (((DrawNode *) dl->data)->extended) ret = ctrlKeyEnter(hosts); else if (((DrawNode *) dl->data)->type > 0){ setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl_1 = dl; while (dl && (((DrawNode *) dl->data)->type == ((DrawNode *) dl_1->data)->type)) dl = g_list_previous(dl); if (dl) { setEntryActiveStatus((DrawNode *) dl->data, TRUE); if(((DrawNode *) dl->data)->scrpos == 0) { ((DrawNode *) dl->data)->scrpos = 1; reorderScrpos(1); } } else setEntryActiveStatus((DrawNode *) dl_1->data, TRUE); } else { setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_first(drawlist); if (dl) { ((DrawNode *) dl->data)->scrpos = 1; setEntryActiveStatus((DrawNode *) dl->data, TRUE); reorderScrpos(1); } } return (ret); } gboolean ctrlKeyRight(GList *hosts) { gboolean ret = TRUE; GList *dl; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); if (!((DrawNode *) dl->data)->extended) ret = ctrlKeyEnter(hosts); return (ret); } gboolean ctrlKeyPgDown() { gboolean ret = TRUE; GList *dl; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); setEntryActiveStatus((DrawNode *) dl->data, FALSE); reorderScrpos(bottomDrawLine); dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->scrpos != 1)) dl = g_list_next(dl); if(dl) setEntryActiveStatus((DrawNode *) dl->data, TRUE); else { dl = g_list_last(drawlist); if(dl) { setEntryActiveStatus((DrawNode *) dl->data, TRUE); ((DrawNode *) dl->data)->scrpos =1; } } return (ret); } gboolean ctrlKeyPgUp() { gboolean ret = TRUE; gint i = 0; GList *dl, *dl_1; dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->selected != TRUE)) dl = g_list_next(dl); setEntryActiveStatus((DrawNode *) dl->data, FALSE); dl = g_list_first(drawlist); while (dl && (((DrawNode *) dl->data)->scrpos != 1)) dl = g_list_next(dl); dl_1 = dl; dl_1 = g_list_previous(dl_1); while (dl && (++i < bottomDrawLine)) dl = g_list_previous(dl); if (dl && dl_1) { ((DrawNode *) dl->data)->scrpos =1; setEntryActiveStatus((DrawNode *) dl_1->data, TRUE); } else { dl = g_list_first(drawlist); if(dl) { ((DrawNode *) dl->data)->scrpos =1; setEntryActiveStatus((DrawNode *) dl->data, TRUE); } } reorderScrpos(1); return (ret); } void injectKey(int ch) { ungetch(ch); } static void expandAllNodes(GList *hosts) { gint i; GList *dl = NULL; /* UGLY: expand everything (so the matched host is on the drawlist) */ for(i=2; i>0; i--) { dl = g_list_first(drawlist); while(dl) { DrawNode *dn = (DrawNode *) dl->data; if(dn->type != HOST) dn->extended = TRUE; dl = g_list_next(dl); } rebuildDrawList(hosts); } g_completion_clear_items (dlCompl); g_completion_add_items (dlCompl, drawlist); } void searchEntry(GList *hosts) { gint c; gchar s[BUF_MAX_LEN]; gint pos = 0; const gchar *query = _("Search: "); const int offset = strlen(query)-1; GList *matches = NULL; GList *selmatch = NULL; GList *dl = NULL; GList *dlkeep = NULL; enableInput(); noecho(); memset(s, 0, sizeof(s)); drawQuery(query, 0); while((c = getch())) { /* handle backspace */ if(c == KEY_BACKSPACE) { if (strlen(s)>0) { s[--pos] = 0; if(strlen(s)>0) expandAllNodes(hosts); selmatch = NULL; } else beep(); } /* search again */ else if((c == '/') || (c == '\t')) { if(selmatch && matches) { selmatch = g_list_next(selmatch); if(!selmatch) selmatch = g_list_first(matches); } if(!selmatch) beep(); } /* abort on control key */ else if(iscntrl(c) || c==KEY_LEFT || c==KEY_DOWN) { if((c==KEY_UP) || (c==KEY_DOWN)) ungetch(c); break; } /* accept char */ else if(strlen(s) 0)) { beep(); s[--pos] = 0; if(pos>0) matches = g_completion_complete(dlCompl, s, NULL); } /* print new search string */ else { attron(uicolors[UI_COLOR_INPUT]); mvaddstr(LINES-1, offset+1, s); attroff(uicolors[UI_COLOR_INPUT]); } /* check if selected match is still valid... or get new one */ if(matches) { if(selmatch) { if(!g_list_find(matches, selmatch->data)) selmatch = g_list_first(matches); } else selmatch = g_list_first(matches); if(selmatch) { attron(uicolors[UI_COLOR_INPUT]); attron(A_REVERSE); gchar *selstr = getStrFromDrawNode((DrawNode *) selmatch->data); mvaddstr(LINES-1, offset+pos+1, &selstr[pos]); attroff(A_REVERSE); attroff(uicolors[UI_COLOR_INPUT]); remln(COLS-offset-strlen(&selstr[pos])-1); } else remln(COLS-offset-pos-1); /* we have a match which is selected */ if(selmatch) { /* Shrink all drawnodes which are not matches. */ GList *m = g_list_first(matches); while(m) { DrawNode *parent = ((DrawNode *) m->data)->parent; while(parent) { /* Keep the following drawnodes extended. */ dlkeep = g_list_append(dlkeep, parent); parent = parent->parent; } m = g_list_next(m); } dl = g_list_last(drawlist); while(dl) { DrawNode *dn = (DrawNode *) dl->data; if(dn->extended == TRUE) { GList *k = g_list_first(dlkeep); while(k) { if(k->data == dn) break; k = g_list_next(k); } /* Shrink the list, if is not found in the search list. */ if(!k) { dn->extended = FALSE; extDrawList(g_list_index(drawlist, dn), FALSE, dn, hosts); } } dl = g_list_previous(dl); } if(dlkeep) { g_list_free(dlkeep); dlkeep = NULL; } /* clear selection */ DrawNode *n = getSelectedDrawNode(); if (n) setEntryActiveStatus(n, FALSE); /* traverse drawlist bottom up... and only expand * the path to the selmatch */ dl = g_list_last(drawlist); while(dl) { DrawNode *dn = (DrawNode *) dl->data; dn->scrpos = 0; if(selmatch->data == dn) { setEntryActiveStatus(dn, TRUE); dn->scrpos = 1; reorderScrpos(1); break; } dl = g_list_previous(dl); } cleanBetween(); g_list_foreach(drawlist, (GFunc) drawEntry, NULL); } } else remln(COLS-offset-pos-1); /* print matches in status bar */ if(matches) { gint dssize = COLS+1; gchar *dsstr = NULL; dsstr = g_malloc0(dssize); if(!dsstr) break; g_strlcat(dsstr, _("Matches:"), dssize); GList *m = g_list_first(matches); while(m) { g_strlcat(dsstr, " ", dssize); DrawNode *dn = (DrawNode *) m->data; g_strlcat(dsstr, getStrFromDrawNode(dn), dssize); m = g_list_next(m); } drawStatus(dsstr, FALSE); g_free(dsstr); } else { drawStatus(_("Matches: -"), FALSE); selmatch = NULL; } /* move to cursor position */ move(LINES-1, offset+pos+1); refresh(); } attroff(uicolors[UI_COLOR_INPUT]); disableInput(); move(LINES - 1, 0); remln(COLS); drawStatus ("", TRUE); } #ifdef FEAT_TCLFILTER void applyFilter(GList *hosts) { if(!strlen(filterexp)) return; gint i; gboolean filtered; GList *l = hosts; Tcl_Preserve(tcl_interp); while(l) { HostNode *n = (HostNode *)l->data; for(i=0; tclmap[i].name; i++) { switch(tclmap[i].type) { case TCLM_STRING: switch(tclmap[i].code) { case TCLMK_GROUP: Tcl_SetVar(tcl_interp, tclmap[i].name, n->group, 0); break; case TCLMK_HOSTNAME: Tcl_SetVar(tcl_interp, tclmap[i].name, n->hostname, 0); break; case TCLMK_KERNEL: Tcl_SetVar(tcl_interp, tclmap[i].name, n->kernelrel, 0); break; case TCLMK_LSBCNAME: Tcl_SetVar(tcl_interp, tclmap[i].name, n->lsb_codename, 0); break; case TCLMK_LSBDISTRI: Tcl_SetVar(tcl_interp, tclmap[i].name, n->lsb_distributor, 0); break; case TCLMK_LSBREL: Tcl_SetVar(tcl_interp, tclmap[i].name, n->lsb_release, 0); break; case TCLMK_UNKERNEL: Tcl_SetVar(tcl_interp, tclmap[i].name, n->uname_kernel, 0); break; case TCLMK_UNMACHINE: Tcl_SetVar(tcl_interp, tclmap[i].name, n->uname_machine, 0); break; case TCLMK_VIRT: Tcl_SetVar(tcl_interp, tclmap[i].name, n->virt, 0); break; default: g_warning(_("Internal error: unhandled TCL TCLM_STRING mapping!")); } break; case TCLM_INT: { gchar *h = NULL; switch(tclmap[i].code) { case TCLMK_CATEGORY: h = g_strdup_printf("%d", n->category); break; case TCLMK_FORBID: h = g_strdup_printf("%d", n->forbid); break; default: g_warning(_("Internal error: unhandled TCL TCLM_INT mapping!")); } Tcl_SetVar(tcl_interp, tclmap[i].name, h, 0); g_free(h); } break; case TCLM_IGNORE: break; default: g_warning(_("Internal error: unknown TCL mapping type!")); } } Tcl_UnsetVar(tcl_interp, "updates", 0); Tcl_UnsetVar(tcl_interp, "installed", 0); Tcl_UnsetVar(tcl_interp, "extras", 0); Tcl_UnsetVar(tcl_interp, "holds", 0); GList *p = n->packages; while(p) { Tcl_SetVar2(tcl_interp, "installed", ((PkgNode *)(p->data))->package, ((PkgNode *)(p->data))->version, 0); if( ((PkgNode *)p->data)->flag & HOST_STATUS_PKGUPDATE) Tcl_SetVar2(tcl_interp, "updates", ((PkgNode *)(p->data))->package, ((PkgNode *)(p->data))->data, 0); if( ((PkgNode *)p->data)->flag & HOST_STATUS_PKGKEPTBACK) Tcl_SetVar2(tcl_interp, "holds", ((PkgNode *)(p->data))->package, ((PkgNode *)(p->data))->data, 0); if( ((PkgNode *)p->data)->flag & HOST_STATUS_PKGEXTRA) Tcl_SetVar2(tcl_interp, "extras", ((PkgNode *)(p->data))->package, ((PkgNode *)(p->data))->version, 0); p = g_list_next(p); } Tcl_UnsetVar(tcl_interp, "flags", 0); for(i=0; hostFlags[i].code; i++) { if(n->status & hostFlags[i].flag) Tcl_SetVar2(tcl_interp, "flags", hostFlags[i].code, hostFlags[i].code, 0); } #ifdef FEAT_CLUSTERS Tcl_UnsetVar(tcl_interp, "clusters", 0); GList *c = n->clusters; while(c) { Tcl_SetVar2(tcl_interp, "clusters", c->data, c->data, 0); c = g_list_next(c); } #endif Tcl_ResetResult(tcl_interp); switch(Tcl_Eval(tcl_interp, filterexp)) { case TCL_OK: case TCL_RETURN: filtered = atoi(Tcl_GetStringResult(tcl_interp)) > 0; ;; default: filtered = FALSE; ;; } if(filtered != n->filtered) { n->filtered = filtered; rebuilddl = TRUE; } l = g_list_next(l); } /* while */ Tcl_Release(tcl_interp); } static void filterHosts(GList *hosts) { gint i, r; gint first; WINDOW *w = newwin(LINES-3, COLS, 2, 0); wattron(w, uicolors[UI_COLOR_QUERY]); mvwaddstr(w, 1, 0, _("Scalars:")); wattroff(w, uicolors[UI_COLOR_QUERY]); waddstr(w, "\n"); first = 1; for(i=0; tclmap[i].name; i++) { if((tclmap[i].type != TCLM_STRING) && (tclmap[i].type != TCLM_INT)) continue; if(!first) waddstr(w, ", "); else first = 0; waddstr(w, tclmap[i].name); } waddstr(w, "\n\n"); wattron(w, uicolors[UI_COLOR_QUERY]); waddstr(w, _("Arrays:")); wattroff(w, uicolors[UI_COLOR_QUERY]); waddstr(w, "\n"); first = 1; for(i=0; tclmap[i].name; i++) { if(tclmap[i].type != TCLM_IGNORE) continue; if(!first) waddstr(w, ", "); else first = 0; waddstr(w, tclmap[i].name); } waddstr(w, "\n\n"); wattron(w, uicolors[UI_COLOR_QUERY]); waddstr(w, _("Examples:")); wattroff(w, uicolors[UI_COLOR_QUERY]); waddstr(w, "\n"); waddstr(w, "return [expr [string compare $lsb_distri \"Debian\"] == 0]\n"); waddstr(w, "return [expr [string compare $lsb_distri \"Debian\"] == 0 && $lsb_rel < 4.0]\n"); waddstr(w, "return [llength [array names installed \"bind*\"]]\n"); waddstr(w, "return [expr [string compare $virt \"Xen\"] == 0]\n"); waddstr(w, "\n"); wattron(w, uicolors[UI_COLOR_QUERY]); waddstr(w, _("Enter filter expression:")); wattroff(w, uicolors[UI_COLOR_QUERY]); waddstr(w, "\n"); enableInput(); wattron(w, uicolors[UI_COLOR_INPUT]); for(i = strlen(filterexp)-1; i>=0; i--) ungetch(filterexp[i]); r = getnLine(w, filterexp, sizeof(filterexp)-1, FALSE); disableInput(); wattroff(w, uicolors[UI_COLOR_INPUT]); delwin(w); refreshDraw(); if(r) applyFilter(hosts); } #endif #ifdef FEAT_HISTORY static void handleErrors(HostNode *n) { int c; HistoryEntry *he = history_recent_entry(n); if(!he) return; gchar *query; if(HOST_SSHPORT_SET(n)) query = g_strdup_printf(_("An error at %s:%d has been detected [Less/ignore/connect]: "), n->hostname, n->ssh_port); else query = g_strdup_printf(_("An error at %s has been detected [Less/ignore/connect]: "), n->hostname); notifyUser(); while(1) { enableInput(); drawQuery(query, 0); move(LINES - 1, strlen(query)); attron(uicolors[UI_COLOR_INPUT]); c = getch(); attroff(uicolors[UI_COLOR_INPUT]); disableInput(); move(LINES - 1, 0); remln(COLS); switch(c) { /* ignore */ case 27: case 'i': case 'I': case 'q': case 'Q': history_free_he(he); return; /* connect */ case 'c': case 'C': history_free_he(he); ignoreSIGINT(TRUE); endwin(); ssh_connect(n, FALSE); ignoreSIGINT(FALSE); refresh(); return; default: ignoreSIGINT(TRUE); endwin(); history_show_less_search(he, cfg->history_errpattern); ignoreSIGINT(FALSE); refresh(); break; } } history_free_he(he); } #endif gboolean ctrlUI (GList *hosts) { gint hostcnt; int ic, i; gboolean ret = TRUE; gboolean retqry = FALSE; gboolean refscr = FALSE; DrawNode *n; static gchar in[INPUT_MAX], in2[INPUT_MAX]; static gboolean keytagactive = FALSE; gchar *qrystr = NULL; gchar *pkg = NULL; guint sc = SC_MAX; if(rebuilddl == TRUE) { rebuildDrawList(hosts); refscr = TRUE; } if((ic = getch()) == -1) refresh(); else for(i = 0; shortCuts[i].keycode; i++) if(shortCuts[i].keycode == ic) sc = shortCuts[i].sc; #ifdef KEY_RESIZE if(ic == KEY_RESIZE) { refscr = TRUE; dump_screen = FALSE; bottomDrawLine = LINES-2; clear(); } #endif if(sc != SC_MAX) { if(keytagactive == TRUE) sc+=TAGGED_MASK; switch(sc) { case SC_KEY_HOME: case SC_KEY_END: case SC_KEY_UP: case SC_KEY_DOWN: case SC_KEY_UP2: case SC_KEY_DOWN2: refscr = ctrlKeyUpDown(ic); break; /* case SC_KEY_DOWN */ case SC_KEY_PPAGE: refscr = ctrlKeyPgUp(); break; /* case SC_KEY_PPAGE */ case SC_KEY_NPAGE: refscr = ctrlKeyPgDown(); break; /* case SC_KEY_NPAGE */ case SC_KEY_LEFT: case SC_KEY_LEFT2: refscr = ctrlKeyLeft(hosts); break; /* case SC_KEY_LEFT */ case SC_KEY_RIGHT: case SC_KEY_RIGHT2: refscr = ctrlKeyRight(hosts); break; /* case SC_KEY_RIGHT */ case SC_KEY_PLUS: case SC_KEY_SPACE: case SC_KEY_ENTER: case SC_KEY_RETURN: refscr = ctrlKeyEnter(hosts); break; /* case SC_KEY_RETURN */ case SC_KEY_REFRESH: n = getSelectedDrawNode(); if(!n) break; if(n->type == HOST) { if(n->extended == TRUE) n->extended = FALSE; ((HostNode *) n->p)->category = C_REFRESH_REQUIRED; rebuildDrawList(hosts); refscr = TRUE; } else if(n->type == GROUP) { if(n->extended == TRUE) n->extended = FALSE; if(drawCategories[getCategoryNumber(incategory)]) { setHostsCategory(hosts, getCategoryNumber(incategory), ingroup, (Category) C_REFRESH_REQUIRED); rebuildDrawList(hosts); refscr = TRUE; } } else if(n->type == CATEGORY) { if(n->extended == TRUE) n->extended = FALSE; if(drawCategories[getCategoryNumber(incategory)]) { setHostsCategory(hosts, getCategoryNumber(incategory), NULL, (Category) C_REFRESH_REQUIRED); rebuildDrawList(hosts); refscr = TRUE; } } break; /* case SC_KEY_REFRESH */ case SC_KEY_REFRESH+TAGGED_MASK: { GList *thosts = NULL; GList *ho = g_list_first(hosts); while(ho) { HostNode *m = (HostNode *)ho->data; if(m->tagged == TRUE) thosts = g_list_prepend(thosts, m); ho = g_list_next(ho); } if(thosts && g_list_length (thosts) > 0) { qrystr = g_strdup_printf(_("Refresh %d tagged hosts? [y/N]: "), g_list_length (thosts)); retqry = queryConfirm(qrystr, FALSE, NULL); g_free(qrystr); if(retqry == TRUE) { GList *ho = g_list_first(thosts); while(ho) { HostNode *m = (HostNode *)ho->data; m->category = C_REFRESH_REQUIRED; refscr = TRUE; ho = g_list_next(ho); } if(refscr == TRUE) rebuildDrawList(hosts); } g_list_free (thosts); } } break; /* case SC_KEY_REFRESH + KEY_TAGGED_MASK */ case SC_KEY_TAGACTION: { GList *ho = g_list_first(hosts); while(ho) { if(((HostNode *)ho->data)->tagged == TRUE) break; ho = g_list_next(ho); } if(ho) { keytagactive = !keytagactive; if(keytagactive == TRUE) { drawQuery(_("tag-"), 0); curs_set(1); } } else beep(); } /* case SC_KEY_TAGACTION */ break; case SC_KEY_CONNECT: n = getSelectedDrawNode(); if(!n) break; if(n->type == HOST) { if(n->extended == TRUE) n->extended = FALSE; if (g_list_length(inhost->screens)) { if (!queryConfirm(_("There are running sessions on this host! Continue? [y/N]: "), FALSE, NULL)) break; } dump_screen = FALSE; cleanUI(); ssh_connect((HostNode *) n->p, FALSE); ((HostNode *) n->p)->category = C_REFRESH_REQUIRED; rebuildDrawList(hosts); initUI(); refscr = TRUE; } break; /* case SC_KEY_CONNECT */ case SC_KEY_UPGRADE: n = getSelectedDrawNode(); if(!n) break; switch(n->type) { case HOST: if(inhost->forbid & HOST_FORBID_UPGRADE) break; if(n->extended == TRUE) n->extended = FALSE; if (g_list_length(inhost->screens)) { if (!queryConfirm(_("There are running sessions on this host! Continue? [y/N]: "), FALSE, NULL)) break; } cleanUI(); #ifdef FEAT_HISTORY gboolean f = #endif ssh_cmd_upgrade((HostNode *) n->p, FALSE); #ifdef FEAT_HISTORY if(f) handleErrors((HostNode *) n->p); #endif ((HostNode *) n->p)->category = C_REFRESH_REQUIRED; rebuildDrawList(hosts); initUI(); refscr = TRUE; break; case CATEGORY: case GROUP: default: { if(((n->type == CATEGORY) && !queryConfirm(_("Run update for the whole category? [y/N]: "), FALSE, NULL)) || ((n->type == GROUP) && !queryConfirm(_("Run update for the whole group? [y/N]: "), FALSE, NULL))) break; GList *ho = g_list_first(hosts); gint cat = getCategoryNumber(incategory); while(ho) { HostNode *m = (HostNode *)ho->data; #ifdef FEAT_TCLFILTER if((n->type == GROUP && (strcmp(m->group, ingroup) == 0) && ((cat == C_FILTERED && m->filtered == TRUE) || m->category == cat)) || (n->type == CATEGORY && ((cat == C_FILTERED && m->filtered == TRUE) || m->category == cat))) { #else if((n->type == GROUP && (strcmp(m->group, ingroup) == 0) && m->category == cat) || (n->type == CATEGORY && m->category == cat)) { #endif if(m->forbid ^ HOST_FORBID_UPGRADE) ssh_cmd_upgrade(m, TRUE); } ho = g_list_next(ho); } } break; } break; /* case SC_KEY_UPGRADE */ case SC_KEY_UPGRADE + TAGGED_MASK: { GList *thosts = NULL; GList *ho = g_list_first(hosts); while(ho) { HostNode *m = (HostNode *)ho->data; if(m->forbid ^ HOST_FORBID_UPGRADE && m->nupdates > 0 && m->tagged == TRUE) thosts = g_list_prepend(thosts, m); ho = g_list_next(ho); } if(thosts && g_list_length (thosts) > 0) { qrystr = g_strdup_printf(_("Run update for %d tagged and updatable hosts? [y/N]: "), g_list_length (thosts)); retqry = queryConfirm(qrystr, FALSE, NULL); g_free(qrystr); if(retqry == TRUE) { GList *ho = g_list_first(thosts); while(ho) { HostNode *m = (HostNode *)ho->data; ssh_cmd_upgrade(m, TRUE); ho = g_list_next(ho); } } g_list_free (thosts); } else beep(); } break; /* case SC_KEY_UPGRADE + TAGGED_MASK */ case SC_KEY_INSTALL: n = getSelectedDrawNode(); if(!n) break; switch(n->type) { case PKG: if(n->p && (inhost->forbid ^ HOST_FORBID_INSTALL)) { pkg = ((PkgNode *) n->p)->package; if(((PkgNode *) n->p)->flag & HOST_STATUS_PKGUPDATE) { qrystr = g_strdup_printf(_("Install package `%s' [y/N]: "), pkg); if(!qrystr) break; retqry = queryConfirm(qrystr, FALSE, NULL); g_free(qrystr); qrystr = NULL; } else { if(queryString(_("Install package: "), in, sizeof(in)-1) == FALSE) break; if (strlen(in)==0) break; pkg = in; retqry = TRUE; } if(retqry == TRUE) { cleanUI(); ssh_cmd_install(inhost, pkg, FALSE); inhost->category = C_REFRESH_REQUIRED; rebuildDrawList(hosts); initUI(); refscr = TRUE; } } break; case HOST: if(n->extended == TRUE) n->extended = FALSE; if(inhost->forbid & HOST_FORBID_INSTALL) break; if (g_list_length(inhost->screens)) { if (!queryConfirm(_("There are running sessions on this host! Continue? [y/N]: "), FALSE, NULL)) break; } if(queryString(_("Install package: "), in, sizeof(in)-1) == FALSE) break; if (strlen(in)==0) break; pkg = in; cleanUI(); ssh_cmd_install(inhost, pkg, FALSE); inhost->category = C_REFRESH_REQUIRED; rebuildDrawList(hosts); initUI(); refscr = TRUE; break; case CATEGORY: case GROUP: default: { if(queryString(_("Install package: "), in, sizeof(in)-1) == FALSE) break; if (strlen(in)==0) break; if(((n->type == CATEGORY) && !queryConfirm(_("Run install for the whole category? [y/N]: "), FALSE, NULL)) || ((n->type == GROUP) && !queryConfirm(_("Run install for the whole group? [y/N]: "), FALSE, NULL))) break; GList *ho = g_list_first(hosts); gint cat = getCategoryNumber(incategory); while(ho) { HostNode *m = (HostNode *)ho->data; #ifdef FEAT_TCLFILTER if((n->type == GROUP && (strcmp(m->group, ingroup) == 0) && ((cat == C_FILTERED && m->filtered == TRUE) || m->category == cat)) || (n->type == CATEGORY && ((cat == C_FILTERED && m->filtered == TRUE) || m->category == cat))) { #else if((n->type == GROUP && (strcmp(m->group, ingroup) == 0) && m->category == cat) || (n->type == CATEGORY && m->category == cat)) { #endif if(m->forbid ^ HOST_FORBID_INSTALL) ssh_cmd_install(m, in, TRUE); } ho = g_list_next(ho); } } break; } break; /* case SC_KEY_INSTALL */ case SC_KEY_INSTALL + TAGGED_MASK: { GList *thosts = NULL; GList *ho = g_list_first(hosts); while(ho) { HostNode *m = (HostNode *)ho->data; if(m->forbid ^ HOST_FORBID_INSTALL && m->tagged == TRUE) thosts = g_list_prepend(thosts, m); ho = g_list_next(ho); } if(thosts && g_list_length (thosts) > 0) { qrystr = g_strdup_printf(_("Install package on %d tagged hosts: "), g_list_length (thosts)); if(!qrystr) break; retqry = TRUE; if(queryString(qrystr, in, sizeof(in)-1) == FALSE) retqry = FALSE; if (strlen(in)==0) retqry = FALSE; g_free(qrystr); if(retqry == TRUE) { pkg = in; GList *ho = g_list_first(thosts); while(ho) { HostNode *m = (HostNode *)ho->data; ssh_cmd_install(m, pkg, TRUE); ho = g_list_next(ho); } } g_list_free (thosts); } else beep(); } break; /* case SC_KEY_INSTALL + TAGGED_MASK */ case SC_KEY_TAGMATCH: case SC_KEY_UNTAGMATCH: { if(queryString(sc == SC_KEY_TAGMATCH ? _("Tag hosts matching: ") : _("Untag hosts matching: "), in2, sizeof(in2)-1) == FALSE) break; if (strlen(in2)==0) break; GList *ho = g_list_first(hosts); while(ho) { HostNode *n = (HostNode *)ho->data; if(strlen(n->hostname) >= strlen(in2)) { if(compHostWithPattern (n, in2, strlen(in2)) == TRUE) { n->tagged= sc == SC_KEY_TAGMATCH ? TRUE : FALSE; refscr= TRUE; } } ho = g_list_next(ho); } if(refscr == FALSE) beep(); else { GList *dl = g_list_first(drawlist); while(dl) { DrawNode *drawnode = dl->data; if(drawnode->type == CATEGORY) { i=0; while(*(drawCategories+i)) { if(*(drawCategories+i) == drawnode->p) drawnode->etagged = getHostCatTaggedCnt(hosts, i); i++; } } else if(drawnode->type == GROUP) { i=0; while(*(drawCategories+i)) { if(*(drawCategories+i) == drawnode->parent->p) drawnode->etagged = getHostGrpCatTaggedCnt(hosts, drawnode->p, i); i++; } } dl = g_list_next(dl); } refscr = TRUE; } } break; /* case SC_KEY_TAGMATCH */ case SC_KEY_CYCLESESS: case SC_KEY_NEXTSESS: { /* Count the number of screens */ GList *ho = g_list_first(hosts); i=0; while(ho) { HostNode *m = (HostNode *)ho->data; GList *scr = m->screens; if(scr) i+=g_list_length (scr); ho = g_list_next(ho); } ho = g_list_first(hosts); while(ho) { gboolean cancel = FALSE; HostNode *m = (HostNode *)ho->data; GList *scr = m->screens; while(scr) { qrystr = g_strdup_printf(_("Attach host %s session %d (%d %s left) [Y/n/c]: "), m->hostname, ((SessNode *)scr->data)->pid, i, i == 1 ? _("session") : _("sessions")); i--; if(!qrystr) { g_warning(_("Out of memory.")); break; } retqry = queryConfirm(qrystr, TRUE, &cancel); g_free(qrystr); qrystr = NULL; if(cancel == TRUE) { ho = NULL; break; } if(retqry == FALSE) { scr = g_list_next(scr); continue; } if (!screen_is_attached((SessNode *)scr->data)) { cleanUI(); #ifdef FEAT_HISTORY gboolean f = #endif screen_attach(m, (SessNode *)scr->data, FALSE); #ifdef FEAT_HISTORY if(f) handleErrors(m); #endif initUI(); if(ic != getKeyForShortcut(sc)) { ho = NULL; break; } } scr = g_list_next(scr); } if(ho) ho = g_list_next(ho); } } break; /* case SC_KEY_NEXTSESS */ case SC_KEY_ATTACH: n = getSelectedDrawNode(); if(!inhost) break; SessNode *s = NULL; if(!n || (n->type != SESSION)) { GList *l = g_list_first(inhost->screens); if (l) s = l->data; } else { s = (SessNode *) n->p; } if(!s) break; { gboolean may_share = FALSE; /* Session already attached! */ if (screen_is_attached(s)) { if (!queryConfirm(_("Already attached - share session? [y/N]: "), FALSE, NULL)) break; may_share = TRUE; } dump_screen = FALSE; cleanUI(); #ifdef FEAT_HISTORY gboolean f = #endif screen_attach(inhost, s, may_share); #ifdef FEAT_HISTORY if(f) handleErrors(inhost); #endif initUI(); } refscr = TRUE; break; /* case SC_KEY_ATTACH */ case SC_KEY_TOGGLEDUMPS: if (!cfg->dump_screen) break; dump_screen = !dump_screen; if(getSelectedDrawNode()->type != SESSION) { if(dump_screen) drawQuery(_("Session dumps enabled."), G_USEC_PER_SEC/2); else drawQuery(_("Session dumps disabled."), G_USEC_PER_SEC/2); } else refscr = TRUE; break; /* case SC_KEY_TOGGLEDUMPS */ case SC_KEY_HELP: { drawHelp(); refscr = TRUE; } break; /* case SC_KEY_HELP */ case SC_KEY_MORE: if (inhost) { drawHostDetails(inhost); refscr = TRUE; } break; /* case SC_KEY_MORE */ case SC_KEY_ERRDIAG: if (inhost) { drawHostErrDiag(inhost); refscr = TRUE; } break; /* case SC_KEY_ERRDIAG */ #ifdef FEAT_HISTORY case SC_KEY_HISTORY: if (inhost) { drawHistoryEntries (inhost); refscr = TRUE; } break; /* case SC_KEY_HISTORY */ #endif case SC_KEY_FIND: searchEntry(hosts); refscr = TRUE; break; case SC_KEY_TAG: n = getSelectedDrawNode(); if(!n) break; if(n->type == HOST) { ((HostNode *) n->p)->tagged = !((HostNode *) n->p)->tagged; DrawNode *p = n->parent; while(p) { p->etagged+= ((HostNode *) n->p)->tagged == TRUE ? 1 : -1; drawEntry(p); p = p->parent; } drawEntry(n); } else beep(); break; #ifdef FEAT_TCLFILTER case SC_KEY_FILTER: filterHosts(hosts); rebuildDrawList(hosts); refscr = TRUE; break; #endif case SC_KEY_FILETRANS: n = getSelectedDrawNode(); if(!n) break; if(n->type == HOST) { if(n->extended == TRUE) n->extended = FALSE; cleanUI(); sftp_connect((HostNode *) n->p); initUI(); refscr = TRUE; } break; /* case SC_KEY_FILETRANS */ case SC_KEY_QUIT: hostcnt = 0; GList *ho = g_list_first(hosts); while(ho) { HostNode *m = (HostNode *)ho->data; if(m->category == C_REFRESH_REQUIRED || m->category == C_REFRESH) hostcnt++; ho = g_list_next(ho); } if(hostcnt > 0) { if (hostcnt != 1) { qrystr = g_strdup_printf(_("There are %d hosts in status refresh state, quit apt-dater? [y/N]: "), hostcnt); } else { qrystr = g_strdup_printf(_("There is %d host in status refresh state, quit apt-dater? [y/N]: "), hostcnt); } retqry = queryConfirm(qrystr, FALSE, NULL); g_free(qrystr); if (retqry == FALSE) break; } #ifdef FEAT_TCLFILTER if (!Tcl_InterpDeleted(tcl_interp)) Tcl_DeleteInterp(tcl_interp); #endif if(dlCompl) g_completion_free (dlCompl); ret = FALSE; attrset(A_NORMAL); cleanUI(); refreshUI(); refscr = FALSE; g_main_loop_quit (loop); break; /* case SC_KEY_QUIT */ default: break; } /* switch (sc) */ } if(((keytagactive == TRUE && sc != SC_KEY_TAGACTION) || (keytagactive == FALSE && SC_KEY_TAGACTION)) && ic != -1) { keytagactive = FALSE; refscr = TRUE; curs_set(0); remln(COLS); } if(refscr == TRUE) { getOldestMtime(hosts); refreshDraw(); } /* Redraw only the an session entry if screen dump enabled. */ if(dump_screen && (n = getSelectedDrawNode()) && n->type==SESSION && win_dump) refreshDumpWindow(n); return (ret); } apt-dater-0.9.0/src/ui.h0000644000175000017500000000676711760757134014361 0ustar thomasthomas/* apt-dater - terminal-based remote package update manager * * Authors: * Andre Ellguth * Thomas Liske * * Copyright Holder: * 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] * * License: * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this package; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef _UI_H #define _UI_H #ifdef HAVE_NCURSES_H #include #else #include #endif #include typedef enum { CATEGORY, GROUP, HOST, PKG, SESSION, } DrawType; typedef enum { VK_ATTACH=1, VK_CONNECT=2, VK_DUMP=4, VK_UPGRADE=8, VK_INSTALL=16, VK_REFRESH=32, VK_KILL=64, VK_ERRDIAG=128, #ifdef FEAT_HISTORY VK_PLAY=256, VK_LESS=512, #endif } EVisKeyMask; typedef enum { SC_KEY_LEFT = 0, SC_KEY_LEFT2, SC_KEY_RIGHT, SC_KEY_RIGHT2, SC_KEY_UP, SC_KEY_UP2, SC_KEY_DOWN, SC_KEY_DOWN2, SC_KEY_HOME, SC_KEY_END, SC_KEY_PPAGE, SC_KEY_NPAGE, SC_KEY_SPACE, SC_KEY_RETURN, SC_KEY_ENTER, SC_KEY_PLUS, SC_KEY_QUIT, SC_KEY_HELP, SC_KEY_FIND, SC_KEY_FILTER, SC_KEY_ATTACH, SC_KEY_KILLSESS, SC_KEY_CONNECT, SC_KEY_FILETRANS, SC_KEY_TOGGLEDUMPS, SC_KEY_REFRESH, SC_KEY_TAGACTION, SC_KEY_INSTALL, SC_KEY_UPGRADE, SC_KEY_MORE, SC_KEY_ERRDIAG, #ifdef FEAT_HISTORY SC_KEY_HISTORY, SC_KEY_PLAY, SC_KEY_LESS, #endif SC_KEY_NEXTSESS, SC_KEY_CYCLESESS, SC_KEY_TAG, SC_KEY_TAGMATCH, SC_KEY_UNTAGMATCH, SC_KEY_UNUSED, SC_MAX, } EShortCuts; #define TAGGED_MASK 100000 typedef struct _drawnode { #ifndef NDEBUG etype _type; #endif void *p; DrawType type; gboolean extended; gboolean selected; guint scrpos; guint elements; guint etagged; int attrs; struct _drawnode *parent; } DrawNode; struct HostFlag { gint flag; gchar *code; gchar *descr; }; gboolean ctrlKeyEnter(GList *hosts); void doUI (GList *hosts); void refreshUI(); void refreshDraw(); gboolean ctrlUI (GList *); void cleanUI(); void injectKey(int); void applyFilter(GList *hosts); void disableInput(); void enableInput(); void reorderScrpos(guint); gchar *getStrFromDrawNode (DrawNode *); void freeDrawNode (DrawNode *); void notifyUser(); void drawStatus (char *str, gboolean drawoldest); #include "apt-dater.h" extern gchar maintainer[48]; extern gchar *drawCategories[]; extern const struct HostFlag hostFlags[]; #ifndef KEY_RETURN # define KEY_RETURN 13 #endif #ifndef KEY_ESC # define KEY_ESC 27 #endif #ifndef KEY_FWWORD # define KEY_FWWORD 102 #endif #ifndef KEY_BWWORD # define KEY_BWWORD 98 #endif #ifndef KEY_KILLEOW # define KEY_KILLEOW 100 #endif #ifndef KEY_KILLBOW # define KEY_KILLBOW 23 #endif #define ctrl(c) ((c)-'@') #define remln(cols) hline(' ', cols); #define mvremln(y, x, cols) mvhline(y, x, ' ', cols); #define mvwremln(win, y, x, cols) mvwhline(win, y, x, ' ', cols); #endif /* _UI_H */ apt-dater-0.9.0/src/Makefile.in0000644000175000017500000003721311761141270015613 0ustar thomasthomas# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ bin_PROGRAMS = apt-dater$(EXEEXT) subdir = src DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_apt_dater_OBJECTS = apt-dater.$(OBJEXT) colors.$(OBJEXT) \ exec.$(OBJEXT) keyfiles.$(OBJEXT) lock.$(OBJEXT) \ parsecmd.$(OBJEXT) report.$(OBJEXT) screen.$(OBJEXT) \ sighandler.$(OBJEXT) stats.$(OBJEXT) ui.$(OBJEXT) \ autoref.$(OBJEXT) tag.$(OBJEXT) history.$(OBJEXT) \ env.$(OBJEXT) clusters.$(OBJEXT) apt_dater_OBJECTS = $(am_apt_dater_OBJECTS) am__DEPENDENCIES_1 = apt_dater_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(apt_dater_SOURCES) DIST_SOURCES = $(apt_dater_SOURCES) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CURSES_LIB = @CURSES_LIB@ CYGPATH_W = @CYGPATH_W@ DBXSL = @DBXSL@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FREEBSD_FALSE = @FREEBSD_FALSE@ FREEBSD_TRUE = @FREEBSD_TRUE@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLIB_CFLAGS = @GLIB_CFLAGS@ GLIB_LIBS = @GLIB_LIBS@ GMSGFMT = @GMSGFMT@ GMSGFMT_015 = @GMSGFMT_015@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ LDFLAGS = @LDFLAGS@ LIBICONV = @LIBICONV@ LIBINTL = @LIBINTL@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBXML2_CFLAGS = @LIBXML2_CFLAGS@ LIBXML2_LIBS = @LIBXML2_LIBS@ LINUX_FALSE = @LINUX_FALSE@ LINUX_TRUE = @LINUX_TRUE@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ TCL_CFLAGS = @TCL_CFLAGS@ TCL_LIBS = @TCL_LIBS@ USE_NLS = @USE_NLS@ VERSION = @VERSION@ XGETTEXT = @XGETTEXT@ XGETTEXT_015 = @XGETTEXT_015@ XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ XSLTPROC = @XSLTPROC@ ac_ct_CC = @ac_ct_CC@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ cv_path_tcl = @cv_path_tcl@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ apt_dater_SOURCES = \ adproto.h \ apt-dater.c \ apt-dater.h \ colors.c \ colors.h \ exec.c \ exec.h \ extern.h \ keyfiles.c \ keyfiles.h \ lock.c \ lock.h \ parsecmd.c \ parsecmd.h \ report.c \ report.h \ screen.c \ screen.h \ sighandler.c \ sighandler.h \ stats.c \ stats.h \ ui.c \ ui.h \ autoref.c \ autoref.h \ tag.c \ tag.h \ history.c \ history.h \ env.c \ env.h \ clusters.c \ clusters.h apt_dater_LDADD = $(GLIB_LIBS) $(TCL_LIBS) $(LIBXML2_LIBS) AM_CFLAGS = -Wall -DPKGLIBDIR='"'$(pkglibdir)'"' @LINUX_FALSE@AM_LDFLAGS = -Wl @LINUX_TRUE@AM_LDFLAGS = -Wl,--as-needed INCLUDES = $(GLIB_CFLAGS) $(TCL_CFLAGS) $(LIBXML2_CFLAGS) all: all-am .SUFFIXES: .SUFFIXES: .c .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu src/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(mkdir_p) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) apt-dater$(EXEEXT): $(apt_dater_OBJECTS) $(apt_dater_DEPENDENCIES) @rm -f apt-dater$(EXEEXT) $(LINK) $(apt_dater_LDFLAGS) $(apt_dater_OBJECTS) $(apt_dater_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/apt-dater.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/autoref.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clusters.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/colors.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/env.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exec.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/history.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keyfiles.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lock.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsecmd.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/report.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/screen.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sighandler.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stats.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tag.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` uninstall-info-am: ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) installdirs: for dir in "$(DESTDIR)$(bindir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-exec-am: install-binPROGRAMS install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-info-am .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ clean-generic ctags distclean distclean-compile \ distclean-generic distclean-tags distdir dvi dvi-am html \ html-am info info-am install install-am install-binPROGRAMS \ install-data install-data-am install-exec install-exec-am \ install-info install-info-am install-man install-strip \ installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ uninstall-am uninstall-binPROGRAMS uninstall-info-am # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: apt-dater-0.9.0/xmlreport/0000755000175000017500000000000011760757134015020 5ustar thomasthomasapt-dater-0.9.0/xmlreport/extra-pkgs.xsl0000644000175000017500000000272111760757134017637 0ustar thomasthomas hosts w/ extra packages installed ================================= No hosts with extra packages found! [] : () apt-dater-0.9.0/xmlreport/overview.xsl0000644000175000017500000000370611760757134017424 0ustar thomasthomas apt-dater host overview ======================= [] Hostname : Status : LSB : Kernel : (reboot needed) Packages installed: Updates : Packages hold back: Extra packages : apt-dater-0.9.0/xmlreport/report.dtd0000644000175000017500000000213111760757134017025 0ustar thomasthomas apt-dater-0.9.0/clients/0000755000175000017500000000000011761142652014417 5ustar thomasthomasapt-dater-0.9.0/clients/README0000644000175000017500000000112611760760436015304 0ustar thomasthomasREADME for apt-dater-host ========================= Setup hosts managed by apt-dater: You need a SSH server and sudo installed. Create a user which will be used to install updates (using root is NOT recommended). Modify the /etc/sudoers: Defaults env_reset,env_keep=MAINTAINER the-user ALL=NOPASSWD: /usr/bin/apt-get, /usr/bin/aptitude At your management server: Create a user on your management server which perform updates on your hosts. Generate a SSH keypair: ssh-keygen [..] Distribute the public key(s) e.g.: ssh-copy-id -i ~/.ssh/your-public-key managed-host apt-dater-0.9.0/clients/debian/0000755000175000017500000000000011761137243015641 5ustar thomasthomasapt-dater-0.9.0/clients/debian/Makefile0000644000175000017500000000056611760760436017315 0ustar thomasthomasclean: install: mkdir -p $(DESTDIR)/usr/bin cp apt-dater-host $(DESTDIR)/usr/bin mkdir -p $(DESTDIR)/etc cp apt-dater-host.conf $(DESTDIR)/etc mkdir -p $(DESTDIR)/etc/kernel/postinst.d cp scripts/apt-dater-host_reboot $(DESTDIR)/etc/kernel/postinst.d mkdir -p $(DESTDIR)/etc/apt/apt.conf.d cp scripts/99apt-dater-host_periodic $(DESTDIR)/etc/apt/apt.conf.d apt-dater-0.9.0/clients/debian/apt-dater-host.conf0000644000175000017500000000223411760760436021352 0ustar thomasthomas# front-end for dpkg to use # Supported: apt-get, aptitude $DPKGTOOL="apt-get"; # Method to do upgrades, possible values (depends on $DPKGTOOL): # upgrade (apt-get, aptitude on Etch) # safe-upgrade (aptitude) # dist-upgrade (recommended default) # # You should use dist-upgrade to get ABI-incompatible upgrades. $APTUPGRADE='dist-upgrade'; # enable use of --assume-yes on safe-upgrade $ASSUMEYES=1; # use this command to become root $GETROOT="sudo"; # clean package cache after upgrade/install $CLEANUP=0; # the installation UUID $UUIDFILE = '/etc/apt-dater-host.uuid'; # If this host is part of (multiple) cluster(s), you might set a # symbolic name. Hosts with the same cluster name won't be upgraded # simultaneously by apt-dater (requires apt-dater 0.9 or above). #@CLUSTERS = qw(my-db-cluster); ## ## If this host is a mission critical system and ## needs scheduled downtimes for upgrades, enable ## (some) of the following $FORBID_* lines: ## # prevent apt-dater-host from refreshing package lists #$FORBID_REFRESH=1; # prevent apt-dater-host from upgrading packages #$FORBID_UPGRADE=1; # prevent apt-dater-host from installing packages #$FORBID_INSTALL=1; apt-dater-0.9.0/clients/debian/scripts/0000755000175000017500000000000011760760436017335 5ustar thomasthomasapt-dater-0.9.0/clients/debian/scripts/99apt-dater-host_periodic0000644000175000017500000000020111760760436024145 0ustar thomasthomasAPT::Periodic::Update-Package-Lists "1"; APT::Periodic::Download-Upgradeable-Packages "1"; APT::Periodic::AutocleanInterval "7"; apt-dater-0.9.0/clients/debian/scripts/apt-dater-host_reboot0000755000175000017500000000006011760760436023465 0ustar thomasthomas#!/bin/sh touch /var/run/apt-dater-host_reboot apt-dater-0.9.0/clients/debian/apt-dater-host0000755000175000017500000002054511761137243020431 0ustar thomasthomas#!/usr/bin/perl # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # use AptPkg::Config '$_config'; use AptPkg::System '$_system'; use AptPkg::Cache; use ImVirt; use strict; use warnings; my $CFGFILE = '/etc/apt-dater-host.conf'; my $DPKGTOOL = 'aptitude'; my $APTUPGRADE = 'dist-upgrade'; my $ASSUMEYES = 0; my $GETROOT = 'sudo'; my $CLEANUP = 0; my $FORBID_REFRESH = 0; my $FORBID_UPGRADE = 0; my $FORBID_INSTALL = 0; my $UUIDFILE = '/etc/apt-dater-host.uuid'; my @CLUSTERS; my $CMD = shift; my $ADPROTO = '0.6'; $ENV{'LC_ALL'} = 'C'; if (-r $CFGFILE) { eval `cat "$CFGFILE"` ; if($@ ne '') { print "ADPROTO: $ADPROTO\n"; print "ADPERR: Invalid config $CFGFILE: $@\n"; exit; } } $GETROOT = '' if($> == 0); die "Don't call this script directly!\n" unless (defined($CMD)); if($CMD eq 'sshkey') { die "Sorry, no shell access allowed!\n" unless(defined($ENV{'SSH_ORIGINAL_COMMAND'})); @ARGV = split(' ', $ENV{'SSH_ORIGINAL_COMMAND'}); shift; $CMD = shift; } die "Invalid command '$CMD'!\n" unless ($CMD=~/^(refresh|status|upgrade|install|kernel)$/); if ($CMD eq 'refresh') { print "ADPROTO: $ADPROTO\n"; if ($FORBID_REFRESH) { print STDERR "\n\n** Sorry, apt-dater based refreshs on this host are disabled! **\n\n" } else { &do_refresh; } &do_status; &do_kernel; } elsif ($CMD eq 'status') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'upgrade') { if ($FORBID_UPGRADE) { print STDERR "\n\n** Sorry, apt-dater based upgrades on this host are disabled! **\n\n"; } else { &do_upgrade; &do_cleanup; } } elsif ($CMD eq 'install') { if ($FORBID_INSTALL) { print STDERR "\n\n** Sorry, apt-dater based installations on this host are disabled! **\n\n"; } else { &do_install(@ARGV); &do_cleanup; } } elsif ($CMD eq 'kernel') { print "ADPROTO: $ADPROTO\n"; &do_kernel; } else { die "Internal error!\n"; } sub do_refresh() { if(system("$GETROOT $DPKGTOOL update")) { print "\nADPERR: Failed to execute '$GETROOT $DPKGTOOL update' ($?).\n"; exit(1); } } sub get_virt() { return imv_get(IMV_PROB_DEFAULT); } sub get_uname() { my $kernel; my $machine; chomp($kernel = `uname -s`); chomp($machine = `uname -m`); return "$kernel|$machine"; } sub do_status() { # initialise the global config object with the default values and # setup the $_system object $_config->init; $_system = $_config->system; # supress cache building messages $_config->{quiet} = 2; # set up the cache my $cache = AptPkg::Cache->new; # retrieve lsb informations unless (open(HLSB, "lsb_release -a 2> /dev/null |")) { print "\nADPERR: Failed to execute 'lsb_release -a' ($!).\n"; exit(1); } my %lsb; while() { chomp; $lsb{$1}=$2 if (/^(Distributor ID|Release|Codename):\s+(\S.*)$/); } close(HLSB); if($?) { print "\nADPERR: Error executing 'lsb_release -a' ($?).\n"; exit(1); } print "LSBREL: $lsb{'Distributor ID'}|$lsb{'Release'}|$lsb{'Codename'}\n"; # retrieve virtualization informations print "VIRT: ".&get_virt."\n"; # retrieve uname informations print "UNAME: ".&get_uname."\n"; # calculate forbid mask my $mask = 0; $mask |= 1 if ($FORBID_REFRESH); $mask |= 2 if ($FORBID_UPGRADE); $mask |= 4 if ($FORBID_INSTALL); print "FORBID: $mask\n"; # add installation UUID if available if(-r $UUIDFILE && -s $UUIDFILE) { print "UUID: ", `head -n 1 "$UUIDFILE"`; } # add cluster name if available foreach my $CLUSTER (@CLUSTERS) { print "CLUSTER: $CLUSTER\n"; } # get packages which might be upgraded my %updates; my %holds; my $pos = 0; my $DPKGARGS; my $_GETROOT = $GETROOT; if($DPKGTOOL eq "apt-get") { $DPKGARGS = "--quiet --simulate --fix-broken --allow-unauthenticated"; } elsif($DPKGTOOL eq "aptitude") { $DPKGARGS = "--verbose --assume-yes --quiet --simulate -f --allow-untrusted"; $_GETROOT = ''; } else { # unkown DPKG frontend - fallback to apt-get $DPKGTOOL = "apt-get"; $DPKGARGS = "--quiet --simulate --fix-broken --allow-unauthenticated"; } unless(open(HAPT, "$_GETROOT $DPKGTOOL $DPKGARGS dist-upgrade |")) { print "\nADPERR: Failed to execute '$_GETROOT $DPKGTOOL $DPKGARGS dist-upgrade' ($!).\n"; exit(1); } while() { chomp; if($pos == 0) { $pos=1 if (/^The following packages have been kept back/); $pos=2 if (/^The following packages will be upgraded:/); next; } if($pos == 1) { unless (/^\s/) { $pos++; next; } while(/^\s*(\S+)(\s(.+))?$/) { $holds{$1} = 1; if(defined($2)) { $_ = $2; } else { $_ = ''; } } } $updates{$1} = $2 if (/^Inst (\S+) \[.+\] \((\S+) /); } close(HAPT); if($?) { print "\nADPERR: Error executing '$GETROOT $DPKGTOOL $DPKGARGS dist-upgrade' ($?).\n"; exit(1); } # get version of installed packages my %installed; my %status; unless(open(HDPKG, "dpkg-query --show --showformat='\${Package} \${Version} \${Status}\\n' |")) { print "\nADPERR: Failed to execute \"dpkg-query --show --showformat='\${Package} \${Version} \${Status}\\n'\" ($!).\n"; exit(1); } while() { chomp; next unless (/^(\S+) (\S+) (\S+) (\S+) (\S+)$/); $installed{$1} = $2 ; if($holds{$1}) { $status{$1} = 'h'; } elsif($updates{$1}) { $status{$1} = 'u'; } else { $status{$1} = substr($3, 0, 1); if ($status{$1} eq 'i') { my $p = $cache->{$1}; unless ($5 eq 'installed') { $status{$1} = "b=$5"; } elsif ($p) { if (my $available = $p->{VersionList}) { my $extra = 1; for my $v (@$available) { for my $f (map $_->{File}, @{$v->{FileList}}) { $extra = 0 unless ($f->{FileName} eq '/var/lib/dpkg/status'); } } $status{$1} = 'x' if($extra); } } } } } close(HDPKG); if($?) { print "\nADPERR: Error executing \"dpkg-query --show --showformat='\${Package} \${Version} \${Status}\\n'\" ($?).\n"; exit(1); } foreach my $pkg (keys %installed) { print "STATUS: $pkg|$installed{$pkg}|$status{$pkg}"; if (exists($updates{$pkg})) { print "=$updates{$pkg}" ; } print "\n"; } } sub do_upgrade() { my $UpgradeCmd = "$GETROOT $DPKGTOOL "; $UpgradeCmd .= '--assume-yes ' if($ASSUMEYES); if($DPKGTOOL eq 'aptitude'){ $UpgradeCmd .= '-o Aptitude::Delete-Unused=false '; } $UpgradeCmd .= $APTUPGRADE; system($UpgradeCmd); } sub do_install() { if($GETROOT) { system($GETROOT, $DPKGTOOL, 'install', @_); } else { system($DPKGTOOL, 'install', @_); } } sub do_kernel() { my $infostr = 'KERNELINFO:'; my $verfile = '/proc/version'; my $version = `uname -r`; chomp($version); unless(-r $verfile) { print "$infostr 9 $version\n"; return; } unless(`cat /proc/version` =~ /^\S+ \S+ \S+ \(Debian ([^\)]+)\)/) { print "$infostr 2 $version\n"; return; } my $vers = $1; my $reboot = 0; unless(open(HDPKG, "dpkg-query -W -f='\${Version} \${Status;20} \${Maintainer} \${Provides}\n' 'linux-image*'|grep 'install ok installed Debian Kernel Team'|grep linux-image|")) { print "$infostr 9 $version\n"; return; } while() { next unless (/^(\S+)\s/); $reboot=1 unless (system("dpkg", "--compare-versions", $vers, "lt", $1) >> 8); } close(HDPKG); print "$infostr $reboot $version\n"; } sub do_cleanup() { return unless $CLEANUP; system("$GETROOT $DPKGTOOL clean"); } apt-dater-0.9.0/clients/doc/0000755000175000017500000000000011760760436015171 5ustar thomasthomasapt-dater-0.9.0/clients/doc/ADP-0.10000644000175000017500000000604011760760436016014 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions should start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.1. Example: ADPROTO: 0.1 Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.1 LSBREL: Debian|4.0|etch STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/ADP-0.20000644000175000017500000000764211760760436016026 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions should start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.2. Example: ADPROTO: 0.2 Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch There sould be an VIRTualization line of the format: VIRT: ${Name} This will only work if the remote host has the imvirt script installed. Detected virtualizations: Microsoft Corporation / Virtual Machine: VIRT: Virtual Machine VMware, Inc. / VMware Virtual Platform: VIRT: VMware Virtual Platform QEMU or KVM: VIRT: QEMU Xen: VIRT: Xen non detected: VIRT: Physical imvirt not installed: VIRT: Unknown There might be a FORBID line of the format: FORBID: ${Operations} This is a mask of forbidded apt-dater-host operations. An single operation is represented by the following values: 1: refresh 2: upgrade 4: install These values are binary ORed. Default value is 0 if no there is no FORBID line (allows all operations). The apt-dater-host executable on the client will refused operations marked as forbidden. For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.2 LSBREL: Debian|4.0|etch VIRT: Physical STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/ADP-0.30000644000175000017500000001026611760760436016023 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions should start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.3. Example: ADPROTO: 0.3 Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch There sould be an VIRTualization line of the format: VIRT: ${Name} This will only work if the remote host has the imvirt script installed. Detected virtualizations: Microsoft Corporation / Virtual Machine: VIRT: Virtual Machine VMware, Inc. / VMware Virtual Platform: VIRT: VMware Virtual Platform QEMU or KVM: VIRT: QEMU Xen: VIRT: Xen non detected: VIRT: Physical imvirt not installed: VIRT: Unknown There sould be an UNAME line of the format: UNAME: ${KERNEL-NAME}|${MACHINE} The values are taken from the uname command: KERNEL-NAME: uname -s MACHINE : uname -m There might be a FORBID line of the format: FORBID: ${Operations} This is a mask of forbidded apt-dater-host operations. An single operation is represented by the following values: 1: refresh 2: upgrade 4: install These values are binary ORed. Default value is 0 if no there is no FORBID line (allows all operations). The apt-dater-host executable on the client will refused operations marked as forbidden. For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) b=${AddInfo} : package is installed but broken (i.e. not configured) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.3 LSBREL: Debian|4.0|etch VIRT: Physical UNAME: Linux|i686 STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/ADP-0.40000644000175000017500000001072111760760436016020 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions should start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.4. Example: ADPROTO: 0.4 Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch There sould be an VIRTualization line of the format: VIRT: ${Name} This will only work if the remote host has the imvirt script installed. Detected virtualizations: Microsoft Corporation / Virtual Machine: VIRT: Virtual Machine VMware, Inc. / VMware Virtual Platform: VIRT: VMware Virtual Platform QEMU or KVM: VIRT: QEMU Xen: VIRT: Xen non detected: VIRT: Physical imvirt not installed: VIRT: Unknown There sould be an UNAME line of the format: UNAME: ${KERNEL-NAME}|${MACHINE} The values are taken from the uname command: KERNEL-NAME: uname -s MACHINE : uname -m There might be a FORBID line of the format: FORBID: ${Operations} This is a mask of forbidded apt-dater-host operations. An single operation is represented by the following values: 1: refresh 2: upgrade 4: install These values are binary ORed. Default value is 0 if no there is no FORBID line (allows all operations). The apt-dater-host executable on the client will refused operations marked as forbidden. There should be an UUID line: UUID: {$UUID} This is the DCE 1.1, ISO/IEC 11578:1996 and RFC 4122 compliant Universally Unique Identifier (UUID) of the host. It should be a DCE version 1 (time and node based) UUID, generated at the installation time of the apt-dater-host client. For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) b=${AddInfo} : package is installed but broken (i.e. not configured) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.3 LSBREL: Debian|4.0|etch VIRT: Physical UNAME: Linux|i686 STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/ADP-0.50000644000175000017500000001127211760760436016023 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions must start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.5. Example: ADPROTO: 0.5 If apt-dater-host detects an error (i.e. from the package manager) during a non-interactive command it must add an error line containing an user readable error message: ADPERR: ${Message} The message string should not be empty. Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch There sould be an VIRTualization line of the format: VIRT: ${Name} This will only work if the remote host has the imvirt script installed. Detected virtualizations: Microsoft Corporation / Virtual Machine: VIRT: Virtual Machine VMware, Inc. / VMware Virtual Platform: VIRT: VMware Virtual Platform QEMU or KVM: VIRT: QEMU Xen: VIRT: Xen non detected: VIRT: Physical imvirt not installed: VIRT: Unknown There sould be an UNAME line of the format: UNAME: ${KERNEL-NAME}|${MACHINE} The values are taken from the uname command: KERNEL-NAME: uname -s MACHINE : uname -m There might be a FORBID line of the format: FORBID: ${Operations} This is a mask of forbidded apt-dater-host operations. An single operation is represented by the following values: 1: refresh 2: upgrade 4: install These values are binary ORed. Default value is 0 if no there is no FORBID line (allows all operations). The apt-dater-host executable on the client will refused operations marked as forbidden. There should be an UUID line: UUID: {$UUID} This is the DCE 1.1, ISO/IEC 11578:1996 and RFC 4122 compliant Universally Unique Identifier (UUID) of the host. It should be a DCE version 1 (time and node based) UUID, generated at the installation time of the apt-dater-host client. For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) b=${AddInfo} : package is installed but broken (i.e. not configured) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.3 LSBREL: Debian|4.0|etch VIRT: Physical UNAME: Linux|i686 STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/ADP-0.60000644000175000017500000001306211760760436016023 0ustar thomasthomasapt-dater protocol 0.6 ====================== This file documents the protocol between apt-dater and the apt-dater-host command called via ssh on remote hosts. The protocol is designed to be a generic package management interface and cover most common GNU/Linux based package manager philosophies. Hosts managed by apt-dater musst have the apt-dater-host command in the search path. User interactive commands (see below) will be shown to the user unfiltered. Non-user interactive commands are parse by apt-dater. Non-user interactive sessions must start with the protocol version: ADPROTO: ${ProtoVersion} The current protocol version is 0.6. Example: ADPROTO: 0.6 If apt-dater-host detects an error (i.e. from the package manager) during a non-interactive command it must add an error line containing an user readable error message: ADPERR: ${Message} The message string should not be empty. Calling syntax ============== An apt-dater-host script must accept the following command parameters: refresh ------- Updates the package list (i.e. apt-get update) and retrieve status informations (see next command). This command is called none user interactive. status ------ Prints status informations about installed distribution and packages. This command is non user interactive. There should be an LSB release line of the format: LSBREL: ${Distri}|{Version}|${Codename} Example for Debian Etch: LSBREL: Debian|4.0|etch There sould be PRL (Package Resource List) lines for the archive sources the packaging system is using: PRL: ${URI} The PRL lines must be in a normalized form (no unnecessary spaces). There must be a PRL line for each archive source or no PRL lines at all. Example for Debian Squeezy: PRL: http://ftp.de.debian.org/debian/ squeezy main PRL: http://security.debian.org/ squeeze/updates main PRL: deb http://www.debian-multimedia.org squeeze main A host might be part of one or more cluster (heartbeat, drbd, ...). Cluster nodes should not be updated simultanously. apt-dater will detect cluster nodes by identical CLUSTER lines and avoid updating nodes of the same cluster simultanously: CLUSTER: ${Cluster-A} CLUSTER: ${Cluster-B} The cluster might be any ASCII string and must be identical on all cluster nodes. A node can be part of multiple clusters. There sould be an VIRTualization line of the format: VIRT: ${Name} This will only work if the remote host has the imvirt script installed. Detected virtualizations: Microsoft Corporation / Virtual Machine: VIRT: Virtual Machine VMware, Inc. / VMware Virtual Platform: VIRT: VMware Virtual Platform QEMU or KVM: VIRT: QEMU Xen: VIRT: Xen non detected: VIRT: Physical imvirt not installed: VIRT: Unknown There sould be an UNAME line of the format: UNAME: ${KERNEL-NAME}|${MACHINE} The values are taken from the uname command: KERNEL-NAME: uname -s MACHINE : uname -m There might be a FORBID line of the format: FORBID: ${Operations} This is a mask of forbidded apt-dater-host operations. An single operation is represented by the following values: 1: refresh 2: upgrade 4: install These values are binary ORed. Default value is 0 if no there is no FORBID line (allows all operations). The apt-dater-host executable on the client will refused operations marked as forbidden. There should be an UUID line: UUID: {$UUID} This is the DCE 1.1, ISO/IEC 11578:1996 and RFC 4122 compliant Universally Unique Identifier (UUID) of the host. It should be a DCE version 1 (time and node based) UUID, generated at the installation time of the apt-dater-host client. For each installed package there must be a status line: STATUS: ${Package}|${InstVersion}|${Status}... Supported status values: i : installed h : hold back u=${NewVersion} : update available x : extra (no version found in any repository, this might be an obsoleted package) b=${AddInfo} : package is installed but broken (i.e. not configured) Example for an installed package: STATUS: g++-4.1|4.1.1-21|i Example for an installed package with an update available: STATUS: dnsutils|1:9.3.4-2etch1|u=1:9.3.4-2etch3 There should be a kernel info line (see also 'kernel' command). upgrade ------- Install all available upgrades, this is user interactive. install ------- Install package(s) given as parameters to this command. This command is user interactive. kernel ------ Retrieves informations about the running kernel. This command is non user interactive. The result line has the following format: KERNELINFO: ${Code} ${Release} The following codes are supported: 0 - The running kernel is the latest distri kernel. No reboot required. 1 - The running kernel is an distri kernel but it's older then the latest installed. A reboot is recommended. 2 - No distri kernel is running. 9 - Unknown. The release field should be the output of `uname -r`. Example ======= The following lines show an example output of the 'status' command for a Debian Etch installation (the 'STATUS:' lines are truncated): ADPROTO: 0.3 LSBREL: Debian|4.0|etch VIRT: Physical UNAME: Linux|i686 STATUS: groff-base|1.18.1.1-12|i STATUS: libgnome2-0|2.16.0-2|i STATUS: m4|1.4.8-2|i STATUS: liblwres9|1:9.3.4-2etch1|u=1:9.3.4-2etch3 STATUS: linux-image-2.6-686|2.6.24+13|h STATUS: apache2-mpm-prefork|2.2.3-4+etch4|i STATUS: iceweasel-l10n-de|2.0.0.3+debian-1etch1|i STATUS: mutt|1.5.17+20080114-1~bpo40+1|u=1.5.18-2~bpo40+1 STATUS: libperl5.8|5.8.8-7etch3|i STATUS: autoconf|2.61-4|i KERNELINFO: 2 2.6.18-028stab053.5-openvz apt-dater-0.9.0/clients/doc/README.sshkey0000644000175000017500000000044411760760436017360 0ustar thomasthomasBind to ssh keys ================ apt-dater-host can be bind on a ssh key: $ cat ~/.ssh/authorized_key command="/usr/bin/apt-dater-host sshkey",no-port-forwarding ssh-dss apt-dater@ibh.net This will prevent you from using 'connect' within apt-dater to open a shell on the client. apt-dater-0.9.0/clients/man/0000755000175000017500000000000011760760436015177 5ustar thomasthomasapt-dater-0.9.0/clients/man/apt-dater-host.10000644000175000017500000000122611760760436020116 0ustar thomasthomas.TH "APT-DATER-HOST" "1" .SH "NAME" apt\-dater\-host \- host helper application for apt\-dater. .SH "SYNOPSIS" \fBapt\-dater\-host\fR .SH "DESCRIPTION" This manual page documents briefly the \fBapt\-dater\-host\fR helper. \fBapt\-dater\-host\fR is the host helper application for apt\-dater for watching and updating the targeted application about apt\-dater. .SH "AUTHOR" This manual page was written by Patrick Matth\[:a]i for apt\-dater\-host. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 2 any later version published by the Free Software Foundation. apt-dater-0.9.0/clients/rpm/0000755000175000017500000000000011760760436015222 5ustar thomasthomasapt-dater-0.9.0/clients/rpm/apt-dater-host0000755000175000017500000001271711760760436020014 0ustar thomasthomas#!/usr/bin/perl -w # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # use strict; my $CMD = shift; my $ADPROTO = '0.5'; my $UUIDFILE = '/etc/apt-dater-host.uuid'; $ENV{'LC_ALL'} = 'C'; die "Don't call this script directly!\n" unless (defined($CMD)); if($CMD eq 'sshkey') { die "Sorry, no shell access allowed!\n" unless(defined($ENV{'SSH_ORIGINAL_COMMAND'})); @ARGV = split(' ', $ENV{'SSH_ORIGINAL_COMMAND'}); shift; $CMD = shift; } die "Invalid command '$CMD'!\n" unless ($CMD=~/^(refresh|status|upgrade|install|kernel)$/); if ($CMD eq 'refresh') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'status') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'upgrade') { &do_upgrade; } elsif ($CMD eq 'install') { &do_install(@ARGV); } elsif ($CMD eq 'kernel') { print "ADPROTO: $ADPROTO\n"; &do_kernel; } else { die "Internal error!\n"; } sub get_virt() { return "Unknown" unless (-x '/usr/bin/imvirt'); my $imvirt; chomp($imvirt = `/usr/bin/imvirt`); return $imvirt; } sub get_uname() { my $kernel; my $machine; chomp($kernel = `uname -s`); chomp($machine = `uname -m`); return "$kernel|$machine"; } sub do_status() { # retrieve lsb informations unless (open(HLSB, "lsb_release -a 2> /dev/null |")) { print "\nADPERR: Failed to execute 'lsb_release -a' ($!).\n"; exit(1); } my %lsb; while() { chomp; $lsb{$1}=$2 if (/^(Distributor ID|Release|Codename):\s+(\S.*)$/); } close(HLSB); print "LSBREL: $lsb{'Distributor ID'}|$lsb{'Release'}|$lsb{'Codename'}\n"; # retrieve virtualization informations print "VIRT: ".&get_virt."\n"; # retrieve uname informations print "UNAME: ".&get_uname."\n"; # rpm is readonly, so forbid anything! print "FORBID: 255\n"; # add installation UUID if available if(-r $UUIDFILE && -s $UUIDFILE) { print "UUID: ", `head -n 1 "$UUIDFILE"`; } # get version of installed packages my %installed; my %status; unless(open(HDPKG, "rpm -qa --qf '%{NAME}\t%{VERSION}-%{RELEASE}\ti\n' |")) { print "\nADPERR: Failed to execute 'rpm -qa --qf '%{NAME}\\t%{VERSION}-%{RELEASE}\\ti\\n' ($!).\n"; exit(1); } while() { chomp; next unless (/^(\S+)\s+(\S+)\s+(\S+)/); $installed{$1} = $2 ; $status{$1} = substr($3, 0, 1); } close(HDPKG); foreach my $pkg (keys %installed) { print "STATUS: $pkg|$installed{$pkg}|$status{$pkg}\n"; } } sub do_upgrade() { # not implemented print STDERR "\n\n** Sorry, apt-dater based upgrades on this host are not supported! **\n\n"; } sub do_install() { # not implemented print STDERR "\n\n** Sorry, apt-dater based installations on this host are not supported! **\n\n"; } sub do_kernel() { my $infostr = 'KERNELINFO:'; my $version = `uname -r`; chomp($version); my $ver = $version; my $rel = ''; my $add = ''; $add = $1 if($version =~ /([a-z]+)$/); ($ver, $rel) = ($1, $2) if($version =~ /(.+)-([^-]+)$add$/); $add = "-$add" if($add); my $kinstalled; my $distri = 0; unless(open(HKERNEL, "rpm -q --whatprovides kernel$add --qf '%{NAME}\t%{VERSION}\t%{RELEASE}\n' |")) { print "\nADPERR: Failed to execute 'rpm -q --whatprovides kernel$add --qf '%{NAME}\\t%{VERSION}\\t%{RELEASE}\\n' ($!).\n"; exit(1); } while() { if(/^\S+\s+(\S+)\s+(\S+)/) { if($ver eq $1) { $distri = 1; if(!$kinstalled) { $kinstalled = $2; } else { $kinstalled = $2 if(&versioncmp($kinstalled, $2) < 0); } } } } close(HKERNEL); unless($distri) { print "$infostr 2 $version\n"; return; } unless($kinstalled cmp $rel) { print "$infostr 0 $version\n"; return; } print "$infostr 1 $version\n"; } ## # Taken from Sort::Versions 1.4 # Copyright (c) 1996, Kenneth J. Albanowski. ## sub versioncmp() { my @A = ($_[0] =~ /([-.]|\d+|[^-.\d]+)/g); my @B = ($_[1] =~ /([-.]|\d+|[^-.\d]+)/g); my ($A, $B); while (@A and @B) { $A = shift @A; $B = shift @B; if ($A eq '-' and $B eq '-') { next; } elsif ( $A eq '-' ) { return -1; } elsif ( $B eq '-') { return 1; } elsif ($A eq '.' and $B eq '.') { next; } elsif ( $A eq '.' ) { return -1; } elsif ( $B eq '.' ) { return 1; } elsif ($A =~ /^\d+$/ and $B =~ /^\d+$/) { if ($A =~ /^0/ || $B =~ /^0/) { return $A cmp $B if $A cmp $B; } else { return $A <=> $B if $A <=> $B; } } else { $A = uc $A; $B = uc $B; return $A cmp $B if $A cmp $B; } } @A <=> @B; } apt-dater-0.9.0/clients/rug/0000755000175000017500000000000011760760436015221 5ustar thomasthomasapt-dater-0.9.0/clients/rug/apt-dater-host0000755000175000017500000001527311760760436020013 0ustar thomasthomas#!/usr/bin/perl # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # use strict; use warnings; my $CFGFILE = '/etc/apt-dater-host.conf'; my $GETROOT = 'sudo'; my $FORBID_UPGRADE = 0; my $FORBID_INSTALL = 0; my $UUIDFILE = '/etc/apt-dater-host.uuid'; my @CLUSTERS; my $CMD = shift; my $ADPROTO = '0.6'; $ENV{'LC_ALL'} = 'C'; if (-r $CFGFILE) { eval `cat "$CFGFILE"` ; if($@ ne '') { print "ADPROTO: $ADPROTO\n"; print "ADPERR: Invalid config $CFGFILE: $@\n"; exit; } } $GETROOT = '' if($> == 0); die "Don't call this script directly!\n" unless (defined($CMD)); if($CMD eq 'sshkey') { die "Sorry, no shell access allowed!\n" unless(defined($ENV{'SSH_ORIGINAL_COMMAND'})); @ARGV = split(' ', $ENV{'SSH_ORIGINAL_COMMAND'}); shift; $CMD = shift; } die "Invalid command '$CMD'!\n" unless ($CMD=~/^(refresh|status|upgrade|install|kernel)$/); if ($CMD eq 'refresh') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'status') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'upgrade') { if ($FORBID_UPGRADE) { print STDERR "\n\n** Sorry, apt-dater based upgrades on this host are disabled! **\n\n" } else { &do_upgrade; } } elsif ($CMD eq 'install') { if ($FORBID_INSTALL) { print STDERR "\n\n** Sorry, apt-dater based installations on this host are disabled! **\n\n" } else { &do_install(@ARGV); } } elsif ($CMD eq 'kernel') { print "ADPROTO: $ADPROTO\n"; &do_kernel; } else { die "Internal error!\n"; } sub get_virt() { return "Unknown" unless (-x '/usr/bin/imvirt'); my $imvirt; chomp($imvirt = `/usr/bin/imvirt`); return $imvirt; } sub get_uname() { my $kernel; my $machine; chomp($kernel = `uname -s`); chomp($machine = `uname -m`); return "$kernel|$machine"; } sub do_status() { # retrieve lsb informations unless(open(HLSB, "lsb_release -a 2> /dev/null |")) { print "\nADPERR: Failed to execute 'lsb_release -a' ($!).\n"; exit(1); } my %lsb; while() { chomp; $lsb{$1}=$2 if (/^(Distributor ID|Release|Codename):\s+(\S.*)$/); } close(HLSB); if($?) { print "\nADPERR: Error executing 'lsb_release -a' ($?).\n"; exit(1); } print "LSBREL: $lsb{'Distributor ID'}|$lsb{'Release'}|$lsb{'Codename'}\n"; # retrieve virtualization informations print "VIRT: ".&get_virt."\n"; # retrieve uname informations print "UNAME: ".&get_uname."\n"; # calculate forbid mask my $mask = 1; # $mask |= 1 if ($FORBID_REFRESH); NOT SUPPORTED $mask |= 2 if ($FORBID_UPGRADE); $mask |= 4 if ($FORBID_INSTALL); print "FORBID: $mask\n"; # add installation UUID if available if(-r $UUIDFILE && -s $UUIDFILE) { print "UUID: ", `head -n 1 "$UUIDFILE"`; } # add cluster name if available foreach my $CLUSTER (@CLUSTERS) { print "CLUSTER: $CLUSTER\n"; } # get packages which might be upgraded my %updates; unless(open(HAPT, "$GETROOT rug --terse list-updates |")) { print "\nADPERR: Failed to execute '$GETROOT rug --terse list-updates' ($!).\n"; exit(1); }; while() { chomp; $updates{$1} = $2 if (/^.*\|.*\|.*\|([^|]+)\|([^|]+)\|/); } close(HAPT); if($?) { print "\nADPERR: Error executing '$GETROOT rug --terse list-updates' ($?).\n"; exit(1); } # get version of installed packages my %installed; my %status; unless(open(HDPKG, "rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\n' |")) { print "\nADPERR: Failed to execute \"rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\\n'\" ($!).\n"; exit(1); }; while() { chomp; next unless (/^(\S+)\|\S+\|/); print "STATUS: "; print; if($updates{$1}) { print 'u=', $updates{$1}; } else { print 'i'; } print "\n"; } close(HDPKG); if($?) { print "\nADPERR: Error executing \"rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\\n'\" ($?).\n"; exit(1); }; } sub do_upgrade() { system("$GETROOT rug update"); } sub do_install() { if($GETROOT) { system($GETROOT, 'rug', 'install', @_); } else { system('rug', 'install', @_); } } sub do_kernel() { my $infostr = 'KERNELINFO:'; my $version = `uname -r`; chomp($version); my $add = ''; $add = $1 if($version =~ /(-[a-z]+)$/); my $pos = 0; my $kinstalled; my %distri; unless(open(HKERNEL, "rpm -q --whatprovides kernel --qf '%{NAME}|%{VERSION}-%{RELEASE}\n' |")) { print "$infostr 9 $version\n"; return; } while() { chomp; if(/^kernel$add\|(.+)/) { my $ver = $1; $distri{$ver.$add} = 1; if(!$kinstalled) { $kinstalled = $ver; } else { $kinstalled = $ver if(&versioncmp($kinstalled, $ver) < 0); } } } close(HKERNEL); if($?) { print "$infostr 9 $version\n"; return; } unless($distri{$version}) { print "$infostr 2 $version\n"; return; } unless($kinstalled.$add cmp $version) { print "$infostr 0 $version\n"; return; } print "$infostr 1 $version\n"; } ## # Taken from Sort::Versions 1.4 # Copyright (c) 1996, Kenneth J. Albanowski. ## sub versioncmp() { my @A = ($_[0] =~ /([-.]|\d+|[^-.\d]+)/g); my @B = ($_[1] =~ /([-.]|\d+|[^-.\d]+)/g); my ($A, $B); while (@A and @B) { $A = shift @A; $B = shift @B; if ($A eq '-' and $B eq '-') { next; } elsif ( $A eq '-' ) { return -1; } elsif ( $B eq '-') { return 1; } elsif ($A eq '.' and $B eq '.') { next; } elsif ( $A eq '.' ) { return -1; } elsif ( $B eq '.' ) { return 1; } elsif ($A =~ /^\d+$/ and $B =~ /^\d+$/) { if ($A =~ /^0/ || $B =~ /^0/) { return $A cmp $B if $A cmp $B; } else { return $A <=> $B if $A <=> $B; } } else { $A = uc $A; $B = uc $B; return $A cmp $B if $A cmp $B; } } @A <=> @B; } apt-dater-0.9.0/clients/rug/apt-dater-host.conf0000644000175000017500000000117711760760436020732 0ustar thomasthomas# use this command to become root $GETROOT="sudo"; # the installation UUID $UUIDFILE = '/etc/apt-dater-host.uuid'; # If this host is part of (multiple) cluster(s), you might set a # symbolic name. Hosts with the same cluster name won't be upgraded # simultaneously by apt-dater (requires apt-dater 0.9 or above). #@CLUSTERS = qw(my-db-cluster); ## ## If this host is a mission critical system and ## needs scheduled downtimes for upgrades, enable ## (some) of the following $FORBID_* lines: ## # prevent apt-dater-host from upgrading packages #$FORBID_UPGRADE=1; # prevent apt-dater-host from installing packages #$FORBID_INSTALL=1; apt-dater-0.9.0/clients/wua/0000755000175000017500000000000011760760436015220 5ustar thomasthomasapt-dater-0.9.0/clients/wua/README.wua0000644000175000017500000000241711760760436016677 0ustar thomasthomasapt-dater-host for Windows Update Agent ======================================= This scripts support the Windows Update Agent to search for updates on MS Windows based hosts. You need to have to install a SSH daemon which supports public key authentification and allows bash like command line syntax. Cygwin OpenSSH ============== This SSH daemon is known to work with apt-dater. First install OpenSSH with der Cygwin Installer. Open a shell and run: $ ssh-host-config -y This will generate a initial config, host keys and creates a ssh service. To start the ssh daemon run: $ cygrunsrv.exe -S sshd Finaly you have to create a symlink or script in /usr/local/bin which is named apt-dater-host and calls the apt-dater-host.cmd. Since apt-dater uses SSH public key authentification, apt-dater-host must be run as the SYSTEM user (SID S-1-5-18) to be able to search for updates. To be able to login via SSH as SYSTEM, edit /etc/passwd and add a home directory: SYSTEM:*:18:544:,S-1-5-18:/home/SYSTEM: Create the .ssh directory in the home directory: $ mkdir -p /home/SYSTEM/.ssh And add your public key to the 'authorized_keys' file in the .ssh directory. Remember: SYSTEM has all kinds of dangerous rights, sort of an uber-root account. apt-dater-0.9.0/clients/wua/apt-dater-host.cmd0000755000175000017500000000007111760760436020542 0ustar thomasthomas@echo off cscript cscript-apt-dater-host.vbs //Nologo %*apt-dater-0.9.0/clients/wua/cscript-apt-dater-host.vbs0000755000175000017500000001126611760760436022246 0ustar thomasthomas'~ apt-dater - terminal-based remote package update manager '~ '~ Authors: '~ Andre Ellguth '~ Thomas Liske '~ '~ Copyright Holder: '~ 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] '~ '~ License: '~ This program is free software; you can redistribute it and/or modify '~ it under the terms of the GNU General Public License as published by '~ the Free Software Foundation; either version 2 of the License, or '~ (at your option) any later version. '~ '~ This program is distributed in the hope that it will be useful, '~ but WITHOUT ANY WARRANTY; without even the implied warranty of '~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the '~ GNU General Public License for more details. '~ '~ You should have received a copy of the GNU General Public License '~ along with this package; if not, write to the Free Software '~ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA '~ Dim sh, adproto adproto = "0.2" If WScript.Arguments.Count < 1 Then WScript.Echo "Don't call this script directly!" WScript.Quit End If Set sh = CreateObject("WScript.Shell") cmd = WScript.Arguments.Item(0) If cmd = "refresh" Then WScript.Echo "ADPROTO: " & adproto WScript.Echo WScript.Echo "Sorry, apt-dater based refreshs on this host are disabled!" WScript.Echo do_status do_kernel ElseIf cmd = "status" Then WScript.Echo "ADPROTO: " & adproto do_status do_kernel ElseIf cmd = "upgrade" Then WScript.Echo WScript.Echo "** Sorry, apt-dater based upgrades on this host are disabled! **" WScript.Echo ElseIf cmd = "install" Then WScript.Echo WScript.Echo "** Sorry, apt-dater based upgrades on this host are disabled! **" WScript.Echo ElseIf cmd = "kernel" Then WScript.Echo "ADPROTO: " & adproto do_kernel Else WScript.Echo "IInvalid command " & cmd & "!" End If Sub do_status() If sh.ExpandEnvironmentStrings("%OS%") = "Windows_NT" Then regkey = "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\" lsbrel = sh.regread(regkey & "ProductName") & "|" & sh.regread(regkey & "CurrentVersion") & "|" & sh.regread(regkey & "CurrentBuildNumber") Else regkey = "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\" lsbrel = sh.regread(regkey & "ProductName") & "|" & sh.regread(regkey & "VersionNumber") & "|" End If WScript.Echo "LSBREL: " & lsbrel WScript.Echo "FORBID: 7" get_installed Set updateSession = CreateObject("Microsoft.Update.Session") Set updateSearcher = updateSession.CreateupdateSearcher() Set searchResult = updateSearcher.Search("IsInstalled=0 and Type='Software'") For I = 0 To searchResult.Updates.Count-1 Set update = searchResult.Updates.Item(I) WScript.Echo "STATUS: " & update.Title & "|n/i|u=n/a" Next End Sub Sub do_kernel() If sh.ExpandEnvironmentStrings("%OS%") = "Windows_NT" Then kernelinfo = sh.regread("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\BuildLab") Else kernelinfo = sh.regread("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\BuildLab") End If Set updateSession = CreateObject("Microsoft.Update.Session") Set updateSearcher = updateSession.CreateupdateSearcher() Set searchResult = updateSearcher.Search("RebootRequired=1") If searchResult.Updates.Count > 0 then WScript.Echo "KERNELINFO: " & kernelinfo & " 1" Else WScript.Echo "KERNELINFO: " & kernelinfo & " 0" End If End Sub Sub get_installed() Const HKLM = &H80000002 'HKEY_LOCAL_MACHINE strComputer = "." strKey = "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" strEntry1a = "DisplayName" strEntry1b = "QuietDisplayName" strEntry2 = "DisplayVersion" strEntry3 = "VersionMajor" strEntry4 = "VersionMinor" Set objReg = GetObject("winmgmts://" & strComputer & "/root/default:StdRegProv") objReg.EnumKey HKLM, strKey, arrSubkeys For Each strSubkey In arrSubkeys ret = objReg.GetStringValue(HKLM, strKey & strSubkey, strEntry1a, strProgName) If ret <> 0 Then objReg.GetStringValue HKLM, strKey & strSubkey, strEntry1b, strProgName End If If strProgName <> "" Then ret = objReg.GetStringValue(HKLM, strKey & strSubkey, strEntry2, strVersion) if ret <> 0 Then objReg.GetDWORDValue HKLM, strKey & strSubkey, strEntry3, intValue3 objReg.GetDWORDValue HKLM, strKey & strSubkey, strEntry4, intValue4 If intValue3 <> "" Then strVersion = intValue3 & "." & intValue4 Else strVersion = "n/a" End If End If WScript.Echo "STATUS: " & strProgName & "|" & strVersion & "|i" End If Next End Sub apt-dater-0.9.0/clients/yum/0000755000175000017500000000000011760760436015236 5ustar thomasthomasapt-dater-0.9.0/clients/yum/apt-dater-host0000755000175000017500000001663311760760436020031 0ustar thomasthomas#!/usr/bin/perl # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # use strict; use warnings; my $CFGFILE = '/etc/apt-dater-host.conf'; my $GETROOT = 'sudo'; my $CLEANUP = 0; my $FORBID_UPGRADE = 0; my $FORBID_INSTALL = 0; my $UUIDFILE = '/etc/apt-dater-host.uuid'; my @CLUSTERS; my $CMD = shift; my $ADPROTO = '0.6'; $ENV{'LC_ALL'} = 'C'; if (-r $CFGFILE) { eval `cat "$CFGFILE"` ; if($@ ne '') { print "ADPROTO: $ADPROTO\n"; print "ADPERR: Invalid config $CFGFILE: $@\n"; exit; } } $GETROOT = '' if($> == 0); die "Don't call this script directly!\n" unless (defined($CMD)); if($CMD eq 'sshkey') { die "Sorry, no shell access allowed!\n" unless(defined($ENV{'SSH_ORIGINAL_COMMAND'})); @ARGV = split(' ', $ENV{'SSH_ORIGINAL_COMMAND'}); shift; $CMD = shift; } die "Invalid command '$CMD'!\n" unless ($CMD=~/^(refresh|status|upgrade|install|kernel)$/); if ($CMD eq 'refresh') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'status') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'upgrade') { if ($FORBID_UPGRADE) { print STDERR "\n\n** Sorry, apt-dater based upgrades on this host are disabled! **\n\n" } else { &do_upgrade; &do_cleanup; } } elsif ($CMD eq 'install') { if ($FORBID_INSTALL) { print STDERR "\n\n** Sorry, apt-dater based installations on this host are disabled! **\n\n" } else { &do_install(@ARGV); &do_cleanup; } } elsif ($CMD eq 'kernel') { print "ADPROTO: $ADPROTO\n"; &do_kernel; } else { die "Internal error!\n"; } sub get_virt() { return "Unknown" unless (-x '/usr/bin/imvirt'); my $imvirt; chomp($imvirt = `/usr/bin/imvirt`); return $imvirt; } sub get_uname() { my $kernel; my $machine; chomp($kernel = `uname -s`); chomp($machine = `uname -m`); return "$kernel|$machine"; } sub do_status() { # retrieve lsb informations unless(open(HLSB, "lsb_release -a 2> /dev/null |")) { print "\nADPERR: Failed to execute 'lsb_release -a' ($!).\n"; exit(1); }; my %lsb; while() { chomp; $lsb{$1}=$2 if (/^(Distributor ID|Release|Codename):\s+(\S.*)$/); } close(HLSB); if($?) { print "\nADPERR: Error executing 'lsb_release -a' ($?).\n"; exit(1); }; print "LSBREL: $lsb{'Distributor ID'}|$lsb{'Release'}|$lsb{'Codename'}\n"; # retrieve virtualization informations print "VIRT: ".&get_virt."\n"; # retrieve uname informations print "UNAME: ".&get_uname."\n"; # calculate forbid mask my $mask = 0; # $mask |= 1 if ($FORBID_REFRESH); NOT SUPPORTED $mask |= 2 if ($FORBID_UPGRADE); $mask |= 4 if ($FORBID_INSTALL); print "FORBID: $mask\n"; # add installation UUID if available if(-r $UUIDFILE && -s $UUIDFILE) { print "UUID: ", `head -n 1 "$UUIDFILE"`; } # add cluster name if available foreach my $CLUSTER (@CLUSTERS) { print "CLUSTER: $CLUSTER\n"; } # get packages which might be upgraded my %updates; unless(open(HAPT, "$GETROOT yum list updates |")) { print "\nADPERR: Failed to execute '$GETROOT yum list updates' ($!).\n"; exit(1); }; while() { chomp; $updates{$1} = $2 if (/^(\S+)\s+(\d\S*)\s+(\S+)/); } close(HAPT); # get packages which are obsolete (extra - no downloadable version available) my %extras; unless(open(HYUM, "$GETROOT yum list extras |")) { print "\nADPERR: Failed to execute '$GETROOT yum list extras' ($!).\n"; exit(1); } while() { chomp; $extras{$1} = $2 if (/^(\S+)\s+(\d\S*)\s+(\S+)/); } close(HYUM); if($?) { print "\nADPERR: Error executing '$GETROOT yum list extras' ($?).\n"; exit(1); } # get version of installed packages my %installed; my %status; unless(open(HDPKG, "$GETROOT yum list installed |")) { print "\nADPERR: Failed to execute '$GETROOT yum list installed' ($!).\n"; exit(1); } while() { chomp; next unless (/^(\S+)\s+(\d\S*)\s+(\S+)/); $installed{$1} = $2 ; if($updates{$1}) { $status{$1} = 'u'; } elsif($extras{$1}) { $status{$1} = 'x'; } else { $status{$1} = 'i'; } } close(HDPKG); if($?) { print "\nADPERR: Error executing '$GETROOT yum list installed' ($?).\n"; exit(1); } foreach my $pkg (keys %installed) { print "STATUS: $pkg|$installed{$pkg}|$status{$pkg}"; if (exists($updates{$pkg})) { print "=$updates{$pkg}" ; } print "\n"; } } sub do_upgrade() { system("$GETROOT yum update"); } sub do_install() { if($GETROOT) { system($GETROOT, 'yum', 'install', @_); } else { system('yum', 'install', @_); } } sub do_kernel() { my $infostr = 'KERNELINFO:'; my $version = `uname -r`; chomp($version); my $add = ''; $add = "-$1" if($version =~ /([a-z]+)$/); my $pos = 0; my $kinstalled; my %distri; unless(open(HKERNEL, "$GETROOT yum list 'kernel*' |")) { print "$infostr 9 $version\n"; return; }; while() { chomp; if(/^Installed Packages/) { $pos = 1; next; } if(/^Available Packages/) { $pos = 2; next; } if(($pos == 1) && /^(\S+$add\.\S+)\s+(\d\S*)\s/) { my $ver = $2; $distri{$ver.substr($add,1)} = 1; if(!$kinstalled) { $kinstalled = $ver; } else { $kinstalled = $ver if(&versioncmp($kinstalled, $ver) < 0); } } } close(HKERNEL); if($?) { print "$infostr 9 $version\n"; return; }; unless($distri{$version}) { print "$infostr 2 $version\n"; return; } unless($kinstalled.substr($add, 1) cmp $version) { print "$infostr 0 $version\n"; return; } print "$infostr 1 $version\n"; } ## # Taken from Sort::Versions 1.4 # Copyright (c) 1996, Kenneth J. Albanowski. ## sub versioncmp() { my @A = ($_[0] =~ /([-.]|\d+|[^-.\d]+)/g); my @B = ($_[1] =~ /([-.]|\d+|[^-.\d]+)/g); my ($A, $B); while (@A and @B) { $A = shift @A; $B = shift @B; if ($A eq '-' and $B eq '-') { next; } elsif ( $A eq '-' ) { return -1; } elsif ( $B eq '-') { return 1; } elsif ($A eq '.' and $B eq '.') { next; } elsif ( $A eq '.' ) { return -1; } elsif ( $B eq '.' ) { return 1; } elsif ($A =~ /^\d+$/ and $B =~ /^\d+$/) { if ($A =~ /^0/ || $B =~ /^0/) { return $A cmp $B if $A cmp $B; } else { return $A <=> $B if $A <=> $B; } } else { $A = uc $A; $B = uc $B; return $A cmp $B if $A cmp $B; } } @A <=> @B; } sub do_cleanup() { return unless $CLEANUP; system("$GETROOT yum clean packages"); } apt-dater-0.9.0/clients/yum/apt-dater-host.conf0000644000175000017500000000127011760760436020741 0ustar thomasthomas# use this command to become root $GETROOT="sudo"; # clean package cache after upgrade/install $CLEANUP=0; # the installation UUID $UUIDFILE = '/etc/apt-dater-host.uuid'; # If this host is part of (multiple) cluster(s), you might set a # symbolic name. Hosts with the same cluster name won't be upgraded # simultaneously by apt-dater (requires apt-dater 0.9 or above). #@CLUSTERS = qw(my-db-cluster); ## ## If this host is a mission critical system and ## needs scheduled downtimes for upgrades, enable ## (some) of the following $FORBID_* lines: ## # prevent apt-dater-host from upgrading packages #$FORBID_UPGRADE=1; # prevent apt-dater-host from installing packages #$FORBID_INSTALL=1; apt-dater-0.9.0/clients/zypper/0000755000175000017500000000000011760760436015755 5ustar thomasthomasapt-dater-0.9.0/clients/zypper/apt-dater-host0000755000175000017500000001606111760760436020543 0ustar thomasthomas#!/usr/bin/perl # apt-dater - terminal-based remote package update manager # # Authors: # Andre Ellguth # Thomas Liske # # Copyright Holder: # 2008-2012 (C) IBH IT-Service GmbH [http://www.ibh.de/apt-dater/] # # License: # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this package; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # use strict; use warnings; my $CFGFILE = '/etc/apt-dater-host.conf'; my $GETROOT = 'sudo'; my $FORBID_REFRESH = 0; my $FORBID_UPGRADE = 0; my $FORBID_INSTALL = 0; my $UUIDFILE = '/etc/apt-dater-host.uuid'; my @CLUSTERS; my $CMD = shift; my $ADPROTO = '0.6'; $ENV{'LC_ALL'} = 'C'; if (-r $CFGFILE) { eval `cat "$CFGFILE"` ; if($@ ne '') { print "ADPROTO: $ADPROTO\n"; print "ADPERR: Invalid config $CFGFILE: $@\n"; exit; } } $GETROOT = '' if($> == 0); die "Don't call this script directly!\n" unless (defined($CMD)); if($CMD eq 'sshkey') { die "Sorry, no shell access allowed!\n" unless(defined($ENV{'SSH_ORIGINAL_COMMAND'})); @ARGV = split(' ', $ENV{'SSH_ORIGINAL_COMMAND'}); shift; $CMD = shift; } die "Invalid command '$CMD'!\n" unless ($CMD=~/^(refresh|status|upgrade|install|kernel)$/); if ($CMD eq 'refresh') { print "ADPROTO: $ADPROTO\n"; if ($FORBID_REFRESH) { print STDERR "\n\n** Sorry, apt-dater based refreshs on this host are disabled! **\n\n" } else { &do_refresh; } &do_status; &do_kernel; } elsif ($CMD eq 'status') { print "ADPROTO: $ADPROTO\n"; &do_status; &do_kernel; } elsif ($CMD eq 'upgrade') { if ($FORBID_UPGRADE) { print STDERR "\n\n** Sorry, apt-dater based upgrades on this host are disabled! **\n\n" } else { &do_upgrade; } } elsif ($CMD eq 'install') { if ($FORBID_INSTALL) { print STDERR "\n\n** Sorry, apt-dater based installations on this host are disabled! **\n\n" } else { &do_install(@ARGV); } } elsif ($CMD eq 'kernel') { print "ADPROTO: $ADPROTO\n"; &do_kernel; } else { die "Internal error!\n"; } sub do_refresh() { if(system("$GETROOT zypper refresh")) { print "\nADPERR: Failed to execute '$GETROOT zypper refresh' ($?).\n"; exit(1); } } sub get_virt() { return "Unknown" unless (-x '/usr/bin/imvirt'); my $imvirt; chomp($imvirt = `/usr/bin/imvirt`); return $imvirt; } sub get_uname() { my $kernel; my $machine; chomp($kernel = `uname -s`); chomp($machine = `uname -m`); return "$kernel|$machine"; } sub do_status() { # retrieve lsb informations unless(open(HLSB, "lsb_release -a 2> /dev/null |")) { print "\nADPERR: Failed to execute 'lsb_release -a' ($!).\n"; exit(1); } my %lsb; while() { chomp; $lsb{$1}=$2 if (/^(Distributor ID|Release|Codename):\s+(\S.*)$/); } close(HLSB); if($?) { print "\nADPERR: Error executing 'lsb_release -a' ($?).\n"; exit(1); } print "LSBREL: $lsb{'Distributor ID'}|$lsb{'Release'}|$lsb{'Codename'}\n"; # retrieve virtualization informations print "VIRT: ".&get_virt."\n"; # retrieve uname informations print "UNAME: ".&get_uname."\n"; # calculate forbid mask my $mask = 0; $mask |= 1 if ($FORBID_REFRESH); $mask |= 2 if ($FORBID_UPGRADE); $mask |= 4 if ($FORBID_INSTALL); print "FORBID: $mask\n"; # add installation UUID if available if(-r $UUIDFILE && -s $UUIDFILE) { print "UUID: ", `head -n 1 "$UUIDFILE"`; } # add cluster name if available foreach my $CLUSTER (@CLUSTERS) { print "CLUSTER: $CLUSTER\n"; } # get packages which might be upgraded my %updates; unless(open(HAPT, "$GETROOT zypper --terse list-updates -a |")) { print "\nADPERR: Failed to execute '$GETROOT zypper --terse list-updates -a' ($!).\n"; exit(1); }; while() { chomp; my @line = split(/\s*\|\s*/); $updates{$line[2]} = $line[4] if($#line >= 4); } close(HAPT); if($?) { print "\nADPERR: Error executing '$GETROOT zypper --terse list-updates -a' ($?).\n"; exit(1); } # get version of installed packages my %installed; my %status; unless(open(HDPKG, "rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\n' |")) { print "\nADPERR: Failed to execute \"rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\\n'\" ($!).\n"; exit(1); }; while() { chomp; next unless (/^(\S+)\|\S+\|/); print "STATUS: "; print; if($updates{$1}) { print 'u=', $updates{$1}; } else { print 'i'; } print "\n"; } close(HDPKG); if($?) { print "\nADPERR: Error executing \"rpm -qa --qf '%{NAME}|%{VERSION}-%{RELEASE}|\\n'\" ($?).\n"; exit(1); }; } sub do_upgrade() { system("$GETROOT zypper -r update"); } sub do_install() { if($GETROOT) { system($GETROOT, 'zypper', '-r', 'install', @_); } else { system('rug', '-r', 'install', @_); } } sub do_kernel() { my $infostr = 'KERNELINFO:'; my $version = `uname -r`; chomp($version); my $add = ''; $add = $1 if($version =~ /(-[a-z]+)$/); my $pos = 0; my $kinstalled; my %distri; unless(open(HKERNEL, "rpm -q --whatprovides kernel --qf '%{NAME}|%{VERSION}-%{RELEASE}\n' |")) { print "$infostr 9 $version\n"; return; } while() { chomp; if(/^kernel$add\|(.+)/) { my $ver = $1; $distri{$ver.$add} = 1; if(!$kinstalled) { $kinstalled = $ver; } else { $kinstalled = $ver if(&versioncmp($kinstalled, $ver) < 0); } } } close(HKERNEL); if($?) { print "$infostr 9 $version\n"; return; } unless($distri{$version}) { print "$infostr 2 $version\n"; return; } unless($kinstalled.$add cmp $version) { print "$infostr 0 $version\n"; return; } print "$infostr 1 $version\n"; } ## # Taken from Sort::Versions 1.4 # Copyright (c) 1996, Kenneth J. Albanowski. ## sub versioncmp() { my @A = ($_[0] =~ /([-.]|\d+|[^-.\d]+)/g); my @B = ($_[1] =~ /([-.]|\d+|[^-.\d]+)/g); my ($A, $B); while (@A and @B) { $A = shift @A; $B = shift @B; if ($A eq '-' and $B eq '-') { next; } elsif ( $A eq '-' ) { return -1; } elsif ( $B eq '-') { return 1; } elsif ($A eq '.' and $B eq '.') { next; } elsif ( $A eq '.' ) { return -1; } elsif ( $B eq '.' ) { return 1; } elsif ($A =~ /^\d+$/ and $B =~ /^\d+$/) { if ($A =~ /^0/ || $B =~ /^0/) { return $A cmp $B if $A cmp $B; } else { return $A <=> $B if $A <=> $B; } } else { $A = uc $A; $B = uc $B; return $A cmp $B if $A cmp $B; } } @A <=> @B; } apt-dater-0.9.0/clients/zypper/apt-dater-host.conf0000644000175000017500000000131311760760436021456 0ustar thomasthomas# use this command to become root $GETROOT="sudo"; # the installation UUID $UUIDFILE = '/etc/apt-dater-host.uuid'; # If this host is part of (multiple) cluster(s), you might set a # symbolic name. Hosts with the same cluster name won't be upgraded # simultaneously by apt-dater (requires apt-dater 0.9 or above). #@CLUSTERS = qw(my-db-cluster); ## ## If this host is a mission critical system and ## needs scheduled downtimes for upgrades, enable ## (some) of the following $FORBID_* lines: ## # prevent apt-dater-host from refreshing package lists #$FORBID_REFRESH=1; # prevent apt-dater-host from upgrading packages #$FORBID_UPGRADE=1; # prevent apt-dater-host from installing packages #$FORBID_INSTALL=1; apt-dater-0.9.0/clients/Makefile.am0000644000175000017500000000021511760754207016455 0ustar thomasthomas#SUBDIRS = man EXTRA_DIST=debian-pkg DPKGBPKG=@DPKGBPKG@ distpkgs: $(EXTRA_DIST) debian-pkg: cd debian && $(DPKGBPKG) -rfakeroot -b -uc apt-dater-0.9.0/clients/Makefile.in0000644000175000017500000005154011760754125016474 0ustar thomasthomas# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = . am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/build/apt-dater.spec.in $(top_srcdir)/configure \ ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL NEWS TODO \ config.guess config.sub depcomp install-sh missing \ mkinstalldirs subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno configure.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = build/apt-dater.spec SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ html-recursive info-recursive install-data-recursive \ install-exec-recursive install-info-recursive \ install-recursive installcheck-recursive installdirs-recursive \ pdf-recursive ps-recursive uninstall-info-recursive \ uninstall-recursive ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CURSES_LIB = @CURSES_LIB@ CYGPATH_W = @CYGPATH_W@ DBXSL = @DBXSL@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FREEBSD_FALSE = @FREEBSD_FALSE@ FREEBSD_TRUE = @FREEBSD_TRUE@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLIB_CFLAGS = @GLIB_CFLAGS@ GLIB_LIBS = @GLIB_LIBS@ GMSGFMT = @GMSGFMT@ GMSGFMT_015 = @GMSGFMT_015@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ LDFLAGS = @LDFLAGS@ LIBICONV = @LIBICONV@ LIBINTL = @LIBINTL@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBXML2_CFLAGS = @LIBXML2_CFLAGS@ LIBXML2_LIBS = @LIBXML2_LIBS@ LINUX_FALSE = @LINUX_FALSE@ LINUX_TRUE = @LINUX_TRUE@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ TCL_CFLAGS = @TCL_CFLAGS@ TCL_LIBS = @TCL_LIBS@ USE_NLS = @USE_NLS@ VERSION = @VERSION@ XGETTEXT = @XGETTEXT@ XGETTEXT_015 = @XGETTEXT_015@ XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ XSLTPROC = @XSLTPROC@ ac_ct_CC = @ac_ct_CC@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ cv_path_tcl = @cv_path_tcl@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ SUBDIRS = po clients man src lib AUTOMAKE_OPTIONS = \ 1.9 \ dist-bzip2 ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = config.rpath m4/ChangeLog mkinstalldirs all: config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \ cd $(srcdir) && $(AUTOMAKE) --gnu \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 build/apt-dater.spec: $(top_builddir)/config.status $(top_srcdir)/build/apt-dater.spec.in cd $(top_builddir) && $(SHELL) ./config.status $@ uninstall-info-am: # This directory's subdirectories are mostly independent; you can cd # into them and run `make' without going through this Makefile. # To change the values of `make' variables: instead of editing Makefiles, # (1) if the variable is set in `config.status', edit `config.status' # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" mostlyclean-recursive clean-recursive distclean-recursive \ maintainer-clean-recursive: @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ rev=''; for subdir in $$list; do \ if test "$$subdir" = "."; then :; else \ rev="$$subdir $$rev"; \ fi; \ done; \ rev="$$rev ."; \ target=`echo $@ | sed s/-recursive//`; \ for subdir in $$rev; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done && test -z "$$fail" tags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ done ctags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) mkdir $(distdir) $(mkdir_p) $(distdir)/build $(distdir)/m4 $(distdir)/po @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -d "$(distdir)/$$subdir" \ || $(mkdir_p) "$(distdir)/$$subdir" \ || exit 1; \ distdir=`$(am__cd) $(distdir) && pwd`; \ top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ (cd $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$top_distdir" \ distdir="$$distdir/$$subdir" \ distdir) \ || exit 1; \ fi; \ done -find "$(distdir)" -type d ! -perm -755 \ -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e '1{h;s/./=/g;p;x;}' -e '$${p;x;}' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile config.h installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -f Makefile distclean-am: clean-am distclean-generic distclean-hdr distclean-local \ distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive info: info-recursive info-am: install-data-am: install-exec-am: install-info: install-info-recursive install-man: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: uninstall-info-am uninstall-info: uninstall-info-recursive .PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \ check-am clean clean-generic clean-recursive ctags \ ctags-recursive dist dist-all dist-bzip2 dist-gzip dist-shar \ dist-tarZ dist-zip distcheck distclean distclean-generic \ distclean-hdr distclean-local distclean-recursive \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-exec install-exec-am \ install-info install-info-am install-man install-strip \ installcheck installcheck-am installdirs installdirs-am \ maintainer-clean maintainer-clean-generic \ maintainer-clean-recursive mostlyclean mostlyclean-generic \ mostlyclean-recursive pdf pdf-am ps ps-am tags tags-recursive \ uninstall uninstall-am uninstall-info-am distclean-local: rm -rf *.cache *~ .project .settings .cdtproject check-gettext: @if test x$(USE_NLS) != "xyes" ; then echo "Missing gettext. Rerun configure and check for" \ "'checking whether to use NLS... yes'!" ; exit 1 ; fi update-po: check-gettext @find $(srcdir)/src/ -name "*.c" -print | sort > $(srcdir)/po/POTFILES.in.2 ; \ if diff $(srcdir)/po/POTFILES.in $(srcdir)/po/POTFILES.in.2 >/dev/null 2>&1 ; then \ rm -f $(srcdir)/po/POTFILES.in.2 ; \ else \ mv $(srcdir)/po/POTFILES.in.2 $(srcdir)/po/POTFILES.in ; \ fi cd po && $(MAKE) $(AM_MAKEFLAGS) update-po update-gmo: check-gettext cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo: check-gettext touch po/*.po cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo-%: check-gettext @language=`echo $@ | sed s/force-update-gmo-//` ; \ if test ! -f po/$$language.po ; then echo "file po/$$language.po does not exist" ; exit 1 ; fi ; \ touch po/$$language.po ; \ cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo .PHONY: check-gettext update-po update-gmo force-update-gmo # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: apt-dater-0.9.0/clients/ChangeLog0000644000175000017500000000404711761137243016176 0ustar thomasthomasapt-dater-host (0.9.0-adp0.6) unstable; urgency=low * Some pedantic stuff (use long options for aptitude and apt-get to ease code reading). Don't fail on untrusted/unauthenticated packages when checking for upgrades (still check for the upgrade itself). (Contributed by Mathieu PARENT due SF Bug#3158198) * Check for updates (refresh) using dist-upgrade. This show ABI-incompatible upgrades (like the recent bind9 one: http://www.debian.org/security/2010/dsa-2130.en.html). (Contributed by Mathieu PARENT due SF Bug#3158198) * Make upgrade method customizable and change default to dist-upgrade. (Inspired by Mathieu PARENT due SF Bug#3158198) * Allow apt-dater-host to be used with ssh keys. (Inspired by 'Chromosom' due SF Bug#2862139) * Implement multiple cluster support (debian, rug, yum, zypper). * zypper: - Fixed: zypper did not report any updates (reported by Ivan De Masi). - Use 'zypper refresh' for refreshing package repositories. * Add RELEASE header to version string on RPM queries. * Use apt-get as default package manager. (Closes Debian Bug#635048 by Felix Bartels) * Add dummy man page apt-dater-host.1 (contributed by Pattrik Matthäi). * Enable apt's update download cronjob. * Track kernel updates using /etc/kernel/postinst.d. * Catch and report config file errors. * Use ImVirt.pm instead of the legacy imvirt binary on Debian. -- Thomas Liske Tue, 29 May 2012 14:17:14 +0200 apt-dater-host (0.8.x-adp0.6) unstable; urgency=low * apt-dater-host split-off * ADP 0.6: - cluster support - archive source support * Don't fail if apt-dater-host could not get the installed kernel packages; fallback to unknown reboot status. (Closes SF Bug#2991717 by Karoly Molnar) * Use $DPKGTOOL to detect packages with updates. (Contributed by Alexandre Anriot) * Fix unknown yum based hosts (reported on Fedora) due bad package status interpretation. (Reported by Patrick Matthäi) -- Thomas Liske Mon, 22 Mar 2010 19:58:59 +0100 apt-dater-0.9.0/Makefile.in0000644000175000017500000005153011761141342015022 0ustar thomasthomas# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = . am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/build/apt-dater.spec.in $(top_srcdir)/configure \ ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL NEWS TODO \ config.guess config.sub depcomp install-sh missing \ mkinstalldirs subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno configure.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = build/apt-dater.spec SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ html-recursive info-recursive install-data-recursive \ install-exec-recursive install-info-recursive \ install-recursive installcheck-recursive installdirs-recursive \ pdf-recursive ps-recursive uninstall-info-recursive \ uninstall-recursive ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CURSES_LIB = @CURSES_LIB@ CYGPATH_W = @CYGPATH_W@ DBXSL = @DBXSL@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FREEBSD_FALSE = @FREEBSD_FALSE@ FREEBSD_TRUE = @FREEBSD_TRUE@ GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ GLIB_CFLAGS = @GLIB_CFLAGS@ GLIB_LIBS = @GLIB_LIBS@ GMSGFMT = @GMSGFMT@ GMSGFMT_015 = @GMSGFMT_015@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INTLLIBS = @INTLLIBS@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ LDFLAGS = @LDFLAGS@ LIBICONV = @LIBICONV@ LIBINTL = @LIBINTL@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBXML2_CFLAGS = @LIBXML2_CFLAGS@ LIBXML2_LIBS = @LIBXML2_LIBS@ LINUX_FALSE = @LINUX_FALSE@ LINUX_TRUE = @LINUX_TRUE@ LTLIBICONV = @LTLIBICONV@ LTLIBINTL = @LTLIBINTL@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MSGFMT = @MSGFMT@ MSGFMT_015 = @MSGFMT_015@ MSGMERGE = @MSGMERGE@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ TCL_CFLAGS = @TCL_CFLAGS@ TCL_LIBS = @TCL_LIBS@ USE_NLS = @USE_NLS@ VERSION = @VERSION@ XGETTEXT = @XGETTEXT@ XGETTEXT_015 = @XGETTEXT_015@ XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ XSLTPROC = @XSLTPROC@ ac_ct_CC = @ac_ct_CC@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ cv_path_tcl = @cv_path_tcl@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target = @target@ target_alias = @target_alias@ target_cpu = @target_cpu@ target_os = @target_os@ target_vendor = @target_vendor@ SUBDIRS = po man src lib AUTOMAKE_OPTIONS = \ 1.9 \ dist-bzip2 ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = config.rpath m4/ChangeLog mkinstalldirs all: config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \ cd $(srcdir) && $(AUTOMAKE) --gnu \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 build/apt-dater.spec: $(top_builddir)/config.status $(top_srcdir)/build/apt-dater.spec.in cd $(top_builddir) && $(SHELL) ./config.status $@ uninstall-info-am: # This directory's subdirectories are mostly independent; you can cd # into them and run `make' without going through this Makefile. # To change the values of `make' variables: instead of editing Makefiles, # (1) if the variable is set in `config.status', edit `config.status' # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" mostlyclean-recursive clean-recursive distclean-recursive \ maintainer-clean-recursive: @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ rev=''; for subdir in $$list; do \ if test "$$subdir" = "."; then :; else \ rev="$$subdir $$rev"; \ fi; \ done; \ rev="$$rev ."; \ target=`echo $@ | sed s/-recursive//`; \ for subdir in $$rev; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done && test -z "$$fail" tags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ done ctags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) mkdir $(distdir) $(mkdir_p) $(distdir)/build $(distdir)/m4 $(distdir)/po @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -d "$(distdir)/$$subdir" \ || $(mkdir_p) "$(distdir)/$$subdir" \ || exit 1; \ distdir=`$(am__cd) $(distdir) && pwd`; \ top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ (cd $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$top_distdir" \ distdir="$$distdir/$$subdir" \ distdir) \ || exit 1; \ fi; \ done -find "$(distdir)" -type d ! -perm -755 \ -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e '1{h;s/./=/g;p;x;}' -e '$${p;x;}' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile config.h installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -f Makefile distclean-am: clean-am distclean-generic distclean-hdr distclean-local \ distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive info: info-recursive info-am: install-data-am: install-exec-am: install-info: install-info-recursive install-man: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: uninstall-info-am uninstall-info: uninstall-info-recursive .PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \ check-am clean clean-generic clean-recursive ctags \ ctags-recursive dist dist-all dist-bzip2 dist-gzip dist-shar \ dist-tarZ dist-zip distcheck distclean distclean-generic \ distclean-hdr distclean-local distclean-recursive \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-exec install-exec-am \ install-info install-info-am install-man install-strip \ installcheck installcheck-am installdirs installdirs-am \ maintainer-clean maintainer-clean-generic \ maintainer-clean-recursive mostlyclean mostlyclean-generic \ mostlyclean-recursive pdf pdf-am ps ps-am tags tags-recursive \ uninstall uninstall-am uninstall-info-am distclean-local: rm -rf *.cache *~ .project .settings .cdtproject check-gettext: @if test x$(USE_NLS) != "xyes" ; then echo "Missing gettext. Rerun configure and check for" \ "'checking whether to use NLS... yes'!" ; exit 1 ; fi update-po: check-gettext @find $(srcdir)/src/ -name "*.c" -print | sort > $(srcdir)/po/POTFILES.in.2 ; \ if diff $(srcdir)/po/POTFILES.in $(srcdir)/po/POTFILES.in.2 >/dev/null 2>&1 ; then \ rm -f $(srcdir)/po/POTFILES.in.2 ; \ else \ mv $(srcdir)/po/POTFILES.in.2 $(srcdir)/po/POTFILES.in ; \ fi cd po && $(MAKE) $(AM_MAKEFLAGS) update-po update-gmo: check-gettext cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo: check-gettext touch po/*.po cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo force-update-gmo-%: check-gettext @language=`echo $@ | sed s/force-update-gmo-//` ; \ if test ! -f po/$$language.po ; then echo "file po/$$language.po does not exist" ; exit 1 ; fi ; \ touch po/$$language.po ; \ cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo .PHONY: check-gettext update-po update-gmo force-update-gmo # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: