Browse Source

new package

master
parent
commit
95756c733a
  1. 70
      libxo/libxo.patch
  2. 89
      libxo/libxo.spec

70
libxo/libxo.patch

@ -0,0 +1,70 @@
Index: configure.ac
--- configure.ac.orig 2015-01-15 22:14:25.000000000 +0100
+++ configure.ac 2015-02-21 14:45:49.505762519 +0100
@@ -13,7 +13,7 @@
AC_PREREQ(2.2)
AC_INIT([libxo], [0.2.0], [phil@juniper.net])
-AM_INIT_AUTOMAKE([-Wall -Werror foreign -Wno-portability])
+AM_INIT_AUTOMAKE([foreign])
# Support silent build rules. Requires at least automake-1.11.
# Disable with "configure --disable-silent-rules" or "make V=1"
Index: libxo/Makefile.am
--- libxo/Makefile.am.orig 2014-10-21 03:33:31.000000000 +0200
+++ libxo/Makefile.am 2015-02-21 14:45:49.505762519 +0100
@@ -26,24 +26,4 @@
libxo_la_SOURCES = \
libxo.c
-man_MANS = \
- libxo.3 \
- xo_attr.3 \
- xo_create.3 \
- xo_emit.3 \
- xo_err.3 \
- xo_finish.3 \
- xo_flush.3 \
- xo_format.5 \
- xo_no_setlocale.3 \
- xo_open_container.3 \
- xo_open_list.3 \
- xo_parse_args.3 \
- xo_set_allocator.3 \
- xo_set_flags.3 \
- xo_set_info.3 \
- xo_set_options.3 \
- xo_set_style.3 \
- xo_set_writer.3
-
EXTRA_DIST =
Index: libxo/xo.h
--- libxo/xo.h.orig 2015-01-15 22:12:53.000000000 +0100
+++ libxo/xo.h 2015-02-21 14:46:52.005747433 +0100
@@ -17,6 +17,8 @@
#ifndef INCLUDE_XO_H
#define INCLUDE_XO_H
+#include <stdarg.h>
+
/** Formatting types */
typedef unsigned xo_style_t;
#define XO_STYLE_TEXT 0 /** Generate text output */
Index: warnings.mk
--- warnings.mk.orig 2014-08-30 04:46:54.000000000 +0200
+++ warnings.mk 2015-02-21 14:45:49.505762519 +0100
@@ -11,12 +11,9 @@
# Commonly used sets of warnings
#
-MIN_WARNINGS?= -W -Wall
+MIN_WARNINGS?=
-LOW_WARNINGS?= ${MIN_WARNINGS} \
- -Wstrict-prototypes \
- -Wmissing-prototypes \
- -Wpointer-arith
+LOW_WARNINGS?= ${MIN_WARNINGS}
MEDIUM_WARNINGS?= ${LOW_WARNINGS} -Werror

89
libxo/libxo.spec

@ -0,0 +1,89 @@
##
## libxo.spec -- OpenPKG RPM Package Specification
## Copyright (c) 2000-2015 OpenPKG Foundation e.V. <http://openpkg.net/>
##
## Permission to use, copy, modify, and distribute this software for
## any purpose with or without fee is hereby granted, provided that
## the above copyright notice and this permission notice appear in all
## copies.
##
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 AUTHORS AND COPYRIGHT HOLDERS AND THEIR
## 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.
##
# package information
Name: libxo
Summary: Extended Output Library
URL: http://juniper.github.io/libxo/libxo-manual.html
Vendor: Juniper Networks, Inc.
Packager: OpenPKG Foundation e.V.
Distribution: OpenPKG Community
Class: EVAL
Group: Libraries
License: BSD
Version: 0.2.0
Release: 20150221
# list of sources
Source0: https://github.com/Juniper/libxo/releases/download/%{version}/libxo-%{version}.tar.gz
Patch0: libxo.patch
# build information
BuildPreReq: OpenPKG, openpkg >= 20140101, autoconf, automake, libtool
PreReq: OpenPKG, openpkg >= 20140101
%description
XO is a C Library for Generating Text, XML, JSON, and HTML Output.
The libxo library allows an application to generate text, XML,
JSON, and HTML output using a common set of function calls. The
application decides at run time which output style should be
produced. The application calls a function xo_emit() to product
output that is described in a format string.
%track
prog libxo = {
version = %{version}
url = https://github.com/Juniper/libxo/releases
regex = libxo-(__VER__)\.tar\.gz
}
%prep
%setup -q
%patch -p0
%build
aclocal
libtoolize
automake
autoconf
CC="%{l_cc}" \
CFLAGS="%{l_cflags -O}" \
CPPFLAGS="%{l_cppflags}" \
LDFLAGS="%{l_ldflags}" \
./configure \
--prefix=%{l_prefix} \
--mandir=%{l_prefix}/man \
--disable-warnings \
--disable-shared
%{l_make} %{l_mflags -O}
%install
%{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT"
strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/doc
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
%files -f files
%clean
Loading…
Cancel
Save