[Home]

Summary:ASTERISK-07342: [patch] Unable to build Zaptel 1.2.7 due to massive number of errors
Reporter:Lee Archer (vgster)Labels:
Date Opened:2006-07-15 02:42:40Date Closed:2008-06-07 11:43:26
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) New.diff
( 1) zaptel.build.prob.txt
( 2) zaptel.Makefile.patch
Description:It looks like it isn't finding the headers in include properly

/usr/src/zaptel-1.2.7/vpm450m.c:34:20: error: octdef.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:36:36: error: apilib/octapi_largmath.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:38:40: error: oct6100api/oct6100_defines.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:39:39: error: oct6100api/oct6100_errors.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:40:38: error: oct6100api/oct6100_apiud.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:42:33: error: apilib/octapi_llman.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:44:41: error: oct6100api/oct6100_tlv_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:45:47: error: oct6100api/oct6100_chip_open_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:46:48: error: oct6100api/oct6100_chip_stats_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:47:48: error: oct6100api/oct6100_interrupts_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:48:45: error: oct6100api/oct6100_channel_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:49:50: error: oct6100api/oct6100_remote_debug_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:50:43: error: oct6100api/oct6100_debug_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:51:41: error: oct6100api/oct6100_api_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:52:48: error: oct6100api/oct6100_adpcm_chan_inst.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:54:47: error: oct6100api/oct6100_interrupts_pub.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:55:46: error: oct6100api/oct6100_chip_open_pub.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:56:44: error: oct6100api/oct6100_channel_pub.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:57:47: error: oct6100api/oct6100_adpcm_chan_pub.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:59:36: error: oct6100_chip_open_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:60:40: error: oct6100_miscellaneous_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:61:33: error: oct6100_memory_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:62:31: error: oct6100_tsst_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:63:34: error: oct6100_channel_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:64:37: error: oct6100_adpcm_chan_priv.h: No such file or directory
/usr/src/zaptel-1.2.7/vpm450m.c:85: error: syntax error before ?Oct6100ApiGetAdpcmChanSwSizes?
/usr/src/zaptel-1.2.7/vpm450m.c:86: error: syntax error before ?tPOCT6100_CHIP_OPEN?
/usr/src/zaptel-1.2.7/vpm450m.c:88: warning: return type defaults to ?int?
/usr/src/zaptel-1.2.7/vpm450m.c:88: warning: function declaration isn?t a prototype
/usr/src/zaptel-1.2.7/vpm450m.c: In function ?Oct6100ApiGetAdpcmChanSwSizes?:
/usr/src/zaptel-1.2.7/vpm450m.c:89: error: ?UINT32? undeclared (first use in this function)
/usr/src/zaptel-1.2.7/vpm450m.c:89: error: (Each undeclared identifier is reported only once
/usr/src/zaptel-1.2.7/vpm450m.c:89: error: for each function it appears in.)

This is just a sample.
Comments:By: Tilghman Lesher (tilghman) 2006-07-15 08:23:41

1.  Were you able to build zaptel-1.2.6 without errors?
2.  What is the output of 'gcc -v'?
3.  What is your architecture/OS/distribution?

By: Lee Archer (vgster) 2006-07-15 10:30:24

gcc version 4.0.2 20050901
On SuSE 10 with a 2.6.13 kernel.

Yes the previous version of zaptel have and still do compile just fine.  I get a few warnings with the xpp stuff but it all compiles.

By: Russell Bryant (russell) 2006-07-15 10:38:06

These errors would not apply to 1.2.6, because they are related to the addition of the vpm450 support.  If you don't need the wct4xxp driver, you can remove it from the MODULES list in the Makefile and the rest should be fine.  I'm not sure what the issue is since it builds fine on my machine ...

By: Kevin P. Fleming (kpfleming) 2006-07-15 19:23:11

Please edit the Makefile in the zaptel directory, find the line that starts with KMAKE and add the string V=1 to the end of it. Then run the 'make' again, and upload the output as an _attachment_ to this bug. Thanks.

By: Lee Archer (vgster) 2006-07-16 09:49:32

File has been uploaded.  It looks like it is looking for it's headers in -I/usr/src/linux-2.6.13-15.10/include/oct6100api which is the wrong folder since the includes are in the zaptel/include folder.  I also tried this on Gentoo with Linux 2.6.16 and gcc version 3.4.6 and it built fine.

Gentoo is looking for headers in -I/usr/src/zaptel-1.2.7/include  -I/usr/src/zaptel-1.2.7/include/oct6100api which is correct.

By: Russell Bryant (russell) 2006-07-16 13:51:22

near the top of the Makefile, you'll find a line that reads: PWD=$(shell pwd)

Please try removing the "ifeq" and "endif" lines that surround it and see if it fixes your problem.

By: Lee Archer (vgster) 2006-07-17 02:30:46

Nope same outcome.

By: Håkan Källberg (hk) 2006-07-17 04:38:50

OS: SuSE 10.1
gcc: 4.1.0
Linux: 2.6.16.13  i686

I can confirm the problem. With make CFLAS=-I<SRCDIR>/include, you get around the first error and get further, but instead I got:

