summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2011-06-18 22:09:38 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-06-18 22:09:38 (GMT)
commita23b90319f9de8db0b455f5cd56e2428a3fcc53b (patch)
tree95d5baed116136cc214d8e1b5c49136b4abded5f /Swiften/Config
parentce4eb88be2eba12d5580bb22b48af3a0e915363b (diff)
parent5b88d16b2ea7edfbc1487751fb95f128b2c30330 (diff)
downloadswift-a23b90319f9de8db0b455f5cd56e2428a3fcc53b.zip
swift-a23b90319f9de8db0b455f5cd56e2428a3fcc53b.tar.bz2
Merge branch 'swift-1.x'
* swift-1.x: Fixed Debian manpages installation. Use LibXML as a Debian source dependency (instead of Expat) Tweak help documentation and add manpages. Conflicts: Swift/QtUI/QtSwift.cpp
Diffstat (limited to 'Swiften/Config')
-rw-r--r--Swiften/Config/swiften-config.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/Swiften/Config/swiften-config.cpp b/Swiften/Config/swiften-config.cpp
index 0c46cf0..81a8357 100644
--- a/Swiften/Config/swiften-config.cpp
+++ b/Swiften/Config/swiften-config.cpp
@@ -16,6 +16,7 @@
#include <Swiften/Base/Platform.h>
#include <Swiften/Base/Paths.h>
+#include <Swiften/Version.h>
#include "swiften-config.h"
@@ -35,6 +36,7 @@ int main(int argc, char* argv[]) {
boost::program_options::options_description desc;
desc.add_options()
("help", "Show this help message")
+ ("version", "Show version information")
("libs", "List the library flags")
("cflags", "List the compiler & preprocessor flags")
;
@@ -56,9 +58,17 @@ int main(int argc, char* argv[]) {
}
if (vm.count("help") > 0) {
+ std::cout << "swiften-config outputs the Swiften build options." << std::endl;
+ std::cout << std::endl;
+ std::cout << "Usage: swiften-config [OPTIONS]..." << std::endl;
+ std::cout << std::endl;
std::cout << desc << "\n";
return 0;
}
+ if (vm.count("version") > 0) {
+ std::cout << "swiften-config " << SWIFTEN_VERSION_STRING << std::endl;
+ return 0;
+ }
// Read in all variables
std::vector<std::string> libs;