Opened 8 days ago

Closed 6 days ago

#71192 closed defect (fixed)

sqlite3-tcl: patch fails to apply

Reported by: barracuda156 Owned by: Schamschula (Marius Schamschula)
Priority: Normal Milestone:
Component: ports Version: 2.10.2
Keywords: Cc:
Port: sqlite3-tcl

Description

--->  Extracting sqlite-autoconf-3470000.tar.gz
Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/sqlite3/sqlite-autoconf-3470000.tar.gz' | /usr/bin/gnutar --no-same-owner -xf - 
--->  Applying patches to sqlite3-tcl
--->  Applying patch-tea-generic-tclsqlite3.c.diff
Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000/tea" && /usr/bin/patch -t -N -p0 < '/opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
can't find file to patch at input line 3
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|--- tea/generic/tclsqlite3.c.orig	2024-10-21 11:48:14
|+++ tea/generic/tclsqlite3.c	2024-10-21 18:19:02
--------------------------
No file to patch.  Skipping patch.
1 out of 1 hunk ignored
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000/tea" && /usr/bin/patch -t -N -p0 < '/opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
Exit code: 1
Error: Failed to patch sqlite3-tcl: command execution failed

Change History (11)

comment:1 Changed 8 days ago by Schamschula (Marius Schamschula)

I can't reproduce this:

--->  Applying patches to sqlite3-tcl
--->  Applying patch-tea-generic-tclsqlite3.c.diff
DEBUG: Environment: 
CC_PRINT_OPTIONS='YES'
CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_databases_sqlite3/sqlite3-tcl/work/.CC_PRINT_OPTIONS'
CPATH='/opt/local/include'
DEVELOPER_DIR='/Library/Developer/CommandLineTools'
LIBRARY_PATH='/opt/local/lib'
MACOSX_DEPLOYMENT_TARGET='14.0'
SDKROOT='/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk'
SOURCE_DATE_EPOCH='1729718650'
Executing:  cd "/opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000" && /usr/bin/patch -t -N -p0 < '/Users/marius/Development/MacPorts/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
DEBUG: system:  cd "/opt/local/var/macports/build/_Users_marius_Development_MacPorts_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000" && /usr/bin/patch -t -N -p0 < '/Users/marius/Development/MacPorts/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
patching file 'tea/generic/tclsqlite3.c'

comment:2 Changed 8 days ago by jmroot (Joshua Root)

As I've mentioned more than once before, you need to provide logs when you report issues, because they contain important information like what OS version the problem is happening on.

comment:3 Changed 8 days ago by barracuda156

Hmm, I cleaned everything, and get the same error:

