ifxmips-dsl-api: fix portability errors
[openwrt/svn-archive/archive.git] / package / ifxmips-dsl-api / patches / 500-portability.patch
1 --- a/configure.in
2 +++ b/configure.in
3 @@ -333,12 +333,12 @@ AC_ARG_ENABLE(ifxos-include,
4 echo Set the lib_ifxos include path $enableval
5 AC_SUBST([IFXOS_INCLUDE_PATH],[$enableval])
6 else
7 - echo -e Set the default lib_ifxos include path $DEFAULT_IFXOS_INCLUDE_PATH
8 + echo Set the default lib_ifxos include path $DEFAULT_IFXOS_INCLUDE_PATH
9 AC_SUBST([IFXOS_INCLUDE_PATH],[$DEFAULT_IFXOS_INCLUDE_PATH])
10 fi
11 ],
12 [
13 - echo -e Set the default lib_ifxos include path $DEFAULT_IFXOS_INCLUDE_PATH
14 + echo Set the default lib_ifxos include path $DEFAULT_IFXOS_INCLUDE_PATH
15 AC_SUBST([IFXOS_INCLUDE_PATH],[$DEFAULT_IFXOS_INCLUDE_PATH])
16 ]
17 )
18 @@ -1702,73 +1702,73 @@ dnl Set the configure params for dist ch
19 AC_SUBST([DISTCHECK_CONFIGURE_PARAMS],[$CONFIGURE_OPTIONS])
20
21 AC_CONFIG_COMMANDS_PRE([
22 -echo -e "------------------------------------------------------------------------"
23 -echo -e " Configuration for drv_dsl_cpe_api:"
24 -echo -e " Configure model type: $DSL_CONFIG_MODEL_TYPE"
25 -echo -e " Source code location: $srcdir"
26 -echo -e " Compiler: $CC"
27 -echo -e " Compiler c-flags: $CFLAGS"
28 -echo -e " Extra compiler c-flags: $EXTRA_DRV_CFLAGS"
29 -echo -e " Host System Type: $host"
30 -echo -e " Install path: $prefix"
31 -echo -e " Linux kernel include path: $KERNEL_INCL_PATH"
32 -echo -e " Linux kernel build path: $KERNEL_BUILD_PATH"
33 -echo -e " Linux kernel architecture: $KERNEL_ARCH"
34 -echo -e " Include IFXOS: $INCLUDE_DSL_CPE_API_IFXOS_SUPPORT"
35 -echo -e " IFXOS include path: $IFXOS_INCLUDE_PATH"
36 -echo -e " Driver Include Path $DSL_DRIVER_INCL_PATH"
37 -echo -e " DSL device: $DSL_DEVICE_NAME"
38 -echo -e " Max device number: $DSL_DRV_MAX_DEVICE_NUMBER"
39 -echo -e " Channels per line: $DSL_CHANNELS_PER_LINE"
40 -echo -e " Build lib (only for kernel 2.6) $DSL_CPE_API_LIBRARY_BUILD_2_6"
41 -echo -e " DSL data led flash frequency: $DSL_DATA_LED_FLASH_FREQUENCY Hz"
42 -echo -e " Disable debug prints: $DSL_DEBUG_DISABLE"
43 -echo -e " Preselection of max. debug level: $DSL_DBG_MAX_LEVEL_SET"
44 -echo -e " Preselected max. debug level: $DSL_DBG_MAX_LEVEL_PRE"
45 -echo -e " Include deprecated functions: $INCLUDE_DEPRECATED"
46 -echo -e " Include Device Exception Codes: $INCLUDE_DEVICE_EXCEPTION_CODES"
47 -echo -e " Include FW request support: $INCLUDE_FW_REQUEST_SUPPORT"
48 -echo -e " Include ADSL trace buffer: $INCLUDE_DSL_CPE_TRACE_BUFFER"
49 -echo -e " Include ADSL MIB: $INCLUDE_DSL_ADSL_MIB"
50 -echo -e " Include ADSL LED: $INCLUDE_ADSL_LED"
51 -echo -e " Include CEOC: $INCLUDE_DSL_CEOC"
52 -echo -e " Include config get support: $INCLUDE_DSL_CONFIG_GET"
53 -echo -e " Include System i/f configuration: $INCLUDE_DSL_SYSTEM_INTERFACE"
54 -echo -e " Include Resource Statistics: $INCLUDE_DSL_RESOURCE_STATISTICS"
55 -echo -e " Include Framing Parameters: $INCLUDE_DSL_FRAMING_PARAMETERS"
56 -echo -e " Include G997 Line Inventory: $INCLUDE_DSL_G997_LINE_INVENTORY"
57 -echo -e " Include G997 Framing Parameters: $INCLUDE_DSL_G997_FRAMING_PARAMETERS"
58 -echo -e " Include G997 per tone data: $INCLUDE_DSL_G997_PER_TONE"
59 -echo -e " Include G997 status: $INCLUDE_DSL_G997_STATUS"
60 -echo -e " Include G997 alarm: $INCLUDE_DSL_G997_ALARM"
61 -echo -e " Include DSL Bonding: $INCLUDE_DSL_BONDING"
62 -echo -e " Include Misc Line Status $INCLUDE_DSL_CPE_MISC_LINE_STATUS"
63 -echo -e " Include DELT: $INCLUDE_DSL_DELT"
64 -echo -e " Include DELT data static storage: $DSL_CPE_STATIC_DELT_DATA"
65 -echo -e " Include PM: $INCLUDE_DSL_PM"
66 -echo -e " Include PM config: $INCLUDE_DSL_CPE_PM_CONFIG"
67 -echo -e " Include PM total: $INCLUDE_DSL_CPE_PM_TOTAL_COUNTERS"
68 -echo -e " Include PM history: $INCLUDE_DSL_CPE_PM_HISTORY"
69 -echo -e " Include PM showtime: $INCLUDE_DSL_CPE_PM_SHOWTIME_COUNTERS"
70 -echo -e " Include PM optional: $INCLUDE_DSL_CPE_PM_OPTIONAL_PARAMETERS"
71 -echo -e " Include PM line: $INCLUDE_DSL_CPE_PM_LINE_COUNTERS"
72 -echo -e " Include PM line event showtime: $INCLUDE_DSL_CPE_PM_LINE_EVENT_SHOWTIME_COUNTERS"
73 -echo -e " Include PM channel: $INCLUDE_DSL_CPE_PM_CHANNEL_COUNTERS"
74 -echo -e " Include PM channel extended: $INCLUDE_DSL_CPE_PM_CHANNEL_EXT_COUNTERS"
75 -echo -e " Include PM data path: $INCLUDE_DSL_CPE_PM_DATA_PATH_COUNTERS"
76 -echo -e " Include PM data path failure: $INCLUDE_DSL_CPE_PM_DATA_PATH_FAILURE_COUNTERS"
77 -echo -e " Include PM ReTx: $INCLUDE_DSL_CPE_PM_RETX_COUNTERS"
78 -echo -e " Include PM line threshold: $INCLUDE_DSL_CPE_PM_LINE_THRESHOLDS"
79 -echo -e " Include PM channel threshold: $INCLUDE_DSL_CPE_PM_CHANNEL_THRESHOLDS"
80 -echo -e " Include PM data path threshold: $INCLUDE_DSL_CPE_PM_DATA_PATH_THRESHOLDS"
81 -echo -e " Include PM ReTx threshold: $INCLUDE_DSL_CPE_PM_RETX_THRESHOLDS"
82 -echo -e " Include FW memory free support: $INCLUDE_DSL_FIRMWARE_MEMORY_FREE"
83 -echo -e "----------------------- deprectated ! ----------------------------------"
84 -echo -e " Include PM line failure: $INCLUDE_DSL_CPE_PM_LINE_FAILURE_COUNTERS"
85 -echo -e ""
86 -echo -e " Settings:"
87 -echo -e " Configure options: $CONFIGURE_OPTIONS"
88 -echo -e "------------------------------------------------------------------------"
89 +echo "------------------------------------------------------------------------"
90 +echo " Configuration for drv_dsl_cpe_api:"
91 +echo " Configure model type: $DSL_CONFIG_MODEL_TYPE"
92 +echo " Source code location: $srcdir"
93 +echo " Compiler: $CC"
94 +echo " Compiler c-flags: $CFLAGS"
95 +echo " Extra compiler c-flags: $EXTRA_DRV_CFLAGS"
96 +echo " Host System Type: $host"
97 +echo " Install path: $prefix"
98 +echo " Linux kernel include path: $KERNEL_INCL_PATH"
99 +echo " Linux kernel build path: $KERNEL_BUILD_PATH"
100 +echo " Linux kernel architecture: $KERNEL_ARCH"
101 +echo " Include IFXOS: $INCLUDE_DSL_CPE_API_IFXOS_SUPPORT"
102 +echo " IFXOS include path: $IFXOS_INCLUDE_PATH"
103 +echo " Driver Include Path $DSL_DRIVER_INCL_PATH"
104 +echo " DSL device: $DSL_DEVICE_NAME"
105 +echo " Max device number: $DSL_DRV_MAX_DEVICE_NUMBER"
106 +echo " Channels per line: $DSL_CHANNELS_PER_LINE"
107 +echo " Build lib (only for kernel 2.6) $DSL_CPE_API_LIBRARY_BUILD_2_6"
108 +echo " DSL data led flash frequency: $DSL_DATA_LED_FLASH_FREQUENCY Hz"
109 +echo " Disable debug prints: $DSL_DEBUG_DISABLE"
110 +echo " Preselection of max. debug level: $DSL_DBG_MAX_LEVEL_SET"
111 +echo " Preselected max. debug level: $DSL_DBG_MAX_LEVEL_PRE"
112 +echo " Include deprecated functions: $INCLUDE_DEPRECATED"
113 +echo " Include Device Exception Codes: $INCLUDE_DEVICE_EXCEPTION_CODES"
114 +echo " Include FW request support: $INCLUDE_FW_REQUEST_SUPPORT"
115 +echo " Include ADSL trace buffer: $INCLUDE_DSL_CPE_TRACE_BUFFER"
116 +echo " Include ADSL MIB: $INCLUDE_DSL_ADSL_MIB"
117 +echo " Include ADSL LED: $INCLUDE_ADSL_LED"
118 +echo " Include CEOC: $INCLUDE_DSL_CEOC"
119 +echo " Include config get support: $INCLUDE_DSL_CONFIG_GET"
120 +echo " Include System i/f configuration: $INCLUDE_DSL_SYSTEM_INTERFACE"
121 +echo " Include Resource Statistics: $INCLUDE_DSL_RESOURCE_STATISTICS"
122 +echo " Include Framing Parameters: $INCLUDE_DSL_FRAMING_PARAMETERS"
123 +echo " Include G997 Line Inventory: $INCLUDE_DSL_G997_LINE_INVENTORY"
124 +echo " Include G997 Framing Parameters: $INCLUDE_DSL_G997_FRAMING_PARAMETERS"
125 +echo " Include G997 per tone data: $INCLUDE_DSL_G997_PER_TONE"
126 +echo " Include G997 status: $INCLUDE_DSL_G997_STATUS"
127 +echo " Include G997 alarm: $INCLUDE_DSL_G997_ALARM"
128 +echo " Include DSL Bonding: $INCLUDE_DSL_BONDING"
129 +echo " Include Misc Line Status $INCLUDE_DSL_CPE_MISC_LINE_STATUS"
130 +echo " Include DELT: $INCLUDE_DSL_DELT"
131 +echo " Include DELT data static storage: $DSL_CPE_STATIC_DELT_DATA"
132 +echo " Include PM: $INCLUDE_DSL_PM"
133 +echo " Include PM config: $INCLUDE_DSL_CPE_PM_CONFIG"
134 +echo " Include PM total: $INCLUDE_DSL_CPE_PM_TOTAL_COUNTERS"
135 +echo " Include PM history: $INCLUDE_DSL_CPE_PM_HISTORY"
136 +echo " Include PM showtime: $INCLUDE_DSL_CPE_PM_SHOWTIME_COUNTERS"
137 +echo " Include PM optional: $INCLUDE_DSL_CPE_PM_OPTIONAL_PARAMETERS"
138 +echo " Include PM line: $INCLUDE_DSL_CPE_PM_LINE_COUNTERS"
139 +echo " Include PM line event showtime: $INCLUDE_DSL_CPE_PM_LINE_EVENT_SHOWTIME_COUNTERS"
140 +echo " Include PM channel: $INCLUDE_DSL_CPE_PM_CHANNEL_COUNTERS"
141 +echo " Include PM channel extended: $INCLUDE_DSL_CPE_PM_CHANNEL_EXT_COUNTERS"
142 +echo " Include PM data path: $INCLUDE_DSL_CPE_PM_DATA_PATH_COUNTERS"
143 +echo " Include PM data path failure: $INCLUDE_DSL_CPE_PM_DATA_PATH_FAILURE_COUNTERS"
144 +echo " Include PM ReTx: $INCLUDE_DSL_CPE_PM_RETX_COUNTERS"
145 +echo " Include PM line threshold: $INCLUDE_DSL_CPE_PM_LINE_THRESHOLDS"
146 +echo " Include PM channel threshold: $INCLUDE_DSL_CPE_PM_CHANNEL_THRESHOLDS"
147 +echo " Include PM data path threshold: $INCLUDE_DSL_CPE_PM_DATA_PATH_THRESHOLDS"
148 +echo " Include PM ReTx threshold: $INCLUDE_DSL_CPE_PM_RETX_THRESHOLDS"
149 +echo " Include FW memory free support: $INCLUDE_DSL_FIRMWARE_MEMORY_FREE"
150 +echo "----------------------- deprectated ! ----------------------------------"
151 +echo " Include PM line failure: $INCLUDE_DSL_CPE_PM_LINE_FAILURE_COUNTERS"
152 +echo ""
153 +echo " Settings:"
154 +echo " Configure options: $CONFIGURE_OPTIONS"
155 +echo "------------------------------------------------------------------------"
156 ])
157
158 AC_CONFIG_FILES([Makefile src/Makefile])
159 --- a/src/Makefile.am
160 +++ b/src/Makefile.am
161 @@ -303,7 +303,7 @@ if KERNEL_2_6
162 drv_dsl_cpe_api_OBJS = "$(subst .c,.o,$(filter %.c,$(drv_dsl_cpe_api_SOURCES)))"
163
164 drv_dsl_cpe_api.ko: $(drv_dsl_cpe_api_SOURCES)
165 - @echo -e "drv_dsl_cpe_api: Making Linux 2.6.x kernel object"
166 + @echo "drv_dsl_cpe_api: Making Linux 2.6.x kernel object"
167 if test ! -e common/drv_dsl_cpe_api.c ; then \
168 echo "copy source files (as links only!)"; \
169 for f in $(filter %.c,$(drv_dsl_cpe_api_SOURCES)); do \
170 @@ -311,10 +311,10 @@ drv_dsl_cpe_api.ko: $(drv_dsl_cpe_api_SO
171 cp -s $(addprefix @abs_srcdir@/,$$f) $(PWD)/`dirname $$f`/ ; \
172 done \
173 fi
174 - @echo -e "# drv_dsl_cpe_api: Generated to build Linux 2.6.x kernel object" > $(PWD)/Kbuild
175 - @echo -e "obj-m := $(subst .ko,.o,$@)" >> $(PWD)/Kbuild
176 - @echo -e "$(subst .ko,,$@)-y := $(drv_dsl_cpe_api_OBJS)" >> $(PWD)/Kbuild
177 - @echo -e "EXTRA_CFLAGS := $(CFLAGS) -DHAVE_CONFIG_H $(drv_dsl_cpe_api_CFLAGS) $(DSL_DRIVER_INCL_PATH) $(IFXOS_INCLUDE_PATH) -I@abs_srcdir@/include -I$(PWD)/include" >> $(PWD)/Kbuild
178 + @echo "# drv_dsl_cpe_api: Generated to build Linux 2.6.x kernel object" > $(PWD)/Kbuild
179 + @echo "obj-m := $(subst .ko,.o,$@)" >> $(PWD)/Kbuild
180 + @echo "$(subst .ko,,$@)-y := $(drv_dsl_cpe_api_OBJS)" >> $(PWD)/Kbuild
181 + @echo "EXTRA_CFLAGS := $(CFLAGS) -DHAVE_CONFIG_H $(drv_dsl_cpe_api_CFLAGS) $(DSL_DRIVER_INCL_PATH) $(IFXOS_INCLUDE_PATH) -I@abs_srcdir@/include -I$(PWD)/include" >> $(PWD)/Kbuild
182 $(MAKE) ARCH=@KERNEL_ARCH@ -C @KERNEL_BUILD_PATH@ O=@KERNEL_BUILD_PATH@ M=$(PWD) modules
183
184 clean-generic: