View | Details | Raw Unified
Collapse All | Expand All

(-) Build.PL.old (-13 / +13 lines)
 Lines 187-205    Link Here 
sub ACTION_postinstall {
sub ACTION_postinstall {
	my $self = shift;
	my $self = shift;
	my $sharedir = $self->install_destination('share');
	my $sharedir = $self->install_destination('share');
	my $mimedir = File::Spec->catdir($sharedir, 'mime');
#	my $mimedir = File::Spec->catdir($sharedir, 'mime');
	my $icon = File::Spec->catfile($sharedir, 'pixmaps', 'zim.png');
#	my $icon = File::Spec->catfile($sharedir, 'pixmaps', 'zim.png');
	for (
#	for (
		['update-desktop-database'],
#		['update-desktop-database'],
		['update-mime-database', $mimedir],
#		['update-mime-database', $mimedir],
	#	[qw{xdg-icon-resource install --context apps --size 64},
#	#	[qw{xdg-icon-resource install --context apps --size 64},
	#		$icon],
#	#		$icon],
		[qw{xdg-icon-resource install --context mimetypes --size 64},
#		[qw{xdg-icon-resource install --context mimetypes --size 64},
			$icon, q{text-x-zim-notebook}],
#			$icon, q{text-x-zim-notebook}],
	) {
#	) {
		print "Trying: @$_\n";
#		print "Trying: @$_\n";
		print system(@$_) == 0 ? "Ok\n\n" : "Failed\n\n" ;
#		print system(@$_) == 0 ? "Ok\n\n" : "Failed\n\n" ;
	}
#	}
}
}