version:1
:debug:main Starting logging for sqlite3-tcl @3.47.0_0
:debug:sysinfo Mac OS X 10.6 (darwin/10.0.0d2) arch powerpc
:debug:sysinfo MacPorts 2.10.99
:debug:sysinfo Xcode 3.2, CLT none
:debug:sysinfo SDK 10.6
:debug:sysinfo MACOSX_DEPLOYMENT_TARGET: 10.6
:debug:main epoch: in tree: 0 installed: 0
:debug:main tcl 8.6.14_0 exists in the ports tree
:debug:main tcl 8.6.14_0 +corefoundation+dtrace+threads is the latest installed
:debug:main tcl 8.6.14_0 +corefoundation+dtrace+threads is active
:debug:main Merging existing requested variants '+corefoundation+dtrace+threads' into variants
:debug:main new fully merged portvariants: corefoundation + dtrace + threads +
:debug:main Opening port in directory: /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/lang/tcl
:debug:main OS darwin/10.0.0d2 (macOS 10.6) arch powerpc
:debug:main only one arch supported, so not adding the default universal variant
:debug:main Executing variant threads provides threads
:debug:main Executing variant corefoundation provides corefoundation
:debug:main Executing variant dtrace provides dtrace
:debug:main Running callback portconfigure::add_automatic_compiler_dependencies
:debug:main Finished running callback portconfigure::add_automatic_compiler_dependencies
:debug:main Running callback portbuild::add_automatic_buildsystem_dependencies
:debug:main Finished running callback portbuild::add_automatic_buildsystem_dependencies
:debug:main Running callback portstartupitem::add_notes
:debug:main Finished running callback portstartupitem::add_notes
:debug:main No need to upgrade! tcl 8.6.14_0 >= tcl 8.6.14_0
:msg:main --->  Computing dependencies for sqlite3-tcl:info:main .:debug:main Searching for dependency: tcl
:debug:main Found Dependency: receipt exists for tcl
:debug:main Executing org.macports.main (sqlite3-tcl)
:debug:fetch fetch phase started at Tue Oct 29 20:59:36 CST 2024
:notice:fetch --->  Fetching distfiles for sqlite3-tcl
:debug:fetch Executing org.macports.fetch (sqlite3-tcl)
:debug:checksum checksum phase started at Tue Oct 29 20:59:36 CST 2024
:notice:checksum --->  Verifying checksums for sqlite3-tcl
:debug:checksum Executing org.macports.checksum (sqlite3-tcl)
:info:checksum --->  Checksumming sqlite-autoconf-3470000.tar.gz
:debug:checksum Calculated (rmd160) is 67b6fb631f7f5657907c3cd578e60994fb2e6013
:debug:checksum Correct (rmd160) checksum for sqlite-autoconf-3470000.tar.gz
:debug:checksum Calculated (sha256) is 83eb21a6f6a649f506df8bd3aab85a08f7556ceed5dbd8dea743ea003fc3a957
:debug:checksum Correct (sha256) checksum for sqlite-autoconf-3470000.tar.gz
:debug:checksum Calculated (size) is 3324599
:debug:checksum Correct (size) checksum for sqlite-autoconf-3470000.tar.gz
:debug:extract extract phase started at Tue Oct 29 20:59:36 CST 2024
:notice:extract --->  Extracting sqlite3-tcl
:debug:extract Executing org.macports.extract (sqlite3-tcl)
:info:extract --->  Extracting sqlite-autoconf-3470000.tar.gz
:debug:extract setting option extract.args to '/opt/local/var/macports/distfiles/sqlite3/sqlite-autoconf-3470000.tar.gz'
:debug:extract Environment: 
:debug:extract CC_PRINT_OPTIONS='YES'
:debug:extract CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/.CC_PRINT_OPTIONS'
:debug:extract CPATH='/opt/local/include'
:debug:extract DEVELOPER_DIR='/Developer'
:debug:extract LIBRARY_PATH='/opt/local/lib'
:debug:extract MACOSX_DEPLOYMENT_TARGET='10.6'
:debug:extract SOURCE_DATE_EPOCH='1729556912'
:info:extract Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/sqlite3/sqlite-autoconf-3470000.tar.gz' | /usr/bin/gnutar --no-same-owner -xf - 
:debug:extract system:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/sqlite3/sqlite-autoconf-3470000.tar.gz' | /usr/bin/gnutar --no-same-owner -xf - 
:debug:patch patch phase started at Tue Oct 29 20:59:36 CST 2024
:debug:patch Executing org.macports.patch (sqlite3-tcl)
:notice:patch --->  Applying patches to sqlite3-tcl
:info:patch --->  Applying patch-tea-generic-tclsqlite3.c.diff
:debug:patch Environment: 
:debug:patch CC_PRINT_OPTIONS='YES'
:debug:patch CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/.CC_PRINT_OPTIONS'
:debug:patch CPATH='/opt/local/include'
:debug:patch DEVELOPER_DIR='/Developer'
:debug:patch LIBRARY_PATH='/opt/local/lib'
:debug:patch MACOSX_DEPLOYMENT_TARGET='10.6'
:debug:patch SOURCE_DATE_EPOCH='1729556912'
:info:patch Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000/tea" && /usr/bin/patch -t -N -p0 < '/opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
:debug:patch system:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000/tea" && /usr/bin/patch -t -N -p0 < '/opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
:info:patch can't find file to patch at input line 3
:info:patch Perhaps you used the wrong -p or --strip option?
:info:patch The text leading up to this was:
:info:patch --------------------------
:info:patch |--- tea/generic/tclsqlite3.c.orig	2024-10-21 11:48:14
:info:patch |+++ tea/generic/tclsqlite3.c	2024-10-21 18:19:02
:info:patch --------------------------
:info:patch No file to patch.  Skipping patch.
:info:patch 1 out of 1 hunk ignored
:info:patch Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/work/sqlite-autoconf-3470000/tea" && /usr/bin/patch -t -N -p0 < '/opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/databases/sqlite3/files/patch-tea-generic-tclsqlite3.c.diff'
:info:patch Exit code: 1
:error:patch Failed to patch sqlite3-tcl: command execution failed
:debug:patch Error code: CHILDSTATUS 1021 1
:debug:patch Backtrace: command execution failed
:debug:patch     while executing
:debug:patch "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
:debug:patch     invoked from within
:debug:patch "command_exec patch "" "< '$patch'""
:debug:patch     (procedure "portpatch::patch_main" line 41)
:debug:patch     invoked from within
:debug:patch "$procedure $targetname"
:error:patch See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_databases_sqlite3/sqlite3-tcl/main.log for details.

I think this is the only error of this kind. I do not have problems with patching a lot of other ports. However, if this patch uses some very new feature, my MacPorts may not have it, it is roughly at 2.10.0.

comment:4 Changed 8 days ago by Schamschula (Marius Schamschula)

I see you are using Mac OS X 10.6. It looks like the patch file for ${os.major} < 11 may have too short a path.

comment:5 Changed 8 days ago by Marius Schamschula <mschamschula@…>

In 30f34236a5de18367465cf77dce71719cdcf34b3/macports-ports (master):

sqlite3: fix path for patch

See: #71192

comment:6 Changed 8 days ago by jmroot (Joshua Root)

You modified patch-tea-configure.diff, but patch-tea-generic-tclsqlite3.c.diff was the one that failed to apply. It's probably easier to use a consistent patch.dir instead of changing it on darwin < 11, and adjust the patches to work with that as needed.

comment:7 Changed 7 days ago by Schamschula (Marius Schamschula)

patch-tea-generic-tclsqlite3.c.diff applies correctly for me (see my above comment). Hence, I set the path of patch-tea-configure.diff to have the same root.

Somehow the patch is being applied differently for Mac OS X 10.6.

comment:8 in reply to:  7 Changed 7 days ago by jmroot (Joshua Root)

Replying to Schamschula:

Somehow the patch is being applied differently for Mac OS X 10.6.

Yes, as I said, patch.dir is being changed on darwin < 11. Line 109 of the Portfile.

comment:9 Changed 6 days ago by Marius Schamschula <mschamschula@…>

In 0aec46cfe88b27791602cbf212ef90c84482ec64/macports-ports (master):

sqlite3: use consistent paths for sqlite3tcl subport

See: #71192

comment:10 in reply to:  9 Changed 6 days ago by barracuda156

Replying to Marius Schamschula <mschamschula@…>:

In 0aec46cfe88b27791602cbf212ef90c84482ec64/macports-ports (master):

sqlite3: use consistent paths for sqlite3tcl subport

See: #71192

Thank you, apparently it is fixed.

comment:11 Changed 6 days ago by Schamschula (Marius Schamschula)

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.