Makefile 35 KB
Newer Older
1 2 3
# ***************************************************************************
# src/Makefile : Dearchive and compile all files necessary
# ***************************************************************************
4
# Copyright (C) 2003, 2004, 2005 VideoLAN
5
# $Id$
6 7
#
# Authors: Christophe Massiot <massiot@via.ecp.fr>
8
#          Derk-Jan Hartman <hartman at videolan dot org>
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
# ***************************************************************************

include ../config.mak
include ./packages.mak

# ***************************************************************************
# Set a clean environment
# ***************************************************************************

32
ifeq ($(HOST),ppc-darwin)
33 34 35 36 37 38
HAVE_DARWIN_OS=1
endif
ifeq ($(HOST),powerpc-apple-darwin8)
HAVE_DARWIN_OS=1
endif

hartman's avatar
hartman committed
39
ifdef HAVE_DARWIN_OS
40 41
export PATH = $(PREFIX)/bin:/bin:/usr/bin
export DYLD_LIBRARY_PATH = $(PREFIX)/lib
42
endif
43 44 45 46

ifeq ($(HOST),i586-pc-beos)
ifeq ($(HOST),$(BUILD))
# Compiling on BeOS
47 48
export PATH = $(PREFIX)/bin:.:/boot/home/config/bin:/bin:/boot/apps:/boot/preferences:/boot/beos/apps:/boot/beos/preferences:/boot/develop/tools/gnupro/bin
export LIBRARY_PATH = $(PREFIX)/lib:%A/lib:/boot/home/config/lib:/boot/beos/system/lib
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
else
# Cross compiling from Linux
export PATH = $(PREFIX)/bin:/opt/cross-tools/bin:/usr/bin:/bin
endif
endif

export CPPFLAGS = -I$(PREFIX)/include $(EXTRA_CPPFLAGS)
export CFLAGS = -I$(PREFIX)/include $(EXTRA_CPPFLAGS)
export CXXFLAGS = -I$(PREFIX)/include $(EXTRA_CPPFLAGS)
export LDFLAGS = -L$(PREFIX)/lib $(EXTRA_LDFLAGS)

# ***************************************************************************
# Cross compilation variables
# We'll usually use --host=<platform>, except for a few libraries which
# don't handle it (gotta set CC/CXX/etc), and obviously FFmpeg has its own
# way of doing it... ;)
# ***************************************************************************

ifneq ($(BUILD),$(HOST))
# We are cross compiling
HOSTCONF=--host=$(HOST)
HOSTCC=CC=$(HOST)-gcc CXX=$(HOST)-g++ AR=$(HOST)-ar RANLIB=$(HOST)-ranlib
# For libebml/libmatroska. Grrr.
HOSTCC2=CC=$(HOST)-gcc CXX=$(HOST)-g++ "AR=$(HOST)-ar rcvu" RANLIB=$(HOST)-ranlib
FFMPEGCONF=--cross-prefix=$(HOST)-
RANLIB=$(HOST)-ranlib
else
# Building natively
RANLIB=ranlib
78
endif
79 80 81 82 83

# ***************************************************************************
# Standard rules
# ***************************************************************************

84
ifdef HAVE_DARWIN_OS
85
 all: .autoconf .libtool .automake .iconv .intl .pkgcfg .freetype .fribidi \
86
	.a52 .mpeg2 .id3tag .mad .ogg .vorbis .vorbisenc .theora \
87
	.FLAC .speex .faad .faac .lame .ebml .matroska .ffmpeg .openslp \
hartman's avatar
hartman committed
88
	.dvdcss .dvdread .dvdnav .dvbpsi .live .goom2k4 .caca .mod \
hartman's avatar
hartman committed
89
	.png .gpgerror .gcrypt .gnutls .daap .cddb .cdio .vcdimager .aclocal
90
# mozilla support? add before .aclocal:  .glib .libidl .mozilla
91
else
92

93 94
 ifeq ($(HOST),i586-pc-beos)
  ifeq ($(HOST),$(BUILD))
95
# Native build: we need perl, autoconf, etc first
96
   all: .perl .autoconf .libtool .automake .iconv .intl .freetype .fribidi \
Eric Petit's avatar
Eric Petit committed
97
	.a52 .mpeg2 .id3tag .mad .ogg .vorbis .vorbisenc .theora \
Eric Petit's avatar
Eric Petit committed
98
	.FLAC .speex .faad .faac .lame .ebml .matroska .ffmpeg .dvdcss \
hartman's avatar
hartman committed
99
	.dvdread .dvdnav .dvbpsi .aclocal
100
  else
101 102
# Cross compiling: we already have the Linux tools, only build the
# libraries now
103
   all: .iconv .intl .freetype .fribidi \
104 105 106
	.a52 .mpeg2 .id3tag .mad .ogg .vorbis .vorbisenc .theora \
	.FLAC .speex .faad .faac .lame .ebml .matroska .ffmpeg .dvdcss \
	.dvdread .dvdnav .dvbpsi .aclocal
107 108 109 110 111 112 113 114
  endif
 else
# Standard Linux or other UNIX-like systems
   all: .iconv .intl .freetype .fribidi \
	.a52 .mpeg2 .id3tag .mad .ogg .vorbis .vorbisenc .theora \
	.FLAC .speex .faad .faac .lame .ebml .matroska .ffmpeg .dvdcss \
	.dvdread .dvdnav .dvbpsi .aclocal
 endif
115 116
endif

117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146
FORCE:

# ***************************************************************************
# Useful macros
# ***************************************************************************

define EXTRACT_GZ
	tar xzf $<
	mv $(patsubst %.tar.gz,%,$(patsubst %.tgz,%,$(notdir $<))) $@ || true
	touch $@
endef

define EXTRACT_BZ2
	bunzip2 -c $< | tar xf -
	mv $(patsubst %.tar.bz2,%,$(notdir $<)) $@ || true
	touch $@
endef

