I have added these changes to my github here:
http://github.com/h4ck3rm1k3/LibreDWGCPlusPlus

the simple makfile (Makefile.Perl) to control it.

please check and comment.
mike

compile everything with G++ :
 g++ -c -I . -fpic -DPIC *.c  -lperl -I/usr/lib/perl/5.10.0/CORE/

Link like this :
gcc -shared -lstdc++ decode.o dwg.o common.o bits.o dwg_wrap.o
missing.o encode.o print.o -o LibreDwg.so

Test like this  :
use LibreDwg;

#dwg_read_file

sub test_dwg_c
{
    my $filename=shift;
    my $error;
    my $dwg_struct = LibreDwg::Dwg_Data->new();

    $error = LibreDwgc::dwg_read_file($filename, $dwg_struct);

    LibreDwgc::dwg_free($dwg_struct);

  if ($error)
    {
      printf("\nERROR!\n\n");
    }
  else
    {
      printf("\nSUCCESS!\n\n");
    }

}

test_dwg_c shift;


it works!

see also :
http://www.swig.org/papers/Perl98/swigperl.htm




On Mon, Apr 26, 2010 at 12:42 PM, [email protected]
<[email protected]> wrote:
> Missing functions :
> #include "dwg.h"
> double dwg_model_page_x_min(_dwg_struct*) { return 0;};
> double dwg_model_page_x_max(_dwg_struct*) { return 0;};
> double dwg_model_page_y_min(_dwg_struct*) { return 0;};
> double dwg_model_page_y_max(_dwg_struct*) {return 0;};
>
>
> These were not defined in the code.
>


Reply via email to