- Simple fixup in autoconf.ac
- Make compilation of jffsX-utils compr_lzo.c optional. Simply
don't compile it if we built without LZO and remove the place
holders. They are not used anyway if we build without LZO.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
)
], [])
-AS_IF([test -z "$LZO_LIBS"], [AS_IF([test "x$with_lzo" != "xcheck"],
+AS_IF([test -z "$LZO_LIBS"], [AS_IF([test "x$with_lzo" = "xyes"],
[AC_MSG_ERROR([cannot find liblzo])],
[with_lzo="no"])],
[with_lzo="yes"])
jffsX-utils/compr_zlib.c \
jffsX-utils/compr.h \
jffsX-utils/rbtree.c \
- jffsX-utils/compr_lzo.c \
jffsX-utils/compr.c \
jffsX-utils/compr_rtime.c \
jffsX-utils/compr.h \
sumtool_SOURCES = jffsX-utils/sumtool.c jffsX-utils/summary.h
sumtool_LDADD = libmtd.a
+if WITH_LZO
+mkfs_jffs2_SOURCES += jffsX-utils/compr_lzo.c
+endif
+
EXTRA_DIST += jffsX-utils/device_table.txt jffsX-utils/mkfs.jffs2.1
dist_man1_MANS += jffsX-utils/mkfs.jffs2.1
#include <stdint.h>
#include <stdio.h>
#include <string.h>
-
-#ifdef WITH_LZO
#include <asm/types.h>
#include <linux/jffs2.h>
#include <lzo/lzo1x.h>
free(lzo_compress_buf);
free(lzo_mem);
}
-
-#else
-
-int jffs2_lzo_init(void)
-{
- return 0;
-}
-
-void jffs2_lzo_exit(void)
-{
-}
-
-#endif