Skip to contentSkip to conversation

libgphoto2: new package

PATCH Superseded Kevin JOLY 3 participants 5 messages Apr 10, 2017 – Apr 11, 2017

v3 of 4 Superseded Latest is v4 →

lore
Share & tools
lore

Kevin JOLY

author
#0 lore raw

PATCH v3 1/1 libgphoto2: new package

Add support for libgphoto2 core library designed to allow access to digital camera.

---
Changes v2 -> v3 (suggested by Arnout Vandecappelle)
- Change the commit description
- Turn libusb-compat as an optional dependency
- Add the BR2_TOOLCHAIN_HAS_THREADS dependency
- Update package website location
- Update version to 2.5.13
- Add comments
- Improve configure options
- Update license informations

Changes v1 -> v2 (suggested by Romain Naour)
- Handle optionnal dependencies on libexif, libjpeg, libgd and lockdev
- Add license informations
- Use tar.bz2 package
- Change hash
- Added myself as package maintainer in the DEVELOPPERS file

---
 DEVELOPERS                         |  3 +++
 package/Config.in                  |  1 +
 package/libgphoto2/Config.in       | 14 +++++++++++
 package/libgphoto2/libgphoto2.hash |  6 +++++
 package/libgphoto2/libgphoto2.mk   | 50 ++++++++++++++++++++++++++++++++++++++
 5 files changed, 74 insertions(+)
 create mode 100644 package/libgphoto2/Config.in
 create mode 100644 package/libgphoto2/libgphoto2.hash
 create mode 100644 package/libgphoto2/libgphoto2.mk
DEVELOPERS +3 -0
index a298669..1f45012 100644
@@ -957,6 +957,9 @@ F:	package/cpuload/
 F:	package/bwm-ng/
 F:	package/ramsmp/
 
+N:	Kevin Joly <[email protected]>
+F:	package/libgphoto2/
+
 N:	Laurent Cans <[email protected]>
 F:	package/aircrack-ng/
 
package/Config.in +1 -0
index c12e5b5..f98a2b5 100644
@@ -1086,6 +1086,7 @@ menu "Hardware handling"
 	source "package/libfreefare/Config.in"
 	source "package/libftdi/Config.in"
 	source "package/libftdi1/Config.in"
+	source "package/libgphoto2/Config.in"
 	source "package/libgpiod/Config.in"
 	source "package/libgudev/Config.in"
 	source "package/libhid/Config.in"
package/libgphoto2/Config.in new file +14 -0
new file mode 100644
index 0000000..fd53232
@@ -0,0 +1,14 @@
+config BR2_PACKAGE_LIBGPHOTO2
+	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	select BR2_PACKAGE_LIBTOOL
+	select BR2_PACKAGE_LIBUSB
+	select BR2_PACKAGE_LIBXML2
+	bool "libgphoto2"
+	help
+	  libgphoto2 is the core library designed to allow access to
+	  digital camera by external programs.
+
+	  http://gphoto.org/proj/libgphoto2/
+
+comment "libgphoto needs a toolchain w threads"
+	depends on !BR2_TOOLCHAIN_HAS_THREADS
package/libgphoto2/libgphoto2.hash new file +6 -0
new file mode 100644
index 0000000..1afe275
@@ -0,0 +1,6 @@
+# https://sourceforge.net/projects/gphoto/files/libgphoto/2.5.13/
+md5 73bf5b3d94c8c6f5fad9ea6b5e561843 libgphoto2-2.5.13.tar.bz2
+sha1 cef2d2f1930f8ada16a63aca15683188231a626a libgphoto2-2.5.13.tar.bz2
+
+# Locally calculated hash
+sha256 ceaacbdf187d1cd1aed5336991f46b0100f6960b6c8383f9aeab98f1f64780ef libgphoto2-2.5.13.tar.bz2
package/libgphoto2/libgphoto2.mk new file +50 -0

50 lines not on this page · raw message

Signature · 1 line
2.7.4
#1 lore raw

PATCH v3 1/1 libgphoto2: new package

Quoted 5 lines · Kevin JOLY

Add support for libgphoto2 core library designed to allow access to digital camera.

Except for some minor issues and one style issue in Config.in (see below), it
all looks good. I've already ran test-pkg for a dozen toolchains and it looks good. So

Quoted 60 lines

---
Changes v2 -> v3 (suggested by Arnout Vandecappelle)
- Change the commit description
- Turn libusb-compat as an optional dependency
- Add the BR2_TOOLCHAIN_HAS_THREADS dependency
- Update package website location
- Update version to 2.5.13
- Add comments
- Improve configure options
- Update license informations

Changes v1 -> v2 (suggested by Romain Naour)
- Handle optionnal dependencies on libexif, libjpeg, libgd and lockdev
- Add license informations
- Use tar.bz2 package
- Change hash
- Added myself as package maintainer in the DEVELOPPERS file

---
 DEVELOPERS                         |  3 +++
 package/Config.in                  |  1 +
 package/libgphoto2/Config.in       | 14 +++++++++++
 package/libgphoto2/libgphoto2.hash |  6 +++++
 package/libgphoto2/libgphoto2.mk   | 50 ++++++++++++++++++++++++++++++++++++++
 5 files changed, 74 insertions(+)
 create mode 100644 package/libgphoto2/Config.in
 create mode 100644 package/libgphoto2/libgphoto2.hash
 create mode 100644 package/libgphoto2/libgphoto2.mk
DEVELOPERS +3 -0
index a298669..1f45012 100644
@@ -957,6 +957,9 @@ F:	package/cpuload/
 F:	package/bwm-ng/
 F:	package/ramsmp/
 
+N:	Kevin Joly <[email protected]>
+F:	package/libgphoto2/
+
 N:	Laurent Cans <[email protected]>
 F:	package/aircrack-ng/
 
package/Config.in +1 -0
index c12e5b5..f98a2b5 100644
@@ -1086,6 +1086,7 @@ menu "Hardware handling"
 	source "package/libfreefare/Config.in"
 	source "package/libftdi/Config.in"
 	source "package/libftdi1/Config.in"
+	source "package/libgphoto2/Config.in"
 	source "package/libgpiod/Config.in"
 	source "package/libgudev/Config.in"
 	source "package/libhid/Config.in"
package/libgphoto2/Config.in new file +0 -0
new file mode 100644
index 0000000..fd53232

package/libgphoto2/Config.in line 6

Quoted 6 lines
package/libgphoto2/Config.in new file +6 -0
@@ -0,0 +1,14 @@
+config BR2_PACKAGE_LIBGPHOTO2
+	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	select BR2_PACKAGE_LIBTOOL
+	select BR2_PACKAGE_LIBUSB
+	select BR2_PACKAGE_LIBXML2
+	bool "libgphoto2"

This should come right below the config line.
(you can now run './support/scripts/check-package package/libgphoto2/*' to detect this kind of error).

package/libgphoto2/Config.in line 13

Quoted 7 lines
package/libgphoto2/Config.in new file +7 -0
+	help
+	  libgphoto2 is the core library designed to allow access to
+	  digital camera by external programs.
+
+	  http://gphoto.org/proj/libgphoto2/
+
+comment "libgphoto needs a toolchain w threads"
                                        ^w/
Quoted 28 lines
package/libgphoto2/Config.in new file +1 -0
+	depends on !BR2_TOOLCHAIN_HAS_THREADS
package/libgphoto2/libgphoto2.hash new file +6 -0
new file mode 100644
index 0000000..1afe275
@@ -0,0 +1,6 @@
+# https://sourceforge.net/projects/gphoto/files/libgphoto/2.5.13/
+md5 73bf5b3d94c8c6f5fad9ea6b5e561843 libgphoto2-2.5.13.tar.bz2
+sha1 cef2d2f1930f8ada16a63aca15683188231a626a libgphoto2-2.5.13.tar.bz2
+
+# Locally calculated hash
+sha256 ceaacbdf187d1cd1aed5336991f46b0100f6960b6c8383f9aeab98f1f64780ef libgphoto2-2.5.13.tar.bz2
package/libgphoto2/libgphoto2.mk new file +9 -0
new file mode 100644
index 0000000..24dac19
@@ -0,0 +1,50 @@
+################################################################################
+#
+# libgphoto2
+#
+################################################################################
+
+LIBGPHOTO2_VERSION = 2.5.13
+LIBGPHOTO2_SOURCE = libgphoto2-$(LIBGPHOTO2_VERSION).tar.bz2
+# Project is maintained on github but github tarball doesn't have configure

package/libgphoto2/libgphoto2.mk line 19

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+LIBGPHOTO2_SITE = https://sourceforge.net/projects/gphoto/files/libgphoto/$(LIBGPHOTO2_VERSION)
+LIBGPHOTO2_INSTALL_STAGING = YES
+
+LIBGPHOTO2_LICENSE = LGPL-2.1+, GPL-2.0 (adc65), GPL-2.0+ (some camlibs), \
+	LGPL-2.0 (sipix), LGPL-3.0+ (pentax), BSD-3-Clause (ax203/tinyjpeg).
+LIBGPHOTO2_LICENSE_FILES = COPYING
+# No license files for other licenses
+
+LIBGPHOTO2_DEPENDENCIES = libxml2 libusb libtool host-pkgconf
+LIBGPHOTO2_CONF_OPTS += --disable-rpm

It might be good to also add --disable-gp2ddb --disable-internal-docs but these
are anyway disabled by default so not so important.

package/libgphoto2/libgphoto2.mk line 21

Quoted 2 lines
package/libgphoto2/libgphoto2.mk new file +2 -0
+
+ifeq ($(BR2_PACKAGE_LIBUSB_COMPAT),y)

Maybe add

# libusb-compat is not actually used, but it is detected, so add it here to
# guarantee reproducible builds
Quoted 16 lines
package/libgphoto2/libgphoto2.mk new file +16 -0
+LIBGPHOTO2_DEPENDENCIES += libusb-compat
+endif
+
+ifeq ($(BR2_PACKAGE_LIBEXIF),y)
+LIBGPHOTO2_DEPENDENCIES += libexif
+LIBGPHOTO2_CONF_OPTS += --with-libexif=auto
+else
+LIBGPHOTO2_CONF_OPTS += --with-libexif=no
+endif
+
+ifeq ($(BR2_PACKAGE_LIBJPEG),y)
+LIBGPHOTO2_DEPENDENCIES += libjpeg
+LIBGPHOTO2_CONF_OPTS += --with-jpeg
+else
+LIBGPHOTO2_CONF_OPTS += --without-jpeg
+endif

package/libgphoto2/libgphoto2.mk line 47

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+
+ifeq ($(BR2_PACKAGE_GD),y)
+LIBGPHOTO2_DEPENDENCIES += gd
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=auto
+else
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=no
+endif
+
+ifeq ($(BR2_PACKAGE_LOCKDEV),y)
+LIBGPHOTO2_DEPENDENCIES += lockdev

Good catch!

Quoted 4 lines
package/libgphoto2/libgphoto2.mk new file +3 -0
+endif
+
+$(eval $(autotools-package))
Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
#2 lore raw

PATCH v3 1/1 libgphoto2: new package

Quoted 6 lines · Arnout Vandecappelle
Quoted 3 lines · Kevin JOLY

Add support for libgphoto2 core library designed to allow access to digital camera.

Quoted 8 lines
Quoted 2 lines

Except for some minor issues and one style issue in Config.in (see below), it
all looks good. I've already ran test-pkg for a dozen toolchains and it looks good. So

Oh, there is one important issue after all: it installs something in
/usr/lib/udev, but that should be /lib/udev. So you need to set

LIBGPHOTO2_CONF_ENV = udevscriptdir=/lib/udev

With that, you can add my Acked-by to v4.

Regards,
Arnout

[snip]

Signature · 6 lines
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
#3 lore raw

PATCH v3 1/1 libgphoto2: new package

In reply to Arnout Vandecappelle

Hi Kevin, Arnout,

Le 10/04/2017 ? 15:14, Arnout Vandecappelle a ?crit :

Quoted 12 lines · Kevin JOLY
Quoted 5 lines

Add support for libgphoto2 core library designed to allow access to digital camera.

Except for some minor issues and one style issue in Config.in (see below), it
all looks good. I've already ran test-pkg for a dozen toolchains and it looks good. So

Thank Arnout for the review.
With your last

