This is another updated version :) v0.3

Changes:
1. Added make %.reconf rule for reconfiguring a package
2. Moved _srcdir path generation into configure.ac
3. Added a few more libs and apps to build, including e itself

Defaults to throwing all build out to /dev/null

Please let me know if it works for you, or more importantly if it doesnt work. It should be able to run a complete build without hickup.

$ autoreconf -iv
$ ./configure --preifx=/opt/e17 --libdir=/opt/e17/lib64
$ make

Set your PATH and LD_LIBRARY_PATH and you are off to running e17.

I was surprised to see the size of my /opt/e17 folder, its 78mb, wow, bigger than Linux, win95, win98 and kdelibs.

Vikram

#                                               -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.

AC_PREREQ(2.61)
AC_INIT(englightenment, VERSION, BUG-REPORT-ADDRESS)
AC_CONFIG_SRCDIR([libs/ecore/src/lib/ecore/ecore.c])

# List of things to build
BUILD_LIBS="eet evas ecore embryo efreet edje e_dbus emotion engrave \
epsilon esmart etk etk_extra"

BUILD_APPS="e exquisite exhibit expedite entrance"

AC_SUBST([build_lib_list],[$BUILD_LIBS])
AC_SUBST([build_app_list],[$BUILD_APPS])

BUILD_LIBS_BUFFER=
for i in $BUILD_LIBS ; do
        BUILD_LIBS_BUFFER+="${i}_srcdir = \$(SRCDIR)/libs/$i
"
done
AC_SUBST([build_lib_srcdirs],[$BUILD_LIBS_BUFFER])

BUILD_APPS_BUFFER=
for i in $BUILD_APPS ; do
        BUILD_APPS_BUFFER+="${i}_srcdir = \$(SRCDIR)/apps/$i
" 
done
AC_SUBST([build_app_srcdirs],[$BUILD_APPS_BUFFER])

AC_CONFIG_FILES([Makefile])
AC_OUTPUT
# Author        - Vikram Ambrose
# Date          - 10/8/2008
# Version       - 0.3

# Installation Prefix
prefix          = @prefix@
exec_prefix     = @exec_prefix@
libdir          = @libdir@
bindir          = @bindir@

INCLUDEDIR      = $(prefix)/include

# Top level source directory (ie, SRCDIR/libs/eet etc..)
# Must be absolute path
SRCDIR          = @abs_top_srcdir@

# Folder to build in
BUILDDIR        = $(SRCDIR)/build

# Folder to store timestamps
STAMPDIR        = $(BUILDDIR)/stamps

# Number of make jobs
JOBS            = 2

# Method of creating time stamp
STAMP           = echo `date` > 

# Print on the screen
PRINT           = echo -n -e 

# Build Log
LOG             = &> /dev/null 

# Environment variables for ./configure
CONFIG_VARS     = \
        PKG_CONFIG_PATH=$(libdir)/pkgconfig 

# Options to pass to ./configure
CONFIG_OPTS     = \
        --prefix=$(prefix) \
        --libdir=$(libdir) 


# Environment variable for running make
MAKE_VARS       = \
        PATH=$$PATH:$(bindir)

# Environemnt variables for ./autogen.sh
AUTOGEN_VARS    = NOCONFIGURE=y

# List of things to build
BUILD_ALL       = @build_lib_list@ \
        @build_app_list@

#       enity

all:  $(STAMPDIR)/built_all setup_env $(BUILD_ALL)
        @$(PRINT) "ALl Done\n"

$(STAMPDIR)/built_all: setup_env
        @$(STAMP) $@

# Run only once to create folders and other stuff if necessary
$(STAMPDIR)/setup :
        @$(PRINT) "Creating build folders\n"
        @mkdir $(STAMPDIR)
        @$(STAMP) $@

# Run at each package rule
setup_env : $(STAMPDIR)/setup
        @$(PRINT) "Setting up Environment\n"
        
