[xwGtk] What is the official command line to configure xwWidgets for compilation?
[xwGtk] What is the official command line to configure xwWidgets for compilation?
Hello,
I have installed the Codelite's wxWidgets version, and I have got mismatch ABI version with my compiled CodeBlocks version. So I have to download and compile wxWidgets myself.
Could anyone pass me the official ./configure command line for both gtk2 and gtk3.
Also, how to install the source code for debugging.
Thank you for your understanding.
I have installed the Codelite's wxWidgets version, and I have got mismatch ABI version with my compiled CodeBlocks version. So I have to download and compile wxWidgets myself.
Could anyone pass me the official ./configure command line for both gtk2 and gtk3.
Also, how to install the source code for debugging.
Thank you for your understanding.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Hi,
You might also have a mismatch between your CodeBlock's compiler and linker settings. Make sure they are both pointing to the same wxWidgets install.
If you do want/need to build your own wx, there is no 'official' configure line; you can build it however you like. However I strongly suggest that you do not 'install' it. Instead keep it 'local' and point to its wx-config. That way there is no chance of conflict between wx versions.
I suggest you build in a subdir of the wx source dir, so start with e.g.
mkdir buildgtk2 && cd buildgtk2
Then a basic configure line would be:
../configure --prefix=$(pwd)
followed by:
make -j
You do not need to 'make install'.
For gtk+3:
mkdir buildgtk3 && cd buildgtk3
../configure --with-gtk=3 --prefix=$(pwd) && make -j
In both your CodeBlocks compiler and linker settings you will call the wx version of your choice by using the full path to that wx-config. I do not know the correct syntax for CodeBlocks, but CodeLite would use:
$(shell /full/path/to/builtgtk2 --cxxflags)
and
$(shell /full/path/to/builtgtk2 --libs)
for the gtk+2 build.
For full information see your wxWidgets source's docs/gtk/install.txt file.
Regards,
David
Why? Of course different wx versions will have different ABI versions, but that will only cause a problem if you are trying to link e.g. 2 .o files that were built against different wx installs. So maybe all you need to do is to 'make clean' your program...got mismatch ABI version with my compiled CodeBlocks version. So I have to download and compile wxWidgets myself
You might also have a mismatch between your CodeBlock's compiler and linker settings. Make sure they are both pointing to the same wxWidgets install.
If you do want/need to build your own wx, there is no 'official' configure line; you can build it however you like. However I strongly suggest that you do not 'install' it. Instead keep it 'local' and point to its wx-config. That way there is no chance of conflict between wx versions.
I suggest you build in a subdir of the wx source dir, so start with e.g.
mkdir buildgtk2 && cd buildgtk2
Then a basic configure line would be:
../configure --prefix=$(pwd)
followed by:
make -j
You do not need to 'make install'.
For gtk+3:
mkdir buildgtk3 && cd buildgtk3
../configure --with-gtk=3 --prefix=$(pwd) && make -j
In both your CodeBlocks compiler and linker settings you will call the wx version of your choice by using the full path to that wx-config. I do not know the correct syntax for CodeBlocks, but CodeLite would use:
$(shell /full/path/to/builtgtk2 --cxxflags)
and
$(shell /full/path/to/builtgtk2 --libs)
for the gtk+2 build.
For full information see your wxWidgets source's docs/gtk/install.txt file.
Since wx3.0 all Linux builds are debug builds, so you do not need to do anything special.Also, how to install the source code for debugging.
Regards,
David
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
when I try to start codeblocks from the command line:
This is my gcc version:
Code: Select all
Fatal Error: Mismatch between the program and library build versions detected.
The library used 3.1.1 (wchar_t,compiler with C++ ABI 1002,wx containers,compatible with 3.0),
and your program used 3.1.1 (wchar_t,compiler with C++ ABI 1011,wx containers,compatible with 3.0).
Aborted (core dumped)
Code: Select all
gcc (Ubuntu 7.3.0-16ubuntu3) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Oh, you mean CodeBlocks itself. I thought you meant if you tried to build a program inside CodeBlocks.when I try to start codeblocks from the command line:
When you installed wxWidgets from the CodeLite site, did you uninstall your distro's official wxWidgets libs? If so, that might explain the problem. You should be able to have both installed at the same time. To avoid conflicts, install the distro's libwx* but not libwx*-dev.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Sure I meant CodeBlocks itself.
It is a fresh new installation of Linux Mint 19 x64 (No previous official wxWidgets libs were installed).
I will delete all libwx*-dev and see.
It is a fresh new installation of Linux Mint 19 x64 (No previous official wxWidgets libs were installed).
I will delete all libwx*-dev and see.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
No! You will need the correct libwx*-dev for building.I will delete all libwx*-dev and see.
Just make sure the official wxWidgets lib packages are there.
They must have been, or CodeBlocks would never have worked. They were probably installed as dependencies.(No previous official wxWidgets libs were installed)
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Sorry the same problem persists.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
That's surprising. Perhaps more information would help.
Where did your CodeBlocks come from? Did it used to work on your Mint 19? (If not, your problem is probably nothing to do with wx3.1.1)
What is the output of doing, in a terminal:
ldd /full/path/to/codeblocks | grep wx
Try uninstalling wx3.1.1. Does CodeBlocks now run? What is the ldd output now?
If you can think of any other relevant information, it would save us both a lot of time...
Where did your CodeBlocks come from? Did it used to work on your Mint 19? (If not, your problem is probably nothing to do with wx3.1.1)
What is the output of doing, in a terminal:
ldd /full/path/to/codeblocks | grep wx
Try uninstalling wx3.1.1. Does CodeBlocks now run? What is the ldd output now?
If you can think of any other relevant information, it would save us both a lot of time...
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Hello,DavidHart wrote:That's surprising. Perhaps more information would help.
Where did your CodeBlocks come from? Did it used to work on your Mint 19? (If not, your problem is probably nothing to do with wx3.1.1)
What is the output of doing, in a terminal:
ldd /full/path/to/codeblocks | grep wx
Try uninstalling wx3.1.1. Does CodeBlocks now run? What is the ldd output now?
If you can think of any other relevant information, it would save us both a lot of time...
I have finally managed to compile C::B under linux mint 19 x64.
The problem was in the Codelite's wxWidgets v3.1.1 binaries (indeed it was compiled with a gcc version which has a C++ ABI v1002 that is not compatible with C++ ABI v1011 of my compiler).
I had to compile wxWidgets myself so that C::B can link to it without any problems.
Thank you.
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
I'm glad you have it working, but I'm surprised you had a problem.
Which of the wxWidgets 3.1.1 binaries did you download? The one for ubuntu bionic was build with gcc 7.3.0, the same gcc version as your Mint 19. (ubuntu artful has 7.2.0)The problem was in the Codelite's wxWidgets v3.1.1 binaries (indeed it was compiled with a gcc version which has a C++ ABI v1002 that is not compatible with C++ ABI v1011 of my compiler).
Last edited by DavidHart on Thu Jul 19, 2018 6:29 pm, edited 1 time in total.
Reason: Corrected ubuntu version
Reason: Corrected ubuntu version
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
using this command line:Which of the wxWidgets 3.1.1 binaries did you download? The one for ubuntu bionic was build with gcc 7.3.0, the same gcc version as your Mint 19. (ubuntu bionic has 7.2.0)
Code: Select all
sudo apt-key adv --fetch-keys http://repos.codelite.org/CodeLite.asc
sudo apt-add-repository 'deb http://repos.codelite.org/wx3.0/ubuntu/ xenial universe'
sudo apt-add-repository 'deb http://repos.codelite.org/wx3.1/ubuntu/ xenial universe'
sudo apt-get update
sudo apt-get install \
libwxbase3.1-0-unofficial \
libwxbase3.1-dev \
libwxgtk3.1-0-unofficial \
libwxgtk3.1-dev \
wx3.1-headers \
wx-common \
libwxgtk-media3.1-0-unofficial \
libwxgtk-media3.1-dev \
libwxgtk-webview3.1-0-unofficial \
libwxgtk-webview3.1-dev \
libwxbase3.1-0-unofficial-dbg \
libwxgtk3.1-0-unofficial-dbg \
libwxgtk-webview3.1-0-unofficial-dbg \
libwxgtk-media3.1-0-unofficial-dbg \
wx3.1-i18n \
wx3.1-examples
Code: Select all
g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 7.3.0-16ubuntu3' --with-bugurl=file:///usr/share/doc/gcc-7/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --with-as=/usr/bin/x86_64-linux-gnu-as --with-ld=/usr/bin/x86_64-linux-gnu-ld --program-suffix=-7 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 7.3.0 (Ubuntu 7.3.0-16ubuntu3)
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
That explains your problem. You downloaded the version intended for ubuntu 16.04 (xenial) and Mint 18.sudo apt-add-repository 'deb http://repos.codelite.org/wx3.0/ubuntu/ xenial universe'
I think you would have found that:
Code: Select all
deb http://repos.codelite.org/wx3.0/ubuntu/ bionic universe
Re: [xwGtk] What is the official command line to configure xwWidgets for compilation?
Yes I completely forgot that I have made an OS upgrade.
and I have previously saved that wx installation command line into a text file. And I just used it directly without paying attention.
You can call me a dumb or whatever. I just have had enough.
and I have previously saved that wx installation command line into a text file. And I just used it directly without paying attention.
You can call me a dumb or whatever. I just have had enough.