Package Details: lcc-compiler 4.2-1

Git Clone URL: (read-only, click to copy)
Package Base: lcc-compiler
Description: A small and fast C compiler.
Upstream URL:
Licenses: custom
Submitter: None
Maintainer: aksr
Last Packager: aksr
Votes: 4
Popularity: 0.075430
First Submitted: 2011-06-30 05:37
Last Updated: 2016-04-24 15:44

Latest Comments

Hekuran commented on 2021-09-14 14:18

This tarball is very old from 2007. While the last commit in the new github repo, ist from january 2021.

The package builds with just changing the souce and the two cd commands. Though i have not tested the program. here is the git diff:

diff --git a/PKGBUILD b/PKGBUILD
index 0ddc794..b806a9e 100644
@@ -6,24 +6,22 @@ pkgver=4.2
 pkgdesc="A small and fast C compiler."
 arch=('i686' 'x86_64')

 build() {
-  cd $srcdir/${_pkgname}-$pkgver
+  cd $srcdir/${_pkgname}
   mkdir -p ${_pkgname}
   BUILDDIR=lcc make -j2 CFLAGS="-O2 -DLCCDIR='\"/usr/lib/lcc/\"'" HOSTFILE=./etc/linux.c lcc
   BUILDDIR=lcc make -j2 CFLAGS="-O2 -DLCCDIR='\"/usr/lib/lcc/\"'" all

 package() {
-  cd $srcdir/${_pkgname}-$pkgver/${_pkgname}
+  cd $srcdir/${_pkgname}/${_pkgname}
   mkdir -p $pkgdir/usr/{bin,lib/${_pkgname}/include,man/man1}
   install -Dm755 bprint $pkgdir/usr/bin/bprint
   install -Dm755 lburg $pkgdir/usr/bin/lburg

andreas_baumann commented on 2020-08-06 08:37

cat > hello.c <<EOF

#include <stdio.h>

int main( int argc, char *argv[] )
        puts( "Hello" );
        return 0;
lcc -o hello hello.c
cpp: /usr/include/features.h:187 /usr/include/bits/libc-header-start.h:33 /usr/include/stdio.h:27 hello.c:1 Unknown preprocessor control warning
cpp: /usr/include/features.h:397 /usr/include/bits/libc-header-start.h:33 /usr/include/stdio.h:27 hello.c:1 Unknown preprocessor control warning
cpp: /usr/include/features.h:399 /usr/include/bits/libc-header-start.h:33 /usr/include/stdio.h:27 hello.c:1 Unknown preprocessor control warning
lcc: fatal error in /usr/lib/lcc/gcc/cpp

There might be gcc-ism or/and glibc-isms everywhere in the copied header files. Unless upstream makes sure the lcc preprocessor can read those, one can not compile simple programs it seems.

andreas_baumann commented on 2020-08-06 08:33

ln -s /usr/lib/gcc/*-linux-gnu/*/include/*
ln -s /usr/lib/gcc/*-linux-gnu/*/crt*

should be more explicit:

ln -s /usr/lib/gcc/x86_64-pc-linux-gnu/*/include/*
ln -s /usr/lib/gcc/x86_64-pc-linux-gnu/*/crt*

Some people might have gcc-cross-compilers installed in /usr/lib/gcc (for instance I have: avr riscv64-linux-gnu x86_64-pc-linux-gnu).

Using the wildcard results in "file exists" errors.

aksr commented on 2015-07-16 14:56

perlawk: I renamed rcc to lcc-rcc to avoid a conflict with qtchooser.

perlawk commented on 2014-04-19 14:06

suggest to rename the rcc to lrcc
and add some warning to the package user.

perlawk commented on 2014-04-19 14:01

failed to compile:
to fix:

andreas_baumann commented on 2011-10-15 18:39

Spoiler alert: During package build (yes I know, never build as root), some parts of gcc get replaced with fatal
effects for gcc.

andreas_baumann commented on 2011-10-12 17:58

I get a conflict with /usr/bin/rcc from the qt package:

pacman -Ql qt | grep /usr/bin/rcc

qt /usr/bin/rcc