Music production session manager https://www.laborejo.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

81 lines
2.8 KiB

#This is a makefile and needs tabs, not spaces.
.PHONY: install uninstall clean gitclean resources
all:
#Our Program
printf "prefix = \"$(PREFIX)\"" > compiledprefix.py
python3 -m nuitka --recurse-all --python-flag -O --warn-unusual-code --warn-implicit-exceptions --recurse-not-to=PyQt5 --show-progress --show-modules --file-reference-choice=runtime $(PROGRAM)
rm compiledprefix.py
#nsm-data
python3 -m nuitka --recurse-all --python-flag -O --warn-unusual-code --warn-implicit-exceptions --recurse-not-to=PyQt5 --show-progress --show-modules --file-reference-choice=runtime tools/nsm-data
clean:
rm -f "$(PROGRAM).bin"
rm -rf "$(PROGRAM).build"
rm -f "nsm-data.bin"
rm -rf "nsm-data.build"
rm Makefile
#Convenience function for developing, not used for the build or install process
gitclean:
git clean -f -X -d
#Convenience function for developing, not used for the build or install process
resources:
cd documentation && python3 build.py
cd documentation && sh build-documentation.sh
cd qtgui/resources && sh buildresources.sh
install:
#nsm-data
install -D -m 755 "nsm-data.bin" $(DESTDIR)$(PREFIX)/bin/nsm-data
#Argodejo
install -D -m 755 $(PROGRAM).bin $(DESTDIR)$(PREFIX)/bin/$(PROGRAM)
install -D -m 644 documentation/out/* -t $(DESTDIR)$(PREFIX)/share/doc/$(PROGRAM)
install -D -m 644 README.md $(DESTDIR)$(PREFIX)/share/doc/$(PROGRAM)/README.md
install -D -m 644 LICENSE $(DESTDIR)$(PREFIX)/share/doc/$(PROGRAM)/LICENSE
install -D -m 644 desktop/desktop.desktop $(DESTDIR)$(PREFIX)/share/applications/$(PROGRAM).desktop
install -D -m 644 desktop/argodejo-continue.desktop $(DESTDIR)$(PREFIX)/share/applications/argodejo-continue.desktop
install -d $(DESTDIR)$(PREFIX)/share/man/man1
gzip -c documentation/$(PROGRAM).1 > $(DESTDIR)$(PREFIX)/share/man/man1/$(PROGRAM).1.gz
#Icons
for size in 16 32 64 128 256 512 ; do \
install -D -m 644 desktop/images/"$$size"x"$$size".png $(DESTDIR)$(PREFIX)/share/icons/hicolor/"$$size"x"$$size"/apps/$(PROGRAM).png ; \
done
install -D -m 644 desktop/images/256x256.png $(DESTDIR)$(PREFIX)/share/pixmaps/$(PROGRAM).png
#Currently no engine resources
#install -d $(DESTDIR)$(PREFIX)/share/$(PROGRAM)
#cp -r engine/resources/* $(DESTDIR)$(PREFIX)/share/$(PROGRAM)/
uninstall:
#Directories
rm -rf $(DESTDIR)$(PREFIX)/share/doc/$(PROGRAM)
#Currently nothing in share
#rm -rf $(DESTDIR)$(PREFIX)/share/$(PROGRAM)
#Files
rm -f $(DESTDIR)$(PREFIX)/bin/$(PROGRAM)
rm -f $(DESTDIR)$(PREFIX)/bin/nsm-data
rm -f $(DESTDIR)$(PREFIX)/share/applications/$(PROGRAM).desktop
rm -f $(DESTDIR)$(PREFIX)/share/applications/argodejo-continue.desktop
rm -f $(DESTDIR)$(PREFIX)/share/man/man1/$(PROGRAM).1.gz
#Icons
for size in 16 32 64 128 256 512 ; do \
rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/"$$size"x"$$size"/apps/$(PROGRAM).png ; \
done
rm -f $(DESTDIR)$(PREFIX)/share/pixmaps/$(PROGRAM).png