+
+ /* Set some application metadata. */
+ QApplication::setApplicationVersion(APP_VERSION);
+ QApplication::setApplicationName("sigrok-qt");
+ QApplication::setOrganizationDomain("http://www.sigrok.org");
+
+ /* Initialise libsigrok */
+ if (sr_init() != SR_OK) {
+ qDebug() << "ERROR: libsigrok init failed.";
+ return 1;
+ }
+
+ /* Initialise libsigrokdecode */
+ if (srd_init(NULL) != SRD_OK) {
+ qDebug() << "ERROR: libsigrokdecode init failed.";
+ return 1;
+ }
+
+ /* Load the protocol decoders */
+ srd_decoder_load_all();
+
+ /* Initialise the main window */