From patchwork Fri Jun 3 17:58:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nikhil Agarwal X-Patchwork-Id: 69243 Delivered-To: patch@linaro.org Received: by 10.140.106.246 with SMTP id e109csp238354qgf; Fri, 3 Jun 2016 05:29:45 -0700 (PDT) X-Received: by 10.55.71.143 with SMTP id u137mr2990195qka.1.1464956985276; Fri, 03 Jun 2016 05:29:45 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id u73si2194360qka.270.2016.06.03.05.29.44; Fri, 03 Jun 2016 05:29:45 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 8D7846173A; Fri, 3 Jun 2016 12:29:44 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: * X-Spam-Status: No, score=1.1 required=5.0 tests=BAYES_00, DATE_IN_FUTURE_03_06, RCVD_IN_DNSWL_NONE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 131D56168E; Fri, 3 Jun 2016 12:29:34 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 38FB36169F; Fri, 3 Jun 2016 12:29:28 +0000 (UTC) Received: from na01-by2-obe.outbound.protection.outlook.com (mail-eopbgr690047.outbound.protection.outlook.com [40.107.69.47]) by lists.linaro.org (Postfix) with ESMTPS id 912A16161C for ; Fri, 3 Jun 2016 12:29:26 +0000 (UTC) Received: from DM2PR03CA0050.namprd03.prod.outlook.com (10.141.96.49) by BY2PR03MB206.namprd03.prod.outlook.com (10.242.36.152) with Microsoft SMTP Server (TLS) id 15.1.485.9; Fri, 3 Jun 2016 12:29:24 +0000 Received: from BN1BFFO11FD015.protection.gbl (2a01:111:f400:7c10::1:156) by DM2PR03CA0050.outlook.office365.com (2a01:111:e400:2428::49) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.506.9 via Frontend Transport; Fri, 3 Jun 2016 12:29:24 +0000 Received-SPF: SoftFail (protection.outlook.com: domain of transitioning linaro.org discourages use of 192.88.158.2 as permitted sender) Received: from az84smr01.freescale.net (192.88.158.2) by BN1BFFO11FD015.mail.protection.outlook.com (10.58.144.78) with Microsoft SMTP Server (TLS) id 15.1.497.8 via Frontend Transport; Fri, 3 Jun 2016 12:29:24 +0000 Received: from netperf2.ap.freescale.net ([10.232.133.164]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id u53CTL8K012828; Fri, 3 Jun 2016 05:29:22 -0700 From: Nikhil Agarwal To: Date: Fri, 3 Jun 2016 23:28:42 +0530 Message-ID: <1464976722-11932-1-git-send-email-nikhil.agarwal@linaro.org> X-Mailer: git-send-email 2.8.2 X-EOPAttributedMessage: 0 X-Matching-Connectors: 131094305643950975; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.158.2; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(2980300002)(189002)(199003)(9170700003)(86362001)(586003)(105596002)(189998001)(92566002)(87936001)(11100500001)(33646002)(50466002)(50986999)(8676002)(19580405001)(110136002)(48376002)(19580395003)(4326007)(106466001)(5008740100001)(229853001)(104016004)(2351001)(77096005)(47776003)(36756003)(81166006)(50226002)(6806005)(2906002)(8936002)(5003940100001); DIR:OUT; SFP:1101; SCL:1; SRVR:BY2PR03MB206; H:az84smr01.freescale.net; FPR:; SPF:SoftFail; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11FD015; 1:0WlrFoCH+G/XZJEznaplFG9ILOHrE3o1fg79dAtYXf1QtsZ8uXVy0a5WWDXdfeXlBoMywphqV2SWojv+QqpLcWqAXUkuuphLeyO8OiNyA7XOY0R8L5CYH/jIaVAM/jPPjS5g6p7yePwype9o2MhslNBBLRNWQlN9ZxPqdJ5duU2ez7NwJm/AXGvhH2pDM4fnC446c2V90QqfBwc50+CjO8B8iOjaL0Zz51hKFRblnjmqsaSToKPDubi67W91u0KGSiM4F41lP2BhN6Zlo5P9E930RnfggOuYu1ixX55KRKq8ONlzaX30zyYP3sYdvFC6Y1MNcap2Q8k28r+hdy/gzmK6UvjmLgeeyGO9Y5mS5QIY90qkeumyOk+1yC79JKhSR6hFi6A6cR41lH2ZbA8W2/SX/nyF9Pxg8gD3pFEWIGkJITfmHf+i6WQK27Ct24sAu4e6K8ZtMyDk6O5gzqNIp97ncmJgXYp0EELv+HZ8TVZHbW536nIH/hqQ5eZJksWBsyi9v9bEh1hpMclRifXkmPb9Kbs60nicDXbk6agM0vvOzqsJl6XFPkvmWO3kTfU4dQl/BiJZHtMVBFxTbp0ucau0efz9e6bFLOGN2mlw2QaPsimfdbKXuPRUQNSY5vsS MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: 1e3d273b-7a92-42d0-921d-08d38baab270 X-Microsoft-Exchange-Diagnostics: 1; BY2PR03MB206; 2:44llX3oJq9SlLmsIjg5NLVwKHfrZLQsO1mfeMNcIvjzfJPMHbIVSWoSFSshFP4ky4BxaeeTLzlmvnGQF6E4GX3C+4xkAxGNFUObohoAJlZtghekYPyUFvM1+CotSWvtQ3h60nc/8wTNCNvfeZoAQukdzn9rwT8ga/cyhFRxEatEUB9VgozVkx2XgQfVk8Xi6; 3:/s4hfzndUqwep7ugEXvqwgeidRjakIrFmv0e9mYTm/XcD5AOFP/qgHw/Ddq6RAhLpIudAzF5pGaeVyrBNNwtmOJkyXCCeHMvbfX6Xbz+Z/RoT6O/7pDj5l56p1Zllyu3IFUrsF3g8qNKcn/gskEa1hqJsuPnHWGIRWLSLlBwvhede0ZkbUEgbhkxaFR92CpqxuH6jl/1UoCFeeqXIPPi+1vJtBNjaDMvKmsAhGHjEXA=; 25:wF1tBWBHCpu505eQE+bI8qBxq0p7shMSUctqQrTftUjQHIpOSJ5G6BPsmMR98XCd1tqfmhQvG3QoH+zFZBB17n5QdptjwP+DOHTrNjmhdGeyBpNQYZJX9apV0WUTx868FOeZP/COS5+bZm6v5Fs7LxkloGl+6BWxLsz/NoYD5l7CWo6w+0Y71OSWY+/8+jpjlbRJNBp3XIyylw2HquM5DVq7dXMCF4pb6sbQ4lATG/2Mwfvs1oO+ru3XieGeLJw3sSj0nSRPVfkuJCBGBeuAyjdcciJMKF7V1aHACLRDnckqbPQmJtvr2OwAPRo2D9Aze1/b5PEwnbO8ACM0L9HLmdIUpcU0UcFMAYeYcDC+nJ5/xH2dYAxowtvSJJzWfQW2jKDah4fBBU4JourPEEVc9yoC+Q3GFxl83C7LIQFfnXg= X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY2PR03MB206; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(1553240931313); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(2401047)(13018025)(5005006)(13017025)(8121501046)(13023025)(13024025)(13015025)(3002001)(10201501046)(6055026); SRVR:BY2PR03MB206; BCL:0; PCL:0; RULEID:(400006); SRVR:BY2PR03MB206; X-Microsoft-Exchange-Diagnostics: 1; BY2PR03MB206; 4:+IPsPUSWUM2BT0iSAGqqFgAmbNCRa5Ip87daP2wOjSO0yfCUrzp4eZRfRfbHfyisEZNUf6aiYHfVlz+2E+ujHsPlD55/md1uK3Px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Yv1SNZnPdtyOGWQa4g6kGcNQwKVEAvXZOPVW/qkDvPGESCpU8MAOlZoAvl2YpJBEyUYZgPwzMGkBJrzgGtk4efqy9GlbcoDl6LkJh5AXWG4aeXjU4Qq6gFWOupn5NyZ8ei/T8iWeOtvAHZzVQ8quhbkLx45azW3/iGe3SX93TLDnyWBm5pk5unBQ0u5FR4jxpc/BZEIgP61MZVkoGOpV+EcYgNE3oMFov75zMKCfM1AC7xfuRaMrf5tSetpGO16dzEIGXmGonHLk/ocK7J3kI6R2E2b+fn/8a20noD3A4J7IpzeHcwJa80da0S1Og2/2n6/R8cF3m3pHMg7XHGs8LMa9QjLk4wJKHP8ogbPrm/HliqAs0AyHoR11p8vSoY8IdHVdSlIzWFS X-Microsoft-Exchange-Diagnostics: 1; BY2PR03MB206; 5:lrTuXo2CTUkh4yt/iVFCX19+vyfOUmsKDUF1RjtK3zIv1h6JeBf5i832A3Yz7aLY6lM844xGFinZ6X8iWzP/0FKCQXvTWEIzR9XCoMMqirlV2KoHRvvq3O7JCQ1BW1UHY/Mdpzdb5tOpWyAAdXvhb9z2zxE/lXQox2G0i3QrP6k=; 24:fyebo3Hbtn4aGzTlDtqr7iWEch+mom9Im6V/2ledm+RfpntmkkuO/XP+8tg8xdtN93dJiV9glpOclPHC5Ib9a7opRd0nOEvPg0TqBSSxGgc=; 7:l7yqH3zSbMxwczD9mTc1PfO519W+eQJSZaH+3u4gKBps3QNolbI2G+VGttDTGCprxpIgSlKgshVuOvEX4qxkNq6U+uDfob2bzgTisDr46vAIL9yLAxrrLL2ucZimTOwA0U7aJPy7lHc/e8gTkRVW6bOIBtcR+cb9iyc9alYu4TmVOusBt+CJCw/gGOd3M5w2o81To4ksQHOqLETclUFUEAaVWV0P03H3DWZwhpIVtr0= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jun 2016 12:29:24.1454 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.158.2]; Helo=[az84smr01.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY2PR03MB206 Subject: [lng-odp] [RFC OPNESSL-ODP 1/2] Initial Commit for Makeflies and configure scripts. X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" From: Nikhil Agarwal Added Directory structure. Makeflies and configure scripts. Signed-off-by: Nikhil Agarwal --- .gitignore | 25 ++++++++++ Makefile.am | 2 + bootstrap | 7 +++ configure.ac | 136 +++++++++++++++++++++++++++++++++++++++++++++++++++++ engine/Makefile.am | 5 ++ 5 files changed, 175 insertions(+) create mode 100644 .gitignore create mode 100644 Makefile.am create mode 100755 bootstrap create mode 100644 configure.ac create mode 100644 engine/Makefile.am diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1f844a8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,25 @@ +Makefile +Makefile.in +aclocal.m4 +ar-lib +autom4te.cache/ +compile +config.guess +config.log +config.status +config.sub +configure +depcomp +engine/.deps/ +engine/.libs/ +engine/Makefile +engine/Makefile.in +engine/eng_odp.lo +engine/eng_odp.o +engine/libsslodp.la +install-sh +libtool +ltmain.sh +m4/ +missing + diff --git a/Makefile.am b/Makefile.am new file mode 100644 index 0000000..0536da9 --- /dev/null +++ b/Makefile.am @@ -0,0 +1,2 @@ +ACLOCAL_AMFLAGS=-I m4 +SUBDIRS = engine diff --git a/bootstrap b/bootstrap new file mode 100755 index 0000000..ce37658 --- /dev/null +++ b/bootstrap @@ -0,0 +1,7 @@ +#! /bin/sh +set -x +#mkdir m4 +aclocal +libtoolize --copy +automake --add-missing --copy --warnings=all +autoconf diff --git a/configure.ac b/configure.ac new file mode 100644 index 0000000..19249c9 --- /dev/null +++ b/configure.ac @@ -0,0 +1,136 @@ +AC_PREREQ([2.5]) +AC_INIT([ossl-odp], [0.1], [lng-odp@lists.linaro.org]) +AM_INIT_AUTOMAKE([foreign]) +AC_CONFIG_SRCDIR([engine/eng_odp.c]) + +AC_USE_SYSTEM_EXTENSIONS +AC_SYS_LARGEFILE +AC_CONFIG_MACRO_DIR([m4]) +AM_SILENT_RULES([yes]) + +# Checks for programs. +AC_PROG_CC +AM_PROG_CC_C_O + +AC_PROG_CXX +AC_PROG_INSTALL +AC_PROG_MAKE_SET + +AM_PROG_AR +#Use libtool +LT_INIT([]) +AC_SUBST([LIBTOOL_DEPS]) +AM_PROG_LIBTOOL + +# Checks for library functions. +AC_FUNC_MALLOC + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_C_INLINE +AC_TYPE_SIZE_T +AC_TYPE_SSIZE_T +AC_TYPE_UINT8_T +AC_TYPE_UINT16_T +AC_TYPE_INT32_T +AC_TYPE_UINT32_T +AC_TYPE_UINT64_T + +########################################################################## +# Which architecture optimizations will we use +########################################################################## +AS_CASE([$host], + [x86*], [ARCH=x86], + [mips64*], [ARCH=mips64], + [aarch64*], [ARCH=aarch64], + [powerpc*], [ARCH=powerpc], + [ARCH=linux] +) +AC_SUBST([ARCH]) + +########################################################################## +# Save and set temporary compilation flags +########################################################################## +OLD_LDFLAGS=$LDFLAGS +OLD_CPPFLAGS=$CPPFLAGS +LDFLAGS="$AM_LDFLAGS $LDFLAGS" +CPPFLAGS="$AM_CPPFLAGS $CPPFLAGS" + + +########################################################################## +# Default include setup +########################################################################## +AM_CFLAGS="$AM_CFLAGS $ODP_CFLAGS" +AM_CXXFLAGS="-std=c++11" + + + +########################################################################## +# Set optional OpenSSL path +########################################################################## +AC_ARG_WITH([openssl-path], + AC_HELP_STRING([--with-openssl-path=DIR path to openssl libs and headers], + [(or in the default path if not specified).]), + [OPENSSL_PATH=$withval + AM_CPPFLAGS="$AM_CPPFLAGS -I$OPENSSL_PATH/include" + AM_LDFLAGS="$AM_LDFLAGS -L$OPENSSL_PATH/lib" + ],[]) + +########################################################################## +# Set optional ODP path +########################################################################## +AC_ARG_WITH([odp-path], + AC_HELP_STRING([--with-odp-path=DIR path to odp libs and headers], + [(or in the default path if not specified).]), + [ODP_PATH=$withval + AM_CPPFLAGS="$AM_CPPFLAGS -I$ODP_PATH/include" + AM_LDFLAGS="$AM_LDFLAGS -L$ODP_PATH/lib" + ],[]) + + +########################################################################## +# Save and set temporary compilation flags +########################################################################## +OLD_LDFLAGS=$LDFLAGS +OLD_CPPFLAGS=$CPPFLAGS +LDFLAGS="$AM_LDFLAGS $LDFLAGS" +CPPFLAGS="$AM_CPPFLAGS $CPPFLAGS" + +AC_CHECK_LIB([odp], [odp_init_global],[ODP_LIB=-lodp], + [AC_MSG_FAILURE([ODP library required])]) + + +AC_CONFIG_FILES([Makefile + engine/Makefile + ]) + +AC_SUBST([ODP_PATH]) +AC_SUBST([ODP_LIB]) +AC_SUBST([OPENSSL_PATH]) +AC_SUBST([LIBS]) +AC_SUBST([AM_CPPFLAGS]) +AC_SUBST([CPPFLAGS]) +AC_SUBST([AM_CFLAGS]) +AC_SUBST([CFLAGS]) +AC_SUBST([AM_LDFLAGS]) +AC_SUBST([LDFLAGS]) +AC_SUBST([EXEEXT]) + +AC_OUTPUT +AC_MSG_RESULT([ + +package $PACKAGE +version $VERSION +arch ${ARCH} +openssl: ${OPENSSL_PATH} +odp: ${ODP_PATH} +cc: ${CC} +cppflags: ${CPPFLAGS} +am_cppflags: ${AM_CPPFLAGS} +am_cxxflags: ${AM_CXXFLAGS} +cflags: ${CFLAGS} +am_cflags: ${AM_CFLAGS} +ldflags: ${LDFLAGS} +am_ldflags: ${AM_LDFLAGS} +]) + diff --git a/engine/Makefile.am b/engine/Makefile.am new file mode 100644 index 0000000..adcc543 --- /dev/null +++ b/engine/Makefile.am @@ -0,0 +1,5 @@ +libsslodp_la_LDFLAGS = $(AM_LDFLAGS) $(ODP_LIB) + +libsslodp_la_SOURCES = eng_odp.c +lib_LTLIBRARIES = libsslodp.la +