We are undertaking an effort to do a better job of documenting sinan.
There are two big ways you can help. The first is to respond here and
let us know what specifically you would like to see documented. I
would also like to hear about what specifically you had problems with
when you where getting up to speed on the language.
The second thing is, for those of you willing to put in a bit of
effort, is a write up of how you use sinan. Some real world examples
would go a long way.
> The question I have about sinan is how to use it with published components
> that use rebar. I'm ignorant of both, but it looks like rebar projects come
> with a Makefile, and one uses such a project by going to the top level
> directory and running "make" - at which point arbitrarily complex things
> happen but the result is all the sources and binaries you need.
> What is the process for incorporating such a project into a sinan project?
> E.g., suppose I wanted to use sinan to build something with cowboy, which
> uses rebar. Do I just point sinan at the cowbory repository and then "sinan
> build" just works? Or do I need to look at the cowboy Makefile and rebar
> stuff and tell sinan about them (recurse for all dependencies)?
As long as the dependencies have been pull sinan should be able to
build the project. The one thing sinan wont be able to do though is
fetch the dependencies.
So theoretically, you should just be able to go to the project and run
sinan build and things will work. If the deps have not been fetched
then you would need to do rebar get-deps and sinan build. The deps
thing should be solved soonish though.
> If this question makes stupid assumptions, the documentation should address
> those. Assume the reader knows nothing about rebar. sinan can't achieve
> World Domination by requiring that one understand rebar first :-).
> - Stephen
> --
> You received this message because you are subscribed to the Google Groups
> "erlware-questions" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/erlware-questions/-/HN4gmp9PLlUJ.
> To post to this group, send email to erlware-questions@googlegroups.com.
> To unsubscribe from this group, send email to
> erlware-questions+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/erlware-questions?hl=en.
You need the proper dependency. and whoever built jiffy_tests didn't
specify any dependency on proper at all so sinan doesn't know to warn
you that you don't have it.
On Sat, Jun 16, 2012 at 9:52 PM, <s.schaefer.at....@gmail.com> wrote:
> On Saturday, June 16, 2012 7:36:33 PM UTC-4, s.schaef...@gmail.com wrote:
>> On Thursday, June 14, 2012 9:50:18 AM UTC-4, Eric Merritt wrote:
>>> As long as the dependencies have been pull sinan should be able to
>>> build the project. The one thing sinan wont be able to do though is
>>> fetch the dependencies.
>>> So theoretically, you should just be able to go to the project and run
>>> sinan build and things will work. If the deps have not been fetched
>>> then you would need to do rebar get-deps and sinan build. The deps
>>> thing should be solved soonish though.
>> bash-4.2$ sinan build
>> It looks like we couldn't satisfy all the dependency constraints We are
>> going to search the space to see what the problem is but this could take a
>> while
>> Unable to resolve compile time dependencies, probably due to the following
>> constraints:
>> constraint on bcmvc_web with constraints [{bcmvc_web,"0.1.0"}] originating
>> from these application(s) ['__top_level__'] constraint on bcmvc_db with
>> constraints [{bcmvc_db,"0.1.0"}] originating from these application(s)
>> ['__top_level__'] constraint on bcmvc_models with constraints
>> [{bcmvc_models,"0.1.0"}] originating from these application(s)
>> ['__top_level__']
>> bash-4.2$
> OK, I'm closer now. I did a "sinan gen" and named all the applications I
> knew would be included, then started copying in the files one at a time
> until "sinan build" started failing. So now I'm in dependency purgatory -
> not dependency hell, since I haven't yet encountered mutually exclusive
> dependencies. One by one I copy the dependent applications into the lib
> directory.
> jiffy is giving me fits - although "make" within my git clone of proper
> exits success, "sinan build" says jiffy_tests can't find
> "proper/include/proper.hrl" regardless of what I put in the ERL_LIBS
> environment variable or $HOME/.erlang
> To post to this group, send email to erlware-questions@googlegroups.com.
> To unsubscribe from this group, send email to
> erlware-questions+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/erlware-questions?hl=en.
On Wed, Aug 15, 2012 at 1:36 PM, Bill Zajac <billza...@gmail.com> wrote:
> I am trying to build something with a cowboy 0.6.0 dependency. I have cowboy in lib/cowboy, but it apparently has a dependency on proper 1.0. I have run rebar -C rebar.tests.config get-deps, and I have moved lib/cowboy/deps/proper to lib/proper, but I am still seeing the following error.
Does proper and cowboy both have the version numbers in the directory?
Unfortunately, for dependencies that is still something sinan needs.
> --
> You received this message because you are subscribed to the Google Groups "erlware-questions" group.
> To view this discussion on the web visit https://groups.google.com/d/msg/erlware-questions/-/hKgzP0FJeTMJ.
> To post to this group, send email to erlware-questions@googlegroups.com.
> To unsubscribe from this group, send email to erlware-questions+unsubscribe@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/erlware-questions?hl=en.
Oh, Cowboy I think has an implicit dependency on proper (that is they use it but don't specify it). I may have missed this but do you have proper specified as a compile time dependency in your sinan.config?
> Any ideas? I am willing to do some hackery to get this working, especially with cowboy.app.src if need be.
> It seems like it might have to do with order of build (or of building the _build directory). It looks like it is trying to build cowboy before proper. Is there a way to specify order? I assumed that came from parsing thru the app.src files.
> Thanks again,
> Bill
> On Monday, August 20, 2012 7:26:44 AM UTC-7, Eric Merritt wrote:
> On Wed, Aug 15, 2012 at 1:36 PM, Bill Zajac <bill...@gmail.com> wrote: > > I am trying to build something with a cowboy 0.6.0 dependency. I have cowboy in lib/cowboy, but it apparently has a dependency on proper 1.0. I have run rebar -C rebar.tests.config get-deps, and I have moved lib/cowboy/deps/proper to lib/proper, but I am still seeing the following error.
> Does proper and cowboy both have the version numbers in the directory? > Unfortunately, for dependencies that is still something sinan needs.
> > Unable to find include "proper/include/proper.hrl" when processing module: dispatcher_prop
> > I have also tried adding the following to my sinan.config > > {dep_constraints, > > [{lager, "1.0.0"}, > > {syslog, "0.0.1"}, > > {lager_syslog, "0.9.0"}, > > {proper, "1.0"}, > > {cowboy, "0.6.0"}, > > {flake, "0.7"}, > > {mochiweb, "2.3.2"}, > > {work_queue, "0.1.0"}]}.
> > I have also tried adding proper to applications in: lib/cowboy/src/cowboy.app.src
> > Am I missing something?
> > Here is some more output: > > sinan -vvv build > > starting: depends > > Using the following lib directories to resolve dependencies:
> Sorry for the delayed response. Are compile time dependencies specified in dep_constraints? If so, then yes.
> If not, can you tell me how to specify them?
> Here is my sinan.config:
> {project_name, cellophane}.
> {project_vsn, "0.0.1"}.
> {build_dir, "_build"}.
> {ignore_dirs, ["_", "."]}.
> {ignore_apps, []}.
> %% You can see what we have with: sinan depends -v
> {dep_constraints,
> [{lager, "1.0.0"},
> {syslog, "0.0.1"},
> {lager_syslog, "0.9.0"},
> {proper, "1.0"},
> {cowboy, "0.6.0"},
> {flake, "0.7"},
> {mochiweb, "2.3.2"},
> {work_queue, "0.1.0"}]}.
> On Monday, August 20, 2012 10:46:00 AM UTC-7, Eric Merritt wrote:
> Oh, Cowboy I think has an implicit dependency on proper (that is they use it but don't specify it). I may have missed this but do you have proper specified as a compile time dependency in your sinan.config?
> On Aug 20, 2012, at 12:12 PM, Bill Zajac wrote:
>> Thanks for your help Eric,
>> In the build directory, yes (no version numbers in cellophane/lib though).
>> ls -l _build/cellophane/lib/
>> total 32
>> drwxr-xr-x 9 wilzajac users 4096 Aug 15 11:26 cowboy-0.6.0
>> drwxr-xr-x 4 wilzajac users 4096 Aug 15 11:22 flake-0.7
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 lager-1.0.0
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 lager_syslog-0.9.0
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 mochiweb-2.3.2
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 proper-1.0
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 syslog-0.0.1
>> drwxr-xr-x 3 wilzajac users 4096 Aug 15 11:21 work_queue-0.1.0
>> ls -l lib/
>> total 36
>> drwxr-xr-x 6 wilzajac users 4096 Aug 15 10:31 cellophane
>> drwxr-xr-x 10 wilzajac users 4096 Aug 15 11:25 cowboy
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 flake
>> drwxr-xr-x 7 wilzajac users 4096 Aug 15 10:20 lager
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 lager_syslog
>> drwxr-xr-x 9 wilzajac users 4096 Aug 15 10:20 mochiweb
>> drwxr-xr-x 9 wilzajac users 4096 Aug 15 11:25 proper
>> drwxr-xr-x 7 wilzajac users 4096 Aug 15 10:20 syslog
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 work_queue
>> I also tried this permutation:
>> ls -l lib/
>> total 36
>> drwxr-xr-x 6 wilzajac users 4096 Aug 15 10:31 cellophane
>> drwxr-xr-x 10 wilzajac users 4096 Aug 15 11:25 cowboy-0.6.0
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 flake
>> drwxr-xr-x 7 wilzajac users 4096 Aug 15 10:20 lager
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 lager_syslog
>> drwxr-xr-x 9 wilzajac users 4096 Aug 15 10:20 mochiweb
>> drwxr-xr-x 9 wilzajac users 4096 Aug 15 11:25 proper-1.0
>> drwxr-xr-x 7 wilzajac users 4096 Aug 15 10:20 syslog
>> drwxr-xr-x 5 wilzajac users 4096 Aug 15 10:20 work_queue
>> Also, I have tried the following two modifications to cowboy.app.src
>> Any ideas? I am willing to do some hackery to get this working, especially with cowboy.app.src if need be.
>> It seems like it might have to do with order of build (or of building the _build directory). It looks like it is trying to build cowboy before proper. Is there a way to specify order? I assumed that came from parsing thru the app.src files.
>> Thanks again,
>> Bill
>> On Monday, August 20, 2012 7:26:44 AM UTC-7, Eric Merritt wrote:
>> On Wed, Aug 15, 2012 at 1:36 PM, Bill Zajac <bill...@gmail.com> wrote: >> > I am trying to build something with a cowboy 0.6.0 dependency. I have cowboy in lib/cowboy, but it apparently has a dependency on proper 1.0. I have run rebar -C rebar.tests.config get-deps, and I have moved lib/cowboy/deps/proper to lib/proper, but I am still seeing the following error.
>> Does proper and cowboy both have the version numbers in the directory? >> Unfortunately, for dependencies that is still something sinan needs.
>> > Unable to find include "proper/include/proper.hrl" when processing module: dispatcher_prop
>> > I have also tried adding the following to my sinan.config >> > {dep_constraints, >> > [{lager, "1.0.0"}, >> > {syslog, "0.0.1"}, >> > {lager_syslog, "0.9.0"}, >> > {proper, "1.0"}, >> > {cowboy, "0.6.0"}, >> > {flake, "0.7"}, >> > {mochiweb, "2.3.2"}, >> > {work_queue, "0.1.0"}]}.
>> > I have also tried adding proper to applications in: lib/cowboy/src/cowboy.app.src
>> > Am I missing something?
>> > Here is some more output: >> > sinan -vvv build >> > starting: depends >> > Using the following lib directories to resolve dependencies: