diff --git a/qtcreator.pri b/qtcreator.pri
index a2215a28b1ecd7b3956cffc69333bf12bdecb657..73f0574df9228af1d57289b80f84a7bc6ecb71d7 100644
--- a/qtcreator.pri
+++ b/qtcreator.pri
@@ -146,12 +146,6 @@ unix {
     UI_DIR = $${OUT_PWD}/.uic
 }
 
-linux-g++* {
-    # Bail out on non-selfcontained libraries. Just a security measure
-    # to prevent checking in code that does not compile on other platforms.
-    QMAKE_LFLAGS += -Wl,--allow-shlib-undefined -Wl,--no-undefined
-}
-
 win32-msvc* { 
     #Don't warn about sprintf, fopen etc being 'unsafe'
     DEFINES += _CRT_SECURE_NO_WARNINGS
diff --git a/src/qtcreatorplugin.pri b/src/qtcreatorplugin.pri
index 09a0eee70ecc34103f3ac72cc24cd8a95269d684..01a7c63b6b5d6c5ecbac23e6268bbac1089430a7 100644
--- a/src/qtcreatorplugin.pri
+++ b/src/qtcreatorplugin.pri
@@ -60,6 +60,7 @@ macx {
 contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
 
 CONFIG += plugin plugin_with_soname
+linux*:QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF
 
 !macx {
     target.path = /$$IDE_LIBRARY_BASENAME/qtcreator/plugins/$$PROVIDER