gramps: resource-path: forcibly create

- Fixes an issue seen on some systems, where file isn't properly created
- Also re-enable use of 'update-mime-database'
This commit is contained in:
Christopher Nielsen
2023-10-09 13:47:30 -04:00
parent 266731d75d
commit a825135c31
+12 -3
View File
@@ -6,7 +6,7 @@ PortGroup python 1.0
PortGroup app 1.1
github.setup gramps-project gramps 5.1.6 v
revision 1
revision 2
github.tarball_from archive
supported_archs noarch
@@ -97,16 +97,25 @@ if {![variant_isset quartz] && ![variant_isset x11]} {
}
post-destroot {
reinplace "s|${destroot}${python.prefix}|${prefix}|" \
set dir_share ${prefix}/share
set file_resource_path \
${destroot}${python.pkgd}/gramps/gen/utils/resource-path
if {[file exists ${file_resource_path}]} {
ui_info "resource-path: file exists, deleting: ${file_resource_path}"
file delete -force ${file_resource_path}
}
ui_info "resource-path: creating: ${file_resource_path}"
system "/bin/echo -n \"${dir_share}\" > ${file_resource_path}"
delete ${destroot}${prefix}/share
move ${destroot}${python.prefix}/share ${destroot}${prefix}
}
post-activate {
system "${prefix}/bin/update-desktop-database ${prefix}/share/applications"
# system "${prefix}/bin/update-mime-database ${prefix}/share/mime"
system "${prefix}/bin/update-mime-database ${prefix}/share/mime"
}
app.icon ${worksrcpath}/images/hicolor/scalable/apps/gramps.svg