Bitcoin Forum
May 07, 2024, 12:45:26 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 ... 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 [57] 58 59 60 »
  Print  
Author Topic: Building headless Bitcoin and Bitcoin-qt on Windows  (Read 419326 times)
mmortal03
Legendary
*
Offline Offline

Activity: 1762
Merit: 1010


View Profile
August 23, 2016, 01:12:56 AM
 #1121


I'm able to build Linux executables just fine using Bash for Windows but, I can't seem to figure out how to build executables that can run on Windows.

I'm not sure what those errors above mean but, I had a lot of trouble running any script until I realized the issue was related to extra CR (or LF) characters added by Windows to all these files that I obtained using Git for Windows.  To solve this, I deleted the project that I cloned using Windows and used Git on the Bash environment itself to obtain a fresh copy of the bitcoin 0.13 project.


Those errors are from trying to follow the following instructions: https://github.com/bitcoin/bitcoin/blob/master/doc/build-windows.md
If you see garbage posts (off-topic, trolling, spam, no point, etc.), use the "report to moderator" links. All reports are investigated, though you will rarely be contacted about your reports.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715042726
Hero Member
*
Offline Offline

Posts: 1715042726

View Profile Personal Message (Offline)

Ignore
1715042726
Reply with quote  #2

1715042726
Report to moderator
EpyxZ
Hero Member
*****
Offline Offline

Activity: 994
Merit: 500



View Profile
September 28, 2016, 05:29:06 PM
Last edit: September 29, 2016, 10:07:07 AM by EpyxZ
 #1122

Yeah, bash for windows didn't work for me.

To cross compile, you need to use the depends system.

Bash has worked for me to create the daemon but have not been able to build the qt as of yet. but each time i reset bash to try and fresh install qt i get different error for qt so seems to be more of a problem with bash for me atleast.

trying something different with bash

kenpat06
Newbie
*
Offline Offline

Activity: 19
Merit: 0


View Profile
September 29, 2016, 08:11:54 AM
 #1123

I figured out my confusion after some research

Apparently code block uses it's project files in lieu of make files, but there are ways to use make files when compiling in code blocks, go it.

My confusion was when I've compiled stuff using codeblocks I never needed a makefile, but now I see why. I just got my hands on VS12 so eventually I'll have to learn how to use that.

Apologize, I havn't done C++ in 10 years since college and back in those days I used a borland compiler on a unix server and never did anything that complex.

Right now I'm re-learning everything and getting a crash course in Programming, Cryptography and Bitcoin source code. Although I have learned a lot in a short period of time although this project will take awhile but my current goal is to successfully compile Litecoin so I can see how it's done, then understand the genesis block code which I conceptually am starting to get now it's just a matter of seeing how it translates in code.

(spent the weekend reading on the history and concept of proof of work, etc.)


Can you possibly list the courses you have taken and in what order, also if a course requires any prereq? could be helpful to new entrants like me and others.
T
Ken
person1030
Newbie
*
Offline Offline

Activity: 52
Merit: 0


View Profile
December 27, 2016, 11:28:15 PM
 #1124

Thought I would necro this thread incase someone is stuck.

If you're trying to build a previous version and are getting stuck with config errors,
try and replace bitcoin_qt.m4 with the newest bitcoin/src/m4/bitcoin_qt.m4.

# Using a fresh install Ubuntu 14.04 x64,
sudo apt-get update
sudo apt-get install -y build-essential libtool autotools-dev autoconf automake \
libqt5gui5 libqt5dbus5 qttools5-dev qttools5-dev-tools libprotobuf-dev \
libqt5core5a:i386 libqt5core5a pkg-config git \
g++-mingw-w64-i686 mingw-w64-i686-dev g++-mingw-w64-x86-64 mingw-w64-x86-64-dev curl
cd
git clone https://github.com/bitcoin/bitcoin.git
cd bitcoin/depends
make HOST=i686-w64-mingw32
#or 64 bit setup :  make HOST=x86_64-w64-mingw32
cd ..
./configure --prefix=`pwd`/depends/i686-w64-mingw32 --with-gui=qt5 --enable-tests=no
#or 64 bit setup :  ./configure --prefix=`pwd`/depends/x86_64-w64-mingw32 --with-gui=qt5 --enable-tests=no
make
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 06, 2017, 07:16:35 AM
Last edit: January 06, 2017, 07:50:21 AM by awais3344_1
 #1125

