summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--doc/index.html6
-rw-r--r--src/qt-win32.patch186
-rw-r--r--src/qt.mk152
3 files changed, 343 insertions, 1 deletions
diff --git a/doc/index.html b/doc/index.html
index d142098..2dbdc93 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -370,7 +370,7 @@ AR=$(CROSS)ar</pre>
</p>
<p>
- This release enables OpenMP support in GCC.
+ This release adds support for Qt.
</p>
<p>
@@ -378,6 +378,10 @@ AR=$(CROSS)ar</pre>
</p>
<p>
+ OpenMP support has been enabled in GCC.
+ </p>
+
+ <p>
Almost all packages are updated to their latest version.
</p>
</dd>
diff --git a/src/qt-win32.patch b/src/qt-win32.patch
new file mode 100644
index 0000000..a58d598
--- /dev/null
+++ b/src/qt-win32.patch
@@ -0,0 +1,186 @@
+Copyright (C) 2009 Mark Brand
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject
+to the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+--- qt-everywhere-opensource-src-4.6.0-tp1.native/configure 2009-09-07 13:00:28.000000000 +0200
++++ qt-everywhere-opensource-src-4.6.0-tp1/configure 2009-10-02 18:22:05.000000000 +0200
+@@ -600,7 +600,7 @@
+ rm -f "$outpath/config.tests/.qmake.cache"
+ cp "$QMAKE_VARS_FILE" "$outpath/config.tests/.qmake.cache"
+
+-QMakeVar add styles "cde mac motif plastique cleanlooks windows"
++QMakeVar add styles "cde mac motif plastique cleanlooks windows windowsxp windowsvista"
+ QMakeVar add decorations "default windows styled"
+ QMakeVar add mouse-drivers "pc"
+ if [ "$UNAME_SYSTEM" = "Linux" ] ; then
+@@ -4961,7 +4961,11 @@
+ echo "Basic XLib functionality test failed!"
+ echo " You might need to modify the include and library search paths by editing"
+ echo " QMAKE_INCDIR_X11 and QMAKE_LIBDIR_X11 in ${XQMAKESPEC}."
+- exit 1
++echo NOTICE: This is a specially modifed configure script!
++echo For our purposes we do not need or want X11.
++echo For the natve target we only build the tools.
++echo For the win32-g++ target there is no X11
++# exit 1
+ fi
+
+ # auto-detect OpenGL support (es1 = OpenGL ES 1.x Common, es1cl = ES 1.x common lite, es2 = OpenGL ES 2.x)
+@@ -7594,7 +7598,10 @@
+ [ "$IN_ROOT" = "no" ] && continue
+
+ case $a in
+- *winmain/winmain.pro) continue ;;
++ *winmain/winmain.pro)
++ if [ "$XPLATFORM" != "win32-g++" ]; then
++ continue
++ fi ;;
+ *s60main/s60main.pro) continue ;;
+ */qmake/qmake.pro) continue ;;
+ *tools/bootstrap*|*tools/moc*|*tools/rcc*|*tools/uic*) SPEC=$QMAKESPEC ;;
+--- qt-everywhere-opensource-src-4.6.0-tp1.native/src/gui/inputmethod/qwininputcontext_win.cpp 2009-09-07 13:00:30.000000000 +0200
++++ qt-everywhere-opensource-src-4.6.0-tp1/src/gui/inputmethod/qwininputcontext_win.cpp 2009-10-02 09:57:20.000000000 +0200
+@@ -49,6 +49,8 @@
+ #include "qtextformat.h"
+ #include "qtextboundaryfinder.h"
+
++bool qt_sendSpontaneousEvent(QObject*, QEvent*);
++
+ //#define Q_IME_DEBUG
+
+ #ifdef Q_IME_DEBUG
+--- qt-everywhere-opensource-src-4.6.0-tp1.native/mkspecs/win32-g++/qplatformdefs.h 2009-09-07 13:00:28.000000000 +0200
++++ qt-everywhere-opensource-src-4.6.0-tp1/mkspecs/win32-g++/qplatformdefs.h 2009-10-02 09:57:20.000000000 +0200
+@@ -160,5 +160,7 @@
+ # define W_OK 2
+ # define R_OK 4
+
++// for some reason this isn't declared where it should be
++LRESULT CALLBACK qt_internal_proc(HWND hwnd, UINT message, WPARAM wp, LPARAM lp);
+
+ #endif // QPLATFORMDEFS_H
+--- qt-everywhere-opensource-src-4.6.0-tp1.native/mkspecs/win32-g++/qmake.conf 2009-09-07 13:00:28.000000000 +0200
++++ qt-everywhere-opensource-src-4.6.0-tp1/mkspecs/win32-g++/qmake.conf 2009-10-02 09:57:20.000000000 +0200
+@@ -3,23 +3,30 @@
+ #
+ # Written for MinGW
+ #
++load(qt_config)
+
+ MAKEFILE_GENERATOR = MINGW
+ TEMPLATE = app
+ CONFIG += qt warn_on release link_prl copy_dir_files debug_and_release debug_and_release_target precompile_header
++CONFIG += exceptions windows win32
++CONFIG -= freetype
++QT_CONFIG -= freetype
+ QT += core gui
+ DEFINES += UNICODE QT_LARGEFILE_SUPPORT
++DEFINES -= QT_LARGEFILE_SUPPORT
++DEFINES += QT_TABLET QT_SESSIONMANAGER QT_NO_DIRECT3D QT_NO_CODECS
+ QMAKE_COMPILER_DEFINES += __GNUC__ WIN32
+
+ QMAKE_EXT_OBJ = .o
+ QMAKE_EXT_RES = _res.o
+
+-QMAKE_CC = gcc
++QMAKE_CC = HOSTPLATFORMPREFIX-gcc
+ QMAKE_LEX = flex
+ QMAKE_LEXFLAGS =
+ QMAKE_YACC = byacc
+ QMAKE_YACCFLAGS = -d
+ QMAKE_CFLAGS =
++QMAKE_CFLAGS += -isystem HOSTPLATFORMINCLUDE
+ QMAKE_CFLAGS_DEPS = -M
+ QMAKE_CFLAGS_WARN_ON = -Wall
+ QMAKE_CFLAGS_WARN_OFF = -w
+@@ -27,7 +34,7 @@
+ QMAKE_CFLAGS_DEBUG = -g
+ QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+
+-QMAKE_CXX = g++
++QMAKE_CXX = HOSTPLATFORMPREFIX-g++
+ QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+ QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+ QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+@@ -42,6 +49,7 @@
+ QMAKE_CXXFLAGS_EXCEPTIONS_OFF = -fno-exceptions
+
+ QMAKE_INCDIR =
++QMAKE_INCDIR += .
+ QMAKE_INCDIR_QT = $$[QT_INSTALL_HEADERS]
+ QMAKE_LIBDIR_QT = $$[QT_INSTALL_LIBS]
+
+@@ -50,8 +58,8 @@
+ QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $obj $src
+ QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
+
+-QMAKE_LINK = g++
+-QMAKE_LINK_C = gcc
++QMAKE_LINK = HOSTPLATFORMPREFIX-g++
++QMAKE_LINK_C = HOSTPLATFORMPREFIX-gcc
+ QMAKE_LFLAGS = -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-reloc
+ QMAKE_LFLAGS_EXCEPTIONS_ON = -mthreads -Wl
+ QMAKE_LFLAGS_EXCEPTIONS_OFF =
+@@ -72,15 +80,18 @@
+ QMAKE_LIBS_COMPAT = -ladvapi32 -lshell32 -lcomdlg32 -luser32 -lgdi32 -lws2_32
+ QMAKE_LIBS_QT_ENTRY = -lmingw32 -lqtmain
+
++QMAKE_SH = bash
++
+ !isEmpty(QMAKE_SH) {
+ MINGW_IN_SHELL = 1
+ QMAKE_DIR_SEP = /
+ QMAKE_COPY = cp
+- QMAKE_COPY_DIR = xcopy /s /q /y /i
++ QMAKE_COPY_DIR = cp -r
+ QMAKE_MOVE = mv
+ QMAKE_DEL_FILE = rm
+- QMAKE_MKDIR = mkdir
++ QMAKE_MKDIR = mkdir -p
+ QMAKE_DEL_DIR = rmdir
++ QMAKE_SYMBOLIC_LINK = ln -s
+ QMAKE_CHK_DIR_EXISTS = test -d
+ } else {
+ QMAKE_COPY = copy /y
+@@ -92,15 +103,15 @@
+ QMAKE_CHK_DIR_EXISTS = if not exist
+ }
+
+-QMAKE_MOC = $$[QT_INSTALL_BINS]$${DIR_SEPARATOR}moc.exe
+-QMAKE_UIC = $$[QT_INSTALL_BINS]$${DIR_SEPARATOR}uic.exe
+-QMAKE_IDC = $$[QT_INSTALL_BINS]$${DIR_SEPARATOR}idc.exe
+-
+-QMAKE_IDL = midl
+-QMAKE_LIB = ar -ru
+-QMAKE_RC = windres
++QMAKE_MOC = moc
++QMAKE_UIC = uic
++QMAKE_IDC = idc
++QMAKE_RCC = rcc
++
++#QMAKE_IDL = midl
++QMAKE_LIB = HOSTPLATFORMPREFIX-ar -ru
++QMAKE_RC = HOSTPLATFORMPREFIX-windres
+ QMAKE_ZIP = zip -r -9
+
+-QMAKE_STRIP = strip
++QMAKE_STRIP = HOSTPLATFORMPREFIX-strip
+ QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+-load(qt_config)
diff --git a/src/qt.mk b/src/qt.mk
new file mode 100644
index 0000000..e4af8ee
--- /dev/null
+++ b/src/qt.mk
@@ -0,0 +1,152 @@
+# Copyright (C) 2009 Mark Brand
+# Volker Grabsch
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject
+# to the following conditions:
+#
+# The above copyright notice and this permission notice shall be
+# included in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+# Qt
+PKG := qt
+$(PKG)_IGNORE :=
+$(PKG)_VERSION := 4.6.0-tp1
+$(PKG)_CHECKSUM := 4394bea076279ea090549d3caa00cc1f5e33a22b
+$(PKG)_SUBDIR := $(PKG)-everywhere-opensource-src-$($(PKG)_VERSION)
+$(PKG)_FILE := $(PKG)-everywhere-opensource-src-$($(PKG)_VERSION).tar.gz
+$(PKG)_WEBSITE := http://qt.nokia.com/
+$(PKG)_URL := http://get.qt.nokia.com/qt/source/$($(PKG)_FILE)
+$(PKG)_DEPS := gcc
+
+define $(PKG)_UPDATE
+ wget -q -O- 'http://qt.gitorious.org/qt/qt/commits' | \
+ grep '<li><a href="/qt/qt/commit/' | \
+ $(SED) -n 's,.*<a[^>]*>v\([0-9][^>]*\)<.*,\1,p' | \
+ tail -1
+endef
+
+define $(PKG)_BUILD
+
+ # Note on patchfile qt-win32.patch
+ # A patchfile should have been applied already. Since we make a copy
+ # of the patched directory here, it is important that the changes
+ # in the patches do not break the native build.
+
+ # Bogus install bin directory for the DLLs
+ # Should stay empty because of -prefix-install
+ mkdir '$(1)'/bindirsink
+
+ # First configure a minimal native version of Qt
+ # for moc, rcc, uic and qmake
+ cp -a '$(1)' '$(1)'.native
+ cd '$(1)'.native && ./configure \
+ -opensource \
+ -confirm-license \
+ -prefix '$(PREFIX)/$(TARGET)' \
+ -prefix-install \
+ -bindir '$(1)'/bindirsink \
+ -fast \
+ -nomake demos \
+ -nomake examples \
+ -nomake libs \
+ -nomake tools \
+ -nomake docs \
+ -nomake translations
+
+ $(MAKE) -C '$(1)'.native -j $(JOBS) sub-tools-bootstrap
+ $(MAKE) -C '$(1)'.native -j $(JOBS) sub-moc
+ $(MAKE) -C '$(1)'.native -j $(JOBS) sub-rcc
+ $(MAKE) -C '$(1)'.native -j $(JOBS) sub-uic
+ $(MAKE) -C '$(1)'.native clean
+
+ # Trick the build system into using native tools
+ ln -s '$(1)'.native/bin/{moc,rcc,uic,qmake} '$(1)'/bin/
+
+ # Make sure we don't build the tools again
+ echo 'qmake:' >'$(1)'/qmake/Makefile.unix
+ for f in `ls -1 '$(1)'/src/tools`; \
+ do echo TEMPLATE = subdirs >'$(1)'/src/tools/"$$f"/"$$f".pro; \
+ done
+
+ # Trick the buildsystem into using win32 feature files:
+ mv '$(1)'/mkspecs/features/unix '$(1)'/mkspecs/features/unix.orig
+ ln -s win32 '$(1)'/mkspecs/features/unix
+
+ # Adjust the mkspec values that contain the TARGET platform prefix
+ $(SED) 's/HOSTPLATFORMPREFIX-/$(TARGET)-/g;' -i '$(1)'/mkspecs/win32-g++/qmake.conf
+ $(SED) 's^HOSTPLATFORMINCLUDE^$(PREFIX)/$(TARGET)/include^g;' -i '$(1)'/mkspecs/win32-g++/qmake.conf
+
+ # Make sure qmake doesn't use compilation paths meant for unix
+ find '$(1)'/src -name '*.pr[oi]' -exec \
+ $(SED) 's/\(^\|[^_/]\)unix/\1linux/g;' -i {} \;
+
+ # Make qmake use compilation paths meant for Windows
+ find '$(1)'/src -name '*.pr[oi]' -exec \
+ $(SED) 's/\(^\|[^_/]\)win32\([^-]\|$$\)/\1unix\2/g;' -i {} \;
+
+ # Fix-ups for files not found during configure
+ # Probably errors in QT 4.6 Technology Preview 1
+ ln -s ../WebKit.pri '$(1)'/src/3rdparty/webkit/WebKit
+
+ # Fix-ups for files not found during make
+ # Probably errors in QT 4.6 Technology Preview 1
+ mkdir '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/release
+ ln -s ../chartables.c '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/release/
+ ln -s ../Grammar.cpp '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/release/
+ mkdir '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/debug
+ ln -s ../chartables.c '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/debug/
+ ln -s ../Grammar.cpp '$(1)'/src/3rdparty/webkit/JavaScriptCore/generated/debug/
+
+ # Fix case of filename
+ $(SED) 's/QWidget\.h/qwidget.h/g;' -i '$(1)'/src/3rdparty/webkit/WebCore/plugins/win/PluginViewWin.cpp
+
+ # Configure Qt for MinGW target
+ cd '$(1)' && ./configure \
+ -opensource \
+ -confirm-license \
+ -xplatform win32-g++ \
+ -host-arch i386 \
+ -little-endian \
+ -exceptions \
+ -static \
+ -prefix '$(PREFIX)/$(TARGET)' \
+ -prefix-install \
+ -bindir '$(1)'/bindirsink \
+ -plugin-sql-odbc \
+ -plugin-sql-psql \
+ -plugin-sql-sqlite \
+ -plugin-sql-mysql \
+ -script \
+ -webkit \
+ -phonon \
+ -no-phonon-backend \
+ -accessibility \
+ -no-reduce-exports \
+ -no-rpath \
+ -make libs \
+ -nomake demos \
+ -nomake docs \
+ -nomake examples \
+ -continue
+
+ $(MAKE) -C '$(1)' -j '$(JOBS)'
+ $(TARGET)-ranlib '$(1)'/lib/*.a
+ $(MAKE) -C '$(1)' install
+
+ # install native tools manually
+ $(INSTALL) -m755 '$(1)'.native/bin/{moc,rcc,uic} '$(PREFIX)/$(TARGET)/bin/'
+ $(INSTALL) -m755 '$(1)'.native/bin/qmake '$(PREFIX)/bin/$(TARGET)-qmake'
+endef