1 # See LICENSE file for copyright and license details
2 # slstatus - suckless status monitor
32 slstatus
: slstatus.o
$(COM
:=.o
) $(REQ
:=.o
)
33 slstatus.o
: slstatus.c slstatus.h
$(HDR
) $(REQ
:=.h
)
35 battery.o
: battery.c config.mk
$(HDR
) $(REQ
:=.h
)
36 cpu.o
: cpu.c config.mk
$(HDR
) $(REQ
:=.h
)
37 datetime.o
: datetime.c config.mk
$(HDR
) $(REQ
:=.h
)
38 disk.o
: disk.c config.mk
$(HDR
) $(REQ
:=.h
)
39 entropy.o
: entropy.c config.mk
$(HDR
) $(REQ
:=.h
)
40 hostname.o
: hostname.c config.mk
$(HDR
) $(REQ
:=.h
)
41 ip.o
: ip.c config.mk
$(HDR
) $(REQ
:=.h
)
42 kernel_release.o
: kernel_release.c config.mk
$(HDR
) $(REQ
:=.h
)
43 keyboard_indicators.o
: keyboard_indicators.c config.mk
$(HDR
) $(REQ
:=.h
)
44 load_avg.o
: load_avg.c config.mk
$(HDR
) $(REQ
:=.h
)
45 num_files.o
: num_files.c config.mk
$(HDR
) $(REQ
:=.h
)
46 ram.o
: ram.c config.mk
$(HDR
) $(REQ
:=.h
)
47 run_command.o
: run_command.c config.mk
$(HDR
) $(REQ
:=.h
)
48 swap.o
: swap.c config.mk
$(HDR
) $(REQ
:=.h
)
49 temperature.o
: temperature.c config.mk
$(HDR
) $(REQ
:=.h
)
50 uptime.o
: uptime.c config.mk
$(HDR
) $(REQ
:=.h
)
51 user.o
: user.c config.mk
$(HDR
) $(REQ
:=.h
)
52 volume.o
: volume.c config.mk
$(HDR
) $(REQ
:=.h
)
53 wifi.o
: wifi.c config.mk
$(HDR
) $(REQ
:=.h
)
56 $(CC
) -o
$@
$(LDFLAGS
) $< $(COM
:=.o
) $(REQ
:=.o
) $(LDLIBS
)
59 $(CC
) -c
$(CPPFLAGS
) $(CFLAGS
) $<
62 rm -f slstatus slstatus.o
$(COM
:=.o
) $(REQ
:=.o
)
65 rm -rf
"slstatus-$(VERSION)"
66 mkdir
-p
"slstatus-$(VERSION)"
67 cp
-R LICENSE Makefile README config.mk config.def.h \
68 $(HDR
) slstatus.c
$(COM
:=.c
) $(REQ
:=.c
) $(REQ
:=.h
) \
69 slstatus
.1 "slstatus-$(VERSION)"
70 tar -cf
- "slstatus-$(VERSION)" | gzip
-c
> "slstatus-$(VERSION).tar.gz"
71 rm -rf
"slstatus-$(VERSION)"
74 mkdir
-p
"$(DESTDIR)$(PREFIX)/bin"
75 cp
-f slstatus
"$(DESTDIR)$(PREFIX)/bin"
76 chmod
755 "$(DESTDIR)$(PREFIX)/bin/slstatus"
77 mkdir
-p
"$(DESTDIR)$(MANPREFIX)/man1"
78 cp
-f slstatus
.1 "$(DESTDIR)$(MANPREFIX)/man1"
79 chmod
644 "$(DESTDIR)$(MANPREFIX)/man1/slstatus.1"
82 rm -f
"$(DESTDIR)$(PREFIX)/bin/slstatus"
83 rm -f
"$(DESTDIR)$(MANPREFIX)/man1/slstatus.1"