Changeset 17331 in vbox
- Timestamp:
- Mar 4, 2009 9:05:06 AM (16 years ago)
- File:
-
- 1 edited
-
trunk/configure.vbs (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/configure.vbs
r17329 r17331 1742 1742 end sub 1743 1743 1744 1744 1745 '' 1745 1746 ' Checks if the specified path points to an usable libxslt or not. … … 1763 1764 end function 1764 1765 1765 dim g_strQtVer ' Global version number of Qt (3, 333, 338 for example) 1766 g_strQtVer = "" 1767 1768 dim g_strQtLib ' Full path to Qt .lib found 1769 g_strQtLib = "" 1770 1771 dim g_strQtDll ' Full path to Qt .dll found 1772 g_strQtDll = "" 1773 1774 '' 1775 ' Checks for any Qt binaries. Failure here isn't fatal. 1776 sub CheckForQt(strOptQt) 1777 dim strPathQt, str, blnQtWinFree 1778 1779 PrintHdr "Qt" 1780 1781 ' 1782 ' Try find the Qt installation (user specified path with --with-qt=). 1783 ' 1784 strPathQt = "" 1785 blnQtWinFree = False 1786 1787 LogPrint "Checking for user specified path of Qt ..." 1788 if (strPathQt = "") And (strOptQt <> "") then 1789 strOptQt = UnixSlashes(strOptQt) 1790 if CheckForQtSub(strOptQt) then strPathQt = strOptQt 1791 1792 if (strPathQt = "") And (strOptQt <> "") then 1793 LogPrint "Checking for user specified path of Qt/free ..." 1794 if CheckForQtWinFreeSub(strOptQt) then 1795 strPathQt = strOptQt 1796 blnQtWinFree = True 1797 end if 1798 end if 1799 1800 end if 1801 1802 ' 1803 ' Search for any 3.x version 1804 ' 1805 LogPrint "Checking for licensed version of Qt ..." 1806 if strPathQt = "" then 1807 str = LogFindDir(g_strPathDev & "/win.x86/qt", "v3.*") 1808 if (str <> "") then 1809 if CheckForQtSub(str) then strPathQt = str 1810 end if 1811 end if 1812 1813 ' 1814 ' Try to find the Open Source project "qtwin" Qt/free, 1815 ' located at http://qtwin.sf.net 1816 ' 1817 if strPathQt = "" then 1818 LogPrint "Checking for Qt/free ..." 1819 str = LogFindDir(g_strPathDev & "/win.x86/qt", "v3.*") 1820 if (str <> "") then 1821 if CheckForQtWinFreeSub(str) then 1822 strPathQt = str 1823 blnQtWinFree = True 1824 end if 1825 end if 1826 end if 1827 1828 '' @todo check for Qt installations and stuff later. 1829 1830 ' Found anything? 1831 if strPathQt = "" then 1832 CfgPrint "VBOX_WITH_QTGUI=" 1833 PrintResult "Qt", "not found" 1834 else 1835 CfgPrint "VBOX_PATH_QT := " & strPathQt 1836 CfgPrint "QTDIR = $(VBOX_PATH_QT)" 1837 1838 if blnQtWinFree = True then ' The "qtwin" 1839 PrintResult "Qt (v" & g_strQtVer & ", QtWin/Free)", strPathQt 1840 else ' Licensed from Trolltech 1841 PrintResult "Qt (v" & g_strQtVer & ")", strPathQt 1842 end if 1843 1844 CfgPrint "LIB_QT = " & g_strQtLib 1845 CfgPrint "VBOX_DLL_QT = " & g_strQtDll 1846 end if 1847 end sub 1848 1849 1850 '' 1851 ' Checks if the specified path points to an usable Qt install or not. 1852 function CheckForQtSub(strPathQt) 1853 1854 CheckForQtSub = False 1855 LogPrint "trying: strPathQt=" & strPathQt 1856 1857 ' For Qt 3.3.3 1858 dim str 1859 if LogFileExists(strPathQt, "bin/moc.exe") _ 1860 And LogFileExists(strPathQt, "bin/uic.exe") _ 1861 And LogFileExists(strPathQt, "include/qvbox.h") _ 1862 And LogFileExists(strPathQt, "include/qt_windows.h") _ 1863 And LogFileExists(strPathQt, "include/qapplication.h") _ 1864 And LogFileExists(strPathQt, "include/qtextedit.h") _ 1865 And LogFileExists(strPathQt, "lib/dynamic/qtmain.lib") _ 1866 then 1867 1868 ' This check might need improving. 1869 str = LogFindFile(strPathQt, "lib/dynamic/qt-mt33*.lib") 1870 if str <> "" then 1871 g_strQtVer = Mid(str, Len("qt-mt") + 1, Len(str) - Len("qt-mt.lib")) 1872 if LogFileExists(strPathQt, "bin/qt-mt" & g_strQtVer & ".dll") then 1873 g_strQtLib = strPathQt & "/lib/dynamic/" & str 1874 g_strQtDll = strPathQt & "/bin/qt-mt" & g_strQtVer & ".dll" 1875 CheckForQtSub = True 1876 end if 1877 end if 1878 end if 1879 1880 ' For >= Qt 3.3.8 (no "dynamic" folder, VBoxQt338.lib /.dll instead of qt-mt33*.lib /.dll) 1881 str = "" 1882 if LogFileExists(strPathQt, "bin/moc.exe") _ 1883 And LogFileExists(strPathQt, "bin/uic.exe") _ 1884 And LogFileExists(strPathQt, "include/qvbox.h") _ 1885 And LogFileExists(strPathQt, "include/qt_windows.h") _ 1886 And LogFileExists(strPathQt, "include/qapplication.h") _ 1887 And LogFileExists(strPathQt, "include/qtextedit.h") _ 1888 And LogFileExists(strPathQt, "lib/qtmain.lib") _ 1889 then 1890 1891 ' This check might need improving. 1892 str = LogFindFile(strPathQt, "lib/VBoxQt3*.lib") 1893 if str <> "" then 1894 g_strQtVer = Mid(str, Len("VBoxQt") + 1, Len(str) - Len("VBoxQt.lib")) 1895 if LogFileExists(strPathQt, "bin/VBoxQt" & g_strQtVer & ".dll") then 1896 g_strQtLib = strPathQt & "/lib/" & str 1897 g_strQtDll = strPathQt & "/bin/VBoxQt" & g_strQtVer & ".dll" 1898 CheckForQtSub = True 1899 end if 1900 end if 1901 end if 1902 1903 end function 1904 1905 1906 '' 1907 ' Checks if the specified path points to an usable "qtwin" Qt/Free install or not. 1908 ' "qtwin" is an Open Source project located at http://qtwin.sf.net and builds Qt 3.x.x sources 1909 ' of the official GPL'ed Qt 4.x sources from Trolltech. 1910 function CheckForQtWinFreeSub(strPathQt) 1911 1912 CheckForQtWinFreeSub = False 1913 LogPrint "trying: strPathQt=" & strPathQt 1914 if LogFileExists(strPathQt, "bin/moc.exe") _ 1915 And LogFileExists(strPathQt, "bin/uic.exe") _ 1916 And LogFileExists(strPathQt, "include/qvbox.h") _ 1917 And LogFileExists(strPathQt, "include/qt_windows.h") _ 1918 And LogFileExists(strPathQt, "include/qapplication.h") _ 1919 And LogFileExists(strPathQt, "include/qtextedit.h") _ 1920 And LogFileExists(strPathQt, "lib/qtmain.lib") _ 1921 then 1922 dim str 1923 1924 ' This check might need improving. 1925 str = LogFindFile(strPathQt, "lib/qt-mt3.lib") 1926 if str <> "" then 1927 g_strQtVer = Mid(str, Len("qt-mt") + 1, Len(str) - Len("qt-mt.lib")) 1928 if LogFileExists(strPathQt, "bin/qt-mt" & g_strQtVer & ".dll") then 1929 g_strQtLib = strPathQt & "/lib/" & str 1930 g_strQtDll = strPathQt & "/bin/qt-mt" & g_strQtVer & ".dll" 1931 CheckForQtWinFreeSub = True 1932 end if 1933 end if 1934 end if 1935 end function 1936 1937 1766 1767 '' 1938 1768 '' 1939 1769 ' Checks for any Qt4 binaries. … … 2008 1838 Print " --with-libSDL=PATH " 2009 1839 Print " --with-MinGW=PATH " 2010 Print " --with-Qt=PATH "2011 1840 Print " --with-Qt4=PATH " 2012 1841 Print " --with-SDK=PATH " … … 2041 1870 strOptlibSDL = "" 2042 1871 strOptMingW = "" 2043 strOptQt = ""1872 strOptQt4 = "" 2044 1873 strOptSDK = "" 2045 1874 strOptVC = "" … … 2076 1905 case "--with-mingw" 2077 1906 strOptMingW = strPath 2078 case "--with-qt"2079 strOptQt = strPath2080 1907 case "--with-qt4" 2081 1908 strOptQt4 = strPath … … 2148 1975 CheckForXml2 strOptXml2 2149 1976 CheckForXslt strOptXslt 2150 CheckForQt strOptQt2151 1977 CheckForQt4 strOptQt4 2152 1978 if g_blnInternalMode then
Note:
See TracChangeset
for help on using the changeset viewer.

