SHA256
1
0
forked from pool/dia
OBS User unknown 2009-05-20 21:10:58 +00:00 committed by Git OBS Bridge
parent e7e9b1353b
commit 470e1d11ff
13 changed files with 235 additions and 224 deletions

View File

@ -1,11 +1,13 @@
--- configure.in
Index: configure.in
===================================================================
--- configure.in.orig
+++ configure.in
@@ -357,7 +357,7 @@
@@ -409,7 +409,7 @@ if test "$GCC" = yes; then
DIA_CHECK_CFLAG(-Wmissing-prototypes)
DIA_CHECK_CFLAG(-Wmissing-declarations)
DIA_CHECK_CFLAG(-finline-functions)
- DIA_CHECK_CFLAG(-fstrict-aliasing)
+ DIA_CHECK_CFLAG(-fno-strict-aliasing)
fi
AM_CONDITIONAL(HAVE_GCC, test "$GCC" = yes)
dnl DIA_CHECK_CFLAG(-Wshadow)
DIA_CHECK_CFLAG(-Wpointer-arith)
dnl DIA_CHECK_CFLAG(-Wswitch-enum)

View File

@ -1,11 +0,0 @@
--- dia-0.96-pre3/doc/en/usage-layers.xml~ 2007-01-21 17:12:45.000000000 +0100
+++ dia-0.96-pre3/doc/en/usage-layers.xml 2007-02-05 10:23:02.000000000 +0100
@@ -26,7 +26,7 @@
</para>
</tip>
<para>
- Each new diagram comes with the default layer labelled “Background”. Of course you can change its name and settings to customize it to your needs as you can do with any other layer.
+ Each new diagram comes with the default layer labelled “Backgroundâ€<C3A2>. Of course you can change its name and settings to customize it to your needs as you can do with any other layer.
</para>
<para>
You can use layers to create overlay slide show by drawing each incremental slide in a

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7bb43d8b0cb287d728ea479fb65d1b57b8530af773018214e7f312dceed34237
size 4445553

3
dia-0.97.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:9083382bd5435b6d6324fc601f359a7c759504e48adbcece0a7d5c45a76ccf5a
size 6736670

View File

