I am creating three new entities for the TDE help files. The entities will be stored in the sources tree in tdelibs/kdoctools/customization/entities/general.entities.
These new entities will contain the document version, release date, and copyright years.
The past practice with all KDE3 help files was to use hard-coded, static text strings. I want to change the fixed text to entities so they can be dynamic and always match the TDE release information.
Conceptually, I tested these new entities by hard-coding them into general.entities and compiling a couple of modified docbook sources to use those entities. Works as planned. :)
The next step is to modify the cmake build process to update the general.entities file when the tdelibs package is built.
The macro or script, whichever is correct terminology for cmake, needs to work like this:
* Extract the release version variable TDE_VERSION_STRING from tdelibs/tdecore/tdeversion.h.
* Read the file date stamp of tdeversion.h (for GIT sources this will change regularly, for tarballs this will remain fixed)
* Create a copyright year string in the form of "2010-$CURRENT_YEAR"
* Update the text strings between the quotation marks in general.entities:
<!ENTITY tde-release-version "R14.0.0 [DEVELOPMENT]">
<!ENTITY tde-release-date "March 8, 2012">
<!ENTITY tde-copyright-date "2010-2012">
* Continue with the build process.
I think I can do something like that in a shell script but I am unfamiliar with how to do the same in cmake.
I don't mind doing the grunt work and testing, but I appreciate guidance to do this.
Thanks!
Darrell
What is the latest tqt status?
I received the following build failure in tdebase:
/dev/shm/tdebase.build/kicker/kicker/core/kmenubase.ui.h:7: error: 't_xdisplay' was not declared in this scope
This particular run was against Qt3.
Darrell
<snip>
>> Yes! I'll pick an obvious example, KHTML. I would like to replace the
broken KHTML engine with Webkit using Qt4. Problem is, I can't link a
Qt4
>> library into a TDE library or program due to symbol conflicts. Even if
you trick the compiler and linker, the program will crash at runtime
because the C++ runtime will not know which symbols (Qt3 or Qt4) to use
when function names and static members have the same name.
> But that is what the linker does. Isn't it? Looks at symbolic names and
puts addresses instead. Therefore you shouldn't have name
> conflicts at runtime. The crash you may encounter is because the linker
chosen wrong symbols to link together in one algorithm. But this have
obvious solution. Put the code you want to link with Qt4 in separate
module and link only with Qt4. I still don't understand how is renaming
better solves this. Could you please refer exact source file and
function?
Actually the linker creates a reference to a "mangled" symbol--see
http://en.wikipedia.org/wiki/Name_mangling#Name_mangling_in_C.2B.2B
Let's take a simple example, qWarning. This becomes _Z8qWarningPKcz in
libqt-mt.so.3.3.8 (nm -D /usr/lib/libqt-mt.so | grep qWarning), and
_Z8qWarningPKcz in /usr/lib/libQtCore.so (nm -D /usr/lib/libQtCore.so |
grep qWarning). If my program references Z8qWarningPKcz, which library
will the symbol resolver choose at runtime? They are not binary
compatible with each other, and when the symbol resolver chooses the wrong
one at runtime (which it will do quite often) the entire program will
crash.
<snip>
> I suppose this could be done in more easy way without renaming.
Not really, see above. :-)
And if you want to work on a "pure" KDE 3.5.10 fork you have that right;
just be aware that you will hit a dead end far before TDE will. ;-)
Tim
Darrell, all,
Ran into another issue with tdegraphics that I can't solve by a dependency review:
[ 31%] Building CXX object libkscan/CMakeFiles/kscan-shared.dir/imgscaninfo.cpp.o
Linking CXX shared library libkscan.so
/usr/bin/ld: cannot find
-lsane-Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu-L/usr/lib
collect2: ld returned 1 exit status
make[2]: *** [libkscan/libkscan.so.1.0.0] Error 1
make[1]: *** [libkscan/CMakeFiles/kscan-shared.dir/all] Error 2
make: *** [all] Error 2
Is this a CMake issue? Linker error? What to look for?
--
David C. Rankin, J.D.,P.E.
I'm working on bug report 892. Most of this work involves changing XDG categories (X-KDE-Whatever -> X-TDE-Whatever), which will help further distinguish Trinity from KDE3 and KDE4 and reduce potential conflicts. The work is going well but I have run into a challenge.
When I rebuild tdelibs and tdebase to install desktop files to $PREFIX/share/applications/trinity rather than $PREFIX/share/applications/kde, a few things start breaking.
Some keyboard shortcuts stop, but I can recover that by deleting the user's khotkeys config file and starting afresh. That problem might be related or not, or might just be cruft from its KDE3 days when I migrated profiles.
The real problem is noticeable when I open Konqueror and select the Settings menu option. Most of the setting modules do not appear. The only modules that appear are the "native" ones: Behavior, Appearance, Previews & Meta-Data, and Performance.
The associated desktop files built and installed to $PREFIX/share/applications/trinity just fine.
I can solve the problem by creating a sym link from $PREFIX/share/applications/kde to $PREFIX/share/applications/trinity and restarting the session.
I tried a new profile but that did not solve the problem either. Only the sym link, or building to $PREFIX/share/applications/kde, avoids the problem.
I haven't tested with other packages because at this point I only need tdelibs and tdebase for testing.
At this point I'm concluding that something in the code is hard-coded to look for $PREFIX/share/applications/kde. I can't find anything obvious or explicit. I've looked hard and am stumped.
I would appreciate any help in this challenge. :)
Thanks!
Darrell
Tim, All,
I'm working forward in the build order after building tdebase, but I'm not
sure what should be building and what shouldn't?? The build order I'm trying
to follow is:
"dependencies/$useqt" OK
'dependencies/tqtinterface' OK
'dependencies/arts' OK
'dependencies/dbus-tqt' OK
'dependencies/dbus-1-tqt' OK
'dependencies/tqca-tls' OK
'dependencies/libart-lgpl' OK
'dependencies/avahi-tqt' FAILED
'dependencies/libcaldav' OK
'dependencies/libcarddav' OK
'tdelibs' OK
'tdebase' OK
'applications/abakus, ..??'
'tdebindings'
'tdeaccessibility'
'tdeutils'
'tdemultimedia'
'tdenetwork'
'tdeadmin'
'tdeartwork'
'tdegames'
'tdetoys'
'tdeedu'
'tdegraphics'
'tdevelop'
'tdeaddons'
'tdepim'
'tdewebdev'
'tdesdk'
What after tdebase should be ready to build? Also why is everything turned
OFF ("Build all" OFF) in the tdegraphics, tdenetwork, etc.. CMakeLists.txt files?
--
David C. Rankin, J.D.,P.E.
It sounds like you have your own server for your repository, so this
doesn't apply directly to Trinity Desktop. But the vulnerability
probably applies to your personal GIT server as well--which means it
could be hacked if this is not fixed.
-----------------
GitHub hacked, millions of projects at risk of being modified or deleted
http://www.extremetech.com/computing/120981-github-hacked-millions-of-proje…
Keith
Tim, all,
I am working on build scripts that will individually pull or update the source
by pulling code from the git tree. To make this more efficient for building
individual modules (and reduce unneeded bandwidth), it is recommended to use the
git clone form:
git clone --depth 1 http://scm.trinitydesktop.org/scm/git/whatever
But http://scm.trinitydesktop.org/scm/git/ refuses to allow '--depth 1' to be
used in the git clone. Anybody know why? The error received is:
Cloning into 'libart-lgpl'...
error: RPC failed; result=22, HTTP code = 500
fatal: The remote end hung up unexpectedly
It works fine without the --depth limitation. What say the 'git' masters?
--
David C. Rankin, J.D.,P.E.
Tim, all,
I've run into more link problems in tdegraphics. This time I am fairly certain
it is a gcc >= 4.6.2 problem. The error is:
/usr/bin/ld: CMakeFiles/ksnapshot.dir/windowgrabber.cpp.o: undefined reference
to symbol 'XShapeQueryExtension'
/usr/bin/ld: note: 'XShapeQueryExtension' is defined in DSO
/usr/lib/libXext.so.6 so try adding it to the linker command line
This means I need to add '-lXext' to the LDADD lines for ksnapshot. But where
in the CMake chain does this get added. I tried patching the makefile, but cmake
ignores the patch, so it needs to go in a CMakeList file somewhere, but is that
in tdegraphics or tdegraphics/ksnapshot? The changes needed are:
-ksnapshot_LDADD = $(LIB_TDEPRINT)
+ksnapshot_LDADD = $(LIB_TDEPRINT) -lXext
The full error follows. Do we need to open bugs on the gcc linking issues when
found?
Full Error:
[ 64%] Building CXX object ksnapshot/CMakeFiles/ksnapshot.dir/ksnapshotwidget.cpp.o
cd /build/src/build/ksnapshot && /usr/bin/c++ -DHAVE_CONFIG_H
-DKSNAPVERSION=\"0.7\" -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector
--param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -DQT_NO_ASCII_CAST
-DQT_CLEAN_NAMESPACE -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION
-DQT_THREAD_SUPPORT -D_REENTRANT -include tqt.h -I/build/src/build/ksnapshot
-I/build/src/tdegraphics/ksnapshot -I/build/src/build -I/opt/trinity/include
-I/opt/tqt3/include -I/opt/trinity/include/tqt -o
CMakeFiles/ksnapshot.dir/ksnapshotwidget.cpp.o -c
/build/src/build/ksnapshot/ksnapshotwidget.cpp
Linking CXX executable ksnapshot
cd /build/src/build/ksnapshot && /usr/bin/cmake -E cmake_link_script
CMakeFiles/ksnapshot.dir/link.txt --verbose=1
/usr/bin/c++ -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector
--param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -DQT_NO_ASCII_CAST
-DQT_CLEAN_NAMESPACE -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION
-DQT_THREAD_SUPPORT -D_REENTRANT -include tqt.h
-Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu
CMakeFiles/ksnapshot.dir/ksnapshotiface_skel.cpp.o
CMakeFiles/ksnapshot.dir/main.cpp.o CMakeFiles/ksnapshot.dir/ksnapshot.cpp.o
CMakeFiles/ksnapshot.dir/regiongrabber.cpp.o
CMakeFiles/ksnapshot.dir/windowgrabber.cpp.o
CMakeFiles/ksnapshot.dir/ksnapshotwidget.cpp.o -o ksnapshot -rdynamic
-L/opt/trinity/lib -L/opt/tqt3/lib /opt/trinity/lib/libtdeprint.so.4.2.0
/opt/trinity/lib/libkio.so.4.2.0 /opt/trinity/lib/libtdeui.so.4.2.0 -lfreetype
-lfontconfig /opt/trinity/lib/libtdesu.so.4.2.0 -lutil
/opt/trinity/lib/libkwalletclient.so.1.0.1 /opt/trinity/lib/libtdecore.so.4.2.0
/opt/trinity/lib/libDCOP.so.4.2.0 /opt/trinity/lib/libtdefx.so.4.2.0 -ltqt
-ltqt-mt -lXrender -lX11 -lz -lidn -lXcomposite -lICE -lSM
-Wl,-rpath,/opt/trinity/lib:/opt/tqt3/lib:
/usr/bin/ld: CMakeFiles/ksnapshot.dir/windowgrabber.cpp.o: undefined reference
to symbol 'XShapeQueryExtension'
/usr/bin/ld: note: 'XShapeQueryExtension' is defined in DSO
/usr/lib/libXext.so.6 so try adding it to the linker command line
/usr/lib/libXext.so.6: could not read symbols: Invalid operation
collect2: ld returned 1 exit status
m
--
David C. Rankin, J.D.,P.E.
Will someone tell me or put the link to the description of why someone
would need to rename QT API?
I know that for programmer this is a disaster!!! This will strangle
the development!