2016-05-13 15:58:30 +00:00
|
|
|
# -*-makefile-gmake-*-
|
2002-02-27 16:27:08 +00:00
|
|
|
# Instance/framework.make
|
|
|
|
#
|
|
|
|
# Instance Makefile rules to build GNUstep-based frameworks.
|
|
|
|
#
|
2010-02-07 19:56:09 +00:00
|
|
|
# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2010 Free Software Foundation, Inc.
|
2002-02-27 16:27:08 +00:00
|
|
|
#
|
|
|
|
# Author: Mirko Viviani <mirko.viviani@rccr.cremona.it>
|
2010-02-07 19:56:09 +00:00
|
|
|
# Author: Nicola Pero <nicola.pero@meta-innovation.com>
|
2002-02-27 16:27:08 +00:00
|
|
|
#
|
|
|
|
# This file is part of the GNUstep Makefile Package.
|
|
|
|
#
|
|
|
|
# This library is free software; you can redistribute it and/or
|
|
|
|
# modify it under the terms of the GNU General Public License
|
2007-10-30 14:18:41 +00:00
|
|
|
# as published by the Free Software Foundation; either version 3
|
2002-02-27 16:27:08 +00:00
|
|
|
# of the License, or (at your option) any later version.
|
|
|
|
#
|
|
|
|
# You should have received a copy of the GNU General Public
|
2007-07-13 10:11:48 +00:00
|
|
|
# License along with this library; see the file COPYING.
|
2002-02-27 16:27:08 +00:00
|
|
|
# If not, write to the Free Software Foundation,
|
2005-05-22 03:20:14 +00:00
|
|
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2008-02-19 10:49:20 +00:00
|
|
|
# Frameworks usually link against a gui library (if available). If
|
2008-03-11 01:06:50 +00:00
|
|
|
# you don't need a gui library, use xxx_NEEDS_GUI = no.
|
2008-02-19 14:15:08 +00:00
|
|
|
ifeq ($(NEEDS_GUI),)
|
2008-03-11 01:06:50 +00:00
|
|
|
NEEDS_GUI = yes
|
2008-02-19 14:15:08 +00:00
|
|
|
endif
|
2008-02-19 10:49:20 +00:00
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
ifeq ($(RULES_MAKE_LOADED),)
|
|
|
|
include $(GNUSTEP_MAKEFILES)/rules.make
|
|
|
|
endif
|
|
|
|
|
2006-09-19 00:45:34 +00:00
|
|
|
.PHONY: internal-framework-all_ \
|
|
|
|
build-framework \
|
|
|
|
internal-framework-build-headers \
|
|
|
|
build-framework-dirs \
|
|
|
|
internal-framework-install_ \
|
|
|
|
internal-framework-distclean \
|
|
|
|
internal-framework-clean \
|
2009-02-23 11:12:11 +00:00
|
|
|
internal-framework-uninstall_ \
|
|
|
|
internal-framework-run-compile-submake \
|
|
|
|
internal-framework-compile
|
2002-03-19 13:06:56 +00:00
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
# The name of the framework is in the FRAMEWORK_NAME variable.
|
|
|
|
# The list of framework resource files are in xxx_RESOURCE_FILES
|
|
|
|
# The list of framework web server resource files are in
|
|
|
|
# xxx_WEBSERVER_RESOURCE_FILES
|
|
|
|
# The list of localized framework resource files is in
|
|
|
|
# xxx_LOCALIZED_RESOURCE_FILES
|
|
|
|
# The list of localized framework web server resource files is in
|
2002-06-13 11:04:30 +00:00
|
|
|
# xxx_WEBSERVER_LOCALIZED_RESOURCE_FILES
|
2002-02-27 16:27:08 +00:00
|
|
|
# The list of framework GSWeb components are in xxx_COMPONENTS
|
|
|
|
# The list of languages the framework supports is in xxx_LANGUAGES
|
|
|
|
# The list of framework resource directories are in xxx_RESOURCE_DIRS
|
|
|
|
# The list of framework subprojects directories are in xxx_SUBPROJECTS
|
|
|
|
# The name of the principal class is xxx_PRINCIPAL_CLASS
|
|
|
|
# The header files are in xxx_HEADER_FILES
|
2002-12-02 12:44:55 +00:00
|
|
|
# The directory where the header files are located is xxx_HEADER_FILES_DIR
|
|
|
|
# (defaults to ./)
|
|
|
|
# The directory where to install the header files inside the library
|
|
|
|
# installation directory is xxx_HEADER_FILES_INSTALL_DIR
|
2003-03-31 16:53:05 +00:00
|
|
|
# (defaults to the framework name [without .framework]). Can't be `.'
|
2002-02-27 16:27:08 +00:00
|
|
|
# The list of framework web server resource directories are in
|
|
|
|
# xxx_WEBSERVER_RESOURCE_DIRS
|
|
|
|
# The list of localized framework web server GSWeb components are in
|
2002-06-13 11:04:30 +00:00
|
|
|
# xxx_WEBSERVER_LOCALIZED_RESOURCE_DIRS
|
2008-05-24 13:12:15 +00:00
|
|
|
# xxx_CURRENT_VERSION_NAME is the compiled version name (default "0")
|
2004-03-04 13:19:33 +00:00
|
|
|
# xxx_MAKE_CURRENT_VERSION is used to decide if the framework version
|
|
|
|
# we compiling should be made the current/default version or not
|
|
|
|
# (default is "yes")
|
2015-10-20 13:33:17 +00:00
|
|
|
# xxx_TEST_DIR is the directory in which 'make check' will cause tests
|
|
|
|
# to be run using gnustep-tests.
|
2002-02-27 16:27:08 +00:00
|
|
|
#
|
|
|
|
# where xxx is the framework name
|
|
|
|
#
|
2002-12-02 12:44:55 +00:00
|
|
|
#
|
2003-03-31 16:53:05 +00:00
|
|
|
# The HEADER_FILES_INSTALL_DIR might look somewhat weird - because in
|
|
|
|
# most if not all cases, you want it to be the framework name. At the
|
2002-12-02 12:44:55 +00:00
|
|
|
# moment, it allows you to put headers for framework XXX in directory
|
|
|
|
# YYY, so that you can refer to them by using #include
|
|
|
|
# <YYY/MyHeader.h> rather than #include <XXX/MyHeader.h>. It seems to
|
|
|
|
# be mostly used to have a framework with name XXX work as a drop-in
|
|
|
|
# replacement for another framework, which has name YYY -- and which
|
|
|
|
# might be installed at the same time :-).
|
|
|
|
#
|
2008-10-21 11:18:05 +00:00
|
|
|
# If you want to insert your own entries into Info.plist (or
|
|
|
|
# Info-gnustep.plist) you should create a xxxInfo.plist file (where
|
|
|
|
# xxx is the framework name) and gnustep-make will automatically
|
|
|
|
# read it and merge it into Info-gnustep.plist.
|
|
|
|
#
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2007-03-13 19:15:19 +00:00
|
|
|
# Set VERSION from xxx_VERSION
|
|
|
|
ifneq ($($(GNUSTEP_INSTANCE)_VERSION),)
|
|
|
|
VERSION = $($(GNUSTEP_INSTANCE)_VERSION)
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(VERSION),)
|
|
|
|
VERSION = 0.0.1
|
|
|
|
endif
|
|
|
|
|
|
|
|
# By setting xxx_INTERFACE_VERSION you can change the soversion used
|
|
|
|
# when linking the library. See comments in library.make for the
|
|
|
|
# variables with the same name for libraries.
|
|
|
|
ifeq ($($(GNUSTEP_INSTANCE)_INTERFACE_VERSION),)
|
|
|
|
# By default, if VERSION is 1.0.0, INTERFACE_VERSION is 1
|
|
|
|
INTERFACE_VERSION = $(word 1,$(subst ., ,$(VERSION)))
|
|
|
|
else
|
|
|
|
INTERFACE_VERSION = $($(GNUSTEP_INSTANCE)_INTERFACE_VERSION)
|
|
|
|
endif
|
|
|
|
|
|
|
|
# CURRENT_VERSION_NAME is the name of the version as used when
|
|
|
|
# building the library structure. We recommend just using
|
|
|
|
# INTERFACE_VERSION for that, so your resources and your shared
|
|
|
|
# library have the same versioning.
|
|
|
|
|
2002-11-06 13:25:19 +00:00
|
|
|
# Warning - the following variable is also used in Master/rules.make
|
|
|
|
# to build the OWNING_PROJECT_HEADER_DIR for the framework's
|
|
|
|
# subprojects. Make sure you keep them in sync if you change them.
|
|
|
|
CURRENT_VERSION_NAME = $($(GNUSTEP_INSTANCE)_CURRENT_VERSION_NAME)
|
|
|
|
ifeq ($(CURRENT_VERSION_NAME),)
|
2007-03-13 19:15:19 +00:00
|
|
|
CURRENT_VERSION_NAME = $(INTERFACE_VERSION)
|
2002-11-06 13:25:19 +00:00
|
|
|
endif
|
|
|
|
|
2004-03-04 13:31:40 +00:00
|
|
|
# xxx_MAKE_CURRENT_VERSION can be set to 'no' if you do not want the
|
|
|
|
# framework version that we are building from becoming the Current
|
|
|
|
# one.
|
2004-03-04 13:19:33 +00:00
|
|
|
ifneq ($($(GNUSTEP_INSTANCE)_MAKE_CURRENT_VERSION),)
|
|
|
|
MAKE_CURRENT_VERSION = $($(GNUSTEP_INSTANCE)_MAKE_CURRENT_VERSION)
|
2002-11-06 13:25:19 +00:00
|
|
|
endif
|
|
|
|
|
2004-03-04 13:19:33 +00:00
|
|
|
ifeq ($(MAKE_CURRENT_VERSION),)
|
|
|
|
MAKE_CURRENT_VERSION = yes
|
2002-11-06 13:25:19 +00:00
|
|
|
endif
|
|
|
|
|
2005-07-20 16:00:07 +00:00
|
|
|
# If there are no working symlinks, common.make sets
|
|
|
|
# FRAMEWORK_VERSION_SUPPORT to no, which unconditionally turn
|
|
|
|
# versioning off. This means that we create no symlinks inside the
|
|
|
|
# xxx.framework directory for the various versions; that everything is
|
|
|
|
# put top-level as in the case of bundles. So with
|
|
|
|
# FRAMEWORK_VERSION_SUPPORT = no, the Directory structure is:
|
2005-07-14 16:00:52 +00:00
|
|
|
#
|
|
|
|
# xxx.framework/libframework.dll.a
|
|
|
|
# xxx.framework/framework.dll
|
|
|
|
# xxx.framework/Resources
|
|
|
|
# xxx.framework/Headers
|
|
|
|
#
|
|
|
|
# The Headers, libframework.dll.a and framework.dll are then copied into
|
|
|
|
# the standard header/library locations so that they can be found by
|
|
|
|
# compiler/linker. Given that there are no symlinks, there is no other
|
|
|
|
# way of doing this.
|
2005-07-20 16:00:07 +00:00
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT),no)
|
2005-07-14 16:00:52 +00:00
|
|
|
MAKE_CURRENT_VERSION = no
|
|
|
|
endif
|
|
|
|
|
2003-11-03 22:58:01 +00:00
|
|
|
# This is used on Apple to build frameworks which can be embedded into
|
|
|
|
# applications. You usually set it to something like
|
|
|
|
# @executable_path/../Frameworks and then you can embed the framework
|
|
|
|
# in an application.
|
|
|
|
DYLIB_INSTALL_NAME_BASE = $($(GNUSTEP_INSTANCE)_DYLIB_INSTALL_NAME_BASE)
|
|
|
|
|
2002-11-06 13:25:19 +00:00
|
|
|
FRAMEWORK_DIR_NAME = $(GNUSTEP_INSTANCE).framework
|
2003-10-13 23:25:23 +00:00
|
|
|
FRAMEWORK_DIR = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_DIR_NAME)
|
2005-07-14 16:00:52 +00:00
|
|
|
|
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
|
|
|
FRAMEWORK_VERSION_DIR_NAME = $(FRAMEWORK_DIR_NAME)/Versions/$(CURRENT_VERSION_NAME)
|
|
|
|
else
|
|
|
|
FRAMEWORK_VERSION_DIR_NAME = $(FRAMEWORK_DIR_NAME)
|
|
|
|
endif
|
|
|
|
|
2003-10-13 23:25:23 +00:00
|
|
|
FRAMEWORK_VERSION_DIR = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_VERSION_DIR_NAME)
|
2002-11-06 13:25:19 +00:00
|
|
|
|
2005-04-06 12:02:18 +00:00
|
|
|
# This is not doing much at the moment, it is only defining
|
2010-02-07 19:56:09 +00:00
|
|
|
# HEADER_FILES, HEADER_SUBDIRS, HEADER_FILES_DIR and
|
|
|
|
# HEADER_FILES_INSTALL_DIR in the standard way. Please note that
|
|
|
|
# HEADER_FILES might be empty even if we have headers in subprojects
|
|
|
|
# that we need to manage and install. So we assume by default that we
|
|
|
|
# have some headers even if HEADER_FILES is empty.
|
2002-12-02 12:44:55 +00:00
|
|
|
include $(GNUSTEP_MAKEFILES)/Instance/Shared/headers.make
|
2016-07-08 13:09:17 +00:00
|
|
|
include $(GNUSTEP_MAKEFILES)/Instance/Shared/pkgconfig.make
|
2002-03-05 15:09:58 +00:00
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
# On windows, this is unfortunately required.
|
|
|
|
ifeq ($(BUILD_DLL), yes)
|
|
|
|
LINK_AGAINST_ALL_LIBS = yes
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(LINK_AGAINST_ALL_LIBS), yes)
|
2008-02-19 10:49:20 +00:00
|
|
|
# Link against all libs ... but not the one we're compiling! (not sure
|
|
|
|
# when this could happen with frameworks, anyway it makes sense)
|
|
|
|
LIBRARIES_DEPEND_UPON += $(filter-out -l$(GNUSTEP_INSTANCE), $(ALL_LIBS))
|
2005-07-14 16:00:52 +00:00
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
|
|
|
INTERNAL_LIBRARIES_DEPEND_UPON = \
|
|
|
|
$(ALL_LIB_DIRS) \
|
2006-09-08 11:19:09 +00:00
|
|
|
$(LIBRARIES_DEPEND_UPON)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
ifeq ($(FOUNDATION_LIB),gnu)
|
2005-07-12 14:09:13 +00:00
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
# On GNUstep, build our dummy class to store information which
|
2005-07-12 14:09:13 +00:00
|
|
|
# gnustep-base can find at run time.
|
|
|
|
|
|
|
|
# An ObjC class name can not contain '-', but some people '-' this
|
|
|
|
# in framework names. So we need to encode the '-' in some way
|
|
|
|
# into an ObjC class name. (since we're there, we also encode '+'
|
|
|
|
# even if that's not really common).
|
|
|
|
|
|
|
|
# What we do is, we use '_' as an escape character, and encode (in the
|
|
|
|
# order) as follows:
|
|
|
|
#
|
|
|
|
# '_' is converted to '__'
|
|
|
|
# '-' is converted to '_0'
|
|
|
|
# '+' is converted to '_1'
|
|
|
|
#
|
|
|
|
|
|
|
|
# For example, 'Renaissance-Experimental' becomes
|
|
|
|
# 'Renaissance_0Experimental'.
|
|
|
|
|
|
|
|
# GNUstep-base will convert the name back by applying the reverse rules
|
|
|
|
# in the reverse order.
|
|
|
|
|
|
|
|
DUMMY_FRAMEWORK = NSFramework_$(subst +,_1,$(subst -,_0,$(subst _,__,$(GNUSTEP_INSTANCE))))
|
2003-10-13 23:25:23 +00:00
|
|
|
DUMMY_FRAMEWORK_FILE = $(DERIVED_SOURCES_DIR)/$(DUMMY_FRAMEWORK).m
|
2010-02-12 09:19:25 +00:00
|
|
|
DUMMY_FRAMEWORK_OBJ_FILE = $(addprefix $(GNUSTEP_OBJ_INSTANCE_DIR)/,$(DUMMY_FRAMEWORK).o)
|
2003-10-20 13:47:54 +00:00
|
|
|
|
|
|
|
# The following file will hold the list of classes compiled into the
|
|
|
|
# framework, ready to be included in the .plist file. We include the
|
|
|
|
# list of classes twice, in the object file itself (for when the
|
|
|
|
# framework is loaded) and in the .plist (for tools which let you
|
|
|
|
# browse in frameworks on disk and see lists of classes). Please note
|
|
|
|
# that reading the class list from the .plist requires gnustep-base to
|
|
|
|
# have properly located the framework bundle on disk, while reading
|
|
|
|
# the list from the object file itself does not (and so it's more
|
|
|
|
# likely to work in a portable way), which is why we still save the
|
|
|
|
# list in the object file rather than only putting it in the .plist.
|
|
|
|
# Maybe this point should be discarded, and we should only store the class
|
|
|
|
# list in the .plist file.
|
|
|
|
DUMMY_FRAMEWORK_CLASS_LIST = $(DERIVED_SOURCES_DIR)/$(GNUSTEP_INSTANCE)-class-list
|
2002-12-25 02:08:31 +00:00
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2007-03-06 00:23:01 +00:00
|
|
|
FRAMEWORK_HEADER_FILES = $(addprefix $(FRAMEWORK_VERSION_DIR)/Headers/,$(HEADER_FILES))
|
2010-02-07 19:56:09 +00:00
|
|
|
FRAMEWORK_HEADER_SUBDIRS = $(addprefix $(FRAMEWORK_VERSION_DIR)/Headers/,$(HEADER_SUBDIRS))
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2006-09-19 01:32:43 +00:00
|
|
|
# FIXME - do we really those variables too ?
|
2005-07-14 16:00:52 +00:00
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
2007-03-06 00:23:01 +00:00
|
|
|
FRAMEWORK_CURRENT_DIR_NAME = $(FRAMEWORK_DIR_NAME)/Versions/Current
|
2005-07-14 16:00:52 +00:00
|
|
|
else
|
2007-03-06 00:23:01 +00:00
|
|
|
FRAMEWORK_CURRENT_DIR_NAME = $(FRAMEWORK_DIR_NAME)
|
2005-07-14 16:00:52 +00:00
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2007-03-06 00:23:01 +00:00
|
|
|
FRAMEWORK_CURRENT_DIR = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_CURRENT_DIR_NAME)
|
|
|
|
FRAMEWORK_LIBRARY_DIR_NAME = $(FRAMEWORK_VERSION_DIR_NAME)/$(GNUSTEP_TARGET_LDIR)
|
|
|
|
FRAMEWORK_LIBRARY_DIR = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_LIBRARY_DIR_NAME)
|
|
|
|
FRAMEWORK_CURRENT_LIBRARY_DIR_NAME = $(FRAMEWORK_CURRENT_DIR_NAME)/$(GNUSTEP_TARGET_LDIR)
|
|
|
|
FRAMEWORK_CURRENT_LIBRARY_DIR = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_CURRENT_LIBRARY_DIR_NAME)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2007-03-09 11:42:00 +00:00
|
|
|
ifneq ($(BUILD_DLL), yes)
|
|
|
|
|
|
|
|
FRAMEWORK_LIBRARY_FILE = lib$(GNUSTEP_INSTANCE)$(SHARED_LIBEXT)
|
2011-04-30 07:59:20 +00:00
|
|
|
ifeq ($(findstring darwin, $(GNUSTEP_TARGET_OS)), darwin)
|
|
|
|
# On Mac OS X the version number conventionally precedes the shared
|
|
|
|
# library suffix, e.g., libgnustep-base.1.16.1.dylib.
|
2011-06-26 09:00:16 +00:00
|
|
|
VERSION_FRAMEWORK_LIBRARY_FILE = lib$(GNUSTEP_INSTANCE).$(VERSION)$(SHARED_LIBEXT)
|
|
|
|
SONAME_FRAMEWORK_FILE = lib$(GNUSTEP_INSTANCE).$(INTERFACE_VERSION)$(SHARED_LIBEXT)
|
2011-04-30 07:59:20 +00:00
|
|
|
else
|
2007-03-09 11:42:00 +00:00
|
|
|
VERSION_FRAMEWORK_LIBRARY_FILE = $(FRAMEWORK_LIBRARY_FILE).$(VERSION)
|
2004-03-04 12:26:00 +00:00
|
|
|
SONAME_FRAMEWORK_FILE = $(FRAMEWORK_LIBRARY_FILE).$(INTERFACE_VERSION)
|
2011-04-30 07:59:20 +00:00
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
|
|
|
else # BUILD_DLL
|
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
# When you build a DLL, you have to install it in a directory which is
|
|
|
|
# in your PATH.
|
2002-02-27 16:27:08 +00:00
|
|
|
ifeq ($(DLL_INSTALLATION_DIR),)
|
|
|
|
DLL_INSTALLATION_DIR = $(GNUSTEP_TOOLS)/$(GNUSTEP_TARGET_LDIR)
|
|
|
|
endif
|
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
# When we build a DLL, we also pass -DBUILD_lib{library_name}_DLL=1 to
|
|
|
|
# the preprocessor. With the new DLL support, this is usually not
|
|
|
|
# needed; but in some cases some symbols are difficult and have to be
|
|
|
|
# exported/imported manually. For these cases, the library header
|
|
|
|
# files can use this preprocessor define to know that they are
|
|
|
|
# included during compilation of the library itself, or are being
|
|
|
|
# imported by external code. Typically with the new DLL support if a
|
|
|
|
# symbol can't be imported you have to mark it with
|
|
|
|
# __declspec(dllimport) when the library is not being compiled.
|
|
|
|
# __declspec(dllexport) is not particularly useful instead.
|
|
|
|
|
|
|
|
CLEAN_framework_NAME = $(subst -,_,$(GNUSTEP_INSTANCE))
|
|
|
|
SHARED_CFLAGS += -DBUILD_$(CLEAN_framework_NAME)_DLL=1
|
|
|
|
|
|
|
|
# FRAMEWORK_LIBRARY_FILE is the import library, libRenaissance.dll.a
|
|
|
|
FRAMEWORK_LIBRARY_FILE = lib$(GNUSTEP_INSTANCE)$(DLL_LIBEXT)$(LIBEXT)
|
|
|
|
VERSION_FRAMEWORK_LIBRARY_FILE = $(FRAMEWORK_LIBRARY_FILE)
|
|
|
|
SONAME_FRAMEWORK_FILE = $(FRAMEWORK_LIBRARY_FILE)
|
|
|
|
|
2009-08-15 21:59:04 +00:00
|
|
|
# LIB_LINK_DLL_FILE is the DLL library, Renaissance-0.dll
|
|
|
|
# (cygRenaissance-0.dll on Cygwin). Include the INTERFACE_VERSION in
|
|
|
|
# the DLL library name. Applications are linked explicitly to this
|
|
|
|
# INTERFACE_VERSION of the library; this works exactly in the same way
|
|
|
|
# as under Unix.
|
|
|
|
LIB_LINK_DLL_FILE = $(DLL_PREFIX)$(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2022-08-03 12:43:36 +00:00
|
|
|
# LIB_LINK_PDB_FILE is the PDB symbol file. The program database (PDB)
|
|
|
|
# includes instructions for formatting trace messages so that they
|
|
|
|
# can be presented in a human-readable display.
|
|
|
|
LIB_LINK_PDB_FILE = $(DLL_PREFIX)$(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_PDBEXT)
|
|
|
|
|
2005-09-29 04:25:01 +00:00
|
|
|
FRAMEWORK_OBJ_EXT = $(DLL_LIBEXT)
|
2005-03-10 04:28:35 +00:00
|
|
|
endif # BUILD_DLL
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2007-03-06 00:23:01 +00:00
|
|
|
FRAMEWORK_FILE_NAME = $(FRAMEWORK_LIBRARY_DIR_NAME)/$(VERSION_FRAMEWORK_LIBRARY_FILE)
|
|
|
|
FRAMEWORK_FILE = $(GNUSTEP_BUILD_DIR)/$(FRAMEWORK_FILE_NAME)
|
2005-07-14 16:00:52 +00:00
|
|
|
|
2004-01-16 17:04:48 +00:00
|
|
|
ifneq ($($(GNUSTEP_INSTANCE)_INSTALL_DIR),)
|
|
|
|
FRAMEWORK_INSTALL_DIR = $($(GNUSTEP_INSTANCE)_INSTALL_DIR)
|
|
|
|
endif
|
|
|
|
|
2002-10-30 13:20:26 +00:00
|
|
|
ifeq ($(FRAMEWORK_INSTALL_DIR),)
|
|
|
|
FRAMEWORK_INSTALL_DIR = $(GNUSTEP_FRAMEWORKS)
|
|
|
|
endif
|
|
|
|
|
|
|
|
#
|
|
|
|
# Now prepare the variables which are used by target-dependent commands
|
|
|
|
# defined in target.make
|
|
|
|
#
|
2003-10-13 23:25:23 +00:00
|
|
|
LIB_LINK_OBJ_DIR = $(FRAMEWORK_LIBRARY_DIR)
|
2002-10-30 13:20:26 +00:00
|
|
|
LIB_LINK_VERSION_FILE = $(VERSION_FRAMEWORK_LIBRARY_FILE)
|
|
|
|
LIB_LINK_SONAME_FILE = $(SONAME_FRAMEWORK_FILE)
|
|
|
|
LIB_LINK_FILE = $(FRAMEWORK_LIBRARY_FILE)
|
|
|
|
LIB_LINK_INSTALL_DIR = $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_LIBRARY_DIR_NAME)
|
|
|
|
|
2003-11-03 22:58:01 +00:00
|
|
|
ifneq ($(DYLIB_INSTALL_NAME_BASE),)
|
|
|
|
LIB_LINK_INSTALL_NAME = $(DYLIB_INSTALL_NAME_BASE)/$(FRAMEWORK_FILE_NAME)
|
|
|
|
else
|
|
|
|
# Use a relative path for easy relocation.
|
|
|
|
LIB_LINK_INSTALL_NAME = $(GNUSTEP_INSTANCE).framework/$(GNUSTEP_INSTANCE)
|
2008-05-22 13:16:43 +00:00
|
|
|
|
|
|
|
# On Mac OS X, set absolute install_name if requested
|
|
|
|
ifeq ($(findstring darwin, $(GNUSTEP_TARGET_OS)), darwin)
|
|
|
|
ifeq ($(GNUSTEP_ABSOLUTE_INSTALL_PATHS), yes)
|
|
|
|
LIB_LINK_INSTALL_NAME = $(LIB_LINK_INSTALL_DIR)/$(GNUSTEP_INSTANCE)
|
|
|
|
endif
|
|
|
|
endif
|
2003-11-03 22:58:01 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
|
2003-10-13 23:25:23 +00:00
|
|
|
GNUSTEP_SHARED_BUNDLE_RESOURCE_PATH = $(FRAMEWORK_VERSION_DIR)/Resources
|
2002-03-05 15:02:12 +00:00
|
|
|
include $(GNUSTEP_MAKEFILES)/Instance/Shared/bundle.make
|
|
|
|
|
2010-02-12 09:19:25 +00:00
|
|
|
internal-framework-all_:: $(GNUSTEP_OBJ_INSTANCE_DIR) $(OBJ_DIRS_TO_CREATE) \
|
2002-03-19 13:06:56 +00:00
|
|
|
build-framework
|
2009-10-10 14:59:24 +00:00
|
|
|
# If they specified Info-gnustep.plist in the xxx_RESOURCE_FILES,
|
|
|
|
# print a warning. They are supposed to provide a xxxInfo.plist which
|
|
|
|
# gets merged with the automatically generated entries to generate
|
|
|
|
# Info-gnustep.plist.
|
|
|
|
ifneq ($(FOUNDATION_LIB), apple)
|
|
|
|
ifneq ($(filter Info-gnustep.plist,$($(GNUSTEP_INSTANCE)_RESOURCE_FILES)),)
|
|
|
|
$(WARNING_INFO_GNUSTEP_PLIST)
|
|
|
|
endif
|
|
|
|
else
|
|
|
|
ifneq ($(filter Info.plist,$($(GNUSTEP_INSTANCE)_RESOURCE_FILES)),)
|
|
|
|
$(WARNING_INFO_PLIST)
|
|
|
|
endif
|
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2008-05-24 13:12:15 +00:00
|
|
|
internal-framework-build-headers:: $(FRAMEWORK_VERSION_DIR)/Headers \
|
2010-02-07 19:56:09 +00:00
|
|
|
$(FRAMEWORK_HEADER_SUBDIRS) \
|
2008-05-24 13:12:15 +00:00
|
|
|
$(FRAMEWORK_HEADER_FILES) \
|
2005-07-14 16:00:52 +00:00
|
|
|
build-framework-dirs
|
2004-03-04 13:19:33 +00:00
|
|
|
|
|
|
|
ifeq ($(MAKE_CURRENT_VERSION),yes)
|
2006-09-19 01:32:43 +00:00
|
|
|
|
2004-03-04 13:19:33 +00:00
|
|
|
# A target to build/reset the Current symlink to point to the newly
|
2006-09-19 01:32:43 +00:00
|
|
|
# compiled framework. Only executed if MAKE_CURRENT_VERSION is yes,
|
|
|
|
# and only executed if the symlink doesn't exist yet, or if
|
|
|
|
# FRAMEWORK_VERSION_DIR is newer than the symlink. This is to avoid
|
|
|
|
# rebuilding the symlink every single time, which is a waste of time.
|
|
|
|
UPDATE_CURRENT_SYMLINK_RULE = $(FRAMEWORK_DIR)/Versions/Current
|
|
|
|
$(FRAMEWORK_DIR)/Versions/Current: $(FRAMEWORK_VERSION_DIR)
|
2008-05-24 13:12:15 +00:00
|
|
|
$(ECHO_UPDATING_VERSION_SYMLINK)cd $(FRAMEWORK_DIR)/Versions; \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) Current; \
|
2004-03-04 13:19:33 +00:00
|
|
|
$(LN_S) $(CURRENT_VERSION_NAME) Current$(END_ECHO)
|
|
|
|
|
|
|
|
else
|
|
|
|
UPDATE_CURRENT_SYMLINK_RULE =
|
|
|
|
endif
|
|
|
|
|
2006-09-19 01:32:43 +00:00
|
|
|
# FIXME/TODO - the following rule is always executed. This is stupid.
|
|
|
|
# We should have some decent dependencies so that it's not executed if
|
|
|
|
# there is nothing to build. :-)
|
|
|
|
|
|
|
|
# Please note that test -h must be used instead of test -L because on
|
|
|
|
# old Sun Solaris, test -h works but test -L does not.
|
2005-07-06 16:14:15 +00:00
|
|
|
build-framework-dirs: $(DERIVED_SOURCES_DIR) \
|
|
|
|
$(FRAMEWORK_LIBRARY_DIR) \
|
|
|
|
$(FRAMEWORK_VERSION_DIR)/Resources \
|
|
|
|
$(FRAMEWORK_RESOURCE_DIRS) \
|
|
|
|
$(UPDATE_CURRENT_SYMLINK_RULE)
|
2005-07-14 16:00:52 +00:00
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
2004-03-04 13:19:33 +00:00
|
|
|
$(ECHO_NOTHING)cd $(FRAMEWORK_DIR); \
|
2016-06-29 09:47:11 +00:00
|
|
|
if [ ! -h "Resources" ]; then \
|
|
|
|
$(RM_LN_S) Resources; \
|
|
|
|
$(LN_S_RECURSIVE) Versions/Current/Resources Resources; \
|
|
|
|
fi; \
|
2004-01-04 23:46:11 +00:00
|
|
|
if [ ! -h "Headers" ]; then \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) Headers; \
|
2008-01-09 15:55:08 +00:00
|
|
|
$(LN_S_RECURSIVE) Versions/Current/Headers Headers; \
|
2003-05-27 12:07:03 +00:00
|
|
|
fi$(END_ECHO)
|
2005-07-14 16:00:52 +00:00
|
|
|
endif
|
2003-10-13 23:25:23 +00:00
|
|
|
$(ECHO_NOTHING)cd $(DERIVED_SOURCES_DIR); \
|
2004-01-04 23:46:11 +00:00
|
|
|
if [ ! -h "$(HEADER_FILES_INSTALL_DIR)" ]; then \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) ./$(HEADER_FILES_INSTALL_DIR); \
|
2008-01-09 15:55:08 +00:00
|
|
|
$(LN_S_RECURSIVE) ../$(FRAMEWORK_DIR_NAME)/Headers \
|
2002-12-02 12:44:55 +00:00
|
|
|
./$(HEADER_FILES_INSTALL_DIR); \
|
2003-05-27 12:07:03 +00:00
|
|
|
fi$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2003-10-13 23:25:23 +00:00
|
|
|
$(FRAMEWORK_LIBRARY_DIR):
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2003-10-13 23:25:23 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Headers:
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2010-02-07 19:56:09 +00:00
|
|
|
$(FRAMEWORK_HEADER_SUBDIRS):
|
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
|
|
|
|
2006-03-07 20:21:29 +00:00
|
|
|
$(DERIVED_SOURCES_DIR): $(DERIVED_SOURCES_DIR)/.stamp
|
|
|
|
$(DERIVED_SOURCES_DIR)/.stamp:
|
|
|
|
$(ECHO_CREATING)$(MKDIRS) $(DERIVED_SOURCES_DIR); \
|
|
|
|
touch $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2002-03-05 17:15:55 +00:00
|
|
|
# Need to share this code with the headers code ... but how.
|
2008-05-24 13:30:18 +00:00
|
|
|
|
|
|
|
# IMPORTANT: It is tempting to have a file (a header, in this case)
|
|
|
|
# depend on the directory in which we want to create it (the
|
|
|
|
# .../Headers/ directory in this case). The idea being that make
|
|
|
|
# would automatically create the directory before the file. That
|
|
|
|
# might work for a single file, but could trigger spurious rebuilds if
|
|
|
|
# you have more than one file in the directory. The first file will
|
|
|
|
# create the directory, then create the file. The second file will be
|
|
|
|
# created inside the directory; but on some filesystems, creating the
|
|
|
|
# file inside the directory then updates the 'last modified' timestamp
|
|
|
|
# of the directory. So next time you run make, the directory is
|
|
|
|
# 'newer' than the first file, and because the first file depends on
|
|
|
|
# the directory, make will determine that it needs to be updated,
|
|
|
|
# triggering a spurious recreation of the file. If you also have
|
|
|
|
# auto-dependencies turned on, this might in turn cause recompilation
|
|
|
|
# and further spurious rebuilding to happen.
|
2008-05-24 13:12:15 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Headers/%.h: $(HEADER_FILES_DIR)/%.h
|
|
|
|
$(ECHO_CREATING)$(INSTALL_DATA) $< $@$(END_ECHO)
|
2006-03-07 20:21:29 +00:00
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
OBJC_OBJ_FILES_TO_INSPECT = $(OBJC_OBJ_FILES) $(SUBPROJECT_OBJ_FILES)
|
|
|
|
|
2002-12-15 15:49:20 +00:00
|
|
|
# FIXME - We should not depend on GNUmakefile - rather we should use
|
|
|
|
# Instance/Shared/stamp-string.make if we need to depend on the value
|
|
|
|
# of some make variables. That would also detect a change in
|
|
|
|
# FRAMEWORK_INSTALL_DIR from the command line, not currently covered
|
|
|
|
# at the moment!
|
2002-10-11 10:36:51 +00:00
|
|
|
#
|
2004-06-19 11:55:45 +00:00
|
|
|
# To get the list of all classes, we use
|
|
|
|
# $(EXTRACT_CLASS_NAMES_COMMAND), which is defined in target.make
|
2002-10-11 11:00:56 +00:00
|
|
|
#
|
2003-10-20 13:47:54 +00:00
|
|
|
#
|
|
|
|
# The following rule will also build the DUMMY_FRAMEWORK_CLASS_LIST
|
|
|
|
# file. This file is always created/deleted at the same time as the
|
|
|
|
# DUMMY_FRAMEWORK_FILE.
|
2006-03-07 20:21:29 +00:00
|
|
|
$(DUMMY_FRAMEWORK_FILE): $(DERIVED_SOURCES_DIR)/.stamp $(OBJ_FILES_TO_LINK) GNUmakefile
|
2003-05-27 10:35:01 +00:00
|
|
|
$(ECHO_CREATING) classes=""; \
|
2004-06-19 11:55:45 +00:00
|
|
|
for object_file in $(OBJC_OBJ_FILES_TO_INSPECT) __dummy__; do \
|
|
|
|
if [ "$$object_file" != "__dummy__" ]; then \
|
|
|
|
sym=`$(EXTRACT_CLASS_NAMES_COMMAND)`; \
|
2002-02-27 16:27:08 +00:00
|
|
|
classes="$$classes $$sym"; \
|
|
|
|
fi; \
|
|
|
|
done; \
|
|
|
|
classlist=""; \
|
2003-10-20 13:47:54 +00:00
|
|
|
classarray=""; \
|
2002-02-27 16:27:08 +00:00
|
|
|
for f in $$classes __dummy__ ; do \
|
|
|
|
if [ "$$f" != "__dummy__" ]; then \
|
|
|
|
if [ "$$classlist" = "" ]; then \
|
|
|
|
classlist="@\"$$f\""; \
|
2003-10-20 13:47:54 +00:00
|
|
|
classarray="(\"$$f\""; \
|
2002-02-27 16:27:08 +00:00
|
|
|
else \
|
|
|
|
classlist="$$classlist, @\"$$f\""; \
|
2003-10-20 13:47:54 +00:00
|
|
|
classarray="$$classarray, \"$$f\""; \
|
2002-02-27 16:27:08 +00:00
|
|
|
fi; \
|
|
|
|
fi; \
|
|
|
|
done; \
|
|
|
|
if [ "$$classlist" = "" ]; then \
|
|
|
|
classlist="NULL"; \
|
2003-10-20 13:47:54 +00:00
|
|
|
classarray="()"; \
|
2002-02-27 16:27:08 +00:00
|
|
|
else \
|
|
|
|
classlist="$$classlist, NULL"; \
|
2003-10-20 13:47:54 +00:00
|
|
|
classarray="$$classarray)"; \
|
2002-02-27 16:27:08 +00:00
|
|
|
fi; \
|
2003-10-20 13:47:54 +00:00
|
|
|
echo "$$classarray" > $(DUMMY_FRAMEWORK_CLASS_LIST); \
|
2012-08-15 14:46:33 +00:00
|
|
|
echo "#include <Foundation/NSObject.h>" > $@; \
|
2002-02-27 16:27:08 +00:00
|
|
|
echo "#include <Foundation/NSString.h>" > $@; \
|
2012-08-15 14:46:33 +00:00
|
|
|
echo "@interface $(DUMMY_FRAMEWORK) : NSObject" >> $@; \
|
2002-02-27 16:27:08 +00:00
|
|
|
echo "+ (NSString *)frameworkVersion;" >> $@; \
|
2011-06-29 17:07:06 +00:00
|
|
|
echo "+ (NSString *const*)frameworkClasses;" >> $@; \
|
2002-02-27 16:27:08 +00:00
|
|
|
echo "@end" >> $@; \
|
|
|
|
echo "@implementation $(DUMMY_FRAMEWORK)" >> $@; \
|
|
|
|
echo "+ (NSString *)frameworkVersion { return @\"$(CURRENT_VERSION_NAME)\"; }" >> $@; \
|
|
|
|
echo "static NSString *allClasses[] = {$$classlist};" >> $@; \
|
2011-06-29 17:07:06 +00:00
|
|
|
echo "+ (NSString *const*)frameworkClasses { return allClasses; }" >> $@;\
|
2003-05-27 10:35:01 +00:00
|
|
|
echo "@end" >> $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
ifeq ($(FOUNDATION_LIB),gnu)
|
2002-02-27 16:27:08 +00:00
|
|
|
$(DUMMY_FRAMEWORK_OBJ_FILE): $(DUMMY_FRAMEWORK_FILE)
|
2002-10-07 17:21:39 +00:00
|
|
|
$(ECHO_COMPILING)$(CC) $< -c $(ALL_CPPFLAGS) $(ALL_OBJCFLAGS) -o $@$(END_ECHO)
|
2002-12-25 02:08:31 +00:00
|
|
|
endif
|
|
|
|
|
2007-03-16 12:23:56 +00:00
|
|
|
ifeq ($(FOUNDATION_LIB),gnu)
|
|
|
|
FRAMEWORK_INFO_PLIST_FILE = Info-gnustep.plist
|
|
|
|
else
|
|
|
|
FRAMEWORK_INFO_PLIST_FILE = Info.plist
|
|
|
|
endif
|
|
|
|
|
2007-03-06 00:23:01 +00:00
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
2009-02-16 11:21:57 +00:00
|
|
|
build-framework: internal-framework-run-compile-submake \
|
2007-03-06 00:23:01 +00:00
|
|
|
shared-instance-bundle-all \
|
2007-03-16 12:23:56 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Resources/$(FRAMEWORK_INFO_PLIST_FILE) \
|
2007-03-06 00:23:01 +00:00
|
|
|
$(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR)/$(GNUSTEP_INSTANCE)
|
|
|
|
else
|
2009-02-16 11:21:57 +00:00
|
|
|
build-framework: internal-framework-run-compile-submake \
|
2007-03-06 00:23:01 +00:00
|
|
|
shared-instance-bundle-all \
|
2007-03-16 12:23:56 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Resources/$(FRAMEWORK_INFO_PLIST_FILE)
|
2007-03-06 00:23:01 +00:00
|
|
|
endif
|
|
|
|
|
2005-04-15 22:48:30 +00:00
|
|
|
ifeq ($(findstring darwin, $(GNUSTEP_TARGET_OS)), darwin)
|
2002-12-25 02:08:31 +00:00
|
|
|
# When building native frameworks on Apple, we need to create a
|
|
|
|
# top-level symlink xxx.framework/xxx ---> the framework shared
|
2005-04-20 03:01:09 +00:00
|
|
|
# library. On Darwin (non-Apple) we do this as well since we can partially
|
|
|
|
# emulate frameworks (see the ld_lib_path.sh comments on this).
|
2002-12-25 02:08:31 +00:00
|
|
|
|
2004-03-04 13:19:33 +00:00
|
|
|
# Please note that the following keeps the top-level symlink pointing
|
|
|
|
# to the framework in Current. This is always correct, even if what
|
|
|
|
# we are compiling is not made the Current framework version, but if
|
|
|
|
# what we are compiling is not made the Current framework version, I
|
|
|
|
# think it's not our business to touch the Current stuff, so let's
|
|
|
|
# ignore it. It's faster to ignore it anyway. ;-)
|
2007-03-13 08:56:51 +00:00
|
|
|
$(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR):
|
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
|
|
|
|
2013-02-22 09:37:00 +00:00
|
|
|
$(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR)/$(GNUSTEP_INSTANCE): $(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR)
|
2004-03-04 13:19:33 +00:00
|
|
|
ifeq ($(MAKE_CURRENT_VERSION),yes)
|
2003-10-13 23:25:23 +00:00
|
|
|
$(ECHO_NOTHING)cd $(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework; \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) $(GNUSTEP_INSTANCE); \
|
2003-05-27 12:07:03 +00:00
|
|
|
$(LN_S) Versions/Current/$(GNUSTEP_TARGET_LDIR)/$(GNUSTEP_INSTANCE) $(GNUSTEP_INSTANCE)$(END_ECHO)
|
2004-03-04 13:19:33 +00:00
|
|
|
endif
|
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
else
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
# We create a top-level symlink (/copy)
|
|
|
|
#
|
2007-03-06 00:23:01 +00:00
|
|
|
# xxx.framework/{TARGET_LDIR}/xxx --> <the Current framework {TARGET_LDIR}/object file>
|
|
|
|
#
|
|
|
|
# And also
|
|
|
|
#
|
|
|
|
# xxx.framework/{TARGET_LDIR}/libxxx.so --> <the Current framework {TARGET_LDIR}/libxxx.so file>
|
|
|
|
#
|
|
|
|
# On Windows, we don't do any of this since there are no versions anyway.
|
2005-07-14 16:00:52 +00:00
|
|
|
#
|
2007-03-06 00:23:01 +00:00
|
|
|
# The reason for doing this is that you can link against the uninstalled framework
|
|
|
|
# by just using -Lpath_to_the_framework/xxx.framework/$TARGET_LDIR
|
2005-07-14 16:00:52 +00:00
|
|
|
#
|
2007-03-06 00:23:01 +00:00
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
2007-03-13 08:56:51 +00:00
|
|
|
$(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR):
|
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
|
|
|
|
2013-02-22 09:37:00 +00:00
|
|
|
$(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR)/$(GNUSTEP_INSTANCE): $(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR)
|
2007-03-06 00:23:01 +00:00
|
|
|
ifeq ($(MAKE_CURRENT_VERSION),yes)
|
|
|
|
$(ECHO_NOTHING)cd $(GNUSTEP_BUILD_DIR)/$(GNUSTEP_INSTANCE).framework/$(GNUSTEP_TARGET_LDIR); \
|
2007-04-10 15:55:26 +00:00
|
|
|
$(RM_LN_S) $(GNUSTEP_INSTANCE) $(FRAMEWORK_LIBRARY_FILE); \
|
2007-03-13 08:56:51 +00:00
|
|
|
$(LN_S) `$(REL_PATH_SCRIPT) $(GNUSTEP_TARGET_LDIR) \
|
2008-01-09 17:44:12 +00:00
|
|
|
Versions/Current/$(GNUSTEP_TARGET_LDIR)/$(GNUSTEP_INSTANCE) short` \
|
2007-03-13 08:56:51 +00:00
|
|
|
$(GNUSTEP_INSTANCE); \
|
|
|
|
$(LN_S) `$(REL_PATH_SCRIPT) $(GNUSTEP_TARGET_LDIR) \
|
2008-01-09 17:44:12 +00:00
|
|
|
Versions/Current/$(GNUSTEP_TARGET_LDIR)/$(FRAMEWORK_LIBRARY_FILE) short` \
|
2007-03-13 08:56:51 +00:00
|
|
|
$(FRAMEWORK_LIBRARY_FILE)$(END_ECHO)
|
2007-03-06 00:23:01 +00:00
|
|
|
endif
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
ifneq ($(BUILD_DLL), yes)
|
|
|
|
LIB_LINK_FRAMEWORK_FILE = $(LIB_LINK_FILE)
|
|
|
|
else
|
|
|
|
LIB_LINK_FRAMEWORK_FILE = $(LIB_LINK_DLL_FILE)
|
|
|
|
endif
|
2003-11-03 22:35:45 +00:00
|
|
|
|
2009-10-10 17:33:02 +00:00
|
|
|
LIB_LINK_FILES_TO_LINK = $(OBJ_FILES_TO_LINK)
|
|
|
|
|
2009-02-16 11:21:57 +00:00
|
|
|
# Important: FRAMEWORK_FILE (which is created in the parallel
|
|
|
|
# 'compile' invocation) depends on DUMMY_FRAMEWORK_OBJ_FILES as well,
|
|
|
|
# which depends on a lot of other rules. These rules *must* be safe
|
|
|
|
# for parallel building, because they will be used during a parallel
|
|
|
|
# build. In particular, note that DUMMY_FRAMEWORK_OBJ_FILE must
|
|
|
|
# itself depend on OBJ_FILES_TO_LINK else it might be built before all
|
|
|
|
# files are compiled.
|
2005-07-14 16:00:52 +00:00
|
|
|
$(FRAMEWORK_FILE): $(DUMMY_FRAMEWORK_OBJ_FILE) $(OBJ_FILES_TO_LINK)
|
2009-03-19 16:59:53 +00:00
|
|
|
ifeq ($(OBJ_FILES_TO_LINK),)
|
|
|
|
$(WARNING_EMPTY_LINKING)
|
|
|
|
endif
|
2002-12-02 21:59:03 +00:00
|
|
|
$(ECHO_LINKING) \
|
2006-03-07 20:21:29 +00:00
|
|
|
$(LIB_LINK_CMD) || $(RM) $(FRAMEWORK_FILE) ; \
|
2002-12-02 21:59:03 +00:00
|
|
|
(cd $(LIB_LINK_OBJ_DIR); \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) $(GNUSTEP_INSTANCE); \
|
2005-07-14 16:00:52 +00:00
|
|
|
$(LN_S) $(LIB_LINK_FRAMEWORK_FILE) $(GNUSTEP_INSTANCE)) \
|
2002-12-02 21:59:03 +00:00
|
|
|
$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2009-02-16 11:21:57 +00:00
|
|
|
ifeq ($(GNUSTEP_MAKE_PARALLEL_BUILDING), no)
|
|
|
|
# Standard building
|
|
|
|
internal-framework-run-compile-submake: $(FRAMEWORK_FILE)
|
|
|
|
else
|
|
|
|
# Parallel building. The actual compilation is delegated to a
|
|
|
|
# sub-make invocation where _GNUSTEP_MAKE_PARALLEL is set to yet.
|
|
|
|
# That sub-make invocation will compile files in parallel.
|
|
|
|
internal-framework-run-compile-submake:
|
2010-02-14 23:13:47 +00:00
|
|
|
$(ECHO_NOTHING_RECURSIVE_MAKE)$(MAKE) -f $(MAKEFILE_NAME) --no-print-directory --no-keep-going \
|
2009-02-16 11:21:57 +00:00
|
|
|
internal-framework-compile \
|
|
|
|
GNUSTEP_TYPE=$(GNUSTEP_TYPE) \
|
|
|
|
GNUSTEP_INSTANCE=$(GNUSTEP_INSTANCE) \
|
|
|
|
GNUSTEP_OPERATION=compile \
|
|
|
|
GNUSTEP_BUILD_DIR="$(GNUSTEP_BUILD_DIR)" \
|
2010-02-14 23:13:47 +00:00
|
|
|
_GNUSTEP_MAKE_PARALLEL=yes$(END_ECHO_RECURSIVE_MAKE)
|
2009-02-16 11:21:57 +00:00
|
|
|
|
|
|
|
internal-framework-compile: $(FRAMEWORK_FILE)
|
|
|
|
endif
|
|
|
|
|
2002-02-28 18:30:07 +00:00
|
|
|
PRINCIPAL_CLASS = $(strip $($(GNUSTEP_INSTANCE)_PRINCIPAL_CLASS))
|
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
ifeq ($(PRINCIPAL_CLASS),)
|
2002-02-28 18:30:07 +00:00
|
|
|
PRINCIPAL_CLASS = $(GNUSTEP_INSTANCE)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
|
|
|
|
2002-03-07 15:20:18 +00:00
|
|
|
MAIN_MODEL_FILE = $(strip $(subst .gmodel,,$(subst .gorm,,$(subst .nib,,$($(GNUSTEP_INSTANCE)_MAIN_MODEL_FILE)))))
|
|
|
|
|
2007-03-16 12:23:56 +00:00
|
|
|
# FIXME: Use stamp.make to depend on the value of MAIN_MODEL_FILE and PRINCIPAL_CLASS
|
|
|
|
|
|
|
|
# FIXME: MacOSX frameworks should also merge xxxInfo.plist into them
|
2002-02-27 16:27:08 +00:00
|
|
|
# MacOSX-S frameworks
|
2008-05-24 14:47:33 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Resources/Info.plist:
|
2003-05-27 10:35:01 +00:00
|
|
|
$(ECHO_CREATING)(echo "{"; echo ' NOTE = "Automatically generated, do not edit!";'; \
|
2005-07-14 16:00:52 +00:00
|
|
|
echo " NSExecutable = \"$(GNUSTEP_INSTANCE)\";"; \
|
2002-03-07 15:20:18 +00:00
|
|
|
echo " NSMainNibFile = \"$(MAIN_MODEL_FILE)\";"; \
|
2002-02-27 16:27:08 +00:00
|
|
|
echo " NSPrincipalClass = \"$(PRINCIPAL_CLASS)\";"; \
|
2003-05-27 10:35:01 +00:00
|
|
|
echo "}") >$@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
|
|
|
# GNUstep frameworks
|
2007-03-16 12:23:56 +00:00
|
|
|
$(FRAMEWORK_VERSION_DIR)/Resources/Info-gnustep.plist: \
|
|
|
|
$(DUMMY_FRAMEWORK_FILE) \
|
|
|
|
$(GNUSTEP_PLIST_DEPEND)
|
2003-05-27 10:35:01 +00:00
|
|
|
$(ECHO_CREATING)(echo "{"; echo ' NOTE = "Automatically generated, do not edit!";'; \
|
2005-09-29 04:25:01 +00:00
|
|
|
echo " NSExecutable = \"$(GNUSTEP_INSTANCE)$(FRAMEWORK_OBJ_EXT)\";"; \
|
2002-03-07 15:20:18 +00:00
|
|
|
echo " NSMainNibFile = \"$(MAIN_MODEL_FILE)\";"; \
|
2002-02-27 16:27:08 +00:00
|
|
|
echo " NSPrincipalClass = \"$(PRINCIPAL_CLASS)\";"; \
|
2003-10-20 13:47:54 +00:00
|
|
|
echo " Classes = "; \
|
|
|
|
cat $(DUMMY_FRAMEWORK_CLASS_LIST); \
|
|
|
|
echo " ;"; \
|
2003-05-27 10:35:01 +00:00
|
|
|
echo "}") >$@$(END_ECHO)
|
2013-12-27 16:23:08 +00:00
|
|
|
$(ECHO_NOTHING)if [ -r "$(GNUSTEP_PLIST_DEPEND)" ]; then \
|
|
|
|
plmerge $@ $(GNUSTEP_PLIST_DEPEND); \
|
2003-05-27 10:35:01 +00:00
|
|
|
fi$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-03-10 04:28:35 +00:00
|
|
|
ifneq ($(BUILD_DLL),yes)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
ifeq ($(FOUNDATION_LIB),gnu)
|
|
|
|
|
2002-03-19 13:06:56 +00:00
|
|
|
internal-framework-install_:: $(FRAMEWORK_INSTALL_DIR) \
|
2002-02-27 16:27:08 +00:00
|
|
|
$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR) \
|
2016-07-08 13:09:17 +00:00
|
|
|
$(GNUSTEP_HEADERS) shared-instance-pkgconfig-install
|
2016-05-13 15:58:30 +00:00
|
|
|
$(ECHO_INSTALLING)(cd $(GNUSTEP_BUILD_DIR); \
|
|
|
|
$(TAR) cfX - $(GNUSTEP_MAKEFILES)/tar-exclude-list \
|
|
|
|
$(FRAMEWORK_DIR_NAME)) \
|
|
|
|
| (cd $(FRAMEWORK_INSTALL_DIR); $(TAR) xf -)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)$(CHOWN) -R $(CHOWN_TO) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
|
|
|
ifeq ($(strip),yes)
|
2003-10-13 23:25:23 +00:00
|
|
|
$(ECHO_STRIPPING)$(STRIP) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_FILE_NAME)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
2002-06-13 16:16:14 +00:00
|
|
|
$(ECHO_INSTALLING_HEADERS)cd $(GNUSTEP_HEADERS); \
|
2005-04-06 12:02:18 +00:00
|
|
|
$(RM_LN_S) $(HEADER_FILES_INSTALL_DIR); \
|
2008-01-09 17:44:12 +00:00
|
|
|
$(LN_S_RECURSIVE) `$(REL_PATH_SCRIPT) $(GNUSTEP_HEADERS) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME)/Headers short` $(HEADER_FILES_INSTALL_DIR); \
|
2005-04-06 12:02:18 +00:00
|
|
|
$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)cd $(GNUSTEP_HEADERS); \
|
2005-04-06 12:02:18 +00:00
|
|
|
$(CHOWN) $(CHOWN_TO) $(HEADER_FILES_INSTALL_DIR); \
|
|
|
|
$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
2003-05-27 12:07:03 +00:00
|
|
|
$(ECHO_NOTHING)cd $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR); \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) $(FRAMEWORK_LIBRARY_FILE); \
|
|
|
|
$(RM_LN_S) $(SONAME_FRAMEWORK_FILE); \
|
|
|
|
$(RM_LN_S) $(VERSION_FRAMEWORK_LIBRARY_FILE); \
|
2008-01-09 17:44:12 +00:00
|
|
|
$(LN_S) `$(REL_PATH_SCRIPT) $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_CURRENT_LIBRARY_DIR_NAME)/$(FRAMEWORK_LIBRARY_FILE) short` $(FRAMEWORK_LIBRARY_FILE); \
|
2016-05-13 15:58:30 +00:00
|
|
|
if test -r "$(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_LIBRARY_DIR_NAME)/$(SONAME_FRAMEWORK_FILE)"; then \
|
|
|
|
$(LN_S) `$(REL_PATH_SCRIPT) $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_LIBRARY_DIR_NAME)/$(SONAME_FRAMEWORK_FILE) short` $(SONAME_FRAMEWORK_FILE); \
|
2002-02-27 16:27:08 +00:00
|
|
|
fi; \
|
2016-05-13 15:58:30 +00:00
|
|
|
$(LN_S) `$(REL_PATH_SCRIPT) $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_LIBRARY_DIR_NAME)/$(VERSION_FRAMEWORK_LIBRARY_FILE) short` $(VERSION_FRAMEWORK_LIBRARY_FILE)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)cd $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR); \
|
2002-02-27 16:27:08 +00:00
|
|
|
$(CHOWN) $(CHOWN_TO) $(FRAMEWORK_LIBRARY_FILE); \
|
2003-05-28 08:56:40 +00:00
|
|
|
if test -r "$(SONAME_FRAMEWORK_FILE)"; then \
|
2002-02-27 16:27:08 +00:00
|
|
|
$(CHOWN) $(CHOWN_TO) $(SONAME_FRAMEWORK_FILE); \
|
|
|
|
fi; \
|
2003-05-27 11:00:50 +00:00
|
|
|
$(CHOWN) $(CHOWN_TO) $(VERSION_FRAMEWORK_LIBRARY_FILE)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
|
|
|
|
2002-12-25 02:08:31 +00:00
|
|
|
else
|
|
|
|
|
|
|
|
# This code for Apple OSX
|
|
|
|
|
|
|
|
internal-framework-install_:: $(FRAMEWORK_INSTALL_DIR)
|
|
|
|
$(ECHO_INSTALLING)rm -rf $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME); \
|
2004-09-02 16:14:21 +00:00
|
|
|
(cd $(GNUSTEP_BUILD_DIR); $(TAR) cfX - $(GNUSTEP_MAKEFILES)/tar-exclude-list $(FRAMEWORK_DIR_NAME)) | (cd $(FRAMEWORK_INSTALL_DIR); $(TAR) xf -)$(END_ECHO)
|
2002-12-25 02:08:31 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)$(CHOWN) -R $(CHOWN_TO) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME)$(END_ECHO)
|
2002-12-25 02:08:31 +00:00
|
|
|
endif
|
|
|
|
ifeq ($(strip),yes)
|
2003-10-13 23:25:23 +00:00
|
|
|
$(ECHO_STRIPPING)$(STRIP) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_FILE_NAME)$(END_ECHO)
|
2002-12-25 02:08:31 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
endif
|
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
else # install DLL
|
|
|
|
|
2002-03-19 13:06:56 +00:00
|
|
|
internal-framework-install_:: $(FRAMEWORK_INSTALL_DIR) \
|
2002-02-27 16:27:08 +00:00
|
|
|
$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR) \
|
|
|
|
$(GNUSTEP_HEADERS) \
|
|
|
|
$(DLL_INSTALLATION_DIR)
|
2005-07-14 16:00:52 +00:00
|
|
|
$(ECHO_INSTALLING)\
|
|
|
|
rm -rf $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME); \
|
|
|
|
(cd $(GNUSTEP_BUILD_DIR);\
|
|
|
|
$(TAR) cfX - $(GNUSTEP_MAKEFILES)/tar-exclude-list \
|
|
|
|
$(FRAMEWORK_DIR_NAME)) | (cd $(FRAMEWORK_INSTALL_DIR); \
|
|
|
|
$(TAR) xf -)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)$(CHOWN) -R $(CHOWN_TO) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
|
|
|
ifeq ($(strip),yes)
|
2003-10-13 23:25:23 +00:00
|
|
|
$(ECHO_STRIPPING)$(STRIP) $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_FILE_NAME)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
2002-06-13 16:16:14 +00:00
|
|
|
$(ECHO_INSTALLING_HEADERS)cd $(GNUSTEP_HEADERS); \
|
2005-04-06 12:02:18 +00:00
|
|
|
if test -d "$(HEADER_FILES_INSTALL_DIR)"; then \
|
|
|
|
rm -Rf $(HEADER_FILES_INSTALL_DIR); \
|
|
|
|
fi; \
|
|
|
|
$(MKINSTALLDIRS) $(HEADER_FILES_INSTALL_DIR); \
|
|
|
|
cd $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_VERSION_DIR_NAME)/Headers ; \
|
|
|
|
$(TAR) cfX - $(GNUSTEP_MAKEFILES)/tar-exclude-list . | (cd $(GNUSTEP_HEADERS)/$(HEADER_FILES_INSTALL_DIR); \
|
|
|
|
$(TAR) xf - ); \
|
|
|
|
$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
ifneq ($(CHOWN_TO),)
|
2003-05-27 11:00:50 +00:00
|
|
|
$(ECHO_CHOWNING)cd $(GNUSTEP_HEADERS); \
|
2005-04-06 12:02:18 +00:00
|
|
|
$(CHOWN) -R $(CHOWN_TO) $(HEADER_FILES_INSTALL_DIR); \
|
|
|
|
$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
endif
|
2005-07-14 16:00:52 +00:00
|
|
|
$(ECHO_NOTHING)$(INSTALL_PROGRAM) $(FRAMEWORK_LIBRARY_DIR)/$(LIB_LINK_DLL_FILE) \
|
|
|
|
$(DLL_INSTALLATION_DIR)$(END_ECHO)
|
|
|
|
$(ECHO_NOTHING)$(INSTALL_PROGRAM) $(FRAMEWORK_FILE_NAME) \
|
|
|
|
$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
|
|
|
endif
|
|
|
|
|
2005-07-06 16:14:15 +00:00
|
|
|
$(DLL_INSTALLATION_DIR):
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKINSTALLDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
# If Version support is disabled, then this directory is the same as
|
|
|
|
# the Resources directory in Shared/bundle.make for which we already
|
|
|
|
# have a rule.
|
|
|
|
ifeq ($(FRAMEWORK_VERSION_SUPPORT), yes)
|
2005-07-06 16:14:15 +00:00
|
|
|
$(FRAMEWORK_DIR)/Resources:
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKDIRS) $@$(END_ECHO)
|
2005-07-14 16:00:52 +00:00
|
|
|
endif
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-06 16:14:15 +00:00
|
|
|
$(FRAMEWORK_INSTALL_DIR):
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKINSTALLDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-06 16:14:15 +00:00
|
|
|
$(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR):
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKINSTALLDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-06 16:14:15 +00:00
|
|
|
$(GNUSTEP_HEADERS):
|
2003-05-27 10:19:06 +00:00
|
|
|
$(ECHO_CREATING)$(MKINSTALLDIRS) $@$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
2005-07-14 16:00:52 +00:00
|
|
|
ifneq ($(BUILD_DLL), yes)
|
2004-11-04 08:45:18 +00:00
|
|
|
# NB: We use '$(RM_LN_S)' to remove the symlinks to insure
|
2003-11-13 11:41:33 +00:00
|
|
|
# that we do not remove customized real directories.
|
2016-07-08 13:09:17 +00:00
|
|
|
internal-framework-uninstall_:: shared-instance-pkgconfig-uninstall
|
2003-05-27 12:07:03 +00:00
|
|
|
$(ECHO_UNINSTALLING)if [ "$(HEADER_FILES)" != "" ]; then \
|
2002-02-27 16:27:08 +00:00
|
|
|
for file in $(HEADER_FILES) __done; do \
|
|
|
|
if [ $$file != __done ]; then \
|
|
|
|
rm -rf $(GNUSTEP_HEADERS)/$(HEADER_FILES_INSTALL_DIR)/$$file ; \
|
|
|
|
fi; \
|
|
|
|
done; \
|
|
|
|
fi; \
|
2005-04-06 12:02:18 +00:00
|
|
|
$(RM_LN_S) $(GNUSTEP_HEADERS)/$(HEADER_FILES_INSTALL_DIR) ; \
|
2004-01-05 16:50:59 +00:00
|
|
|
rm -rf $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME) ; \
|
|
|
|
cd $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR); \
|
2004-11-04 08:45:18 +00:00
|
|
|
$(RM_LN_S) $(FRAMEWORK_LIBRARY_FILE); \
|
|
|
|
$(RM_LN_S) $(SONAME_FRAMEWORK_FILE); \
|
|
|
|
$(RM_LN_S) $(VERSION_FRAMEWORK_LIBRARY_FILE); \
|
2004-01-05 16:50:59 +00:00
|
|
|
$(END_ECHO)
|
2005-07-14 16:00:52 +00:00
|
|
|
else
|
|
|
|
internal-framework-uninstall_::
|
|
|
|
$(ECHO_UNINSTALLING)if [ "$(HEADER_FILES)" != "" ]; then \
|
|
|
|
for file in $(HEADER_FILES) __done; do \
|
|
|
|
if [ $$file != __done ]; then \
|
|
|
|
rm -rf $(GNUSTEP_HEADERS)/$(HEADER_FILES_INSTALL_DIR)/$$file ; \
|
|
|
|
fi; \
|
|
|
|
done; \
|
|
|
|
fi; \
|
|
|
|
$(RM_LN_S) $(GNUSTEP_HEADERS)/$(HEADER_FILES_INSTALL_DIR) ; \
|
|
|
|
rm -rf $(FRAMEWORK_INSTALL_DIR)/$(FRAMEWORK_DIR_NAME) ; \
|
|
|
|
cd $(GNUSTEP_LIBRARIES)/$(GNUSTEP_TARGET_LDIR); \
|
|
|
|
$(RM_LN_S) $(FRAMEWORK_LIBRARY_FILE); \
|
|
|
|
cd $(DLL_INSTALLATION_DIR); \
|
|
|
|
$(RM_LN_S) $(LIB_LINK_DLL_FILE); \
|
|
|
|
$(END_ECHO)
|
|
|
|
endif
|
2015-10-20 13:33:17 +00:00
|
|
|
|
|
|
|
internal-framework-check::
|
|
|
|
ifneq ($($(GNUSTEP_INSTANCE)_TEST_DIR),)
|
2015-10-24 13:55:08 +00:00
|
|
|
@(\
|
2015-10-25 15:22:25 +00:00
|
|
|
touch $($(GNUSTEP_INSTANCE)_TEST_DIR)/TestInfo; \
|
2015-10-24 13:55:08 +00:00
|
|
|
echo "# Generated by 'make check'" \
|
2015-10-25 09:17:24 +00:00
|
|
|
> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.env; \
|
|
|
|
echo "export LD_LIBRARY_PATH=\"$$(pwd)/$(GNUSTEP_INSTANCE).framework:$(LD_LIBRARY_PATH)\"" > $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.env; \
|
2015-10-24 13:55:08 +00:00
|
|
|
echo "# Generated by 'make check'" \
|
2015-10-25 09:17:24 +00:00
|
|
|
> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.mak; \
|
2018-07-05 10:03:00 +00:00
|
|
|
echo "ADDITIONAL_INCLUDE_DIRS += \"-I$(GNUSTEP_MAKEFILES)/TestFramework\" \"-I$(FRAMEWORK_VERSION_DIR)/Headers\"" \
|
2015-10-25 09:17:24 +00:00
|
|
|
>> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.mak; \
|
2018-07-05 10:03:00 +00:00
|
|
|
echo "ADDITIONAL_LDFLAGS += \"-Wl,-rpath,$$(pwd)/$(GNUSTEP_INSTANCE).framework\"" \ >> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.mak; \
|
2015-10-24 13:55:08 +00:00
|
|
|
echo "ADDITIONAL_LIB_DIRS += \"-L$(FRAMEWORK_VERSION_DIR))\"" \
|
2015-10-25 09:17:24 +00:00
|
|
|
>> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.mak; \
|
2015-10-24 13:55:08 +00:00
|
|
|
echo "ADDITIONAL_TOOL_LIBS += \"-l$(GNUSTEP_INSTANCE)\"" \
|
2015-10-25 09:17:24 +00:00
|
|
|
>> $($(GNUSTEP_INSTANCE)_TEST_DIR)/make-check.mak; \
|
2015-10-24 13:55:08 +00:00
|
|
|
unset MAKEFLAGS; \
|
2015-10-20 13:33:17 +00:00
|
|
|
if [ "$(DEBUG)" = "" ]; then \
|
2015-10-24 13:55:08 +00:00
|
|
|
gnustep-tests --verbose $($(GNUSTEP_INSTANCE)_TEST_DIR);\
|
2015-10-20 13:33:17 +00:00
|
|
|
else \
|
|
|
|
gnustep-tests --debug $($(GNUSTEP_INSTANCE)_TEST_DIR);\
|
2015-10-24 13:55:08 +00:00
|
|
|
fi;\
|
|
|
|
)
|
2015-10-20 13:33:17 +00:00
|
|
|
endif
|
|
|
|
|
2002-02-27 16:27:08 +00:00
|
|
|
#
|
|
|
|
# Cleaning targets
|
|
|
|
#
|
|
|
|
internal-framework-clean::
|
2006-09-13 04:01:28 +00:00
|
|
|
$(ECHO_NOTHING)rm -rf \
|
2003-10-20 13:47:54 +00:00
|
|
|
$(PSWRAP_C_FILES) $(PSWRAP_H_FILES) \
|
2003-10-13 23:25:23 +00:00
|
|
|
$(FRAMEWORK_DIR) $(DERIVED_SOURCES_DIR)$(END_ECHO)
|
2002-02-27 16:27:08 +00:00
|
|
|
|
|
|
|
internal-framework-distclean::
|
|
|
|
|
2002-10-22 00:27:39 +00:00
|
|
|
include $(GNUSTEP_MAKEFILES)/Instance/Shared/strings.make
|