while compiling qteverywhere from page 42.

Code:
 -I"." -I"..\3rdparty\double-conversion" -I"debugger" -I"animations" -I"C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\include\QtNetwork'python' is not recognized as an internal or external command,
operable program or batch file.
" -I"C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\include\QtCore\5.3.2" -I"C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\include\QtCore\5.3.2\QtCore" -I"C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\include\QtCore" -I".moc\release" -I"C:\deps\openssl-1.0.1j\include" -I"C:\deps\icu\dist\include" -I"C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\mkspecs\win32-g++" -o .obj\release\YarrSyntaxChecker.o ..\3rdparty\masm\yarr\YarrSyntaxChecker.cpp
Makefile.Release:599: recipe for target 'RegExpJitTables.h' failed
mingw32-make[4]: *** [RegExpJitTables.h] Error 1
mingw32-make[4]: *** Waiting for unfinished jobs....
mingw32-make[4]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src/qml'
Makefile:34: recipe for target 'release' failed
mingw32-make[3]: *** [release] Error 2
mingw32-make[3]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src/qml'
Makefile:41: recipe for target 'sub-qml-make_first-ordered' failed
mingw32-make[2]: *** [sub-qml-make_first-ordered] Error 2
mingw32-make[2]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src'
Makefile:41: recipe for target 'sub-src-make_first' failed
mingw32-make[1]: *** [sub-src-make_first] Error 2
mingw32-make[1]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative'
makefile:215: recipe for target 'module-qtdeclarative-make_first' failed
mingw32-make: *** [module-qtdeclarative-make_first] Error 2

py output in cmd says
Code:
C:\Qt\qt-everywhere-opensource-src-5.3.2>py
Python 3.5.3rc1 (v3.5.3rc1:de530d7f21c0, Jan  2 2017, 06:41:25) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>

Edit: I think I am supposed to use python27. beause python 35 uses 'py' instead of 'python' to look for python. will report back what happens.

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 06, 2017, 08:20:50 AM
 #1126

so I continued to build right from there after adding python27 to environment.

i run the mingw32-make -j5

and it continues from there but I do not understand this new error. is this a problem in the qt_everywhere release?
 