### Darwin-specific ###
# These macros prepare the dynamic libraries for inclusion in the Mac OS X
# bundle. For instance if you're building a library named libtoto.dylib,
# which depends on the contrib library libtata.dylib, you should have the
# following entry :
# .toto: toto_directory .tata
#	cd $< ; ./configure --prefix=$(PREFIX)
#	$(MAKE) -C $<
#	$(MAKE) -C $< install
#	$(INSTALL_NAME)
#	touch $@

147
ifdef HAVE_DARWIN_OS
148 149 150
define INSTALL_NAME_LIB
	install_name_tool \
		-change $(PREFIX)/lib/$(shell cd $(PREFIX)/lib; ls | grep "lib$(INSTALL_LIB).[0-9]*.dylib") \
151
		@executable_path/lib/vlc_lib$(INSTALL_LIB).dylib \
152 153 154 155 156 157 158 159 160
		$(PREFIX)/vlc-lib/lib$(patsubst .%,%,$@).dylib ;
endef

define INSTALL_NAME
	if which install_name_tool >/dev/null; then \
		mkdir -p $(PREFIX)/vlc-lib ; \
		cp $(PREFIX)/lib/lib$(patsubst .%,%,$@).dylib \
			$(PREFIX)/vlc-lib/lib$(patsubst .%,%,$@).dylib ; \
		install_name_tool \
161
			-id @executable_path/lib/vlc_lib$(patsubst .%,%,$@).dylib \
162 163 164 165 166
			$(PREFIX)/vlc-lib/lib$(patsubst .%,%,$@).dylib ; \
		$(foreach INSTALL_LIB,$(patsubst .%,%,$(filter .%,$^)), \
			$(INSTALL_NAME_LIB)) \
	fi
endef
167 168
endif

169
ifeq ($(HOST),i586-pc-beos)
Eric Petit's avatar
Eric Petit committed
170 171
# We test if the file actually exists, as sometimes (but not always)
# libtool won't accept to build the shared library
172
define INSTALL_NAME
Eric Petit's avatar
Eric Petit committed
173 174 175 176 177
	if test -f $(PREFIX)/lib/lib$(patsubst .%,%,$@).so ; then \
		mkdir -p $(PREFIX)/vlc-lib ; \
		cp $(PREFIX)/lib/lib$(patsubst .%,%,$@).so \
		  $(PREFIX)/vlc-lib/ ; \
	fi
178 179 180 181 182 183 184
endef
endif

# ***************************************************************************
# perl
# ***************************************************************************

185
ifeq ($(BUILD),i586-pc-beos)
186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201
perl-$(PERL_VERSION).tar.gz:
	$(WGET) $(PERL_URL)

perl: perl-$(PERL_VERSION).tar.gz
	$(EXTRACT_GZ)
	mv perl/hints/beos.sh perl/hints/beos.sh.orig
	sed 's%prefix="/boot/home/config"%prefix="$(PREFIX)"%' < perl/hints/beos.sh.orig > perl/hints/beos.sh

.perl: perl
	(cd $<; ./Configure -d -e && make && make install && ln -sf perl5/$(PERL_VERSION)/BePC-beos/CORE/libperl.so $(PREFIX)/lib/libperl.so)
	touch $@

CLEAN_FILE += .perl
CLEAN_PKG += perl
DISTCLEAN_PKG += perl-$(PERL_VERSION).tar.gz
endif
202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224

# ***************************************************************************
# autoconf
# ***************************************************************************

autoconf-$(AUTOCONF_VERSION).tar.gz:
	$(WGET) $(AUTOCONF_URL)

autoconf: autoconf-$(AUTOCONF_VERSION).tar.gz
	$(EXTRACT_GZ)

.autoconf: autoconf
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install)
	touch $@

CLEAN_FILE += .autoconf
CLEAN_PKG += autoconf
DISTCLEAN_PKG += autoconf-$(AUTOCONF_VERSION).tar.gz

# ***************************************************************************
# libtool
# ***************************************************************************

225
ifdef HAVE_DARWIN_OS
226 227 228 229 230
.libtool:
	if test -x /usr/bin/glibtoolize; then \
		ln -sf /usr/bin/glibtoolize $(PREFIX)/bin/libtoolize ; \
	fi
	touch $@
231 232
endif

233
ifeq ($(BUILD),i586-pc-beos)
234 235 236 237 238 239 240 241 242 243 244 245 246
libtool-$(LIBTOOL_VERSION).tar.gz:
	$(WGET) $(LIBTOOL_URL)

libtool: libtool-$(LIBTOOL_VERSION).tar.gz
	$(EXTRACT_GZ)

.libtool: libtool
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install)
	touch $@

CLEAN_PKG += libtool
DISTCLEAN_PKG += libtool-$(LIBTOOL_VERSION).tar.gz
endif
247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267

CLEAN_FILE += .libtool

# ***************************************************************************
# automake
# ***************************************************************************

automake-$(AUTOMAKE_VERSION).tar.gz:
	$(WGET) $(AUTOMAKE_URL)

automake: automake-$(AUTOMAKE_VERSION).tar.gz
	$(EXTRACT_GZ)

.automake: automake
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install)
	touch $@

CLEAN_FILE += .automake
CLEAN_PKG += automake
DISTCLEAN_PKG += automake-$(AUTOMAKE_VERSION).tar.gz

268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284
# ***************************************************************************
# pkgconfig
# ***************************************************************************

pkgconfig-$(PKGCFG_VERSION).tar.gz:
	$(WGET) $(PKGCFG_URL)

pkgconfig: pkgconfig-$(PKGCFG_VERSION).tar.gz
	$(EXTRACT_GZ)

.pkgcfg: pkgconfig
	(cd pkgconfig; ./configure --prefix=$(PREFIX) --disable-shared --enable-static && make && make install)
	touch $@

CLEAN_FILE += .pkgcfg
CLEAN_PKG += pkgconfig
DISTCLEAN_PKG += pkgconfig-$(PKGCFG_VERSION).tar.gz
285

286 287 288 289 290 291 292 293 294
# ***************************************************************************
# gettext
# ***************************************************************************

