Misplaced Pages

Mingw-w64

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.

Mingw-w64 is a free and open-source suite of development tools that generate Portable Executable (PE) binaries for Microsoft Windows . It was forked in 2005–2010 from MinGW ( Minimalist GNU for Windows ).

#925074

41-721: Mingw-w64 includes a port of the GNU Compiler Collection (GCC), GNU Binutils for Windows ( assembler , linker , archive manager ), a set of freely distributable Windows specific header files and static import libraries for the Windows API , a Windows-native version of the GNU Project 's GNU Debugger , and miscellaneous utilities. Mingw-w64 can be run natively on Microsoft Windows, cross-hosted on Linux (or other Unix), or "cross-native" on MSYS2 or Cygwin . Mingw-w64 can generate 32-bit and 64-bit executables for x86 under

82-456: A PC without the need for actual porting (instead relying on the common porting of individual component libraries ). Porting arcade games to home systems with inferior hardware was difficult. The ported version of Pac-Man for the Atari 2600 omitted many of the visual features of the original game to compensate for the lack of ROM space and the hardware struggled when multiple ghosts appeared on

123-405: A cheaper solution). The number of significantly different CPUs and operating systems used on the desktop today is much smaller than in the past. The dominance of the x86 architecture means that most desktop software is never ported to a different CPU. In that same market, the choice of operating systems has effectively been reduced to three: Microsoft Windows , macOS , and Linux . However, in

164-508: A full environment like Cygwin does, MSYS2 tasks itself with being a development and deployment platform. The main MSYS2 environment provides a package manager ( Pacman from Arch Linux ), a bash shell , and other Unix programs. It uses a runtime library msys-2.0.dll (~20MB) that is derived from the Cygwin library cygwin1.dll , and is updated regularly to keep track of the Cygwin development. It

205-399: A home console with the same specifications. This allowed arcade perfect games to be played at home. A "console port" is a game that was originally made for a console before an identical version is created which can be played on a personal computer . This term has been widely used by the gaming community. The process of porting a game from a console to a PC is often regarded negatively due to

246-447: A machine independent intermediate code in order to enhance portability of the compiler and minimize design efforts. The intermediate language defines a virtual machine that can execute all programs written in the intermediate language (a machine is defined by its language and vice versa). The intermediate code instructions are translated into equivalent machine code sequences by a code generator to create executable code . It

287-439: A policy was not always feasible; Bunten stated that "M.U.L.E. can't be done for an Apple", and that the non-Atari versions of The Seven Cities of Gold were inferior. Compute!'s Gazette wrote in 1986 that when porting from Atari to Commodore the original was usually superior. The latter's games' quality improved when developers began creating new software for it in late 1983, the magazine stated. In porting arcade games ,

328-447: Is portable when the cost of porting it to a new platform is significantly less than the cost of writing it from scratch. The lower the cost of porting software relative to its implementation cost, the more portable it is said to be. The term "port" is derived from the Latin portāre , meaning "to carry". When code is not compatible with a particular operating system or architecture ,

369-400: Is a low-level, hardware-dependent format. In contrast, an application programming interface (API) defines this access in source code , which is a relatively high-level, hardware-independent, often human-readable format. A common aspect of an ABI is the calling convention , which determines how data is provided as input to, or read as output from, computational routines. Examples of this are

410-443: Is also possible to skip the generation of machine code by actually implementing an interpreter or JIT for the virtual machine. The use of intermediate code enhances portability of the compiler, because only the machine dependent code (the interpreter or the code generator) of the compiler itself needs to be ported to the target machine. The remainder of the compiler can be imported as intermediate code and then further processed by

451-683: Is compatible with code generated by other such compilers, allowing developers to link libraries generated with one compiler with object code generated with another compiler. Developers writing their own assembly language code may also interface with assembly generated by a compliant compiler. EABIs are designed to optimize for performance within the limited resources of an embedded system. Therefore, EABIs omit most abstractions that are made between kernel and user code in complex operating systems. For example, dynamic linking may be avoided to allow smaller executables and faster loading, fixed register usage allows more compact stacks and kernel calls, and running

SECTION 10

#1732856011926

492-511: Is intended as a development environment, one that developers can manage (using pacman) and run their tools with. Features judged unnecessary for development are removed. As with Cygwin, MSYS2 supports path translation for non-MSYS2 software launched from it. For example one can use the command notepad++ /c/Users/John/file.txt to launch an editor that will open the file with the Windows path C:\Users\John\file.txt . MSYS2 and its bash environment

533-403: Is less complex and therefore easier to port than a code generator, because it is not able to do code optimizations due to its limited view of the program code (it only sees one instruction at a time, and users need a sequence to do optimization). Some interpreters are extremely easy to port, because they only make minimal assumptions about the instruction set of the underlying hardware. As a result,

