-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
autotools and erlmongo.spec for rpm thanks to sipXecs
- Loading branch information
1 parent
072766e
commit c055556
Showing
5 changed files
with
109 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
EXTRA_DIST = \ | ||
erlmongo.spec \ | ||
README.rdoc \ | ||
LICENSE.txt \ | ||
$(source_files) \ | ||
ebin/erlmongo.app | ||
|
||
erlmongohdrdir = $(ERLANG_INSTALL_LIB_DIR_erlmongo)/include | ||
dist_erlmongohdr_DATA = \ | ||
src/erlmongo.hrl | ||
|
||
erlmongobindir = $(ERLANG_INSTALL_LIB_DIR_erlmongo)/ebin | ||
|
||
source_files = \ | ||
src/erlmongo_app.erl \ | ||
src/mongoapi.erl \ | ||
src/mongodb.erl \ | ||
src/mongodb_supervisor.erl | ||
|
||
beam_files = $(foreach B,$(notdir $(source_files:.erl=.beam)),ebin/$(B)) | ||
|
||
erlmongobin_DATA = \ | ||
$(beam_files) \ | ||
ebin/erlmongo.app | ||
|
||
CLEANFILES = $(beam_files) | ||
|
||
all: $(beam_files); | ||
|
||
ebin/%.beam : src/%.erl | ||
test -d ebin || mkdir ebin | ||
$(ERLC) $(ERLC_FLAGS) -o ebin $< | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
AC_PREREQ(2.57) | ||
AC_INIT(erlmongo, 0.0.9, sergej.jurecko@wpn.tv) | ||
AC_CONFIG_AUX_DIR(config) | ||
AC_CONFIG_SRCDIR([src/erlmongo.hrl]) | ||
AM_INIT_AUTOMAKE(foreign tar-ustar) | ||
AC_ERLANG_PATH_ERL | ||
AC_ERLANG_PATH_ERLC | ||
AC_ERLANG_SUBST_INSTALL_LIB_SUBDIR(AC_PACKAGE_NAME, AC_PACKAGE_VERSION) | ||
AC_CONFIG_FILES([ | ||
Makefile | ||
]) | ||
AC_OUTPUT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
Name: erlmongo | ||
Version: 0.0.9 | ||
Release: 1%{?dist} | ||
Summary: Erlang driver for mongodb. | ||
|
||
Group: Database/Driver | ||
License: APL | ||
URL: https://github.com/wpntv/erlmongo | ||
Source0: %{name}-%{version}.tar.gz | ||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) | ||
|
||
BuildRequires: erlang | ||
Requires: erlang | ||
|
||
%define erlmongolibdir %{_libdir}/erlang/lib/%{name}-%{version} | ||
|
||
%description | ||
Erlmongo is a pretty complete Erlang driver for mongodb. | ||
|
||
It supports records and proplists as datatypes. Strings can be lists or binaries, but strings received from mongodb (as a result of find) will be binaries. | ||
|
||
Because of the way records work in Erlang, you need to call mongoapi:recinfo/2 before using any record, or define each record in erlmongo.hrl. | ||
|
||
|
||
%prep | ||
%setup -q | ||
|
||
|
||
%build | ||
%configure | ||
make %{?_smp_mflags} | ||
|
||
|
||
%install | ||
rm -rf $RPM_BUILD_ROOT | ||
make install DESTDIR=$RPM_BUILD_ROOT | ||
|
||
|
||
%clean | ||
rm -rf $RPM_BUILD_ROOT | ||
|
||
|
||
%files | ||
%defattr(-,root,root,-) | ||
%doc | ||
|
||
%{erlmongolibdir}/ebin/erlmongo.app | ||
%{erlmongolibdir}/ebin/erlmongo_app.beam | ||
%{erlmongolibdir}/ebin/mongodb.beam | ||
%{erlmongolibdir}/ebin/mongodb_supervisor.beam | ||
%{erlmongolibdir}/ebin/mongoapi.beam | ||
%{erlmongolibdir}/include/erlmongo.hrl | ||
|
||
%changelog | ||
* Thu Jan 27 2011 Douglas Hubler <douglas@hubler.us> | ||
- Initial release |