gettext-$(GETTEXT_VERSION).tar.gz:
	$(WGET) $(GETTEXT_URL)

gettext: gettext-$(GETTEXT_VERSION).tar.gz
	$(EXTRACT_GZ)
295
	patch -p 0 < Patches/gettext.patch
296

297
.intl: gettext
298 299
	( cd $< && ./configure $(HOSTCONF) --prefix=$(PREFIX) )
ifeq ($(BUILD),i586-pc-beos)
300 301 302 303
# The ugliest kludge ever - so libtool correctly links shared libraries
# on BeOS. Sorry, I just can't figure out how libtool works
	( cd $< && for f in `find . -name libtool`; do mv $$f $$f.orig; sed -e 's/ -shared / -nostart /' -e 's/^predep_objects.*/predep_objects=""/' < $$f.orig > $$f; chmod +x $$f; rm $$f.orig; done )
endif
304 305 306 307 308
ifneq ($(HOST),$(BUILD))
# We'll use the installed gettext and only need to cross-compile libintl
	( cd $< && make -C gettext-runtime/intl && make -C gettext-runtime/intl install )
else
# Build and install the whole gettext
309
	( cd $< && make && make install )
310
endif
311 312 313 314 315 316 317
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .intl
CLEAN_PKG += gettext
DISTCLEAN_PKG += gettext-$(GETTEXT_VERSION).tar.gz

318 319 320 321 322 323 324 325 326 327 328
# ***************************************************************************
# libiconv
# ***************************************************************************

libiconv-$(LIBICONV_VERSION).tar.gz:
	$(WGET) $(LIBICONV_URL)

libiconv: libiconv-$(LIBICONV_VERSION).tar.gz
	$(EXTRACT_GZ)

.iconv: libiconv
329
	(cd libiconv; ./configure $(HOSTCONF) --prefix=$(PREFIX) --disable-nls && make && make install)
330 331 332 333 334 335 336
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .iconv
CLEAN_PKG += libiconv
DISTCLEAN_PKG += libiconv-$(LIBICONV_VERSION).tar.gz

337 338 339 340 341 342 343 344 345 346 347
# ***************************************************************************
# freetype2
# ***************************************************************************

freetype-$(FREETYPE2_VERSION).tar.gz:
	$(WGET) $(FREETYPE2_URL)

freetype2: freetype-$(FREETYPE2_VERSION).tar.gz
	$(EXTRACT_GZ)

.freetype: freetype2
348
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .freetype
CLEAN_PKG += freetype2
DISTCLEAN_PKG += freetype-$(FREETYPE2_VERSION).tar.gz

# ***************************************************************************
# fribidi
# ***************************************************************************

fribidi-$(FRIBIDI_VERSION).tar.gz:
	$(WGET) $(FRIBIDI_URL)

fribidi: fribidi-$(FRIBIDI_VERSION).tar.gz
	$(EXTRACT_GZ)
365
	patch -p 0 < Patches/fribidi.patch.real
366 367

.fribidi: fribidi
368
	(cd $<; ./bootstrap && ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .fribidi
CLEAN_PKG += fribidi
DISTCLEAN_PKG += fribidi-$(FRIBIDI_VERSION).tar.gz

# ***************************************************************************
# liba52
# ***************************************************************************

a52dec-$(A52DEC_VERSION).tar.gz:
	$(WGET) $(A52DEC_URL)

a52dec: a52dec-$(A52DEC_VERSION).tar.gz
	$(EXTRACT_GZ)

.a52: a52dec
387
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403
	touch $@

CLEAN_FILE += .a52
CLEAN_PKG += a52dec
DISTCLEAN_PKG += a52dec-$(A52DEC_VERSION).tar.gz

# ***************************************************************************
# mpeg2dec
# ***************************************************************************

#mpeg2dec:
#	@echo "*** Please press return here : ***"
#	cvs -d $(MPEG2DEC_CVSROOT) login
#	cvs -d $(MPEG2DEC_CVSROOT) co mpeg2dec
#	(cd $@; ./bootstrap)

404 405 406
#mpeg2dec-$(MPEG2DEC_VERSION).tar.gz:
#	$(WGET) $(MPEG2DEC_URL)

407
# It is easier to use bootstrapped versions...
hartman's avatar
hartman committed
408
mpeg2dec-$(MPEG2DEC_VERSION).tar.gz:
409 410 411
	$(WGET) $(MPEG2DEC_SNAPSHOT)
	mv mpeg2dec-snapshot.tar.gz $@

hartman's avatar
hartman committed
412
mpeg2dec: mpeg2dec-$(MPEG2DEC_VERSION).tar.gz
413
	$(EXTRACT_GZ)
hartman's avatar
hartman committed
414
	patch -p 0 < Patches/mpeg2dec.patch
415 416

.mpeg2: mpeg2dec
hartman's avatar
hartman committed
417
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) --without-x --disable-sdl && make && make install)
418 419 420 421
	touch $@

CLEAN_FILE += .mpeg2
CLEAN_PKG += mpeg2dec
422
#DISTCLEAN_PKG += mpeg2dec-$(MPEG2DEC_VERSION)-cvs.tar.gz
Eric Petit's avatar
Eric Petit committed
423
DISTCLEAN_PKG += mpeg2dec-$(MPEG2DEC_VERSION).tar.gz
424 425 426 427 428 429 430 431 432 433 434 435

# ***************************************************************************
# libid3tag
# ***************************************************************************

libid3tag-$(LIBID3TAG_VERSION).tar.gz:
	$(WGET) $(LIBID3TAG_URL)

libid3tag: libid3tag-$(LIBID3TAG_VERSION).tar.gz
	$(EXTRACT_GZ)

.id3tag: libid3tag
436
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
437 438 439 440 441 442 443 444 445 446 447
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .id3tag
CLEAN_PKG += libid3tag
DISTCLEAN_PKG += libid3tag-$(LIBID3TAG_VERSION).tar.gz

