Add install, uninstall, and debs to Makefile

This commit is contained in:
BBaoVanC 2021-01-06 01:04:12 -06:00
parent 8fc99fb467
commit a9ecbe74e6
No known key found for this signature in database
GPG key ID: 18089E4E3CCF1D3A
4 changed files with 20 additions and 10 deletions

View file

@ -27,10 +27,8 @@ jobs:
draft: true
prerelease: false
- name: Build iOS deb
run: make iosdeb
- name: Build amd64 deb
run: make amd64deb
- name: Build debs
run: make debs
- name: Upload iphoneos-arm asset
id: upload-iphoneos-arm-asset

View file

@ -19,10 +19,8 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Build iOS deb
run: make iosdeb
- name: Build amd64 deb
run: make amd64deb
- name: Build debs
run: make debs
- name: Upload iphoneos-arm deb as artifact
uses: actions/upload-artifact@v2

View file

@ -2,11 +2,24 @@ VERSION ?= $(shell git tag --points-at HEAD | sed 's/^v//')
VERSION += 0-git-$(shell git rev-parse --short HEAD)
VERSION := $(word 1, $(VERSION))
all: options iosdeb amd64deb
include config.mk
all:
@echo "Nekofetch doesn't need to be compiled, run 'make install' to install"
debs: options iosdeb amd64deb
options:
@echo "VERSION: $(VERSION)"
install:
mkdir -p $(PREFIX)/bin
install -m 0755 nekofetch $(PREFIX)/bin/nekofetch
@echo "You may need to install jq, jp2a, and neofetch"
uninstall:
rm -f $(PREFIX)/bin/nekofetch
ioscontrol:
cp control.template ioscontrol
sed -i 's/PACKAGE/com.propr.nekofetch/' ioscontrol
@ -39,4 +52,4 @@ clean:
rm -f ioscontrol amd64control
rm -f com.propr.nekofetch_*_iphoneos-arm.deb nekofetch_*_amd64.deb
.PHONY: all options clean iosdeb amd64deb
.PHONY: all debs options install uninstall clean iosdeb amd64deb

1
config.mk Normal file
View file

@ -0,0 +1 @@
PREFIX := /usr/local