make[1]: Entering directory `/usr/src/linux-2.6.16.13-4-obj/i386/default'
make -C ../../../linux-2.6.16.13-4 O=../linux-2.6.16.13-4-obj/i386/default modules
 CC [M]  /opt/local/src/zaptel-1.2.7/zaptel.o
/opt/local/src/zaptel-1.2.7/zaptel.c:85:26: error: linux/zaptel.h: No such file or directory

If I take away the wct4xxp as suggested, it works!

By: andrea lanza (lanzaandrea) 2006-07-17 09:51:51

I can confirm the problem too
I am running Suse Linux 10.0
I had no problem with 1.2.6
I have the last platform kernel
2.6.13-15.10-smp
and I tried both the svn version and tar.gz version.

I don't know where these missing files should be present;
I have them under zaptel-1.2/include

I didn't undertand what to do to remove vpm450 support; my
MODULES lines in Makefile looks like:

MODULES:=zaptel tor2 torisa wcusb wcfxo wctdm wctdm24xxp \
        ztdynamic ztd-eth wct1xxp wct4xxp wcte11xp pciradio \
        ztd-loc # ztdummy

it's not clear (to me!!!) which module is to remove

Andrea



By: andrea lanza (lanzaandrea) 2006-07-17 10:04:03

Sorry, I did't read carefully.
I removed wct4xxp from MODULES and compilation correctly ended.
I also saw no changes removing "ifeq" and "endif"

By: Russell Bryant (russell) 2006-07-18 00:38:14

I'm downloading a vmware image of SuSE 10 so that I can recreate the problem locally.

If anyone else is interested in the image, this is one I'm downloading:

http://developer.kde.org/~binner/vmware/

By: pkubat (pkubat) 2006-07-18 15:53:26

Same problem on SLES9

If you change the PWD=$(shell pwd) and hard code where the zaptel sources are it will them compile these modules.

Still does not compile clean, tracking down that now.

By: Håkan Källberg (hk) 2006-08-03 09:24:10

If you add a hard coded path, as above, you break the relocated installation:
make INSTALL_PREFIX=foo/bar install, which is imortant for us building packages.

What I think is the correct solution is to change line 114 in the Makefile from:

   EXTRA_CFLAGS:=-I$(PWD)/include  -I$(PWD)/include/oct6100api

to:

   EXTRA_CFLAGS:=-I$(SUBDIRS)/include  -I$(SUBDIRS)/include/oct6100api

As it is a one liner, I don't bother to make a Patch. OK?

You can see why this is The Right Thing to do in line 41:

   KMAKE:= $(MAKE) -C $(KSRC) SUBDIRS=$(PWD)

Verified to work on SuSE 10.1!



By: Lee Archer (vgster) 2006-08-03 09:29:30

I tried this and the problem looks fixed with SuSE 10 also.

By: Serge Vecher (serge-v) 2006-08-03 09:34:49

hk: please make a patch and confirm your disclaimer status here please. Would be greatly apreciated. Thanks!

By: Håkan Källberg (hk) 2006-08-03 10:36:14

Disclaimer is prepared, will be filed!

By: Serge Vecher (serge-v) 2006-08-03 10:40:50

thanks, man. The patch looks weird. Can you please take a look at this page http://www.asterisk.org/developers/Patch_Howto

By: Håkan Källberg (hk) 2006-08-03 11:20:35

Well, it is a regular context diff file. Exactly what pepole running releases need to get thier release source working. I therefor object *slightly* to the method described in the sugested document. Nevertheless, a new conforming patch is added, but not tested. In this case, the patch is more or less obvios, so I don't expect a problem. Now both patches are available, for conveniance:-)



By: John Lange (johnlange) 2006-08-03 12:50:59

Just confirming that I checked out code from SVN trunk 38820 and this problem now appears to be fixed. It compiled fine under OpenSUSE 10.1 where as earlier today it did not.

By: Håkan Källberg (hk) 2006-08-03 14:07:09

I had to make one more change to get the patch to work with trunk too. Now it should be OK.

By: Russell Bryant (russell) 2006-08-05 00:56:43

fixed in 1.2 and the trunk in revisions 1259 and 1260, thanks!

By: Digium Subversion (svnbot) 2008-06-07 11:43:23

Repository: dahdi
Revision: 1259

U   branches/1.2/Makefile

------------------------------------------------------------------------
r1259 | russell | 2008-06-07 11:43:23 -0500 (Sat, 07 Jun 2008) | 2 lines

Fix the zaptel build on SuSE 10.1 (issue ASTERISK-7342, hk)

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

http://svn.digium.com/view/dahdi?view=rev&revision=1259

By: Digium Subversion (svnbot) 2008-06-07 11:43:26

Repository: dahdi
Revision: 1260

_U  trunk/
U   trunk/Makefile

------------------------------------------------------------------------
r1260 | russell | 2008-06-07 11:43:25 -0500 (Sat, 07 Jun 2008) | 10 lines

Merged revisions 1259 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1259 | russell | 2006-08-05 01:53:20 -0400 (Sat, 05 Aug 2006) | 2 lines

Fix the zaptel build on SuSE 10.1 (issue ASTERISK-7342, hk)

........

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

http://svn.digium.com/view/dahdi?view=rev&revision=1260