Commit bd840b28 authored by Samuel Debionne's avatar Samuel Debionne

Initial import

parent f259ea0c
Pipeline #3315 passed with stages
in 2 minutes and 20 seconds
......@@ -12,6 +12,8 @@ build:
- dist/
except:
- master
tags:
- conda
deploy:
stage: deploy
......
......@@ -18,6 +18,7 @@ This repository stores the conda recipes for several projects:
- silx
- tango
- v4l2
- cbflib
......
#!/bin/bash
export CBF_PREFIX=$PREFIX
export HDF5_PREFIX=$PREFIX
export REGEX_PREFIX=$PREFIX
export CBFLIB_DONT_USE_TIFF=yes
export CBFLIB_DONT_USE_LZ4=yes
export CBFLIB_DONT_USE_BSHUF=yes
export CBFLIB_DONT_USE_PYCIFRW=yes
export DOWNLOAD="curl -O -L -k"
make baseinstall
diff --git a/Makefile b/Makefile
index 0ead4c0..599687a 100644
--- a/Makefile
+++ b/Makefile
@@ -303,10 +303,12 @@ endif
#
# Definition to get a version of tifflib to support tiff2cbf
#
-TIFF = tiff-4.0.6_rev_3Nov16
-TIFF_PREFIX ?= $(PWD)
-TIFF_INSTALL = $(TIFF)_INSTALL
-
+CBFLIB_DONT_USE_TIFF ?= no
+ifneq ($(CBFLIB_DONT_USE_TIFF),yes)
+ TIFF = tiff-4.0.6_rev_3Nov16
+ TIFF_PREFIX ?= $(PWD)
+ TIFF_INSTALL = $(TIFF)_INSTALL
+endif
#
# Definitions to get a version of HDF5
@@ -416,12 +418,12 @@ SHAR = /usr/bin/shar
#
# Program to use to create archives
#
-AR = /usr/bin/ar
+#AR = /usr/bin/ar
#
# Program to use to add an index to an archive
#
-RANLIB = /usr/bin/ranlib
+#RANLIB = /usr/bin/ranlib
#
@@ -542,14 +544,10 @@ INSTALLSETUP_PY = installsetup.py
# Appropriate compiler definitions for default (Linux)
#
#########################################################
-CC = gcc
-C++ = g++
-#CFLAGS = -g -O0 -Wall -D_USE_XOPEN_EXTENDED -fno-strict-aliasing -DCBFDEBUG=1
-CFLAGS = -g -O3 -Wall -D_USE_XOPEN_EXTENDED -fno-strict-aliasing
-LDFLAGS =
-F90C = gfortran
-F90FLAGS = -g -fno-range-check
-F90LDFLAGS =
+C++ = $(CXX)
+F90C = $(FC)
+F90FLAGS = $(FCFLAGS) -fno-range-check
+F90LDFLAGS = $(FLDFLAGS)
SOCFLAGS = -fPIC
SOLDFLAGS = -shared -Wl,-rpath,$(CBF_PREFIX)/lib
JAVAINCLUDES = -I$(JDKDIR)/include -I$(JDKDIR)/include/linux
@@ -900,10 +898,13 @@ all:: $(BIN) $(SOURCE) $(F90SOURCE) $(HEADERS) \
$(BIN)/testflatpacked \
$(BIN)/testhdf5 \
$(BIN_TESTULP) \
- $(BIN)/tiff2cbf \
$(BIN)/test_cbf_airy_disk \
$(BIN)/cbf_testxfelread
+ifneq ($(CBFLIB_DONT_USE_TIFF),yes)
+all:: $(BIN)/tiff2cbf
+endif
+
ifneq ($(F90C),)
all:: $(BIN)/test_xds_binary \
$(BIN)/test_fcb_read_image
@@ -1085,8 +1086,10 @@ baseinstall: all $(CBF_PREFIX) $(CBF_PREFIX)/lib $(CBF_PREFIX)/bin \
cp $(BIN)/testflat $(CBF_PREFIX)/bin/testflat
-cp $(CBF_PREFIX)/bin/testflatpacked $(CBF_PREFIX)/bin/testflatpacked_old
cp $(BIN)/testflatpacked $(CBF_PREFIX)/bin/testflatpacked
+ifneq ($(CBFLIB_DONT_USE_TIFF),yes)
-cp $(CBF_PREFIX)/bin/tiff2cbf $(CBF_PREFIX)/bin/tiff2cbf_old
cp $(BIN)/tiff2cbf $(CBF_PREFIX)/bin/tiff2cbf
+endif
-cp $(CBF_PREFIX)/bin/test_cbf_airy_disk $(CBF_PREFIX)/bin/test_cbf_airy_disk_old
cp $(BIN)/test_cbf_airy_disk $(CBF_PREFIX)/bin/test_cbf_airy_disk
-cp $(CBF_PREFIX)/bin/test_cbf_airy_disk $(CBF_PREFIX)/bin/test_cbf_airy_disk_old
@@ -1137,7 +1140,9 @@ endif
ifneq ($(CBF_USE_ULP),)
chmod 755 $(CBF_PREFIX)/bin/testulp
endif
+ifneq ($(CBFLIB_DONT_USE_TIFF),yes)
chmod 755 $(CBF_PREFIX)/bin/tiff2cbf
+endif
chmod 755 $(CBF_PREFIX)/bin/test_cbf_airy_disk
chmod 755 $(CBF_PREFIX)/bin/batch_convert_minicbf.sh
chmod 644 $(CBF_PREFIX)/include/cbflib/*.h
@@ -1192,6 +1197,8 @@ $(REGEX)_INSTALL: $(REGEX)
@-cp $(CBF_PREFIX)/include/pcreposix.h $(CBF_PREFIX)/include/regex.h
@-cp $(CBF_PREFIX)/include/pcre2posix.h $(CBF_PREFIX)/include/regex.h
+
+ifneq ($(CBFLIB_DONT_USE_LOCAL_TIFF),yes)
#
# TIFF
#
@@ -1208,6 +1215,7 @@ $(TIFF): build_tiff config.guess config.sub
(cd $(TIFF); ./configure --prefix=$(TIFF_PREFIX); make install)
$(TIFF)_INSTALL: $(TIFF)
(cd $(TIFF); ./configure --prefix=$(CBF_PREFIX); make install)
+endif
ifneq ($(CBFLIB_DONT_USE_LOCAL_HDF5),yes)
@@ -1668,12 +1676,13 @@ $(BIN)/sequence_match: $(LIB)/libcbf.a $(EXAMPLES)/sequence_match.c $(LIB)/libim
#
# tiff2cbf example program
#
-$(BIN)/tiff2cbf: $(LIB)/libcbf.a $(EXAMPLES)/tiff2cbf.c \
+ifneq ($(CBFLIB_DONT_USE_TIFF),yes)
+$(BIN)/tiff2cbf: $(LIB)/libcbf.a $(EXAMPLES)/tiff2cbf.c $(SRC)/tif_sprint.c \
$(GOPTLIB) $(GOPTINC) $(TIFF)
$(CC) $(CFLAGS) $(LDFLAGS) $(MISCFLAG) $(CBF_REGEXFLAG) $(INCLUDES) $(WARNINGS) \
- -I$(TIFF)/libtiff $(EXAMPLES)/tiff2cbf.c $(GOPTLIB) -L$(LIB) \
+ -I$(TIFF)/libtiff -I$(SRC) $(EXAMPLES)/tiff2cbf.c $(SRC)/tif_sprint.c $(GOPTLIB) -L$(LIB) \
-lcbf -L$(TIFF_PREFIX)/lib -ltiff $(REGEX_LIBS_STATIC) $(HDF5LIBS_LOCAL) $(EXTRALIBS) $(HDF5LIBS_SYSTEM) -limg -o $@
-
+endif
#
# Andy Arvai's buffered read test program
#
package:
name: cbflib
version: 0.9.5
source:
git_url: https://github.com/esrf-bliss/cbflib
patches:
- cbflib.patch
requirements:
build:
- make
- m4
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('fortran') }}
- lz4-c 1.8*
- hdf5 1.10*
- pcre 8*
build:
number: 0
skip: True # [win or osx]
script_env:
- http_proxy
- https_proxy
about:
home: http://www.bernstein-plus-sons.com/software/CBF/
license: LGPL
summary: CBFLIB is a library of ANSI-C functions providing a simple mechanism for accessing Crystallographic Binary Files (CBF files)
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