# sh autogen.sh rule
$(STAMPDIR)/%.preconf : $(STAMPDIR)/setup
        @$(PRINT) "Preconfiguring:\t\t$(basename $(notdir $@))\n"
        @cd $($(basename $(notdir $@))_srcdir) && \
                $(AUTOGEN_VARS) ./autogen.sh $(LOG)
        @mkdir $(BUILDDIR)/$(basename $(notdir $@))
        @$(STAMP) $@

# Used to run ./configure
$(STAMPDIR)/%.conf : $(STAMPDIR)/%.preconf
        @$(PRINT) "Configuring:\t\t$(basename $(notdir $@))\n"
        @cd $(BUILDDIR)/$(basename $(notdir $@)) \
                && $(CONFIG_VARS) \
                $($(basename $(notdir $@))_srcdir)/configure \
                $(CONFIG_OPTS)  $(LOG)
        @$(STAMP) $@

# Actual compile rule
$(STAMPDIR)/%.compile : $(STAMPDIR)/%.conf
        @$(PRINT) "Compiling:\t\t$(basename $(notdir $@))\n"
        @time \
                { $(MAKE_VARS) make \
                        -C $(BUILDDIR)/$(basename $(notdir $@)) \
                        -j $(JOBS) \
                        $(LOG) ; }
        @$(STAMP) $@

# Install rule
$(STAMPDIR)/%.install : $(STAMPDIR)/%.compile
        @$(PRINT) "Installing:\t\t$(basename $(notdir $@))\n"
        @time \
                { make \
                        -C $(BUILDDIR)/$(basename $(notdir $@))  \
                        install \
                        $(LOG) ; }
        @$(STAMP) $@

        
# Clean rule
%.clean: $(BUILDDIR)/%
        @$(PRINT) "Cleaning $(basename $@)\n"
        @-make -C $(BUILDDIR)/$(basename $@) clean $(LOG)
        @-rm -f \
                $(STAMPDIR)/$(basename $@).compile \
                $(STAMPDIR)/$(basename $@).install

# Distclean rule
%.distclean: $(BUILDDIR)/%
        @$(PRINT) "Dist Cleaning $(basename $@)\n"
        @-make -C $(BUILDDIR)/$(basename $@) distclean $(LOG) 
        @-rm -f $(STAMPDIR)/$(basename $@).compile \
                $(STAMPDIR)/$(basename $@).install \
                $(STAMPDIR)/$(basename $@).conf 
                

# Map rules to stamps
%.preconf:$(STAMPDIR)/%.preconf
        @$(PRINT) "$(basename $@) preconfigured\n"
%.conf: $(STAMPDIR)/%.conf
        @$(PRINT) "$(basename $@) configured\n"
%.reconf: $(STAMPDIR)/%.preconf
        @rm -f $(STAMPDIR)/$(basename $@).conf
        @make $(basename $@).conf
%.compile: $(STAMPDIR)/%.compile
        @$(PRINT) "$(basename $@) compiled\n"
%.install: $(STAMPDIR)/%.install
        @$(PRINT) "$(basename $@) installed\n"


@build_lib_srcdirs@


@build_app_srcdirs@


# Listed explicitly to prevent Make from deleteing intermediataries 
# from Chain Rule
eet:    $(STAMPDIR)/eet.install \
        $(STAMPDIR)/eet.compile \
        $(STAMPDIR)/eet.conf \
        $(STAMPDIR)/eet.preconf

evas:   $(STAMPDIR)/evas.install \
        $(STAMPDIR)/evas.compile \
        $(STAMPDIR)/evas.conf \
        $(STAMPDIR)/evas.preconf \
        eet

ecore:  $(STAMPDIR)/ecore.install \
        $(STAMPDIR)/ecore.compile \
        $(STAMPDIR)/ecore.conf \
        $(STAMPDIR)/ecore.preconf \
        evas

