summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gbs.conf3
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac4
-rw-r--r--examples/Makefile.am2
-rw-r--r--libusbg.pc.in (renamed from libusbgx.pc.in)2
-rw-r--r--packaging/libusbg.manifest6
-rw-r--r--packaging/libusbg.spec75
-rw-r--r--src/Makefile.am14
-rw-r--r--tests/Makefile.am8
9 files changed, 100 insertions, 16 deletions
diff --git a/.gbs.conf b/.gbs.conf
new file mode 100644
index 0000000..99e7cc8
--- /dev/null
+++ b/.gbs.conf
@@ -0,0 +1,3 @@
+[general]
+upstream_branch = upstream
+upstream_tag = upstream/${upstreamversion}
diff --git a/Makefile.am b/Makefile.am
index 05e1379..d0e6e83 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -10,4 +10,4 @@ EXTRA_DIST = doxygen.cfg
library_includedir=$(includedir)/usbg
library_include_HEADERS = include/usbg/usbg.h
pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = libusbgx.pc
+pkgconfig_DATA = libusbg.pc
diff --git a/configure.ac b/configure.ac
index a456ba7..89f5dc9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT([libusbgx], [0.0.1], [k.opasiak@samsung.com])
+AC_INIT([libusbg], [0.1.0], [mporter@linaro.org])
AM_INIT_AUTOMAKE([1.12 -Wall -Werror foreign serial-tests])
AC_PROG_CC
AM_PROG_AR
@@ -46,6 +46,6 @@ AS_IF([test "x$enable_gadget_schemes" = xyes],
AM_CONDITIONAL(TEST_GADGET_SCHEMES, [test "x$enable_gadget_schemes" != xno])
LT_INIT
-AC_CONFIG_FILES([Makefile src/Makefile examples/Makefile libusbgx.pc doxygen.cfg])
+AC_CONFIG_FILES([Makefile src/Makefile examples/Makefile libusbg.pc doxygen.cfg])
DX_INIT_DOXYGEN([$PACKAGE_NAME],[doxygen.cfg])
AC_OUTPUT
diff --git a/examples/Makefile.am b/examples/Makefile.am
index 8c2acb2..36e0b9b 100644
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -7,4 +7,4 @@ gadget_export_SOURCE = gadget-export.c
gadget_import_SOURCE = gadget-import.c
show_udcs_SOURCE = show-udcs.c
AM_CPPFLAGS=-I$(top_srcdir)/include/
-AM_LDFLAGS=-L../src/ -lusbgx
+AM_LDFLAGS=-L../src/ -lusbg
diff --git a/libusbgx.pc.in b/libusbg.pc.in
index 8ea8fb5..e24d8d6 100644
--- a/libusbgx.pc.in
+++ b/libusbg.pc.in
@@ -3,7 +3,7 @@ exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
-Name: libusbgx
+Name: libusbg
Description: USB gadget-configfs library
Requires: libconfig
Version: @PACKAGE_VERSION@
diff --git a/packaging/libusbg.manifest b/packaging/libusbg.manifest
new file mode 100644
index 0000000..4819ac2
--- /dev/null
+++ b/packaging/libusbg.manifest
@@ -0,0 +1,6 @@
+<manifest>
+ <request>
+ <domain name="_"/>
+ </request>
+</manifest>
+
diff --git a/packaging/libusbg.spec b/packaging/libusbg.spec
new file mode 100644
index 0000000..8b99ea1
--- /dev/null
+++ b/packaging/libusbg.spec
@@ -0,0 +1,75 @@
+Name: libusbg
+Version: 0.1.0
+Release: 0
+License: LGPL-2.1+ and GPL-2.0+
+Summary: USB gadget with ConfigFS Library
+Group: Base/Device Management
+
+Source0: libusbg-%{version}.tar.gz
+Source1001: libusbg.manifest
+BuildRequires: pkg-config
+BuildRequires: pkgconfig(libconfig)
+
+%description
+Libusbg is a librarary for all USB gadget operations using ConfigFS.
+
+%package devel
+Summary: USB gadget with ConfigFS Library
+Group: Development/Libraries
+Requires: %{name} = %{version}-%{release}
+
+%description devel
+Development package for libusbg. Contains headers and binaries required for
+compilation of applications which use libusbg.
+
+%package examples
+Summary: Examples of libusbg usage
+Group: Applications/Other
+Requires: %{name} = %{version}-%{release}
+
+%description examples
+Sample applications which shows how to use libusbg.
+
+%prep
+%setup -q
+cp %{SOURCE1001} .
+%reconfigure
+
+%build
+make
+
+%install
+%make_install
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+%files
+%manifest %{name}.manifest
+%defattr(-,root,root)
+%license COPYING.LGPL
+%{_libdir}/libusbg.so.*
+%{_libdir}/libusbg.so.*.*.*
+
+%files devel
+%manifest %{name}.manifest
+%defattr(-,root,root)
+%{_includedir}/usbg/usbg.h
+%{_libdir}/pkgconfig/libusbg.pc
+%{_libdir}/libusbg.so
+
+%files examples
+%manifest %{name}.manifest
+%license COPYING
+%{_bindir}/gadget-acm-ecm
+%{_bindir}/show-gadgets
+%{_bindir}/gadget-vid-pid-remove
+%{_bindir}/gadget-ffs
+%{_bindir}/gadget-export
+%{_bindir}/gadget-import
+%{_bindir}/show-udcs
+%{_bindir}/gadget-ms
+%{_bindir}/gadget-midi
+
+%changelog
diff --git a/src/Makefile.am b/src/Makefile.am
index b1eb951..3e4bc77 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,11 +1,11 @@
-lib_LTLIBRARIES = libusbgx.la
-libusbgx_la_SOURCES = usbg.c
+lib_LTLIBRARIES = libusbg.la
+libusbg_la_SOURCES = usbg.c
if TEST_GADGET_SCHEMES
-libusbgx_la_SOURCES += usbg_schemes_libconfig.c
+libusbg_la_SOURCES += usbg_schemes_libconfig.c
else
-libusbgx_la_SOURCES += usbg_schemes_none.c
+libusbg_la_SOURCES += usbg_schemes_none.c
endif
-libusbgx_la_LDFLAGS = $(LIBCONFIG_LIBS)
-libusbgx_la_LDFLAGS += -version-info 0:0:0
-libusbgx_la_CFLAGS = $(LIBCONFIG_CFLAGS)
+libusbg_la_LDFLAGS = $(LIBCONFIG_LIBS)
+libusbg_la_LDFLAGS += -version-info 0:1:0
+libusbg_la_CFLAGS = $(LIBCONFIG_CFLAGS)
AM_CPPFLAGS=-I$(top_srcdir)/include/
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 01feea4..9895192 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -3,12 +3,12 @@ test_SOURCES = test.c usbg-test.c usbg-io-wrappers.c
test_LDFLAGS = -ldl
test_LDFLAGS += $(CMOCKA_LIBS)
test_LDFLAGS += $(LIBCONFIG_LIBS)
-test_LDADD = ./libusbgx.so
+test_LDADD = ./libusbg.so
test_CPPFLAGS = -I$(top_srcdir)/include/
-./libusbgx.so:
- -ln -s $(top_srcdir)/src/.libs/libusbgx.so* .
-CLEANFILES = libusbgx.so*
+./libusbg.so:
+ -ln -s $(top_srcdir)/src/.libs/libusbg.so* .
+CLEANFILES = libusbg.so*
check_SCRIPTS = ./test.sh
TESTS = $(check_SCRIPTS)