@ -1,22 +0,0 @@
--- app/load_save.c
+++ app/load_save.c
@@ -940,7 +940,7 @@
#else
ret = 0; /* less paranoia on windoze */
#endif
- file = fdopen(fildes,"wb");
+ file = (FILE *) fdopen(fildes,"wb");
/* Now write the data in the temporary file name. */
--- app/paginate_psprint.c
+++ app/paginate_psprint.c
@@ -391,7 +391,7 @@
#ifdef G_OS_WIN32
file = win32_printer_open (printcmd);
#else
- file = popen(printcmd, "w");
+ file = (FILE *) popen(printcmd, "w");
#endif
is_pipe = TRUE;
} else {

29
dia-build-errors.patch Normal file
View File

@ -0,0 +1,29 @@
Index: dia-0.97/bindings/dia-properties.cpp
===================================================================
--- dia-0.97.orig/bindings/dia-properties.cpp
+++ dia-0.97/bindings/dia-properties.cpp
@@ -140,7 +140,7 @@ dia::Property< ::Property* >::get (const
::ArrayProperty *prop = (::ArrayProperty *)self;
// now build with new values
- int num_props = num_props = prop->ex_props->len;
+ int num_props = prop->ex_props->len;
for (int i = 0; i < prop->records->len; ++i) {
::Property* p = 0;
vec.push_back (new dia::Property <Property*> (0));
Index: dia-0.97/plug-ins/drs/dia-render-script-import.c
===================================================================
--- dia-0.97.orig/plug-ins/drs/dia-render-script-import.c
+++ dia-0.97/plug-ins/drs/dia-render-script-import.c
@@ -164,10 +164,9 @@ gboolean
import_drs (const gchar *filename, DiagramData *dia, void* user_data)
{
GList *item, *items;
- xmlNodePtr root;
xmlDocPtr doc = xmlParseFile(filename);
- items = read_items (root->xmlChildrenNode);
+ items = read_items (doc->xmlChildrenNode);
for (item = items; item != NULL; item = g_list_next (item)) {
DiaObject *obj = (DiaObject *)item->data;
layer_add_object(dia->active_layer, obj);

View File

@ -1,73 +0,0 @@
--- dia-0.95/app/app_procs.c
+++ dia-0.95/app/app_procs.c
@@ -111,6 +111,7 @@
char *show_layers);
static void create_user_dirs(void);
+static void create_user_files(void);
static PluginInitResult internal_plugin_init(PluginInfo *info);
static void process_opts(int argc, char **argv,
#if USE_GOPTION
@@ -557,6 +558,7 @@
DDisplay *ddisp = NULL;
Diagram *diagram = NULL;
gboolean made_conversions = FALSE;
+ gchar *rcf;
if (export_file_format) {
char *export_file_name = NULL;
@@ -662,6 +664,7 @@
static char *show_layers = NULL;
gboolean made_conversions = FALSE;
GSList *files = NULL;
+ gchar *rcf;
gchar *export_format_string =
/* Translators: The argument is a list of options, not to be translated */
@@ -862,8 +865,6 @@
gdk_rgb_init();
- gtk_rc_parse("diagtkrc");
-
if (!nosplash) {
app_splash_init("");
}
@@ -871,6 +872,11 @@
if (dia_is_interactive)
create_user_dirs();
+ create_user_files();
+
+ rcf = dia_config_filename("diagtkrc");
+ gtk_rc_parse(rcf);
+ g_free(rcf);
/* Init cursors: */
if (dia_is_interactive) {
@@ -1055,6 +1061,25 @@
return TRUE;
}
+static void create_user_files(void)
+{
+ gchar *rc = NULL;
+
+ rc = dia_config_filename("diagtkrc");
+
+ /* If the file does not exist, we put in our defaults */
+ if (!g_file_test(rc, G_FILE_TEST_EXISTS)) {
+ FILE *f;
+
+ /* Never mind if it fails */
+ if ((f = fopen(rc, "w"))!= NULL) {
+ fprintf(f, "gtk-can-change-accels = 1");
+ fclose(f);
+ }
+ }
+ g_free(rc);
+}
+
static void create_user_dirs(void)
{
gchar *dir, *subdir;

29
dia-diagtkrc.patch Normal file
View File

@ -0,0 +1,29 @@
Index: dia-0.97/lib/dialib.c
===================================================================
--- dia-0.97.orig/lib/dialib.c
+++ dia-0.97/lib/dialib.c
@@ -27,6 +27,7 @@
#include <libxml/xmlerror.h>
#include "dialib.h"
+#include "dia_dirs.h"
#include "message.h"
#include "utils.h"
#include "dia_image.h"
@@ -104,12 +105,15 @@ libdia_init (guint flags)
stdprops_init();
if (flags & DIA_INTERACTIVE) {
+ char *diagtkrc;
dia_image_init();
gdk_rgb_init();
- gtk_rc_parse("diagtkrc");
+ diagtkrc = dia_config_filename("diagtkrc");
+ gtk_rc_parse(diagtkrc);
+ g_free(diagtkrc);
color_init();
}

View File

@ -1,24 +0,0 @@
Index: plug-ins/python/group_props.py
===================================================================
RCS file: /cvs/gnome/dia/plug-ins/python/group_props.py,v
retrieving revision 1.3
diff -u -p -r1.3 group_props.py
--- plug-ins/python/group_props.py 18 Jul 2004 17:45:58 -0000 1.3
+++ plug-ins/python/group_props.py 17 Aug 2005 22:29:14 -0000
@@ -86,14 +86,14 @@ class CPropsDialog :
box1.pack_start(separator, expand=0)
separator.show()
- box2 = gtk.VBox(spacing=10)
+ box2 = gtk.HBox(spacing=10)
box2.set_border_width(10)
box1.pack_start(box2, expand=0)
box2.show()
button = gtk.Button("Ok")
button.connect("clicked", self.on_ok)
- box2.pack_start(button)
+ box2.pack_start(button, padding=80, expand=1, fill=0)
button.set_flags(gtk.CAN_DEFAULT)
button.grab_default()
button.show()

View File

@ -1,40 +0,0 @@
Index: dia-0.96.1/doc/Makefile.am
===================================================================
--- dia-0.96.1.orig/doc/Makefile.am
+++ dia-0.96.1/doc/Makefile.am
@@ -7,11 +7,11 @@ EXTRA_DIST = \
shape.dtd \
sheet.dtd
-if HAVE_GNOME
+#if HAVE_GNOME
helpdir = $(datadir)/gnome/help/dia
-else
-helpdir = $(pkgdatadir)/help
-endif
+#else
+#helpdir = $(pkgdatadir)/help
+#endif
# a simple rule to symlink en to C
install-data-local:
Index: dia-0.96.1/xmldocs.make
===================================================================
--- dia-0.96.1.orig/xmldocs.make
+++ dia-0.96.1/xmldocs.make
@@ -36,11 +36,11 @@
# ********** Begin of section some packagers may need to modify **********
# This variable (docdir) specifies where the documents should be installed.
# This default value should work for most packages.
-if HAVE_GNOME
+#if HAVE_GNOME
docdir = $(datadir)/gnome/help/$(docname)/$(lang)
-else
-docdir = $(datadir)/help/$(docname)/$(lang)
-endif
+#else
+#docdir = $(datadir)/help/$(docname)/$(lang)
+#endif
# ********** You should not have to edit below this line **********
xml_files = $(entities) $(docname).xml

View File

@ -1,20 +1,22 @@
--- dia-0.95/app/commands.c
+++ dia-0.95/app/commands.c
@@ -575,7 +575,7 @@
Index: dia-0.97/app/commands.c
===================================================================
--- dia-0.97.orig/app/commands.c
+++ dia-0.97/app/commands.c
@@ -690,7 +690,7 @@ help_manual_callback (GtkAction *action)
ShellExecuteA (0, "open", helpindex, NULL, helpdir, SW_SHOWNORMAL);
#else
command = getenv("BROWSER");
- command = g_strdup_printf("%s 'file://%s' &", command ? command : "gnome-open", helpindex);
+ command = g_strdup_printf("%s 'file://%s' &", command ? command : "call-browser", helpindex);
+ command = g_strdup_printf("%s 'file://%s' &", command ? command : "xdg-open", helpindex);
system(command);
g_free(command);
#endif
@@ -593,7 +593,7 @@
@@ -708,7 +708,7 @@ activate_url (GtkAboutDialog *about,
ShellExecuteA (0, "open", link, NULL, NULL, SW_SHOWNORMAL);
#else
gchar *command = getenv("BROWSER");
- command = g_strdup_printf("%s '%s' &", command ? command : "gnome-open", link);
+ command = g_strdup_printf("%s '%s' &", command ? command : "call-browser", link);
+ command = g_strdup_printf("%s '%s' &", command ? command : "xdg-open", link);
system(command);
g_free(command);
#endif

View File

@ -1,3 +1,64 @@
-------------------------------------------------------------------
Wed May 6 00:42:20 CEST 2009 - vuntz@novell.com
- Update to version 0.97:
+ Many build fixes.
+ Updated translations.
+ Improved rendering with cairo (PS, PDF, SVG, PNG, EMF) and also
default print through Gtk+/cairo support.
+ Simple Find & Replace for diagram objects names
+ Dedicated text editing mode finally allows to use 'Del' while
editing text and/or for whole object removal
+ Custom lines plug-in
+ Shapes can now have sub-shapes that can be scaled or not when
the main shape is scaled. Also, it is now possible to specify
that shapes are created with their stated sizes.
+ Much decreased start-up time and memory usage by delay loading
custom shapes.
+ Rotated text by "Standard - Outline" object (based on cairo)
+ Overhaul of the DXF plug-in (import and export)
+ With the help of libEMF dia now can write EMF on Linux(x86),
too.
+ New database table relation shapes
+ A huge step forward regarding properties of grouped objects
bgo#60331
+ Antialiased rendering done with cairo if the plug-in is loaded
+ Improvements on arrow bounding box calculations
+ The "UML - Class" dialog fits again 800x600 screen again
+ There is an optional 'integrated' UI for people otherwise
loosing their toolbox ;)
+ Experimental stand-alone bindings with the help of SWIG/C++
- Rename dia-0.92.2-callbrowser.patch to dia-xdg-open.patch, and
update the patch to use xdg-open.
- Respin dia-0.92.2-no-strict-aliasing.patch.
- Replace dia-create-user-files.patch with dia-diagtkrc.patch. This
last one is simpler and doesn't do things we don't want it to do.
- Drop dia-group-props-size.patch: doesn't seem to be needed
anymore.
- Drop dia-64bit-clean.patch: fixed upstream.
- Drop dia-help.patch: the use of --enable-gnome is enough for
this.
- Drop dia-0.96-pre3-docs.patch: fixed upstream.
- Add dia-build-errors.patch to fix compilation warnings.
- Remove unneeded BuildRequires: docbook-toys, libgnomeprint-devel
- Add BuildRequires: libEMF-devel (only for ix86), swig.
- Remove workaround for bnc#186174: I don't see how it could still
be needed.
- Remove --with-gnomeprint from configure: this doesn't exist
anymore.
- Pass --with-swig to configure.
- Pass --disable-static to configure and remove .la files.
- Do not add the GNOME category to the desktop file: it's already
there.
- Add a workaround for bgo#581537: rename the en help to C.
- Reorganize file list a bit.
-------------------------------------------------------------------
Fri May 1 03:26:28 CEST 2009 - vuntz@novell.com
- Remove AutoReqProv: it's default now.
- Remove checks for old versions of openSUSE.
-------------------------------------------------------------------
Fri Apr 3 11:38:44 CEST 2009 - vuntz@novell.com

138
dia.spec
View File

@ -1,5 +1,5 @@
#
# spec file for package dia (Version 0.96.1)
# spec file for package dia (Version 0.97)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@ -19,46 +19,51 @@
Name: dia
BuildRequires: docbook-toys docbook-xsl-stylesheets fdupes gcc-c++ intltool libgnomeprint-devel libgnomeui-devel libxslt-devel python-devel python-gtk-devel scrollkeeper sgml-skel translation-update-upstream update-desktop-files
BuildRequires: docbook-xsl-stylesheets
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: intltool
%ifarch %ix86
# libEMF is not on x86_64
BuildRequires: libEMF-devel
%endif
BuildRequires: libgnomeui-devel
BuildRequires: libxslt-devel
BuildRequires: python-devel
BuildRequires: python-gtk-devel
BuildRequires: scrollkeeper
BuildRequires: sgml-skel
BuildRequires: swig
BuildRequires: translation-update-upstream
BuildRequires: update-desktop-files
License: GPL v2 or later
Group: Productivity/Graphics/Other
Requires: ghostscript-fonts-std python-gtk
# Ugh. I guess there should be a -devel subpackage split out
# Warning: Missing "Requires: libpng-devel" in dependency chain (/usr/lib/dia/libdia.la from dia requires /usr/lib/libpng.la).
# Warning: Missing "Requires: glibc-devel" in dependency chain (/usr/lib/dia/libdia.la from dia requires /usr/lib/libm.so).
# Warning: Missing "Requires: zlib-devel" in dependency chain (/usr/lib/dia/libdia.la from dia requires /usr/lib/libz.so).
# Requires: glibc-devel libpng-devel zlib-devel
AutoReqProv: on
Requires: ghostscript-fonts-std
Requires: python-gtk
# for xdg-open
Requires: xdg-utils
Summary: A Diagram Creation Program
Version: 0.96.1
Release: 167
Version: 0.97
Release: 1
Source: ftp://ftp.gnome.org/pub/GNOME/stable/sources/dia/%{name}-%{version}.tar.bz2
Source1: font-test-japanese.dia
Source2: font-test-czech.dia
Source3: font-test-german-euro.dia
# PATCH-FIX-OPENSUSE dia-0.92.2-callbrowser.patch
Patch: %name-0.92.2-callbrowser.patch
# PATCH-FIX-UPSTREAM bgo581529 dia-xdg-open.patch -- Use xdg-open instead of gnome-open
Patch: dia-xdg-open.patch
# PATCH-FIX-OPENSUSE dia-0.92.2-no-strict-aliasing.patch
Patch3: dia-0.92.2-no-strict-aliasing.patch
# PATCH-FIX-OPENSUSE dia-create-user-files.patch
Patch5: dia-create-user-files.patch
# PATCH-FIX-OPENSUSE dia-group-props-size.patch
Patch8: dia-group-props-size.patch
# PATCH-FIX-UPSTREAM dia-64bit-clean.patch bgo519529
Patch13: dia-64bit-clean.patch
# PATCH-FIX-OPENSUSE dia-python-acinclude.patch
# PATCH-FIX-UPSTREAM bgo581531 dia-diagtkrc.patch vuntz@novell.com -- Use diagtkrc from config dir
Patch5: dia-diagtkrc.patch
# PATCH-FIX-UPSTREAM bgo581533 dia-python-acinclude.patch
Patch14: dia-python-acinclude.patch
# PATCH-FIX-OPENSUSE dia-help.patch bnc157798
Patch15: dia-help.patch
# PATCH-FIX-UPSTREAM dia-0.96-pre3-docs.patch bgo404535
Patch16: dia-0.96-pre3-docs.patch
# PATCH-FIX-UPSTREAM bgo581542 dia-build-errors.patch vuntz@novell.com -- Fix compilation warnings
Patch15: dia-build-errors.patch
# PATCH-FIX-OPENSUSE dia-remove-datetime.patch vuntz@novell.com -- Do not put date/time in the compiled binary (needed for build-compare)
Patch17: dia-remove-datetime.patch
Url: http://live.gnome.org/Dia
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if %suse_version > 1020
Requires: %{name}-lang = %{version}
%endif
%description
Dia is designed to be much like the commercial program 'Visio.' It can
@ -87,58 +92,111 @@ translation-update-upstream
%patch -p1
%patch3
%patch5 -p1
%patch8
%patch13
%patch14
%patch15 -p1
%patch16 -p1
%patch17 -p1
# Work around gettext bug #186174
LANG=en_US.UTF-8 msgconv po/ko.po -o po/ko.po.new
mv po/ko.po.new po/ko.po
cp $RPM_SOURCE_DIR/font-test*dia .
%build
autoreconf -f -i
intltoolize --force
%configure\
--disable-static\
--enable-db2html\
--enable-gnome\
--with-python\
--with-cairo\
--with-gnomeprint
--with-swig
make %{?jobs:-j%jobs}
%install
%makeinstall
%suse_update_desktop_file -r -N Dia -C "" -G "Diagram Editor" dia Office FlowChart GNOME
find %{buildroot} -type f -name "*.la" -exec %{__rm} -fv {} +
%suse_update_desktop_file -r -N Dia -C "" -G "Diagram Editor" dia Office FlowChart
# Change sr@Latn to sr@latin
mv %{buildroot}%{_datadir}/locale/sr@Latn %{buildroot}%{_datadir}/locale/sr@latin
# Workaround for bgo#581537: the C help is just a symlink to the en help. But
# find_lang doesn't like this
rm %{buildroot}%{_datadir}/gnome/help/dia/C
mv %{buildroot}%{_datadir}/gnome/help/dia/en %{buildroot}%{_datadir}/gnome/help/dia/C
%find_lang %{name}
# No need for mime-info-to-mime, application/x-dia-diagram is defined in freedesktop.org.xml
rm -r $RPM_BUILD_ROOT%{_datadir}/mime-info
%if %suse_version > 1020
%fdupes -s $RPM_BUILD_ROOT
%endif
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog INSTALL KNOWN_BUGS NEWS README TODO samples/*.dia font-test*dia
%{_bindir}/*
%{_libdir}/dia
%{_datadir}/applications/*.desktop
%{_datadir}/dia
%{_datadir}/pixmaps/*
%{_datadir}/icons/hicolor/*/apps/dia.*
%doc %{_datadir}/doc/dia
%doc %{_mandir}/man1/*.*
%doc AUTHORS COPYING ChangeLog INSTALL KNOWN_BUGS NEWS README TODO samples/*.dia font-test*dia
%doc %{_mandir}/fr/man1/*.*
%files lang -f %{name}.lang
%defattr(-,root,root)
%{_datadir}/gnome/help/dia/*
%changelog
* Wed May 06 2009 vuntz@novell.com
- Update to version 0.97:
+ Many build fixes.
+ Updated translations.
+ Improved rendering with cairo (PS, PDF, SVG, PNG, EMF) and also
default print through Gtk+/cairo support.
+ Simple Find & Replace for diagram objects names
+ Dedicated text editing mode finally allows to use 'Del' while
editing text and/or for whole object removal
+ Custom lines plug-in
+ Shapes can now have sub-shapes that can be scaled or not when
the main shape is scaled. Also, it is now possible to specify
that shapes are created with their stated sizes.
+ Much decreased start-up time and memory usage by delay loading
custom shapes.
+ Rotated text by "Standard - Outline" object (based on cairo)
+ Overhaul of the DXF plug-in (import and export)
+ With the help of libEMF dia now can write EMF on Linux(x86),
too.
+ New database table relation shapes
+ A huge step forward regarding properties of grouped objects
bgo#60331
+ Antialiased rendering done with cairo if the plug-in is loaded
+ Improvements on arrow bounding box calculations
+ The "UML - Class" dialog fits again 800x600 screen again
+ There is an optional 'integrated' UI for people otherwise
loosing their toolbox ;)
+ Experimental stand-alone bindings with the help of SWIG/C++
- Rename dia-0.92.2-callbrowser.patch to dia-xdg-open.patch, and
update the patch to use xdg-open.
- Respin dia-0.92.2-no-strict-aliasing.patch.
- Replace dia-create-user-files.patch with dia-diagtkrc.patch. This
last one is simpler and doesn't do things we don't want it to do.
- Drop dia-group-props-size.patch: doesn't seem to be needed
anymore.
- Drop dia-64bit-clean.patch: fixed upstream.
- Drop dia-help.patch: the use of --enable-gnome is enough for
this.
- Drop dia-0.96-pre3-docs.patch: fixed upstream.
- Add dia-build-errors.patch to fix compilation warnings.
- Remove unneeded BuildRequires: docbook-toys, libgnomeprint-devel
- Add BuildRequires: libEMF-devel (only for ix86), swig.
- Remove workaround for bnc#186174: I don't see how it could still
be needed.
- Remove --with-gnomeprint from configure: this doesn't exist
anymore.
- Pass --with-swig to configure.
- Pass --disable-static to configure and remove .la files.
- Do not add the GNOME category to the desktop file: it's already
there.
- Add a workaround for bgo#581537: rename the en help to C.
- Reorganize file list a bit.
* Fri May 01 2009 vuntz@novell.com
- Remove AutoReqProv: it's default now.
- Remove checks for old versions of openSUSE.
* Fri Apr 03 2009 vuntz@novell.com
- Remove python-numeric Requires: there's no reference to it
anywhere in the code, so it wasn't needed.