File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # Copyright (C) 2024 John Törnblom
2+ #
3+ # This file is free software; you can redistribute it and/or modify it
4+ # under the terms of the GNU General Public License as published by
5+ # the Free Software Foundation; either version 3 of the License, or
6+ # (at your option) any later version.
7+ #
8+ # This program is distributed in the hope that it will be useful, but
9+ # WITHOUT ANY WARRANTY; without even the implied warranty of
10+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11+ # General Public License for more details.
12+ #
13+ # You should have received a copy of the GNU General Public License
14+ # along with this program; see the file COPYING. If not see
15+ # <http://www.gnu.org/licenses/>.
16+
17+ BREW_PREFIX := $(shell brew --prefix)
18+ CURL_PREFIX := $(BREW_PREFIX)/opt/curl
19+
20+ CFLAGS := -O2 -Wall -Werror -I$(CURL_PREFIX)/include
21+ LDFLAGS := -L$(CURL_PREFIX)/lib
22+ LDADD := -lcurl
23+
24+ ELF := fetchpkg
25+ all: $(ELF)
26+
27+ $(ELF): main.c dl.c parson.c sha256.c sha1.c
28+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDADD)
29+
30+ clean:
31+ rm -f $(ELF)
You can’t perform that action at this time.
0 commit comments