diff --git a/.gitignore b/.gitignore index 0b064d319..5330fe041 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ DEBIAN *.a *.orig *.qm +*.o !qt_*.qm headers*.tar.gz license_template diff --git a/QupZilla.pro b/QupZilla.pro index fb4b1f07e..775422fc6 100644 --- a/QupZilla.pro +++ b/QupZilla.pro @@ -14,4 +14,5 @@ lessThan(QT_VERSION, 4.7) { mac|unix: system(test -d bin/plugins || mkdir bin/plugins) TEMPLATE = subdirs -SUBDIRS = src +SUBDIRS = src/lib src/main src/plugins +CONFIG += ordered diff --git a/src/plugins/plugins.pro b/src/plugins/plugins.pro index a8e138305..c08a0ad9d 100644 --- a/src/plugins/plugins.pro +++ b/src/plugins/plugins.pro @@ -1,5 +1,22 @@ TEMPLATE = subdirs -SUBDIRS = MouseGestures AccessKeysNavigation + +defineTest(addSubdir) { + for(subdir, 1) { + entries = $$files($$subdir/*) + for(entry, entries) { + fullPath = $$replace(entry, ;,"") + name = $$replace(fullPath, $$re_escape("$$subdir/"), "") + exists($$fullPath/*.pro): SUBDIRS += $$fullPath + } + } + + export (SUBDIRS) +} + +addSubdir($$PWD) + +outOfDirPlugins = $$(QUPZILLA_PLUGINS_SRCDIR) +!equals(outOfDirPlugins, "") : addSubdir($$(QUPZILLA_PLUGINS_SRCDIR)) # TestPlugin only in debug build -CONFIG(debug, debug|release): SUBDIRS += TestPlugin +!CONFIG(debug, debug|release): SUBDIRS -= $$PWD/TestPlugin diff --git a/src/src.pro b/src/src.pro deleted file mode 100644 index 157ad45f8..000000000 --- a/src/src.pro +++ /dev/null @@ -1,3 +0,0 @@ -TEMPLATE = subdirs -SUBDIRS = lib main plugins -CONFIG += ordered