Does gcc-arm-linux-gnueabi build for a 64 bit target? - gcc

The processor I'm building for is 64 bit ARM. Will this tool chain work?

64-bit ARM support in GCC is separate backend, called AARCH64. So your compiler normally must be called something like gcc-aarch64-linux-gnu-*.
Still, your question is strange, because, if you will rename 64-bit ARM compiler executable to gcc-arm-linux-gnueabi (you may do it, why not), then answer will be yes.

The answer is no.
The tool chain you are referencing is old, and works for 32bit architectures.
You need this (ubuntu):
sudo apt-get install gcc-aarch64-linux-gnu g++-aarch64-linux-gnu

Related

Error go build using gcc on windows

I'm working on hyperledger fabric sdk client on my computer which is running on Windows 10 64 bits but my problem is general with Go.
In order to do the go build command on my .go file, I had to install gcc. So I installed cygwin 64 bits for Windows.
In the bin repository, I had 3 differents .exe for gcc. I tried all of them :
gcc.exe : I have an error because this .exe is for windows 32 bits and go is 64 bits
x86_64-w64-mingw32-gcc.exe : I have an error, this .exe isn't able to find -lltdl
x86_64-pc-cygwin-gcc : This .exe isn't able to find -lmingwex and -lmingw32
The solution proposed on some subject was to install TDM-GCC-64, but when I do that, I have an error : ltdl.h not found
So if anyone have any idea in order to solve this issue, it will be great !
Thank you :)
PS : Sorry for my english
You're jumping to conclusions without thinking. Windows X64 has full support for 32-bit .exe, but of course you must avoid trying to mix 32-bit and 64-bit applications. You will need to look up how to install libtool or libltdl (.dll and .h) corresponding to whichever gcc version you end up choosing. It's unclear on the cygwin web page whether that is supported for cygwin64. Also, you may need to think about whether you want cygwin gcc and go or a mingw version.

How to compile libdp.dll as 64 bit architecture on windows

I'm trying to build libpd on windows https://github.com/libpd/libpd
The problem I'm having is that when I build with the given "mingw_build.bat" - the libpd.dll that is built is 32 bit architecture.
How can I build using MingW so my resulting DLL is 64 bit architecture?
afaict there is no ready-made solution for this.
here are some generic hints (haven't tried them):
you would need to install mingw64 (the mingw_build.bat seems to assume that you are using mingw32)
fix the paths in mingw_build.bat
additionally set the C-compiler to one that produces 64bit binaries:
CC=x86_64-w64-mingw32-gcc

How to Build/Update Cygwin GCC?

I'm new to Stack Overflow and Cygwin. My problem is that how do you build/update Cygwin's GCC? I see a very obsolete version of gcc from the Cygwin setup.exe. Yes, I am on windows. Windows 7 to be exact.
So, how can I build/update Cygwin's GCC? I'd rather use Cygwin than MinGW+MSYS because I like things all in one, rather than things all over the place.
Thanks. (A step by step would be appreciated as I do not know anything about building a program from source)
Also, what would I need from Cygwin to build/update Cygwin's gcc? Do I install the gcc from Cygwin first? Or do I just get the necessities from Cygwin and then build gcc using Cygwin and install gcc?
Sorry, but I do not excel at these types of subjects.
You can volunteer to help the maintainer, I guess. See Why is the Cygwin package of XYZ so out of date? in the Cygwin FAQ.

how to install cygwin and mingw under windows 7?

I want to use gcc ( and g++ ) under windows 7.
I download cygwin ( setup file: setup.exe )...
So, what is packages really needed?! It suggests to setup very many packages, but i think that for developing in C++ not all of these is really needed..
gcc4-g++ for Cygwin programs
mingw64-i686-gcc-g++ for 32-bit MinGW programs
mingw64-x86_64-gcc-g++ for 64-bit MinGW programs
Setup.exe will select their dependencies such as gcc-core or binutils for you.
You'll probably also want make, and don't forget to pick an editor. Other packages in my minimum install: cygutils, diffutils, util-linux, inetutils, openssh, mintty.
If you would like to use only gcc and g++, I'd receomend you MinGW Distro designed by Stephan T. Lavavej.
Here is a direct link: http://nuwen.net/mingw.html to the Distro's main page. It contains currently the most up to date gcc and boost (4.7.2 and 1.52.0 respectively in version 9.5). It also contains make, git and couple more of useful tools.
Installation is really simple, you need only to extract zip-archive.
So, if you need Cygwin only to use GCC, I'd recomment you this MinGW Distro instead of Cygwin.
Greetings,

Cygwin: How to actually use gcc-mingw

Since "gcc -mno-cygwin" does not work anymore, I was looking for a way to get a MinGW-targeted GCC running within my Cygwin environment. (Running a MSYS environment is not an option at this point.)
The Cygwin installer offers a package "gcc-mingw", which installs, among others:
lib/gcc/i686-pc-mingw32/3.4.4/cc1.exe
lib/gcc/i686-pc-mingw32/3.4.4/collect2.exe
lib/gcc/i686-pc-mingw32/3.4.4/crtbegin.o
lib/gcc/i686-pc-mingw32/3.4.4/crtend.o
What is absent is the "gcc" frontend. So, how do I actually invoke this compiler? I hopefully don't have to go through "cc1" manually, have I?
I googled, but couldn't find anything relevant on the subject...
As you already found, you can use gcc-3 with -mno-cygwin. The other possibility is to install the 32-bit and/or 64-bit toolchains from the MinGW-w64 project, which have been packaged for Cygwin very recently and hence are available through setup.exe now. Don't be put off by the rather confusing executable names: i686-w64-mingw32-gcc is the 32-bit compiler and x86_64-w64-mingw32-gcc is the 64-bit one.
Further searches revealed that the MinGW-targeted cross-compiler is not ready yet, and that one has to either use GCC v3 with -mno-cygwin, or install a cross-compiler manually (see link above)...
After installing the MingW g++ package for Cygwin (mingw64-x86_64-gcc-g++), I also struggled to figure out how to invoke it.
Thanks to this wiki, I found out the command was x86_64-w64-mingw32-g++. Then I did alias g++='x86_64-w64-mingw32-g++' and g++ started working as expected.
Cygwin homepage says that "Individual packages like bash, gcc, less, etc. are released independently of the DLL.".
Here you can find how to install gcc under cygwin, so you should also select gcc package during install not only gcc-mingw.

Resources