# ***************************************************************************
# libmad
# ***************************************************************************

448
libmad-$(LIBMAD_VERSION).tar.gz:
449 450
	$(WGET) $(LIBMAD_URL)

451
libmad: libmad-$(LIBMAD_VERSION).tar.gz
452 453
	$(EXTRACT_GZ)

454
.mad: libmad
455
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) CFLAGS="-O3" && make && make install)
Christophe Massiot's avatar
Christophe Massiot committed
456
	$(INSTALL_NAME)
457 458 459
	touch $@

CLEAN_FILE += .mad
460 461
CLEAN_PKG += libmad
DISTCLEAN_PKG += libmad-$(LIBMAD_VERSION).tar.gz
462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479

# ***************************************************************************
# ogg
# ***************************************************************************

#ogg:
#	@echo "*** Please type \"anoncvs\" here : ***"
#	cvs -d $(OGG_CVSROOT) login
#	cvs -d $(OGG_CVSROOT) co ogg
#	(cd $@; ./autogen.sh)

libogg-$(OGG_VERSION).tar.gz:
	$(WGET) $(OGG_URL)

libogg: libogg-$(OGG_VERSION).tar.gz
	$(EXTRACT_GZ)

.ogg: libogg
480
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .ogg
CLEAN_PKG += libogg
DISTCLEAN_PKG += libogg-$(OGG_VERSION).tar.gz

# ***************************************************************************
# vorbis
# ***************************************************************************

#vorbis:
#	@echo "*** Please type \"anoncvs\" here : ***"
#	cvs -d $(OGG_CVSROOT) login
#	cvs -d $(OGG_CVSROOT) co vorbis
#	(cd $@; ./autogen.sh)
#	patch -p 0 < Patches/vorbis.patch

libvorbis-$(VORBIS_VERSION).tar.gz:
	$(WGET) $(VORBIS_URL)

libvorbis: libvorbis-$(VORBIS_VERSION).tar.gz
	$(EXTRACT_GZ)

.vorbis: libvorbis .ogg
506 507 508 509 510 511
# libvorbis' configure doesn't handle --host
# FIXME: shared libs disabled for now because configure thinks we should
# link the .so to -lc when cross-compiling to BeOS (-> fails)
#   -- titer 2005/02/12
	(cd $<; $(HOSTCC) ./configure --prefix=$(PREFIX) --disable-shared && make && make install)
#	$(INSTALL_NAME)
512 513 514
	touch $@

.vorbisenc: .vorbis .ogg
515
#	$(INSTALL_NAME)
516 517 518 519 520 521 522 523 524 525
	touch $@

CLEAN_FILE += .vorbis .vorbisenc
CLEAN_PKG += libvorbis
DISTCLEAN_PKG += libvorbis-$(VORBIS_VERSION).tar.gz

# ***************************************************************************
# theora
# ***************************************************************************

hartman's avatar
hartman committed
526
libtheora-$(THEORA_VERSION).tar.bz2:
527 528
	$(WGET) $(THEORA_URL)

hartman's avatar
hartman committed
529 530
libtheora: libtheora-$(THEORA_VERSION).tar.bz2
	$(EXTRACT_BZ2)
531 532 533
	patch -p 0 < Patches/theora.patch

.theora: libtheora
534
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
hartman's avatar
hartman committed
535
	$(INSTALL_NAME)
536 537 538 539
	touch $@

CLEAN_FILE += .theora
CLEAN_PKG += libtheora
hartman's avatar
hartman committed
540
DISTCLEAN_PKG += libtheora-$(THEORA_VERSION).tar.bz2
541 542 543 544 545 546 547 548 549 550 551 552

# ***************************************************************************
# flac
# ***************************************************************************

flac-$(FLAC_VERSION).tar.gz:
	$(WGET) $(FLAC_URL)

flac: flac-$(FLAC_VERSION).tar.gz
	$(EXTRACT_GZ)

.FLAC: flac
553
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .flac
CLEAN_PKG += flac
DISTCLEAN_PKG += flac-$(FLAC_VERSION).tar.gz

# ***************************************************************************
# speex
# ***************************************************************************

speex-$(SPEEX_VERSION).tar.gz:
	$(WGET) $(SPEEX_URL)

speex: speex-$(SPEEX_VERSION).tar.gz
	$(EXTRACT_GZ)
Eric Petit's avatar
Eric Petit committed
570
	patch -p 0 < Patches/speex.patch
571 572

.speex: speex
573
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) --enable-ogg=no && make && make install)
574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .speex
CLEAN_PKG += speex
DISTCLEAN_PKG += speex-$(SPEEX_VERSION).tar.gz

# ***************************************************************************
# faad2
# ***************************************************************************

#faad2:
#	@echo "*** Please type return here : ***"
#	cvs -d $(FAAD2_CVSROOT) login
#	cvs -d $(FAAD2_CVSROOT) co faad2
#	(cd $@; patch -p 0 < ../Patches/faad2.patch)
#	(cd $@; sh ./bootstrap)

592
faad2-$(FAAD2_VERSION).tar.bz2:
593 594
	$(WGET) $(FAAD2_URL)

595 596
faad2: faad2-$(FAAD2_VERSION).tar.bz2
	$(EXTRACT_BZ2)
597 598

.faad: faad2
599
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) CFLAGS="-O3" && make -C libfaad && make -C libfaad install)
600 601 602 603 604
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .faad
CLEAN_PKG += faad2
Eric Petit's avatar
Eric Petit committed
605
DISTCLEAN_PKG += faad2-$(FAAD2_VERSION).tar.bz2
606

607 608 609 610 611 612 613 614 615
# ***************************************************************************
# faac
# ***************************************************************************

faac-$(FAAC_VERSION).tar.bz2:
	$(WGET) $(FAAC_URL)

faac: faac-$(FAAC_VERSION).tar.bz2
	$(EXTRACT_BZ2)
hartman's avatar
hartman committed
616
	patch -p 0 < Patches/faac.patch
617 618

