On 2023-08-08 12:14, Jon Turney via Cygwin-apps wrote:
On 03/08/2023 17:21, Brian Inglis via Cygwin-apps wrote:
Hi folks,

Trying to build updated jq package, get cygautoreconf directory creation and existence bugs.
[...]

Cygport dies processing AC_CONFIG_SUBDIRS([modules/oniguruma]) under two levels of AS_IF (which handle existence of oniguruma library module or libonig-devel at default or custom locations with or without configure scripts in configure.ac) with:

Could not find modules/oniguruma/configure.ac or modules/oniguruma/configure.in

I'm not able to reproduce this problem.

Can you provide the jq.cygport you are using.

Also, can you be clear as to whether you have libonig-devel installed or not?

Hi Jon,

Attached jq.cygport.

As the cygport debug prep make log shows, libonig-devel is in DEPEND/BUILD_REQUIRES and installed.

Installed cygport is latest available 0.36.6-1.

With the attached cygautoreconf patch applied, it builds.

--
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                -- Antoine de Saint-Exupéry
NAME=jq
VERSION=1.6
RELEASE=1
VERSION=1.7
RELEASE=0.rc1

CATEGORY="Text"
SUMMARY="Lightweight and flexible JSON processor"
DESCRIPTION="jq is like sed for JSON data - you can use it to slice and
filter and map and transform structured data with the same ease
that sed, awk, grep and friends let you play with text."

HOMEPAGE=https://stedolan.github.io/$NAME/
SRC_URI=https://github.com/stedolan/$NAME/releases/download/$NAME-$VERSION/$NAME-$VERSION.tar.gz
HOMEPAGE=https://jqlang.github.io/$NAME/
SRC_URI=https://github.com/jqlang/$NAME/archive/refs/tags/$NAME-$VERSION${RELEASE#*.}.tar.gz
SRC_DIR=$NAME-$NAME-$VERSION${RELEASE#*.}
PATCH_URI=1.4-no-undefined.patch

DEPEND="libonig-devel"
DEPEND=" autoconf automake bison flex gcc-core"
DEPEND+=" libtool pkg-config python3 rubygems"  # should have pipenv if packaged
BUILD_REQUIRES="$DEPEND"

LDFLAGS="$LDFLAGS -Wl,--no-allow-shlib-undefined -Wl,--no-undefined"

CYGCONF_ARGS="
        lt_no_undefined_flag=-no-undefined
        no_undefined_flag=-no-undefined
"
#        --enable-all-static            link jq with static libraries only
#        --enable-asan                  enable address sanitizer
#        --enable-dependency-tracking   do not reject slow dependency extractors
#       --disable-dependency-tracking   speeds up one-time build
#       --disable-docs                  don't build docs
#        --enable-error-injection       build and test with error injection
#        --enable-fast-install[=PKGS]   optimize for fast installation 
[default=yes]
#        --enable-gcov                  enable gcov code coverage tool
#       --disable-libtool-lock          avoid locking (might break parallel 
builds)
#       --disable-maintainer-mode       disable make rules and dependencies not 
useful (and sometimes confusing) to the casual installer
#       --disable-option-checking       ignore unrecognized --enable/--with 
options
#        --enable-pthread-tls           Enable use of pthread thread local 
storage
#        --enable-shared[=PKGS]         build shared libraries [default=yes]
#        --enable-silent-rules          less verbose build output (undo: "make 
V=1")
#       --disable-silent-rules          verbose build output (undo: "make V=0")
#        --enable-static[=PKGS]         build static libraries [default=yes]
#        --enable-ubsan                 enable undefined behavior sanitizer
#       --disable-valgrind              do not run tests under Valgrind
#          --with-aix-soname=aix|svr4|both      shared library versioning (aka 
"SONAME") variant to provide on AIX, [default=aix].
#          --with-gnu-ld                assume the C compiler uses GNU ld 
[default=no]
#          --with-oniguruma=prefix      try this for a non-standard install 
prefix of the oniguruma library
#          --with-pic[=PKGS]            try to use only PIC/non-PIC objects 
[default=use both]
#          --with-sysroot[=DIR]         Search for dependent libraries within 
DIR (or the compiler's sysroot if not specified).

PKG_NAMES="lib${NAME}1 lib${NAME}-devel $NAME"


libjq1_CATEGORY="Libs"
libjq1_CONTENTS="usr/bin/cyg${NAME}-1.dll"


libjq_devel_CATEGORY="Devel"
libjq_devel_CONTENTS="
        usr/include/
        usr/lib/lib${NAME}.dll.a
        usr/lib/pkgconfig/libjq.pc
"


jq_CONTENTS="usr/bin/${NAME}.exe usr/share/doc/ usr/share/man/"


src_test() {
        cd $B/
        # did something change in libtool-2.4.5+?
        PATH="$B/.libs:$PATH" cygmake check
}


# SPDX-License-Identifier: MIT AND CC-BY-3.0 AND dtoa AND ICU
LICENSE_SPDX="SPDX-License-Identifier: MIT AND CC-BY-3.0 AND dtoa AND ICU"
LICENSE="MIT AND CC-BY-3.0 AND dtoa AND ICU"
LICENSE_URI=COPYING

--- /usr/share/cygport/cygclass/autotools.cygclass.orig 2023-04-12 
10:42:56.000000000 -0600
+++ /usr/share/cygport/cygclass/autotools.cygclass      2023-08-03 
10:12:55.194067700 -0600
@@ -276,7 +276,9 @@ cygautoreconf() {
                        then
                                sub_configure_ac="${d}/configure.in";
                        else
-                               error "Could not find ${d}/configure.ac or 
${d}/configure.in";
+                               local level;
+                               [ -z "${sub_configure_ac}" ] && level=error || 
level=warning;
+                               ${level} "Could not find ${d}/configure.ac or 
${d}/configure.in";
                        fi
 
                        # e.g. CVS checkouts
@@ -311,7 +313,7 @@ cygautoreconf() {
                        then
                                __parse_aclocal_amflags $(grep 
'^ACLOCAL_AMFLAGS' Makefile.am | sed 's/=/ = /') | xargs -r mkdir -p
                        fi
-                       grep '^[^\#]*AC_CONFIG_MACRO_DIR' ${sub_configure_ac} | 
sed -e "s!.*AC_CONFIG_MACRO_DIR(\[*\(.*\))!${d}/\1!g" -e 's!\]*!!g' | xargs -r 
mkdir -p
+                       grep '^[^\#]*AC_CONFIG_MACRO_DIRS*' ${sub_configure_ac} 
| sed -e "s!.*AC_CONFIG_MACRO_DIRS*(\[*\(.*\))!${d}/\1!g" -e 's!\]*!!g' | xargs 
-r mkdir -p
 
                        if [ ! -f ${d}/aclocal.m4 ] || $(head -n 1 
${d}/aclocal.m4 | grep -q 'generated.* by aclocal')
                        then

Reply via email to