Code:
./.obj\release\YarrInterpreter.o:YarrInterpreter.cpp:(.text+0x622): undefined reference to `JSC::Yarr::wordcharCreate()'
./.obj\release\YarrInterpreter.o:YarrInterpreter.cpp:(.text+0x693): undefined reference to `JSC::Yarr::newlineCreate()'
C:/MingW/bin/../lib/gcc/i686-w64-mingw32/4.9.2/../../../../i686-w64-mingw32/bin/ld.exe: ./.obj\release\YarrInterpreter.o: bad reloc address 0x12 in section `.text$_ZN3WTF15BumpPointerPool6createEj[__ZN3WTF15BumpPointerPool6createEj]'
collect2.exe: error: ld returned 1 exit status
Makefile.Release:534: recipe for target 'C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\lib\Qt5Qml.dll' failed
mingw32-make[4]: *** [C:\Qt\qt-everywhere-opensource-src-5.3.2\qtbase\lib\Qt5Qml.dll] Error 1
mingw32-make[4]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src/qml'
Makefile:34: recipe for target 'release' failed
mingw32-make[3]: *** [release] Error 2
mingw32-make[3]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src/qml'
Makefile:41: recipe for target 'sub-qml-make_first-ordered' failed
mingw32-make[2]: *** [sub-qml-make_first-ordered] Error 2
mingw32-make[2]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative/src'
Makefile:41: recipe for target 'sub-src-make_first' failed
mingw32-make[1]: *** [sub-src-make_first] Error 2
mingw32-make[1]: Leaving directory 'C:/Qt/qt-everywhere-opensource-src-5.3.2/qtdeclarative'
makefile:215: recipe for target 'module-qtdeclarative-make_first' failed
mingw32-make: *** [module-qtdeclarative-make_first] Error 2

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 06, 2017, 08:52:28 AM
Last edit: January 06, 2017, 12:06:33 PM by awais3344_1
 #1127

okay, so qt-everywhere-opensource-src-5.2.1 works.

but the compilation still says unknown module webkitwidgets

so how does one add this qt-everywhere to PATH?


Edit: I added C:\Qt\Qt5.3.2new\5.3\mingw482_32\bin to path environment. I am now only using qtcreator 5.3 instead of qt everywhere

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 10, 2017, 09:41:09 PM
 #1128

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
old c coder
Sr. Member
****
Offline Offline

Activity: 260
Merit: 250



View Profile WWW
January 10, 2017, 11:56:46 PM
 #1129

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


LTC: LUYiMVsrFQewUSPDasSKGzhyTPAkiTeSov BTC: 1DPvP6WoZzaNQ9Nxzd64hjYad1kyQzTTbx YAC: Y3ZggXDvnRJaRwtVGyGJwt6DMLN3EPQpQf 
The day is coming when a single carrot, freshly observed, will set off a revolution.  Paul Cezanne
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 11, 2017, 07:08:15 AM
 #1130

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
old c coder
Sr. Member
****
Offline Offline

Activity: 260
Merit: 250



View Profile WWW
January 11, 2017, 03:09:45 PM
 #1131

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.
Looking at http://www.qtcentre.org/threads/27729-statically-link-Qt-libraries-%28not-build-static-library%29 I tried the suggestions there and I still ended up with a dynamically linked bitcoin-qt.exe or *coin-qt.exe

If you look at message #1 in this forum it is not clear what Qt is created on one's system.  I did read, but can't find the link now, that one needs to build a set of libraries for Qt that are dynamic for the use of Qt creator and Qt designer (if you use them) and a set that is static for building one's applications.  I don't know if that is so, nor how one would keep the environment straight Huh Smiley

Ron


LTC: LUYiMVsrFQewUSPDasSKGzhyTPAkiTeSov BTC: 1DPvP6WoZzaNQ9Nxzd64hjYad1kyQzTTbx YAC: Y3ZggXDvnRJaRwtVGyGJwt6DMLN3EPQpQf 
The day is coming when a single carrot, freshly observed, will set off a revolution.  Paul Cezanne
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 13, 2017, 10:55:07 AM
 #1132

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.
Looking at http://www.qtcentre.org/threads/27729-statically-link-Qt-libraries-%28not-build-static-library%29 I tried the suggestions there and I still ended up with a dynamically linked bitcoin-qt.exe or *coin-qt.exe

If you look at message #1 in this forum it is not clear what Qt is created on one's system.  I did read, but can't find the link now, that one needs to build a set of libraries for Qt that are dynamic for the use of Qt creator and Qt designer (if you use them) and a set that is static for building one's applications.  I don't know if that is so, nor how one would keep the environment straight Huh Smiley

Ron

I still haven't figured this one out. And I stopped hacking at it for now. Did you find anything helpful?

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
dfox101
Hero Member
*****
Offline Offline

Activity: 551
Merit: 500



View Profile
January 14, 2017, 04:27:34 AM
 #1133

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.
Looking at http://www.qtcentre.org/threads/27729-statically-link-Qt-libraries-%28not-build-static-library%29 I tried the suggestions there and I still ended up with a dynamically linked bitcoin-qt.exe or *coin-qt.exe

If you look at message #1 in this forum it is not clear what Qt is created on one's system.  I did read, but can't find the link now, that one needs to build a set of libraries for Qt that are dynamic for the use of Qt creator and Qt designer (if you use them) and a set that is static for building one's applications.  I don't know if that is so, nor how one would keep the environment straight Huh Smiley

Ron

I still haven't figured this one out. And I stopped hacking at it for now. Did you find anything helpful?

I use this and it works fine

Quote
greaterThan(QT_MAJOR_VERSION, 4) {
    QT += widgets
    DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
}

if you have errors, post them here, so people can help you.
awais3344_1
Sr. Member
****
Offline Offline

Activity: 350
Merit: 250


View Profile
January 14, 2017, 06:57:02 AM
 #1134

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.
Looking at http://www.qtcentre.org/threads/27729-statically-link-Qt-libraries-%28not-build-static-library%29 I tried the suggestions there and I still ended up with a dynamically linked bitcoin-qt.exe or *coin-qt.exe

If you look at message #1 in this forum it is not clear what Qt is created on one's system.  I did read, but can't find the link now, that one needs to build a set of libraries for Qt that are dynamic for the use of Qt creator and Qt designer (if you use them) and a set that is static for building one's applications.  I don't know if that is so, nor how one would keep the environment straight Huh Smiley

Ron

I still haven't figured this one out. And I stopped hacking at it for now. Did you find anything helpful?

I use this and it works fine

Quote
greaterThan(QT_MAJOR_VERSION, 4) {
    QT += widgets
    DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
}

if you have errors, post them here, so people can help you.


I have that in my code. My qt version is 5.3. The app starts fine. When I open debug window and enter any word or whenever I close the wallet. it closes with generic "this application has requested the runtime to terminate in an unusual way"
I noticed the final qt file size is only 9.few mb which is low if qt would statically link libs.

                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
           ░▒█████████████████████▒░
         ▓███████████████████████████▓░
      ░███████████████▓░▒███████████████░
     ▓██████████▓▓▒░        ▒▒▓▓██████████
   ░███▓                               ▒███▒
  ░████               ▒▒▒               ████▒
 ░█████░           ░███████░            █████▒
 ██████░          ░██      ██▒          ██████
░██████░          ██       ██           ██████▒
▓██████           ██░ ░   ░██           ███████
▓██████         ████████████████        ███████
▓██████        █████████████████        ███████
░██████▒       ███████████████       ░██████▓
 ███████       █████████████████       ▓██████
 ░███████       ████████████████      ▓██████▒
  ▒███████▒       ░ ░     ░ ░       ░███████▒
   ░████████▒                     ▒████████▒
     ▓████████▓░               ░▓█████████
      ░██████████▓░          ▓██████████░
         ▓██████████▒     ▒██████████▓░
           ░▒██████████▒▓█████████▓░
                 ░▒▓▓▓▓▓▓▓▓▓▒▒░
old c coder
Sr. Member
****
Offline Offline

Activity: 260
Merit: 250



View Profile WWW
January 16, 2017, 06:38:17 PM
 #1135

How does one build qt 4.8 projects on qt 5?
I use the greaterThan(QT_MAJOR_VERSION, 4): QT += widgets and added -static but the compiled file throws runtime errors on opening or sometimes closing. Is there anything else to do?
I don't know about building a 4.8.x bitcoinQt on a Qt 5.x system?  But when I build 4.8.x on a 4.8.x (Windows 8.1) system, I found I got similar errors if I didn't delete all the .obj & other files in the build directory.  The make file isn't too bright about what needs to be compiled and what doesn't.

Ron


My build dir is already clean. I compiled a clean source. No luck so far. I think this runtime has to do with how qt is not statically linking libs. I pasted some dlls into the coins release folder but no dice.
Looking at http://www.qtcentre.org/threads/27729-statically-link-Qt-libraries-%28not-build-static-library%29 I tried the suggestions there and I still ended up with a dynamically linked bitcoin-qt.exe or *coin-qt.exe

If you look at message #1 in this forum it is not clear what Qt is created on one's system.  I did read, but can't find the link now, that one needs to build a set of libraries for Qt that are dynamic for the use of Qt creator and Qt designer (if you use them) and a set that is static for building one's applications.  I don't know if that is so, nor how one would keep the environment straight Huh Smiley

Ron

I still haven't figured this one out. And I stopped hacking at it for now. Did you find anything helpful?

I use this and it works fine

Quote
greaterThan(QT_MAJOR_VERSION, 4) {
    QT += widgets
    DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
}

if you have errors, post them here, so people can help you.


I have that in my code. My qt version is 5.3. The app starts fine. When I open debug window and enter any word or whenever I close the wallet. it closes with generic "this application has requested the runtime to terminate in an unusual way"
I noticed the final qt file size is only 9.few mb which is low if qt would statically link libs.
Hello,

How big is your Qt exe? ~7MB?  27MB?

I can't find the actual link, but here is a parallel discussion,
http://tdm-gcc.tdragon.net/quirks
which I think is apropos.  It seems that there are some exceptions being thrown due to the Qt linking perhaps?

I found similar errors going back to linking bitcoin-qt 0.8.1!  I was able to get rid of them and get a stable exe by removing the link arguments
 
Code:
	-static-libgcc \
-static-libstdc++ \
-static \
The test for me was using any command in the help->debug window->console, in addition to your actions.  But this is for Qt 4.8.4, not 5.x

Ron


LTC: LUYiMVsrFQewUSPDasSKGzhyTPAkiTeSov BTC: 1DPvP6WoZzaNQ9Nxzd64hjYad1kyQzTTbx YAC: Y3ZggXDvnRJaRwtVGyGJwt6DMLN3EPQpQf 
The day is coming when a single carrot, freshly observed, will set off a revolution.  Paul Cezanne
Varuna
Newbie
*
Offline Offline

Activity: 16
Merit: 0


View Profile
January 17, 2017, 09:47:24 AM
 #1136

Hi, I tried this instructions but:

1. after make HOST, I have to perform ./autogen.sh in order to get a configure file
2. the ./configure thing produces this error:

    checking for static Qt plugins: -lqwindows... no
    configure: error: Could not resolve: -lqwindows

What I'm supposed to do?

P.S. The line

    ./configure --prefix=`pwd`/depends/x86_64-w64-mingw32 --with-gui=qt5 --enable-tests=no

has to be corrected this way:

    ./configure --prefix=$PWD/depends/x86_64-w64-mingw32 --with-gui=qt5 --enable-tests=no



Thought I would necro this thread incase someone is stuck.

If you're trying to build a previous version and are getting stuck with config errors,
try and replace bitcoin_qt.m4 with the newest bitcoin/src/m4/bitcoin_qt.m4.

# Using a fresh install Ubuntu 14.04 x64,
sudo apt-get update
sudo apt-get install -y build-essential libtool autotools-dev autoconf automake \
libqt5gui5 libqt5dbus5 qttools5-dev qttools5-dev-tools libprotobuf-dev \
libqt5core5a:i386 libqt5core5a pkg-config git \
g++-mingw-w64-i686 mingw-w64-i686-dev g++-mingw-w64-x86-64 mingw-w64-x86-64-dev curl
cd
git clone https://github.com/bitcoin/bitcoin.git
cd bitcoin/depends
make HOST=i686-w64-mingw32
#or 64 bit setup :  make HOST=x86_64-w64-mingw32
cd ..
./configure --prefix=`pwd`/depends/i686-w64-mingw32 --with-gui=qt5 --enable-tests=no
#or 64 bit setup :  ./configure --prefix=`pwd`/depends/x86_64-w64-mingw32 --with-gui=qt5 --enable-tests=no
make
EpyxZ
Hero Member
*****
Offline Offline

Activity: 994
Merit: 500



View Profile
January 17, 2017, 02:11:57 PM
 #1137

Anyone try windows 10 bash with mxe compile? if not ill set up a vb and see if it works :p
Varuna
Newbie
*
Offline Offline

Activity: 16
Merit: 0


View Profile
January 17, 2017, 04:27:30 PM
Last edit: January 18, 2017, 02:12:36 PM by Varuna
 #1138

Anyone try windows 10 bash with mxe compile? if not ill set up a vb and see if it works :p


I get the same results whether I use a Linux VM or Windows 10 bash.

I think the problem is that the static libqwindows.a is not distributed with Qt. You get only the shared library qwindows.dll.

The platform plugin libraries are here:

C:\Qt\5.7\mingw53_32\plugins\platforms

I only have:

qminimal.dll
qminimald.dll
qwindows.dll
qwindowsd.dll

I am trying to follow the instructions for building a static Qt5.7 and I hope that also the missing libraries are built in the process.
Varuna
Newbie
*
Offline Offline

Activity: 16
Merit: 0


View Profile
January 18, 2017, 02:17:50 PM
 #1139

It works following the official guide:

    https://github.com/bitcoin/bitcoin/blob/master/doc/build-windows.md

But first you have to build a static version of Qt5.7 by following the guide (it takes some hours):

    http://dimitris.apeiro.gr/2015/06/24/build-a-static-qt5-for-windows-by-compiling/

And copy all the files from:

    C:\Qt\Qt5_static\plugins\platforms

To the bitcoin source folder:

    [whatever]\bitcoin-0.13.2\depends\x86_64-w64-mingw32\plugins\platforms

Desten
Sr. Member
****
Offline Offline

Activity: 357
Merit: 250


View Profile
January 26, 2017, 07:31:56 PM
 #1140

How made it possible with current mingw64/msys2 to compile bitcoin(core) or other wallets?
Are there any guides to do that? This manual is outdated at all :/
Pages: « 1 ... 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 [57] 58 59 60 »
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!