.faac: faac
619
	(cd $<; rm -f install-sh mkinstalldirs missing && ./bootstrap && ./configure $(HOSTCONF) --prefix=$(PREFIX) --disable-shared && make && make install)
620 621 622 623 624 625
	touch $@

CLEAN_FILE += .faac
CLEAN_PKG += faac
DISTCLEAN_PKG += faac-$(FAAC_VERSION).tar.bz2

626 627 628 629 630 631 632 633 634 635 636
# ***************************************************************************
# lame
# ***************************************************************************

lame-$(LAME_VERSION).tar.gz:
	$(WGET) $(LAME_URL)

lame: lame-$(LAME_VERSION).tar.gz
	$(EXTRACT_GZ)

.lame: lame
637
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) --disable-shared && make && make install)
638 639 640 641 642 643 644 645 646 647
	touch $@

CLEAN_FILE += .lame
CLEAN_PKG += lame
DISTCLEAN_PKG += lame-$(LAME_VERSION).tar.gz

# ***************************************************************************
# libebml
# ***************************************************************************

648 649
libebml:
	svn co http://svn.matroska.org/svn/matroska/trunk/libebml libebml
650 651

.ebml: libebml
652
	(cd $<; make -C make/linux prefix=$(PREFIX) $(HOSTCC2) staticlib && make -C make/linux install_staticlib install_headers prefix=$(PREFIX))
653
	$(RANLIB) $(PREFIX)/lib/libebml.a
654 655 656 657
	touch $@

CLEAN_FILE += .ebml
CLEAN_PKG += libebml
658
DISTCLEAN_PKG += libebml-$(LIBEBML_VERSION).tar.bz2
659 660 661 662 663

# ***************************************************************************
# libmatroska
# ***************************************************************************

664 665
libmatroska:
	svn co http://svn.matroska.org/svn/matroska/trunk/libmatroska libmatroska
666 667

.matroska: libmatroska
668
	(cd $<; make -C make/linux prefix=$(PREFIX) $(HOSTCC2) staticlib && make -C make/linux install_staticlib install_headers prefix=$(PREFIX))
669
	$(RANLIB) $(PREFIX)/lib/libmatroska.a
670 671 672 673
	touch $@

CLEAN_FILE += .matroska
CLEAN_PKG += libmatroska
674
DISTCLEAN_PKG += libmatroska-$(LIBMATROSKA_VERSION).tar.bz2
675 676 677 678 679

# ***************************************************************************
# ffmpeg
# ***************************************************************************

680 681 682
# Note: at present, we check out the tree from 2005-04-30 because of 
# compilation issues. We will use the latest version again, when our
# ffmpeg-module is fixed properly -- FK
683
ffmpeg:
684
	echo $(FFMPEG_CVSROOT) A > ./ffmpeg.cvs
685
	CVS_PASSFILE=./ffmpeg.cvs cvs -z3 -d $(FFMPEG_CVSROOT) co -D 2005-04-30 ffmpeg
686
	patch -p 0 < Patches/ffmpeg.patch.cvs
Christophe Massiot's avatar
Christophe Massiot committed
687
#	(cd $@; ./bootstrap)
688

Christophe Massiot's avatar
Christophe Massiot committed
689 690 691
ffmpeg-$(FFMPEG_VERSION).tar.gz:
	$(WGET) $(FFMPEG_URL)

692 693 694
#ffmpeg: ffmpeg-$(FFMPEG_VERSION).tar.gz
#	$(EXTRACT_GZ)
#	patch -p 0 < Patches/ffmpeg.patch
695 696

.ffmpeg: ffmpeg
697
	(cd $<; ./configure $(FFMPEGCONF) --prefix=$(PREFIX) --extra-cflags="$(CFLAGS) -DRUNTIME_CPUDETECT" --extra-ldflags="$(LDFLAGS)" --enable-gpl --enable-mp3lame --enable-faac --enable-pp --disable-vhook --disable-audio-beos --disable-ffserver --disable-vorbis --disable-faad --enable-mp3lame --enable-zlib --enable-a52 && make && make -C libavcodec/libpostproc install && make -C libavcodec installlib && make -C libavformat installlib)
698 699 700 701
	touch $@

CLEAN_FILE += .ffmpeg
CLEAN_PKG += ffmpeg
Christophe Massiot's avatar
Christophe Massiot committed
702
DISTCLEAN_PKG += ffmpeg-$(FFMPEG_VERSION).tar.gz
703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733

# ***************************************************************************
# openslp
# ***************************************************************************

openslp-$(OPENSLP_VERSION).tar.gz:
	$(WGET) $(OPENSLP_URL)

openslp: openslp-$(OPENSLP_VERSION).tar.gz
	$(EXTRACT_GZ)
	patch -p 0 < Patches/openslp.patch

.openslp: openslp
	(cd $<; ./configure --prefix=$(PREFIX) && make SUBDIRS="common libslpattr slpd libslp slptool" && make install SUBDIRS="common libslpattr slpd libslp slptool")
	touch $@

CLEAN_FILE += .openslp
CLEAN_PKG += openslp
DISTCLEAN_PKG += openslp-$(OPENSLP_VERSION).tar.gz

# ***************************************************************************
# libdvdcss
# ***************************************************************************

libdvdcss-$(LIBDVDCSS_VERSION).tar.gz:
	$(WGET) $(LIBDVDCSS_URL)

libdvdcss: libdvdcss-$(LIBDVDCSS_VERSION).tar.gz
	$(EXTRACT_GZ)

.dvdcss: libdvdcss
734
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .dvdcss
CLEAN_PKG += libdvdcss
DISTCLEAN_PKG += libdvdcss-$(LIBDVDCSS_VERSION).tar.gz

# ***************************************************************************
# libdvdread
# ***************************************************************************

libdvdread-$(LIBDVDREAD_VERSION).tar.gz:
	$(WGET) $(LIBDVDREAD_URL)

libdvdread: libdvdread-$(LIBDVDREAD_VERSION).tar.gz
	$(EXTRACT_GZ)
Eric Petit's avatar
Eric Petit committed
751
	patch -p 0 < Patches/libdvdread.patch
752 753

.dvdread: libdvdread .dvdcss
754
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) --with-libdvdcss=$(PREFIX) && make && make install)
755 756 757 758 759 760 761
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .dvdread
CLEAN_PKG += libdvdread
DISTCLEAN_PKG += libdvdread-$(LIBDVDREAD_VERSION).tar.gz

762 763 764 765 766 767 768 769 770
# ***************************************************************************
# libdvdnav
# ***************************************************************************

libdvdnav-$(LIBDVDNAV_VERSION).tar.gz:
	$(WGET) $(LIBDVDNAV_URL)

libdvdnav: libdvdnav-$(LIBDVDNAV_VERSION).tar.gz
	$(EXTRACT_GZ)
771
	patch -p 0 < Patches/dvdnav.patch
772
ifdef HAVE_DARWIN_OS
hartman's avatar
hartman committed
773
	(cd $@; autoconf)
774
else
775 776
	(cd $@; ./autogen.sh noconfig)
endif
777 778

.dvdnav: libdvdnav .dvdread
779
	(cd $<; ./configure $(HOSTCONF) --enable-static --prefix=$(PREFIX) --with-libdvdcss=$(PREFIX) CFLAGS="$(CFLAGS) -Dlseek64=lseek -Doff64_t=off_t" && make && make install)
780 781 782 783 784 785 786
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .dvdnav
CLEAN_PKG += libdvdnav
DISTCLEAN_PKG += libdvdnav-$(LIBDVDNAV_VERSION).tar.gz

787 788 789 790
# ***************************************************************************
# libdvbpsi
# ***************************************************************************

791
libdvbpsi3-$(LIBDVBPSI_VERSION).tar.gz:
792 793
	$(WGET) $(LIBDVBPSI_URL)

794
libdvbpsi: libdvbpsi3-$(LIBDVBPSI_VERSION).tar.gz
795 796 797
	$(EXTRACT_GZ)

.dvbpsi: libdvbpsi
798
	(cd $<; ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
799 800 801 802 803 804 805
	$(INSTALL_NAME)
	touch $@

CLEAN_FILE += .dvbpsi
CLEAN_PKG += libdvbpsi
DISTCLEAN_PKG += libdvbpsi-$(LIBDVBPSI_VERSION).tar.gz

806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828
# ***************************************************************************
# live
# ***************************************************************************

live.$(LIVEDOTCOM_VERSION).tar.gz:
	$(WGET) $(LIVEDOTCOM_URL)

live: live.$(LIVEDOTCOM_VERSION).tar.gz
	$(EXTRACT_GZ)
	patch -p 0 < Patches/live.patch

.live: live
	(cd $<; ./genmakefiles macosx && make )
	touch $@

CLEAN_FILE += .live
CLEAN_PKG += live
DISTCLEAN_PKG += live.$(LIVEDOTCOM_VERSION).tar.gz

# ***************************************************************************
# goom
# ***************************************************************************

hartman's avatar
hartman committed
829 830
#goom-macosx-altivec-bin.tar.gz:
#	$(WGET) $(GOOM_URL)
831

hartman's avatar
hartman committed
832 833 834 835 836 837 838 839 840 841 842 843 844 845 846
#goom: goom-macosx-altivec-bin.tar.gz
#	$(EXTRACT_GZ)

#.goom: goom
#	(cd $<;)
#	touch $@

#CLEAN_FILE += .goom
#CLEAN_PKG += goom
#DISTCLEAN_PKG += goom-macosx-altivec-bin.tar.gz

# ***************************************************************************
# goom2k4
# ***************************************************************************

847
goom$(GOOM2k4_VERSION).tar.gz:
hartman's avatar
hartman committed
848
	$(WGET) $(GOOM2k4_URL)
849
	mv goom-$(GOOM2k4_VERSION)-src.tar.gz goom$(GOOM2k4_VERSION).tar.gz
hartman's avatar
hartman committed
850

851
goom: goom$(GOOM2k4_VERSION).tar.gz
852
	$(EXTRACT_GZ)
853
	patch -p 0 < Patches/goom.patch
854

hartman's avatar
hartman committed
855
.goom2k4: goom
856
	(cd $<; ./configure --prefix=$(PREFIX) --disable-shared --enable-static && make && make install )
857 858
	touch $@

hartman's avatar
hartman committed
859
CLEAN_FILE += .goom2k4
860
CLEAN_PKG += goom
861
DISTCLEAN_PKG += goom$(GOOM2k_VESION).tar.gz
862

hartman's avatar
hartman committed
863 864 865 866 867 868 869 870 871 872 873
# ***************************************************************************
# libcaca
# ***************************************************************************

libcaca-$(LIBCACA_VERSION).tar.gz:
	$(WGET) $(LIBCACA_URL)

libcaca: libcaca-$(LIBCACA_VERSION).tar.gz
	$(EXTRACT_GZ)

.caca: libcaca
hartman's avatar
hartman committed
874
	(cd $<; ./configure --prefix=$(PREFIX) --disable-imlib2 --disable-doc && make && make install)
hartman's avatar
hartman committed
875 876 877 878 879 880
	touch $@

CLEAN_FILE += .caca
CLEAN_PKG += libcaca
DISTCLEAN_PKG += libcaca-$(LIBCACA_VERSION).tar.gz

881 882 883 884
# ***************************************************************************
# libdts
# ***************************************************************************

hartman's avatar
hartman committed
885
libdts-$(LIBDTS_VERSION).tar.gz:
hartman's avatar
hartman committed
886
	$(WGET) $(LIBDTS_URL)
887

888
ifeq ($(HOST),i586-pc-beos)
889 890 891 892
# libdts 0.0.2 doesn't compile on BeOS
libdts:
	svn co svn://svn.videolan.org/libdts/trunk libdts
	(cd $@; ./bootstrap)
893 894 895
else
libdts: libdts-$(LIBDTS_VERSION).tar.gz
	$(EXTRACT_GZ)
hartman's avatar
hartman committed
896
endif
897

hartman's avatar
hartman committed
898
.dts: libdts
899 900 901 902
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install)
	touch $@

