# TI ACX 111 Compile Error

## dangod

Having trouble compiling this good old piece of software on an amd64 architecture. 

Solution would be pretty simple I guess. Just define a struct called semaphore properly.

There are some header files called sem.h in /usr/include/linux directory.

Is it worth to dig into this stuff or just buy a new wlan adapter?

Thanks a lot in advance for looking into this!

```
>>> Emerging (1 of 1) net-wireless/acx-0.3.37_p20080210

 * acx-20080210.tar.bz2 RMD160 SHA1 SHA256 size ;-) ...                  [ ok ]

 * Determining the location of the kernel source code

 * Found kernel source directory:

 *     /usr/src/linux

 * Found kernel object directory:

 *     /lib/modules/2.6.39-gentoo-r3/build

 * Found sources for kernel version:

 *     2.6.39-gentoo-r3

 * Checking for suitable kernel configuration options...

 [ ok ]

>>> Unpacking source...

>>> Unpacking acx-20080210.tar.bz2 to /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work

 * Applying 01_addRequestInfo.dpatch ...

 [ ok ]

 * Applying 02_fix_irqreturn_t.dpatch ...

 [ ok ]

 * Applying 03_typo_fix.dpatch ...

 [ ok ]

 * Applying 04_pci_and_usb.dpatch ...

 [ ok ]

 * Applying acx-2.6.33.patch ...

 [ ok ]

>>> Source unpacked in /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work

>>> Compiling source in /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210 ...

ln: failed to create symbolic link `Module.symvers': File exists

 * Preparing acx module

make -j2 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- LDFLAGS= -C /usr/src/linux SUBDIRS=/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210 modules 

make: Entering directory `/usr/src/linux-2.6.39-gentoo-r3'

  CC [M]  /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/wlan.o

  CC [M]  /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/conv.o

In file included from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx.h:5,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/wlan.c:49:

/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx_struct.h:1214: error: field 'sem' has incomplete type

In file included from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx.h:5,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/conv.c:43:

/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx_struct.h:1214: error: field 'sem' has incomplete type

In file included from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx.h:6,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/wlan.c:49:

/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx_func.h:115:1: warning: "printk_ratelimited" redefined

In file included from include/linux/kernel.h:20,

                 from include/linux/skbuff.h:17,

                 from include/linux/if_ether.h:126,

                 from include/linux/netdevice.h:29,

                 from include/linux/if_arp.h:26,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/wlan.c:45:

include/linux/printk.h:237:1: warning: this is the location of the previous definition

In file included from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx.h:6,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/conv.c:43:

/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/acx_func.h:115:1: warning: "printk_ratelimited" redefined

In file included from include/linux/kernel.h:20,

                 from include/linux/skbuff.h:17,

                 from /var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/conv.c:37:

include/linux/printk.h:237:1: warning: this is the location of the previous definition

cc1: warning: unrecognized command line option "-Wno-unused-but-set-variable"

make[1]: *** [/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/wlan.o] Error 1

make[1]: *** Waiting for unfinished jobs....

cc1: warning: unrecognized command line option "-Wno-unused-but-set-variable"

make[1]: *** [/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210/conv.o] Error 1

make: *** [_module_/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210] Error 2

make: Leaving directory `/usr/src/linux-2.6.39-gentoo-r3'

emake failed

 * ERROR: net-wireless/acx-0.3.37_p20080210 failed (compile phase):

 *   Unable to emake HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- LDFLAGS=  -C /usr/src/linux SUBDIRS=/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210 modules

 * 

 * Call stack:

 *     ebuild.sh, line   56:  Called src_compile

 *   environment, line 3451:  Called linux-mod_src_compile

 *   environment, line 2669:  Called die

 * The specific snippet of code:

 *               eval "emake HOSTCC=\"$(tc-getBUILD_CC)\"                   CROSS_COMPILE=${CHOST}-                   LDFLAGS=\"$(get_abi_LDFLAGS)\"                   ${BUILD_FIXES}                   ${BUILD_PARAMS}                   ${BUILD_TARGETS} " || die "Unable to emake HOSTCC="$(tc-getBUILD_CC)" CROSS_COMPILE=${CHOST}- LDFLAGS="$(get_abi_LDFLAGS)" ${BUILD_FIXES} ${BUILD_PARAMS} ${BUILD_TARGETS}";

 * 

 * If you need support, post the output of 'emerge --info =net-wireless/acx-0.3.37_p20080210',

 * the complete build log and the output of 'emerge -pqv =net-wireless/acx-0.3.37_p20080210'.

 * The complete build log is located at '/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/temp/build.log'.

 * The ebuild environment file is located at '/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/temp/environment'.

 * S: '/var/tmp/portage/net-wireless/acx-0.3.37_p20080210/work/acx-20080210'

```

----------

## gringo

 *Quote:*   

> Is it worth to dig into this stuff or just buy a new wlan adapter?

 

i dont think its worth it, i own one of these crappy acx based wlan cards too and with every kernel release things get worse. There is also no chance this thing will be accepted in mainline.

So, if you have the time & skills to fix it from time to time then sure, use it ; otherwise just buy a new ( well supoported) one.

cheers

----------

## dangod

Exactly, that's what I thought. Thanks for your reply.

cheers

----------

## roarinelk

just add "#include <linux/semaphore.h>"  to acx_struct.h  and it should build again.

----------

