From e862ca59a22ac50026810309c64727d9e5b1810f Mon Sep 17 00:00:00 2001 From: Jeffrey Townsend Date: Mon, 4 Jan 2016 19:47:14 +0000 Subject: [PATCH] New ONLPD tool. - This will evenutally become the standalone platform manager. - It currently is just a version of the onlpdump tool that is linked to the ONLP shared library. It works (and can be used to test) all platforms. --- packages/base/any/onlp/APKG.yml | 2 + packages/base/any/onlp/builds/onlpd/Makefile | 53 ++++++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 packages/base/any/onlp/builds/onlpd/Makefile diff --git a/packages/base/any/onlp/APKG.yml b/packages/base/any/onlp/APKG.yml index c5441696..c9e3fbb4 100644 --- a/packages/base/any/onlp/APKG.yml +++ b/packages/base/any/onlp/APKG.yml @@ -7,6 +7,7 @@ ############################################################ variables: libdir: /lib/${TOOLCHAIN} + bindir: /bin common: arch: $ARCH @@ -23,6 +24,7 @@ packages: builds/onlp/$BUILD_DIR/${TOOLCHAIN}/bin/libonlp.so : $libdir/ builds/onlp-platform/$BUILD_DIR/${TOOLCHAIN}/bin/libonlp-platform.so : $libdir/ builds/onlp-platform-defaults/$BUILD_DIR/${TOOLCHAIN}/bin/libonlp-platform-defaults.so : $libdir/ + builds/onlpd/$BUILD_DIR/${TOOLCHAIN}/bin/onlpd : $bindir/ changelog: Change changes changes., diff --git a/packages/base/any/onlp/builds/onlpd/Makefile b/packages/base/any/onlp/builds/onlpd/Makefile new file mode 100644 index 00000000..f8e9e684 --- /dev/null +++ b/packages/base/any/onlp/builds/onlpd/Makefile @@ -0,0 +1,53 @@ +############################################################ +# +# +# Copyright 2014 BigSwitch Networks, Inc. +# +# Licensed under the Eclipse Public License, Version 1.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.eclipse.org/legal/epl-v10.html +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, +# either express or implied. See the License for the specific +# language governing permissions and limitations under the +# License. +# +# +############################################################ +# +# +# +############################################################ +include $(ONL)/make/config.mk + +ifndef TOOLCHAIN +$(error $$TOOLCHAIN must be specified.) +else +export TOOLCHAIN +endif + +MODULE := onlpd-module +include $(BUILDER)/standardinit.mk + +DEPENDMODULES := AIM + +include $(BUILDER)/dependmodules.mk + +BINARY := onlpd +$(BINARY)_LIBRARIES := $(LIBRARY_TARGETS) +include $(BUILDER)/bin.mk + +LIBONLP_SO := ../onlp/$(BUILD_DIR)/bin/libonlp.so + +GLOBAL_CFLAGS += -DAIM_CONFIG_AIM_MAIN_FUNCTION=onlpdump_main +GLOBAL_CFLAGS += -DAIM_CONFIG_INCLUDE_MODULES_INIT=1 +GLOBAL_CFLAGS += -DAIM_CONFIG_INCLUDE_MAIN=1 +GLOBAL_LINK_LIBS += $(LIBONLP_SO) -Wl,--unresolved-symbols=ignore-in-shared-libs +GLOBAL_LINK_LIBS += -lpthread -lm + +include $(BUILDER)/targets.mk +