Added tcc-0.9.25 build template.

This commit is contained in:
Juan RP 2011-02-24 15:42:01 +01:00
parent b34874574d
commit a6b89ffae0
2 changed files with 82 additions and 0 deletions

View File

@ -0,0 +1,43 @@
--- Makefile.orig 2011-02-24 15:04:41.177936565 +0100
+++ Makefile 2011-02-24 15:07:25.127413480 +0100
@@ -197,25 +197,25 @@ INSTALL=install
ifndef CONFIG_WIN32
install: $(PROGS) $(LIBTCC1) $(BCHECK_O) libtcc.a tcc.1 tcc-doc.html
- mkdir -p "$(bindir)"
- $(INSTALL) -s -m755 $(PROGS) "$(bindir)"
- mkdir -p "$(mandir)/man1"
- $(INSTALL) tcc.1 "$(mandir)/man1"
- mkdir -p "$(tccdir)"
- mkdir -p "$(tccdir)/include"
+ $(INSTALL) -d "$(DESTDIR)$(bindir)"
+ $(INSTALL) -m755 $(PROGS) "$(DESTDIR)$(bindir)"
+ $(INSTALL) -d "$(DESTDIR)$(mandir)/man1"
+ $(INSTALL) -m644 tcc.1 "$(DESTDIR)$(mandir)/man1"
+ $(INSTALL) -d "$(DESTDIR)$(tccdir)"
+ $(INSTALL) -d "$(DESTDIR)$(tccdir)/include"
ifneq ($(LIBTCC1),)
- $(INSTALL) -m644 $(LIBTCC1) "$(tccdir)"
+ $(INSTALL) -m644 $(LIBTCC1) "$(DESTDIR)$(tccdir)"
endif
ifneq ($(BCHECK_O),)
- $(INSTALL) -m644 $(BCHECK_O) "$(tccdir)"
+ $(INSTALL) -m644 $(BCHECK_O) "$(DESTDIR)$(tccdir)"
endif
- $(INSTALL) -m644 $(addprefix include/,$(TCC_INCLUDES)) "$(tccdir)/include"
- mkdir -p "$(docdir)"
- $(INSTALL) -m644 tcc-doc.html "$(docdir)"
- mkdir -p "$(libdir)"
- $(INSTALL) -m644 libtcc.a "$(libdir)"
- mkdir -p "$(includedir)"
- $(INSTALL) -m644 libtcc.h "$(includedir)"
+ $(INSTALL) -m644 $(addprefix include/,$(TCC_INCLUDES)) "$(DESTDIR)$(tccdir)/include"
+ $(INSTALL) -d "$(DESTDIR)$(docdir)"
+ $(INSTALL) -m644 tcc-doc.html "$(DESTDIR)$(docdir)"
+ $(INSTALL) -d "$(DESTDIR)$(libdir)"
+ $(INSTALL) -m644 libtcc.a "$(DESTDIR)$(libdir)"
+ $(INSTALL) -d "$(DESTDIR)$(includedir)"
+ $(INSTALL) -m644 libtcc.h "$(DESTDIR)$(includedir)"
uninstall:
rm -fv $(foreach P,$(PROGS),"$(bindir)/$P")

39
srcpkgs/tcc/template Normal file
View File

@ -0,0 +1,39 @@
# Template file for 'tcc'
pkgname=tcc
version=0.9.25
distfiles="${NONGNU_SITE}/tinycc/tcc-$version.tar.bz2"
build_style=custom-install
short_desc="The Tiny C Compiler"
maintainer="Juan RP <xtraeme@gmail.com>"
checksum=1bed6cb0fb2ef4100df1b94435d22863679e84cf419ec48ef96d9c0e9063de35
long_desc="
Features
* SMALL! You can compile and execute C code everywhere, for example on
rescue disks (about 100KB for x86 TCC executable, including C
preprocessor, C compiler, assembler and linker).
* FAST! tcc generates x86 code. No byte code overhead. Compile, assemble
and link several times faster than GCC.
* UNLIMITED! Any C dynamic library can be used directly. TCC is heading
torward full ISOC99 compliance. TCC can of course compile itself.
* SAFE! tcc includes an optional memory and bound checker. Bound checked
code can be mixed freely with standard code.
* Compile and execute C source directly. No linking or assembly necessary.
Full C preprocessor and GNU-like assembler included.
* C script supported : just add '#!/usr/local/bin/tcc -run' at the first
line of your C source, and execute it directly from the command line.
* With libtcc, you can use TCC as a backend for dynamic code generation."
Add_dependency run glibc
Add_dependency build perl # for pod2man
do_build()
{
sed -i -e "s|pod2man|/usr/lib/perl5/core_perl/bin/pod2man|g" Makefile
./configure --prefix=/usr --mandir=/usr/share/man
make ${makejobs}
}
do_install()
{
make DESTDIR=${DESTDIR} install
}