2 # Copyright (C) 2003 IBM
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; version 2 of the License.
8 # This program is distributed in the hope that it will be useful,
9 # but 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.
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 sbindir = ${prefix}/sbin
21 mandir = ${prefix}/usr/share/man
23 INSTALL = /usr/bin/install -c
24 INSTALL_PROGRAM = ${INSTALL}
25 INSTALL_DATA = ${INSTALL} -m 644
27 # Note some of the variables used here are set when built under udev, and
28 # otherwise might not be set.
30 override CFLAGS+=-DSCSI_ID_VERSION=\"$(SCSI_ID_VERSION)\" $(DEBUG) -Wall
36 # Built static and stripped when built with udev.
47 # XXX use a compressed man page?
50 $(INSTALL_PROGRAM) -D $(PROG) $(sbindir)/$(PROG)
51 $(INSTALL_DATA) -D scsi_id.8 $(DESTDIR)$(mandir)/man8/scsi_id.8
54 -rm $(sbindir)/$(PROG)
55 -rm $(mandir)/man8/scsi_id.8
57 $(OBJS): scsi_id.h scsi.h
63 $(LD) $(LDFLAGS) -o $(PROG) $(CRT0) $(OBJS) $(SYSFS) $(LIB_OBJS) $(ARCH_LIB_OBJS)