[grisbi-devel] Grisbi 2.0 pour bientôt ?

Ludovic Rousseau ludovic.rousseau at gmail.com
Fri Jan 8 19:18:26 CET 2021


Le ven. 8 janv. 2021 à 19:03, Nicolas LAURENT <nl at haplo.info> a écrit :

> J’ai un patch qui fixe les 2 problèmes.
> Ludovic, j’ai déposé un dmg ici: http://ovh.to/uLd4Q8F
> Peux-tu tester?
>

Plantage au lancement de Grisbi.
Essais de ton côté *après* avoir déplacé ton dossier ~/gtk/

J'ai aussi un patch (joint).
Pour l'instant le nouveau chemin est codé en dur pour chercher dans
"/Applications/Grisbi.app/..."
Mais ça marche pour moi.

J'ai aussi testé ce binaire généré sur Mojave et ça marche sur Big Sur.

Ma version
http://ludovic.rousseau.free.fr/softwares/grisbi/Grisbi-1.9.99.dmg
Est-ce que ça marche pour toi ?

Je crois qu'on est proche du but :-)

à+

-- 
 Dr. Ludovic Rousseau
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listes.grisbi.org/pipermail/devel/attachments/20210108/5bd58e7c/attachment.html>
-------------- next part --------------
diff --git a/MacOS/manual_add.sh b/MacOS/manual_add.sh
index 5af079f58..89cfc4257 100755
--- a/MacOS/manual_add.sh
+++ b/MacOS/manual_add.sh
@@ -6,8 +6,11 @@ set -e
 
 DEST=MacOS/dist/Grisbi.app/Contents/Resources
 
-EXTRA_FILES="
+EXTRA_LIBS="
 lib/goffice/
+"
+
+EXTRA_FILES="
 share/libofx/dtd/
 share/icons/Adwaita/16x16/actions/go-down-symbolic.symbolic.png
 share/icons/Adwaita/16x16/actions/go-up-symbolic.symbolic.png
@@ -160,6 +163,24 @@ share/icons/Adwaita/16x16/ui/pan-down-symbolic.symbolic.png
 share/icons/Adwaita/16x16/ui/pan-end-symbolic.symbolic.png
 share/icons/Adwaita/16x16/ui/pan-start-symbolic.symbolic.png
 share/icons/Adwaita/24x24/status/image-missing.png
+lib/goffice/0.10.49/plugins//plot_distrib/plugin.xml
+lib/goffice/0.10.49/plugins//plot_distrib/plot-types.xml
+lib/goffice/0.10.49/plugins//smoothing/plugin.xml
+lib/goffice/0.10.49/plugins//smoothing/types.xml
+lib/goffice/0.10.49/plugins//plot_radar/plugin.xml
+lib/goffice/0.10.49/plugins//plot_radar/plot-types.xml
+lib/goffice/0.10.49/plugins//plot_barcol/plugin.xml
+lib/goffice/0.10.49/plugins//plot_barcol/plot-types.xml
+lib/goffice/0.10.49/plugins//plot_xy/plugin.xml
+lib/goffice/0.10.49/plugins//plot_xy/plot-types.xml
+lib/goffice/0.10.49/plugins//plot_pie/plugin.xml
+lib/goffice/0.10.49/plugins//plot_pie/plot-types.xml
+lib/goffice/0.10.49/plugins//reg_logfit/plugin.xml
+lib/goffice/0.10.49/plugins//reg_logfit/reg-types.xml
+lib/goffice/0.10.49/plugins//reg_linear/plugin.xml
+lib/goffice/0.10.49/plugins//reg_linear/reg-types.xml
+lib/goffice/0.10.49/plugins//plot_surface/plugin.xml
+lib/goffice/0.10.49/plugins//plot_surface/plot-types.xml
 "
 
 if [ -z "$PREFIX" ]
@@ -168,22 +189,42 @@ then
 	exit 1
 fi
 
