about summary refs log tree commit diff
path: root/third_party/glog/packages
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/glog/packages')
-rwxr-xr-xthird_party/glog/packages/deb.sh73
-rw-r--r--third_party/glog/packages/deb/README7
-rw-r--r--third_party/glog/packages/deb/changelog71
-rw-r--r--third_party/glog/packages/deb/compat1
-rw-r--r--third_party/glog/packages/deb/control23
-rw-r--r--third_party/glog/packages/deb/copyright35
-rw-r--r--third_party/glog/packages/deb/docs7
-rw-r--r--third_party/glog/packages/deb/libgoogle-glog-dev.dirs4
-rw-r--r--third_party/glog/packages/deb/libgoogle-glog-dev.install10
-rw-r--r--third_party/glog/packages/deb/libgoogle-glog0.dirs1
-rw-r--r--third_party/glog/packages/deb/libgoogle-glog0.install2
-rwxr-xr-xthird_party/glog/packages/deb/rules117
-rwxr-xr-xthird_party/glog/packages/rpm.sh75
-rw-r--r--third_party/glog/packages/rpm/rpm.spec72
14 files changed, 498 insertions, 0 deletions
diff --git a/third_party/glog/packages/deb.sh b/third_party/glog/packages/deb.sh
new file mode 100755
index 000000000000..a1cdf321ef58
--- /dev/null
+++ b/third_party/glog/packages/deb.sh
@@ -0,0 +1,73 @@
+#!/bin/bash -e
+
+# This takes one commandline argument, the name of the package.  If no
+# name is given, then we'll end up just using the name associated with
+# an arbitrary .tar.gz file in the rootdir.  That's fine: there's probably
+# only one.
+#
+# Run this from the 'packages' directory, just under rootdir
+
+## Set LIB to lib if exporting a library, empty-string else
+LIB=
+#LIB=lib
+
+PACKAGE="$1"
+VERSION="$2"
+
+# We can only build Debian packages, if the Debian build tools are installed
+if [ \! -x /usr/bin/debuild ]; then
+  echo "Cannot find /usr/bin/debuild. Not building Debian packages." 1>&2
+  exit 0
+fi
+
+# Double-check we're in the packages directory, just under rootdir
+if [ \! -r ../Makefile -a \! -r ../INSTALL ]; then
+  echo "Must run $0 in the 'packages' directory, under the root directory." 1>&2
+  echo "Also, you must run \"make dist\" before running this script." 1>&2
+  exit 0
+fi
+
+# Find the top directory for this package
+topdir="${PWD%/*}"
+
+# Find the tar archive built by "make dist"
+archive="$PACKAGE-$VERSION"
+if [ -z "${archive}" ]; then
+  echo "Cannot find ../$PACKAGE*.tar.gz. Run \"make dist\" first." 1>&2
+  exit 0
+fi
+
+# Create a pristine directory for building the Debian package files
+trap 'rm -rf '`pwd`/tmp'; exit $?' EXIT SIGHUP SIGINT SIGTERM
+
+rm -rf tmp
+mkdir -p tmp
+cd tmp
+
+package="google-glog_$VERSION"
+
+# Debian has very specific requirements about the naming of build
+# directories, and tar archives. It also wants to write all generated
+# packages to the parent of the source directory. We accommodate these
+# requirements by building directly from the tar file.
+ln -s "${topdir}/${archive}.tar.gz" "${LIB}${package}.orig.tar.gz"
+tar zfx "${LIB}${package}.orig.tar.gz"
+mv "${archive}" "${LIB}${package}"
+cd "${LIB}${package}"
+# This is one of those 'specific requirements': where the deb control files live
+cp -a "packages/deb" "debian"
+
+# Now, we can call Debian's standard build tool
+debuild -uc -us
+cd ../..                            # get back to the original top-level dir
+
+# We'll put the result in a subdirectory that's named after the OS version
+# we've made this .deb file for.
+destdir="debian-$(cat /etc/debian_version 2>/dev/null || echo UNKNOWN)"
+
+rm -rf "$destdir"
+mkdir -p "$destdir"
+mv $(find tmp -mindepth 1 -maxdepth 1 -type f) "$destdir"
+
+echo
+echo "The Debian package files are located in $PWD/$destdir"
diff --git a/third_party/glog/packages/deb/README b/third_party/glog/packages/deb/README
new file mode 100644
index 000000000000..57becfda757e
--- /dev/null
+++ b/third_party/glog/packages/deb/README
@@ -0,0 +1,7 @@
+The list of files here isn't complete.  For a step-by-step guide on
+how to set this package up correctly, check out
+    http://www.debian.org/doc/maint-guide/
+
+Most of the files that are in this directory are boilerplate.
+However, you may need to change the list of binary-arch dependencies
+in 'rules'.
diff --git a/third_party/glog/packages/deb/changelog b/third_party/glog/packages/deb/changelog
new file mode 100644
index 000000000000..4cbed1bd0cde
--- /dev/null
+++ b/third_party/glog/packages/deb/changelog
@@ -0,0 +1,71 @@
+google-glog (0.4.0-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Tue, 22 Jan 2019 21:00:26 +0900
+
+google-glog (0.3.5-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Tue, 09 May 2017 16:22:12 +0900
+
+google-glog (0.3.4-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Tue, 10 Mar 2015 12:02:20 +0900
+
+google-glog (0.3.3-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Fri, 01 Feb 2012 14:54:14 +0900
+
+google-glog (0.3.2-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Thu, 12 Jan 2012 17:36:14 +0900
+
+google-glog (0.3.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Tue, 15 Jun 2010 13:50:47 +0900
+
+google-glog (0.3-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Thu, 30 Jul 2009 21:31:35 +0900
+
+google-glog (0.2.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Fri, 10 Apr 2009 15:24:17 +0900
+
+google-glog (0.2-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Fri, 23 Jan 2009 03:14:29 +0900
+
+google-glog (0.1.2-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Tue, 18 Nov 2008 20:37:00 +0900
+
+google-glog (0.1.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Google Inc. <opensource@google.com>  Wed, 15 Oct 2008 20:38:19 +0900
+
+google-glog (0.1-1) unstable; urgency=low
+
+  * Initial release.
+
+ -- Google Inc. <opensource@google.com>  Sat, 10 May 2008 12:31:10 +0900
diff --git a/third_party/glog/packages/deb/compat b/third_party/glog/packages/deb/compat
new file mode 100644
index 000000000000..b8626c4cff28
--- /dev/null
+++ b/third_party/glog/packages/deb/compat
@@ -0,0 +1 @@
+4
diff --git a/third_party/glog/packages/deb/control b/third_party/glog/packages/deb/control
new file mode 100644
index 000000000000..110a72cb3560
--- /dev/null
+++ b/third_party/glog/packages/deb/control
@@ -0,0 +1,23 @@
+Source: google-glog
+Priority: optional
+Maintainer: Google Inc. <opensource@google.com>
+Build-Depends: debhelper (>= 4.0.0), binutils
+Standards-Version: 3.6.1
+
+Package: libgoogle-glog-dev
+Section: libdevel
+Architecture: any
+Depends: libgoogle-glog0 (= ${Source-Version})
+Description:  a library that implements application-level logging.
+ This library provides logging APIs based on C++-style streams and
+ various helper macros.  The devel package contains static and debug
+ libraries and header files for developing applications that use the
+ google-glog package.
+
+Package: libgoogle-glog0
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}
+Description:  a library that implements application-level logging.
+ This library provides logging APIs based on C++-style streams and
+ various helper macros.
diff --git a/third_party/glog/packages/deb/copyright b/third_party/glog/packages/deb/copyright
new file mode 100644
index 000000000000..b2ce8e8f023c
--- /dev/null
+++ b/third_party/glog/packages/deb/copyright
@@ -0,0 +1,35 @@
+This package was debianized by Google Inc. <opensource@google.com> on
+13 June 2008.
+
+It was downloaded from https://github.com/google/glog
+
+Upstream Author: opensource@google.com
+
+Copyright (c) 2008, Google Inc.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+    * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+    * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+    * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/third_party/glog/packages/deb/docs b/third_party/glog/packages/deb/docs
new file mode 100644
index 000000000000..6da25d4d3113
--- /dev/null
+++ b/third_party/glog/packages/deb/docs
@@ -0,0 +1,7 @@
+AUTHORS
+COPYING
+ChangeLog
+INSTALL
+README.md
+doc/designstyle.css
+doc/glog.html
diff --git a/third_party/glog/packages/deb/libgoogle-glog-dev.dirs b/third_party/glog/packages/deb/libgoogle-glog-dev.dirs
new file mode 100644
index 000000000000..bddfbf5c112b
--- /dev/null
+++ b/third_party/glog/packages/deb/libgoogle-glog-dev.dirs
@@ -0,0 +1,4 @@
+usr/lib
+usr/lib/pkgconfig
+usr/include
+usr/include/glog
diff --git a/third_party/glog/packages/deb/libgoogle-glog-dev.install b/third_party/glog/packages/deb/libgoogle-glog-dev.install
new file mode 100644
index 000000000000..9c61e86eaf6f
--- /dev/null
+++ b/third_party/glog/packages/deb/libgoogle-glog-dev.install
@@ -0,0 +1,10 @@
+usr/include/glog/*
+usr/lib/lib*.so
+usr/lib/lib*.a
+usr/lib/*.la
+usr/lib/pkgconfig/*
+debian/tmp/usr/include/glog/*
+debian/tmp/usr/lib/lib*.so
+debian/tmp/usr/lib/lib*.a
+debian/tmp/usr/lib/*.la
+debian/tmp/usr/lib/pkgconfig/*
diff --git a/third_party/glog/packages/deb/libgoogle-glog0.dirs b/third_party/glog/packages/deb/libgoogle-glog0.dirs
new file mode 100644
index 000000000000..68457717bd8e
--- /dev/null
+++ b/third_party/glog/packages/deb/libgoogle-glog0.dirs
@@ -0,0 +1 @@
+usr/lib
diff --git a/third_party/glog/packages/deb/libgoogle-glog0.install b/third_party/glog/packages/deb/libgoogle-glog0.install
new file mode 100644
index 000000000000..704ea87ab754
--- /dev/null
+++ b/third_party/glog/packages/deb/libgoogle-glog0.install
@@ -0,0 +1,2 @@
+usr/lib/lib*.so.*
+debian/tmp/usr/lib/lib*.so.*
diff --git a/third_party/glog/packages/deb/rules b/third_party/glog/packages/deb/rules
new file mode 100755
index 000000000000..f520befd259d
--- /dev/null
+++ b/third_party/glog/packages/deb/rules
@@ -0,0 +1,117 @@
+#!/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_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+	INSTALL_PROGRAM += -s
+endif
+
+# shared library versions, option 1
+#version=2.0.5
+#major=2
+# option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so
+version=`ls src/.libs/lib*.so.* | \
+ awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'`
+major=`ls src/.libs/lib*.so.* | \
+ awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'`
+
+config.status: configure
+	dh_testdir
+	# Add here commands to configure the package.
+	CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info
+
+
+build: build-stamp
+build-stamp:  config.status
+	dh_testdir
+
+	# Add here commands to compile the package.
+	$(MAKE)
+
+	touch build-stamp
+
+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
+
+
+	dh_clean 
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k 
+	dh_installdirs
+
+	# Add here commands to install the package into debian/tmp
+	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
+
+
+# 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 ChangeLog
+	dh_installdocs
+	dh_installexamples
+	dh_install --sourcedir=debian/tmp
+#	dh_installmenu
+#	dh_installdebconf	
+#	dh_installlogrotate
+#	dh_installemacsen
+#	dh_installpam
+#	dh_installmime
+#	dh_installinit
+#	dh_installcron
+#	dh_installinfo
+	dh_installman
+	dh_link
+	dh_strip
+	dh_compress
+	dh_fixperms
+#	dh_perl
+#	dh_python
+	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/third_party/glog/packages/rpm.sh b/third_party/glog/packages/rpm.sh
new file mode 100755
index 000000000000..e5649a22581b
--- /dev/null
+++ b/third_party/glog/packages/rpm.sh
@@ -0,0 +1,75 @@
+#!/bin/sh -e
+
+# Run this from the 'packages' directory, just under rootdir
+
+# We can only build rpm packages, if the rpm build tools are installed
+if [ \! -x /usr/bin/rpmbuild ]
+then
+  echo "Cannot find /usr/bin/rpmbuild. Not building an rpm." 1>&2
+  exit 0
+fi
+
+# Check the commandline flags
+PACKAGE="$1"
+VERSION="$2"
+fullname="${PACKAGE}-${VERSION}"
+archive=../$fullname.tar.gz
+
+if [ -z "$1" -o -z "$2" ]
+then
+  echo "Usage: $0 <package name> <package version>" 1>&2
+  exit 0
+fi
+
+# Double-check we're in the packages directory, just under rootdir
+if [ \! -r ../Makefile -a \! -r ../INSTALL ]
+then
+  echo "Must run $0 in the 'packages' directory, under the root directory." 1>&2
+  echo "Also, you must run \"make dist\" before running this script." 1>&2
+  exit 0
+fi
+
+if [ \! -r "$archive" ]
+then
+  echo "Cannot find $archive. Run \"make dist\" first." 1>&2
+  exit 0
+fi
+
+# Create the directory where the input lives, and where the output should live
+RPM_SOURCE_DIR="/tmp/rpmsource-$fullname"
+RPM_BUILD_DIR="/tmp/rpmbuild-$fullname"
+
+trap 'rm -rf $RPM_SOURCE_DIR $RPM_BUILD_DIR; exit $?' EXIT SIGHUP SIGINT SIGTERM
+
+rm -rf "$RPM_SOURCE_DIR" "$RPM_BUILD_DIR"
+mkdir "$RPM_SOURCE_DIR"
+mkdir "$RPM_BUILD_DIR"
+
+cp "$archive" "$RPM_SOURCE_DIR"/v"$VERSION".tar.gz
+
+rpmbuild -bb rpm/rpm.spec \
+  --define "NAME $PACKAGE" \
+  --define "VERSION $VERSION" \
+  --define "_sourcedir $RPM_SOURCE_DIR" \
+  --define "_builddir $RPM_BUILD_DIR" \
+  --define "_rpmdir $RPM_SOURCE_DIR"
+
+# We put the output in a directory based on what system we've built for
+destdir=rpm-unknown
+if [ -r /etc/issue ]
+then
+   grep "Red Hat.*release 7" /etc/issue >/dev/null 2>&1 && destdir=rh7
+   grep "Red Hat.*release 8" /etc/issue >/dev/null 2>&1 && destdir=rh8
+   grep "Red Hat.*release 9" /etc/issue >/dev/null 2>&1 && destdir=rh9
+   if grep Fedora /etc/issue >/dev/null; then 
+	destdir=fc`grep Fedora /etc/issue | cut -d' ' -f 4`;
+   fi
+fi
+
+rm -rf "$destdir"
+mkdir -p "$destdir"
+# We want to get not only the main package but devel etc, hence the middle *
+mv "$RPM_SOURCE_DIR"/*/"${PACKAGE}"-*"${VERSION}"*.rpm "$destdir"
+
+echo
+echo "The rpm package file(s) are located in $PWD/$destdir"
diff --git a/third_party/glog/packages/rpm/rpm.spec b/third_party/glog/packages/rpm/rpm.spec
new file mode 100644
index 000000000000..24ef134df520
--- /dev/null
+++ b/third_party/glog/packages/rpm/rpm.spec
@@ -0,0 +1,72 @@
+%define	RELEASE	1
+%define rel     %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}
+%define	prefix	/usr
+
+Name: %NAME
+Summary: A C++ application logging library
+Version: %VERSION
+Release: %rel
+Group: Development/Libraries
+URL: http://github.com/google/glog
+License: BSD
+Vendor: Google
+Packager: Google Inc. <opensource@google.com>
+Source: https://github.com/google/glog/archive/v%{VERSION}.tar.gz
+Distribution: Redhat 7 and above.
+Buildroot: %{_tmppath}/%{name}-root
+Prefix: %prefix
+
+%description
+The %name package contains a library that implements application-level
+logging.  This library provides logging APIs based on C++-style
+streams and various helper macros.
+
+%package devel
+Summary: A C++ application logging library
+Group: Development/Libraries
+Requires: %{NAME} = %{VERSION}
+
+%description devel
+The %name-devel package contains static and debug libraries and header
+files for developing applications that use the %name package.
+
+%changelog
+    * Wed Mar 26 2008 <opensource@google.com>
+    - First draft
+
+%prep
+%setup
+
+%build
+./configure
+make prefix=%prefix
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make prefix=$RPM_BUILD_ROOT%{prefix} install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(-,root,root)
+
+## Mark all installed files within /usr/share/doc/{package name} as
+## documentation.  This depends on the following two lines appearing in
+## Makefile.am:
+##     docdir = $(prefix)/share/doc/$(PACKAGE)-$(VERSION)
+##     dist_doc_DATA = AUTHORS COPYING ChangeLog INSTALL README.md
+%docdir %{prefix}/share/doc/%{NAME}-%{VERSION}
+%{prefix}/share/doc/%{NAME}-%{VERSION}/*
+
+%{prefix}/lib/libglog.so.0
+%{prefix}/lib/libglog.so.0.0.0
+
+%files devel
+%defattr(-,root,root)
+
+%{prefix}/include/glog
+%{prefix}/lib/libglog.a
+%{prefix}/lib/libglog.la
+%{prefix}/lib/libglog.so
+%{prefix}/lib/pkgconfig/libglog.pc