SQLite

Check-in [e24a3efe]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:buildtclext.tcl: work around a case, reported in forum post 0683a49cb0, in which package maintainers edit their copy of tclConfig.sh to change the TCL_SHLIB_LD command.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: e24a3efec8c168b69d665ab20e8d715210208e6cf291ac93549fdd175a9009d6
User & Date: stephan 2024-11-15 15:31:13
Context
2024-11-15
16:35
Generic auto.def cleanups. No functional differences. (check-in: 02aceb8c user: stephan tags: trunk)
15:31
buildtclext.tcl: work around a case, reported in forum post 0683a49cb0, in which package maintainers edit their copy of tclConfig.sh to change the TCL_SHLIB_LD command. (check-in: e24a3efe user: stephan tags: trunk)
10:53
configure: add optional pkg-config support for detecting ICU. (check-in: 3e5b8077 user: stephan tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to tool/buildtclext.tcl.
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117

  # Read the tclConfig.sh file into the $tclConfig variable
  #
  #puts "using $LIBDIR/tclConfig.sh"
  set fd [open $LIBDIR/tclConfig.sh rb]
  set tclConfig [read $fd]
  close $fd
  
  # Extract parameter we will need from the tclConfig.sh file
  #
  set TCLMAJOR 8
  regexp {TCL_MAJOR_VERSION='(\d)'} $tclConfig all TCLMAJOR
  set SUFFIX so
  regexp {TCL_SHLIB_SUFFIX='\.([^']+)'} $tclConfig all SUFFIX
  if {$CC==""} {







|







103
104
105
106
107
108
109
110
111
112
113
114
115
116
117

  # Read the tclConfig.sh file into the $tclConfig variable
  #
  #puts "using $LIBDIR/tclConfig.sh"
  set fd [open $LIBDIR/tclConfig.sh rb]
  set tclConfig [read $fd]
  close $fd

  # Extract parameter we will need from the tclConfig.sh file
  #
  set TCLMAJOR 8
  regexp {TCL_MAJOR_VERSION='(\d)'} $tclConfig all TCLMAJOR
  set SUFFIX so
  regexp {TCL_SHLIB_SUFFIX='\.([^']+)'} $tclConfig all SUFFIX
  if {$CC==""} {
136
137
138
139
140
141
142
143
144
145
146
147
148




149
150
151
152
153
154
155
156
157
  }
  set cmd {${CC} ${CFLAGS} ${LDFLAGS} -shared}
  regexp {TCL_SHLIB_LD='([^']+)'} $tclConfig all cmd
  set LDFLAGS "$INC -DUSE_TCL_STUBS"
  if {[string length $OPTS]>1} {
    append LDFLAGS $OPTS
  }
  set CMD [subst $cmd]
  if {$TCLMAJOR>8} {
    set OUT libtcl9sqlite$VERSION.$SUFFIX
  } else {
    set OUT libsqlite$VERSION.$SUFFIX
  }




}
  
# Show information about prior installs
#
if {$infoonly} {
  set cnt 0
  foreach dir $auto_path {
    foreach subdir [glob -nocomplain -types d $dir/sqlite3*] {
      if {[file exists $subdir/pkgIndex.tcl]} {







<





>
>
>
>

|







136
137
138
139
140
141
142

143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
  }
  set cmd {${CC} ${CFLAGS} ${LDFLAGS} -shared}
  regexp {TCL_SHLIB_LD='([^']+)'} $tclConfig all cmd
  set LDFLAGS "$INC -DUSE_TCL_STUBS"
  if {[string length $OPTS]>1} {
    append LDFLAGS $OPTS
  }

  if {$TCLMAJOR>8} {
    set OUT libtcl9sqlite$VERSION.$SUFFIX
  } else {
    set OUT libsqlite$VERSION.$SUFFIX
  }
  set @ $OUT; # Workaround for https://sqlite.org/forum/forumpost/0683a49cb02f31a1
              # in which Gentoo edits their tclConfig.sh to include an soname
              # linker flag which includes ${@} (the target file's name).
  set CMD [subst $cmd]
}

# Show information about prior installs
#
if {$infoonly} {
  set cnt 0
  foreach dir $auto_path {
    foreach subdir [glob -nocomplain -types d $dir/sqlite3*] {
      if {[file exists $subdir/pkgIndex.tcl]} {