Sponsored Content
Full Discussion: Build Error
Top Forums Programming Build Error Post 302590729 by rupeshkp728 on Tuesday 17th of January 2012 09:13:15 AM
Old 01-17-2012
Thanks Praveen for the reply.
I just changed the kernel source to an another and built it.
But now I am facing another problem.
I tried with a simple kernel module:
Code:
#include <linux/module.h>
#include <linux/version.h>
#include <linux/kernel.h>

/* Add your variables here */

static int __init mfd_init(void)
{
	printk(KERN_INFO "mfd registered");
	return 0;
}

static void __exit mfd_exit(void)
{
	printk(KERN_INFO "mfd deregistered");
}

module_init(mfd_init);
module_exit(mfd_exit);

MODULE_LICENSE("GPL");
MODULE_AUTHOR("RKP");
MODULE_DESCRIPTION("Test Driver");

I used the earlier makefile just changing the kernel source:
Code:
# if KERNELRELEASE is defined, we've been invoked from the
# kernel build system and can use its language.
ifneq ($(KERNELRELEASE),)
	src-m := $(wildcard ${SUBDIRS}/*.c)
	src-mod := $(wildcard ${SUBDIRS}/*.mod.c)
	src-m := $(notdir ${src-m})
	src-mod := $(notdir ${src-mod})
	src-m := $(filter-out ${src-mod}, ${src-m})
	obj-m := $(src-m:.c=.o)
# Otherwise we were called directly from the command
# line; invoke the kernel build system.
else
	KERNEL_SOURCE := /usr/src/linux-2.6.31.5-0.1/
	PWD := $(shell pwd)
default:
	$(MAKE) -C $(KERNEL_SOURCE) SUBDIRS=$(PWD) modules

clean:
	$(MAKE) -C $(KERNEL_SOURCE) SUBDIRS=$(PWD) clean
endif

The code got built.
But on loading the module it gives me an error:
Code:
insmod test_driver.ko 
insmod: error inserting 'test_driver.ko': -1 Invalid module format

Any idea how to get rid of this?
 

10 More Discussions You Might Find Interesting

1. SuSE

How can I build gcc (gettng 'cc' error)?

Hi I have installed Suse Linux 9.3 desktop on my computer. I found out I need to install 'gcc', and I was able to download the source code. I then tried to follow some instructions from WEB search to compile and build gcc, and I am getting the following error: --- linux:/gcc/gcc-2.95.3 #... (1 Reply)
Discussion started by: pat_and_cami
1 Replies

2. Solaris

build error

dears i working in solaris and when i type make for report it gives me the error kindly can you help me what is the reason -bash-3.00$ make BPSEXT130 make: Warning: File `BPSEXT130.rc' has modification time 12 s in the future make BPSEXT130.c make: Entering directory... (3 Replies)
Discussion started by: murad.jaber
3 Replies

3. SCO

Installation error for Kernel Re-build

Hi All, While installing a Service Pack on my Unix Solaris machine, i got the following error: UX:acomp: ERROR: "space.c", line 16: undefined symbol: CHROOT_SECURITY UX:acomp: ERROR: "space.c", line 16: non-constant initializer: op "NAME" UX:idmkunix: ERROR: Compile/link of 'Driver_atup.o... (9 Replies)
Discussion started by: am_yadav
9 Replies

4. AIX

Error thrown while trying to build in AIX 5.2

Hi All, Currently my project source code is compatible with HP-UX11.0 and Sun Solaris5.8. I m trying to build the source code in AIX 5.2 using gcc 4.2.2 compiler. Can anyone suggest me after seeing the rules file, what options do i need to specify to get rid of the cb error I m... (0 Replies)
Discussion started by: cleopatra789
0 Replies

5. Programming

kdevelop build project error

Hi, I am starting to learn how to use KDevelop. I have a console program with .cc, .h and Makefile. To work it in KDevelop, I firstly create a C++ Simple Hello World program, remove the single existing target in the project and also the auto-created main.cpp. Then I copy my .cc and .h files into... (1 Reply)
Discussion started by: flylehe
1 Replies

6. UNIX for Dummies Questions & Answers

Build Error: error: dereferencing pointer to incomplete type

I'm getting the following Error: prepare_pcap.c: In function `prepare_pkts': prepare_pcap.c:127: error: dereferencing pointer to incomplete type prepare_pcap.c:138: error: dereferencing pointer to incomplete type ==================================== This is the part of the relevant... (8 Replies)
Discussion started by: katwala
8 Replies

7. UNIX for Advanced & Expert Users

Error with ANT build for red5

I installed java at usr/local/jdk directory. My Java Version is 1.6.0_05. I have installed apache ant version 1.8.1 in folder opt/ant successfully. And later on I have installed RED 5.0.9 final version at /opt/ant directory. But I am getting error while building ant at RED5 , I got following... (1 Reply)
Discussion started by: ninadgac
1 Replies

8. Solaris

Error at ndiswrapper build

Today I tried to generate ndis Solaris driver. Problem is when I try to compile ndiswapper following instructions on opensolaris site. ndis wrapper (Community Group laptop.ndis) - XWiki My version of Solaris $ uname -a SunOS pc001 5.10 Generic_142910-17 i86pc i386 i86pc ... (0 Replies)
Discussion started by: solaris_user
0 Replies

9. UNIX for Dummies Questions & Answers

Adding SDK Build on Kernel Source Build

Hi, So I downloaded this kernel source and was able to build it successfully. But I want to add this SDK source code inside, can anyone help me how to do this? Note that the SDK source can be built by itself. I added the SDK in the main Makefile: init-y := init/ #added SDK... (0 Replies)
Discussion started by: h0ujun
0 Replies

10. Shell Programming and Scripting

Build.xml invocation by Build Script

Hi I have a build.xml file and I can run it on Windows via cmd. Now I want to write a script to invoke the same. Is there a way to do this? (1 Reply)
Discussion started by: ankur328
1 Replies
SND_VIA8233(4)						   BSD Kernel Interfaces Manual 					    SND_VIA8233(4)

NAME
snd_via8233 -- VIA Technologies VT8233 bridge device driver SYNOPSIS
To compile this driver into the kernel, place the following lines in your kernel configuration file: device sound device snd_via8233 Alternatively, to load the driver as a module at boot time, place the following line in loader.conf(5): snd_via8233_load="YES" DESCRIPTION
The snd_via8233 bridge driver allows the generic audio driver, sound(4), to attach to the VIA VT8233 audio devices. These audio chipsets are integrated in the southbridge on many VIA based motherboards. Runtime Configuration The following sysctl(8) variables are available in addition to those available to all sound(4) devices: dev.pcm.%d.polling Experimental polling mode, where the driver operates by querying the device state on each tick using callout(9). Polling is disabled by default. Do not enable it unless you are facing weird interrupt problems or if the device cannot generate interrupts at all. HARDWARE
The snd_via8233 driver supports the following audio chipsets: o VIA VT8233 o VIA VT8233A o VIA VT8233C o VIA VT8235 o VIA VT8237 o VIA VT8251 SEE ALSO
sound(4) HISTORY
The snd_via8233 device driver first appeared in FreeBSD 4.7. AUTHORS
This manual page was written by Joel Dahl <joel@FreeBSD.org>. BUGS
The snd_via8233 driver does not support S/PDIF. There is partial support in the code, so implementing it should be fairly easy if the right hardware is available. BSD
November 29, 2006 BSD
All times are GMT -4. The time now is 06:36 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy