annotate binary-dist-rules.mk @ 7207:9ed6500e56d3 default tip @

maint: Merge release to default.
author Markus Mützel <markus.muetzel@gmx.de>
date Fri, 17 May 2024 20:16:41 +0200
parents 47ac621e632f
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
1
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
2 ifeq ($(MXE_WINDOWS_BUILD),yes)
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
3 ifeq ($(ENABLE_WINDOWS_64),yes)
4694
98bcbdaf910b binary-dist-rules.mk: Fix dist file suffixes.
John W. Eaton <jwe@octave.org>
parents: 4686
diff changeset
4 ifeq ($(ENABLE_FORTRAN_INT64),yes)
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
5 OCTAVE_PLATFORM_SUFFIX := -w64-64
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
6 else
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
7 OCTAVE_PLATFORM_SUFFIX := -w64
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
8 endif
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
9 else
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
10 OCTAVE_PLATFORM_SUFFIX := -w32
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
11 endif
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
12 endif
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
13
4788
65dfbc5a5dbc binary-dist-rules.mk (OCTAVE_DIST_NAME): Use octave-$($(OCTAVE_TARGET)_VERSION)$(OCTAVE_PLATFORM_SUFFIX) for octave-release version.
John W. Eaton <jwe@octave.org>
parents: 4767
diff changeset
14 ifeq ($(OCTAVE_TARGET),release-octave)
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
15 OCTAVE_DIST_NAME := octave-$($(OCTAVE_TARGET)_VERSION)$(OCTAVE_PLATFORM_SUFFIX)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
16 else
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
17 OCTAVE_DIST_NAME := octave-$(DATE)$(OCTAVE_PLATFORM_SUFFIX)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
18 endif
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
19
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
20 OCTAVE_DIST_DIR := $(TOP_BUILD_DIR)/dist/$(OCTAVE_DIST_NAME)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
21
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
22 OCTAVE_NSI_FILE := $(TOP_BUILD_DIR)/dist/octave.nsi
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
23
4906
bcfecd611e1b * binary-dist-rules.mk: remove '/' from any addpath paths
John Donoghue
parents: 4807
diff changeset
24 OCTAVE_ADD_PATH := /
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
25 ifeq ($(MXE_WINDOWS_BUILD),yes)
3522
9bc3862c2091 update binary-dist rules for new way of building gcc
John W. Eaton <jwe@octave.org>
parents: 3517
diff changeset
26 TAR_H_OPTION := -h
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
27 WINDOWS_BINARY_DIST_DEPS := \
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
28 octave-launch \
5957
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
29 octave-launch-firsttime \
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
30 win7appid \
6582
9a909530773b Add opengl_switch
John Donoghue <john.donoghue@ieee.org>
parents: 5960
diff changeset
31 blas_switch \
9a909530773b Add opengl_switch
John Donoghue <john.donoghue@ieee.org>
parents: 5960
diff changeset
32 opengl_switch
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
33
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
34 ifeq ($(USE_MSYS2),yes)
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
35 WINDOWS_BINARY_DIST_DEPS += \
4795
f39017b331bf only download msys2 source packages if building dist target
John W. Eaton <jwe@octave.org>
parents: 4793
diff changeset
36 msys2 \
f39017b331bf only download msys2 source packages if building dist target
John W. Eaton <jwe@octave.org>
parents: 4793
diff changeset
37 msys2-sources
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
38
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
39 ifeq ($(ENABLE_WINDOWS_64),yes)
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
40 OCTAVE_ADD_PATH := /mingw64
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
41 else
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
42 OCTAVE_ADD_PATH := /mingw32
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
43 endif
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
44 else
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
45 WINDOWS_BINARY_DIST_DEPS += \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
46 msys-base \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
47 msys-base-sources
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
48 endif
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
49
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
50 ifeq ($(MXE_NATIVE_BUILD),no)
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
51 WINDOWS_BINARY_DIST_DEPS += \
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
52 native-binutils \
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
53 native-gcc \
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
54 npp
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
55 endif
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
56 endif
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
57
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
58 BINARY_DIST_DEPS := \
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
59 $(OCTAVE_TARGET) \
3471
6a97f4d1dedb installer: Add ref BLAS/OpenBLAS install option
John Donoghue <john.donoghue@ieee.org>
parents: 3468
diff changeset
60 blas-packages \
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
61 octave-forge-packages \
5742
b532d40c63d8 Add Octave package biosig version 2.2.1
Markus Mützel <markus.muetzel@gmx.de>
parents: 5650
diff changeset
62 octave-other-packages \
3958
ac3abcea55e8 Add --enable-devel-tools option to configure
John Donoghue <john.donoghue@ieee.org>
parents: 3862
diff changeset
63 devel-packages \
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
64 units \
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
65 transfig \
3435
9fcc72373e24 build stable-octave package by default
John W. Eaton <jwe@octave.org>
parents: 3433
diff changeset
66 $(WINDOWS_BINARY_DIST_DEPS)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
67
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
68 define delete-dist-directory
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
69 echo "deleting previous dist directory..."
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
70 rm -rf $(TOP_BUILD_DIR)/dist
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
71 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
72
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
73 define make-dist-directory
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
74 echo "creating dist directory..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
75 mkdir -p $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
76 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
77
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
78 define copy-dist-files
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
79 echo "copying files..."
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
80 echo " octave and dependencies..."
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
81 cd $(HOST_PREFIX) \
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
82 && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH) ; tar xpf - )
7106
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
83 if [ -f "$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/share/octave/site/m/startup/octaverc" ]; then \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
84 echo " octaverc file (appending to existing file)..."; \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
85 cat $(TOP_DIR)/octaverc >> $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/share/octave/site/m/startup/octaverc; \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
86 else \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
87 echo " octaverc file..."; \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
88 cp $(TOP_DIR)/octaverc $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/share/octave/site/m/startup/octaverc; \
47ac621e632f append our octaverc file to existing site rcfile
John W. Eaton <jwe@octave.org>
parents: 7105
diff changeset
89 fi
4078
e5e0b3f7244b Dont copy src directory if binary packages enabled
John Donoghue <john.donoghue@ieee.org>
parents: 4066
diff changeset
90 if [ $(ENABLE_BINARY_PACKAGES) = no ]; then \
e5e0b3f7244b Dont copy src directory if binary packages enabled
John Donoghue <john.donoghue@ieee.org>
parents: 4066
diff changeset
91 echo " build_packages.m..."; \
e5e0b3f7244b Dont copy src directory if binary packages enabled
John Donoghue <john.donoghue@ieee.org>
parents: 4066
diff changeset
92 cp $(TOP_DIR)/build_packages.m $(OCTAVE_DIST_DIR)/src; \
e5e0b3f7244b Dont copy src directory if binary packages enabled
John Donoghue <john.donoghue@ieee.org>
parents: 4066
diff changeset
93 fi
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
94 endef
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
95
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
96 ## FIXME: Maybe we should have a uniform way of dealing with the
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
97 ## creation of build-tree directories like this?
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
98 installer-files/.dirstamp:
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
99 @mkdir -p installer-files
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
100 @: > installer-files/.dirstamp
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
101
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
102 ifeq ($(MXE_WINDOWS_BUILD),yes)
5960
49b3f6c6d255 octave-launch: Don't use short path names when building default-octave.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5959
diff changeset
103
49b3f6c6d255 octave-launch: Don't use short path names when building default-octave.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5959
diff changeset
104 ifeq ($(OCTAVE_TARGET),default-octave)
49b3f6c6d255 octave-launch: Don't use short path names when building default-octave.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5959
diff changeset
105 OCTAVE_LAUNCH_NO_SHORT_CPPFLAGS := -DNO_SHORT_PATH_NAMES
49b3f6c6d255 octave-launch: Don't use short path names when building default-octave.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5959
diff changeset
106 endif
49b3f6c6d255 octave-launch: Don't use short path names when building default-octave.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5959
diff changeset
107
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
108 .PHONY: octave-launch
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
109 octave-launch: installer-files/octave-launch.exe
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
110
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
111 ## FIXME: We aren't using VPATH?
5959
bf9be5e7ab00 octave-launch: Add icons and version info.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5957
diff changeset
112 installer-files/octave-launch.exe: $(TOP_DIR)/installer-files/octave-launch.c installer-files/octave-launch.res | installer-files/.dirstamp
6837
6adeb47401d6 Add qt6 usage to mxe-octave
John Donoghue <john.donoghue@ieee.org>
parents: 6781
diff changeset
113 $(MXE_CC) $< -o $@ installer-files/octave-launch.res -lshlwapi -municode -DUNICODE -D_UNICODE -DQTVERSION=$(ENABLE_QT) $(OCTAVE_LAUNCH_NO_SHORT_CPPFLAGS)
5957
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
114
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
115 .PHONY: octave-launch-firsttime
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
116 octave-launch-firsttime: installer-files/octave-launch-firsttime.exe
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
117
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
118 ## FIXME: We aren't using VPATH?
5959
bf9be5e7ab00 octave-launch: Add icons and version info.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5957
diff changeset
119 installer-files/octave-launch-firsttime.exe: $(TOP_DIR)/installer-files/octave-launch.c installer-files/octave-launch.res | installer-files/.dirstamp
6837
6adeb47401d6 Add qt6 usage to mxe-octave
John Donoghue <john.donoghue@ieee.org>
parents: 6781
diff changeset
120 $(MXE_CC) $< -o $@ installer-files/octave-launch.res -Wl,--subsystem,windows -lshlwapi -municode -DUNICODE -D_UNICODE -DFIRST_TIME -DQTVERSION=$(ENABLE_QT) $(OCTAVE_LAUNCH_NO_SHORT_CPPFLAGS)
5959
bf9be5e7ab00 octave-launch: Add icons and version info.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5957
diff changeset
121
6622
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
122 installer-files/octave-logo.ico: $(TOP_DIR)/installer-files/octave-logo.ico | installer-files/.dirstamp
7105
0abe4f772e3e * binary-dist-rules.mk: Don't use -a option for cp.
John W. Eaton <jwe@octave.org>
parents: 6837
diff changeset
123 cp $< $@
6622
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
124
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
125 installer-files/octave-launch.rc: $(TOP_DIR)/installer-files/octave-launch.rc.in | installer-files/octave-logo.ico installer-files/.dirstamp
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
126 $(SED) $< -e 's/@PRODUCT_VERSION@/$($(OCTAVE_TARGET)_VERSION)/' -e "s/@PRODUCT_VERSION_COMMA@/$(shell echo $($(OCTAVE_TARGET)_VERSION).0 | $(SED) 's|\.|,|g')/" > $@
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
127
1f6d83d95f96 Update octave-launch file version info for octave version (Bug #63740)
John Donoghue <john.donoghue@ieee.org>
parents: 6582
diff changeset
128 installer-files/octave-launch.res: installer-files/octave-launch.rc | installer-files/.dirstamp
5959
bf9be5e7ab00 octave-launch: Add icons and version info.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5957
diff changeset
129 $(MXE_WINDRES) $< -o $@ -O coff
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
130 endif
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
131
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
132 ifeq ($(MXE_WINDOWS_BUILD),yes)
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
133 ifeq ($(MXE_NATIVE_BUILD),no)
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
134 define copy-windows-dist-files
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
135 echo " DLL files..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
136 cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
137 cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
138 cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/$(build-gcc_VERSION)/*.dll $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
139 if [ "$(USE_MSYS2)" = "yes" ]; then \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
140 echo " msys2 files..."; \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
141 cd $(TOP_BUILD_DIR)/msys2 \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
142 && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - ); \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
143 else \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
144 echo " msys base files..."; \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
145 cd $(TOP_BUILD_DIR)/msys-base \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
146 && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - ); \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
147 echo " msys extension files..."; \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
148 cd $(TOP_BUILD_DIR)/msys-extension \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
149 && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - ); \
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
150 fi
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
151 echo " notepad++..."
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
152 cd $(TOP_BUILD_DIR) \
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
153 && tar -c $(TAR_H_OPTION) -f - notepad++ | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
154 echo " README.html..."
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
155 cp $(TOP_DIR)/installer-files/README.html $(OCTAVE_DIST_DIR)/
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
156 echo " refblas..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
157 cp $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin/libblas.dll $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin/librefblas.dll
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
158 echo " installing octave-launch.exe..."
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
159 cp $(TOP_BUILD_DIR)/installer-files/octave-launch.exe $(OCTAVE_DIST_DIR)/
5957
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
160 cp $(TOP_BUILD_DIR)/installer-files/octave-launch-firsttime.exe $(OCTAVE_DIST_DIR)/
4767
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
161 echo " octave.vbs..."
3817
6daa158a7018 nsis installer: use octave.vbs as laucher (Bug #41074)
John Donoghue <john.donoghue@ieee.org>
parents: 3721
diff changeset
162 cp $(TOP_DIR)/installer-files/octave.vbs $(OCTAVE_DIST_DIR)/
4028
8803dfa40236 nsis installer: set directory to userprofile on startof octave from installer (Bug #45899)
John Donoghue
parents: 3963
diff changeset
163 cp $(TOP_DIR)/installer-files/octave-firsttime.vbs $(OCTAVE_DIST_DIR)/
4767
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
164 cp $(TOP_DIR)/installer-files/fc_update.bat $(OCTAVE_DIST_DIR)/
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
165 cp $(TOP_DIR)/installer-files/post-install.bat $(OCTAVE_DIST_DIR)/
5650
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
166 # This patch can be dropped as soon as those lines are removed from
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
167 # the startup scripts for all targets (including stable and release).
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
168 if [ "$(OCTAVE_TARGET)" = "default-octave" ]; then \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
169 (cd '$(OCTAVE_DIST_DIR)' && $(PATCH) -p1 -u) < $(TOP_DIR)/installer-files/octave-no-short-path.patch; \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
170 fi
4590
5b5c47cd2111 Add file with hg id of MXE-Octave to dist package (bug #52794).
Markus Mützel <markus.muetzel@gmx.de>
parents: 4506
diff changeset
171 cp $(TOP_BUILD_DIR)/HG-ID $(OCTAVE_DIST_DIR)/
5954
90a4202652e7 Don't delete octave wrapper executables when packaging for Windows.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5742
diff changeset
172 echo " installing octave.bat script file..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
173 cp $(TOP_DIR)/installer-files/octave.bat $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin/octave.bat
5650
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
174 # This patch can be dropped as soon as those lines are removed from
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
175 # "octave.bat" for all targets (including stable and release).
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
176 if [ "$(OCTAVE_TARGET)" = "default-octave" ]; then \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
177 (cd '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin' && $(PATCH) -p1 -u) < $(TOP_DIR)/installer-files/octave-bat-no-short-path.patch; \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
178 fi
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
179 cp $(TOP_DIR)/installer-files/octave.bat $(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin/octave-$($(OCTAVE_TARGET)_VERSION).bat
3961
808ff354717a binary-dist-rules: fix paths of distributes .pc and .la files
John D
parents: 3958
diff changeset
180 echo " updating libtool references..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
181 find '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/' -type f -name "*.la" \
3963
9d402d735dd1 nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents: 3961
diff changeset
182 -exec $(SED) -i 's|$(HOST_PREFIX)|/usr|g;s|$(BUILD_TOOLS_PREFIX)|/usr|g' {} \; ;
3961
808ff354717a binary-dist-rules: fix paths of distributes .pc and .la files
John D
parents: 3958
diff changeset
183 echo " updating pkg-config .pc references..."
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
184 find '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/lib/pkgconfig' -type f -name "*.pc" \
3963
9d402d735dd1 nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents: 3961
diff changeset
185 -exec $(SED) -i 's|$(HOST_PREFIX)|/usr|g;s|$(BUILD_TOOLS_PREFIX)|/usr|g' {} \; ;
9d402d735dd1 nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents: 3961
diff changeset
186 if [ "$(ENABLE_DEVEL_TOOLS)" = "yes" ]; then \
9d402d735dd1 nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents: 3961
diff changeset
187 cp $(TOP_DIR)/installer-files/cmdshell.bat $(OCTAVE_DIST_DIR)/; \
5650
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
188 if [ "$(OCTAVE_TARGET)" = "default-octave" ]; then \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
189 (cd '$(OCTAVE_DIST_DIR)' && $(PATCH) -p1 -u) < $(TOP_DIR)/installer-files/cmdshell-no-short-path.patch; \
6805ab42c8aa Don't convert to short paths for default-octave target (bug #59923).
Markus Mützel <markus.muetzel@gmx.de>
parents: 5553
diff changeset
190 fi; \
3963
9d402d735dd1 nsis-installer: add bash window menu if devel tools enabled
John Donoghue
parents: 3961
diff changeset
191 fi
4807
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
192 echo " updating script tool references..."
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
193 #find '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin' -type f ! -name "*.*" \
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
194 # -exec $(SED) -i 's|$(HOST_PREFIX)|/$(OCTAVE_ADD_PATH)|g;s|$(BUILD_TOOLS_PREFIX)|/$(OCTAVE_ADD_PATH)|g' {} \; ;
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
195 find '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin' -type f ! -name "*.*" \
4906
bcfecd611e1b * binary-dist-rules.mk: remove '/' from any addpath paths
John Donoghue
parents: 4807
diff changeset
196 -exec sh -c 'test `head -c2 {}` = "#!" && $(SED) -i "s|$(HOST_PREFIX)|$(OCTAVE_ADD_PATH)|g;s|$(BUILD_TOOLS_PREFIX)|$(OCTAVE_ADD_PATH)|g" {}' \; ;
4807
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
197 # some additional script files to fix
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
198 $(SED) -i "s|datadir = '/usr/share'|datadir = '$(OCTAVE_ADD_PATH)/share'|g" '$(OCTAVE_DIST_DIR)$(OCTAVE_ADD_PATH)/bin/makeinfo'
9fa4ad9a659a * binary-dist-rules.mk: in mingw, update all non ext script files for /mingXX path
John Donoghue
parents: 4795
diff changeset
199
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
200 endef
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
201 else
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
202 define copy-windows-dist-files
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
203 echo " DLL files..."
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
204 cp /mingw/bin/*.dll $(OCTAVE_DIST_DIR)/bin
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
205 echo " README.html..."
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
206 cp $(TOP_DIR)/installer-files/README.html $(OCTAVE_DIST_DIR)/
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
207 echo " refblas..."
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
208 cp $(OCTAVE_DIST_DIR)/bin/libblas.dll $(OCTAVE_DIST_DIR)/bin/librefblas.dll
5955
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
209 echo " installing octave-launch.exe..."
f42752ce0ae3 new octave-launcher.exe program from John Donoghue
John W. Eaton <jwe@octave.org>
parents: 5954
diff changeset
210 cp $(TOP_BUILD_DIR)/installer-files/octave-launch.exe $(OCTAVE_DIST_DIR)/
5957
9cd5425b033b octave-launch-firsttime: New launcher executable for starting Octave first time.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5956
diff changeset
211 cp $(TOP_BUILD_DIR)/installer-files/octave-launch-firsttime.exe $(OCTAVE_DIST_DIR)/
4767
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
212 echo " octave.vbs..."
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
213 cp $(TOP_DIR)/installer-files/octave.vbs $(OCTAVE_DIST_DIR)/
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
214 cp $(TOP_DIR)/installer-files/octave-firsttime.vbs $(OCTAVE_DIST_DIR)/
4254
7f2d5c8c4491 installer: update fc cache during install (Bug #45458)
John D
parents: 4174
diff changeset
215 cp $(TOP_DIR)/installer-files/fc_update.bat $(OCTAVE_DIST_DIR)/
4793
202fa20cf559 add msys2 environment/tools option, use seprate post-install script to finalize install
John Donoghue
parents: 4788
diff changeset
216 cp $(TOP_DIR)/installer-files/post-install.bat $(OCTAVE_DIST_DIR)/
5954
90a4202652e7 Don't delete octave wrapper executables when packaging for Windows.
Markus Mützel <markus.muetzel@gmx.de>
parents: 5742
diff changeset
217 echo " installing octave.bat script files..."
4767
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
218 cp $(TOP_DIR)/installer-files/octave.bat $(OCTAVE_DIST_DIR)/bin/octave.bat
a800e350d88b use .bat file for octave.exe/octave-version.exe (Bug #53938)
John Donoghue
parents: 4698
diff changeset
219 cp $(TOP_DIR)/installer-files/octave.bat $(OCTAVE_DIST_DIR)/bin/octave-$($(OCTAVE_TARGET)_VERSION).bat
3673
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
220 endef
972f2d9c76ca tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874)
John Donoghue
parents: 3588
diff changeset
221 endif
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
222 endif
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
223
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
224 define make-dist-files-writable
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
225 echo "making all dist files writable by user..."
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
226 chmod -R u+w $(OCTAVE_DIST_DIR)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
227 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
228
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
229 ifeq ($(STRIP_DIST_FILES),yes)
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
230 ifeq ($(MXE_WINDOWS_BUILD),yes)
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
231 define strip-dist-files
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
232 echo "stripping files..."
5231
ad00dd601316 * binary-dist-rules.mk: dont strip the msys-2.0.dll
John Donoghue
parents: 5067
diff changeset
233 for f in `find $(OCTAVE_DIST_DIR) -name '*.dll' -o -name '*.exe' -o -name '*.oct' | $(GREP) -v "notepad++" | $(GREP) -v "msys-2.0.dll"`; do \
4913
0958cf066f1a Don't strip files starting with a shebang (bug #55281).
Markus Mützel <markus.muetzel@gmx.de>
parents: 4906
diff changeset
234 if [ "$$(head -n1 $$f | cut -c1-2)" != "#!" ]; then \
0958cf066f1a Don't strip files starting with a shebang (bug #55281).
Markus Mützel <markus.muetzel@gmx.de>
parents: 4906
diff changeset
235 $(MXE_STRIP) $$f; \
0958cf066f1a Don't strip files starting with a shebang (bug #55281).
Markus Mützel <markus.muetzel@gmx.de>
parents: 4906
diff changeset
236 fi; \
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
237 done
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
238 endef
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
239 else
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
240 define strip-dist-files
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
241 echo "stripping files..."
3446
f827586fef9c * binary-dist-rules.mk: don't use $(shell ...) in shell for loop
John W. Eaton <jwe@octave.org>
parents: 3444
diff changeset
242 for f in `find $(OCTAVE_DIST_DIR) -type f -a -perm /a+x`; do \
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
243 case "`file $$f`" in \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
244 *script*) \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
245 ;; \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
246 *executable* | *archive* | *"shared object"*) \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
247 $(MXE_STRIP) $$f; \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
248 ;; \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
249 esac; \
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
250 done
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
251 endef
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
252 endif
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
253 else
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
254 define strip-dist-files
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
255 echo "not stripping files..."
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
256 endef
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
257 endif
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
258
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
259 OCTAVE_WRAPPER_SCRIPTS = octave octave-cli octave-config
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
260
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
261 ifeq ($(MXE_SYSTEM), gnu-linux)
3530
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
262 define install-octave-wrapper-scripts
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
263 echo "installing octave wrapper scripts..."
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
264 for f in $(OCTAVE_WRAPPER_SCRIPTS); do \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
265 mv $(OCTAVE_DIST_DIR)/bin/$$f-$($(OCTAVE_TARGET)_VERSION) \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
266 $(OCTAVE_DIST_DIR)/bin/$$f-$($(OCTAVE_TARGET)_VERSION).real; \
4990
a059052f4807 * binary-dist-rules.mk: use full path for octave-wrapper.in
John Donoghue <john.donoghue@ieee.org>
parents: 4913
diff changeset
267 $(SED) < $(TOP_DIR)/octave-wrapper.in \
4506
f3d64fe692e6 octave-wrapper.in: Include GCC library directory in LD_LIBRARY_PATH.
John W. Eaton <jwe@octave.org>
parents: 4254
diff changeset
268 -e "s|@GCC_VERSION@|$(native-gcc_VERSION)|" \
f3d64fe692e6 octave-wrapper.in: Include GCC library directory in LD_LIBRARY_PATH.
John W. Eaton <jwe@octave.org>
parents: 4254
diff changeset
269 -e "s|@GCC_ARCH@|$(TARGET)|" \
3530
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
270 -e "s|@OCTAVE_VERSION@|$($(OCTAVE_TARGET)_VERSION)|" \
3862
c08abc3f5bf3 correctly extract first two digits of gnuplot version number
John W. Eaton <jwe@octave.org>
parents: 3817
diff changeset
271 -e "s|@GNUPLOT_MAJOR_MINOR_VERSION@|$(shell echo $(gnuplot_VERSION) | $(SED) -e 's/\(^[0-9][0-9]*\.[0-9][0-9]*\)\..*/\1/')|" \
3530
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
272 -e "s|@PROGRAM_NAME@|$$f|" > $$f-t \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
273 && $(INSTALL) -m 755 $$f-t $(OCTAVE_DIST_DIR)/bin/$$f-$($(OCTAVE_TARGET)_VERSION); \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
274 rm -f $(OCTAVE_DIST_DIR)/bin/$$f; \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
275 ln -s $$f-$($(OCTAVE_TARGET)_VERSION) $(OCTAVE_DIST_DIR)/bin/$$f; \
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
276 done
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
277 endef
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
278 else
3530
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
279 define install-octave-wrapper-scripts
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
280 echo "no octave wrapper scripts to install for this system..."
1e09264307e8 binary-dist-rules.mk: Style fixes.
John W. Eaton <jwe@octave.org>
parents: 3529
diff changeset
281 endef
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
282 endif
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
283
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
284 .PHONY: binary-dist-files
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
285 binary-dist-files: $(BINARY_DIST_DEPS)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
286 @$(delete-dist-directory)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
287 @$(make-dist-directory)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
288 @$(copy-dist-files)
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
289 @$(copy-windows-dist-files)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
290 @$(make-dist-files-writable)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
291 @$(strip-dist-files)
3442
ebe73c541a16 allow binary dist to work for gnu-linux target
John W. Eaton <jwe@octave.org>
parents: 3435
diff changeset
292 @$(install-octave-wrapper-scripts)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
293
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
294 define make-installer-file
3571
44eb8941c35f fix make nsis-installer
John Donoghue <john.donoghue@ieee.org>
parents: 3569
diff changeset
295 if [ -f $(OCTAVE_NSI_FILE) ]; then \
44eb8941c35f fix make nsis-installer
John Donoghue <john.donoghue@ieee.org>
parents: 3569
diff changeset
296 echo "deleting previous installer script..."; \
44eb8941c35f fix make nsis-installer
John Donoghue <john.donoghue@ieee.org>
parents: 3569
diff changeset
297 rm -f $(OCTAVE_NSI_FILE); \
3569
c53ea91b338b don't delete generated installer script
John W. Eaton <jwe@octave.org>
parents: 3544
diff changeset
298 fi
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
299 echo "generating installer script..."
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
300 $(TOP_BUILD_DIR)/tools/makeinst-script.sh $(OCTAVE_DIST_DIR) $(OCTAVE_DIST_NAME)-installer.exe $(OCTAVE_NSI_FILE)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
301 echo "generating installer..."
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
302 $(TARGET)-makensis $(OCTAVE_NSI_FILE) > $(TOP_BUILD_DIR)/dist/nsis.log
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
303 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
304
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
305 $(OCTAVE_DIST_NAME)-installer.exe: nsis binary-dist-files
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
306 @$(make-installer-file)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
307
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
308 .PHONY: nsis-installer
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
309 nsis-installer: $(OCTAVE_DIST_NAME)-installer.exe
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
310
4658
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
311 define make-7z-dist
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
312 echo "generating 7z file..."
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
313 cd $(TOP_BUILD_DIR)/dist && p7zip -k $(OCTAVE_DIST_NAME)
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
314 endef
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
315
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
316 .PHONY: 7z-dist
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
317 7z-dist: binary-dist-files
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
318 @$(make-7z-dist)
213da5688be0 update binary dist rules
John W. Eaton <jwe@octave.org>
parents: 4590
diff changeset
319
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
320 define make-zip-dist
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
321 echo "generating zip file..."
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
322 cd $(TOP_BUILD_DIR)/dist \
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
323 && zip -q -9 -r $(OCTAVE_DIST_NAME).zip $(OCTAVE_DIST_NAME)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
324 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
325
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
326 .PHONY: zip-dist
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
327 zip-dist: binary-dist-files
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
328 @$(make-zip-dist)
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
329
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
330 define make-tar-dist
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
331 echo "generating tar file..."
4066
0962acdde3be builld: allow out of source build
John Donoghue
parents: 4028
diff changeset
332 cd $(TOP_BUILD_DIR)/dist \
3432
5fc3d674ca3a Correctly name output of dist-tar with .tgz, not .zip, extension.
Rik <rik@octave.org>
parents: 3431
diff changeset
333 && tar -c -z -f $(OCTAVE_DIST_NAME).tgz $(OCTAVE_DIST_NAME)
3431
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
334 endef
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
335
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
336 .PHONY: tar-dist
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
337 tar-dist: binary-dist-files
a7c772aa106f Move mk-dist script functionality into Makefile.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
338 @$(make-tar-dist)