warp_c starting

18 views
Skip to first unread message

jacques silberstein

unread,
Jan 12, 2026, 12:37:31 PM (7 days ago) Jan 12
to Eiffel Users

I just try to use wrap_c. My objective being to wrap the modbus protocol.

I'm on linux debian.

I use the https://github.com/eiffel-wrap-c/WrapC/tree/master/doc#understanding_wrapc as sources.

Naturally I try to start whit the basic example "hello_world". 

here are my first try:

jacques@neuchatel:/Eiffel_archives/EWG/ewg_0_9_0/example$ wrap_c --output-dir=/tmp/wrap/ --full-header=simple/library/manual_wrapper/c/include/simple_header.h 
cc1: fatal error: simple/library/manual_wrapper/c/include/simple_header.h: Aucun fichier ou dossier de ce type
compilation terminated.
Syntax error in "simple_header_cpp.h" at line 1
jacques@neuchatel:/Eiffel_archives/EWG/ewg_0_9_0/example$ cat simple/library/manual_wrapper/c/include/simple_header.h 
#ifndef __EWG_SIMPLE_HEADER__
#define __EWG_SIMPLE_HEADER__

struct foo
{
  int a,b,*pc;
};

typedef union
{
  int a;
} foo1;

typedef enum
{
  red,
  blue,
  green
} colors;

void func1 (int a, int b);

int func2 (int a, int b);

#endif

This is a little bit confusing :

fatal error: simple/library/manual_wrapper/c/include/simple_header.h: Aucun fichier ou dossier de ce type

and

Syntax error in "simple_header_cpp.h" at line 1

A syntax error in an unexisting file !

the wrap_c version is: wrap_c version 1.0.0


I also try, with a config option has suggested. Here is the result:

jacques@neuchatel:/Eiffel_archives/EWG/ewg_0_9_0/example$ wrap_c --output-dir=/tmp/wrap/ --full-header=simple/library/manual_wrapper/c/include/simple_header.h --config=simple/library/config.ewg 
cc1: fatal error: simple/library/manual_wrapper/c/include/simple_header.h: Aucun fichier ou dossier de ce type
compilation terminated.
wrap_c: cannot read 'simple/library/config.ewg'
jacques@neuchatel:/Eiffel_archives/EWG/ewg_0_9_0/example$ cat simple/library/config.ewg
<?xml version="1.0"?>
<ewg_config name="simple">

  <rule_list>
    <rule>
      <match>
      </match>
      <wrapper type="default">
      </wrapper>
    </rule>
  </rule_list>




-- 

Cordialement

Jacques Silberstein

Ulrich Windl

unread,
Jan 13, 2026, 4:45:26 AM (7 days ago) Jan 13
to 'jacques silberstein' via Eiffel Users
Hi!

As not everybody understands French well, couldn't you try to set the language to default English temporarily (for the error messages)?

12.01.2026 18:37:25 'jacques silberstein' via Eiffel Users <eiffel...@googlegroups.com>:
> --
> You received this message because you are subscribed to the Google Groups "Eiffel Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to eiffel-users...@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/eiffel-users/d044449b-a996-49c8-92f4-34b92427138c%40abstraction.ch[https://groups.google.com/d/msgid/eiffel-users/d044449b-a996-49c8-92f4-34b92427138c%40abstraction.ch?utm_medium=email&utm_source=footer].
Reply all
Reply to author
Forward
0 new messages