Re: dia-list Digest, Vol 132, Issue 2



I've installed python2-dev, but i haven't try python3-dev, i use ubuntu 12.04, outside dia folder i have been succeed to compile c file with gcc, but when code inserted inside commands.c in folder dia/app, make have error like commands.c:17:20: fatal error: Python.h: No such file or directory,
Must i installed python3-dev?

On Apr 3, 2015 7:00 PM, <dia-list-request gnome org> wrote:
Send dia-list mailing list submissions to
        dia-list gnome org

To subscribe or unsubscribe via the World Wide Web, visit
        https://mail.gnome.org/mailman/listinfo/dia-list
or, via email, send a message with subject or body 'help' to
        dia-list-request gnome org

You can reach the person managing the list at
        dia-list-owner gnome org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of dia-list digest..."


Today's Topics:

   1. Re: dia-list Digest, Vol 132, Issue 1 (Yosua Alvin Adi Soetrisno)
   2. Re: dia-list Digest, Vol 132, Issue 1 (Octavio Alvarez)


----------------------------------------------------------------------

Message: 1
Date: Fri, 3 Apr 2015 09:48:43 +0700
From: Yosua Alvin Adi Soetrisno <yosuaalvin mti13 mail ugm ac id>
To: dia-list gnome org, alvarezp alvarezp ods org
Subject: Re: dia-list Digest, Vol 132, Issue 1
Message-ID:
        <CAFZkH6TQSq-eaD7akCdZz_1dG-903-LBN-U7zfcLJV=j9SvRjg mail gmail com>
Content-Type: text/plain; charset="utf-8"

I add some line to disp_callback.c like this
static void
add_custom_menu_item (GtkMenu *menu)
{
  GtkWidget *menu_item = gtk_menu_item_new_with_label(_("Custom Link"));
  g_signal_connect(GTK_OBJECT(menu_item), "activate",
G_CALLBACK(call_python_callback), NULL);
  gtk_menu_shell_append (GTK_MENU_SHELL (menu), menu_item);
  gtk_widget_show(menu_item);
}
and i add some line to commands.c like this
#include <Python.h>
...
void
call_python_callback (GtkAction *action)
{
    Py_SetProgramName("Testing"); /* optional but recommended */
    Py_Initialize();

    FILE *fp = fopen("tree.py", "r");
    if (fp == NULL)
        return 2;

    PyRun_SimpleFile(fp, "tree.py");
    Py_Finalize();

    fclose(fp);
    return 0;
}
When i make the compilation
commands.c:17:20: fatal error: Python.h: No such file or directory
How to solve that thanks

On Thu, Apr 2, 2015 at 7:00 PM, <dia-list-request gnome org> wrote:

> Send dia-list mailing list submissions to
>         dia-list gnome org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://mail.gnome.org/mailman/listinfo/dia-list
> or, via email, send a message with subject or body 'help' to
>         dia-list-request gnome org
>
> You can reach the person managing the list at
>         dia-list-owner gnome org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of dia-list digest..."
>
>
> Today's Topics:
>
>    1. DIA extend properties (Yosua Alvin Adi Soetrisno)
>    2. Re: DIA extend properties (Michael Ross)
>    3. Re: DIA extend properties (Octavio Alvarez)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Thu, 2 Apr 2015 00:21:24 +0700
> From: Yosua Alvin Adi Soetrisno <yosuaalvin mti13 mail ugm ac id>
> To: dia-list gnome org
> Subject: DIA extend properties
> Message-ID:
>         <
> CAFZkH6QiCST4-GtvdAE45omgL4emsLCFVRdLtHSOTJ5ChkCpSA mail gmail com>
> Content-Type: text/plain; charset="utf-8"
>
> Let me introduce myself I'm Yosua from Gadjah Mada University, I'm still on
> progress working my master thesis. I'd like to develop OpenERP module based
> on DIA OpenERP Interface. My problem is I can't extend default object
> properties with custom data type like properties list. I want to ask how to
> compile DIA with make, but there is some customization in dispcallback.c
> with include Python.h, i want to extend some right click properties with
> custom Python GTK Window, so i linked it with C script
> Thanks before, I've referenced by Lars Causen to ask in mailing list
> Regards Yosua Alvin
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://mail.gnome.org/archives/dia-list/attachments/20150402/462e7627/attachment.html
> >
>
> ------------------------------
>
> Message: 2
> Date: Wed, 1 Apr 2015 15:11:45 -0400
> From: Michael Ross <michael e ross gmail com>
> To: discussions about usage and development of dia
>         <dia-list gnome org>
> Subject: Re: DIA extend properties
> Message-ID:
>         <CANNQeoLcA=
> 7QELc3KdMQ6ufEODckFPykrtUcQwNQtMEXGSG39A mail gmail com>
> Content-Type: text/plain; charset="utf-8"
>
> Your message is received, but I do not know the answer.  Someone will write
> back who does know.
>
> On Wed, Apr 1, 2015 at 1:21 PM, Yosua Alvin Adi Soetrisno <
> yosuaalvin mti13 mail ugm ac id> wrote:
>
> > Let me introduce myself I'm Yosua from Gadjah Mada University, I'm still
> > on progress working my master thesis. I'd like to develop OpenERP module
> > based on DIA OpenERP Interface. My problem is I can't extend default
> object
> > properties with custom data type like properties list. I want to ask how
> to
> > compile DIA with make, but there is some customization in dispcallback.c
> > with include Python.h, i want to extend some right click properties with
> > custom Python GTK Window, so i linked it with C script
> > Thanks before, I've referenced by Lars Causen to ask in mailing list
> > Regards Yosua Alvin
> >
> > _______________________________________________
> > dia-list mailing list
> > dia-list gnome org
> > https://mail.gnome.org/mailman/listinfo/dia-list
> > FAQ at http://live.gnome.org/Dia/Faq
> > Main page at http://live.gnome.org/Dia
> >
> >
> >
>
>
> --
> To invent, you need a good imagination and a pile of junk.
> Thomas A. Edison
> <http://www.brainyquote.com/quotes/quotes/t/thomasaed125362.html>
>
> A public-opinion poll is no substitute for thought.
> *Warren Buffet*
>
> Michael E. Ross
> (919) 585-6737 Land
> (919) 576-0824 <https://www.google.com/voice/b/0?pli=1#phones> Google
> Phone
> (919) 631-1451 Cell
>
> michael e ross gmail com
> <michael e ross gmail com>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://mail.gnome.org/archives/dia-list/attachments/20150401/d30455d8/attachment.html
> >
>
> ------------------------------
>
> Message: 3
> Date: Wed, 01 Apr 2015 23:19:49 -0700
> From: Octavio Alvarez <alvarezp alvarezp ods org>
> To: discussions about usage and development of dia
>         <dia-list gnome org>
> Subject: Re: DIA extend properties
> Message-ID: <551CDF85 8060408 alvarezp ods org>
> Content-Type: text/plain; charset=windows-1252
>
> On 01/04/15 10:21, Yosua Alvin Adi Soetrisno wrote:
> > I want to ask how to compile DIA with make
>
> Hi.
>
> What happens when you try it?
>
>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> dia-list mailing list
> dia-list gnome org
> https://mail.gnome.org/mailman/listinfo/dia-list
>
>
> ------------------------------
>
> End of dia-list Digest, Vol 132, Issue 1
> ****************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.gnome.org/archives/dia-list/attachments/20150403/8f9946f6/attachment.html>

------------------------------

Message: 2
Date: Thu, 02 Apr 2015 20:21:36 -0700
From: Octavio Alvarez <alvarezp alvarezp ods org>
To: dia-list gnome org
Subject: Re: dia-list Digest, Vol 132, Issue 1
Message-ID: <551E0740 1040908 alvarezp ods org>
Content-Type: text/plain; charset=utf-8

On 02/04/15 19:48, Yosua Alvin Adi Soetrisno wrote:
> When i make the compilation
> commands.c:17:20: fatal error: Python.h: No such file or directory
> How to solve that thanks

If you are on a Debian-based system try installing python3-dev. In other
systems there should be a similar package related to Python development
headers.

Best regards.




------------------------------

Subject: Digest Footer

_______________________________________________
dia-list mailing list
dia-list gnome org
https://mail.gnome.org/mailman/listinfo/dia-list


------------------------------

End of dia-list Digest, Vol 132, Issue 2
****************************************


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]