/[gentoo-x86]/sys-kernel/linux-extras/linux-extras-2.4.4-r5.ebuild
Gentoo

Diff of /sys-kernel/linux-extras/linux-extras-2.4.4-r5.ebuild

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.1 Revision 1.2
83then 83then
84 DEPEND=">=sys-kernel/linux-sources-${PVR}" 84 DEPEND=">=sys-kernel/linux-sources-${PVR}"
85 RDEPEND="" 85 RDEPEND=""
86 if [ "`use xfs`" ] 86 if [ "`use xfs`" ]
87 then 87 then
88 DEPEND="${DEPEND} >=sys-devel/autoconf-2.13 >=sys-devel/automake-1.4" 88 DEPEND="${DEPEND} >=sys-devel/autoconf-2.13"
89 fi
90 if [ "`use alsa`" ]
91 then
92 PROVIDE="virtual/alsa"
89 fi 93 fi
90elif [ "${PN}" = "linux" ] 94elif [ "${PN}" = "linux" ]
91then 95then
92 PROVIDE="virtual/kernel" 96 PROVIDE="virtual/kernel"
93 if [ "`use alsa`" ] 97 if [ "`use alsa`" ]
96 fi 100 fi
97 RDEPEND=">=sys-apps/reiserfs-utils-3.6.25-r1" 101 RDEPEND=">=sys-apps/reiserfs-utils-3.6.25-r1"
98 DEPEND=">=sys-apps/modutils-2.4.2 102 DEPEND=">=sys-apps/modutils-2.4.2
99 >=sys-devel/flex-2.5.4a-r3 103 >=sys-devel/flex-2.5.4a-r3
100 >=dev-util/yacc-1.9.1-r1" 104 >=dev-util/yacc-1.9.1-r1"
101else
102 if [ "`use alsa`" ]
103 then
104 PROVIDE="${PROVIDE} virtual/alsa"
105 fi
106fi 105fi
107 106
108HOMEPAGE="http://www.kernel.org/ 107HOMEPAGE="http://www.kernel.org/
109 http://www.netroedge.com/~lm78/ 108 http://www.netroedge.com/~lm78/
110 http://www.namesys.com 109 http://www.namesys.com
214 echo "Preparing for compilation..." 213 echo "Preparing for compilation..."
215 214
216 cd ${S} 215 cd ${S}
217 #sometimes we have icky kernel symbols; this seems to get rid of them 216 #sometimes we have icky kernel symbols; this seems to get rid of them
218 try make mrproper 217 try make mrproper
218
219 #fix silly permissions in tarball
220 cd ${WORKDIR}
221 chown -R 0.0 ${S}
222 chmod -R a+r-w+X,u+w ${S}
223 fi
224}
225
226src_compile() {
227
228 if [ "${PN}" != "linux-sources" ]
229 then
219 if [ "${PN}" = "linux" ] 230 if [ "${PN}" = "linux" ]
220 then 231 then
221 #this is the configuration for the default kernel 232 #this is the configuration for the default kernel
222 try cp ${FILESDIR}/${PVR}/config.bootcomp .config 233 try cp ${FILESDIR}/${PVR}/config.bootcomp .config
223 try yes \"\" \| make oldconfig 234 try yes \"\" \| make oldconfig
224 echo "Ignore any errors from the yes command above." 235 echo "Ignore any errors from the yes command above."
225 try make include/linux/version.h 236 try make include/linux/version.h
226 fi 237 fi
227 #fix silly permissions in tarball 238
228 cd ${WORKDIR}
229 chown -R 0.0 ${S}
230 chmod -R a+r-w+X,u+w ${S}
231 fi
232}
233
234src_compile() {
235
236 if [ "${PN}" != "linux-sources" ]
237 then
238 if [ "$PN" = "linux" ] 239 if [ "$PN" = "linux" ]
239 then 240 then
240 try make symlinks 241 try make symlinks
241 fi 242 fi
242 243
246 cd ${S}/extras/LVM/${LVMV} 247 cd ${S}/extras/LVM/${LVMV}
247 248
248 # This is needed for linux-extras 249 # This is needed for linux-extras
249 if [ -f "Makefile" ] 250 if [ -f "Makefile" ]
250 then 251 then
251 try make clean 252 try make distclean
252 fi 253 fi
253 # I had to hack this in so that LVM will look in the current linux 254 # I had to hack this in so that LVM will look in the current linux
254 # source directory instead of /usr/src/linux for stuff - pete 255 # source directory instead of /usr/src/linux for stuff - pete
255 try CFLAGS=\""${CFLAGS} -I${S}/include"\" ./configure --prefix=/ --mandir=/usr/share/man --with-kernel_dir="${S}" 256 try CFLAGS=\""${CFLAGS} -I${S}/include"\" ./configure --prefix=/ --mandir=/usr/share/man --with-kernel_dir="${S}"
256 257
266 -e \'"s#^DESTDIR.*#DESTDIR := ${D}#"\' \ 267 -e \'"s#^DESTDIR.*#DESTDIR := ${D}#"\' \
267 -e \''s#^PREFIX.*#PREFIX := /usr#'\' \ 268 -e \''s#^PREFIX.*#PREFIX := /usr#'\' \
268 -e \''s#^MANDIR.*#MANDIR := /usr/share/man#'\' \ 269 -e \''s#^MANDIR.*#MANDIR := /usr/share/man#'\' \
269 Makefile.orig > Makefile 270 Makefile.orig > Makefile
270 271
272 try make clean
273
271 try make 274 try make
272 fi 275 fi
273 276
274 if [ "`use xfs`" ] 277 if [ "`use xfs`" ]
275 then 278 then
276 cd ${S}/extras/xfs-${XFSV}/acl 279 cd ${S}/extras/xfs-${XFSV}/acl
280 try make distclean
277 try make \ 281 try make \
278 CPPFLAGS=\""-I${S}/include"\" \ 282 CPPFLAGS=\""-I${S}/include"\" \
279 configure 283 configure
280 try make \ 284 try make \
281 PKG_SBIN_DIR=/sbin \ 285 PKG_SBIN_DIR=/sbin \
285 CC=\""gcc -I${S}/include"\" \ 289 CC=\""gcc -I${S}/include"\" \
286 OPTIMIZER=\""${CFLAGS}"\" \ 290 OPTIMIZER=\""${CFLAGS}"\" \
287 DEBUG=\"\" 291 DEBUG=\"\"
288 292
289 cd ${S}/extras/xfs-${XFSV}/attr 293 cd ${S}/extras/xfs-${XFSV}/attr
294 try make distclean
290 try make \ 295 try make \
291 CPPFLAGS=\""-I${S}/include"\" \ 296 CPPFLAGS=\""-I${S}/include"\" \
292 configure 297 configure
293 try make \ 298 try make \
294 PKG_SBIN_DIR=/bin \ 299 PKG_SBIN_DIR=/bin \
298 CC=\""gcc -I${S}/include"\" \ 303 CC=\""gcc -I${S}/include"\" \
299 OPTIMIZER=\""${CFLAGS}"\" \ 304 OPTIMIZER=\""${CFLAGS}"\" \
300 DEBUG=\"\" 305 DEBUG=\"\"
301 306
302 cd ${S}/extras/xfs-${XFSV}/xfsprogs 307 cd ${S}/extras/xfs-${XFSV}/xfsprogs
308 try make distclean
303 try make \ 309 try make \
304 CPPFLAGS=\""-I${S}/include"\" \ 310 CPPFLAGS=\""-I${S}/include"\" \
305 configure 311 configure
306 try make \ 312 try make \
307 PKG_SBIN_DIR=/sbin \ 313 PKG_SBIN_DIR=/sbin \
314 DEBUG=\"\" 320 DEBUG=\"\"
315 321
316 # dmapi and xfsdump must be built last, cuz they depend on libattr (in attr) and libxfs (in xfsprogs) 322 # dmapi and xfsdump must be built last, cuz they depend on libattr (in attr) and libxfs (in xfsprogs)
317 cd ${S}/extras/xfs-${XFSV}/dmapi 323 cd ${S}/extras/xfs-${XFSV}/dmapi
318 ln -sf ../../xfsprogs/include include/xfs 324 ln -sf ../../xfsprogs/include include/xfs
325 try make distclean
319 try make \ 326 try make \
320 CPPFLAGS=\""-I${S}/include -I${S}/extras/xfs-${XFSV}/dmapi/include"\" \ 327 CPPFLAGS=\""-I${S}/include -I${S}/extras/xfs-${XFSV}/dmapi/include"\" \
321 configure 328 configure
322 try make \ 329 try make \
323 PKG_INC_DIR=/usr/include/dmapi \ 330 PKG_INC_DIR=/usr/include/dmapi \
328 DEBUG=\"\" 335 DEBUG=\"\"
329 336
330 cd ${S}/extras/xfs-${XFSV}/xfsdump 337 cd ${S}/extras/xfs-${XFSV}/xfsdump
331 ln -sf ../../xfsprogs/include include/xfs 338 ln -sf ../../xfsprogs/include include/xfs
332 ln -sf ../../attr/include include/attr 339 ln -sf ../../attr/include include/attr
340 try make distclean
333 try make \ 341 try make \
334 CPPFLAGS=\""-I${S}/include -I${S}/extras/xfs-${XFSV}/xfsdump/include -I${S}/extras/xfs-${XFSV}/xfsprogs/include -I${S}/extras/xfs-${XFSV}/attr/include"\" \ 342 CPPFLAGS=\""-I${S}/include -I${S}/extras/xfs-${XFSV}/xfsdump/include -I${S}/extras/xfs-${XFSV}/xfsprogs/include -I${S}/extras/xfs-${XFSV}/attr/include"\" \
335 LDFLAGS=\""-L${S}/extras/xfs-${XFSV}/attr/libattr -L${S}/extras/xfs-${XFSV}/xfsprogs/libxfs -L${S}/extras/xfs-${XFSV}/xfsprogs/libhandle -lhandle"\" \ 343 LDFLAGS=\""-L${S}/extras/xfs-${XFSV}/attr/libattr -L${S}/extras/xfs-${XFSV}/xfsprogs/libxfs -L${S}/extras/xfs-${XFSV}/xfsprogs/libhandle -lhandle"\" \
336 configure 344 configure
337 try make \ 345 try make \
354 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" dep 362 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" dep
355 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" LEX=\""flex -l"\" bzImage 363 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" LEX=\""flex -l"\" bzImage
356 #LEX=\""flex -l"\" bzImage 364 #LEX=\""flex -l"\" bzImage
357 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" LEX=\""flex -l"\" modules 365 try make HOSTCFLAGS=\""${LINUX_HOSTCFLAGS}"\" LEX=\""flex -l"\" modules
358 #LEX=\""flex -l"\" modules 366 #LEX=\""flex -l"\" modules
367
359 fi 368 fi
360
361 # This must come after the kernel compilation in linux 369 # This must come after the kernel compilation in linux
362 if [ "`use alsa`" ] 370 if [ "`use alsa`" ]
363 then 371 then
364 cd ${S}/extras/alsa-driver-${AV} 372 cd ${S}/extras/alsa-driver-${AV}
365 # This is needed for linux-extras 373 # This is needed for linux-extras
366 if [ -f "Makefile.conf" ] 374 if [ -f "Makefile.conf" ]
367 then 375 then
368 try make clean 376 try make distclean
369 fi 377 fi
370 try ./configure --with-kernel=\"${S}\" --with-isapnp=yes --with-sequencer=yes --with-oss=yes --with-cards=all 378 try ./configure --with-kernel=\"${S}\" --with-isapnp=yes --with-sequencer=yes --with-oss=yes --with-cards=all
371 try make 379 try make
372 fi 380 fi
373 if [ "`use pcmcia-cs`" ] 381 if [ "`use pcmcia-cs`" ]
407 415
408 try CFLAGS=\""${CFLAGS} -I${S}/include"\" make install -e prefix=${D} mandir=${D}/usr/share/man \ 416 try CFLAGS=\""${CFLAGS} -I${S}/include"\" make install -e prefix=${D} mandir=${D}/usr/share/man \
409 sbindir=${D}/sbin libdir=${D}/lib 417 sbindir=${D}/sbin libdir=${D}/lib
410 #no need for a static library in /lib 418 #no need for a static library in /lib
411 mv ${D}/lib/*.a ${D}/usr/lib 419 mv ${D}/lib/*.a ${D}/usr/lib
420
421 docinto LVM-${LVMV}
422 dodoc ABSTRACT CHANGELOG CONTRIBUTORS COPYING COPYING.LIB FAQ KNOWN_BUGS LVM-HOWTO
423 dodoc README TODO WHATSNEW
412 fi 424 fi
413 425
414 if [ "`use lm_sensors`" ] 426 if [ "`use lm_sensors`" ]
415 then 427 then
416 echo "Install sensor tools..." 428 echo "Install sensor tools..."
417 #install sensors tools 429 #install sensors tools
418 cd ${S}/extras/lm_sensors-${SENV} 430 cd ${S}/extras/lm_sensors-${SENV}
419 make install 431 make install
432 docinto lm_sensors-${SENV}
433 dodoc BACKGROUND BUGS CHANGES CONTRIBUTORS COPYING INSTALL QUICKSTART README
420 fi 434 fi
421 435
422 if [ "`use xfs`" ] 436 if [ "`use xfs`" ]
423 then 437 then
424 cd ${S}/extras/xfs-${XFSV}/acl 438 cd ${S}/extras/xfs-${XFSV}/acl
475 PKG_BIN_DIR=${D}/usr/sbin \ 489 PKG_BIN_DIR=${D}/usr/sbin \
476 PKG_LIB_DIR=${D}/usr/lib \ 490 PKG_LIB_DIR=${D}/usr/lib \
477 PKG_MAN_DIR=${D}/usr/share/man \ 491 PKG_MAN_DIR=${D}/usr/share/man \
478 install install-dev 492 install install-dev
479 rm -rf ${D}/usr/share/doc/xfsprogs 493 rm -rf ${D}/usr/share/doc/xfsprogs
480 docinto xfs-${XFSV}/xfsprogs 494 docinto xfs-${XFSV}/xfsdump
481 dodoc README doc/CHANGES doc/COPYING doc/PORTING doc/README.xfsdump 495 dodoc README doc/CHANGES doc/COPYING doc/PORTING doc/README.xfsdump
482 fi 496 fi
483 497
484 if [ "${PN}" = "linux" ] 498 if [ "${PN}" = "linux" ]
485 then 499 then
513 ln -sf /usr/src/linux-${KV} build 527 ln -sf /usr/src/linux-${KV} build
514 fi 528 fi
515 529
516 if [ "`use alsa`" ] 530 if [ "`use alsa`" ]
517 then 531 then
518 #install ALSA modules
519 cd ${S}/extras/alsa-driver-${AV} 532 cd ${S}/extras/alsa-driver-${AV}
520 dodoc INSTALL FAQ 533 docinto alsa-${AV}
521 dodir /lib/modules/${KV}/misc 534 dodoc COPYING INSTALL FAQ README WARNING
535 docinto alsa-${AV}/doc
536 dodoc doc/README.1st doc/SOUNDCARDS
522 cp modules/*.o ${D}/lib/modules/${KV}/misc 537 cp modules/*.o ${D}/lib/modules/${KV}/misc
523 fi 538 fi
524 if [ "`use pcmcia-cs`" ] 539 if [ "`use pcmcia-cs`" ]
525 then 540 then
526 #install PCMCIA modules and utilities 541 #install PCMCIA modules and utilities
527 cd ${S}/extras/pcmcia-cs-${PCV} 542 cd ${S}/extras/pcmcia-cs-${PCV}
528 try make PREFIX=${D} install 543 try make PREFIX=${D} install
529 rm -rf ${D}/etc/rc.d 544 rm -rf ${D}/etc/rc.d
530 exeinto /etc/rc.d/init.d 545 exeinto /etc/rc.d/init.d
531 doexe ${FILESDIR}/${PVR}/pcmcia 546 doexe ${FILESDIR}/${PVR}/pcmcia
532 fi 547 docinto pcmcia-cs-${PCV}
533 548 dodoc BUGS CHANGES COPYING LICENSE MAINTAINERS README README-2.4 SUPPORTED.CARDS
549 cd doc ; docinto pcmcia-cs-${PCV}/doc
550 dodoc PCMCIA-HOWTO PCMCIA-HOWTO.ps PCMCIA-PROG PCMCIA-PROG.ps
551 fi
534 else 552 else
535 dodir /usr/src 553 dodir /usr/src
536 554
537 cd ${S} 555 cd ${S}
538 make mrproper 556 make mrproper
539 557
558 if [ "`use lvm`" ]
559 then
560 cd ${S}/extras/LVM/${LVMV}
561 if [ -f Makefile ]
562 then
563 make distclean
564 fi
565 fi
566 if [ "`use lm_sensors`" ]
567 then
568 cd ${S}/extras/lm_sensors-${SENV}
569 make clean
570 fi
571
572 rm -f ${S}/lm_sensors-patch
573
540 echo ">>> Copying sources..." 574 echo ">>> Copying sources..."
541 cp -ax ${S} ${D}/usr/src 575 cp -ax ${S} ${D}/usr/src
542 576
543 #don't overwrite existing .config if present 577 #don't overwrite existing .config if present
544 cd ${D}/usr/src/linux-${KV} 578 cd ${D}/usr/src/linux-${KV}

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.20