Here are working openwrt and source makefiles for the x10 USB transceiver driver from http://lemaymd.com/files/x10-cm19a-0.1.1.tar.bz2
I changed the directory structure found in the source tarball (above), removing all subdirs found there, and creating a new subdir called "src" that contains only the files license, README, AUTHORS, a modified Makefile, and the x10-cm19a.c file. I did that to simplify debugging, and because I have no use for the xmms tools and test suite.
To use the tarball, untar it, and from the x10-cm19a dir, delete the test and tools directories and create the "src" directory, then move all the files in the drivers/usb/comm/ directory to src. Then delete the drivers directory recursively. Rename or delete the original Makefile in src and replace it with the modified source Makefile listed below. You _MUST_ use tabs, not spaces, in both Makefiles, so your cut and paste will likely be trouble until you fix any tab conversions caused by the cut and paste. If the line begins with whitespace, it's a tab. You'll know you have spaces when the make fails with the error report 'Makefile:#: *** missing separator', where # is the offending line number in the makefile. Look closely at the path reported by the error to ascertain which makefile has spaces.
See the original tarball for usage of the driver (I've not fully tested it yet, but I have succeeded in building the ipkg without error).
I have used the Ubiquiti Routerstation source (an SVN R15349 copy of Openwrt with patches) to build the firmware for the routerstation. This is set up as a directory containing the openwrt tree source, so one can descend to the openwrt directory and do a make menuconfig as usual to build openwrt (the x10-cm19a module appears in the utilities submenu of menuconfig). However, the Ubiquiti system will apply it's own .config (the file openwrt-routerstation-r####/config/rs where #### is the ubiquiti release number) and overwrite any .config you might make with the openwrt menuconfig-you can hand edit the rs file to revise most software to the routerstation, but this module (x10-cm19a) will be offered as a prompt when you make the routerstation, so no hand editing of the rs file is required for it, instead, simply select the module with an "m" when prompted to include it for the routerstation after you invoke "make V=99" in the openwrt-routerstation-r#### directory. Regular openwrt users will just use the standard menuconfig and makemethods.
I'll be testing the module soon, but it is the original source so it should work fine.
===source Makefile===
obj-m := x10-cm19a.o
ifeq ($(MAKING_MODULES),1)
-include $(TOPDIR)/Rules.make
endif
===EOF source Makefile
===Openwrt package Makefile ===
#
# Copyright (C) 2009 WS. Herrick
#
# This software is licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=x10-cm19a
PKG_VERSION:=0.1.1
PKG_RELEASE:=1
###PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/x10-cm19a-$(PKG_VERSION)
####PKG_BUILD_DIR:=$(BUILD_DIR)/x10-cm19a-$(PKG_VERSION)
###PKG_SOURCE:=x10-cm19a-$(PKG_VERSION).tar.bz2
###PKG_SOURCE_URL:=http://lemaymd.com/files/
###PKG_MD5SUM:=9e7ee0feb8315163eda60538729addb6
include $(INCLUDE_DIR)/package.mk
define KernelPackage/x10-cm19a
TITLE:=X10-CM19A support
SECTION:=utils
CATEGORY:=Utilities
FILES:=$(PKG_BUILD_DIR)/x10-cm19a.$(LINUX_KMOD_SUFFIX)
AUTOLOAD:=$(call AutoLoad,50,x10-cm19a)
endef
define Package/x10-cm19a/description
Kernel module for X10 CM19a USB controller
endef
define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)
$(CP) ./src/* $(PKG_BUILD_DIR)/
endef
define Build/Compile
$(MAKE) -C $(LINUX_DIR) \
CROSS_COMPILE="$(TARGET_CROSS)" \
ARCH="$(LINUX_KARCH)" \
SUBDIRS="$(PKG_BUILD_DIR)" \
KERNELDIR=$(LINUX_DIR) \
CC="$(TARGET_CC)" \
modules
endef
$(eval $(call KernelPackage,x10-cm19a))
===EOF openwrt package Makefile ===
The Openwrt package Makefile was tediously exacting to construct, but ultimately, an examination of the included package siit's Makefile prevailed. Most other examples were inappropriate or flawed.
good luck,
p0g0