Updated makefile for security reasons (special thanks to linuxreviews.org)

This commit is contained in:
TheDarkBug 2021-03-13 21:37:27 +01:00
parent ae2fcf8799
commit a9f7bcf419
3 changed files with 19 additions and 19 deletions

View file

@ -3,7 +3,6 @@ FILES = uwufetch.c
FLAGS = -O3 FLAGS = -O3
FLAGS_DEBUG = -Wall -Wextra FLAGS_DEBUG = -Wall -Wextra
INSTALL_DIR = /usr/bin/ INSTALL_DIR = /usr/bin/
all: build install
build: uwufetch.c build: uwufetch.c
gcc $(FLAGS) -o $(NAME) $(FILES) gcc $(FLAGS) -o $(NAME) $(FILES)
@ -14,13 +13,13 @@ debug:
./uwufetch ./uwufetch
install: install:
sudo cp $(NAME) $(INSTALL_DIR)$(NAME) cp $(NAME) $(INSTALL_DIR)$(NAME)
ls /usr/lib/uwufetch/ > /dev/null || sudo mkdir /usr/lib/uwufetch/ ls /usr/lib/uwufetch/ 2> /dev/null || mkdir /usr/lib/uwufetch/
sudo cp res/* /usr/lib/uwufetch/ cp res/* /usr/lib/uwufetch/
uninstall: uninstall:
sudo rm $(INSTALL_DIR)$(NAME) rm $(INSTALL_DIR)$(NAME)
sudo rm -rf /usr/lib/uwufetch/ rm -rf /usr/lib/uwufetch/
termux: build termux: build
cp $(NAME) /data/data/com.termux/files$(INSTALL_DIR)$(NAME) cp $(NAME) /data/data/com.termux/files$(INSTALL_DIR)$(NAME)

View file

@ -13,6 +13,7 @@ Nyalpine, Nyarch Linuwu, Nyartix Linuwu, Debinyan, Fedowa, GentOwO, Miwint, Myan
Right now, the package is only available on the AUR: Right now, the package is only available on the AUR:
[![uwufetch](https://img.shields.io/aur/version/uwufetch?color=1793d1&label=uwufetch&logo=arch-linux&style=for-the-badge)](https://aur.archlinux.org/packages/uwufetch/) [![uwufetch](https://img.shields.io/aur/version/uwufetch?color=1793d1&label=uwufetch&logo=arch-linux&style=for-the-badge)](https://aur.archlinux.org/packages/uwufetch/)
[![uwufetch-git](https://img.shields.io/aur/version/uwufetch-git?color=1793d1&label=uwufetch-git&logo=arch-linux&style=for-the-badge)](https://aur.archlinux.org/packages/uwufetch-git/) [![uwufetch-git](https://img.shields.io/aur/version/uwufetch-git?color=1793d1&label=uwufetch-git&logo=arch-linux&style=for-the-badge)](https://aur.archlinux.org/packages/uwufetch-git/)
##### Via source ##### Via source
@ -22,24 +23,24 @@ To install UwUfetch from the source, type these commands in the terminal:
```shell ```shell
git clone https://github.com/TheDarkBug/uwufetch.git git clone https://github.com/TheDarkBug/uwufetch.git
cd uwufetch cd uwufetch
make make build
sudo make install
``` ```
To uninstall: To uninstall:
```shell ```shell
cd uwufetch cd uwufetch
make uninstall sudo make uninstall
``` ```
##### Make options: ##### Make options:
```shell ```shell
make all # builds and installs
make build # builds uwueftch make build # builds uwueftch
make debug # use for debug make debug # use for debug
make install # installs uwufetch make install # installs uwufetch (needs root permissons)
make uninstall # uninstalls uwufetch make uninstall # uninstalls uwufetch (needs root permissons)
make termux # build and install for termux make termux # build and install for termux
make termux_uninstall # uninstall for termux make termux_uninstall # uninstall for termux
``` ```

View file

@ -217,11 +217,11 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu
// linux // linux
if (strcmp(version_name, "alpine") == 0) { if (strcmp(version_name, "alpine") == 0) {
printf("\033[2E\033[4C%s. .___.\n" printf("\033[2E\033[4C%s. .___.\n"
" / \\/ \\ /\n" " / \\/ \\ /\n"
" /OwO\\ɛU\\/ __\n" " /OwO\\ɛU\\/ __\n"
" / \\ \\__/ \\\n" " / \\ \\__/ \\\n"
"/ \\ \\\n\n\n", BLUE); "/ \\ \\\n\n\n", BLUE);
} else if (strcmp(version_name, "arch") == 0) { } else if (strcmp(version_name, "arch") == 0) {
printf( "\033[1E\033[8C%s/\\\n" printf( "\033[1E\033[8C%s/\\\n"
" / \\\n" " / \\\n"
@ -289,9 +289,9 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu
" %s --%s'--------'\n\n",GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN); " %s --%s'--------'\n\n",GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN, WHITE, GREEN);
} else if (strcasecmp(version_name, "popos") == 0) { } else if (strcasecmp(version_name, "popos") == 0) {
printf("\033[2E\033[6C%s|\\.-----./|\n" printf("\033[2E\033[6C%s|\\.-----./|\n"
" |/ \\|\n" " |/ \\|\n"
" | > < |\n" " | > < |\n"
" | %s~ %sP! %s~ %s|\n" " | %s~ %sP! %s~ %s|\n"
"_ ---\\ w /\n" "_ ---\\ w /\n"
" \\_/ '-----'\n\n", BLUE, LPINK, WHITE, LPINK, BLUE); " \\_/ '-----'\n\n", BLUE, LPINK, WHITE, LPINK, BLUE);
} else if (strcmp(version_name, "ubuntu") == 0) { } else if (strcmp(version_name, "ubuntu") == 0) {