Hi,
I saw a built error on klayout-0.22 source compile.
Here is my environment.
1) OS: CentOS 5.3 64bit (SW development system)
2) Qt: qt4.8.0 (commercial)
3) Built: Source compile
4) Found errors:
====
In file included from /opt/klayout-0.22/src/rba.cc:117:
/usr/lib64/ruby/1.8/x86_64-linux/node.h:398: warning: comma at end of enumerator list
/opt/klayout-0.22/src/rba.cc: In function 'VALUE rba::rb_funcall2_checked(VALUE, ID, int, VALUE*)':
/opt/klayout-0.22/src/rba.cc:427: error: 'T_ZOMBIE' was not declared in this scope
gmake[1]: *** [rba.o] Error 1
gmake[1]: Leaving directory `/opt/klayout-0.22/build.linux-64-gcc-release/main'
gmake: *** [all] Error 1
===
As klayout-0.21.19 can built without errors, klayout-0.22 source may have a problems or lack of required library/tools is missing. # I added static ruby library.
I use klayout-0.21.19 still.
Regards,
-Kenji Morohashi-
Comments
Hi Matthias,
I also have some klayout v0.22 build issue, both case could compile klayout v0.21.19 without problems.
Case1:
OS: CentOS 6.2 64bit
Qt: 4.6.2-20
Case2:
OS: MDK 9.2 64bit
Qt: 4.4.3-1
Best Regards,
chhung
Hallo both of you,
Please download the tarkit once again - I have applied two minor changes.
The T_ZOMBIE problem is because the rba.cc file has trouble compiling with Ruby 1.8. Frankly I was not aware I have to support Ruby 1.8 still. I have fixed the build problem and on first glance it still runs with Ruby 1.8, but nevertheless I'd suggest to switch to Ruby 1.9 which is better tested by myself.
You can do so by installing the appropriate packages (i.e. ruby1.9.2 and ruby1.9.2-dev). Please check if the "ruby" executable gives a 1.9 version, i.e.
Regarding the second issue ("Case2" by chhung): the build was broken for Qt <4.6. The latest tarkit contains a fix for this issue as well.
I hope that helps.
Best regards,
Matthias
Hi Matthias,
With the new tarkit, the T_ZOMBIE and QtGui problems were fixed, however new issue happened.
OS: MDK 9.2 64bit
Qt: 4.4.3-1
Ruby: 1.9.3p194 (2012-04-20 revision 35410) or 1.8.7 (2011-02-18 patchlevel 334)
This problem didn't happen on CentOS 6.2 with Ruby 1.8.7 (2011-06-30 patchlevel 352),
so I have no idea it's a compiler issue or others.
Best Regards,
chhung
Hi chhung,
I think that is a compiler issue. Which gcc version are you using? I'd say it's a pretty old one. I have tested myself with 4.3.2, 4.4.3 and 4.7.1 which I think is a fair cross section of the recent ones.
You may be able to solve that by using the following patch in line 1254 of rba.cc:
Instead of
use that line:
The template keyword will tell the compiler that "morph" is a template member and requires a template parameter.
Please give me feedback if that works. I'll include the patch in the source then.
Best regards,
Matthias
Hi Matthias,
I tried the patch in line 1254 of rba.cc, and it fixed the compiler issue, thank you so much.
Currently our gcc version is v4.0.1, although it's really old but we are not able to upgrade it now.
Finally we success compiled the binary code ok with the combination:
gcc: v4.0.1
qt: 4.4.3
ruby: 1.9.3p194 or 1.8.7p334
Best Regards,
chhung
Hi chhung,
thank you for the feedback. I will add the patch to the source.
Best regards,
Matthias
I too am having problems building 0.22.1. I am on MacOSX 10.6.8 with
gcc 4.2.1, ruby 1.8.7, qt 4.8.0. The source has your patch included, but I still get this error:
In file included from /Volumes/Raptor/klayout-0.22.1/src/rba.cc:117:
/usr/lib/ruby/1.8/universal-darwin10.0/node.h:398: error: comma at end of enumerator list
Any ideas on what could be wrong? 0.21.19 compiled fine. Thanks,
Keith
Looking in this file /usr/lib/ruby/1.8/<EITHER x86_64-linux OR i686-linux>/node.h, I would expect your compiler is complaining correctly: the comma after THREAD_KILLED shouldn't be there (see below). However, compiling worked correctly for me. Possible there is a difference in what gcc accepts? (I used gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5)
)
enum rb_thread_status {
THREAD_TO_KILL,
THREAD_RUNNABLE,
THREAD_STOPPED,
THREAD_KILLED,
};
Looking at the latest code of ruby1.9, this enumeration is moved to ./ruby/vm_core.h, see here:
http://www.ruby-lang.org/en/community/ruby-core/
Or download it with subversion:
svn co http://svn.ruby-lang.org/repos/ruby/trunk ruby
And the comma is removed:
enum rb_thread_status {
THREAD_TO_KILL,
THREAD_RUNNABLE,
THREAD_STOPPED,
THREAD_STOPPED_FOREVER,
THREAD_KILLED
};
I assume you can easily remove it, and start compiling again.
Regards,
Peter
I downloaded klayout-0.22.4 and building with qt 4.7.4.
I encounter same errors as Kenji-san first post above.
I am on Centos, and I just need to install ruby-1.8.7.352-7.el6_2.x86_64.rpm
Then it complained about no ruby.h, so I install
ruby-devel-1.8.7.352-7.el6_2.x86_64.rpm
Then it complained again no ruby static .a library
So I install ruby-static-1.8.7.352-7.el6_2.x86_64.rpm
Bingo, now it's compiled and can run from bin/klayout.
cheers!
I'm using QT 4.7.1 (open source), which built successfully.
I'm using the pre-built ruby1.9.1-p430 suggested on the klayout web page
(http://178.77.72.242/downloads/ruby1.9.1-p430.zip)
I've got these environment variables set:
RUBY=C:\Users\myuid\src\ruby1.9.1-p430\1.9.1-p430\x86
QTDIR=C:\Qt\4.7.1
I'm using the VS solution provided in the source download and then trying to build the "klayout" project.
Here's the build output through the first error:
1>------ Build started: Project: klayout, Configuration: Release Win32 ------
1>Build started 4/29/2013 5:35:05 PM.
1>InitializeBuildStatus:
1> Touching "Release\klayout.unsuccessfulbuild".
1>CustomBuild:
1> All outputs are up-to-date.
1>CompileQtUI:
1>Skipping target "CompileQtUI" because all output files are up-to-date with respect to the input files.
1>CompileQtQRC:
1>Skipping target "CompileQtQRC" because all output files are up-to-date with respect to the input files.
1>ClCompile:
1> moc_gsiDeclQSslSocket_EventAdaptor.cpp
1>c:\users\dmiller\src\klayout-0.22.7\src\gsiDeclQSslSocket_Enums.h(149): error C2653: 'QSslSocket' : is not a class or namespace name
Anyone know if this is because I'm trying to use the open-source version of QT?
Hallo,
apparently there is no SSL support compiled into your Qt installation. I can't recall exactly, but it came for free on my installation. Maybe I had installed openSSL already.
If you need a quick workaround you can remove or disable the gsiDeclQSsl*.cc source files. There is no dependency on these files - they just contribute Ruby bindings through registration of method handlers.
Matthias
Removing those files did fix that problem.
Now I have another--any suggestions?
1>------ Build started: Project: klayout, Configuration: Release Win32 ------
1>Build started 5/1/2013 8:05:17 AM.
1>InitializeBuildStatus:
1> Touching "Release\klayout.unsuccessfulbuild".
1>CustomBuild:
1> All outputs are up-to-date.
1>CompileQtUI:
1>Skipping target "CompileQtUI" because all output files are up-to-date with respect to the input files.
1>CompileQtQRC:
1>Skipping target "CompileQtQRC" because all output files are up-to-date with respect to the input files.
1>ClCompile:
1> gsiDeclQFontMetrics.cc
1>gsiDeclQFontMetrics.cc(292): error C2668: 'QFontMetrics::boundingRect' : ambiguous call to overloaded function
1> c:\qt\4.7.1\include\qtgui\../../src/gui/text/qfontmetrics.h(123): could be 'QRect QFontMetrics::boundingRect(int,int,int,int,int,const QString &,int,int,int *) const'
1> c:\qt\4.7.1\include\qtgui\../../src/gui/text/qfontmetrics.h(101): or 'QRect QFontMetrics::boundingRect(int,int,int,int,int,const QString &,int,int *) const'
1> while trying to match the argument list '(int, int, int, int, int, const QString, int)'
Hi,
Please try to remove the "QT3_SUPPORT" defines from the project. They are not required and apparently they create conflicts in your built of the Qt libraries. I shall remove them in the next minor release.
If this define is set, the Qt headers offers more methods which cause this ambiguity issue.
Regards,
Matthias
I have a built error on klayout-0.22,
I use Qt 4.8.4 (open source) on visual studio express 2010
and I have this problem who stuck me since two days :
fatal error C1083: Unable to open file include : 'QtWidgets/QAction' : No such file or directory
If someone have a solution, i will be very thankful!
Hi Bertrand,
That is quite unusual. There is no "QtWidgets/QAction" included somewhere in KLayout's source code. Does VC++ tell which compilation unit this problem occurs in?
BTW: I am using VS 2010 express myself but with a somewhat older Qt version. Maybe 4.8.4 requires some other #define switches.
Regards,
Matthias
I tried with Qt 4.7.3 and i had the same issues.
please find below pages on which I experienced issues :
> rdbMarkerBrowser.cc
1>c:\users\labo\desktop\klayout\klayout-r1897\src\generated\markerbrowserdialog.h(13): fatal error C1083: Impossible d'ouvrir le fichier include : 'QtWidgets/QAction' : No such file or directory
1> rdb.cc
1> rbaRuntimeErrorForm.cc
1>c:\users\labo\desktop\klayout\klayout-r1897\src\generated\runtimeerrorform.h(13): fatal error C1083: Impossible d'ouvrir le fichier include : 'QtWidgets/QAction' : No such file or directory
1> layTipDialog.cc
1>c:\users\labo\desktop\klayout\klayout-r1897\src\generated\tipdialog.h(13): fatal error C1083: Impossible d'ouvrir le fichier include : 'QtWidgets/QAction' : No such file or directory
1> layTechnologySelector.cc
1> layTechnology.cc
1> layTechSetupDialog.cc
1>c:\users\labo\desktop\klayout\klayout-r1897\src\generated\techsetupdialog.h(13): fatal error C1083: Impossible d'ouvrir le fichier include : 'QtWidgets/QAction' : No such file or directory
1> laySettingsForm.cc
1>c:\users\labo\desktop\klayout\klayout-r1897\src\generated\settingsform.h(13): fatal error C1083: Impossible d'ouvrir le fichier include : 'QtWidgets/QAction' : No such file or directory
Hi Bertrand,
Your problems indicate there is an issue with UIC (the user interface compiler of Qt). Apparently it generates output which won't compile. Since UIC is called by VC++ according to the custom rule definitions I assume there is something wrong with your Qt integration in VC++. When I started with VS 2010, I had to do the integration myself. I think you installed some VisualStudio plugin which appears to be available now.
I strongly assume that your UIC comes from Qt5, not from Qt4. Both are not compatible apparently. If so, which plugin did you install? Did it come from Qt4?
Regards,
Matthias
thanks for your help.
I tried several plugin QT :
qt-windows-opensource-4.8.4 for visual studio 2010
qt-windows-opensource-5.0.2 for visual studio 2010
and qt windows opensource 4.7.4 source code (build with "configure", "nmake" with the VS2010 shell)
I had the same issue with QT 4.7.4 and 4.8.4("QtWidgets/QAction" are missing), I don't understand why.
I work on a computer without internet connection. Maybe some updates are missing?
Regards,
Bertrand
Hi Bertand,
I guess the Qt 5 plugin was overwriting the path to uic.exe. Because of that, the uic is no generating code which is compatible with Qt 4. Maybe it helps removing the Qt 5 plugin an reinstalling the Qt 4 plugin. I don't think this is related to some internet connection. It's just a matter of where Visual Studio takes the uic.exe from.
I was not using the plugin myself - when I was setting up the Qt environment there was no plugin and I had to do it manually by setting up the proper custom build rules for Visual Studio.
Regards,
Matthias
I have issues with laywidgets.cc when I trying to build 0.22.8 (VS2010), any suggestions ?
*************************************
src\laywidgets.cc(422): error C2440: 'initialisation' : cannot convert from 'std::_Tree_iterator<_Mytree>' en 'std::_Tree_const_iterator<_Mytree>'
1> with
1> [
1> _Mytree=std::_Tree_val<std::_Tmap_traits<std::pair<db::LayerProperties,int>,std::string,lay::LPIPairCompareOp,std::allocator<std::pair<const std::pair<db::LayerProperties,int>,std::string>>,false>>
1> ]
1> and
1> [
1> _Mytree=std::_Tree_val<std::_Tmap_traits<std::pair<db::LayerProperties,int>,std::string,std::less<std::pair<db::LayerProperties,int>>,std::allocator<std::pair<const std::pair<db::LayerProperties,int>,std::string>>,false>>
1> ]
1> No constructor could take the source type, or constructor overload resolution was ambiguous
*************************************
klayout-0.22.8\src\laywidgets.cc(423): error C2678: '!=' binaire : no operator found which takes a lef-hand operand of type 'std::_Tree_const_iterator<_Mytree>' (or there is no acceptable conversion)
1> with
1> [
1> _Mytree=std::_Tree_val<std::_Tmap_traits<std::pair<db::LayerProperties,int>,std::string,std::less<std::pair<db::LayerProperties,int>>,std::allocator<std::pair<const std::pair<db::LayerProperties,int>,std::string>>,false>>
1> ]
*************************************
Thanks for you help.
Regards,
Bertrand
Hi Bertrand,
it should compile if you replace the line 422
by this one:
I am doing my builds with Visual Studio 2010 and the STLPort library which turned out to be much better in performance and memory footprint. With this library the compile error does not happen. I very much recommend using that library instead of the STL which comes with VC++. Please see the instructions in http://www.klayout.de/build.html - "Building KLayout for Windows 32 bit and 64 bit with Visual Studio". Please note that you'll have to use the STLPort and set the STLPORT environment variable to the installation path to build with STLPort.
Regards,
Matthias