move compiled-in option reporting into -info

Also explicitly say which ones aren't in.
This commit is contained in:
rathnor 2003-05-07 23:17:24 +00:00
parent 1b9a07dcbc
commit 72e4f1eeb3

View file

@ -22,7 +22,7 @@
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE. // DEALINGS IN THE SOFTWARE.
// $Id: main.cc,v 1.15 2003/05/07 22:19:59 fluxgen Exp $ // $Id: main.cc,v 1.16 2003/05/07 23:17:24 rathnor Exp $
@ -118,46 +118,61 @@ int main(int argc, char **argv) {
" -display <string>\t\tuse display connection.\n" " -display <string>\t\tuse display connection.\n"
" -rc <string>\t\t\tuse alternate resource file.\n" " -rc <string>\t\t\tuse alternate resource file.\n"
" -version\t\t\tdisplay version and exit.\n" " -version\t\t\tdisplay version and exit.\n"
" -info\t\t\tdisplay some useful information.\n"
" -help\t\t\t\tdisplay this help text and exit.\n\n"), " -help\t\t\t\tdisplay this help text and exit.\n\n"),
__fluxbox_version); __fluxbox_version);
::exit(0);
cout<<"Compiled with: "<<endl<< } else if (strcmp(argv[i], "-info") == 0 || strcmp(argv[i], "-i") == 0) {
#ifdef DEBUG #define NOT "-"
"DEBUG"<<endl<< cout<<"Compiled options ("<<NOT<<" => disabled): "<<endl<<
#ifndef DEBUG
NOT<<
#endif // DEBUG #endif // DEBUG
#ifdef SLIT "DEBUG"<<endl<<
"SLIT"<<endl<< #ifndef SLIT
NOT<<
#endif // SLIT #endif // SLIT
#ifdef HAVE_XPM "SLIT"<<endl<<
"XPM"<<endl<< #ifndef HAVE_XPM
NOT<<
#endif // HAVE_XPM #endif // HAVE_XPM
#ifdef USE_GNOME "XPM"<<endl<<
"GNOME"<<endl<< #ifndef USE_GNOME
NOT<<
#endif // USE_GNOME #endif // USE_GNOME
#ifdef KDE "GNOME"<<endl<<
"KDE"<<endl<< #ifndef KDE
NOT<<
#endif // KDE #endif // KDE
#ifdef USE_NEWWMSPEC "KDE"<<endl<<
"EWMH"<<endl<< #ifndef USE_NEWWMSPEC
NOT<<
#endif // USE_NEWWMSPEC #endif // USE_NEWWMSPEC
#ifdef REMEMBER "EWMH"<<endl<<
"REMEMBER"<<endl<< #ifndef REMEMBER
NOT<<
#endif // REMEMBER #endif // REMEMBER
#ifdef SHAPE "REMEMBER"<<endl<<
"SHAPE"<<endl<< #ifndef SHAPE
NOT<<
#endif // SHAPE #endif // SHAPE
#ifdef USE_XFT "SHAPE"<<endl<<
"XFT"<<endl<< #ifndef USE_XFT
NOT<<
#endif // USE_XFT #endif // USE_XFT
#ifdef USE_XMB "XFT"<<endl<<
"XMB"<<endl<< #ifndef USE_XMB
NOT<<
#endif // USE_XMB #endif // USE_XMB
#ifdef XINERAMA "XMB"<<endl<<
"XINERAMA"<<endl<< #ifndef XINERAMA
NOT<<
#endif // XINERAMA #endif // XINERAMA
#ifdef HAVE_XRENDER "XINERAMA"<<endl<<
"RENDER"<<endl<< #ifndef HAVE_XRENDER
NOT<<
#endif // HAVE_XRENDER #endif // HAVE_XRENDER
"RENDER"<<endl<<
endl; endl;
::exit(0); ::exit(0);
} }