From 122b58ad82f1a144226d262c87241ee035ed1aff Mon Sep 17 00:00:00 2001 From: Rod Smith Date: Tue, 12 Apr 2022 18:11:23 -0400 Subject: Introduction of unified (multi-OS) Makefile Forgot something! --- README | 44 +++++++++++++++++++++++++++----------------- 1 file changed, 27 insertions(+), 17 deletions(-) (limited to 'README') diff --git a/README b/README index 69775eb..157abb8 100644 --- a/README +++ b/README @@ -161,12 +161,12 @@ features of FixParts require elaboration: Installing ---------- -To compile GPT fdisk, you must have appropriate development tools -installed, most notably the GNU Compiler Collection (GCC) and its g++ -compiler for C++. I've also tested compilation with Clang, which seems to -work; however, I've not done extensive testing of the resulting binaries, -beyond checking a few basics. Under Windows, Microsoft Visual C++ 2008 can -be used instead. In addition, note these requirements: +To compile GPT fdisk, you must have appropriate development tools installed, +most notably the GNU Compiler Collection (GCC) and its g++ compiler for C++. +I've also tested compilation with Clang, which seems to work; however, I've +not done extensive testing of the resulting binaries, beyond checking a few +basics. See the README.Windows files for additional notes on compiling the +software for Windows. In addition, note these requirements: * On Linux, FreeBSD, macOS, and Solaris, libuuid must be installed. This is the standard for Linux and macOS, although you may need to install a @@ -214,17 +214,27 @@ be used instead. In addition, note these requirements: When all the necessary development tools and libraries are installed, you can uncompress the package and type "make" at the command prompt in the -resulting directory. (You must type "make -f Makefile.mac" on macOS, "make --f Makefile.freebsd" on FreeBSD, "make -f Makefile.solaris" on Solaris, or -"make -f Makefile.mingw" to compile using MinGW for Windows.) You may also -need to add header (include) directories or library directories by setting -the CXXFLAGS environment variable or by editing the Makefile. The result -should be program files called gdisk, cgdisk, sgdisk, and fixparts. Typing -"make gdisk", "make cgdisk", "make sgdisk", or "make fixparts" will compile -only the requested programs. You can use these programs in place or copy the -files to a suitable directory, such as /usr/local/sbin. You can copy the man -pages (gdisk.8, cgdisk.8, sgdisk.8, and fixparts.8) to /usr/local/man/man8 -to make them available. +resulting directory. (Beginning with version 1.0.9, GPT fdisk provides a +consolidated Makefile for all supported OSes. Earlier versions used +OS-specific Makefiles, such as Makefile.mac and Makefile.freebsd, which are +still provided, but are deprecated.) You must use GNU make (gmake on +FreeBSD) with this Makefile. You may also need to add header (include) +directories or library directories by setting the CXXFLAGS environment +variable or by editing the Makefile. The result should be program files +called gdisk, cgdisk, sgdisk, and fixparts (or variants with "32.exe" or +"64.exe" added for Windows binaries). Typing "make gdisk", "make cgdisk", +"make sgdisk", or "make fixparts" will compile only the requested programs. +You can use these programs in place or copy the files to a suitable +directory, such as /usr/local/sbin. You can copy the man pages (gdisk.8, +cgdisk.8, sgdisk.8, and fixparts.8) to /usr/local/man/man8 to make them +available. + +Cross-compiling is possible, but is not well-tested, except for compiling +Windows binaries on Linux. (See README.Windows for details.) To +cross-compile, specify the TARGET environment variable when launching make, +as in "TARGET=win64 make" to compile for 64-bit (x86-64, X64, AMD64) Windows +on a non-Windows platform. Supported TARGET values are linux, freebsd, +solaris, macos, win32, and win64. Caveats ------- -- cgit v1.2.1