Quoted 133 lines
Quoted 60 lines

---
Changes v2 -> v3 (suggested by Arnout Vandecappelle)
- Change the commit description
- Turn libusb-compat as an optional dependency
- Add the BR2_TOOLCHAIN_HAS_THREADS dependency
- Update package website location
- Update version to 2.5.13
- Add comments
- Improve configure options
- Update license informations

Changes v1 -> v2 (suggested by Romain Naour)
- Handle optionnal dependencies on libexif, libjpeg, libgd and lockdev
- Add license informations
- Use tar.bz2 package
- Change hash
- Added myself as package maintainer in the DEVELOPPERS file

---
 DEVELOPERS                         |  3 +++
 package/Config.in                  |  1 +
 package/libgphoto2/Config.in       | 14 +++++++++++
 package/libgphoto2/libgphoto2.hash |  6 +++++
 package/libgphoto2/libgphoto2.mk   | 50 ++++++++++++++++++++++++++++++++++++++
 5 files changed, 74 insertions(+)
 create mode 100644 package/libgphoto2/Config.in
 create mode 100644 package/libgphoto2/libgphoto2.hash
 create mode 100644 package/libgphoto2/libgphoto2.mk
DEVELOPERS +3 -0
index a298669..1f45012 100644
@@ -957,6 +957,9 @@ F:	package/cpuload/
 F:	package/bwm-ng/
 F:	package/ramsmp/
 
+N:	Kevin Joly <[email protected]>
+F:	package/libgphoto2/
+
 N:	Laurent Cans <[email protected]>
 F:	package/aircrack-ng/
 
package/Config.in +1 -0
index c12e5b5..f98a2b5 100644
@@ -1086,6 +1086,7 @@ menu "Hardware handling"
 	source "package/libfreefare/Config.in"
 	source "package/libftdi/Config.in"
 	source "package/libftdi1/Config.in"
+	source "package/libgphoto2/Config.in"
 	source "package/libgpiod/Config.in"
 	source "package/libgudev/Config.in"
 	source "package/libhid/Config.in"
package/libgphoto2/Config.in new file +0 -0
new file mode 100644
index 0000000..fd53232

package/libgphoto2/Config.in line 6

Quoted 6 lines
package/libgphoto2/Config.in new file +6 -0
@@ -0,0 +1,14 @@
+config BR2_PACKAGE_LIBGPHOTO2
+	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	select BR2_PACKAGE_LIBTOOL
+	select BR2_PACKAGE_LIBUSB
+	select BR2_PACKAGE_LIBXML2
+	bool "libgphoto2"

This should come right below the config line.
(you can now run './support/scripts/check-package package/libgphoto2/*' to detect this kind of error).

package/libgphoto2/Config.in line 13

Quoted 7 lines
package/libgphoto2/Config.in new file +7 -0
+	help
+	  libgphoto2 is the core library designed to allow access to
+	  digital camera by external programs.
+
+	  http://gphoto.org/proj/libgphoto2/
+
+comment "libgphoto needs a toolchain w threads"
                                        ^w/
Quoted 28 lines
package/libgphoto2/Config.in new file +1 -0
+	depends on !BR2_TOOLCHAIN_HAS_THREADS
package/libgphoto2/libgphoto2.hash new file +6 -0
new file mode 100644
index 0000000..1afe275
@@ -0,0 +1,6 @@
+# https://sourceforge.net/projects/gphoto/files/libgphoto/2.5.13/
+md5 73bf5b3d94c8c6f5fad9ea6b5e561843 libgphoto2-2.5.13.tar.bz2
+sha1 cef2d2f1930f8ada16a63aca15683188231a626a libgphoto2-2.5.13.tar.bz2
+
+# Locally calculated hash
+sha256 ceaacbdf187d1cd1aed5336991f46b0100f6960b6c8383f9aeab98f1f64780ef libgphoto2-2.5.13.tar.bz2
package/libgphoto2/libgphoto2.mk new file +9 -0
new file mode 100644
index 0000000..24dac19
@@ -0,0 +1,50 @@
+################################################################################
+#
+# libgphoto2
+#
+################################################################################
+
+LIBGPHOTO2_VERSION = 2.5.13
+LIBGPHOTO2_SOURCE = libgphoto2-$(LIBGPHOTO2_VERSION).tar.bz2
+# Project is maintained on github but github tarball doesn't have configure

package/libgphoto2/libgphoto2.mk line 19

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+LIBGPHOTO2_SITE = https://sourceforge.net/projects/gphoto/files/libgphoto/$(LIBGPHOTO2_VERSION)
+LIBGPHOTO2_INSTALL_STAGING = YES
+
+LIBGPHOTO2_LICENSE = LGPL-2.1+, GPL-2.0 (adc65), GPL-2.0+ (some camlibs), \
+	LGPL-2.0 (sipix), LGPL-3.0+ (pentax), BSD-3-Clause (ax203/tinyjpeg).
+LIBGPHOTO2_LICENSE_FILES = COPYING
+# No license files for other licenses
+
+LIBGPHOTO2_DEPENDENCIES = libxml2 libusb libtool host-pkgconf
+LIBGPHOTO2_CONF_OPTS += --disable-rpm

It might be good to also add --disable-gp2ddb --disable-internal-docs but these
are anyway disabled by default so not so important.

package/libgphoto2/libgphoto2.mk line 21

Quoted 2 lines
package/libgphoto2/libgphoto2.mk new file +2 -0
+
+ifeq ($(BR2_PACKAGE_LIBUSB_COMPAT),y)

Maybe add

# libusb-compat is not actually used, but it is detected, so add it here to
# guarantee reproducible builds
Quoted 16 lines
Quoted 6 lines
package/libgphoto2/libgphoto2.mk new file +6 -0
+LIBGPHOTO2_DEPENDENCIES += libusb-compat
+endif
+
+ifeq ($(BR2_PACKAGE_LIBEXIF),y)
+LIBGPHOTO2_DEPENDENCIES += libexif
+LIBGPHOTO2_CONF_OPTS += --with-libexif=auto

package/libgphoto2/libgphoto2.mk line 37

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+else
+LIBGPHOTO2_CONF_OPTS += --with-libexif=no
+endif
+
+ifeq ($(BR2_PACKAGE_LIBJPEG),y)
+LIBGPHOTO2_DEPENDENCIES += libjpeg
+LIBGPHOTO2_CONF_OPTS += --with-jpeg
+else
+LIBGPHOTO2_CONF_OPTS += --without-jpeg
+endif

libjpeg is a jpeg provider like jpeg-tubo

Can you try with:

ifeq ($(BR2_PACKAGE_JPEG),y)
LIBGPHOTO2_DEPENDENCIES += jpeg
LIBGPHOTO2_CONF_OPTS += --with-jpeg
else
LIBGPHOTO2_CONF_OPTS += --without-jpeg
endif

and jped-turbo enabled ?

Quoted 4 lines
Quoted 4 lines
package/libgphoto2/libgphoto2.mk new file +4 -0
+
+ifeq ($(BR2_PACKAGE_GD),y)
+LIBGPHOTO2_DEPENDENCIES += gd
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=auto
Quoted 8 lines

package/libgphoto2/libgphoto2.mk line 47

Quoted 6 lines
package/libgphoto2/libgphoto2.mk new file +6 -0
+else
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=no
+endif
+
+ifeq ($(BR2_PACKAGE_LOCKDEV),y)
+LIBGPHOTO2_DEPENDENCIES += lockdev

Good catch!

I had this one in my initial patch but not as optional dependency :p

I think, the v4 will be the last :)

Best regards,
Romain

Quoted 6 lines
Quoted 5 lines
package/libgphoto2/libgphoto2.mk new file +3 -0
+endif
+
+$(eval $(autotools-package))
author
#4 lore raw

PATCH v3 1/1 libgphoto2: new package

Hi Romain, Arnout,

Le 10. 04. 17 ? 20:51, Romain Naour a ?crit :

Quoted 165 lines

Hi Kevin, Arnout,

Le 10/04/2017 ? 15:14, Arnout Vandecappelle a ?crit :

Quoted 10 lines · Kevin JOLY
Quoted 5 lines

Add support for libgphoto2 core library designed to allow access to digital camera.

Except for some minor issues and one style issue in Config.in (see below), it
all looks good. I've already ran test-pkg for a dozen toolchains and it looks good. So

Thank Arnout for the review.
With your last

Quoted 129 lines
Quoted 60 lines

---
Changes v2 -> v3 (suggested by Arnout Vandecappelle)
- Change the commit description
- Turn libusb-compat as an optional dependency
- Add the BR2_TOOLCHAIN_HAS_THREADS dependency
- Update package website location
- Update version to 2.5.13
- Add comments
- Improve configure options
- Update license informations

Changes v1 -> v2 (suggested by Romain Naour)
- Handle optionnal dependencies on libexif, libjpeg, libgd and lockdev
- Add license informations
- Use tar.bz2 package
- Change hash
- Added myself as package maintainer in the DEVELOPPERS file

---
  DEVELOPERS                         |  3 +++
  package/Config.in                  |  1 +
  package/libgphoto2/Config.in       | 14 +++++++++++
  package/libgphoto2/libgphoto2.hash |  6 +++++
  package/libgphoto2/libgphoto2.mk   | 50 ++++++++++++++++++++++++++++++++++++++
  5 files changed, 74 insertions(+)

create mode 100644 package/libgphoto2/Config.in create mode 100644 package/libgphoto2/libgphoto2.hash create mode 100644 package/libgphoto2/libgphoto2.mk

DEVELOPERS +3 -0
index a298669..1f45012 100644
@@ -957,6 +957,9 @@ F:	package/cpuload/
  F:	package/bwm-ng/
  F:	package/ramsmp/
 
+N:	Kevin Joly <[email protected]>
+F:	package/libgphoto2/
+
  N:	Laurent Cans <[email protected]>
  F:	package/aircrack-ng/
 
package/Config.in +1 -0
index c12e5b5..f98a2b5 100644
@@ -1086,6 +1086,7 @@ menu "Hardware handling"
  	source "package/libfreefare/Config.in"
  	source "package/libftdi/Config.in"
  	source "package/libftdi1/Config.in"
+	source "package/libgphoto2/Config.in"
  	source "package/libgpiod/Config.in"
  	source "package/libgudev/Config.in"
  	source "package/libhid/Config.in"
package/libgphoto2/Config.in new file +0 -0
new file mode 100644
index 0000000..fd53232

package/libgphoto2/Config.in line 6

Quoted 6 lines
package/libgphoto2/Config.in new file +6 -0
@@ -0,0 +1,14 @@
+config BR2_PACKAGE_LIBGPHOTO2
+	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
+	select BR2_PACKAGE_LIBTOOL
+	select BR2_PACKAGE_LIBUSB
+	select BR2_PACKAGE_LIBXML2
+	bool "libgphoto2"

This should come right below the config line.
(you can now run './support/scripts/check-package package/libgphoto2/*' to detect this kind of error).

package/libgphoto2/Config.in line 13

Quoted 7 lines
package/libgphoto2/Config.in new file +7 -0
+	help
+	  libgphoto2 is the core library designed to allow access to
+	  digital camera by external programs.
+
+	  http://gphoto.org/proj/libgphoto2/
+
+comment "libgphoto needs a toolchain w threads"
                                         ^w/
Quoted 28 lines
package/libgphoto2/Config.in new file +1 -0
+	depends on !BR2_TOOLCHAIN_HAS_THREADS
package/libgphoto2/libgphoto2.hash new file +6 -0
new file mode 100644
index 0000000..1afe275
@@ -0,0 +1,6 @@
+# https://sourceforge.net/projects/gphoto/files/libgphoto/2.5.13/
+md5 73bf5b3d94c8c6f5fad9ea6b5e561843 libgphoto2-2.5.13.tar.bz2
+sha1 cef2d2f1930f8ada16a63aca15683188231a626a libgphoto2-2.5.13.tar.bz2
+
+# Locally calculated hash
+sha256 ceaacbdf187d1cd1aed5336991f46b0100f6960b6c8383f9aeab98f1f64780ef libgphoto2-2.5.13.tar.bz2
package/libgphoto2/libgphoto2.mk new file +9 -0
new file mode 100644
index 0000000..24dac19
@@ -0,0 +1,50 @@
+################################################################################
+#
+# libgphoto2
+#
+################################################################################
+
+LIBGPHOTO2_VERSION = 2.5.13
+LIBGPHOTO2_SOURCE = libgphoto2-$(LIBGPHOTO2_VERSION).tar.bz2
+# Project is maintained on github but github tarball doesn't have configure

