From e183d9ba8e8bc5309fa145da1809c7e78489f05b Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Thu, 8 Dec 2016 03:06:31 +0100 Subject: new package helloworld, add a package for regression testing with embedded-test --- package/helloworld/Makefile | 31 +++++++++++++++++++++++++++++++ package/helloworld/src/helloworld.c | 6 ++++++ 2 files changed, 37 insertions(+) create mode 100644 package/helloworld/Makefile create mode 100644 package/helloworld/src/helloworld.c (limited to 'package/helloworld') diff --git a/package/helloworld/Makefile b/package/helloworld/Makefile new file mode 100644 index 000000000..c993cde38 --- /dev/null +++ b/package/helloworld/Makefile @@ -0,0 +1,31 @@ +# This file is part of the OpenADK project. OpenADK is copyrighted +# material, please see the LICENCE file in the top-level directory. + +include $(ADK_TOPDIR)/rules.mk + +PKG_NAME:= helloworld +PKG_VERSION:= 1.0 +PKG_RELEASE:= 1 +PKG_DESCR:= hello world +PKG_SECTION:= base/tests + +NO_DISTFILES:= 1 + +include $(ADK_TOPDIR)/mk/package.mk + +$(eval $(call PKG_template,HELLOWORLD,helloworld,$(PKG_VERSION)-$(PKG_RELEASE),$(PKG_DEPENDS),$(PKG_DESCR),$(PKG_SECTION))) + +CONFIG_STYLE:= manual +BUILD_STYLE:= manual +INSTALL_STYLE:= manual + +do-build: + $(TARGET_CC) $(TARGET_CFLAGS) -o $(WRKBUILD)/helloworld $(WRKBUILD)/helloworld.c + $(TARGET_CC) $(TARGET_CFLAGS) -static -o $(WRKBUILD)/helloworld.static $(WRKBUILD)/helloworld.c + +helloworld-install: + $(INSTALL_DIR) $(IDIR_HELLOWORLD)/usr/bin + $(INSTALL_BIN) $(WRKBUILD)/helloworld{,.static} \ + $(IDIR_HELLOWORLD)/usr/bin + +include $(ADK_TOPDIR)/mk/pkg-bottom.mk diff --git a/package/helloworld/src/helloworld.c b/package/helloworld/src/helloworld.c new file mode 100644 index 000000000..232880377 --- /dev/null +++ b/package/helloworld/src/helloworld.c @@ -0,0 +1,6 @@ +#include + +int main() { + printf("Hello World\n"); + return 0; +} -- cgit v1.2.3