A modern Music Player Daemon based on Rockbox open source high quality audio player
libadwaita audio rust zig deno mpris rockbox mpd
at master 47 lines 1.6 kB view raw
1# __________ __ ___. 2# Open \______ \ ____ ____ | | _\_ |__ _______ ___ 3# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / 4# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < 5# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ 6# \/ \/ \/ \/ \/ 7 8CFLAGS += -Wall -Wextra -Iinclude -I../../tools/ucl/include -I../../lib/microtar/src 9OUTPUT = jztool 10 11ifdef RELEASE 12CFLAGS += -Os -DNDEBUG 13else 14CFLAGS += -O0 -ggdb 15endif 16 17LIBSOURCES := src/buffer.c src/context.c src/device_info.c \ 18 src/identify_file.c src/ucl_unpack.c src/usb.c src/x1000.c 19SOURCES := $(LIBSOURCES) jztool.c 20EXTRADEPS := libucl.a libmicrotar.a 21 22CPPDEFINES := $(shell echo foo | $(CROSS)$(CC) -dM -E -) 23 24ifeq ($(findstring WIN32,$(CPPDEFINES)),WIN32) 25# TODO: support Windows 26else 27ifeq ($(findstring APPLE,$(CPPDEFINES)),APPLE) 28# Mac, tested on x86 only -- may need to adjust paths if building on ARM. 29# paths should work with homebrew libusb. 30LIBUSB_CFLAGS ?= -I/usr/local/include/libusb-1.0 31ifdef STATIC 32LIBUSB_LDOPTS ?= /usr/local/lib/libusb-1.0.a -framework IOKit -framework CoreFoundation 33else 34LIBUSB_LDOPTS ?= -L/usr/local/lib -lusb-1.0 35endif 36else 37# Linux; note for static builds you need to build a copy of libusb without 38# udev support and specify the includes / libs manually 39LIBUSB_CFLAGS ?= `pkg-config --cflags libusb-1.0` 40LIBUSB_LDOPTS ?= `pkg-config --libs libusb-1.0` 41endif 42endif 43 44CFLAGS += $(LIBUSB_CFLAGS) 45LDOPTS += $(LIBUSB_LDOPTS) 46 47include ../libtools.make