bch
/
xmem
1
0
Fork 0

Add Linux makefile

This commit is contained in:
Christian Barthel 2022-01-07 22:55:21 +01:00
parent 65bf48110a
commit 2458539dc7
1 changed files with 44 additions and 0 deletions

44
Makefile.linux Normal file
View File

@ -0,0 +1,44 @@
PROG= xmem
VERSION= 1.27
LDFLAGS+= -L/usr/lib/x86_64-linux-gnu/ -lX11 -lXt -lXaw -lXmu
CFLAGS+= -Wall -I/usr/include/X11/ -I/usr/X11R6/include/ -I/usr/local/include/
OBJECTS= xmem.o MemStripChart.o get_mem.o
all: xmem
xmem.full:
@echo "full not supported yet"
xmem.debug:
@echo "debug not supported yet"
xmem: $(OBJECTS)
$(CC) -o xmem $(OBJECTS) $(LDFLAGS)
%.o: %c
$(CC) $(CFLAGS) -c $<
clean:
-rm -rf $(OBJECTS) $(PROG)
dist:
mkdir -p ${PROG}-${VERSION}
cp *.h *.c Makefile xmem.1 xmem.bit copyright XMem.ad ${PROG}-${VERSION}
tar cfvz ${PROG}-${VERSION}.tar.gz ${PROG}-${VERSION}
rm -rf ${PROG}-${VERSION}
dist-clean:
-rm ${PROG}-${VERSION}.tar.gz
install:
install -d -m 755 ${PREFIX}/bin/
install -c -S -s -o root -g bin -m 755 xmem ${PREFIX}/bin/xmem
install -d -m 755 ${PREFIX}/man/man1/
install -c -o root -g bin -m 644 xmem.1 ${PREFIX}/man/man1/xmem.1
install -d -m 755 ${PREFIX}/lib/X11/app-defaults/
install -c -o root -g bin -m 644 XMem.ad ${PREFIX}/lib/X11/app-defaults/XMem
install -d -m 755 ${PREFIX}/share/${PROG}/
install -c -o root -g bin -m 644 xmem.bit ${PREFIX}/share/${PROG}/xmem.bit
install -c -o root -g bin -m 644 copyright ${PREFIX}/share/${PROG}/copyright