From b7508dce08a9136b508b88295d3f9127cd7de114 Mon Sep 17 00:00:00 2001 From: stansmith Date: Thu, 17 Jan 2008 23:13:14 +0000 Subject: [PATCH] [DAPL2] remove Linux Makefiles git-svn-id: svn://openib.tc.cornell.edu/gen1@927 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86 --- trunk/ulp/dapl2/dapl/udapl/Makefile.linux | 444 ---------------------- trunk/ulp/dapl2/dat/udat/Makefile.linux | 256 ------------- 2 files changed, 700 deletions(-) delete mode 100644 trunk/ulp/dapl2/dapl/udapl/Makefile.linux delete mode 100644 trunk/ulp/dapl2/dat/udat/Makefile.linux diff --git a/trunk/ulp/dapl2/dapl/udapl/Makefile.linux b/trunk/ulp/dapl2/dapl/udapl/Makefile.linux deleted file mode 100644 index 94569c68..00000000 --- a/trunk/ulp/dapl2/dapl/udapl/Makefile.linux +++ /dev/null @@ -1,444 +0,0 @@ -# -# Copyright (c) 2002-2005, Network Appliance, Inc. All rights reserved. -# -# This Software is licensed under one of the following licenses: -# -# 1) under the terms of the "Common Public License 1.0" a copy of which is -# in the file LICENSE.txt in the root directory. The license is also -# available from the Open Source Initiative, see -# http://www.opensource.org/licenses/cpl.php. -# -# 2) under the terms of the "The BSD License" a copy of which is in the file -# LICENSE2.txt in the root directory. The license is also available from -# the Open Source Initiative, see -# http://www.opensource.org/licenses/bsd-license.php. -# -# 3) under the terms of the "GNU General Public License (GPL) Version 2" a -# copy of which is in the file LICENSE3.txt in the root directory. The -# license is also available from the Open Source Initiative, see -# http://www.opensource.org/licenses/gpl-license.php. -# -# Licensee has the right to choose one of the above licenses. -# -# Redistributions of source code must retain the above copyright -# notice and one of the license notices. -# -# Redistributions in binary form must reproduce both the above copyright -# notice, one of the license notices in the documentation -# and/or other materials provided with the distribution. -# - -#********************************************************************** -# -# MODULE: Makefile -# -# PURPOSE: Makefile for dapl reference provider -# -# $Id: Makefile 1367 2005-12-05 16:48:37Z jlentini $ -#*********************************************************************/ - -TOPDIR = $(shell /bin/pwd) - -SRC_PATH = $(TOPDIR) -OBJ_PATH = $(TOPDIR)/Obj -TARGET_PATH = $(TOPDIR)/Target - -TARGET = $(TARGET_PATH)/libdapl.so -STATIC = $(TARGET_PATH)/libdapl.a -COMMON = $(TOPDIR)/../common -LINUX = $(TOPDIR)/../udapl/linux -CC = gcc - -MACH=$(shell uname -m) -OSRELEASE=$(shell expr `uname -r | cut -f1 -d.` \* 65536 + `uname -r | cut -f2 -d.`) - -# -# Set up the default provider -# -ifndef $VERBS -VERBS=openib_cma -endif - -# -# Set an OS Vendor -# -# OS_VENDOR = REDHAT_EL4 -# OS_VENDOR = SuSE -# - -# -# CFLAGS definition -# -# The makefile will build for multiple providers, but each provider -# must have a set of compiler definitions that include, but are not -# limited to: -# -# PROVIDER Directory of provider sources -# CFLAGS Compile time flags for build -# - -CFLAGS = -O2 $(CPPFLAGS) -DOS_VERSION=$(OSRELEASE) -DDAPL_DBG - -ifdef OS_VENDOR -CFLAGS += -D$(OS_VENDOR) -endif - -# -# dummy provider -# -ifeq ($(VERBS),dummy) -PROVIDER = $(TOPDIR)/../dummy -CFLAGS += -DDAPL_ATS -DDUMMY -endif - -# -# JNI Provider -# -ifeq ($(VERBS),jni) -PROVIDER = $(TOPDIR)/../ibapi -CFLAGS += -DDAPL_ATS -DIBAPI # -DCM_BUSTED -CFLAGS += -I../include/ib/IBM -CFLAGS += -I../include/ib/IBM/us -endif - -# -# Mellanox Provider -# -ifeq ($(VERBS),mellanox) -DAPL_IBLIB_DIR = /usr/mellanox/lib -PROVIDER = $(TOPDIR)/../vapi -CFLAGS += -DVAPI -DSMR_BUSTED # -DCM_BUSTED # -DMW_BUSTED -#CFLAGS += -DIBHOSTS_NAMING -#CFLAGS += -I/usr/mellanox/include -CFLAGS += -I../include/ib/MELLANOX -endif - -# -# OpenIB Gen one provider -# -ifeq ($(VERBS),openib_gen_one) -OPENIB_UNAME=$(shell uname -r) - -OPENIB_USER_DIR ?= /usr/local/ibgd -OPENIB_KERNEL_DIR ?= /lib/modules/$(OPENIB_UNAME)/build/drivers/infiniband -OPENIB_THCA_DIR ?= $(OPENIB_USER_DIR)/driver/infinihost - -PROVIDER = $(TOPDIR)/../openib_gen_one -CFLAGS += -D__OPENIB__ -DSMR_BUSTED # -DMW_BUSTED -CFLAGS += -DDAPL_ATS -CFLAGS += -I$(OPENIB_KERNEL_DIR)/include -CFLAGS += -I$(OPENIB_KERNEL_DIR)/ulp/dapl_srv -CFLAGS += -I$(OPENIB_USER_DIR)/driver/infinihost/include -endif - -# -# OpenIB provider -# -ifeq ($(VERBS),openib) -PROVIDER = $(TOPDIR)/../openib -CFLAGS += -DOPENIB -CFLAGS += -DCQ_WAIT_OBJECT -CFLAGS += -I/usr/local/include/infiniband -endif - -# -# OpenIB provider with Socket CM -# -ifeq ($(VERBS),openib_scm) -PROVIDER = $(TOPDIR)/../openib_scm -CFLAGS += -DOPENIB -CFLAGS += -DCQ_WAIT_OBJECT -CFLAGS += -I/usr/local/include/infiniband -endif - -# -# OpenIB provider with IB CMA -# -ifeq ($(VERBS),openib_cma) -PROVIDER = $(TOPDIR)/../openib_cma -CFLAGS += -DOPENIB -CFLAGS += -DCQ_WAIT_OBJECT -CFLAGS += -DDAT_EXTENSIONS -CFLAGS += -I/usr/local/include/infiniband -endif - -# -# If an implementation supports CM and DTO completions on the same EVD -# then DAPL_MERGE_CM_DTO should be set -# CFLAGS += -DDAPL_MERGE_CM_DTO=1 - -# -# If an implementation supports Shared Memory, enable -# VN_MEM_SHARED_VIRTUAL_SUPPORT -# CFLAGS += -DVN_MEM_SHARED_VIRTUAL_SUPPORT=1 - -CFLAGS += -I. -CFLAGS += -I.. -CFLAGS += -I../../dat/include -CFLAGS += -I../include - -CFLAGS += -I$(PROVIDER) -CFLAGS += -I../udapl/linux -CFLAGS += -I../common -CFLAGS += -Wall -CFLAGS += -Wstrict-prototypes -CFLAGS += -Wmissing-prototypes -CFLAGS += -Wmissing-declarations -CFLAGS += --no-strict-aliasing -CFLAGS += -Werror -CFLAGS += -g3 -CFLAGS += -fPIC - -ifdef GPROF -CFLAGS += -pg -endif - -LD = ld - -# -# LDFLAGS definition -# -LDFLAGS = -shared -LDFLAGS += -lpthread -LDFLAGS += -init dapl_init -LDFLAGS += -fini dapl_fini -ifeq ($(OS_VENDOR),SuSE) -LDFLAGS += -lgcc_s -endif - - -AR = ar -# -# ARFLAGS definition -# -ARFLAGS = r - -# -# To build with JNI verbs: make VERBS=jni [default] -# To build with Mellanox verbs: make VERBS=mellanox -# To build with XYZ verbs: make VERBS=XYZ -# -# Verb libraries should be in /usr/lib or vendor specified directories -# - -# Allow specification in the environment of a location for the -# verbs library, to allow running DAPL without installing -# the verbs library in /usr/lib. For development. -ifneq (${DAPL_IBLIB_DIR},) -LDFLAGS += -L${DAPL_IBLIB_DIR} -R${DAPL_IBLIB_DIR} -endif - -ifeq ($(VERBS),dummy) -PROVIDER_SRCS = dapl_dummy_util.c -endif - -ifeq ($(VERBS),ibm) -CFLAGS += -D_IBM -DIBM -LDFLAGS += -lIBusd -LDFLAGS += -lIBlueHCAd -LDFLAGS += -ldl -PROVIDER_SRCS = dapl_ibapi_util.c dapl_ibapi_qp.c dapl_ibapi_cm.c -endif - -ifeq ($(VERBS),jni) -CFLAGS += -DJNI -LDFLAGS += -lJniTavorVerbs -LDFLAGS += -lpthread -LDFLAGS += -rpath /opt/JNIhca/lib/ -L /opt/JNIhca/lib/ -PROVIDER_SRCS = dapl_ibapi_util.c dapl_ibapi_qp.c dapl_ibapi_cm.c -endif - -ifeq ($(VERBS),mellanox) -CFLAGS += -DMTL_MODULE=M_dapl -DMAX_TRACE=8 -DMAX_DEBUG=8 -DMAX_ERROR=8 -PROVIDER_SRCS = dapl_vapi_util.c dapl_vapi_qp.c dapl_vapi_cm.c -LDFLAGS += -lvapi -LDFLAGS += -lmpga -LDFLAGS += -lmtl_common -LDFLAGS += -lcm -endif - -ifeq ($(VERBS),openib_gen_one) -CFLAGS += -DMTL_MODULE=M_dapl -DMAX_TRACE=8 -DMAX_DEBUG=8 -DMAX_ERROR=8 -LDFLAGS += -lvapi -LDFLAGS += -lmpga -LDFLAGS += -lmtl_common -LDFLAGS += -lcm -LDFLAGS += -L$(OPENIB_USER_DIR)/lib -L$(OPENIB_THCA_DIR)/lib -PROVIDER_SRCS = dapl_openib.c dapl_openib_qp.c -PROVIDER_SRCS += dapl_openib_util.c dapl_openib_cm.c dapl_openib_cm_util_user.c -endif - -ifeq ($(VERBS),openib) -LDFLAGS += -libverbs -libcm -libat -LDFLAGS += -rpath /usr/local/lib -L /usr/local/lib -PROVIDER_SRCS = dapl_ib_util.c dapl_ib_cq.c dapl_ib_qp.c -PROVIDER_SRCS += dapl_ib_cm.c dapl_ib_mem.c -endif - -ifeq ($(VERBS),openib_scm) -LDFLAGS += -libverbs -LDFLAGS += -rpath /usr/local/lib -L /usr/local/lib -PROVIDER_SRCS = dapl_ib_util.c dapl_ib_cq.c dapl_ib_qp.c \ - dapl_ib_cm.c dapl_ib_mem.c -endif - -ifeq ($(VERBS),openib_cma) -LDFLAGS += -libverbs -lrdmacm -LDFLAGS += -rpath /usr/local/lib -L /usr/local/lib -PROVIDER_SRCS = dapl_ib_util.c dapl_ib_cq.c dapl_ib_qp.c \ - dapl_ib_cm.c dapl_ib_mem.c -endif - -UDAPL_SRCS = dapl_init.c \ - dapl_evd_create.c \ - dapl_evd_query.c \ - dapl_cno_create.c \ - dapl_cno_modify_agent.c \ - dapl_cno_free.c \ - dapl_cno_wait.c \ - dapl_cno_query.c \ - dapl_lmr_create.c \ - dapl_evd_wait.c \ - dapl_evd_disable.c \ - dapl_evd_enable.c \ - dapl_evd_modify_cno.c \ - dapl_evd_set_unwaitable.c \ - dapl_evd_clear_unwaitable.c - -COMMON_SRCS = dapl_cookie.c \ - dapl_cr_accept.c \ - dapl_cr_query.c \ - dapl_cr_reject.c \ - dapl_cr_util.c \ - dapl_cr_callback.c \ - dapl_cr_handoff.c \ - dapl_ep_connect.c \ - dapl_ep_create.c \ - dapl_ep_disconnect.c \ - dapl_ep_dup_connect.c \ - dapl_ep_free.c \ - dapl_ep_reset.c \ - dapl_ep_get_status.c \ - dapl_ep_modify.c \ - dapl_ep_post_rdma_read.c \ - dapl_ep_post_rdma_write.c \ - dapl_ep_post_recv.c \ - dapl_ep_post_send.c \ - dapl_ep_query.c \ - dapl_ep_util.c \ - dapl_evd_dequeue.c \ - dapl_evd_free.c \ - dapl_evd_post_se.c \ - dapl_evd_resize.c \ - dapl_evd_util.c \ - dapl_evd_cq_async_error_callb.c \ - dapl_evd_qp_async_error_callb.c \ - dapl_evd_un_async_error_callb.c \ - dapl_evd_connection_callb.c \ - dapl_evd_dto_callb.c \ - dapl_get_consumer_context.c \ - dapl_get_handle_type.c \ - dapl_hash.c \ - dapl_hca_util.c \ - dapl_ia_close.c \ - dapl_ia_open.c \ - dapl_ia_query.c \ - dapl_ia_util.c \ - dapl_llist.c \ - dapl_lmr_free.c \ - dapl_lmr_query.c \ - dapl_lmr_util.c \ - dapl_lmr_sync_rdma_read.c \ - dapl_lmr_sync_rdma_write.c \ - dapl_mr_util.c \ - dapl_provider.c \ - dapl_sp_util.c \ - dapl_psp_create.c \ - dapl_psp_create_any.c \ - dapl_psp_free.c \ - dapl_psp_query.c \ - dapl_pz_create.c \ - dapl_pz_free.c \ - dapl_pz_query.c \ - dapl_pz_util.c \ - dapl_rmr_create.c \ - dapl_rmr_free.c \ - dapl_rmr_bind.c \ - dapl_rmr_query.c \ - dapl_rmr_util.c \ - dapl_rsp_create.c \ - dapl_rsp_free.c \ - dapl_rsp_query.c \ - dapl_cno_util.c \ - dapl_set_consumer_context.c \ - dapl_ring_buffer_util.c \ - dapl_name_service.c \ - dapl_timer_util.c \ - dapl_ep_create_with_srq.c \ - dapl_ep_recv_query.c \ - dapl_ep_set_watermark.c \ - dapl_srq_create.c \ - dapl_srq_free.c \ - dapl_srq_query.c \ - dapl_srq_resize.c \ - dapl_srq_post_recv.c \ - dapl_srq_set_lw.c \ - dapl_srq_util.c \ - dapl_debug.c - -LINUX_SRCS = dapl_osd.c - -SRCS = $(UDAPL_SRCS) $(COMMON_SRCS) $(LINUX_SRCS) $(PROVIDER_SRCS) - -UDAPL_OBJS = $(UDAPL_SRCS:%.c=$(OBJ_PATH)/%.o) -COMMON_OBJS = $(COMMON_SRCS:%.c=$(OBJ_PATH)/%.o) -LINUX_OBJS = $(LINUX_SRCS:%.c=$(OBJ_PATH)/%.o) -PROVIDER_OBJS = $(PROVIDER_SRCS:%.c=$(OBJ_PATH)/%.o) - -OBJS = $(UDAPL_OBJS) $(COMMON_OBJS) $(LINUX_OBJS) $(PROVIDER_OBJS) - - -all: mkdirs $(TARGET) $(STATIC) MAKE_DONE - -mkdirs: - @[ -d $(TARGET_PATH) ] || /bin/mkdir -p $(TARGET_PATH) - @[ -d $(OBJ_PATH) ] || /bin/mkdir -p $(OBJ_PATH) - -$(UDAPL_OBJS): $(OBJ_PATH)/%.o : %.c - @echo Compiling $< - $(CC) $(CFLAGS) -c $< -o $@ - -$(COMMON_OBJS): $(OBJ_PATH)/%.o : $(COMMON)/%.c - @echo Compiling $< - $(CC) $(CFLAGS) -c $< -o $@ - -$(LINUX_OBJS): $(OBJ_PATH)/%.o : $(LINUX)/%.c - @echo Compiling $< - $(CC) $(CFLAGS) -c $< -o $@ - -$(PROVIDER_OBJS): $(OBJ_PATH)/%.o : $(PROVIDER)/%.c - @echo Compiling $< - $(CC) $(CFLAGS) -c $< -o $@ - -$(TARGET): $(OBJS) - @echo Linking $(TARGET) - $(LD) $(LDFLAGS) $^ -o $(TARGET) - -$(STATIC): $(OBJS) - @echo Archiving $(STATIC) - @$(AR) $(ARFLAGS) $(STATIC) $^ - -MAKE_DONE: - @echo "--- Make done ----" - -clean: - rm -f $(OBJS) - rm -f $(TARGET) $(STATIC) - -tidy: - rm -f *~ - rm -f ../common/*~ - rm -f ../include/*~ - rm -f ../vapi/*~ - rm -f ../ibapi/*~ - rm -f linux/*~ diff --git a/trunk/ulp/dapl2/dat/udat/Makefile.linux b/trunk/ulp/dapl2/dat/udat/Makefile.linux deleted file mode 100644 index 3947588e..00000000 --- a/trunk/ulp/dapl2/dat/udat/Makefile.linux +++ /dev/null @@ -1,256 +0,0 @@ -# -# Copyright (c) 2002-2005, Network Appliance, Inc. All rights reserved. -# -# This Software is licensed under one of the following licenses: -# -# 1) under the terms of the "Common Public License 1.0" a copy of which is -# in the file LICENSE.txt in the root directory. The license is also -# available from the Open Source Initiative, see -# http://www.opensource.org/licenses/cpl.php. -# -# 2) under the terms of the "The BSD License" a copy of which is in the file -# LICENSE2.txt in the root directory. The license is also available from -# the Open Source Initiative, see -# http://www.opensource.org/licenses/bsd-license.php. -# -# 3) under the terms of the "GNU General Public License (GPL) Version 2" a -# copy of which is in the file LICENSE3.txt in the root directory. The -# license is also available from the Open Source Initiative, see -# http://www.opensource.org/licenses/gpl-license.php. -# -# Licensee has the right to choose one of the above licenses. -# -# Redistributions of source code must retain the above copyright -# notice and one of the license notices. -# -# Redistributions in binary form must reproduce both the above copyright -# notice, one of the license notices in the documentation -# and/or other materials provided with the distribution. -# - -#********************************************************************* -# -# MODULE: Makefile -# -# PURPOSE: Makefile for DAT registration module -# -# $Id: Makefile 1301 2005-03-24 05:58:55Z jlentini $ -#*********************************************************************/ - - -#AT = @ -ARCH := $(shell uname -m) -UDAT_ROOT := $(shell /bin/pwd) -UDAT_LINUX := $(UDAT_ROOT)/linux -UDAT_COMMON := $(UDAT_ROOT)/../common - -DAT_ROOT := $(UDAT_ROOT)/.. -DAT_HEADERS := $(DAT_ROOT)/include -DAT_HEADERS_SYSTEM_PATH := $(PREFIX)/usr/include/dat - -VPATH = $(UDAT_ROOT) $(UDAT_LINUX) $(UDAT_COMMON) - -OBJ_PATH = $(UDAT_ROOT)/Obj/$(ARCH) -TARGET_PATH = $(UDAT_ROOT)/Target/$(ARCH) -OBJ_PATH32 = $(UDAT_ROOT)/Obj/$(ARCH).32bit -TARGET_PATH32 = $(UDAT_ROOT)/Target/$(ARCH).32bit - -STATIC = $(TARGET_PATH)/libdat.a -DYNAMIC = $(TARGET_PATH)/libdat.so -STATIC32 = $(TARGET_PATH32)/libdat.a -DYNAMIC32 = $(TARGET_PATH32)/libdat.so - -ifeq "$(ARCH)" "x86_64" -#DUAL_ARCH = true -endif - -OBJS = $(OBJ_PATH)/udat.o \ - $(OBJ_PATH)/udat_api.o \ - $(OBJ_PATH)/dat_api.o \ - $(OBJ_PATH)/dat_osd.o \ - $(OBJ_PATH)/dat_dictionary.o \ - $(OBJ_PATH)/dat_dr.o \ - $(OBJ_PATH)/dat_init.o \ - $(OBJ_PATH)/dat_sr.o \ - $(OBJ_PATH)/udat_sr_parser.o \ - $(OBJ_PATH)/dat_strerror.o - -OBJS32= $(OBJ_PATH32)/udat.o \ - $(OBJ_PATH32)/udat_api.o \ - $(OBJ_PATH32)/dat_api.o \ - $(OBJ_PATH32)/dat_osd.o \ - $(OBJ_PATH32)/dat_dictionary.o \ - $(OBJ_PATH32)/dat_dr.o \ - $(OBJ_PATH32)/dat_init.o \ - $(OBJ_PATH32)/dat_sr.o \ - $(OBJ_PATH32)/udat_sr_parser.o \ - $(OBJ_PATH32)/dat_strerror.o - -# -# CC definitions -# - -CC = gcc - -CFLAGS = -O $(CPPFLAGS) -CFLAGS += -g3 -CFLAGS += -fPIC -CFLAGS += -I. -CFLAGS += -I../common -CFLAGS += -I./linux -CFLAGS += -I$(DAT_HEADERS) -CFLAGS += -Wall -CFLAGS += -Wstrict-prototypes -CFLAGS += -Wmissing-prototypes -CFLAGS += -Wmissing-declarations -CFLAGS += -Werror -ifdef GPROF -CFLAGS += -pg -endif -ifeq "$(ARCH)" "x86_64" -CFLAGS32 = -m32 -endif - -CFLAGS += -DDAT_EXTENSIONS - -# -# LD definitions -# - -LD = gcc - -LDFLAGS = -shared -LDFLAGS += -ldl -ifeq "$(ARCH)" "x86_64" -LDFLAGS32 = -m32 -endif - - -# -# AR definitions -# - -AR = ar - -ARFLAGS = r - - -# -# install definitions -# - -INSTALL = install - -INSTALL_FLAGS += -p - - -# -# rpm definitions -# - -RPM_FILE = dat-registry-1.1 -RPM_PATH = /tmp/$(RPM_FILE)-build - - -# -# Rules -# - -ifdef DUAL_ARCH -all: mkdirs $(DYNAMIC) $(STATIC) $(DYNAMIC32) $(STATIC32) -else -all: mkdirs $(DYNAMIC) $(STATIC) -endif - -mkdirs: - $(AT)[ -d $(TARGET_PATH) ] || /bin/mkdir -p $(TARGET_PATH) - $(AT)[ -d $(OBJ_PATH) ] || /bin/mkdir -p $(OBJ_PATH) -ifdef DUAL_ARCH - $(AT)[ -d $(TARGET_PATH32) ] || /bin/mkdir -p $(TARGET_PATH32) - $(AT)[ -d $(OBJ_PATH32) ] || /bin/mkdir -p $(OBJ_PATH32) -endif - -$(OBJ_PATH)/%.o : %.c - @echo Compiling $< - $(AT)$(CC) $(CFLAGS) -c $< -o $@ - -$(OBJ_PATH32)/%.o : %.c - @echo Compiling $< - $(AT)$(CC) $(CFLAGS) $(CFLAGS32) -c $< -o $@ - -$(DYNAMIC): $(OBJS) - @echo Linking $(DYNAMIC) - $(AT)$(LD) $(LDFLAGS) $^ -o $(DYNAMIC) - -$(DYNAMIC32): $(OBJS32) - @echo Linking $(DYNAMIC32) - $(AT)$(LD) $(LDFLAGS) $(LDFLAGS32) $^ -o $(DYNAMIC32) - -$(STATIC): $(OBJS) - @echo Archiving $(STATIC) - $(AT)$(AR) $(ARFLAGS) $(STATIC) $^ - -$(STATIC32): $(OBJS32) - @echo Archiving $(STATIC32) - $(AT)$(AR) $(ARFLAGS) $(STATIC32) $^ - -rpm: mkdirs - @echo Creating RPM - $(AT)if [ -d $(RPM_PATH) ]; then rm -rf $(RPM_PATH); fi; \ - mkdir $(RPM_PATH); \ - mkdir $(RPM_PATH)/SOURCES; \ - mkdir $(RPM_PATH)/BUILD; \ - mkdir $(RPM_PATH)/RPMS; \ - mkdir $(RPM_PATH)/SPECS; \ - case `uname -m` in \ - i?86*) ARCH_DIR=i386;;\ - ia64*) ARCH_DIR=ia64;;\ - x86_64*) ARCH_DIR=x86_64;;\ - *) echo "Unknown architecture: `uname -m`"; exit 1;;\ - esac;\ - mkdir $(RPM_PATH)/RPMS/$$ARCH_DIR; \ - echo "%_topdir $(RPM_PATH)" > $(RPM_PATH)/rpmmacros; \ - echo "macrofiles: /usr/lib/rpm/macros:/etc/rpm/macros:$(RPM_PATH)/rpmmacros" > $(RPM_PATH)/rpmrc; \ - cd $(DAT_ROOT)/..; tar zcvf $(RPM_PATH)/SOURCES/$(RPM_FILE).tgz dat/* --exclude dat/udat/Target --exclude dat/udat/Obj; \ - install -m 644 $(UDAT_LINUX)/$(RPM_FILE).spec $(RPM_PATH)/SPECS/; \ - if [ -f /usr/bin/rpmbuild ]; then \ - RPMBUILD=/usr/bin/rpmbuild;\ - else\ - RPMBUILD=rpm;\ - fi;\ - $$RPMBUILD -bb --rcfile $(RPM_PATH)/rpmrc --target=$$ARCH_DIR $(RPM_PATH)/SPECS/$(RPM_FILE).spec; \ - if [ $$? != 0 ]; then \ - echo "### ERROR: rpm failed:"; \ - exit 1; \ - fi; \ - mv $(RPM_PATH)/RPMS/$$ARCH_DIR/*.rpm $(TARGET_PATH); \ - rm -rf $(RPM_PATH) - -install: all -ifdef DUAL_ARCH - $(INSTALL) $(INSTALL_FLAGS) -m 755 $(DYNAMIC32) $(PREFIX)/usr/lib/libdat.so - $(INSTALL) $(INSTALL_FLAGS) -m 644 $(STATIC32) $(PREFIX)/usr/lib/libdat.a - $(INSTALL) $(INSTALL_FLAGS) -m 755 $(DYNAMIC) $(PREFIX)/usr/lib64/libdat.so - $(INSTALL) $(INSTALL_FLAGS) -m 644 $(STATIC) $(PREFIX)/usr/lib64/libdat.a -else - $(INSTALL) $(INSTALL_FLAGS) -m 755 $(DYNAMIC) $(PREFIX)/usr/lib - $(INSTALL) $(INSTALL_FLAGS) -m 644 $(STATIC) $(PREFIX)/usr/lib -endif - $(INSTALL) $(INSTALL_FLAGS) -m 755 -d $(DAT_HEADERS_SYSTEM_PATH) - $(INSTALL) $(INSTALL_FLAGS) -m 644 $(DAT_HEADERS)/dat/*.h $(DAT_HEADERS_SYSTEM_PATH) - -clean: - rm -f $(OBJ_PATH)/*.o - rm -f $(TARGET_PATH)/*.rpm - rm -f $(DYNAMIC) - rm -f $(STATIC) -ifdef DUAL_ARCH - rm -f $(OBJ_PATH32)/*.o - rm -f $(DYNAMIC32) - rm -f $(STATIC32) -endif - -tidy: - rm -f $(UDAT_ROOT)/*~ - rm -f $(UDAT_LINUX)/*~ - rm -f $(UDAT_COMMON)/*~ -- 2.41.0