mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-10 08:16:15 +02:00
* Refactoring (step 2).
This commit is contained in:
parent
ac68840e79
commit
fd7ac09f10
6 changed files with 17 additions and 10 deletions
|
@ -35,6 +35,7 @@ AC_CONFIG_FILES([Makefile
|
||||||
src/nix-store/Makefile
|
src/nix-store/Makefile
|
||||||
src/nix-hash/Makefile
|
src/nix-hash/Makefile
|
||||||
src/libexpr/Makefile
|
src/libexpr/Makefile
|
||||||
|
src/nix-instantiate/Makefile
|
||||||
scripts/Makefile
|
scripts/Makefile
|
||||||
corepkgs/Makefile
|
corepkgs/Makefile
|
||||||
corepkgs/fetchurl/Makefile
|
corepkgs/fetchurl/Makefile
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
SUBDIRS = bin2c boost libutil libstore libmain nix-store nix-hash \
|
SUBDIRS = bin2c boost libutil libstore libmain nix-store nix-hash \
|
||||||
libexpr #nix-instantiate
|
libexpr nix-instantiate
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
bin_PROGRAMS = nix-instantiate
|
noinst_LIBRARIES = libexpr.a
|
||||||
|
|
||||||
nix_instantiate_SOURCES = nixexpr.cc parser.cc eval.cc primops.cc main.cc
|
libexpr_a_SOURCES = nixexpr.cc parser.cc eval.cc primops.cc
|
||||||
nix_instantiate_LDADD = ../libmain/libmain.a ../libstore/libstore.a ../libutil/libutil.a \
|
|
||||||
../boost/format/libformat.a -L../../externals/inst/lib -ldb_cxx \
|
|
||||||
-lsglr -lATB -lconversion -lasfix2 -lmept -lATerm
|
|
||||||
|
|
||||||
AM_CXXFLAGS = \
|
AM_CXXFLAGS = \
|
||||||
-I.. -I../../externals/inst/include -I../libutil -I../libstore -I../libmain
|
-I.. -I../../externals/inst/include -I../libutil -I../libstore
|
||||||
|
|
||||||
|
|
||||||
# Parse table generation.
|
# Parse table generation.
|
||||||
|
|
|
@ -12,7 +12,6 @@ extern "C" {
|
||||||
|
|
||||||
#include "aterm.hh"
|
#include "aterm.hh"
|
||||||
#include "parser.hh"
|
#include "parser.hh"
|
||||||
#include "shared.hh"
|
|
||||||
#include "parse-table.h"
|
#include "parse-table.h"
|
||||||
|
|
||||||
|
|
||||||
|
@ -100,8 +99,7 @@ Expr parseExprFromFile(Path path)
|
||||||
|
|
||||||
ATprotect(&lang);
|
ATprotect(&lang);
|
||||||
lang = ATmake("Nix");
|
lang = ATmake("Nix");
|
||||||
if (!SGopenLanguageFromTerm(
|
if (!SGopenLanguageFromTerm("nix-parse", lang, parseTable))
|
||||||
(char *) programId.c_str(), lang, parseTable))
|
|
||||||
throw Error(format("cannot open language"));
|
throw Error(format("cannot open language"));
|
||||||
|
|
||||||
SG_STARTSYMBOL_ON();
|
SG_STARTSYMBOL_ON();
|
||||||
|
|
11
src/nix-instantiate/Makefile.am
Normal file
11
src/nix-instantiate/Makefile.am
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
bin_PROGRAMS = nix-instantiate
|
||||||
|
|
||||||
|
nix_instantiate_SOURCES = main.cc
|
||||||
|
nix_instantiate_LDADD = ../libmain/libmain.a ../libexpr/libexpr.a \
|
||||||
|
../libstore/libstore.a ../libutil/libutil.a \
|
||||||
|
../boost/format/libformat.a -L../../externals/inst/lib -ldb_cxx \
|
||||||
|
-lsglr -lATB -lconversion -lasfix2 -lmept -lATerm
|
||||||
|
|
||||||
|
AM_CXXFLAGS = \
|
||||||
|
-I.. -I../../externals/inst/include -I../libutil -I../libstore \
|
||||||
|
-I../libexpr -I../libmain
|
Loading…
Reference in a new issue