Commit 27ebea38 authored by Daniel Armbruster's avatar Daniel Armbruster Committed by thomas.forbriger
Browse files

added rule to create package - proceeding

This is a legacy commit from before 2015-03-01.
It may be incomplete as well as inconsistent.
See COPYING.legacy and README.history for details.

SVN Path:     http://gpitrsvn.gpi.uni-karlsruhe.de/repos/TFSoftware/branches/any2matlab0.4
SVN Revision: 3885
SVN UUID:     67feda4a-a26e-11df-9d6e-31afc202ad0c
parent 625ec802
......@@ -29,6 +29,7 @@
# - changed doxygen path name to any2matlab, since I
# expect more mex programs to contribute documentation
# in the future
# 29/04/2011 V1.3 - provides now the build of an any2matlab package
#
# ============================================================================
#
......@@ -51,10 +52,6 @@ else
TYPE:=mexglx
endif
ifndef MATLABBINDIR
MATLABBINDIR=$(HOME)/bin/matlab
endif
README=README
SRC=$(wildcard *.cc)
......@@ -66,8 +63,7 @@ edit: flist; vim $<
.PHONY: clean
clean: ;
-find . -name \*.bak | xargs --no-run-if-empty /bin/rm -v
-find $(MATLABBINDIR) -name any2matlab.mex* | xargs --no-run-if-empty /bin/rm -v
-/bin/rm *.o *.bak *.o77 *.exe *.ps *.xxx *.d
#======================================================================
# installation part
......@@ -75,7 +71,8 @@ clean: ;
# depends on operating system $(OS)
.PHONY: any2matlab
any2matlab: any2matlab.cc
mkdir -pv $(MATLABBINDIR)
mkdir -pv $(LOCBINDIR)
mkdir -pv $(LOCBINDIR)/matlab
mex $< $(MEXFLAGS) -output $(MATLABBINDIR)/$@.$(TYPE) \
-L$(LOCLIBDIR) -I$(LOCINCLUDEDIR) -ldatrwxx\
-lsffxx -lgsexx -laff -ltime++
......
# this is <Makefile.package>
# ----------------------------------------------------------------------------
# $Id: $
# Copyright (c) 2011 by Daniel Armbruster
# ----
# 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 3 of the License, or
# (at your option) any later version.
#
# 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.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# ----
# Daniel Armbruster 29/04/2011
#
# REVISIONS and CHANGES
# 29/04/2011 V1.0 Daniel Armbruster
# ----------------------------------------------------------------------------
#
# Makefile which provides building a any2matlab package as well as a full
# installation of any2matlab.
#
# USAGE:
# - make -f Makefile.package fullpackage
# Rule to create a full any2matlab package.
# - make -f Makefile.package install
# Rule to install any2matlab on your system.
#
# ----------------------------------------------------------------------------
CHECKVAR=$(if $($(1)),,$(error ERROR: missing variable $(1)))
CHECKVARS=$(foreach var,$(1),$(call CHECKVAR,$(var)))
$(call CHECKVARS,LOCINCLUDEDIR LOCLIBDIR LOCBINDIR)
#======================================================================
# installation part
# --------------
#======================================================================
# create package
# --------------
# is delegated to Makefile.packages
ifdef TF_MAKEPKG
.PHONY: fullpackage
fullpackage: $(TF_MAKEPKG)
$(MAKE) -f $< \
PACKAGE=any2matlabWithLibs \
PACKAGEEXPORT="branches/any2matlab0.4/src/matlab/any2matlab:src" \
PACKAGETARGETS="src:all" \
PACKAGELIBS="libaff:libtime:libsffxx:libgsexx:libdatrwxx"
endif
# ----- END OF Makefile.package -----
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment