Commit 7e5ddbcb authored by Maxime Hadjinlian's avatar Maxime Hadjinlian Committed by Thomas Petazzoni
Browse files

zxing-cpp: new package, replacing zxing



ZXing was hosted on Google Code, which is a closing. The current link
was already redirecting to the github repo.

But upstream is no longer supporting the cpp bindings, it's now a Java
library/application.

A fork has been created from the latest cpp source of the original
upstream. So this commit creates a new package, zxing-cpp, and adds
Config.in.legacy handling for the old zxing pakcage that is removed.

[Thomas:
  - add a patch that improves the CMakeLists.txt file to add
    installation rules. This allows to remove the manual installation
    logic from zxing-cpp.mk.
  - make libiconv a normal optional dependency. No need to involve
    BR2_ENABLE_LOCALE in the condition, since libiconv can only be
    enabled when !BR2_ENABLE_LOCALE.
  - bump to the latest upstream version.
  - add hash file.]

Signed-off-by: default avatarMaxime Hadjinlian <maxime.hadjinlian@gmail.com>
Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
parent 0611258a
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -107,6 +107,14 @@ endif
###############################################################################
comment "Legacy options removed in 2015.11"

config BR2_PACKAGE_ZXING
	bool "zxing option has been renamed"
	select BR2_LEGACY
	select BR2_PACKAGE_ZXING_CPP
	help
	  ZXing no longer provides the cpp bindings, it has been renamed to
	  BR2_PACKAGE_ZXING_CPP which uses a new upstream.

# Since FreeRDP has new dependencies, protect this legacy to avoid the
# infamous "unmet direct dependencies" kconfig error.
config BR2_PACKAGE_FREERDP_CLIENT
+1 −1
Original line number Diff line number Diff line
@@ -851,7 +851,7 @@ menu "Graphics"
	source "package/webkit/Config.in"
	source "package/webkitgtk24/Config.in"
	source "package/webp/Config.in"
	source "package/zxing/Config.in"
	source "package/zxing-cpp/Config.in"
endmenu

menu "Hardware handling"
+33 −0
Original line number Diff line number Diff line
From 2bc58a87dd629cef4cd2c62c5132c319bede61fa Mon Sep 17 00:00:00 2001
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Date: Sun, 4 Oct 2015 11:49:52 +0100
Subject: [PATCH] CMakeLists: add rules for installation

This commit adds some CMake rules that allow to do a "make install" to
install the zxing binary, its library and corresponding header files.

Submitted upstream: https://github.com/glassechidna/zxing-cpp/pull/31

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
 CMakeLists.txt | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index f49b28d..7151d90 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -68,6 +68,10 @@ file(GLOB_RECURSE ZXING_FILES
 )
 add_executable(zxing ${ZXING_FILES})
 target_link_libraries(zxing libzxing)
+install(TARGETS zxing libzxing
+	LIBRARY DESTINATION lib
+	RUNTIME DESTINATION bin)
+install(DIRECTORY core/src/zxing/ DESTINATION include/zxing FILES_MATCHING PATTERN "*.h")
 
 # Add testrunner executable.
 find_package(CPPUNIT)
-- 
2.6.0
+5 −5
Original line number Diff line number Diff line
comment "zxing needs a toolchain w/ C++"
comment "zxing-cpp needs a toolchain w/ C++"
	depends on !BR2_INSTALL_LIBSTDCPP

config BR2_PACKAGE_ZXING
	bool "zxing"
config BR2_PACKAGE_ZXING_CPP
	bool "zxing-cpp"
	depends on BR2_INSTALL_LIBSTDCPP
	help
	  ZXing (pronounced "zebra crossing") is an open-source,
	  ZXing-cpp (pronounced "zebra crossing") is an open-source,
	  multi-format 1D/2D barcode image processing library
	  implemented in Java, with ports to other languages. This
	  compiles the C++ port.

	  http://code.google.com/p/zxing/
	  https://github.com/glassechidna/zxing-cpp
+2 −0
Original line number Diff line number Diff line
# Locally calculated
sha256 c3934e9e59b7496c9a4db7ad4d8eb43668da4b321ec705feebaf085b185b2d08 zxing-cpp-4abdbb62c9939014eca3e43ac7dfa30daa344536.tar.gz
Loading