Skip to content

Commit a62372b

Browse files
committed
patch 8.2.1648: Amiga: no common build file for Amiga (-like) systems
Problem: Amiga: no common build file for Amiga (-like) systems. Solution: Turn Make_morph.mak into Make_ami.mak. (Ola Söder, closes #6805)
1 parent 4ed124c commit a62372b

5 files changed

Lines changed: 212 additions & 156 deletions

File tree

Filelist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ SRC_AMI = \
623623
README_amisrc.txt.info \
624624
src.info \
625625
src/INSTALLami.txt \
626-
src/Make_morph.mak \
626+
src/Make_ami.mak \
627627
src/os_amiga.c \
628628
src/os_amiga.h \
629629
src/proto/os_amiga.pro \

src/INSTALLami.txt

Lines changed: 8 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
INSTALLami.txt - Installation of Vim from source on Amiga
1+
INSTALLami.txt - Installation of Vim from source on Amiga and MorphOS
22

33
This file contains instructions for compiling Vim. If you already have an
44
executable version of Vim, you don't need this.
@@ -7,28 +7,13 @@ The file "feature.h" can be edited to match your preferences. You can skip
77
this, then you will get the default behavior as is documented, which should
88
be fine for most people.
99

10-
1110
Summary:
12-
make -f Make_manx.mak Manx C
13-
make -f Make_sas.mak Lattice/SAS C
14-
make -f Make_dice.mak DICE
15-
16-
The Manx compiler is preferred, it was used to produce the Amiga executable
17-
and has been tested most. You should not get any errors or warnings.
18-
19-
The SAS compiler can be used. Older versions (6.0 to 6.3) don't work with the
20-
optimizer switched on. This seems to be fixed with 6.5 or 6.56, but this has
21-
not been tested much. Also disable optimizing when the compiler runs out of
22-
memory or crashes the system (yes, that happens; did I say the Manx compiler
23-
is preferred?).
24-
25-
The DICE makefile has been reported to work by one person only.
26-
27-
You will have to set the "VIM" environment variable to the location of the
28-
documentation files.
29-
11+
make -f Make_ami.mak gcc
12+
make -f Make_ami.mak CC=vc vbcc
3013

31-
MorphOS
14+
Please note that currently only gcc has been tested. VBCC would need its own
15+
CFLAGS, but should otherwise work out of the box. For cross-compiling, UNM
16+
can be used to override uname and thereby set the target. An example is shown
17+
below:
3218

33-
Use the Make_morph.mak Makefile:
34-
make -f Make_morph.mak
19+
make -f Make_ami.mak CC=ppc-morphos-gcc UNM=MorphOS

src/Make_ami.mak

Lines changed: 201 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
#
2+
# Makefile for AROS, AmigaOS4 and MorphOS.
3+
#
4+
BIN = vim
5+
CC ?= gcc
6+
LD = $(CC)
7+
UNM ?= $(shell uname)
8+
DEBUG ?= no
9+
BUILD ?= huge
10+
CFLAGS = -c -O3
11+
12+
# Common compiler flags
13+
CFLAGS += \
14+
-DNO_ARP \
15+
-DUSE_TMPNAM \
16+
-DHAVE_STDARG_H \
17+
-DHAVE_TGETENT \
18+
-DHAVE_TERMCAP \
19+
-DNEW_SHELLSIZE \
20+
-I proto \
21+
-Wno-attributes \
22+
-Wextra
23+
24+
# Vim 'huge' build
25+
ifeq ($(BUILD),huge)
26+
CFLAGS += \
27+
-DFEAT_BROWSE \
28+
-DFEAT_MOUSE \
29+
-DFEAT_HUGE
30+
else
31+
32+
# Vim 'big' build
33+
ifeq ($(BUILD),big)
34+
CFLAGS += \
35+
-DFEAT_BROWSE \
36+
-DFEAT_MOUSE \
37+
-DFEAT_BIG
38+
else
39+
40+
# Vim 'normal' build
41+
ifeq ($(BUILD),normal)
42+
CFLAGS +=\
43+
-DFEAT_BROWSE \
44+
-DFEAT_MOUSE \
45+
-DFEAT_NORMAL
46+
else
47+
48+
# Vim 'small' build
49+
ifeq ($(BUILD),small)
50+
CFLAGS += -DFEAT_SMALL
51+
else
52+
53+
# Vim 'tiny' build
54+
ifeq ($(BUILD),tiny)
55+
CFLAGS += -DFEAT_TINY
56+
endif
57+
endif
58+
endif
59+
endif
60+
endif
61+
62+
# OS specific compiler flags
63+
ifeq ($(UNM),AmigaOS)
64+
LDFLAGS = -mcrt=clib2 -lauto -lm -lnet
65+
CFLAGS += -DHAVE_FSYNC -D__USE_INLINE__ -mcrt=clib2
66+
else
67+
ifeq ($(UNM),AROS)
68+
LDFLAGS = -DHAVE_FSYNC -ldebug
69+
else
70+
ifeq ($(UNM),MorphOS)
71+
LDFLAGS = -ldebug -noixemul
72+
endif
73+
endif
74+
endif
75+
76+
# Patch level used for Amiga style version string
77+
ifdef PATCHLEVEL
78+
CFLAGS += -DPATCHLEVEL=\"$(PATCHLEVEL)\"
79+
endif
80+
81+
# Common sources
82+
SRC += \
83+
arabic.c \
84+
arglist.c \
85+
autocmd.c \
86+
beval.c \
87+
blob.c \
88+
blowfish.c \
89+
buffer.c \
90+
bufwrite.c \
91+
change.c \
92+
charset.c \
93+
cindent.c \
94+
clientserver.c \
95+
clipboard.c \
96+
cmdhist.c \
97+
cmdexpand.c \
98+
crypt.c \
99+
crypt_zip.c \
100+
debugger.c \
101+
dict.c \
102+
diff.c \
103+
digraph.c \
104+
drawline.c \
105+
drawscreen.c \
106+
edit.c \
107+
eval.c \
108+
evalbuffer.c \
109+
evalfunc.c \
110+
evalvars.c \
111+
evalwindow.c \
112+
ex_cmds.c \
113+
ex_cmds2.c \
114+
ex_docmd.c \
115+
ex_eval.c \
116+
ex_getln.c \
117+
fileio.c \
118+
filepath.c \
119+
findfile.c \
120+
fold.c \
121+
getchar.c \
122+
hardcopy.c \
123+
hashtab.c \
124+
help.c \
125+
highlight.c \
126+
if_cscope.c \
127+
indent.c \
128+
insexpand.c \
129+
json.c \
130+
list.c \
131+
locale.c \
132+
main.c \
133+
mark.c \
134+
map.c \
135+
match.c \
136+
mbyte.c \
137+
memfile.c \
138+
memline.c \
139+
menu.c \
140+
message.c \
141+
misc1.c \
142+
misc2.c \
143+
mouse.c \
144+
move.c \
145+
normal.c \
146+
ops.c \
147+
option.c \
148+
optionstr.c \
149+
os_amiga.c \
150+
popupmenu.c \
151+
popupwin.c \
152+
quickfix.c \
153+
regexp.c \
154+
register.c \
155+
screen.c \
156+
scriptfile.c \
157+
search.c \
158+
session.c \
159+
sha256.c \
160+
sign.c \
161+
spell.c \
162+
spellfile.c \
163+
spellsuggest.c \
164+
syntax.c \
165+
tag.c \
166+
term.c \
167+
termlib.c \
168+
testing.c \
169+
textformat.c \
170+
textobject.c \
171+
textprop.c \
172+
time.c \
173+
typval.c \
174+
ui.c \
175+
undo.c \
176+
usercmd.c \
177+
userfunc.c \
178+
version.c \
179+
viminfo.c \
180+
vim9compile.c \
181+
vim9execute.c \
182+
vim9script.c \
183+
vim9type.c \
184+
window.c \
185+
xdiff/xdiffi.c \
186+
xdiff/xemit.c \
187+
xdiff/xhistogram.c \
188+
xdiff/xpatience.c \
189+
xdiff/xprepare.c \
190+
xdiff/xutils.c
191+
192+
OBJ = $(SRC:.c=.o)
193+
194+
# Build everything - Ignoring header dependencies.
195+
$(BIN): $(OBJ)
196+
${LD} -o $(BIN) $(OBJ) $(LDFLAGS)
197+
198+
# Clean up
199+
.PHONY: clean
200+
clean:
201+
$(RM) -fv $(OBJ) $(BIN)

src/Make_morph.mak

Lines changed: 0 additions & 132 deletions
This file was deleted.

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,6 +750,8 @@ static char *(features[]) =
750750

751751
static int included_patches[] =
752752
{ /* Add new patch number below this line */
753+
/**/
754+
1648,
753755
/**/
754756
1647,
755757
/**/

0 commit comments

Comments
 (0)