Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 12-08-2001, 02:53 PM   #1
LQ Newbie
Registered: Nov 2001
Posts: 8

Rep: Reputation: 0
module compilation

i am trying to compile a simple hello module but when i write

gcc -c -Wall hello.c

then i get

warning: implicit declaration of function "printk"

so where is the wrong , thanx for helps

/* hello.c */

#define MODULE
#include <linux/module.h>

int init_module(void) {printk("<1>hello\n"); return 0; }

void cleanup_module(void) {printk("<1>goodbye\n");}


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Module Compilation thirumalai Linux - Software 0 08-13-2004 01:20 AM
Apache module compilation problem the-chains Linux - Software 1 07-22-2004 12:20 PM
kernel module compilation zbrox Linux - Software 1 01-28-2004 04:31 PM
NICdriver/module compilation problem pPcG5 Linux - Networking 0 09-11-2003 06:10 AM
module compilation aliyildiz Linux - General 6 03-31-2003 04:11 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:39 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration