Hello,
I built my QT refering to http://developer.qt.nokia.com/wiki/Building_Qt_for_Embedded_Linux.
And then I made the jffs2 file refering to http://processors.wiki.ti.com/index.php/Put_JFFS2_Image_to_Flash.
I add the codes bellow
QMAKE_INCDIR = /opt/Tools/qt/tslib/lib/include
QMAKE_LIBDIR = /opt/Tools/qt/tslib/lib/lib #my tslib installed here
to qt/mkspecs/qws/linux-arm-gnueabi-g++/qmake.conf.
I developed a application using qt and put it into jffs2.And then put the jffs2 to the nand flash.But I can't use the touch screen when my application run. I am sure I have put the tslib in /opt/Tools/qt/tslib/lib/ on the target board.
My application Makefile here:
CC = /opt/Tools/arm-2009q1/bin/arm-none-linux-gnueabi-gcc
CXX = /opt/Tools/arm-2009q1/bin/arm-none-linux-gnueabi-g++
DEFINES = -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED
CFLAGS = -pipe -O2 -Wall -W -D_REENTRANT $(DEFINES)
CXXFLAGS = -pipe $(shell cat /root/dsplink_1_65_00_03/dsplink/gpp/export/BIN/Linux/OMAPL138/DEBUG/API_defines.txt) $(shell cat /root/dsplink_1_65_00_03/dsplink/gpp/export/BIN/Linux/OMAPL138/DEBUG/API_includes.txt) -O2 -Wall -W -D_REENTRANT $(DEFINES)
INCPATH = -I../../../mkspecs/qws/linux-arm-gnueabi-g++ -I. -I../../../include/QtCore -I../../../include/QtNetwork -I../../../include/QtGui -I../../../include -I. -Implist -I.moc/release-shared-emb-arm -I../../../tslib/lib/include
LINK = /opt/Tools/arm-2009q1/bin/arm-none-linux-gnueabi-g++
LFLAGS = -Wl,-rpath-link,/opt/Tools/qt/lib -Wl,-O1 -Wl,-rpath,/opt/Tools/qt/qt-embedded/lib -Wl,-rpath,/opt/Tools/qt/qt-embedded/lib
LIBS = $(SUBLIBS) -L/opt/Tools/qt/lib -L/opt/Tools/qt/tslib/lib/lib /root/dsplink_1_65_00_03/dsplink/gpp/export/BIN/Linux/OMAPL138/RELEASE/dsplink.lib -lQtGui -L/opt/Tools/qt/lib -L/opt/Tools/qt/tslib/lib/lib -lQtNetwork -lQtCore -lpthread
AR = /opt/Tools/arm-2009q1/bin/arm-none-linux-gnueabi-ar cqs
RANLIB =
QMAKE = /usr/bin/qmake
TAR = tar -cf
COMPRESS = gzip -9f
COPY = cp -f
SED = sed
COPY_FILE = $(COPY)
COPY_DIR = $(COPY) -r
STRIP = /opt/Tools/arm-2009q1/bin/arm-none-linux-gnueabi-strip
INSTALL_FILE = install -m 644 -p
INSTALL_DIR = $(COPY_DIR)
INSTALL_PROGRAM = install -m 755 -p
DEL_FILE = rm -f
SYMLINK = ln -f -s
DEL_DIR = rmdir
MOVE = mv -f
CHK_DIR_EXISTS= test -d
MKDIR = mkdir -p
####### Output directory
OBJECTS_DIR = .obj/release-shared-emb-arm/
####### Files
SOURCES = my.cpp \
mplist/mp_list.cpp \
mplist/mp_list_os.cpp
OBJECTS = .obj/release-shared-emb-arm/SPMMain.o \
.obj/release-shared-emb-arm/mp_list.o \
.obj/release-shared-emb-arm/mp_list_os.o
DIST = ../../../mkspecs/common/unix.conf \
../../../mkspecs/common/linux.conf \
../../../mkspecs/common/gcc-base.conf \
../../../mkspecs/common/gcc-base-unix.conf \
../../../mkspecs/common/g++-base.conf \
../../../mkspecs/common/g++-unix.conf \
../../../mkspecs/common/qws.conf \
../../../mkspecs/features/exclusive_builds.prf \
../../../mkspecs/features/default_pre.prf \
../../../.qmake.cache \
../../../mkspecs/qconfig.pri \
../../../mkspecs/modules/qt_webkit_version.pri \
../../../mkspecs/features/qt_functions.prf \
../../../mkspecs/features/qt_config.prf \
../../../mkspecs/features/release.prf \
../../../mkspecs/features/default_post.prf \
../../../mkspecs/features/unix/dylib.prf \
../../../mkspecs/features/dll.prf \
../../../mkspecs/features/shared.prf \
../../../mkspecs/features/warn_on.prf \
../../../mkspecs/features/qt.prf \
../../../mkspecs/features/unix/thread.prf \
../../../mkspecs/features/moc.prf \
../../../mkspecs/features/resources.prf \
../../../mkspecs/features/uic.prf \
../../../mkspecs/features/yacc.prf \
../../../mkspecs/features/lex.prf \
spmgpp.pro
QMAKE_TARGET = spmgpp
DESTDIR =
TARGET = spmgpp
first: all
####### Implicit rules
.SUFFIXES: .o .c .cpp .cc .cxx .C
.cpp.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cc.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cxx.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.C.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.c.o:
$(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
####### Build rules
all: Makefile $(TARGET)
$(TARGET): $(OBJECTS)
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
Makefile: spmgpp.pro ../../../.qmake.cache ../../../mkspecs/qws/linux-arm-gnueabi-g++/qmake.conf ../../../mkspecs/common/unix.conf \
../../../mkspecs/common/linux.conf \
../../../mkspecs/common/gcc-base.conf \
../../../mkspecs/common/gcc-base-unix.conf \
../../../mkspecs/common/g++-base.conf \
../../../mkspecs/common/g++-unix.conf \
../../../mkspecs/common/qws.conf \
../../../mkspecs/features/exclusive_builds.prf \
../../../mkspecs/features/default_pre.prf \
../../../.qmake.cache \
../../../mkspecs/qconfig.pri \
../../../mkspecs/modules/qt_webkit_version.pri \
../../../mkspecs/features/qt_functions.prf \
../../../mkspecs/features/qt_config.prf \
../../../mkspecs/features/release.prf \
../../../mkspecs/features/default_post.prf \
../../../mkspecs/features/unix/dylib.prf \
../../../mkspecs/features/dll.prf \
../../../mkspecs/features/shared.prf \
../../../mkspecs/features/warn_on.prf \
../../../mkspecs/features/qt.prf \
../../../mkspecs/features/unix/thread.prf \
../../../mkspecs/features/moc.prf \
../../../mkspecs/features/resources.prf \
../../../mkspecs/features/uic.prf \
../../../mkspecs/features/yacc.prf \
../../../mkspecs/features/lex.prf \
/opt/Tools/qt/lib/libQtGui.prl \
/opt/Tools/qt/lib/libQtNetwork.prl \
/opt/Tools/qt/lib/libQtCore.prl
$(QMAKE) -unix -o Makefile spmgpp.pro
../../../mkspecs/common/unix.conf:
../../../mkspecs/common/linux.conf:
../../../mkspecs/common/gcc-base.conf:
../../../mkspecs/common/gcc-base-unix.conf:
../../../mkspecs/common/g++-base.conf:
../../../mkspecs/common/g++-unix.conf:
../../../mkspecs/common/qws.conf:
../../../mkspecs/features/exclusive_builds.prf:
../../../mkspecs/features/default_pre.prf:
../../../.qmake.cache:
../../../mkspecs/qconfig.pri:
../../../mkspecs/modules/qt_webkit_version.pri:
../../../mkspecs/features/qt_functions.prf:
../../../mkspecs/features/qt_config.prf:
../../../mkspecs/features/release.prf:
../../../mkspecs/features/default_post.prf:
../../../mkspecs/features/unix/dylib.prf:
../../../mkspecs/features/dll.prf:
../../../mkspecs/features/shared.prf:
../../../mkspecs/features/warn_on.prf:
../../../mkspecs/features/qt.prf:
../../../mkspecs/features/unix/thread.prf:
../../../mkspecs/features/moc.prf:
../../../mkspecs/features/resources.prf:
../../../mkspecs/features/uic.prf:
../../../mkspecs/features/yacc.prf:
../../../mkspecs/features/lex.prf:
/opt/Tools/qt/lib/libQtGui.prl:
/opt/Tools/qt/lib/libQtNetwork.prl:
/opt/Tools/qt/lib/libQtCore.prl:
qmake: FORCE
@$(QMAKE) -unix -o Makefile spmgpp.pro
dist:
@$(CHK_DIR_EXISTS) .obj/release-shared-emb-arm/spmgpp1.0.0 || $(MKDIR) .obj/release-shared-emb-arm/spmgpp1.0.0
$(COPY_FILE) --parents $(SOURCES) $(DIST) .obj/release-shared-emb-arm/spmgpp1.0.0/ && $(COPY_FILE) --parents mplist/mp_list.h mplist/mp_list_os.h .obj/release-shared-emb-arm/spmgpp1.0.0/ && $(COPY_FILE) --parents SPMMain.cpp mplist/mp_list.cpp mplist/mp_list_os.cpp .obj/release-shared-emb-arm/spmgpp1.0.0/ && (cd `dirname .obj/release-shared-emb-arm/spmgpp1.0.0` && $(TAR) spmgpp1.0.0.tar spmgpp1.0.0 && $(COMPRESS) spmgpp1.0.0.tar) && $(MOVE) `dirname .obj/release-shared-emb-arm/spmgpp1.0.0`/spmgpp1.0.0.tar.gz . && $(DEL_FILE) -r .obj/release-shared-emb-arm/spmgpp1.0.0
clean:compiler_clean
-$(DEL_FILE) $(OBJECTS)
-$(DEL_FILE) *~ core *.core
####### Sub-libraries
distclean: clean
-$(DEL_FILE) $(TARGET)
-$(DEL_FILE) Makefile
check: first
mocclean: compiler_moc_header_clean compiler_moc_source_clean
mocables: compiler_moc_header_make_all compiler_moc_source_make_all
compiler_moc_header_make_all:
compiler_moc_header_clean:
compiler_rcc_make_all:
compiler_rcc_clean:
compiler_image_collection_make_all: .uic/release-shared-emb-arm/qmake_image_collection.cpp
compiler_image_collection_clean:
-$(DEL_FILE) .uic/release-shared-emb-arm/qmake_image_collection.cpp
compiler_moc_source_make_all:
compiler_moc_source_clean:
compiler_uic_make_all:
compiler_uic_clean:
compiler_yacc_decl_make_all:
compiler_yacc_decl_clean:
compiler_yacc_impl_make_all:
compiler_yacc_impl_clean:
compiler_lex_make_all:
compiler_lex_clean:
compiler_clean:
####### Compile
.obj/release-shared-emb-arm/SPMMain.o: SPMMain.cpp ../../../include/QtGui/QApplication \
../../../include/QtGui/qapplication.h \
../../../src/gui/kernel/qapplication.h \
../../../include/QtCore/qcoreapplication.h \
../../../src/corelib/kernel/qcoreapplication.h \
../../../include/QtCore/qobject.h \
../../../src/corelib/kernel/qobject.h \
../../../include/QtCore/qobjectdefs.h \
../../../src/corelib/kernel/qobjectdefs.h \
../../../include/QtCore/qnamespace.h \
../../../src/corelib/global/qnamespace.h \
../../../include/QtCore/qglobal.h \
../../../src/corelib/global/qglobal.h \
../../../include/QtCore/qconfig.h \
../../../src/corelib/global/qconfig.h \
../../../include/QtCore/qfeatures.h \
../../../src/corelib/global/qfeatures.h \
../../../include/QtCore/qstring.h \
../../../src/corelib/tools/qstring.h \
../../../include/QtCore/qchar.h \
../../../src/corelib/tools/qchar.h \
../../../include/QtCore/qbytearray.h \
../../../src/corelib/tools/qbytearray.h \
../../../include/QtCore/qatomic.h \
../../../src/corelib/thread/qatomic.h \
../../../include/QtCore/qbasicatomic.h \
../../../src/corelib/thread/qbasicatomic.h \
../../../include/QtCore/qatomic_bootstrap.h \
../../../src/corelib/arch/qatomic_bootstrap.h \
../../../include/QtCore/qatomic_arch.h \
../../../src/corelib/arch/qatomic_arch.h \
../../../include/QtCore/qatomic_integrity.h \
../../../src/corelib/arch/qatomic_integrity.h \
../../../include/QtCore/qatomic_vxworks.h \
../../../src/corelib/arch/qatomic_vxworks.h \
../../../include/QtCore/qatomic_powerpc.h \
../../../src/corelib/arch/qatomic_powerpc.h \
../../../include/QtCore/qatomic_alpha.h \
../../../src/corelib/arch/qatomic_alpha.h \
../../../include/QtCore/qatomic_arm.h \
../../../src/corelib/arch/qatomic_arm.h \
../../../include/QtCore/qatomic_armv7.h \
../../../src/corelib/arch/qatomic_armv7.h \
../../../include/QtCore/qatomic_armv6.h \
../../../src/corelib/arch/qatomic_armv6.h \
../../../include/QtCore/qatomic_armv5.h \
../../../src/corelib/arch/qatomic_armv5.h \
../../../include/QtCore/qatomic_avr32.h \
../../../src/corelib/arch/qatomic_avr32.h \
../../../include/QtCore/qatomic_bfin.h \
../../../src/corelib/arch/qatomic_bfin.h \
../../../include/QtCore/qatomic_generic.h \
../../../src/corelib/arch/qatomic_generic.h \
../../../include/QtCore/qatomic_i386.h \
../../../src/corelib/arch/qatomic_i386.h \
../../../include/QtCore/qatomic_ia64.h \
../../../src/corelib/arch/qatomic_ia64.h \
../../../include/QtCore/qatomic_macosx.h \
../../../src/corelib/arch/qatomic_macosx.h \
../../../include/QtCore/qatomic_x86_64.h \
../../../src/corelib/arch/qatomic_x86_64.h \
../../../include/QtCore/qatomic_mips.h \
../../../src/corelib/arch/qatomic_mips.h \
../../../include/QtCore/qatomic_parisc.h \
../../../src/corelib/arch/qatomic_parisc.h \
../../../include/QtCore/qatomic_s390.h \
../../../src/corelib/arch/qatomic_s390.h \
../../../include/QtCore/qatomic_sparc.h \
../../../src/corelib/arch/qatomic_sparc.h \
../../../include/QtCore/qatomic_windows.h \
../../../src/corelib/arch/qatomic_windows.h \
../../../include/QtCore/qatomic_windowsce.h \
../../../src/corelib/arch/qatomic_windowsce.h \
../../../include/QtCore/qatomic_symbian.h \
../../../src/corelib/arch/qatomic_symbian.h \
../../../include/QtCore/qatomic_sh.h \
../../../src/corelib/arch/qatomic_sh.h \
../../../include/QtCore/qatomic_sh4a.h \
../../../src/corelib/arch/qatomic_sh4a.h \
../../../include/Qt3Support/q3cstring.h \
../../../src/qt3support/tools/q3cstring.h \
../../../include/QtCore/qstringbuilder.h \
../../../src/corelib/tools/qstringbuilder.h \
../../../include/QtCore/qmap.h \
../../../src/corelib/tools/qmap.h \
../../../include/QtCore/qiterator.h \
../../../src/corelib/tools/qiterator.h \
../../../include/QtCore/qlist.h \
../../../src/corelib/tools/qlist.h \
../../../include/QtCore/qalgorithms.h \
../../../src/corelib/tools/qalgorithms.h \
../../../include/QtCore/qcoreevent.h \
../../../src/corelib/kernel/qcoreevent.h \
../../../include/QtCore/qscopedpointer.h \
../../../src/corelib/tools/qscopedpointer.h \
../../../include/QtCore/qeventloop.h \
../../../src/corelib/kernel/qeventloop.h \
../../../include/QtCore/qstringlist.h \
../../../src/corelib/tools/qstringlist.h \
../../../include/QtCore/qdatastream.h \
../../../src/corelib/io/qdatastream.h \
../../../include/QtCore/qiodevice.h \
../../../src/corelib/io/qiodevice.h \
../../../include/QtCore/qregexp.h \
../../../src/corelib/tools/qregexp.h \
../../../include/QtCore/qstringmatcher.h \
../../../src/corelib/tools/qstringmatcher.h \
../../../include/Qt3Support/q3valuelist.h \
../../../src/qt3support/tools/q3valuelist.h \
../../../include/QtCore/qlinkedlist.h \
../../../src/corelib/tools/qlinkedlist.h \
../../../include/QtGui/qwindowdefs.h \
../../../src/gui/kernel/qwindowdefs.h \
../../../include/QtGui/qmacdefines_mac.h \
../../../src/gui/kernel/qmacdefines_mac.h \
../../../include/QtGui/qwindowdefs_win.h \
../../../src/gui/kernel/qwindowdefs_win.h \
../../../include/QtCore/qpoint.h \
../../../src/corelib/tools/qpoint.h \
../../../include/QtCore/qsize.h \
../../../src/corelib/tools/qsize.h \
../../../include/QtGui/qcursor.h \
../../../src/gui/kernel/qcursor.h \
../../../include/QtGui/qdesktopwidget.h \
../../../src/gui/kernel/qdesktopwidget.h \
../../../include/QtGui/qwidget.h \
../../../src/gui/kernel/qwidget.h \
../../../include/QtCore/qmargins.h \
../../../src/corelib/tools/qmargins.h \
../../../include/QtGui/qpaintdevice.h \
../../../src/gui/painting/qpaintdevice.h \
../../../include/QtCore/qrect.h \
../../../src/corelib/tools/qrect.h \
../../../include/QtGui/qpalette.h \
../../../src/gui/kernel/qpalette.h \
../../../include/QtGui/qcolor.h \
../../../src/gui/painting/qcolor.h \
../../../include/QtGui/qrgb.h \
../../../src/gui/painting/qrgb.h \
../../../include/QtGui/qbrush.h \
../../../src/gui/painting/qbrush.h \
../../../include/QtCore/qpair.h \
../../../src/corelib/tools/qpair.h \
../../../include/QtCore/qvector.h \
../../../src/corelib/tools/qvector.h \
../../../include/QtCore/QPointF \
../../../include/QtCore/QPoint \
../../../include/QtGui/qmatrix.h \
../../../src/gui/painting/qmatrix.h \
../../../include/QtGui/qpolygon.h \
../../../src/gui/painting/qpolygon.h \
../../../include/QtGui/qregion.h \
../../../src/gui/painting/qregion.h \
../../../include/QtCore/qline.h \
../../../src/corelib/tools/qline.h \
../../../include/QtGui/qwmatrix.h \
../../../src/gui/painting/qwmatrix.h \
../../../include/QtGui/qtransform.h \
../../../src/gui/painting/qtransform.h \
../../../include/QtGui/qpainterpath.h \
../../../src/gui/painting/qpainterpath.h \
../../../include/QtGui/qimage.h \
../../../src/gui/image/qimage.h \
../../../include/QtGui/qpixmap.h \
../../../src/gui/image/qpixmap.h \
../../../include/QtCore/qsharedpointer.h \
../../../src/corelib/tools/qsharedpointer.h \
../../../include/QtCore/qshareddata.h \
../../../src/corelib/tools/qshareddata.h \
../../../include/QtCore/qsharedpointer_impl.h \
../../../src/corelib/tools/qsharedpointer_impl.h \
../../../include/QtGui/qfont.h \
../../../src/gui/text/qfont.h \
../../../include/QtGui/qfontmetrics.h \
../../../src/gui/text/qfontmetrics.h \
../../../include/QtGui/qfontinfo.h \
../../../src/gui/text/qfontinfo.h \
../../../include/QtGui/qsizepolicy.h \
../../../src/gui/kernel/qsizepolicy.h \
../../../include/QtGui/qkeysequence.h \
../../../src/gui/kernel/qkeysequence.h \
../../../include/QtGui/qplatformwindowformat_qpa.h \
../../../src/gui/kernel/qplatformwindowformat_qpa.h \
../../../include/QtGui/QPlatformWindow \
../../../include/QtGui/qplatformwindow_qpa.h \
../../../src/gui/kernel/qplatformwindow_qpa.h \
../../../include/QtGui/qevent.h \
../../../src/gui/kernel/qevent.h \
../../../include/QtGui/qmime.h \
../../../src/gui/kernel/qmime.h \
../../../include/QtCore/qmimedata.h \
../../../src/corelib/kernel/qmimedata.h \
../../../include/QtCore/qvariant.h \
../../../src/corelib/kernel/qvariant.h \
../../../include/QtCore/qmetatype.h \
../../../src/corelib/kernel/qmetatype.h \
../../../include/QtCore/qhash.h \
../../../src/corelib/tools/qhash.h \
../../../include/QtGui/qdrag.h \
../../../src/gui/kernel/qdrag.h \
../../../include/QtCore/qset.h \
../../../src/corelib/tools/qset.h \
../../../include/QtCore/qfile.h \
../../../src/corelib/io/qfile.h \
../../../include/QtGui/qtransportauth_qws.h \
../../../src/gui/embedded/qtransportauth_qws.h \
../../../include/QtCore/qbuffer.h \
../../../src/corelib/io/qbuffer.h \
../../../include/QtCore/qpointer.h \
../../../src/corelib/kernel/qpointer.h \
../../../include/QtGui/QPushButton \
../../../include/QtGui/qpushbutton.h \
../../../src/gui/widgets/qpushbutton.h \
../../../include/QtGui/qabstractbutton.h \
../../../src/gui/widgets/qabstractbutton.h \
../../../include/QtGui/qicon.h \
../../../src/gui/image/qicon.h \
mplist/mp_list.h \
mplist/mp_list_os.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/release-shared-emb-arm/SPMMain.o SPMMain.cpp
.obj/release-shared-emb-arm/mp_list.o: mplist/mp_list.cpp mplist/mp_list.h \
mplist/mp_list_os.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/release-shared-emb-arm/mp_list.o mplist/mp_list.cpp
.obj/release-shared-emb-arm/mp_list_os.o: mplist/mp_list_os.cpp mplist/mp_list.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/release-shared-emb-arm/mp_list_os.o mplist/mp_list_os.cpp
####### Install
install: FORCE
uninstall: FORCE
FORCE:
Best regards,
yu.