Hopefully some programmer types can help me out, as I am not one in the slightest.
Trying to compile cryptodev so as to be able to use the AES engine in the Geode CPU. This is the output of make:
Code:
make -C /lib/modules/3.14.0-4-ARCH/build SUBDIRS=`pwd` modules
make[1]: Entering directory '/usr/lib/modules/3.14.0-4-ARCH/build'
CC [M] /root/cryptodev-linux-1.6/ioctl.o
/root/cryptodev-linux-1.6/ioctl.c:710:21: warning: âis_known_acceleratedâ defined but not used [-Wunused-function]
static unsigned int is_known_accelerated(struct crypto_tfm *tfm)
^
CC [M] /root/cryptodev-linux-1.6/main.o
CC [M] /root/cryptodev-linux-1.6/cryptlib.o
/root/cryptodev-linux-1.6/cryptlib.c: In function âcryptodev_cipher_encryptâ:
/root/cryptodev-linux-1.6/cryptlib.c:223:2: error: implicit declaration of function âINIT_COMPLETIONâ [-Werror=implicit-function-declaration]
INIT_COMPLETION(cdata->async.result->completion);
^
cc1: some warnings being treated as errors
scripts/Makefile.build:308: recipe for target '/root/cryptodev-linux-1.6/cryptlib.o' failed
make[2]: *** [/root/cryptodev-linux-1.6/cryptlib.o] Error 1
Makefile:1274: recipe for target '_module_/root/cryptodev-linux-1.6' failed
make[1]: *** [_module_/root/cryptodev-linux-1.6] Error 2
make[1]: Leaving directory '/usr/lib/modules/3.14.0-4-ARCH/build'
Makefile:18: recipe for target 'build' failed
make: *** [build] Error 2
This is the makefile:
Code:
#
# Since version 1.6 the asynchronous mode has been
# disabled by default. To re-enable it uncomment the
# corresponding CFLAG.
#
CRYPTODEV_CFLAGS ?= #-DENABLE_ASYNC
#CRYPTODEV_CFLAGS += -Wno-error
KBUILD_CFLAGS += -I$(src) $(CRYPTODEV_CFLAGS)
KERNEL_DIR = /lib/modules/$(shell uname -r)/build
VERSION = 1.6
PREFIX =
cryptodev-objs = ioctl.o main.o cryptlib.o authenc.o zc.o util.o
obj-m += cryptodev.o
build: version.h
make -C $(KERNEL_DIR) SUBDIRS=`pwd` modules
version.h: Makefile
@echo "#define VERSION \"$(VERSION)\"" > version.h
install: modules_install
modules_install:
make -C $(KERNEL_DIR) SUBDIRS=`pwd` modules_install
@echo "Installing cryptodev.h in $(PREFIX)/usr/include/crypto ..."
@install -D crypto/cryptodev.h $(PREFIX)/usr/include/crypto/cryptodev.h
clean:
make -C $(KERNEL_DIR) SUBDIRS=`pwd` clean
rm -f $(hostprogs) *~
CFLAGS=$(CRYPTODEV_CFLAGS) KERNEL_DIR=$(KERNEL_DIR) make -C tests clean
check:
CFLAGS=$(CRYPTODEV_CFLAGS) KERNEL_DIR=$(KERNEL_DIR) make -C tests check
FILEBASE = cryptodev-linux-$(VERSION)
TMPDIR ?= /tmp
OUTPUT = $(FILEBASE).tar.gz
dist: clean
@echo Packing
@rm -f *.tar.gz
@mkdir $(TMPDIR)/$(FILEBASE)
@cp -ar crypto extras tests examples Makefile *.c *.h README NEWS \
AUTHORS COPYING $(TMPDIR)/$(FILEBASE)
@rm -rf $(TMPDIR)/$(FILEBASE)/.git* $(TMPDIR)/$(FILEBASE)/releases $(TMPDIR)/$(FILEBASE)/scripts
@tar -C /tmp -czf ./$(OUTPUT) $(FILEBASE)
@rm -rf $(TMPDIR)/$(FILEBASE)
@echo Signing $(OUTPUT)
@gpg --output $(OUTPUT).sig -sb $(OUTPUT)
@gpg --verify $(OUTPUT).sig $(OUTPUT)
@mv $(OUTPUT) $(OUTPUT).sig releases/
It seems like there is an error in the cryptlib.c code? But i would have NO idea where to go from there... I have tried adding the -i switch to all the "make" statements in the Makefile, but that just made make skip the errors; it didn't actually build the program, i don't think.
EDIT tried changing the first line in the makefile to:
Code:
CRYPTODEV_CFLAGS ?= -Wno-error #-DENABLE_ASYNC
with of course no change in result.