574-410: Is the process of adapting software for the purpose of achieving some form of execution in a computing environment that is different from the one that a given program (meant for such execution) was originally designed for (e.g., different CPU , operating system, or third party library ). The term is also used when software/hardware is changed to make them usable in different environments. Software

615-672: Is used by Git and GNU Octave for their official Windows distribution. Most languages supported by GCC are supported on the Mingw-w64 port as well. These include C, C++ , Objective-C , Objective-C++, Fortran , and Ada . The GCC runtime libraries are used (libstdc++ for C++, libgfortran for Fortran, etc.). A packaging of LLVM 's clang to mingw-w64 is also provided by MSYS2. It supports ARM for Windows ( aarch64-w64-mingw32 and armv7-w64-mingw32 ). Binaries (executables or DLLs) generated with different C++ compilers (like Mingw-w64 GCC and Visual Studio) are in general not link compatible due to

656-511: The Atari VCS became the console's killer app despite its differences, while the later Pac-Man port was notorious for its deviations from the arcade version. Arcade-accurate games became more prevalent starting in the 1990s as home consoles caught up to the power of arcade systems. Notably, the Neo Geo system from SNK , which was introduced as a multi-game arcade system, would also be offered as

697-680: The GNU Compiler Collection , which provides consistent programming languages on different platforms, and Autotools , which automates the detection of minor variations in the environment and adapts the software accordingly before compilation. The compilers for some high-level programming languages (e.g. Eiffel , Esterel ) gain portability by outputting source code in another high level intermediate language (such as C ) for which compilers for many platforms are generally available. Two activities related to (but distinct from) porting are emulating and cross-compiling . Instead of translating directly into machine code , modern compilers translate to

738-579: The Unix world on Windows. It plays the same role the old MSYS did in MinGW. MSYS2 shares this goal of bringing Unix code to Windows machines with several other projects, most notably Cygwin and Windows Subsystem for Linux (WSL). WSL lets Linux ELF binaries run on Windows through a managed Virtual Machine . Cygwin provides a full POSIX environment (as a windows DLL ) in which applications, compiled as Windows EXEs, run as they would under Unix. Instead of providing

779-496: The embedded systems and mobile markets, portability remains a significant issue, with the ARM being a widely used alternative. International standards, such as those promulgated by the ISO , greatly facilitate porting by specifying details of the computing environment in a way that helps reduce differences between different standards-conforming platforms . Writing software that stays within

820-424: The x86 calling conventions . Adhering to an ABI (which may or may not be officially standardized) is usually the job of a compiler , operating system, or library author. However, an application programmer may have to deal with an ABI directly when writing a program in a mix of programming languages, or even compiling a program written in the same language with different compilers. Details covered by an ABI include

861-502: The Apple rewrites?" the audience shouted "No!" Garriott responded, "[otherwise] the Apple version will never get done. From a publisher's point of view that's not money wise". Others worked differently. Ozark Softscape , for example, wrote M.U.L.E. for the Atari first because it preferred to develop for the most advanced computers, removing or altering features as necessary during porting. Such

SECTION 20

#1732856011926

902-535: The Internet before execution can start on the target's Java virtual machine (JVM). Porting is also the term used when a video game designed to run on one platform, be it an arcade , video game console , or personal computer , is converted to run on a different platform, perhaps with some minor differences. From the beginning of video games through to the 1990s, "ports", at the time often known as "conversions", were often not true ports, but rather reworked versions of

943-448: The Mingw-w64 project maintains winpthreads, a wrapper library similar to pthreads-win32, with the main difference that it allows GCC to use it as a threads library resulting in functional C++11 thread libraries <thread> , <future> , and <mutex> . MSYS2 ("minimal system 2") is a software distribution and a development platform for Microsoft Windows , based on Mingw-w64 and Cygwin , that helps to deploy code from

984-494: The application in privileged mode allows direct access to custom hardware operation without the indirection of calling a device driver. The choice of EABI can affect performance. Widely used EABIs include PowerPC , Arm EABI and MIPS EABI. Specific software implementations like the C library may impose additional limitations to form more concrete ABIs; one example is the GNU OABI and EABI for ARM, both of which are subsets of

1025-602: The bounds specified by these standards represents a practical although nontrivial effort. Porting such a program between two standards-compliant platforms (such as POSIX.1 ) can be just a matter of loading the source code and recompiling it on the new platform, but practitioners often find that various minor corrections are required, due to subtle platform differences. Most standards suffer from "gray areas" where differences in interpretation of standards lead to small variations from platform to platform. There also exists an ever-increasing number of tools to facilitate porting, such as

1066-405: The code must be "carried" to the new system. The term is not generally applied to the process of adapting software to run with less memory on the same CPU and operating system. Software developers often claim that the software they write is portable , meaning that little effort is needed to adapt it to a new environment. The amount of effort actually needed depends on several factors, including