CLEAN_FILE += .dts
hartman's avatar
hartman committed
903 904
CLEAN_PKG += libdts
DISTCLEAN_PKG += libdts-$(LIBDTS_VERSION).tar.gz
905

hartman's avatar
hartman committed
906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923
# ***************************************************************************
# libmodplug
# ***************************************************************************

libmodplug-$(MODPLUG_VERSION).tar.gz:
	$(WGET) $(MODPLUG_URL)

libmodplug: libmodplug-$(MODPLUG_VERSION).tar.gz
	$(EXTRACT_GZ)

.mod: libmodplug
	(cd $<; ./configure --prefix=$(PREFIX) --disable-shared --enable-static && make && make install)
	touch $@

CLEAN_FILE += .mod
CLEAN_PKG += libmodplug
DISTCLEAN_PKG += libmodplug-$(MODPLUG_VERSION).tar.gz

924 925 926 927 928 929 930 931 932 933 934 935
# ***************************************************************************
# libcddb
# ***************************************************************************

libcddb-$(CDDB_VERSION).tar.gz:
	$(WGET) $(CDDB_URL)

libcddb: libcddb-$(CDDB_VERSION).tar.gz
	$(EXTRACT_GZ)
	patch -p 0 < Patches/libcddb.patch

.cddb: libcddb
936
	(cd $<; ./configure --prefix=$(PREFIX) --disable-shared --enable-static CFLAGS="$(CFLAGS) -D_BSD_SOCKLEN_T_=int" LDFLAGS="$(LDFLAGS) -liconv" && make && make install)
937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952
	touch $@

CLEAN_FILE += .cddb
CLEAN_PKG += libcddb
DISTCLEAN_PKG += libcddb-$(CDDB_VERSION).tar.gz

# ***************************************************************************
# vcdimager
# ***************************************************************************

vcdimager-$(VCDIMAGER_VERSION).tar.gz:
	$(WGET) $(VCDIMAGER_URL)

vcdimager: vcdimager-$(VCDIMAGER_VERSION).tar.gz
	$(EXTRACT_GZ)

953
ifdef HAVE_DARWIN_OS
954 955 956
.vcdimager: vcdimager
	(cd $<; ./configure --prefix=$(PREFIX) --disable-shared --enable-static LDFLAGS="$(LDFLAGS) -framework CoreFoundation -framework IOKit" && make && make install)
	touch $@
957
else
958 959 960
.vcdimager: vcdimager
	(cd $<; ./configure --prefix=$(PREFIX) --disable-shared --enable-static && make && make install)
	touch $@
961
endif
962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977

CLEAN_FILE += .vcdimager
CLEAN_PKG += vcdimager
DISTCLEAN_PKG += vcdimager-$(VCDIMAGER_VERSION).tar.gz

# ***************************************************************************
# libcdio
# ***************************************************************************

libcdio-$(CDIO_VERSION).tar.gz:
	$(WGET) $(CDIO_URL)

libcdio: libcdio-$(CDIO_VERSION).tar.gz
	$(EXTRACT_GZ)

.cdio: libcdio
978
	(cd $<; ./configure --prefix=$(PREFIX) --without-vcdinfo --disable-shared && make && make install)
979 980 981 982 983 984
	touch $@

CLEAN_FILE += .cdio
CLEAN_PKG += libcdio
DISTCLEAN_PKG += libcdio-$(CDIO_VERSION).tar.gz

hartman's avatar
hartman committed
985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002
# ***************************************************************************
# OpenMash
# ***************************************************************************

mash-src-$(MASH_VERSION).tar.gz:
	$(WGET) $(MASH_URL)

mash-code: mash-src-$(MASH_VERSION).tar.gz
	$(EXTRACT_GZ)

.mash: mash-code
	(cd $<; ./configure && make )
	touch $@

CLEAN_FILE += .mash
CLEAN_PKG += mash-code
DISTCLEAN_PKG += mash-src-$(MASH_VERSION).tar.gz

1003
# ***************************************************************************
1004
# twolame
1005 1006
# ***************************************************************************

1007 1008
twolame-$(TWOLAME_VERSION).tar.gz:
	$(WGET) $(TWOLAME_URL)
1009

1010 1011
twolame: twolame-$(TWOLAME_VERSION).tar.gz
	$(EXTRACT_GZ)
1012

1013 1014
.twolame: twolame
	(cd twolame; ./configure --prefix=$(PREFIX) && make && make install)
1015 1016 1017
	$(INSTALL_NAME)
	touch $@

1018 1019 1020
CLEAN_FILE += .twolame
CLEAN_PKG += twolame
DISTCLEAN_PKG += twolame-$(TWOLAME_VERSION).tar.bz2
1021

1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033
# ***************************************************************************
# libpng
# ***************************************************************************

libpng-$(PNG_VERSION).tar.bz2:
	$(WGET) $(PNG_URL)

libpng: libpng-$(PNG_VERSION).tar.bz2
	$(EXTRACT_BZ2)
	cat Patches/libpng.patch | sed s,PREFIX,$(PREFIX), | patch -p0

.png: libpng
1034
	(cd $<; cp scripts/makefile.macosx Makefile && make && make install)
1035 1036 1037 1038 1039 1040
	touch $@

CLEAN_FILE += .png
CLEAN_PKG += libpng
DISCLEAN_PKG += libpng-$(PNG_VERSION).tar.bz2

1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058
# ***************************************************************************
# libzvbi
# ***************************************************************************

zvbi-$(ZVBI_VERSION).tar.bz2:
	$(WGET) $(ZVBI_URL)

zvbi: zvbi-$(ZVBI_VERSION).tar.bz2
	$(EXTRACT_BZ2)

.zvbi: zvbi
	(cd $<; ./configure --prefix=$(PREFIX) && make )
	touch $@

