2 # Makefile for libulz (stolen from musl) (requires GNU make)
4 # Use config.mak to override any of the following variables.
5 # Do not make changes here.
8 exec_prefix = /usr
/local
9 bindir = $(exec_prefix)/bin
12 includedir = $(prefix)/include
13 libdir = $(prefix)/lib
16 FLASH_SRCS
= $(sort $(wildcard flashlib
/*.c
))
17 CORE_SRCS
= $(sort $(wildcard neoart
/flod
/core
/*.c
))
18 BACKEND_SRCS
= $(sort $(wildcard backends
/*.c
))
20 TRACKER_SRCS
= $(sort $(wildcard neoart
/flod
/trackers
/*.c
))
21 FASTTRACKER_SRCS
= $(sort $(wildcard neoart
/flod
/fasttracker
/*.c
))
22 WHITTAKER_SRCS
= $(sort $(wildcard neoart
/flod
/whittaker
/*.c
))
23 FUTURECOMPOSER_SRCS
= $(sort $(wildcard neoart
/flod
/futurecomposer
/*.c
))
24 DIGITALMUGICIAN_SRCS
= $(sort $(wildcard neoart
/flod
/digitalmugician
/*.c
))
25 SIDMON_SRCS
= $(sort $(wildcard neoart
/flod
/sidmon
/*.c
))
26 SOUNDFX_SRCS
= $(sort $(wildcard neoart
/flod
/soundfx
/*.c
))
27 BPSOUNDMON_SRCS
= $(sort $(wildcard neoart
/flod
/soundmon
/*.c
))
28 HUBBARD_SRCS
= $(sort $(wildcard neoart
/flod
/hubbard
/*.c
))
29 FREDED_SRCS
= $(sort $(wildcard neoart
/flod
/fred
/*.c
))
30 HIPPEL_SRCS
= $(sort $(wildcard neoart
/flod
/hippel
/*.c
))
31 DELTA_SRCS
= $(sort $(wildcard neoart
/flod
/deltamusic
/*.c
))
33 ALL_PLAYER_SRCS
= $(WHITTAKER_SRCS
) $(FUTURECOMPOSER_SRCS
) $(TRACKER_SRCS
) \
34 $(FASTTRACKER_SRCS
) $(DIGITALMUGICIAN_SRCS
) $(SIDMON_SRCS
) $(SOUNDFX_SRCS
) \
35 $(BPSOUNDMON_SRCS
) $(HUBBARD_SRCS
) $(FREDED_SRCS
) $(HIPPEL_SRCS
) $(DELTA_SRCS
)
37 #FILELOADER_SRCS = neoart/flod/FileLoader.c
38 #PLAYER_SRCS = demos/Demo5.c
39 PLAYER_SRCS
= $(sort $(wildcard player
/*.c
))
41 SRCS
= $(BACKEND_SRCS
) $(FLASH_SRCS
) $(CORE_SRCS
) $(ALL_PLAYER_SRCS
) \
42 $(FILELOADER_SRCS
) $(PLAYER_SRCS
)
47 AR
= $(CROSS_COMPILE
)ar
48 RANLIB
= $(CROSS_COMPILE
)ranlib
49 OBJCOPY
= $(CROSS_COMPILE
)objcopy
51 #ALL_INCLUDES = $(sort $(wildcard include/*.h include/*/*.h))
54 ALL_TOOLS
= flodplayer
55 #ALL_TOOLS = flod_demo.out
59 all: $(ALL_LIBS
) $(ALL_TOOLS
)
61 install: $(ALL_LIBS
:lib
/%=$(DESTDIR
)$(libdir)/%) $(ALL_INCLUDES
:include/%=$(DESTDIR
)$(includedir)/%) $(ALL_TOOLS
:tools
/%=$(DESTDIR
)$(bindir)/%)
67 # rm -f $(ALL_LIBS) lib/*.[ao] lib/*.so
70 $(CC
) $(CFLAGS
) $(INC
) -c
-o
$@
$<
73 $(CC
) -o
$@
$(OBJS
) -lm
-lao
$(LDFLAGS
)
75 flod_demo.out
: $(OBJS
)
76 $(CC
) -o
$@
$(OBJS
) -lm
-lao
$(LDFLAGS
)
86 $(DESTDIR
)$(bindir)/%: tools
/%
89 $(DESTDIR
)$(prefix)/%: %
90 install -D
-m
644 $< $@
92 .PHONY
: all clean install