diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-04-26 15:35:10 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-04-26 15:35:10 -0300 |
commit | e1526ffa31150849a329a3974cceb151193a1364 (patch) | |
tree | 4eb4a9a74900c76063b0217b65e781b57d885da2 | |
parent | d81f0636d4fdf143055769c57ef3489142c50729 (diff) | |
download | mediapointer-dvb-s2-e1526ffa31150849a329a3974cceb151193a1364.tar.gz mediapointer-dvb-s2-e1526ffa31150849a329a3974cceb151193a1364.tar.bz2 |
Some improvements at Makefile
From: Mauro Carvalho Chehab <mchehab@infradead.org>
Included a INSTALL file
make help shows the INSTALL file
added make release to force compiling against a specified version
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
-rw-r--r-- | INSTALL | 99 | ||||
-rw-r--r-- | linux/drivers/media/video/zc0301/zc0301_core.c | 4 | ||||
-rw-r--r-- | v4l/Makefile | 29 |
3 files changed, 121 insertions, 11 deletions
diff --git a/INSTALL b/INSTALL new file mode 100644 index 000000000..28ea51ef7 --- /dev/null +++ b/INSTALL @@ -0,0 +1,99 @@ +Mauro Carvalho Chehab 2006 Apr 26 + +V4L/DVB building procedures are based at the use of Makefile rules. +Those rules are close tho the ones at Linux Kernel, to allow an easier +usage. + +======================================================================= +Quick building procedure is: + make all +====================================================================== + +For those that may want more than just build all stuff there are some +other interesting parameters to make: + +====================== +Normal building rules: +all - build all modules + +clean - Cleans compiled files from the tree, + but keeping the latest + used configuration and kernel version + +distclean - Cleans compiled files from the tree, + latest used configuration and kernel + version. + +default - Continues building the latest module selection + This is the behavior when just typed: + make + +install - Installs all modules at kernel's default dir + for V4L/DVB. Requires root access. + +======================= +Module selection rules: +(Those may require write access to kernel tree) + +allmodconfig - Called by make all. Selects all modules that are known + to compile against the kernel version used. + +xconfig - Generate a xconfig menu. Requires full + kernel source, since it depends on kernel's + qconf stript; + +gconfig - Generate a qt menu. Requires full + kernel source, since it depends on kernel's + gconf stript; + +config - Generate a text-mode menu. Requires full + kernel source, since it depends on kernel's + conf stript; + +menuconfig - Generate a ncurses menu. Requires full + kernel source, since it depends on kernel's + mconf and lxconfig stripts; + +release - Allows changing kernel version. + Typical usage is: + make release VER=2.6.12-18mdk + (to force compiling to 2.6.12-18mdk) + This will work only if + /lib/modules/2.6.12-18mdk/build/ + points to that kernel version + To use current kernel version instead: + make release + +====================== +Module handling rules: +(require root access) + +insmod - inserts all modules from V4L/DVB tree + +rmmod - removes all modules from V4L/DVB tree + +reload - removes then reinserts all modules + +=================== +Tree merging rules: + +ivtv-checkout - retrieve latest ivtv sources from the site + +ivtv-update - updates from ivtv sources + +ivtv - Prepare ivtv to compile with the tree + +========================================== +Patch preparation and tree handling rules: +(used by developers) + +kernel-links - Generate links to V4L/DVB at kernel tree. + Requires write access to kernel tree. + +cardlist - Updates Documentation/video4linux/CARDLIST.* + +update - updates the tree from master repository + +commit - commits the change, asking for a commit msg + +push - sends outgoing stuff to master repository diff --git a/linux/drivers/media/video/zc0301/zc0301_core.c b/linux/drivers/media/video/zc0301/zc0301_core.c index f20eb61ee..2b5ce2d79 100644 --- a/linux/drivers/media/video/zc0301/zc0301_core.c +++ b/linux/drivers/media/video/zc0301/zc0301_core.c @@ -428,8 +428,8 @@ static int zc0301_start_transfer(struct zc0301_device* cam) { struct usb_device *udev = cam->usbdev; struct usb_host_interface* altsetting = usb_altnum_to_altsetting( - usb_ifnum_to_if(udev, 0), - ZC0301_ALTERNATE_SETTING); + usb_ifnum_to_if(udev, 0), + ZC0301_ALTERNATE_SETTING); const unsigned int psz = altsetting->endpoint[0].desc.wMaxPacketSize; struct urb* urb; s8 i, j; diff --git a/v4l/Makefile b/v4l/Makefile index 3afe20e8b..bf4aa56f2 100644 --- a/v4l/Makefile +++ b/v4l/Makefile @@ -120,12 +120,21 @@ all:: allmodconfig default Makefile.media:: scripts/make_makefile.pl -.version: +.version:: ifneq ($(KERNELRELEASE),) - echo -e VERSION=$(VERSION)\\nPATCHLEVEL:=$(PATCHLEVEL)\\nSUBLEVEL:=$(SUBLEVEL)\\nKERNELRELEASE:=$(KERNELRELEASE) > $(obj)/.version + @echo -e VERSION=$(VERSION)\\nPATCHLEVEL:=$(PATCHLEVEL)\\nSUBLEVEL:=$(SUBLEVEL)\\nKERNELRELEASE:=$(KERNELRELEASE) > $(obj)/.version else - echo "No version yet." - uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version + @echo "No version yet." + @uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version +endif + +release:: +ifneq ($(VER),) + @echo "Forcing compiling to version $(VER)." + @echo $(VER)|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version +else + @echo "No version specified. Using `uname -r`." + @uname -r|perl -ne 'if (/^([0-9]*)\.([0-9])*\.([0-9]*)(.*)$$/) { printf ("VERSION=%s\nPATCHLEVEL:=%s\nSUBLEVEL:=%s\nKERNELRELEASE:=%s.%s.%s%s\n",$$1,$$2,$$3,$$1,$$2,$$3,$$4); };' > $(obj)/.version endif links:: @@ -139,7 +148,7 @@ kernel-links makelinks:: ################################################# # Cardlist updating rule -card cardlist cardlists: +card cardlist cardlists:: scripts/cardlist ################################################# @@ -281,9 +290,6 @@ old-install:: rminstall ################################################# # Tree management rules -change changes changelog:: - make -C .. changelog - update:: make -C .. update @@ -294,6 +300,11 @@ push:: make -C .. push ################################################# +# Help +help:: + @cat ../INSTALL + +################################################# # build tarballs rules RPWD := $(shell cd .. && pwd) @@ -305,7 +316,7 @@ tardest ?= . snapdir := $(HOME)/snapshot snap := $(name) -snapshot snap tarball: update distclean +snapshot snap tarball:: update distclean echo $(thisdir) echo $(name) echo $(date) > .snapshot |