package/libgphoto2/libgphoto2.mk line 19

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+LIBGPHOTO2_SITE = https://sourceforge.net/projects/gphoto/files/libgphoto/$(LIBGPHOTO2_VERSION)
+LIBGPHOTO2_INSTALL_STAGING = YES
+
+LIBGPHOTO2_LICENSE = LGPL-2.1+, GPL-2.0 (adc65), GPL-2.0+ (some camlibs), \
+	LGPL-2.0 (sipix), LGPL-3.0+ (pentax), BSD-3-Clause (ax203/tinyjpeg).
+LIBGPHOTO2_LICENSE_FILES = COPYING
+# No license files for other licenses
+
+LIBGPHOTO2_DEPENDENCIES = libxml2 libusb libtool host-pkgconf
+LIBGPHOTO2_CONF_OPTS += --disable-rpm

It might be good to also add --disable-gp2ddb --disable-internal-docs but these
are anyway disabled by default so not so important.

package/libgphoto2/libgphoto2.mk line 21

Quoted 2 lines
package/libgphoto2/libgphoto2.mk new file +2 -0
+
+ifeq ($(BR2_PACKAGE_LIBUSB_COMPAT),y)

Maybe add

# libusb-compat is not actually used, but it is detected, so add it here to
# guarantee reproducible builds
Quoted 16 lines
Quoted 6 lines
package/libgphoto2/libgphoto2.mk new file +6 -0
+LIBGPHOTO2_DEPENDENCIES += libusb-compat
+endif
+
+ifeq ($(BR2_PACKAGE_LIBEXIF),y)
+LIBGPHOTO2_DEPENDENCIES += libexif
+LIBGPHOTO2_CONF_OPTS += --with-libexif=auto

package/libgphoto2/libgphoto2.mk line 37

Quoted 10 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+else
+LIBGPHOTO2_CONF_OPTS += --with-libexif=no
+endif
+
+ifeq ($(BR2_PACKAGE_LIBJPEG),y)
+LIBGPHOTO2_DEPENDENCIES += libjpeg
+LIBGPHOTO2_CONF_OPTS += --with-jpeg
+else
+LIBGPHOTO2_CONF_OPTS += --without-jpeg
+endif

libjpeg is a jpeg provider like jpeg-tubo

Can you try with:

Quoted 8 lines

ifeq ($(BR2_PACKAGE_JPEG),y)
LIBGPHOTO2_DEPENDENCIES += jpeg
LIBGPHOTO2_CONF_OPTS += --with-jpeg
else
LIBGPHOTO2_CONF_OPTS += --without-jpeg
endif

and jped-turbo enabled ?

It compiles and the JPEG mangling support is enabled.

Quoted 16 lines
Quoted 12 lines

package/libgphoto2/libgphoto2.mk line 47

Quoted 11 lines
package/libgphoto2/libgphoto2.mk new file +10 -0
+
+ifeq ($(BR2_PACKAGE_GD),y)
+LIBGPHOTO2_DEPENDENCIES += gd
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=auto
+else
+LIBGPHOTO2_CONF_OPTS += --with-gdlib=no
+endif
+
+ifeq ($(BR2_PACKAGE_LOCKDEV),y)
+LIBGPHOTO2_DEPENDENCIES += lockdev

Good catch!

I had this one in my initial patch but not as optional dependency :p

I think, the v4 will be the last :)

Quoted 7 lines

Best regards,
Romain

Quoted 4 lines

package/libgphoto2/libgphoto2.mk line 50

Quoted 4 lines
package/libgphoto2/libgphoto2.mk new file +3 -0
+endif
+
+$(eval $(autotools-package))

Best regards,

Signature · 10 lines
*Kevin JOLY*
Embedded systems engineer

SenseFly <http://www.sensefly.com/>
38, rte de Gen?ve
1033 Cheseaux-Lausanne, Switzerland

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20170411/6ad519aa/attachment-0001.html>