-for file in $EXTRA_FILES
-do
-	echo $file
-	mkdir -p $DEST/$(dirname $file)
-	cp -a $PREFIX/$file $DEST/$file
-done
+function copy
+{
+	for file in $@
+	do
+		echo $file
+		mkdir -p $DEST/$(dirname $file)
+		cp -a $PREFIX/$file $DEST/$file
+	done
+}
+
+case "$1" in 
+	"gtk-mac-bundler")
+		# copy libs before running gtk-mac-bundler
+
+		copy $EXTRA_LIBS
+		;;
+
+	"")
+		copy $EXTRA_FILES
+
+		# the icons are NOT found in "ui/" directory. So make them available in
+		# "places/" instead.
+		( cd $DEST/share/icons/Adwaita/scalable/places ; ln -sf ../ui/* . )
+
+		#
+		mkdir -p $DEST/share/pixmaps/grisbi
+		( cd $DEST/share/pixmaps/grisbi ; ln -sf gtk-execute-24.png gtk-execute.png )
 
-# the icons are NOT found in "ui/" directory. So make them available in
-# "places/" instead.
-( cd $DEST/share/icons/Adwaita/scalable/places ; ln -sf ../ui/* . )
+		# patch Grisbi CSS for the dark mode
+		DARK='@import url("resource:///org/gtk/libgtk/theme/Adwaita/gtk-contained-dark.css");'
+		echo $DARK >> $DEST/share/grisbi/ui/grisbi-dark.css
+		;;
 
-#
-mkdir -p $DEST/share/pixmaps/grisbi
-( cd $DEST/share/pixmaps/grisbi ; ln -sf gtk-execute-24.png gtk-execute.png )
+	*)
+		echo "Unknown argument: $1"
+		exit 1
+		;;
+esac
 
-# patch Grisbi CSS for the dark mode
-DARK='@import url("resource:///org/gtk/libgtk/theme/Adwaita/gtk-contained-dark.css");'
-mkdir -p $DEST/share/grisbi/ui
-echo $DARK >> $DEST/share/grisbi/ui/grisbi-dark.css
diff --git a/Makefile.am b/Makefile.am
index ef898f60d..f8909b615 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -18,8 +18,9 @@ bundle:
 	sed -i.old -e "s/VERSION/$(GRISBI_MAJOR_VERSION).$(GRISBI_MINOR_VERSION).$(GRISBI_MICRO_VERSION)/" MacOS/Info.plist
 	sed -i.old -e "s/VERSION/$(GRISBI_MAJOR_VERSION).$(GRISBI_MINOR_VERSION).$(GRISBI_MICRO_VERSION)/" MacOS/Grisbi\ Launcher/Grisbi\ Launcher/Info.plist
 	rm -rf MacOS/dist
-	$(srcdir)/MacOS/manual_add.sh
+	$(srcdir)/MacOS/manual_add.sh gtk-mac-bundler
 	env GRIBSI_BUNDLE_PATH=$(srcdir) gtk-mac-bundler $(srcdir)/MacOS/Grisbi.bundle
+	$(srcdir)/MacOS/manual_add.sh
 	$(srcdir)/MacOS/create-launcher.sh
 	$(srcdir)/MacOS/create-dmg.sh --volname Grisbi --volicon $(srcdir)/MacOS/Grisbi.icns --window-size 640 400 --background $(srcdir)/MacOS/background.png --icon-size 96 --app-drop-link 500 250 --icon "Grisbi.app" 150 250  $(srcdir)/MacOS/Grisbi-$(GRISBI_MAJOR_VERSION).$(GRISBI_MINOR_VERSION).$(GRISBI_MICRO_VERSION).dmg $(srcdir)/MacOS/dist.new
 	mv MacOS/Info.plist.old MacOS/Info.plist
diff --git a/src/main.c b/src/main.c
index e57c730e0..9e16eff78 100644
--- a/src/main.c
+++ b/src/main.c
@@ -90,7 +90,10 @@ int main (int argc, char **argv)
     /* initialisation libgoffice */
     libgoffice_init ();
     /* Initialize plugins manager */
-    go_plugins_init (NULL, NULL, NULL, NULL, TRUE, GO_TYPE_PLUGIN_LOADER_MODULE);
+	GSList *plugins_list = NULL;
+	plugins_list = g_slist_append(plugins_list, "/Applications/Grisbi.app/Contents/Resources/Grisbi.app/Contents/Resources/lib/goffice/0.10.49/plugins");
+    go_plugins_init (NULL, NULL, NULL, plugins_list, TRUE, GO_TYPE_PLUGIN_LOADER_MODULE);
+	g_slist_free(plugins_list);
 #endif /* HAVE_GOFFICE */
 
     app = g_object_new (GRISBI_APP_TYPE,


More information about the devel mailing list