# Default values
top_srcdir=.
-builddir=build
-top_builddir=${top_srcdir}/${builddir}
stagedir=.
distdir=.
globalprefix=glite
version=0.0.0
PREFIX=/opt/glite
-glite_location=/opt/glite
globus_prefix=/opt/globus
nothrflavour=gcc32
thrflavour=gcc32pthr
-I. \
-I${top_srcdir}/test \
-I${stagedir}/include \
- -I${glite_location}/include \
-I${expat_prefix}/include \
${COVERAGE_FLAGS} \
-D_GNU_SOURCE \
# major version more frequently. This variable specifies how many steps ahead
# we are.
-VERSION_AHEAD=1
+VERSION_AHEAD=3
+CHECK_VERSION:=VERSION=${version} VERSION_AHEAD=${VERSION_AHEAD} perl ${top_srcdir}/project/check_version.pl
GLOBUS_LIBS:=-L${globus_prefix}/lib \
-lglobus_common_${nothrflavour} \
-lglobus_common_${thrflavour} \
-lglobus_gssapi_gsi_${thrflavour} \
-GLITE_LIBS:=-L${glite_location}/lib
-
ifneq (${expat_prefix},/usr)
EXPAT_LIBS:=-L${expat_prefix}/lib
endif
default: all
-#all compile: check_version ${STATICLIB} ${LTLIB} ${THRSTATICLIB} ${THRLTLIB} ${TRIO_LIB} ${MAILDIR_LIB}
-all compile: ${STATICLIB} ${LTLIB} ${THRSTATICLIB} ${THRLTLIB} ${TRIO_LIB} ${MAILDIR_LIB}
+all compile: check_version ${STATICLIB} ${LTLIB} ${THRSTATICLIB} ${THRLTLIB} ${TRIO_LIB} ${MAILDIR_LIB}
-# FIXME: to use libtool versioning correcty, we should have:
+# In order to use libtool versioning correcty, we must have:
#
# current = major + minor + offset
# revision = patch
#
# where offset is a sum of maximal released minor's of all previous major's
#
-# version_info=-version-info `echo ${version} | cut -d. -f1,2 | tr . :`
-
-# counted minors: 1.1
-offset=1
+# counted minors: 1.1, 3.1
+offset=2
version_info:=-version-info ${shell \
perl -e '$$,=":"; @F=split "\\.","${version}"; print $$F[0]+$$F[1]+${offset},$$F[2],$$F[1]' }
fi
clean:
+ rm -rf *.o *.lo .libs lib*
%.o: %.c
chmod -w $@ >/dev/null
check_version:
- @perl -ne '/#define GLITE_LB_CLIENT_INTERFACE "(\d+)\.\d+\.\d+"/; \
- $$iface=$$1; \
- $$_="${version}"; /(\d+)\.\d+\.\d+/; \
- if ($$iface + ${VERSION_AHEAD} != $$1) { \
- print "error: Major version of the interface ($$iface+${VERSION_AHEAD}) does not match implementation ($$1)\n" ;\
- exit 1; \
- } \
- ' ${stagedir}/include/glite/lb/interface_version.h
+ ${CHECK_VERSION} ${stagedir}/include/glite/lb/interface_version.h
Revision history:
$Log$
+ Revision 1.8.20.1 2006/09/21 13:21:40 jpospi
+ use check_version.pl
+
+ Revision 1.8 2005/08/03 09:30:17 akrenek
+ Merged the release 1.0 branch
+
Revision 1.7 2005/05/26 15:13:46 zurek
inserted module.build.file
<include name="at3" />
<include name="*.T" />
<include name="*.pm" />
+ <include name="check_version.pl" />
</fileset>
</copy>
<antcall target="lbmakefiles" />
#include <sys/un.h>
#include <stdio.h>
#include <math.h>
+#include <sys/stat.h>
+#include <unistd.h>
#include "context-int.h"
struct flock filelock;
int filedesc,
i, filelock_status=-1;
+ struct stat statbuf;
-
+try_again:
if ( (outfile = fopen(event_file, "a")) == NULL ) {
edg_wll_SetError(ctx, errno, "fopen()");
goto event_write_end;
if ( (filedesc = fileno(outfile)) == -1 ) {
edg_wll_SetError(ctx, errno, "fileno()");
- fclose(outfile);
goto cleanup;
}
edg_wll_SetError(ctx, errno, "fcntl()");
goto cleanup;
}
- } else break;
+ } else {
+ /* check that the file still exists */
+ if(stat(event_file, &statbuf)) {
+ if(errno == ENOENT) {
+ /* not there anymore - reopen it */
+ fclose(outfile);
+ goto try_again;
+ } else {
+ /* could not stat the output file */
+ edg_wll_SetError(ctx, errno, "stat()");
+ goto cleanup;
+ }
+ } else {
+ /* file exists and is locked */
+ break;
+ }
+ }
}
if (i == fcntl_attempts) {
edg_wll_SetError(ctx, ETIMEDOUT, "timed out trying to lock event file");
VPATH=${top_srcdir}/src
AT3=perl -I${top_srcdir}/project ${top_srcdir}/project/at3
XSLTPROC:=xsltproc --nonet
-TIDY=tidy
XMLLINT:=xmllint --nonet
+TIDY=tidy -i -q --show-warnings no --tidy-mark no --wrap 0
docbookxls:=http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl
STAGETO=interface
${WSDL}: %.wsdl: %.xml puke-wsdl.xsl
${XSLTPROC} ../src/puke-wsdl.xsl $< >$@
- -${TIDY} -wrap 10000 -xml -m -i -q $@
- -perl -i -n -e 'if (/^\s*$$/) { $$empty .= "\n"; } elsif (/^\s*<(xsd:)?(enumeration|element|input|output|fault)/) { print $$_; $$empty = "";} else { print "$$empty$$_"; $$empty=""; }; ' $@
+ -${TIDY} -xml -m $@
+# XXX: obsolete:
+# -perl -i -n -e 'if (/^\s*$$/) { $$empty .= "\n"; } elsif (/^\s*<(xsd:)?(enumeration|element|input|output|fault)/) { print $$_; $$empty = "";} else { print "$$empty$$_"; $$empty=""; }; ' $@
LB.html: doc.xml LBTypes.xml LB.xml puke-ug.xsl
${XSLTPROC} --novalid ../src/puke-ug.xsl $< >doc-html.xml
+ -${TIDY} -xml -m doc-html.xml
${XMLLINT} --valid --noout doc-html.xml
${XSLTPROC} --stringparam chapter.autolabel 0 ${docbookxls} doc-html.xml >$@
+ -${TIDY} -asxhtml -m $@
<?xml version="1.0"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
- "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
-<book>
-</book>
+<book/>