embryo: $(STAMPDIR)/embryo.install \
        $(STAMPDIR)/embryo.compile \
        $(STAMPDIR)/embryo.conf \
        $(STAMPDIR)/embryo.preconf \
        efreet

efreet: $(STAMPDIR)/efreet.install \
        $(STAMPDIR)/efreet.compile \
        $(STAMPDIR)/efreet.conf \
        $(STAMPDIR)/efreet.preconf \
        ecore

edje:   $(STAMPDIR)/edje.install \
        $(STAMPDIR)/edje.compile \
        $(STAMPDIR)/edje.conf \
        $(STAMPDIR)/edje.preconf \
        embryo evas

e_dbus: $(STAMPDIR)/e_dbus.install \
        $(STAMPDIR)/e_dbus.compile \
        $(STAMPDIR)/e_dbus.conf \
        $(STAMPDIR)/e_dbus.preconf \
        edje

emotion:$(STAMPDIR)/emotion.install \
        $(STAMPDIR)/emotion.compile \
        $(STAMPDIR)/emotion.conf \
        $(STAMPDIR)/emotion.preconf \
        edje

e:$(STAMPDIR)/e.install \
        $(STAMPDIR)/e.compile \
        $(STAMPDIR)/e.conf \
        $(STAMPDIR)/e.preconf \
        e_dbus

evolve:$(STAMPDIR)/evolve.install \
        $(STAMPDIR)/evolve.compile \
        $(STAMPDIR)/evolve.conf \
        $(STAMPDIR)/evolve.preconf \
        etk

epsilon:$(STAMPDIR)/epsilon.install \
        $(STAMPDIR)/epsilon.compile \
        $(STAMPDIR)/epsilon.conf \
        $(STAMPDIR)/epsilon.preconf \
        ecore evas

engrave:$(STAMPDIR)/engrave.install \
        $(STAMPDIR)/engrave.compile \
        $(STAMPDIR)/engrave.conf \
        $(STAMPDIR)/engrave.preconf \
        e_dbus

esmart:$(STAMPDIR)/esmart.install \
        $(STAMPDIR)/esmart.compile \
        $(STAMPDIR)/esmart.conf \
        $(STAMPDIR)/esmart.preconf \
        ecore evas

etk:$(STAMPDIR)/etk.install \
        $(STAMPDIR)/etk.compile \
        $(STAMPDIR)/etk.conf \
        $(STAMPDIR)/etk.preconf \
        ecore evas edje

etk_extra:$(STAMPDIR)/etk_extra.install \
        $(STAMPDIR)/etk_extra.compile \
        $(STAMPDIR)/etk_extra.conf \
        $(STAMPDIR)/etk_extra.preconf \
        etk

exquisite:$(STAMPDIR)/exquisite.install \
        $(STAMPDIR)/exquisite.compile \
        $(STAMPDIR)/exquisite.conf \
        $(STAMPDIR)/exquisite.preconf \
        eet evas ecore embryo edje

enity:$(STAMPDIR)/enity.install \
        $(STAMPDIR)/enity.compile \
        $(STAMPDIR)/enity.conf \
        $(STAMPDIR)/enity.preconf \
        etk

exhibit:$(STAMPDIR)/exhibit.install \
        $(STAMPDIR)/exhibit.compile \
        $(STAMPDIR)/exhibit.conf \
        $(STAMPDIR)/exhibit.preconf \
        etk

expedite:$(STAMPDIR)/expedite.install \
        $(STAMPDIR)/expedite.compile \
        $(STAMPDIR)/expedite.conf \
        $(STAMPDIR)/expedite.preconf \
        evas

entrance:$(STAMPDIR)/entrance.install \
        $(STAMPDIR)/entrance.compile \
        $(STAMPDIR)/entrance.conf \
        $(STAMPDIR)/entrance.preconf \
        evas ecore edje esmart

.PHONY: $(BUILD_ALL) setup_env all

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to