1107-458: The condition that it remains open source. It was first submitted to the original MinGW project, but refused under suspicion of using non-public or proprietary information. For many reasons, the lead developer and co-founder of the MinGW-w64 project, Kai Tietz, decided not to attempt further cooperation with MinGW. MinGW-w64 provides a more complete Win32 API implementation, including: Additionally,

1148-411: The extent to which the original environment (the source platform ) differs from the new environment (the target platform ), the experience of the original authors in knowing which programming language constructs and third party library calls are unlikely to be portable, and the amount of effort invested by the original authors in only using portable constructs (platform specific constructs often provide

1189-564: The following: A complete ABI, such as the Intel Binary Compatibility Standard (iBCS), allows a program from one operating system supporting that ABI to run without modifications on any other such system, provided that necessary shared libraries are present, and similar prerequisites are fulfilled. ABIs can also standardize details such as the C++ name mangling , exception propagation, and calling convention between compilers on

1230-409: The games due to the limitations of different systems. For example, the 1982 game The Hobbit , a text adventure augmented with graphic images, has significantly different graphic styles across the range of personal computers that its ports were developed for. However, many 21st century video games are developed using software (often in C++ ) that can output code for one or more consoles as well as for

1271-406: The higher levels of performance that computers generally have being underutilized, partially due to console hardware being fixed throughout their run (with games being developed for console specs), while PCs become more powerful as hardware evolves, but also due to ported games sometimes being poorly optimized for PCs, or lazily ported. While broadly similar, architectural differences may exist such as

Mingw-w64 - Misplaced Pages Continue

1312-408: The latter machines' sprites and other sophisticated features made porting from them to Apple "far more difficult, perhaps even impossible". Reviews complained of ports that suffered from "Apple conversionitis", retaining the Apple's "lousy sound and black-white-green-purple graphics"; after Garriott's statement, when Dan Bunten asked "Atari and Commodore people in the audience, are you happy with

1353-404: The ported code generator or interpreter, thus producing the compiler software or directly executing the intermediate code on the interpreter. The machine independent part can be developed and tested on another machine (the host machine ). This greatly reduces design efforts, because the machine independent part needs to be developed only once to create portable intermediate code. An interpreter

1394-446: The same platform, but do not require cross-platform compatibility. An embedded-application binary interface (EABI) specifies standard conventions for file formats , data types, register usage, stack frame organization, and function parameter passing of an embedded software program, for use with an embedded operating system . Compilers that support the EABI create object code that

1435-563: The screen creating a flickering effect. The poor performance of the Atari 2600 Pac-Man is cited by some scholars as a cause of the video game crash of 1983 . Many early ports suffered significant gameplay quality issues because computers greatly differed. Richard Garriott stated in 1984 at Origins Game Fair that Origin Systems developed video games for the Apple II first then ported them to Commodore 64 and Atari 8-bit computers , because

1476-420: The target names i686-w64-mingw32 and x86_64-w64-mingw32 . In 2005, Mingw-w64 was created by OneVision Software under cleanroom software engineering principles, since the original MinGW project was not prompt on updating its code base, including the inclusion of several key new APIs and also much needed 64-bit support. In 2008, OneVision then donated the code to Kai Tietz, one of its lead developers, under

1517-573: The target. According to the designers of the BCPL language, interpreted code (in the BCPL case) is more compact than machine code, typically by a factor of two to one. Interpreted code however runs about ten times slower than compiled code on the same machine. The designers of the Java programming language try to take advantage of the compactness of interpreted code, because a Java program may need to be transmitted over

1558-405: The terms "arcade perfect" or "arcade accurate" were often used to describe how closely the gameplay, graphics, and other assets on the ported version matched the arcade version. Many arcade ports in the early 1980s were far from arcade perfect as home consoles and computers lacked the sophisticated hardware in arcade games, but games could still approximate the gameplay. Notably, Space Invaders on

1599-436: The use of unified memory on a console. Application Binary Interface In computer software , an application binary interface ( ABI ) is an interface between two binary program modules. Often, one of these modules is a library or operating system facility, and the other is a program that is being run by a user. An ABI defines how data structures or computational routines are accessed in machine code , which

1640-460: The use of different ABIs and name mangling schemes caused by the differences in C++ runtimes. However, compiled C code is link compatible. Clang is an exception, as it mostly supports MSVC's C++ ABI on Windows. The binutils documentation has up-to-date information about its handling of various windows-specific formats and special tools for doing so. Porting In software engineering , porting

1681-402: The virtual machine is even simpler than the target CPU. Writing the compiler sources entirely in the programming language the compiler is supposed to translate, makes the following approach, better known as compiler bootstrapping , feasible on the target machine: The difficult part of coding the optimization routines is done using the high-level language instead of the assembly language of

Mingw-w64 - Misplaced Pages Continue

#925074