Re: [ptxdist] does ptxdist newpackage target support building a Qt application - YES
\o/ Impressive! Subject communication! :)) Juergen -- Pengutronix e.K. | Juergen Beisert | Linux Solutions for Science and Industry | http://www.pengutronix.de/ | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] does ptxdist newpackage target support building a Qt application - YES; Juergen, you did it wrong!!ELF!11
-- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] libtar: add as new package
On Wed, Feb 26, 2014 at 09:41:53AM +0100, Alexander Dahl wrote: I had some problems with the get stage and git urls we already discussed in IRC last week. This still occurs with the current ptxdist 2014.02.0 release, so I describe what I found. Am 2014-02-23 14:01, schrieb Alexander Dahl: Git only I used the ptxdist mechanism for creating a tarball from a git clone in get stage. In this context I noticed a behavior of ptxdist I consider a bug. Let me describe: We use collections here. If I mark the libtar package * in the config everything builds fine. If I mark it m in the config and [*] in the collection there's no problem, too. However if I mark this package m in the config but leave it [ ] in the connection a manual call to the get stage fails: % ptxdist get libtar target: libtar-1.2.20.tar.gz error: empty parameter to 'ptxd_make_get' make: *** [/home/adahl/mnt/bagend-isys/Downloads/ptxdist_src_archive/libtar-1.2.20.tar.gz] Error 1 I didn't notice this behavior with ordinary packages getting their tarball by HTTP, but this one is different, because it uses git and builds the tarball from the local mirror. Maybe anyone has time to look into this. ;-) This should happen with all packages. You cannot 'get' a package that is not enabled. The tarball - URL mapping only exists for enabled packages, so ptxd_make_get gets called with an empty URL and complains. Michael -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] ntp: version bump 4.2.6 - 4.2.6p5
On Wed, Feb 26, 2014 at 08:07:05AM +0100, Bruno Thomsen wrote: Version 4.2.6p5 is the latest stable release. Fixed install ntpq option. Signed-off-by: Bruno Thomsen b...@kamstrup.dk Thanks, applied. Michael --- patches/ntp-4.2.6/Fix-undefined-MOD_NANO.patch | 42 -- patches/ntp-4.2.6/series |1 - patches/ntp-4.2.6p5/Fix-undefined-MOD_NANO.patch | 42 ++ patches/ntp-4.2.6p5/series |1 + rules/ntp.make |6 ++-- 5 files changed, 46 insertions(+), 46 deletions(-) delete mode 100644 patches/ntp-4.2.6/Fix-undefined-MOD_NANO.patch delete mode 100644 patches/ntp-4.2.6/series create mode 100644 patches/ntp-4.2.6p5/Fix-undefined-MOD_NANO.patch create mode 100644 patches/ntp-4.2.6p5/series diff --git a/patches/ntp-4.2.6/Fix-undefined-MOD_NANO.patch b/patches/ntp-4.2.6/Fix-undefined-MOD_NANO.patch deleted file mode 100644 index f4200cf..000 --- a/patches/ntp-4.2.6/Fix-undefined-MOD_NANO.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 4ccca7260da74d8f9a238a79c03da440831bd33e Mon Sep 17 00:00:00 2001 -From: Alexander Stein alexander.st...@systec-electronic.com -Date: Tue, 5 Jan 2010 13:13:02 +0100 -Subject: [PATCH] Fix undefined MOD_NANO - -With gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) I get this error: - -ntp_loopfilter.c: In function 'local_clock': -ntp_loopfilter.c:571: error: 'MOD_NANO' undeclared (first use in this function) -ntp_loopfilter.c:571: error: (Each undeclared identifier is reported only once -ntp_loopfilter.c:571: error: for each function it appears in.) -ntp_loopfilter.c: In function 'loop_config': -ntp_loopfilter.c:896: error: 'MOD_NANO' undeclared (first use in this function) -make[4]: *** [ntp_loopfilter.o] Error 1 - -Fix it by chaning MOD_NANO to STA_NANO. - -This may be related to some specific toolchains, due to some defines. I use the -Codesourcery Sourcery G++ Lite 2009q3-67 toolchain. - -Signed-off-by: Alexander Stein alexander.st...@systec-electronic.com -Signed-off-by: Marc Kleine-Budde m...@pengutronix.de - -#mkl: ported to ntp-4.2.6 - - ntpd/ntp_loopfilter.c |2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -Index: ntp-4.2.6/ntpd/ntp_loopfilter.c -=== ntp-4.2.6.orig/ntpd/ntp_loopfilter.c -+++ ntp-4.2.6/ntpd/ntp_loopfilter.c -@@ -517,7 +517,7 @@ local_clock( - ntv.modes = MOD_STATUS; - } else { - #ifdef STA_NANO --ntv.modes = MOD_BITS | MOD_NANO; -+ntv.modes = MOD_BITS | STA_NANO; - #else /* STA_NANO */ - ntv.modes = MOD_BITS; - #endif /* STA_NANO */ diff --git a/patches/ntp-4.2.6/series b/patches/ntp-4.2.6/series deleted file mode 100644 index 6a7679c..000 --- a/patches/ntp-4.2.6/series +++ /dev/null @@ -1 +0,0 @@ -Fix-undefined-MOD_NANO.patch diff --git a/patches/ntp-4.2.6p5/Fix-undefined-MOD_NANO.patch b/patches/ntp-4.2.6p5/Fix-undefined-MOD_NANO.patch new file mode 100644 index 000..f4200cf --- /dev/null +++ b/patches/ntp-4.2.6p5/Fix-undefined-MOD_NANO.patch @@ -0,0 +1,42 @@ +From 4ccca7260da74d8f9a238a79c03da440831bd33e Mon Sep 17 00:00:00 2001 +From: Alexander Stein alexander.st...@systec-electronic.com +Date: Tue, 5 Jan 2010 13:13:02 +0100 +Subject: [PATCH] Fix undefined MOD_NANO + +With gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) I get this error: + +ntp_loopfilter.c: In function 'local_clock': +ntp_loopfilter.c:571: error: 'MOD_NANO' undeclared (first use in this function) +ntp_loopfilter.c:571: error: (Each undeclared identifier is reported only once +ntp_loopfilter.c:571: error: for each function it appears in.) +ntp_loopfilter.c: In function 'loop_config': +ntp_loopfilter.c:896: error: 'MOD_NANO' undeclared (first use in this function) +make[4]: *** [ntp_loopfilter.o] Error 1 + +Fix it by chaning MOD_NANO to STA_NANO. + +This may be related to some specific toolchains, due to some defines. I use the +Codesourcery Sourcery G++ Lite 2009q3-67 toolchain. + +Signed-off-by: Alexander Stein alexander.st...@systec-electronic.com +Signed-off-by: Marc Kleine-Budde m...@pengutronix.de + +--- +#mkl: ported to ntp-4.2.6 + + ntpd/ntp_loopfilter.c |2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: ntp-4.2.6/ntpd/ntp_loopfilter.c +=== +--- ntp-4.2.6.orig/ntpd/ntp_loopfilter.c ntp-4.2.6/ntpd/ntp_loopfilter.c +@@ -517,7 +517,7 @@ local_clock( + ntv.modes = MOD_STATUS; + } else { + #ifdef STA_NANO +-ntv.modes = MOD_BITS | MOD_NANO; ++ntv.modes = MOD_BITS | STA_NANO; + #else /* STA_NANO */ + ntv.modes = MOD_BITS; + #endif /* STA_NANO */ diff
Re: [ptxdist] [PATCH] libzmq: add new package
On Thu, Feb 27, 2014 at 10:03:04PM +0100, Alexander Aring wrote: Signed-off-by: Alexander Aring alex.ar...@gmail.com Thanks, applied. Michael --- rules/libzmq.in | 12 +++ rules/libzmq.make | 59 +++ 2 files changed, 71 insertions(+) create mode 100644 rules/libzmq.in create mode 100644 rules/libzmq.make diff --git a/rules/libzmq.in b/rules/libzmq.in new file mode 100644 index 000..c272f84 --- /dev/null +++ b/rules/libzmq.in @@ -0,0 +1,12 @@ +## SECTION=networking + +config LIBZMQ + tristate + prompt libzmq + help + The zeroMQ lightweight messaging kernel is a library which extends the + standard socket interfaces with features traditionally provided by + specialised messaging middleware products. zeroMQ sockets provide an + abstraction of asynchronous message queues, multiple messaging patterns, + message filtering (subscriptions), seamless access to multiple transport + protocols and more. diff --git a/rules/libzmq.make b/rules/libzmq.make new file mode 100644 index 000..56f505f --- /dev/null +++ b/rules/libzmq.make @@ -0,0 +1,59 @@ +# -*-makefile-*- +# +# Copyright (C) 2014 by Alexander Aring a...@pengutronix.de +# +# See CREDITS for details about who has contributed to this project. +# +# For further information about the PTXdist project and license conditions +# see the README file. +# + +# +# We provide this package +# +PACKAGES-$(PTXCONF_LIBZMQ) += libzmq + +# +# Paths and names +# +LIBZMQ_VERSION := 4.0.3 +LIBZMQ_MD5 := 8348341a0ea577ff311630da0d624d45 +LIBZMQ := zeromq-$(LIBZMQ_VERSION) +LIBZMQ_SUFFIX:= tar.gz +LIBZMQ_URL := http://download.zeromq.org/$(LIBZMQ).$(LIBZMQ_SUFFIX) +LIBZMQ_SOURCE:= $(SRCDIR)/$(LIBZMQ).$(LIBZMQ_SUFFIX) +LIBZMQ_DIR := $(BUILDDIR)/$(LIBZMQ) +LIBZMQ_LICENSE := LGPLv3+ + +# +# autoconf +# +LIBZMQ_CONF_TOOL := autoconf +LIBZMQ_CONF_OPT := \ + $(CROSS_AUTOCONF_USR) \ + --enable-shared \ + --disable-static \ + --with-gnu-ld \ + --without-documentation + +# +# Target-Install +# + +$(STATEDIR)/libzmq.targetinstall: + @$(call targetinfo) + + @$(call install_init, libzmq) + @$(call install_fixup, libzmq,PRIORITY,optional) + @$(call install_fixup, libzmq,SECTION,base) + @$(call install_fixup, libzmq,AUTHOR,Alexander Aring a...@pengutronix.de) + @$(call install_fixup, libzmq,DESCRIPTION,missing) + + @$(call install_lib, libzmq, 0, 0, 0644, libzmq) + @$(call install_copy, libzmq, 0, 0, 0755, -, /usr/bin/curve_keygen) + + @$(call install_finish, libzmq) + + @$(call touch) + +# vim: syntax=make -- 1.9.0 -- ptxdist mailing list ptxdist@pengutronix.de -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH 1/7] ptxdist: Add list-packages command
I've applied all of them. Some with small cleanups. Michael On Wed, Feb 26, 2014 at 03:13:15PM +0100, Sascha Hauer wrote: This adds a command to list all packages currently selected. ptxdist gurus can use 'ptxdist print PACKAGES' for the same purpose, this command is for the people who can't remember the command. As a bonus list-packages prints one package per line and sorts them alphabetically. Signed-off-by: Sascha Hauer s.ha...@pengutronix.de --- bin/ptxdist | 8 1 file changed, 8 insertions(+) diff --git a/bin/ptxdist b/bin/ptxdist index 663c41e..b2c2e7a 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -898,6 +898,7 @@ Misc: nfsrootrun a userspace NFS server and export the nfsroot print varprint the contents of a variable, in the way it is known by make + list-packages print a list of all selected packages bash enter a ptxdist environment bash shell bash cmd [args...] execute cmd in ptxdist environment export_src target direxport all source archives needed for this @@ -1804,6 +1805,13 @@ EOF ptxd_make_log ${images[@]} exit ;; + list-packages) + check_config || return + check_deps + ( for i in $(ptxd_make_log print-PACKAGES); + do echo $i + done ) | sort + ;; make) check_premake_compiler ptxd_make_log ${@} -- 1.8.5.3 -- ptxdist mailing list ptxdist@pengutronix.de -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] klibc: Bump to version 2.0.3
On Wed, Feb 26, 2014 at 02:06:43PM +0100, Alexander Stein wrote: Signed-off-by: Alexander Stein alexander.st...@systec-electronic.com Thanks, applied. Michael --- This update is needed for newer kernels, e.g. v3.10 ...ernel-header-installed-by-headers_install.patch | 60 -- ...d-support-for-detection-of-vfat-and-jffs2.patch | 58 - .../0003-define-__socklen_t_defined.patch | 17 -- ...-include-signal.h-47-5-warning-SIGRTMAX-i.patch | 31 --- patches/klibc-1.5.25/series| 4 -- ...ernel-header-installed-by-headers_install.patch | 60 ++ ...d-support-for-detection-of-vfat-and-jffs2.patch | 58 + .../0003-define-__socklen_t_defined.patch | 17 ++ ...-include-signal.h-47-5-warning-SIGRTMAX-i.patch | 31 +++ patches/klibc-2.0.3/series | 4 ++ rules/klibc.make | 6 +-- 11 files changed, 173 insertions(+), 173 deletions(-) delete mode 100644 patches/klibc-1.5.25/0001-klibc-use-kernel-header-installed-by-headers_install.patch delete mode 100644 patches/klibc-1.5.25/0002-Patch-to-add-support-for-detection-of-vfat-and-jffs2.patch delete mode 100644 patches/klibc-1.5.25/0003-define-__socklen_t_defined.patch delete mode 100644 patches/klibc-1.5.25/0004-fix-warning-include-signal.h-47-5-warning-SIGRTMAX-i.patch delete mode 100644 patches/klibc-1.5.25/series create mode 100644 patches/klibc-2.0.3/0001-klibc-use-kernel-header-installed-by-headers_install.patch create mode 100644 patches/klibc-2.0.3/0002-Patch-to-add-support-for-detection-of-vfat-and-jffs2.patch create mode 100644 patches/klibc-2.0.3/0003-define-__socklen_t_defined.patch create mode 100644 patches/klibc-2.0.3/0004-fix-warning-include-signal.h-47-5-warning-SIGRTMAX-i.patch create mode 100644 patches/klibc-2.0.3/series diff --git a/patches/klibc-1.5.25/0001-klibc-use-kernel-header-installed-by-headers_install.patch b/patches/klibc-1.5.25/0001-klibc-use-kernel-header-installed-by-headers_install.patch deleted file mode 100644 index e9795b3..000 --- a/patches/klibc-1.5.25/0001-klibc-use-kernel-header-installed-by-headers_install.patch +++ /dev/null @@ -1,60 +0,0 @@ -From: Marc Kleine-Budde m...@pengutronix.de -Date: Mon, 5 Jan 2009 17:46:47 +0100 -Subject: [PATCH 17/21] [klibc] use kernel header installed by headers_install - -Originally klibc directly sets the compiler header search path -directly into the kernel tree. This causes compilation to fail on modern -kernel with a changed include dir layout. - -This patch uses the headers_install to extract the includes from the -kernel. Against these headers klibc is build. - -Ported from 1.5.15 - -Index: klibc-1.5.25/Makefile -=== klibc-1.5.25.orig/Makefile -+++ klibc-1.5.25/Makefile -@@ -6,6 +6,7 @@ SRCROOT = . - # kbuild compatibility - export srctree := $(shell pwd) - export objtree := $(shell pwd) -+export LINUX_HEADERS := $(objtree)/linux-headers - export KLIBCSRC := usr/klibc - export VERSION := $(shell cat $(srctree)/$(KLIBCSRC)/version) - export KLIBCINC := usr/include -@@ -102,16 +103,19 @@ $(KLIBCKERNELSRC): - @echo KLIBCKERNELSRC=path to the build. - @false - -+$(LINUX_HEADERS): linux -+$(Q)$(MAKE) -C $(KLIBCKERNELSRC) ARCH=$(KLIBCARCH) INSTALL_HDR_PATH=$@ headers_install -+ - rpmbuild = $(shell which rpmbuild 2/dev/null || which rpm) - - klibc.spec: klibc.spec.in $(KLIBCSRC)/version - sed -e 's/@@VERSION@@/$(VERSION)/g' $ $@ - - # Build klcc - it is the first target --klcc: $(objtree)/.config -+klcc: $(objtree)/.config $(LINUX_HEADERS) - $(Q)$(MAKE) $(klibc)=klcc - --klibc: $(objtree)/.config -+klibc: $(objtree)/.config $(LINUX_HEADERS) - $(Q)$(MAKE) $(klibc)=. - - test: klibc -Index: klibc-1.5.25/scripts/Kbuild.klibc -=== klibc-1.5.25.orig/scripts/Kbuild.klibc -+++ klibc-1.5.25/scripts/Kbuild.klibc -@@ -113,7 +113,7 @@ KLIBCCPPFLAGS:= -nostdinc -iwithpref - # kernel include paths - KLIBCKERNELSRC ?= $(srctree) - KLIBCKERNELOBJ ?= $(objtree) --KLIBCCPPFLAGS+= -I$(KLIBCKERNELSRC)/include \ -+KLIBCCPPFLAGS+= -I$(LINUX_HEADERS)/include \ - $(if $(KBUILD_SRC),-I$(KLIBCKERNELOBJ)/include2 \ --I$(KLIBCKERNELOBJ)/include -I$(srctree)/include)\ - $(KLIBCARCHINCFLAGS) diff --git a/patches/klibc-1.5.25/0002-Patch-to-add-support-for-detection-of-vfat-and-jffs2.patch b/patches/klibc-1.5.25/0002-Patch-to-add-support-for-detection-of-vfat-and-jffs2.patch deleted file mode 100644 index 60f1d8f..000 ---
Re: [ptxdist] tarballs from git URLs: git archive vs. git submodule
Hi, On Mon, Mar 03, 2014 at 01:13:00PM +0100, Alexander Dahl wrote: while trying the local_src feature (local_src/${PACKAGE}.{PLATFORM}) which is actually really cool, I came across a problem with the automatic tarball creation from Git URLs. ptxd_make_get.sh uses `git archive` for this purpose which does not support git submodules. There are several scripts around the web by people who needed this in the past and although there were feature requests and even patches years ago in git, it's still not included mainline. :-( The possibilities I see are these: * waiting probably very long for a new git release with git archive supporting submodules * replace the use of submodules in the repositories I want to use with something else, maybe git subtree * scripting this and change ptxd_make_get.sh which could be quite complicated * create a tarball for each repository and extract all in a custom extract stage. Take a look at e.g. host-tz-database on how to handle multiple tarballs. For the third possibility: I would suggest cloning the repo with the --mirror option into a --bare repository almost like it's done now. Then do a `git clone --recursive` to a temporary folder followed by a checkout to the desired tag. Make a tarball from this clone and remove the directory right afterwards. The git url support was introduced in June 2013 by Michael Olbrich and not touch since. Did anyone try to improve it in any way? Would a change in the proposed direction have chances to be accepted by the ptxdist developers? It would make the code more complex I guess. 'git archive' always creates the exact same tarball. It's not that easy to do the same thing manually. I'd like to avoid too much complexity here. But I'd be open for a patch that puts the 'git archive' call in a separate function. Then you only need to overwrite this function locally in your BSP with a special version that handles submodules. Michael -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] libtar: add as new package
On Sun, Feb 23, 2014 at 02:01:32PM +0100, Alexander Dahl wrote: libtar is a C library for manipulating POSIX tar files. It handles adding and extracting files to/from a tar archive. I reviewed the current Debian patches for usefulness and added all of them. Since the official unofficial way (maintainer's words) to get new releases is Git only I used the ptxdist mechanism for creating a tarball from a git clone in get stage. Signed-off-by: Alexander Dahl p...@lespocky.de Thanks, applied. Michael --- ...d-using-a-static-buffer-in-th_get_pathnam.patch | 92 patches/libtar-1.2.20/0002-no_maxpathlen.patch | 487 patches/libtar-1.2.20/0003-CVE-2013-4420.patch | 126 + ...-th_get_size-macro-to-return-unsigned-int.patch | 51 ++ patches/libtar-1.2.20/autogen.sh |1 + patches/libtar-1.2.20/series |7 + rules/libtar.in| 11 + rules/libtar.make | 62 +++ 8 files changed, 837 insertions(+) create mode 100644 patches/libtar-1.2.20/0001-decode-avoid-using-a-static-buffer-in-th_get_pathnam.patch create mode 100644 patches/libtar-1.2.20/0002-no_maxpathlen.patch create mode 100644 patches/libtar-1.2.20/0003-CVE-2013-4420.patch create mode 100644 patches/libtar-1.2.20/0004-Change-th_get_size-macro-to-return-unsigned-int.patch create mode 12 patches/libtar-1.2.20/autogen.sh create mode 100644 patches/libtar-1.2.20/series create mode 100644 rules/libtar.in create mode 100644 rules/libtar.make diff --git a/patches/libtar-1.2.20/0001-decode-avoid-using-a-static-buffer-in-th_get_pathnam.patch b/patches/libtar-1.2.20/0001-decode-avoid-using-a-static-buffer-in-th_get_pathnam.patch new file mode 100644 index 000..7664f1d --- /dev/null +++ b/patches/libtar-1.2.20/0001-decode-avoid-using-a-static-buffer-in-th_get_pathnam.patch @@ -0,0 +1,92 @@ +From: Kamil Dudka kdu...@redhat.com +Date: Wed, 23 Oct 2013 13:04:22 +0200 +Subject: [PATCH] decode: avoid using a static buffer in th_get_pathname() + +decode: avoid using a static buffer in th_get_pathname() + +A solution suggested by Chris Frey: +https://lists.feep.net:8080/pipermail/libtar/2013-October/000377.html + +Note this can break programs that expect sizeof(TAR) to be fixed. +--- + lib/decode.c | 25 ++--- + lib/handle.c |1 + + lib/libtar.h |3 +++ + 3 files changed, 22 insertions(+), 7 deletions(-) + +diff --git a/lib/decode.c b/lib/decode.c +index c16ea2d..35312be 100644 +--- a/lib/decode.c b/lib/decode.c +@@ -13,6 +13,7 @@ + #include internal.h + + #include stdio.h ++#include stdlib.h + #include sys/param.h + #include pwd.h + #include grp.h +@@ -26,20 +27,30 @@ + char * + th_get_pathname(TAR *t) + { +-static TLS_THREAD char filename[MAXPATHLEN]; +- + if (t-th_buf.gnu_longname) + return t-th_buf.gnu_longname; + +-if (t-th_buf.prefix[0] != '\0') ++/* allocate the th_pathname buffer if not already */ ++if (t-th_pathname == NULL) ++{ ++t-th_pathname = malloc(MAXPATHLEN * sizeof(char)); ++if (t-th_pathname == NULL) ++/* out of memory */ ++return NULL; ++} ++ ++if (t-th_buf.prefix[0] == '\0') ++{ ++snprintf(t-th_pathname, MAXPATHLEN, %.100s, t-th_buf.name); ++} ++else + { +-snprintf(filename, sizeof(filename), %.155s/%.100s, ++snprintf(t-th_pathname, MAXPATHLEN, %.155s/%.100s, + t-th_buf.prefix, t-th_buf.name); +-return filename; + } + +-snprintf(filename, sizeof(filename), %.100s, t-th_buf.name); +-return filename; ++/* will be deallocated in tar_close() */ ++return t-th_pathname; + } + + +diff --git a/lib/handle.c b/lib/handle.c +index 33a262c..9faf2ed 100644 +--- a/lib/handle.c b/lib/handle.c +@@ -121,6 +121,7 @@ tar_close(TAR *t) + libtar_hash_free(t-h, ((t-oflags O_ACCMODE) == O_RDONLY + ? free + : (libtar_freefunc_t)tar_dev_free)); ++free(t-th_pathname); + free(t); + + return i; +diff --git a/lib/libtar.h b/lib/libtar.h +index 55f509a..5993cd2 100644 +--- a/lib/libtar.h b/lib/libtar.h +@@ -85,6 +85,9 @@ typedef struct + int options; + struct tar_header th_buf; + libtar_hash_t *h; ++ ++/* introduced in libtar 1.2.21 */ ++char *th_pathname; + } + TAR; + diff --git a/patches/libtar-1.2.20/0002-no_maxpathlen.patch b/patches/libtar-1.2.20/0002-no_maxpathlen.patch new file mode 100644 index 000..90a95fb --- /dev/null +++ b/patches/libtar-1.2.20/0002-no_maxpathlen.patch @@ -0,0 +1,487 @@ +From: unknown author unknown.aut...@example.com +Date: Thu, 20 Feb 2014 13:49:38 +0100
Re: [ptxdist] [PATCH v2] net-snmp: Improved SNMPv3 authentication and privacy support.
On Mon, Feb 24, 2014 at 01:44:24PM +0100, Bruno Thomsen wrote: Enabled SHA authentication and AES privacy (encryption) using OpenSSL. Upgraded from libnl1 to libnl3 dependency. Disable minimal agent when privacy is enabled. Tested SNMPv3 with USM (User-based Security Model) SHA auth + AES priv, minimal agent option disabled. Ups, I looked at the wrong patch. This one is mostly ok too, but my point about libnl3 remains. Michael Signed-off-by: Bruno Thomsen b...@kamstrup.dk --- rules/net-snmp.in | 13 - rules/net-snmp.make |4 ++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/rules/net-snmp.in b/rules/net-snmp.in index 9821328..052e59e 100644 --- a/rules/net-snmp.in +++ b/rules/net-snmp.in @@ -5,8 +5,10 @@ menuconfig NET_SNMP select LIBC_M select GCCLIBS_GCC_Sif NET_SNMP_AGENT select LIBC_DL if NET_SNMP_AGENT || NET_SNMP_APPLICATIONS - select LIBNLif NET_SNMP_AGENT || NET_SNMP_APPLICATIONS + select LIBNL3 if NET_SNMP_AGENT || NET_SNMP_APPLICATIONS select LM_SENSORS if NET_SNMP_MIB_MODULES_LM_SENSORS + select OPENSSL if NET_SNMP_SHA_AES + select NET_SNMP_PRIVACY if NET_SNMP_SHA_AES || NET_SNMP_DES if NET_SNMP @@ -174,6 +176,7 @@ endchoice config NET_SNMP_MINI_AGENT bool default y + depends on ! NET_SNMP_PRIVACY prompt minimal agent config NET_SNMP_AGENT @@ -200,6 +203,10 @@ config NET_SNMP_SNMPV2C bool prompt support for SNMPv2c +config NET_SNMP_PRIVACY + bool + prompt support for privacy (encryption) + config NET_SNMP_DES bool prompt DES encryption @@ -208,6 +215,10 @@ config NET_SNMP_MD5 bool prompt MD5 authentication +config NET_SNMP_SHA_AES + bool + prompt SHA authentication and AES encryption + config NET_SNMP_DOM_SOCK_ONLY bool Disable UDP/TCP transports for agentx if NET_SNMP_AGENT default y diff --git a/rules/net-snmp.make b/rules/net-snmp.make index 6bdecd8..6ddb954 100644 --- a/rules/net-snmp.make +++ b/rules/net-snmp.make @@ -47,7 +47,7 @@ NET_SNMP_AUTOCONF := \ $(GLOBAL_IPV6_OPTION) \ --with-defaults \ --disable-manuals \ - --without-openssl \ + --$(call ptx/wwo, PTXCONF_NET_SNMP_SHA_AES)-openssl \ --with-mib-modules=$(NET_SNMP_MIB_MODULES-y) \ --with-out-mib-modules=$(NET_SNMP_MIB_MODULES-) \ --with-mibs=$(PTXCONF_NET_SNMP_DEFAULT_MIBS) \ @@ -58,7 +58,7 @@ NET_SNMP_AUTOCONF := \ --disable-embedded-perl \ --without-perl-modules \ --disable-static \ - --disable-privacy \ + --$(call ptx/endis, PTXCONF_NET_SNMP_PRIVACY)-privacy \ --disable-internal-md5 \ --$(call ptx/endis, PTXCONF_NET_SNMP_DOM_SOCK_ONLY)-agentx-dom-sock-only \ --enable-mib-config-checking \ -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] tclap: New package
Signed-off-by: Bernhard Walle bernh...@bwalle.de --- rules/tclap.in | 21 + rules/tclap.make | 40 2 files changed, 61 insertions(+) create mode 100644 rules/tclap.in create mode 100644 rules/tclap.make diff --git a/rules/tclap.in b/rules/tclap.in new file mode 100644 index 000..dd5cd48 --- /dev/null +++ b/rules/tclap.in @@ -0,0 +1,21 @@ +## SECTION=system_libraries + +config TCLAP + tristate + prompt tclap + help + Templatized C++ Command Line Parser Library + + TCLAP is a small, flexible library that provides a simple interface + for defining and accessing command line arguments. It was intially + inspired by the user friendly CLAP libary. The difference is that + this library is templatized, so the argument class is type + independent. Type independence avoids identical-except-for-type + objects, such as IntArg, FloatArg, and StringArg. While the library + is not strictly compliant with the GNU or POSIX standards, it is + close. + + NOTE: TCLAP is header-only, so the package doesn't install anything + on the target! + + diff --git a/rules/tclap.make b/rules/tclap.make new file mode 100644 index 000..31d70e8 --- /dev/null +++ b/rules/tclap.make @@ -0,0 +1,40 @@ +# -*-makefile-*- +# +# Copyright (C) 2014 by Bernhard Walle bernh...@bwalle.de +# +# See CREDITS for details about who has contributed to this project. +# +# For further information about the PTXdist project and license conditions +# see the README file. +# + +# +# We provide this package +# +PACKAGES-$(PTXCONF_TCLAP) += tclap + +# +# Paths and names +# +TCLAP_VERSION := 1.2.1 +TCLAP_MD5 := eb0521d029bf3b1cc0dcaa7e42abf82a +TCLAP := tclap-$(TCLAP_VERSION) +TCLAP_SUFFIX := tar.gz +TCLAP_URL := $(call ptx/mirror, SF, tclap/$(TCLAP).$(TCLAP_SUFFIX)) +TCLAP_SOURCE := $(SRCDIR)/$(TCLAP).$(TCLAP_SUFFIX) +TCLAP_DIR := $(BUILDDIR)/$(TCLAP) +TCLAP_LICENSE := MIT + +# +# Prepare +# + +# +# autoconf +# +TCLAP_CONF_TOOL:= autoconf +TCLAP_CONF_OPT := \ + $(CROSS_AUTOCONF_USR) \ + --disable-doxygen + +# vim: syntax=make -- 1.8.3.2 -- ptxdist mailing list ptxdist@pengutronix.de