mirror of
https://github.com/notepad-plus-plus/notepad-plus-plus.git
synced 2025-07-26 07:15:21 +02:00
parent
a790822847
commit
0dd0a9586a
7
BUILD.md
7
BUILD.md
@ -55,8 +55,11 @@ MinGW-w64 can be downloaded [here](https://sourceforge.net/projects/mingw-w64/fi
|
|||||||
3. Run `mingw32-make`.
|
3. Run `mingw32-make`.
|
||||||
4. The 32-bit or 64-bit `notepad++.exe` will be generated either in `bin.i686` or in `bin.x86_64` directory respectively, depending on the target CPU of the compiler — look for the full path to the resulting binary at the end of the build process.
|
4. The 32-bit or 64-bit `notepad++.exe` will be generated either in `bin.i686` or in `bin.x86_64` directory respectively, depending on the target CPU of the compiler — look for the full path to the resulting binary at the end of the build process.
|
||||||
|
|
||||||
|
### Some additional information:
|
||||||
|
|
||||||
* The directory containing `notepad++.exe` will also contain everything needed for Notepad++ to start.
|
* The directory containing `notepad++.exe` will also contain everything needed for Notepad++ to start.
|
||||||
* To have a debug build just add `DEBUG=1` to the `mingw32-make` invocation above. The output directory then will be suffixed with `-debug`.
|
* To have a debug build just add `DEBUG=1` to the `mingw32-make` invocation above. The output directory then will be suffixed with `-debug`.
|
||||||
* To see commands being executed add `VERBOSE=1` to the same command.
|
* To see commands being executed add `VERBOSE=1` to the same command.
|
||||||
* When switching between compilers or between release/debug modes, `mingw32-make clean` must be executed first.
|
* When switching between compilers or between release/debug modes cleaning must be done first to delete previous temporary files. This can be done by invoking `mingw32-make clean` (the directory with `notepad++.exe` won't be affected) or `mingw32-make fullclean` (everything related to the build will be deleted, including the directory with `notepad++.exe`).
|
||||||
* If you are building the project outside of the `PowerEditor/gcc` directory, for example when using `-f` option, then the entire project path must not contain any spaces. Additionally, the path to `makefile` of this project should be listed as first.
|
* When a project is built outside of the `PowerEditor/gcc` directory, for example when using `-f` option, then the entire project path must not contain any spaces. Additionally, the path to `makefile` of this project should be listed as first.
|
||||||
|
* When a project is built through MinGW-w64 with multilib support, a specific target can be forced by passing `TARGET_CPU` variable with `x86_64` or `i686` as value.
|
||||||
|
@ -50,7 +50,7 @@ SUBMAKEFLAGS := -O --no-print-directory
|
|||||||
ifeq "$(filter-out 0,$(DEBUG))" ""
|
ifeq "$(filter-out 0,$(DEBUG))" ""
|
||||||
BUILD_TYPE := release
|
BUILD_TYPE := release
|
||||||
BUILD_SUFFIX :=
|
BUILD_SUFFIX :=
|
||||||
CXXFLAGS += -O2 -Os
|
CXXFLAGS += -Os
|
||||||
CPP_DEFINE += NDEBUG
|
CPP_DEFINE += NDEBUG
|
||||||
LDFLAGS += -s
|
LDFLAGS += -s
|
||||||
else
|
else
|
||||||
@ -81,12 +81,17 @@ ifeq "$(TARGET_CPU)" "i686"
|
|||||||
ifeq "$(wildcard $(WIN_DIR)/system32/SensApi.dll)" ""
|
ifeq "$(wildcard $(WIN_DIR)/system32/SensApi.dll)" ""
|
||||||
$(error $(TARGET_CPU) build requires "%windir%/system32/SensApi.dll" to be present)
|
$(error $(TARGET_CPU) build requires "%windir%/system32/SensApi.dll" to be present)
|
||||||
endif
|
endif
|
||||||
# detect explicit definition of TARGET_CPU via command line to force a 32-bit build
|
# detect explicit definition of TARGET_CPU via command line to force a 32-bit build for MinGW-w64 with support multilib
|
||||||
ifeq "$(origin TARGET_CPU)" "command line"
|
ifeq "$(origin TARGET_CPU)" "command line"
|
||||||
export CXX += -m32
|
export CXX += -m32
|
||||||
export LD += -m32
|
export LD += -m32
|
||||||
export RC += -Fpe-i386
|
export RC += -Fpe-i386
|
||||||
endif
|
endif
|
||||||
|
# detect explicit definition of TARGET_CPU via command line to force a 64-bit build for MinGW-w64 with support multilib
|
||||||
|
else ifneq "$(and $(findstring x86_64,$(TARGET_CPU)),$(findstring command line,$(origin TARGET_CPU)))" ""
|
||||||
|
export CXX += -m64
|
||||||
|
export LD += -m64
|
||||||
|
export RC += -Fpe-x86-64
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# define target and build directories and update dependent variables
|
# define target and build directories and update dependent variables
|
||||||
|
Loading…
x
Reference in New Issue
Block a user