From 114a878c64ce6f8223cfd22d76a20eb16d177e5e Mon Sep 17 00:00:00 2001 From: toma Date: Wed, 25 Nov 2009 17:56:58 +0000 Subject: Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- buildtools/autotools/misc.h | 65 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 buildtools/autotools/misc.h (limited to 'buildtools/autotools/misc.h') diff --git a/buildtools/autotools/misc.h b/buildtools/autotools/misc.h new file mode 100644 index 00000000..9db9919e --- /dev/null +++ b/buildtools/autotools/misc.h @@ -0,0 +1,65 @@ +/*************************************************************************** +* Copyright (C) 2001-2002 by Bernd Gehrmann * +* bernd@kdevelop.org * +* * +* 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. * +* * +***************************************************************************/ + +#ifndef _MISC_H_ +#define _MISC_H_ + +#include +#include +#include + +/** + * Very small helper class. It has just static methods. + */ +class AutoProjectTool +{ +public: + + /** + * Loads the compiler options plugin for the given compiler, executes the dialog + * with some initial flags, and returns the new flags. + */ + static QString execFlagsDialog( const QString &compiler, const QString &flags, QWidget *parent ); + + /** + * Returns the canonicalized version of a file name, i.e. + * the file name with special characters replaced by underscores + */ + static QString canonicalize( const QString &str ); + + /** + * Parses a Makefile.am and stores its variable assignments + * in a map. + */ + static void parseMakefileam( const QString &filename, QMap *variables ); + + static void addToMakefileam( const QString &filename, QMap variables ); + static void removeFromMakefileam( const QString &filename, QMap variables ); + static void setMakefileam ( const QString &fileName, QMap variables ); + + static void addRemoveMakefileam(const QString &fileName, QMap variables, bool add); + + /** + * Parses configure.in and splits AC_OUTPUT into a QStringList + */ + static QStringList configureinLoadMakefiles( QString configureinpath ); + + /** + * Receives a QStringList and puts it into + * configure.in as arguments to AC_OUTPUT + */ + static void configureinSaveMakefiles( QString configureinpath, QStringList makefiles ); + +}; + +#endif +// kate: indent-mode csands; tab-width 4; + -- cgit v1.2.3