SHA256
1
0
forked from pool/bindfs
2012-07-02 23:36:42 +00:00
committed by Git OBS Bridge
parent 1e593d89ce
commit d0afc12d45
7 changed files with 178 additions and 10 deletions

59
bindfs-01-cflags.diff Normal file
View File

@@ -0,0 +1,59 @@
parent b7b0facdedceb051241cd4ae9154f7e640e30fa1 ()
commit fbe46eac3e5638034f73bba5f55475170843b172
Author: Jan Engelhardt <jengelh@inai.de>
Date: Tue Jun 26 13:54:05 2012 +0200
build: do not change CFLAGS
CFLAGS must not be touched: it is a user variable. Your previous way
of doing it meant that `export CFLAGS="-O1"; ./configure;` never had
any effect.
---
configure.ac | 9 ++++++---
src/Makefile.am | 3 ++-
2 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/configure.ac b/configure.ac
index 94e2d8b..b618654 100644
--- a/configure.ac
+++ b/configure.ac
@@ -17,9 +17,9 @@ AC_ARG_WITH([core-foundation],
if test x"$enable_debug" == "xyes" ; then
- CFLAGS="${CFLAGS} -g -O0"
+ my_CFLAGS="-g -O0"
else
- CFLAGS="${CFLAGS} -O2"
+ my_CFLAGS="-O2"
fi
if test x"$enable_debug_output" == "xyes" ; then
@@ -31,7 +31,10 @@ if test x"$with_core_foundation" == "xyes" ; then
LDFLAGS="${LDFLAGS} -framework CoreFoundation"
fi
-CFLAGS="${CFLAGS} -Wall -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=25"
+my_CPPFLAGS="-D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=25"
+my_CFLAGS="$my_CFLAGS -Wall"
+AC_SUBST([my_CPPFLAGS])
+AC_SUBST([my_CFLAGS])
# Check for xattrs
AC_CHECK_FUNCS([setxattr getxattr listxattr removexattr])
diff --git a/src/Makefile.am b/src/Makefile.am
index 1d5491c..29661a7 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -5,7 +5,8 @@ bin_PROGRAMS = bindfs
noinst_HEADERS = debug.h permchain.h userinfo.h misc.h usermap.h
bindfs_SOURCES = bindfs.c permchain.c userinfo.c misc.c usermap.c
-AM_CFLAGS = $(fuse_CFLAGS)
+AM_CPPFLAGS = ${my_CPPFLAGS}
+AM_CFLAGS = ${my_CFLAGS} $(fuse_CFLAGS)
bindfs_LDADD = $(fuse_LIBS)
man_MANS = bindfs.1
--
# Created with git-export-patch

57
bindfs-02-automake.diff Normal file
View File

@@ -0,0 +1,57 @@
parent fbe46eac3e5638034f73bba5f55475170843b172 ()
commit 673f8a422ccda9b87bbb7a930956e76afeef8948
Author: Jan Engelhardt <jengelh@inai.de>
Date: Tue Jun 26 13:55:36 2012 +0200
build: better placement of variables
automake options are best set in configure.ac, so they apply
not just to the directory, but the whole project.
Also move fuse_CFLAGS into AM_CPPFLAGS, because it actually
consists of preprocessor directives. (pkgconfig misnamed CFLAGS.)
---
Makefile.am | 4 ----
configure.ac | 2 +-
src/Makefile.am | 4 ++--
3 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 623153e..527ba9d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,2 @@
-# not a GNU package. You can remove this line, if
-# have all needed files, that a GNU package needs
-AUTOMAKE_OPTIONS = foreign
-
SUBDIRS = src tests
diff --git a/configure.ac b/configure.ac
index b618654..14c5236 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,6 @@
AC_INIT([bindfs],[1.10.4],[martin.partel@gmail.com])
-AM_INIT_AUTOMAKE
+AM_INIT_AUTOMAKE([foreign])
AM_CONFIG_HEADER(config.h)
AC_PROG_CC
diff --git a/src/Makefile.am b/src/Makefile.am
index 29661a7..412045c 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -5,8 +5,8 @@ bin_PROGRAMS = bindfs
noinst_HEADERS = debug.h permchain.h userinfo.h misc.h usermap.h
bindfs_SOURCES = bindfs.c permchain.c userinfo.c misc.c usermap.c
-AM_CPPFLAGS = ${my_CPPFLAGS}
-AM_CFLAGS = ${my_CFLAGS} $(fuse_CFLAGS)
+AM_CPPFLAGS = ${my_CPPFLAGS} ${fuse_CFLAGS}
+AM_CFLAGS = ${my_CFLAGS}
bindfs_LDADD = $(fuse_LIBS)
man_MANS = bindfs.1
--
# Created with git-export-patch

34
bindfs-03-permchain1.diff Normal file
View File

@@ -0,0 +1,34 @@
parent 673f8a422ccda9b87bbb7a930956e76afeef8948 ()
commit 77ac30454957e478eb7939b3bc7a181eaa254c58
Author: Jan Engelhardt <jengelh@inai.de>
Date: Tue Jun 26 14:29:48 2012 +0200
bindfs: reduce memory holes in struct permchain
Reduce holes in struct permchain by appropriately sizing and
reordering members.
---
src/permchain.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/permchain.c b/src/permchain.c
index 6e99e7b..fe2dd48 100644
--- a/src/permchain.c
+++ b/src/permchain.c
@@ -31,12 +31,12 @@
struct permchain {
mode_t mask; /* which permissions to apply to */
- char op; /* one of '=', '+', '-', 'o' (octal) or '\0' */
union {
- char operands[16]; /* a subset of rwxXstugo */
+ char operands[10]; /* a subset of rwxXstugo */
unsigned int octal;
};
int flags;
+ char op; /* one of '=', '+', '-', 'o' (octal) or '\0' */
struct permchain *next;
};
--
# Created with git-export-patch

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:fe548e7391500a1b2ef9270ae6a96d078bce1b616e3e1093b4bbd4963434fe72
size 271871

3
bindfs-1.10.4.tar.bz2 Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ed2dc411c821cc1d52ddc83747e61929d39f2505c81529677fde210eafa5370b
size 259375

View File

@@ -1,3 +1,11 @@
-------------------------------------------------------------------
Mon Jul 2 23:30:30 UTC 2012 - jengelh@inai.de
- Update to new upstream version 1.10.4
* A memory bug from 1.10.1, and --create-as-user and thread
safety regressions were resolved.
- Add patches for honoring CFLAGS and reducing memory usage.
-------------------------------------------------------------------
Sat May 5 13:30:19 UTC 2012 - jengelh@medozas.de

View File

@@ -17,23 +17,29 @@
Name: bindfs
Version: 1.10.2
Version: 1.10.4
Release: 0
Summary: Mount Directories to other Locations and alter Permission Bits
License: GPL-2.0+
Group: System/Filesystems
#DL-URL: http://bindfs.googlecode.com/files/bindfs-%{version}.tar.gz
#Git-Clone: git://github.com/mpartel/bindfs
#DL-URL: http://bindfs.googlecode.com/files/bindfs-1.10.4.tar.gz
Source: %name-%version.tar.bz2
Patch1: bindfs-01-cflags.diff
Patch2: bindfs-02-automake.diff
Patch3: bindfs-03-permchain1.diff
Url: http://code.google.com/p/bindfs/
BuildRoot: %{_tmppath}/%{name}-%{version}-build
#BuildRequires: autoconf automake # only for when regeneration is needed
BuildRequires: fuse-devel >= 2.5.3
BuildRequires: gcc
BuildRequires: glibc-devel
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: make
BuildRequires: pkgconfig
%if 0%{?suse_version} >= 1140 || 0%{?fedora_version}
BuildRequires: pkgconfig(fuse) >= 2.5.3
%else
BuildRequires: fuse-devel >= 2.5.3
%endif
# Just for filesystems: project for a short while, hence no Provides et al.
Obsoletes: fuse-bindfs
@@ -44,8 +50,12 @@ using various rules.
%prep
%setup -q
%patch -P 1 -P 2 -P 3 -p1
%build
autoreconf -fi;
export CFLAGS="%optflags -O0 -ggdb3 -pg --test-coverage"
export LDFLAGS="-pg --test-coverage"
%configure
make %{?_smp_mflags}