From: juho Date: Fri, 18 Jan 2013 06:08:36 +0000 (+0900) Subject: Change license and copyright X-Git-Tag: 2.2.1_release~11 X-Git-Url: http://review.tizen.org/git/?p=framework%2Fsystem%2Fdlog.git;a=commitdiff_plain;h=440a93a10ddb5b39d4859e2496d6a42dbbdf7898 Change license and copyright changed a proper license this package and added AUTHORS ,NOTICE and LICENSE.APLv2 file and deleted unnecessary files. Change-Id: I57195593f9bba8f31d31c9028726b19f80ed6efc --- diff --git a/AUTHORS b/AUTHORS new file mode 100755 index 0000000..2190840 --- /dev/null +++ b/AUTHORS @@ -0,0 +1,3 @@ +juho son +Suchang Woo +kyungmin Park diff --git a/LICENSE b/LICENSE.APLv2 similarity index 93% rename from LICENSE rename to LICENSE.APLv2 index c5b1efa..8aa906c 100755 --- a/LICENSE +++ b/LICENSE.APLv2 @@ -1,16 +1,4 @@ - Copyright (c) 2005-2008, The Android Open Source Project - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - - 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. - - Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ @@ -188,3 +176,30 @@ END OF TERMS AND CONDITIONS + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0 + + 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. + + + diff --git a/NOTICE b/NOTICE index c27bc28..a8b23d8 100755 --- a/NOTICE +++ b/NOTICE @@ -1 +1,4 @@ -Copyright (c) 2007 The Android Open Source Project +Copyright (c) The Android Open Source Project +Copyright (c) Samsung Electronics Co., Ltd. All rights reserved. +Except as noted, this software is licensed under Apache License, Version 2. +Please, see the LICENSE.APLv2 file for Apache License terms and conditions. diff --git a/build.sh b/build.sh deleted file mode 100755 index c981648..0000000 --- a/build.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/sh - -### WARNING: DO NOT CHANGE CODES from HERE !!! ### -#import setup -cd `dirname $0` -_PWD=`pwd` -pushd ./ > /dev/null -while [ ! -f "./xo-setup.conf" ] -do - cd ../ - SRCROOT=`pwd` - if [ "$SRCROOT" == "/" ]; then - echo "Cannot find xo-setup.conf !!" - exit 1 - fi -done -popd > /dev/null -. ${SRCROOT}/xo-setup.conf -cd ${_PWD} -### WARNING: DO NOT CHANGE CODES until HERE!!! ### - -CFLAGS="${CFLAGS}" -export VERSION=1.0 - -if [ "$MACHINE" == "volans" ]; then - #export DEVELOP_VER=yes - CFLAGS="${CFLAGS} -D__VOLANS" -fi - - -if [ $1 ]; -then - run make $1 || exit 1 -else - mkdir -p /opt/etc/ -# mkdir -p /opt/data/.debug/symbol/ - if [ -z "$USE_AUTOGEN" ]; then - run ./autogen.sh || exit 1 - run ./configure --prefix=$PREFIX || exit 1 - fi - run make || exit 1 - run make install || exit 1 - mkdir -p ${PREFIX}/bin/ - if [ "$DISTRO" = "vodafone-sdk" ]; then - make_pkg_option="{make_pkg_option} --postjob=./make_openapi.sh" - fi - run make_pkg.sh ${make_pkg_option} || exit 1 -fi - diff --git a/configure.ac b/configure.ac index 6123fe1..186a593 100755 --- a/configure.ac +++ b/configure.ac @@ -12,6 +12,7 @@ PLATFORM_INIT # Checks for programs. dnl AC_PROG_CXX +m4_ifdef([AM_PROG_AR], [AM_PROG_AR]) AC_PROG_CC AC_PROG_GCC_TRADITIONAL AC_PROG_LIBTOOL diff --git a/debian/changelog b/debian/changelog deleted file mode 100644 index 88b3459..0000000 --- a/debian/changelog +++ /dev/null @@ -1,15 +0,0 @@ -dlog (0.4.1-0) unstable; urgency=low - - * change version - * Git: pkgs/d/dlog - * Tag: dlog_0.4.1-0 - - -- Jeesun Kim Sat, 10 Dec 2011 09:26:45 +0900 - -dlog (0.1.0-0) unstable; urgency=low - - * Initial Release. - * Git: pkgs/d/dlog - * Tag: dlog_0.1.0-0 - - -- Jeesun Kim Sat, 10 Dec 2011 09:26:45 +0900 diff --git a/debian/compat b/debian/compat deleted file mode 100755 index 7ed6ff8..0000000 --- a/debian/compat +++ /dev/null @@ -1 +0,0 @@ -5 diff --git a/debian/control b/debian/control deleted file mode 100755 index 23b134b..0000000 --- a/debian/control +++ /dev/null @@ -1,32 +0,0 @@ -Source: dlog -Section: devel -Priority: extra -Maintainer: Youngjoo Park -Uploaders: Youmin Ha , Noha Park , Youngkyeong Yun -Build-Depends: debhelper (>= 5), autotools-dev -Standards-Version: 0.1.0 - -Package: dlog-dev -Section: libs -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, libdlog-0 -Description: dlog API library (Development) -XB-Generate-Docs: yes - -Package: libdlog-0 -Section: libs -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: logging library (shared object) - -Package: dlogutil-bin -Section: devel -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: print log data to the screen - -Package: dlog-0-dbg -Section: debug -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, libdlog-0, dlogutil-bin -Description: logging library, dlogutil dbg package (unstripped) diff --git a/debian/copyright b/debian/copyright deleted file mode 100755 index 90ef6b2..0000000 --- a/debian/copyright +++ /dev/null @@ -1,8 +0,0 @@ -Copyright (c) 2007 The Android Open Source Project - -This program is free software; you can redistribute it and/or modify -it under the terms of the Apache License version 2.0. - -The full text of the Apache 2.0 can be found in -/usr/share/common-licenses. - diff --git a/debian/dirs b/debian/dirs deleted file mode 100755 index ca882bb..0000000 --- a/debian/dirs +++ /dev/null @@ -1,2 +0,0 @@ -usr/bin -usr/sbin diff --git a/debian/dlog-dev.install.in b/debian/dlog-dev.install.in deleted file mode 100755 index bad5cf4..0000000 --- a/debian/dlog-dev.install.in +++ /dev/null @@ -1,4 +0,0 @@ -@PREFIX@/include/dlog/dlog.h -@PREFIX@/lib/libdlog.la -@PREFIX@/lib/pkgconfig/*.pc - diff --git a/debian/dlogutil-bin.install.in b/debian/dlogutil-bin.install.in deleted file mode 100755 index cc4a298..0000000 --- a/debian/dlogutil-bin.install.in +++ /dev/null @@ -1,2 +0,0 @@ -@PREFIX@/bin/dlogutil -/etc/rc.d/init.d/dlog.sh diff --git a/debian/dlogutil-bin.postinst.in b/debian/dlogutil-bin.postinst.in deleted file mode 100644 index 66bafcf..0000000 --- a/debian/dlogutil-bin.postinst.in +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh -#Add boot sequence script -rm -f /etc/rc.d/rc3.d/S05dlog /etc/rc.d/rc5.d/S05dlog -ln -s /etc/rc.d/init.d/dlog.sh /etc/rc.d/rc3.d/S05dlog -ln -s /etc/rc.d/init.d/dlog.sh /etc/rc.d/rc5.d/S05dlog diff --git a/debian/docs b/debian/docs deleted file mode 100755 index e69de29..0000000 diff --git a/debian/libdlog-0.install.in b/debian/libdlog-0.install.in deleted file mode 100755 index e4eff1a..0000000 --- a/debian/libdlog-0.install.in +++ /dev/null @@ -1 +0,0 @@ -@PREFIX@/lib/libdlog.so* diff --git a/debian/rules b/debian/rules deleted file mode 100755 index c931acc..0000000 --- a/debian/rules +++ /dev/null @@ -1,135 +0,0 @@ -#!/usr/bin/make -f -# -*- makefile -*- -# Sample debian/rules that uses debhelper. -# This file was originally written by Joey Hess and Craig Small. -# As a special exception, when this file is copied by dh-make into a -# dh-make output file, you may use that output file without restriction. -# This special exception was added by Craig Small in version 0.37 of dh-make. - -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 - - -# These are used for cross-compiling and for saving the configure script -# from having to guess our platform (since we know it already) -DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) -DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) -DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) -DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_GNU_OS) - -CFLAGS ?= -Wall -g -LDFLAGS ?= -PREFIX ?= /usr -DATADIR ?= /opt - -ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) - CFLAGS += -O0 -else - CFLAGS += -O2 -endif - -# architecture is not arm -ifneq (, $(findstring arm, $(DEB_HOST_ARCH))) - # do something here -else - # do something here for arm architecture -endif - -LDFLAGS += -Wl,--rpath=$(PREFIX)/lib -Wl,--as-needed -Wl,--no-undefined - -#preconfig: -# autoconf -# automake - -config.status: configure.ac Makefile.am - dh_testdir - # Add here commands to configure the package. - ./autogen.sh - CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" ./configure --prefix=$(PREFIX) - -build: build-stamp - -build-stamp: config.status - dh_testdir - touch build-stamp - - # Add here commands to compile the package. - $(MAKE) - #docbook-to-man debian/ncurses.sgml > ncurses.1 - - for f in `find $(CURDIR)/debian/ -name "*.in"`; do \ - cat $$f > $${f%.in}; \ - sed -i -e "s#@PREFIX@#$(PREFIX)#g" $${f%.in}; \ - sed -i -e "s#@DATADIR@#$(DATADIR)#g" $${f%.in}; \ - done - - touch $@ - -clean: - dh_testdir - dh_testroot - rm -f build-stamp - - # Add here commands to clean up after the build process. - -$(MAKE) distclean -ifneq "$(wildcard /usr/share/misc/config.sub)" "" - cp -f /usr/share/misc/config.sub config.sub -endif -ifneq "$(wildcard /usr/share/misc/config.guess)" "" - cp -f /usr/share/misc/config.guess config.guess -endif - - for f in `find $(CURDIR)/debian/ -name "*.in"`; do \ - rm -f $${f%.in}; \ - done - - dh_clean - -install: build - dh_testdir - dh_testroot - dh_clean -k - dh_installdirs - - # Add here commands to install the package into debian/ncurses. - $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install - - -# Build architecture-independent files here. -binary-indep: build install -# We have nothing to do by default. - -# Build architecture-dependent files here. -binary-arch: build install - dh_testdir - dh_testroot - dh_installchangelogs - dh_installdocs - dh_installexamples - dh_install --list-missing --sourcedir=debian/tmp -# dh_installmenu -# dh_installdebconf -# dh_installlogrotate -# dh_installemacsen -# dh_installpam -# dh_installmime -# dh_python -# dh_installinit -# dh_installcron -# dh_installinfo - dh_installman - dh_link -# dh_strip - dh_strip --dbg-package=dlog-0-dbg - dh_compress - dh_fixperms -# dh_perl - dh_makeshlibs - dh_installdeb - dh_shlibdeps - dh_gencontrol - dh_md5sums - dh_builddeb - -binary: binary-indep binary-arch -.PHONY: build clean binary-indep binary-arch binary install diff --git a/include/dlog.h b/include/dlog.h index ee0624c..dfd569f 100755 --- a/include/dlog.h +++ b/include/dlog.h @@ -1,11 +1,13 @@ /* - * Copyright (C) 2005 The Android Open Source Project + * DLOG + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. * - * Licensed under the Apache License, Version 2.0 (the "License"); + * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/include/logger.h b/include/logger.h index 21bee83..cca7567 100755 --- a/include/logger.h +++ b/include/logger.h @@ -1,11 +1,20 @@ -/* utils/logger.h -** -** Copyright 2007, The Android Open Source Project -** -** This file is dual licensed. It may be redistributed and/or modified -** under the terms of the Apache 2.0 License OR version 2 of the GNU -** General Public License. -*/ +/* + * DLOG + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. + * + * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0 + * + * 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. + */ #ifndef _UTILS_LOGGER_H #define _UTILS_LOGGER_H diff --git a/include/logprint.h b/include/logprint.h index 455f90b..6782a0e 100755 --- a/include/logprint.h +++ b/include/logprint.h @@ -1,11 +1,13 @@ /* - * Copyright (C) 2006 The Android Open Source Project + * DLOG + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. * - * Licensed under the Apache License, Version 2.0 (the "License"); + * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/log.c b/log.c index e973395..02738b8 100755 --- a/log.c +++ b/log.c @@ -1,11 +1,13 @@ /* - * Copyright (C) 2007 The Android Open Source Project + * DLOG + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. * - * Licensed under the Apache License, Version 2.0 (the "License"); + * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/logprint.c b/logprint.c index 835b31b..4cf71fa 100755 --- a/logprint.c +++ b/logprint.c @@ -1,7 +1,9 @@ /* - * Copyright 2006, The Android Open Source Project + * DLOG + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd. * - * Licensed under the Apache License, Version 2.0 (the "License"); + * Licensed under the Apache License, Version 2.0 (the License); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * @@ -324,7 +326,7 @@ static inline char * strip_end(char *str) /** - * Splits a wire-format buffer into an AndroidLogEntry + * Splits a wire-format buffer into an LogEntry * entry allocated by caller. Pointers will point directly into buf * * Returns 0 on success and -1 on invalid wire format (entry will be diff --git a/logutil.c b/logutil.c index cb211da..df6e63e 100755 --- a/logutil.c +++ b/logutil.c @@ -1,5 +1,6 @@ /* - * Copyright (C) 2007 The Android Open Source Project + * Copyright (c) 2005-2008, The Android Open Source Project + * Copyright (c) 2009-2013, Samsung Electronics Co., Ltd. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -281,10 +282,16 @@ static void read_log_lines(struct log_device_t* devices) exit(EXIT_FAILURE); } else if (!ret) { + free(entry); fprintf(stderr, "read: Unexpected EOF!\n"); exit(EXIT_FAILURE); } - + else if (entry->entry.len != ret - sizeof(struct logger_entry)) { + free(entry); + fprintf(stderr, "read: unexpected length. Expected %d, got %d\n", + entry->entry.len, ret - sizeof(struct logger_entry)); + exit(EXIT_FAILURE); + } entry->entry.msg[entry->entry.len] = '\0'; enqueue(dev, entry); @@ -583,16 +590,20 @@ int main(int argc, char **argv) } dev = log_devices_new(buf); - if (devices) { - if (log_devices_add_to_tail(devices, dev)) { - fprintf(stderr, "Open log device %s failed\n", buf); - exit(-1); - } - } else { - devices = dev; - g_dev_count = 1; - } - } + if (dev == NULL) { + fprintf(stderr,"Can't add log device: %s\n", buf); + exit(-1); + } + if (devices) { + if (log_devices_add_to_tail(devices, dev)) { + fprintf(stderr, "Open log device %s failed\n", buf); + exit(-1); + } + } else { + devices = dev; + g_dev_count = 1; + } + } break; case 'f': diff --git a/packaging/dlog.changes b/packaging/dlog.changes index 4c0663d..8e4c40f 100644 --- a/packaging/dlog.changes +++ b/packaging/dlog.changes @@ -1,3 +1,8 @@ +* Thu Jan 03 2013 Anas Nashif accepted/trunk/20121212.102709@5168da3 +- fixed build with new compilers +- spec cleanup +- check for archiver in configure.ac + * Thu Jun 28 2012 Patrick McCarty - 0.4.1 - Fix initscript symlinks diff --git a/packaging/dlog.spec b/packaging/dlog.spec index db14771..329abe2 100755 --- a/packaging/dlog.spec +++ b/packaging/dlog.spec @@ -3,19 +3,14 @@ Summary: Logging service Version: 0.4.1 Release: 2 Group: System/Libraries -License: Apache License +License: Apache License, Version 2.0 Source0: %{name}-%{version}.tar.gz -Source101: packaging/dlog-main.service -Source102: packaging/dlog-radio.service -Source103: packaging/tizen-debug-level.service +Source101: dlog-main.service +Source102: dlog-radio.service +Source103: tizen-debug-level.service BuildRequires: pkgconfig(libsystemd-journal) -Requires(post): /sbin/ldconfig -Requires(post): /usr/bin/systemctl Requires(post): /usr/bin/vconftool Requires(post): coreutils -Requires(postun): /sbin/ldconfig -Requires(postun): /usr/bin/systemctl -Requires(preun): /usr/bin/systemctl %description dlog API library @@ -40,10 +35,12 @@ dlog API library Summary: print log data to the screen Group: Development/Libraries Requires: lib%{name} = %{version}-%{release} -Requires(post): /bin/rm, /bin/ln +Requires(post): /usr/bin/systemctl +Requires(postun): /usr/bin/systemctl +Requires(preun): /usr/bin/systemctl %description -n dlogutil -utilities for print log data +Utilities for print log data @@ -85,8 +82,9 @@ ln -s ../dlog-radio.service %{buildroot}%{_libdir}/systemd/system/multi-user.tar ln -s ../tizen-debug-level.service %{buildroot}%{_libdir}/systemd/system/basic.target.wants/tizen-debug-level.service mkdir -p %{buildroot}/usr/share/license -cp LICENSE %{buildroot}/usr/share/license/%{name} +cp LICENSE.APLv2 %{buildroot}/usr/share/license/%{name} +mkdir -p %{buildroot}/opt/etc/dlog %preun -n dlogutil if [ $1 == 0 ]; then @@ -95,10 +93,6 @@ if [ $1 == 0 ]; then fi %post -n dlogutil -mkdir -p /opt/etc/dlog -chown 0:5000 /opt/etc/dlog -chmod 775 /opt/etc/dlog -chmod 755 /usr/bin/dlogctrl systemctl daemon-reload if [ $1 == 1 ]; then systemctl restart dlog-main.service @@ -108,15 +102,13 @@ fi %postun -n dlogutil systemctl daemon-reload -%post -n libdlog -/sbin/ldconfig -%postun -n libdlog -/sbin/ldconfig +%post -n libdlog -p /sbin/ldconfig +%postun -n libdlog -p /sbin/ldconfig %files -n dlogutil %manifest dlogutil.manifest %{_bindir}/dlogutil -%{_bindir}/dlogctrl +%attr(775,root,root) %{_bindir}/dlogctrl %{_sysconfdir}/rc.d/init.d/dlog.sh %{_sysconfdir}/rc.d/rc3.d/S05dlog %{_sysconfdir}/rc.d/rc5.d/S05dlog @@ -126,10 +118,11 @@ systemctl daemon-reload %{_libdir}/systemd/system/basic.target.wants/tizen-debug-level.service %{_libdir}/systemd/system/multi-user.target.wants/dlog-main.service %{_libdir}/systemd/system/multi-user.target.wants/dlog-radio.service +%attr(775,root,app) %dir /opt/etc/dlog %files -n libdlog /usr/share/license/%{name} -%doc LICENSE +%doc LICENSE.APLv2 /opt/etc/.dloglevel /etc/profile.d/tizen_platform_env.sh %{_libdir}/libdlog.so.0