forked from ocaml/ocaml-re
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
5,642 additions
and
66 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 |
---|---|---|
@@ -1,2 +1,5 @@ | ||
.*.swp | ||
_build/ | ||
setup.data | ||
setup.log | ||
*.bak |
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 |
---|---|---|
@@ -1,68 +1,19 @@ | ||
.PHONY: all clean install build | ||
all: build | ||
|
||
NAME = re | ||
setup.data: | ||
ocaml setup.ml -configure | ||
|
||
OCAMLC = ocamlfind ocamlc -g | ||
OCAMLOPT = ocamlfind ocamlopt -unsafe | ||
OCAMLDEP = ocamldep | ||
build: setup.data | ||
ocaml setup.ml -build | ||
|
||
INCFLAGS = | ||
OBJECTS = cset.cmo automata.cmo \ | ||
re.cmo re_posix.cmo re_emacs.cmo re_perl.cmo re_glob.cmo re_str.cmo | ||
XOBJECTS = $(OBJECTS:cmo=cmx) | ||
INTFS = re.mli re_posix.mli re_emacs.mli re_perl.mli re_glob.mli re_str.mli | ||
install: | ||
ocaml setup.ml -install | ||
|
||
ARCHIVE = $(NAME).cma | ||
XARCHIVE = $(NAME).cmxa | ||
reinstall: | ||
ocamlfind -remove regexp || true | ||
ocaml setup.ml -reinstall | ||
|
||
REQUIRES = | ||
PREDICATES = | ||
|
||
all: $(ARCHIVE) | ||
opt: $(XARCHIVE) | ||
|
||
$(ARCHIVE): $(OBJECTS) | ||
$(OCAMLC) -a -o $(ARCHIVE) -package "$(REQUIRES)" -linkpkg \ | ||
-predicates "$(PREDICATES)" $(OBJECTS) | ||
$(XARCHIVE): $(XOBJECTS) | ||
$(OCAMLOPT) -a -o $(XARCHIVE) -package "$(REQUIRES)" -linkpkg \ | ||
-predicates "$(PREDICATES)" $(XOBJECTS) | ||
|
||
.SUFFIXES: .cmo .cmi .cmx .ml .mli | ||
|
||
.ml.cmo: | ||
$(OCAMLC) -package "$(REQUIRES)" -predicates "$(PREDICATES)" \ | ||
$(INCFLAGS) -c $< | ||
.mli.cmi: | ||
$(OCAMLC) -package "$(REQUIRES)" -predicates "$(PREDICATES)" \ | ||
$(INCFLAGS) -c $< | ||
.ml.cmx: | ||
$(OCAMLOPT) -package "$(REQUIRES)" -predicates "$(PREDICATES)" \ | ||
$(INCFLAGS) -c $< | ||
|
||
depend: *.ml *.mli | ||
$(OCAMLDEP) $(INCFLAGS) *.ml *.mli util/*.ml util/*.mli > depend | ||
include depend | ||
|
||
install: all | ||
{ test ! -f $(XARCHIVE) || extra="$(XARCHIVE) "`basename $(XARCHIVE) .cmxa`.a; }; \ | ||
ocamlfind install $(NAME) $(INTFS) $(INTFS:mli=cmi) $(ARCHIVE) META $$extra | ||
|
||
uninstall: | ||
ocamlfind remove $(NAME) | ||
|
||
clean:: | ||
rm -f *.cmi *.cmo *.cmx *.cma *.cmxa *.a *.o | ||
rm -f util/*.cmi util/*.cmo util/*.cmx util/*.o | ||
|
||
clean:: | ||
cd tests; make clean | ||
|
||
realclean: clean | ||
rm -f *~ util/*~ | ||
|
||
distrib: realclean | ||
cd ..; tar zcvf re.tar.gz --exclude CVS re | ||
|
||
check: $(ARCHIVE) | ||
fort $(ARCHIVE) -env tests/env.ml \ | ||
tests/test_re.ml tests/test_emacs.ml tests/test_perl.ml | ||
clean: | ||
ocamlbuild -clean | ||
rm -f setup.data setup.log |
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,13 @@ | ||
OASISFormat: 0.2 | ||
Name: regexp | ||
Version: 0.9-dev | ||
Synopsis: Pure OCaml regular expression library | ||
Authors: Jerome Vouillon | ||
License: LGPL-2.0 with OCaml linking exception | ||
Plugins: META (0.2) | ||
|
||
Library re | ||
Path: lib | ||
BuildTools: ocamlbuild | ||
Modules: Re,Cset,Automata,Re_posix,Re_perl,Re_glob,Re_str | ||
|
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,18 @@ | ||
# OASIS_START | ||
# DO NOT EDIT (digest: ecd10cf2b97824384a608da0dc44c060) | ||
# Ignore VCS directories, you can use the same kind of rule outside | ||
# OASIS_START/STOP if you want to exclude directories that contains | ||
# useless stuff for the build process | ||
<**/.svn>: -traverse | ||
<**/.svn>: not_hygienic | ||
".bzr": -traverse | ||
".bzr": not_hygienic | ||
".hg": -traverse | ||
".hg": not_hygienic | ||
".git": -traverse | ||
".git": not_hygienic | ||
"_darcs": -traverse | ||
"_darcs": not_hygienic | ||
# Library re | ||
"lib": include | ||
# OASIS_STOP |
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,9 @@ | ||
# OASIS_START | ||
# DO NOT EDIT (digest: 50f4e2b5330b2d9e94554eba6b37b43c) | ||
version = "0.9-dev" | ||
description = "Pure OCaml regular expression library" | ||
archive(byte) = "re.cma" | ||
archive(native) = "re.cmxa" | ||
exists_if = "re.cma" | ||
# OASIS_STOP | ||
|
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,10 @@ | ||
# OASIS_START | ||
# DO NOT EDIT (digest: db3e05d0568bfbd5227f0a2c226b2475) | ||
Re | ||
Cset | ||
Automata | ||
Re_posix | ||
Re_perl | ||
Re_glob | ||
Re_str | ||
# OASIS_STOP |
Oops, something went wrong.