2011-03-31 16:19:35 +02:00
|
|
|
# Copyright (c) 2006, 2008, 2009, 2011 Red Hat, Inc.
|
2006-11-27 14:05:54 +01:00
|
|
|
#
|
|
|
|
# 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; either version 2 of the License, or
|
|
|
|
# (at your option) any later version.
|
|
|
|
#
|
|
|
|
# A copy of the GNU General Public License can be found at
|
|
|
|
# http://www.gnu.org/
|
|
|
|
#
|
|
|
|
# Written by Corinna Vinschen <vinschen@redhat.de>
|
|
|
|
#
|
|
|
|
# Makefile for Cygwin subauthentication DLL.
|
|
|
|
|
|
|
|
SHELL := @SHELL@
|
|
|
|
|
|
|
|
srcdir := @srcdir@
|
|
|
|
VPATH := @srcdir@
|
|
|
|
prefix := @prefix@
|
|
|
|
exec_prefix := @exec_prefix@
|
|
|
|
|
|
|
|
bindir := @bindir@
|
|
|
|
etcdir := $(exec_prefix)/etc
|
|
|
|
|
|
|
|
INSTALL := @INSTALL@
|
|
|
|
INSTALL_PROGRAM := @INSTALL_PROGRAM@
|
|
|
|
INSTALL_DATA := @INSTALL_DATA@
|
|
|
|
|
|
|
|
CC := @CC@
|
|
|
|
CC_FOR_TARGET := $(CC)
|
|
|
|
|
|
|
|
CFLAGS := @CFLAGS@
|
|
|
|
|
|
|
|
include $(srcdir)/../Makefile.common
|
|
|
|
|
|
|
|
WIN32_INCLUDES := -I. -I$(srcdir) $(w32api_include) $(w32api_include)/ddk
|
|
|
|
WIN32_CFLAGS := $(CFLAGS) $(WIN32_COMMON) $(WIN32_INCLUDES)
|
|
|
|
WIN32_LDFLAGS := $(CFLAGS) $(WIN32_COMMON) -nostdlib -Wl,-shared
|
|
|
|
|
2008-10-13 01:53:26 +02:00
|
|
|
ifdef MINGW_CC
|
|
|
|
override CC:=${MINGW_CC}
|
|
|
|
endif
|
|
|
|
|
2012-05-29 14:46:01 +02:00
|
|
|
# Never again try to remove advapi32. It does not matter if the DLL calls
|
|
|
|
# advapi32 functions or the equivalent ntdll functions.
|
|
|
|
# But if the LSA authentication DLL is not linked against advapi32, it's
|
|
|
|
# not recognized by LSA.
|
|
|
|
LIBS := -ladvapi32 -lkernel32 -lntdll
|
2006-11-27 14:05:54 +01:00
|
|
|
|
|
|
|
DLL := cyglsa.dll
|
|
|
|
DEF_FILE:= cyglsa.def
|
|
|
|
|
|
|
|
OBJ = cyglsa.o
|
|
|
|
|
|
|
|
.SUFFIXES:
|
|
|
|
.NOEXPORT:
|
|
|
|
|
|
|
|
all: Makefile $(DLL)
|
|
|
|
|
|
|
|
$(DEF_FILE): cyglsa.din config.status
|
|
|
|
$(SHELL) config.status
|
|
|
|
|
|
|
|
$(DLL): $(OBJ) $(DEF_FILE)
|
2008-10-13 01:53:26 +02:00
|
|
|
$(CC) -s $(WIN32_LDFLAGS) -o $@ $^ $(LIBS)
|
2006-11-27 14:05:54 +01:00
|
|
|
|
|
|
|
.PHONY: all install clean realclean
|
|
|
|
|
|
|
|
realclean: clean
|
|
|
|
rm -f Makefile config.cache
|
|
|
|
|
|
|
|
clean:
|
2011-03-31 16:19:35 +02:00
|
|
|
rm -f *.o *.dll cyglsa.def
|
2006-11-27 14:05:54 +01:00
|
|
|
|
|
|
|
install: all
|
2009-02-24 03:11:14 +01:00
|
|
|
$(SHELL) $(updir1)/mkinstalldirs $(DESTDIR)$(bindir)
|
|
|
|
$(INSTALL_PROGRAM) $(DLL) $(DESTDIR)$(bindir)/$(DLL)
|
|
|
|
$(INSTALL_PROGRAM) $(srcdir)/cyglsa64.dll $(DESTDIR)$(bindir)/cyglsa64.dll
|
|
|
|
$(INSTALL_PROGRAM) $(srcdir)/cyglsa-config $(DESTDIR)$(bindir)/cyglsa-config
|
2006-11-27 14:05:54 +01:00
|
|
|
|
|
|
|
%.o: %.c
|
|
|
|
$(CC) $(WIN32_CFLAGS) -c -o $@ $<
|