From patchwork Mon May 6 17:33:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 163423 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:81:0:0:0:0 with SMTP id l1csp255536ilm; Mon, 6 May 2019 10:37:40 -0700 (PDT) X-Google-Smtp-Source: APXvYqzmsQxQgTGjWEsM5dYv9owyXyvN1J3YglzCINOvcBvxRAL4HbMf4uWh40RNT/Jv6GnxFk/Y X-Received: by 2002:a1c:e912:: with SMTP id q18mr17240635wmc.137.1557164259916; Mon, 06 May 2019 10:37:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557164259; cv=none; d=google.com; s=arc-20160816; b=wPYUkEfATfpOyIt2n8pHbJ4qiIvnvtNScEIYAwZlouQ5GZUvORFT5z8+ilxjywoNB8 JcbVR0StDC50qK5tQU75YmLejcL0ZfoGfD8x9/8uKJ7wuGKDPAAVmaWw5NYOw529YQHH 82Y6mpYMiI8kkYsheg7L9KSNbG+uN5QUOaE9qVombFNiLh+VBVseJlhMAhtkPWEdP9qq FsD0AbMOWaRDOVMnZzRqCP0IwkyXC/j5MYeUm7QxZtK6aHxQqT8gbNfV93VK0nSpSQJC OPz458kuyjeHA/9MHeQnN/Xv7/oWcoIhbjtPLlszrhrxFeJpjqqSAUmLNTxQgHyMXBa7 OAVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=1xjlqRXirnP5LswdNxna6nzxrI47MTAcF912r95XRb0=; b=cKpFN4jsCYZGFJg0HA155KlqUwiBpJowe/dCxPICJW0uxySiyrpmKdY13alDXCdWoL aiT8WFfiJPASlhdQQ4bJQwPiyPQpNnfrWt8NjSPb2tN8xE4y8s53mmUvItHz3ZFgtf1H KGaPzApN65qUtUszhzFedFn9J3zo9iubIRj5uf6hzZ2ky/B7JCE1PEkqLd3APn03e3nP bHEem/a5M2O0TdfesvxewRgffmLJDpPuBmOtVHdsYQD49uQC3eYzdUI02FH/tcFVmLiF zeQhtYjWScZrd4hwX4YX4fzNYbvA4WgE9/YltMIVqplubfUufvmKLs78HLT23E45ypHX T9ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=t2CugovX; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t17si7007482wmh.159.2019.05.06.10.37.39 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 06 May 2019 10:37:39 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=t2CugovX; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1]:59942 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hNhYY-0004Qs-Nu for patch@linaro.org; Mon, 06 May 2019 13:37:38 -0400 Received: from eggs.gnu.org ([209.51.188.92]:39764) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hNhV9-00010s-4F for qemu-devel@nongnu.org; Mon, 06 May 2019 13:34:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hNhV5-0001Fd-1o for qemu-devel@nongnu.org; Mon, 06 May 2019 13:34:07 -0400 Received: from mail-pg1-x544.google.com ([2607:f8b0:4864:20::544]:33542) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hNhV3-0001DM-1r for qemu-devel@nongnu.org; Mon, 06 May 2019 13:34:02 -0400 Received: by mail-pg1-x544.google.com with SMTP id h17so818186pgv.0 for ; Mon, 06 May 2019 10:33:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=1xjlqRXirnP5LswdNxna6nzxrI47MTAcF912r95XRb0=; b=t2CugovX1/haMwIVga+gft4+pIDnMUVLUxgHoAcFivygQl7rP7iJdl0OToTNIGpeFn 7To872ySiLXWAWqNo1+AOauzny9sG6PeWH/oVUN/WtGCFx+hQX92YAWGurVodnj1Xpix PT9k0iPbueuPPwQGdexmLOf54fv8Z0Aerny3yCnZBoRRmYS92tpmD16kPk1nTIjkT9Lg Xw/LF1aLnBXnVYKS8pL6AdN7qr9H6GpdxSe1BmrxyB8N/zWMPAuojjNvBN8vitHbdFfd ztF4xbtIraMejUc57UPwaLaKx70MXmSwv7rJjTSyiq5MYD7jLjuUv2Rt/iV4fK/OumO6 TKuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=1xjlqRXirnP5LswdNxna6nzxrI47MTAcF912r95XRb0=; b=uCUhJr4GyGR+uCznGsMxjHJEAdsPB2chM9LczMYdsvQBU0jScwqcb9697PuynwIxrL vHuf9jKg8vZ/IO7W2ktXD38hMgrXNFJ3GDxvVugPPntuMPzBPepvIAFUfV2yOGDCiFDz FTaxUZo0YjLDOvEFBz8JpYsryCDOEw9eHZT/IRglYRj3KZktHTZOO5IXuc/7QjXCXm/5 asSOZgSyuU3P/73FaoowZomS3hWMAF+L6rdlxfQ9kYSAdxDyjhbXYerqe1pvFDEsNizg QdcYas6f5gKmOc+6+Rtm9LHAbvqgdgq7Hb0fwy0zwwsOMk1yYGWSjstlS1RtWUKthkSJ Epvw== X-Gm-Message-State: APjAAAUyMCqIQWkORC79/tArasBon56u4szzkS7seiJ0zuPHjQdfrGtm kFib/8pPGLtcM9uI+p7sInCPd1StKFM= X-Received: by 2002:aa7:8b12:: with SMTP id f18mr34787998pfd.178.1557164037998; Mon, 06 May 2019 10:33:57 -0700 (PDT) Received: from localhost.localdomain (97-113-189-189.tukw.qwest.net. [97.113.189.189]) by smtp.gmail.com with ESMTPSA id k9sm2268839pfa.180.2019.05.06.10.33.56 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 06 May 2019 10:33:57 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Date: Mon, 6 May 2019 10:33:31 -0700 Message-Id: <20190506173353.32206-3-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190506173353.32206-1-richard.henderson@linaro.org> References: <20190506173353.32206-1-richard.henderson@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::544 Subject: [Qemu-devel] [PATCH v4 02/24] crypto: Merge crypto-obj-y into libqemuutil.a X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We will shortly need this in the user-only binaries, so drop the split into system and tools binaries. This also means that crypto-aes-obj-y can be merged back into crypto-obj-y. Cc: Daniel P. Berrangé Signed-off-by: Richard Henderson --- Makefile | 12 +++++------- Makefile.objs | 8 ++------ Makefile.target | 4 ---- configure | 9 +++------ crypto/Makefile.objs | 5 +---- 5 files changed, 11 insertions(+), 27 deletions(-) -- 2.17.1 diff --git a/Makefile b/Makefile index d372493042..09c8591805 100644 --- a/Makefile +++ b/Makefile @@ -410,7 +410,6 @@ dummy := $(call unnest-vars,, \ block-obj-y \ block-obj-m \ crypto-obj-y \ - crypto-aes-obj-y \ qom-obj-y \ io-obj-y \ common-obj-y \ @@ -446,7 +445,6 @@ SOFTMMU_SUBDIR_RULES=$(filter %-softmmu,$(SUBDIR_RULES)) $(SOFTMMU_SUBDIR_RULES): $(authz-obj-y) $(SOFTMMU_SUBDIR_RULES): $(block-obj-y) -$(SOFTMMU_SUBDIR_RULES): $(crypto-obj-y) $(SOFTMMU_SUBDIR_RULES): $(io-obj-y) $(SOFTMMU_SUBDIR_RULES): config-all-devices.mak $(SOFTMMU_SUBDIR_RULES): $(edk2-decompressed) @@ -502,7 +500,7 @@ Makefile: $(version-obj-y) ###################################################################### # Build libraries -libqemuutil.a: $(util-obj-y) $(trace-obj-y) $(stub-obj-y) +libqemuutil.a: $(util-obj-y) $(trace-obj-y) $(stub-obj-y) $(crypto-obj-y) libvhost-user.a: $(libvhost-user-obj-y) $(util-obj-y) $(stub-obj-y) ###################################################################### @@ -511,9 +509,9 @@ COMMON_LDADDS = libqemuutil.a qemu-img.o: qemu-img-cmds.h -qemu-img$(EXESUF): qemu-img.o $(authz-obj-y) $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) -qemu-nbd$(EXESUF): qemu-nbd.o $(authz-obj-y) $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) -qemu-io$(EXESUF): qemu-io.o $(authz-obj-y) $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) +qemu-img$(EXESUF): qemu-img.o $(authz-obj-y) $(block-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) +qemu-nbd$(EXESUF): qemu-nbd.o $(authz-obj-y) $(block-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) +qemu-io$(EXESUF): qemu-io.o $(authz-obj-y) $(block-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) qemu-bridge-helper$(EXESUF): qemu-bridge-helper.o $(COMMON_LDADDS) @@ -524,7 +522,7 @@ qemu-edid$(EXESUF): qemu-edid.o hw/display/edid-generate.o $(COMMON_LDADDS) fsdev/virtfs-proxy-helper$(EXESUF): fsdev/virtfs-proxy-helper.o fsdev/9p-marshal.o fsdev/9p-iov-marshal.o $(COMMON_LDADDS) fsdev/virtfs-proxy-helper$(EXESUF): LIBS += -lcap -scsi/qemu-pr-helper$(EXESUF): scsi/qemu-pr-helper.o scsi/utils.o $(authz-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) +scsi/qemu-pr-helper$(EXESUF): scsi/qemu-pr-helper.o scsi/utils.o $(authz-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS) ifdef CONFIG_MPATH scsi/qemu-pr-helper$(EXESUF): LIBS += -ludev -lmultipath -lmpathpersist endif diff --git a/Makefile.objs b/Makefile.objs index cf065de5ed..0ce429c1af 100644 --- a/Makefile.objs +++ b/Makefile.objs @@ -3,6 +3,8 @@ stub-obj-y = stubs/ util/ crypto/ util-obj-y = util/ qobject/ qapi/ +crypto-obj-y = crypto/ + chardev-obj-y = chardev/ ####################################################################### @@ -21,12 +23,6 @@ block-obj-$(CONFIG_REPLICATION) += replication.o block-obj-m = block/ -####################################################################### -# crypto-obj-y is code used by both qemu system emulation and qemu-img - -crypto-obj-y = crypto/ -crypto-aes-obj-y = crypto/ - ####################################################################### # qom-obj-y is code used by both qemu system emulation and qemu-img diff --git a/Makefile.target b/Makefile.target index ae02495951..ce02924ffb 100644 --- a/Makefile.target +++ b/Makefile.target @@ -179,8 +179,6 @@ dummy := $(call unnest-vars,.., \ block-obj-y \ block-obj-m \ chardev-obj-y \ - crypto-obj-y \ - crypto-aes-obj-y \ qom-obj-y \ io-obj-y \ common-obj-y \ @@ -189,8 +187,6 @@ all-obj-y += $(common-obj-y) all-obj-y += $(qom-obj-y) all-obj-$(CONFIG_SOFTMMU) += $(authz-obj-y) all-obj-$(CONFIG_SOFTMMU) += $(block-obj-y) $(chardev-obj-y) -all-obj-$(CONFIG_USER_ONLY) += $(crypto-aes-obj-y) -all-obj-$(CONFIG_SOFTMMU) += $(crypto-obj-y) all-obj-$(CONFIG_SOFTMMU) += $(io-obj-y) ifdef CONFIG_SOFTMMU diff --git a/configure b/configure index daadfe9ad4..0099e85a03 100755 --- a/configure +++ b/configure @@ -2792,8 +2792,7 @@ if test "$gnutls" != "no"; then # At least ubuntu 18.04 ships only shared libraries. write_c_skeleton if compile_prog "" "$gnutls_libs" ; then - libs_softmmu="$gnutls_libs $libs_softmmu" - libs_tools="$gnutls_libs $libs_tools" + LIBS="$gnutls_libs $LIBS" QEMU_CFLAGS="$QEMU_CFLAGS $gnutls_cflags" pass="yes" fi @@ -2860,8 +2859,7 @@ if test "$nettle" != "no"; then nettle_cflags=$($pkg_config --cflags nettle) nettle_libs=$($pkg_config --libs nettle) nettle_version=$($pkg_config --modversion nettle) - libs_softmmu="$nettle_libs $libs_softmmu" - libs_tools="$nettle_libs $libs_tools" + LIBS="$nettle_libs $LIBS" QEMU_CFLAGS="$QEMU_CFLAGS $nettle_cflags" nettle="yes" @@ -2888,8 +2886,7 @@ if test "$gcrypt" != "no"; then then gcrypt_libs="$gcrypt_libs -lgpg-error" fi - libs_softmmu="$gcrypt_libs $libs_softmmu" - libs_tools="$gcrypt_libs $libs_tools" + LIBS="$gcrypt_libs $LIBS" QEMU_CFLAGS="$QEMU_CFLAGS $gcrypt_cflags" gcrypt="yes" diff --git a/crypto/Makefile.objs b/crypto/Makefile.objs index 256c9aca1f..a291bc5b9a 100644 --- a/crypto/Makefile.objs +++ b/crypto/Makefile.objs @@ -34,8 +34,5 @@ crypto-obj-y += xts.o crypto-obj-y += block.o crypto-obj-y += block-qcow.o crypto-obj-y += block-luks.o - -# Let the userspace emulators avoid linking gnutls/etc -crypto-aes-obj-y = aes.o - +crypto-obj-y += aes.o stub-obj-y += pbkdf-stub.o