mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-04 09:00:44 +00:00
Use a qt.conf to point plugins at qtplugins/ in the application path.
* We can point the platform plugins path at the application dir for qwindows.dll for example, but there's no equivalent for image format plugins which we need for qsvg.dll. So instead we shove them all under an explicit qtplugins path. * Also now that we have this, copy qsvg.dll into the distribution.
This commit is contained in:
@@ -137,21 +137,7 @@ int main(int argc, char *argv[])
|
||||
filename = QString();
|
||||
}
|
||||
|
||||
argc += 2;
|
||||
|
||||
char **argv_mod = new char *[argc];
|
||||
|
||||
for(int i = 0; i < argc - 2; i++)
|
||||
argv_mod[i] = argv[i];
|
||||
|
||||
char arg[] = "-platformpluginpath";
|
||||
QString path = QFileInfo(QString::fromUtf8(argv[0])).absolutePath();
|
||||
QByteArray pathChars = path.toUtf8();
|
||||
|
||||
argv_mod[argc - 2] = arg;
|
||||
argv_mod[argc - 1] = pathChars.data();
|
||||
|
||||
QApplication application(argc, argv_mod);
|
||||
QApplication application(argc, argv);
|
||||
|
||||
{
|
||||
PersistantConfig config;
|
||||
@@ -247,7 +233,5 @@ int main(int argc, char *argv[])
|
||||
Formatter::shutdown();
|
||||
}
|
||||
|
||||
delete[] argv_mod;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
[Paths]
|
||||
Plugins=qtplugins
|
||||
@@ -68,4 +68,7 @@
|
||||
<file>action.png</file>
|
||||
<file>action_hover.png</file>
|
||||
</qresource>
|
||||
<qresource prefix="/qt/etc">
|
||||
<file>qt.conf</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
||||
@@ -1512,7 +1512,12 @@
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\plugins\platforms\qwindows.dll">
|
||||
<Link>qwindows.dll</Link>
|
||||
<Link>qtplugins\platforms\qwindows.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\plugins\imageformats\qsvg.dll">
|
||||
<Link>qtplugins\imageformats\qsvg.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
@@ -1541,6 +1546,21 @@
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\plugins\platforms\qwindowsd.dll" Condition="$(Configuration)==QTDebug">
|
||||
<Link>qtplugins\platforms\qwindowsd.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\plugins\imageformats\qsvgd.dll" Condition="$(Configuration)==QTDebug">
|
||||
<Link>qtplugins\imageformats\qsvgd.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>false</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\bin\Qt5Cored.dll" Condition="$(Configuration)==QTDebug">
|
||||
<Link>Qt5Cored.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<Visible>False</Visible>
|
||||
</Content>
|
||||
<Content Include="3rdparty\qt\$(Platform)\bin\Qt5Cored.dll" Condition="$(Configuration)==QTDebug">
|
||||
<Link>Qt5Cored.dll</Link>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
|
||||
Reference in New Issue
Block a user