CLEAN_FILE += .zvbi
CLEAN_PKG += zvbi
DISCLEAN_PKG += zvbi-$(ZVBI_VERSION).tar.bz2

hartman's avatar
hartman committed
1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085
# ***************************************************************************
# gpg-error 
# ***************************************************************************

libgpg-error-$(GPGERROR_VERSION).tar.gz:
	$(WGET) $(GPGERROR_URL)

libgpg-error: libgpg-error-$(GPGERROR_VERSION).tar.gz
	$(EXTRACT_GZ)

.gpgerror: libgpg-error
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install )
	touch $@

CLEAN_FILE += .gpgerror
CLEAN_PKG += libgpg-error
DISCLEAN_PKG += libgpg-error-$(GPGERROR_VERSION).tar.gz

# ***************************************************************************
# libgcrypt
# ***************************************************************************

libgcrypt-$(GCRYPT_VERSION).tar.gz:
	$(WGET) $(GCRYPT_URL)

libgcrypt: libgcrypt-$(GCRYPT_VERSION).tar.gz
	$(EXTRACT_GZ)
hartman's avatar
hartman committed
1086
	patch -p 0 < Patches/gcrypt.patch
hartman's avatar
hartman committed
1087 1088

.gcrypt: libgcrypt
hartman's avatar
hartman committed
1089
	(cd $<; ./configure --prefix=$(PREFIX) CFLAGS="$(CFLAGS) -D_BSD_SOCKLEN_T_=int" && make && make install )
1090
	$(INSTALL_NAME)
hartman's avatar
hartman committed
1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107
	touch $@

CLEAN_FILE += .gcrypt
CLEAN_PKG += libgcrypt
DISCLEAN_PKG += libgcrypt-$(GCRYPT_VERSION).tar.gz

# ***************************************************************************
# gnutls
# ***************************************************************************

gnutls-$(GNUTLS_VERSION).tar.bz2:
	$(WGET) $(GNUTLS_URL)

gnutls: gnutls-$(GNUTLS_VERSION).tar.bz2
	$(EXTRACT_BZ2)

.gnutls: gnutls
1108 1109
	(cd $<; ./configure --prefix=$(PREFIX) && make && make install )
	$(INSTALL_NAME)
hartman's avatar
hartman committed
1110 1111 1112 1113 1114 1115
	touch $@

CLEAN_FILE += .gnutls
CLEAN_PKG += gnutls
DISCLEAN_PKG += gnutls-$(GNUTLS_VERSION).tar.bz2

1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127
# ***************************************************************************
# libopendaap
# ***************************************************************************

libopendaap-$(DAAP_VERSION).tar.bz2:
	$(WGET) $(DAAP_URL)

libopendaap: libopendaap-$(DAAP_VERSION).tar.bz2
	$(EXTRACT_BZ2)
	patch -p 0 < Patches/daap.patch

.daap: libopendaap
hartman's avatar
hartman committed
1128
	(cd $<; ./configure --prefix=$(PREFIX) CFLAGS="$(CFLAGS) -D_BSD_SOCKLEN_T_=int" && make install )
1129 1130 1131 1132 1133 1134
	touch $@

CLEAN_FILE += .daap
CLEAN_PKG += libopendaap
DISCLEAN_PKG += libopendaap-$(DAAP_VERSION).tar.bz2

1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188
# ***************************************************************************
# glib
# ***************************************************************************

glib-$(GLIB_VERSION).tar.gz:
	$(WGET) $(GLIB_URL)

glib: glib-$(GLIB_VERSION).tar.gz
	$(EXTRACT_GZ)

.glib: glib
	(cd $<; ./configure --prefix=$(PREFIX) --host=powerpc-apple-macos && make && make install )
	touch $@

CLEAN_FILE += .glibl
CLEAN_PKG += glib
DISCLEAN_PKG += glib-$(GLIB_VERSION).tar.gz

# ***************************************************************************
# libIDL
# ***************************************************************************

libIDL-$(LIBIDL_VERSION).tar.gz:
	$(WGET) $(LIBIDL_URL)

libIDL: libIDL-$(LIBIDL_VERSION).tar.gz
	$(EXTRACT_GZ)

.libidl: libIDL
	(cd $<; ./configure --prefix=$(PREFIX) --host=powerpc-apple-macos && make && make install )
	touch $@

CLEAN_FILE += .libidl
CLEAN_PKG += libIDL
DISCLEAN_PKG += libIDL-$(LIBIDL_VERSION).tar.gz

# ***************************************************************************
# mozilla
# ***************************************************************************

mozilla-source-$(MOZILLA_VERSION).tar.bz2:
	$(WGET) $(MOZILLA_URL)

mozilla: mozilla-source-$(MOZILLA_VERSION).tar.bz2
	$(EXTRACT_BZ2)

.mozilla: mozilla
	(cd $<; ./configure --prefix=$(PREFIX) --enable-default-toolkit=mac --enable-standalone-modules=xpcom,plugin && make && make install )
	touch $@

CLEAN_FILE += .mozilla
CLEAN_PKG += mozilla
DISCLEAN_PKG += mozilla-source-$(MOZILLA_VERSION).tar.bz2

1189
# ***************************************************************************
hartman's avatar
hartman committed
1190
# Copy aclocal files
1191
# This is necessary for --missing aclocal to succeed after a
hartman's avatar
hartman committed
1192 1193 1194 1195 1196
# configure.ac/Makefile.am change in the vlc root dir
# **************************************************************************

.aclocal:
	cp -R $(PREFIX)/share/aclocal/* $(PREFIX)/../../m4/
1197
	touch $@
hartman's avatar
hartman committed
1198 1199


1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213
# ***************************************************************************
# Some cleansing
# ***************************************************************************

clean-dots: FORCE
	rm -f $(CLEAN_FILE)

clean: clean-dots
	rm -rf $(CLEAN_PKG)

clean-src: clean
	rm -rf $(DISTCLEAN_PKG)

distclean: clean-src