? info.diff
? old-info.diff
RCS file: /Volumes/src/cvs/od/proj/darwinports/base/src/port1.0/portdestroot.tcl,v
retrieving revision 1.7
diff -u -r1.7 portdestroot.tcl
|
|
|
|
| 76 | 76 | } |
| 77 | 77 | |
| 78 | 78 | proc destroot_finish {args} { |
| 79 | | global destroot |
| | 79 | global destroot prefix |
| 80 | 80 | |
| 81 | 81 | # Prune empty directories in ${destroot} |
| 82 | 82 | catch {system "find \"${destroot}\" -depth -type d -print | xargs rmdir 2>/dev/null"} |
| | 83 | # Delete any info/dir file since we're going to run install-info |
| | 84 | set dirfile "${destroot}/${prefix}/info/dir" |
| | 85 | if {[file exists $dirfile]} { |
| | 86 | ui_debug "removing $dirfile" |
| | 87 | file delete -force $dirfile |
| | 88 | } |
| 83 | 89 | return 0 |
| 84 | 90 | } |
RCS file: /Volumes/src/cvs/od/proj/darwinports/base/src/port1.0/portinstall.tcl,v
retrieving revision 1.64
diff -u -r1.64 portinstall.tcl
|
|
|
|
| 68 | 68 | exec touch -r $src_element $dst_element |
| 69 | 69 | } |
| 70 | 70 | } |
| | 71 | |
| | 72 | # if it's an info file in an info directory, run install-info |
| | 73 | if [regexp {(.*/info)/([^/]*\.info)$} $dst_element match path filename] { |
| | 74 | system "install-info ${path}/${filename} ${path}/dir" |
| | 75 | } |
| 71 | 76 | } |
| 72 | 77 | |
| 73 | 78 | proc directory_dig {rootdir workdir {cwd ""}} { |
RCS file: /Volumes/src/cvs/od/proj/darwinports/base/src/port1.0/portpackage.tcl,v
retrieving revision 1.43
diff -u -r1.43 portpackage.tcl
|
|
|
|
| 75 | 75 | file copy -force -- ${portresourcepath}/package/background.tiff ${pkgpath}/Contents/Resources/background.tiff |
| 76 | 76 | system "mkbom ${destpath} ${pkgpath}/Contents/Archive.bom" |
| 77 | 77 | system "cd ${destpath} && pax -x cpio -w -z . > ${pkgpath}/Contents/Archive.pax.gz" |
| | 78 | write_postinstall_script ${pkgpath}/Contents/Resources/postinstall ${destpath} |
| 78 | 79 | |
| 79 | 80 | write_sizes_file ${pkgpath}/Contents/Resources/Archive.sizes ${portname} ${portversion} ${pkgpath} ${destpath} |
| 80 | 81 | |
| … |
… |
|
| 243 | 244 | InstalledSize $installedSize |
| 244 | 245 | CompressedSize $compressedSize" |
| 245 | 246 | close $fd |
| | 247 | } |
| | 248 | |
| | 249 | proc write_postinstall_script {script destpath} { |
| | 250 | set find [open "|find ${destpath} -name *.info" r] |
| | 251 | # this never returns anything. |
| | 252 | # why? I dunno. tcl is not my friend. |
| | 253 | while {[gets $find fname] >= 0} { |
| | 254 | if {![info exists scriptfile]} { |
| | 255 | set scriptfile [open $script w] |
| | 256 | puts $scriptfile "#!/bin/sh" |
| | 257 | } |
| | 258 | regexp "^${destpath}(/.*/info)/(\[^/]*\.info)$" $fname match path filename |
| | 259 | puts $scriptfile "install-info ${path}/${filename} ${path}/dir" |
| | 260 | } |
| | 261 | if [info exists scriptfile] { |
| | 262 | close $scriptfile |
| | 263 | file attributes $script -permission +x |
| | 264 | } |
| | 265 | close $find |
| 246 | 266 | } |
RCS file: /Volumes/src/cvs/od/proj/darwinports/base/src/port1.0/portrpmpackage.tcl,v
retrieving revision 1.3
diff -u -r1.3 portrpmpackage.tcl
|
|
|
|
| 159 | 159 | %build |
| 160 | 160 | echo \"Go DarwinPorts\" |
| 161 | 161 | %install |
| 162 | | %clean |
| 163 | | %files -f ${destroot}/../${portname}.filelist |
| 164 | | " |
| | 162 | %clean" |
| | 163 | set filelist [open "${destroot}/../${portname}.filelist" r] |
| | 164 | set post {} |
| | 165 | set preun {} |
| | 166 | while {[gets $filelist fname] >= 0} { |
| | 167 | # if it's an info file in an info directory, run install-info |
| | 168 | if [regexp {"(.*/info)/(.*\.info)"$} $fname match path filename] { |
| | 169 | append post "install-info ${path}/${filename} ${path}/dir\n" |
| | 170 | append preun "install-info --delete ${path}/${filename} ${path}/dir\n" |
| | 171 | } |
| | 172 | } |
| | 173 | close $filelist |
| | 174 | if {$post != {}} { |
| | 175 | puts $specfd "%post |
| | 176 | ${post}" |
| | 177 | } |
| | 178 | if {$preun != {}} { |
| | 179 | puts $specfd "%preun |
| | 180 | ${preun}" |
| | 181 | } |
| | 182 | puts $specfd "%files -f ${destroot}/../${portname}.filelist" |
| 165 | 183 | close $specfd |
| 166 | 184 | } |
RCS file: /Volumes/src/cvs/od/proj/darwinports/base/src/port1.0/portuninstall.tcl,v
retrieving revision 1.28
diff -u -r1.28 portuninstall.tcl
|
|
|
|
| 119 | 119 | } |
| 120 | 120 | } |
| 121 | 121 | } else { |
| | 122 | # if it's an info file in an info directory, run install-info |
| | 123 | if [regexp {(.*/info)/([^/]*\.info)$} $fname match path filename] { |
| | 124 | system "install-info --delete ${path}/${filename} ${path}/dir" |
| | 125 | } |
| 122 | 126 | if [catch {file delete -- $fname}] { |
| 123 | 127 | ui_info "$UI_PREFIX [format [msgcat::mc "Uninstall unable to remove file %s"] $fname]" |
| 124 | 128 | set uninst_err 1 |