Files
scst/iscsi-scst/usr/Makefile
Vladislav Bolkhovitin 129cac067c Merged revisions 7253-7266,7268-7271 via svnmerge from
svn+ssh://svn.code.sf.net/p/scst/svn/trunk

........
  r7253 | vlnb | 2017-10-11 20:22:02 -0700 (Wed, 11 Oct 2017) | 3 lines
  
  scst: add example of active non-optimized setup
........
  r7254 | bvassche | 2017-10-12 07:56:44 -0700 (Thu, 12 Oct 2017) | 1 line
  
  qla2x00t: Fix scst_debug.h include path for the in-tree build
........
  r7255 | bvassche | 2017-10-12 08:03:13 -0700 (Thu, 12 Oct 2017) | 1 line
  
  scripts/specialize-patch: Fix #elif handling
........
  r7256 | vlnb | 2017-10-13 19:18:56 -0700 (Fri, 13 Oct 2017) | 3 lines
  
  Unpdate for kernels 4.12+
........
  r7257 | bvassche | 2017-11-11 21:01:16 -0800 (Sat, 11 Nov 2017) | 1 line
  
  iscsi-scst/usr/Makefile: Pass -Wno-format-truncation if supported
........
  r7258 | bvassche | 2017-11-12 21:48:16 -0800 (Sun, 12 Nov 2017) | 4 lines
  
  ib_srpt: Kernel 4.14 build fix
  
  Signed-off-by: Peter Vyazovik <fuzzhead0@gmail.com>
........
  r7259 | bvassche | 2017-11-12 21:49:08 -0800 (Sun, 12 Nov 2017) | 1 line
  
  scst: Introduce the kernel v4.14 bio_set_dev() macro
........
  r7260 | bvassche | 2017-11-12 21:50:44 -0800 (Sun, 12 Nov 2017) | 5 lines
  
  scst, iscsi-scst: Introduce scst_read(), scst_write(), scst_readv() and scst_writev()
  
  This makes it easier to add support for new kernel versions, e.g. kernel
  version v4.14.
........
  r7261 | bvassche | 2017-11-13 08:00:09 -0800 (Mon, 13 Nov 2017) | 1 line
  
  scst/src/scst_lib.c: Fix recently introduced checkpatch complaints
........
  r7262 | bvassche | 2017-11-13 08:18:00 -0800 (Mon, 13 Nov 2017) | 4 lines
  
  scst: Fix build for kernels 3.15 and older
  
  blk_rq_set_block_pc() was introduced in kernel 3.16.
........
  r7263 | bvassche | 2017-11-13 08:24:16 -0800 (Mon, 13 Nov 2017) | 1 line
  
  nightly build: Update kernel versions
........
  r7264 | bvassche | 2017-11-13 08:47:10 -0800 (Mon, 13 Nov 2017) | 1 line
  
  scst: Address two checkpatch warnings
........
  r7265 | bvassche | 2017-11-13 08:47:43 -0800 (Mon, 13 Nov 2017) | 1 line
  
  scst/src/scst_targ: Use READ_ONCE() instead of ACCESS_ONCE()
........
  r7266 | bvassche | 2017-11-13 08:49:39 -0800 (Mon, 13 Nov 2017) | 1 line
  
  fcst/fcst.h: Add identifier names
........
  r7268 | bvassche | 2017-11-14 08:37:24 -0800 (Tue, 14 Nov 2017) | 1 line
  
  scst: Fix kernel <= 2.6.30 build
........
  r7269 | bvassche | 2017-11-14 18:45:57 -0800 (Tue, 14 Nov 2017) | 1 line
  
  nightly/bin/nightly: Clone the source code tree quietly
........
  r7270 | bvassche | 2017-11-14 18:47:06 -0800 (Tue, 14 Nov 2017) | 1 line
  
  nightly build: Update kernel versions
........
  r7271 | bvassche | 2017-11-14 18:48:03 -0800 (Tue, 14 Nov 2017) | 1 line
  
  nightly/conf/nightly.sendmail: Use mail if mutt is not available
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.3.x@7288 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-23 04:30:51 +00:00

73 lines
1.9 KiB
Makefile

#
# Makefile for the user space part of iSCSI-SCST.
#
# Copyright (C) 2007 - 2017 Vladislav Bolkhovitin
# Copyright (C) 2007 - 2017 SanDisk Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation, version 2
# of the License.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
ifndef PREFIX
PREFIX=/usr/local
endif
cc-option = $(shell if $(CC) $(1) -S -o /dev/null -xc /dev/null \
> /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;)
SRCS_D = iscsid.c iscsi_scstd.c conn.c session.c target.c message.c ctldev.c \
log.c chap.c event.c param.c config.c isns.c md5.c sha1.c \
misc.c
OBJS_D = $(SRCS_D:.c=.o)
SRCS_ADM = iscsi_adm.c param.c
OBJS_ADM = $(SRCS_ADM:.c=.o)
CFLAGS += -O2 -Wall -Wextra -Wstrict-prototypes -Wno-sign-compare \
-Wimplicit-function-declaration -Wno-unused-parameter \
-Wno-missing-field-initializers \
$(call cc-option,-Wno-format-truncation) \
-g -I../include -I$(SCST_INC_DIR)
CFLAGS += -D_GNU_SOURCE # required for glibc >= 2.8
CFLAGS += $(LOCAL_CFLAGS)
PROGRAMS = iscsi-scstd iscsi-scst-adm
LIBS =
all: $(PROGRAMS)
iscsi-scstd: .depend_d $(OBJS_D)
$(CC) $(OBJS_D) $(LIBS) $(LOCAL_LD_FLAGS) -o $@
iscsi-scst-adm: .depend_adm $(OBJS_ADM)
$(CC) $(OBJS_ADM) $(LIBS) $(LOCAL_LD_FLAGS) -o $@
ifeq (.depend_d,$(wildcard .depend_d))
-include .depend_d
endif
ifeq (.depend_adm,$(wildcard .depend_adm))
-include .depend_adm
endif
%.o: %.c Makefile
$(CC) -c -o $(@) $(CFLAGS) $(<)
.depend_d:
$(CC) -M $(CFLAGS) $(SRCS_D) >$(@)
.depend_adm:
$(CC) -M $(CFLAGS) $(SRCS_ADM) >$(@)
clean:
rm -f *.o $(PROGRAMS) .depend*
extraclean: clean
rm -f *.orig *.rej