aboutsummaryrefslogtreecommitdiff
path: root/contrib/ls-config/src/makefile
blob: d04a7739a721a3408c350ebf091773fc1dbe8e85 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
CC=gcc
CFLAGS=-O2 -Wall
#Use for DEVELOP mode:
#DEVFLAGS=-g -D __DEVEL__
#Use for PRODUCTION mode:
DEVFLAGS=-s -fomit-frame-pointer

all: ls-config langs

ls-config: ls-config.c ls-config.pot
	$(CC) $(CFLAGS) $(DEVFLAGS) -o ../ls-config ls-config.c -L../lib -lm -lconfig 

ls-config.pot: 
	xgettext -d ls-config -o po/ls-config.pot ls-config.c

langs:
	make -C po

install:
	mkdir -p /usr/share/ls/lib
	chown root:adm /usr/share/ls/lib
	cp ../ls-config /usr/share/ls/lib/
	chown root:adm /usr/share/ls/lib
	chmod 755 /usr/share/ls/lib/ls-config
	make -C po install

clean:
	make -C po clean

remove:
	rm -f /usr/share/ls/lib/ls-config
	make -C po remove