Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add examples/ folder, move non-core bits there #155

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/Makefile
libcomposefs/Makefile
tools/Makefile
examples/Makefile
Makefile.in
aclocal.m4
autom4te.cache
Expand Down
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SUBDIRS=libcomposefs tools
SUBDIRS=libcomposefs tools examples

EXTRA_DIST=\
composefs.pc.in \
Expand Down
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ AC_CONFIG_FILES([
Makefile
libcomposefs/Makefile
tools/Makefile
examples/Makefile
composefs.spec
composefs.pc
])
Expand Down
1 change: 1 addition & 0 deletions examples/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
composefs-from-json
28 changes: 28 additions & 0 deletions examples/Makefile.am
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
noinst_PROGRAMS =

if USE_YAJL
noinst_PROGRAMS += composefs-from-json
endif

AM_CFLAGS = $(WARN_CFLAGS) -I$(top_srcdir)/

composefs_from_json_SOURCES = composefs-from-json.c read-file.c read-file.h
composefs_from_json_LDADD = ../libcomposefs/libcomposefs.la $(LIBS_YAJL) $(LIBCRYPTO_LIBS) $(LIBS_SECCOMP)

TEST_ASSETS_SMALL = \
config.json.gz config-with-hard-link.json.gz

TEST_ASSETS = ${TEST_ASSETS_SMALL} \
cs9-x86_64-developer.json.gz cs9-x86_64-minimal.json.gz \
f36-x86_64-silverblue.json.gz

if ENABLE_VALGRIND
WRITER_JSON_PREFIX=libtool --mode=execute ${VALGRIND} --quiet --leak-check=yes --error-exitcode=42
endif

EXTRA_DIST = test-checksums.sh $(patsubst %,test-assets/%,${TEST_ASSETS_SMALL}) $(patsubst %,test-assets/%.sha256_erofs,${TEST_ASSETS_SMALL})

check-checksums:
$(srcdir)/test-checksums.sh "${WRITER_JSON_PREFIX} $(builddir)/composefs-from-json" "$(srcdir)/test-assets" "${TEST_ASSETS}"

check: check-checksums
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions tools/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ dump
mkcomposefs
writer-json
mount.composefs
composefs-fuse
25 changes: 0 additions & 25 deletions tools/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ bin_PROGRAMS = mkcomposefs
sbin_PROGRAMS = mount.composefs
noinst_PROGRAMS =

if USE_YAJL
noinst_PROGRAMS += composefs-from-json
endif

if USE_FUSE3
noinst_PROGRAMS += composefs-fuse
endif
Expand All @@ -18,27 +14,6 @@ mkcomposefs_LDADD = ../libcomposefs/libcomposefs.la $(LIBCRYPTO_LIBS)
mount_composefs_SOURCES = mountcomposefs.c
mount_composefs_LDADD = ../libcomposefs/libcomposefs.la $(LIBCRYPTO_LIBS)

composefs_from_json_SOURCES = composefs-from-json.c read-file.c read-file.h
composefs_from_json_LDADD = ../libcomposefs/libcomposefs.la $(LIBS_YAJL) $(LIBCRYPTO_LIBS) $(LIBS_SECCOMP)

composefs_fuse_SOURCES = cfs-fuse.c
composefs_fuse_LDADD = ../libcomposefs/libcomposefs.la $(FUSE3_LIBS)
composefs_fuse_CFLAGS = $(FUSE3_CFLAGS)

TEST_ASSETS_SMALL = \
config.json.gz config-with-hard-link.json.gz

TEST_ASSETS = ${TEST_ASSETS_SMALL} \
cs9-x86_64-developer.json.gz cs9-x86_64-minimal.json.gz \
f36-x86_64-silverblue.json.gz

if ENABLE_VALGRIND
WRITER_JSON_PREFIX=libtool --mode=execute ${VALGRIND} --quiet --leak-check=yes --error-exitcode=42
endif

EXTRA_DIST = test-checksums.sh $(patsubst %,test-assets/%,${TEST_ASSETS_SMALL}) $(patsubst %,test-assets/%.sha256_erofs,${TEST_ASSETS_SMALL})

check-checksums:
$(srcdir)/test-checksums.sh "${WRITER_JSON_PREFIX} $(builddir)/composefs-from-json" "$(srcdir)/test-assets" "${TEST_ASSETS}"

check: check-checksums