<SuperNoeMan>
It has instructions, but its proving harder than I thought. I wish there was some kind of really easy script
hongboz has quit [Ping timeout: 252 seconds]
<diml>
SuperNoeMan: actually i did it last week: port install opam and then opam install utop
<SuperNoeMan>
thank you so much
<SuperNoeMan>
I knew there had to be an easier way. I really wish that the actual maintainers of utop would just put the opam way on there... gah
<diml>
SuperNoeMan: actually i am the author of utop
<diml>
yeah, i should probably put the opam way in the README
<diml>
doing it now
<SuperNoeMan>
wow!
<SuperNoeMan>
thank you so much
<SuperNoeMan>
I was going to write them an email reqeust :)
<SuperNoeMan>
you da boss!
tac-tics has quit [Quit: Page closed]
<diml>
it's pushed. I wrote a note at the beginning of the readme
<SuperNoeMan>
:) diml
SuperNoeMan has quit [Remote host closed the connection]
Playground has quit [Ping timeout: 245 seconds]
Playground has joined #ocaml
Playground has quit [Client Quit]
braden_ has joined #ocaml
cdidd has quit [Remote host closed the connection]
<braden_>
anyone here?
<braden_>
*here*
weie has joined #ocaml
braden_ has quit [Quit: Page closed]
fayden has quit [Quit: Bye]
fayden has joined #ocaml
ManAmongHippos has joined #ocaml
fayden has quit [Client Quit]
fayden has joined #ocaml
gour has joined #ocaml
troydm has quit [Ping timeout: 256 seconds]
troydm has joined #ocaml
cdidd has joined #ocaml
Playground has joined #ocaml
ManAmongHippos has quit [Quit: ManAmongHippos]
andreypopp has joined #ocaml
<wmeyer``>
hi
Playground has quit [Quit: When I come back, please tell me in what new ways you have decided to be completely wrong.]
<wmeyer``>
(morning)
<adrien>
moin
<wmeyer``>
is the ocamlbuild stopping you at the moment?
<wmeyer``>
we need to think about cross compilation story for ocamlbuild anyway
<adrien>
I've been a bit low on free time this week
<adrien>
I had to skip ocamlbuild
<wmeyer``>
yeah, me too
<adrien>
anyway it's not required
<wmeyer``>
Ok, feel free to raise tickets anyway
<adrien>
build the cross-compiler requires: ocamlc, ocamlopt, ocamlmklib
<adrien>
cross-compiling a native compiler will require: ocamldoc, ocamlbuild, camlp4, ocamllex, ...
<wmeyer``>
but building packages requires ocamlbuild to understand that your target is different than host
<adrien>
the biggest issue is that -custom seems undoable
<adrien>
-custom requires to dlopen() the libraries you link against in order to find primitives; obviously you're not going to dlopen() a .dll file on linux
<wmeyer``>
there might be other way to find the primitives
<adrien>
wmeyer``: it needs to pick up the right compiler but that should be easily doable with ocamlfind
<adrien>
about -custom, probably, we could skip it and simply not use it
<wmeyer``>
I'm keen on seein the toolchain being cross compilation aware.
<adrien>
it's used because windows doesn't grok shebangs...
<adrien>
hmm, ocamlbuild is going to need to know it's doing cross because it needs to know whiich files are being created
<adrien>
but for windows that could be solved by ocamlbuild seeing that ".exe" means "expect .dll files"
<adrien>
and for others the extensions shouldn't change
<adrien>
but actually, there is no choice: ocamlbuild has to support cross-compilation
<adrien>
if it tries to build myocamlbuild.ml with the cross-compiler, it won't work
<adrien>
I'd prefer to have a command-line switch for that: it makes it possible to reuse the ocamlbuild from your native installation
cdidd has quit [Remote host closed the connection]
Playground has joined #ocaml
cdidd has joined #ocaml
dwmw2_gone is now known as dwmw2_LHR
dwmw2_LHR has quit [Excess Flood]
dwmw2_gone has joined #ocaml
dwmw2_gone is now known as dwmw2_LHR
<wmeyer``>
adrien: we can work it out
<wmeyer``>
but there are other priorities, I'll raise mantis tickets for this chunk
<adrien>
I think the main outstanding issue currently is that it doesn't pick the proper ASM generator (it uses the host's); I hope to have working native binaries right after solving that
<wmeyer``>
yes, the current configuration is bolted to config, it picks the code generator from the target directory, and becasuse of bootstrapping it picks always from the same
andreypopp has quit [Quit: sleep]
Yoric has joined #ocaml
rwmjones has quit [Ping timeout: 276 seconds]
Submarine__ has joined #ocaml
rwmjones has joined #ocaml
andreypopp has joined #ocaml
cyball has quit [Quit: Leaving.]
Simn has joined #ocaml
RagingDave has joined #ocaml
Yoric has quit [Remote host closed the connection]
Yoric has joined #ocaml
invariant has joined #ocaml
<invariant>
Is there any way to install multiple OCaml compilers in parallel (in time) with opam?
<invariant>
I am thinking that it should be possible if multiple user accounts would be used.
<orbitz>
I don't think it currently supports it
mcclurmc has joined #ocaml
gour has quit [Disconnected by services]
gour_ has joined #ocaml
ontologiae has joined #ocaml
<wmeyer``>
invariant: you can change the root via --root option and then use normal shell & operator to spawn two opam process at the same time
<invariant>
wmeyer``, odd that this isn't the default then.
<wmeyer``>
invariant: AFAIK, opam relies on a state in the root and locks, to ensure consistency. It's not odd.
wmeyer`` is now known as wmeyer
<invariant>
wmeyer``, with multiple roots, there is no issue when installing multiple compilers.
<invariant>
wmeyer, all of them will have their own lock.
<invariant>
wmeyer, still, there is no reason for having locks with freely available databases.
ManAmongHippos has joined #ocaml
<wmeyer>
invariant: well, it's still a single line shell command.
<wmeyer>
invariant: i got your point that for each toolchain opam could maintain separate root. In practice however --root is used rarely
Cyanure has joined #ocaml
q66 has joined #ocaml
dwmw2_LHR is now known as dwmw2_gone
Yoric has quit [Ping timeout: 246 seconds]
ontologiae has quit [Ping timeout: 256 seconds]
ManAmongHippos has quit [Quit: ManAmongHippos]
jamii has joined #ocaml
justdit has joined #ocaml
justdit has quit [Read error: No route to host]
jamii has quit [Ping timeout: 252 seconds]
ontologiae has joined #ocaml
jamii has joined #ocaml
Yoric has joined #ocaml
eikke has joined #ocaml
tane has joined #ocaml
<invariant>
ocamldoc complains with "Bad magic number for this ocamldoc dump" for the 4.00.1+annot compiler.
<invariant>
Where does ocamldoc search and doesn't opam modify that information?
eikke has quit [Ping timeout: 252 seconds]
eikke has joined #ocaml
emmanuelux has quit [Ping timeout: 244 seconds]
pippijn has quit [Quit: qq]
pippijn has joined #ocaml
pippijn has quit [Changing host]
pippijn has joined #ocaml
emmanuelux has joined #ocaml
andreypopp has quit [Quit: sleep]
weie_ has joined #ocaml
weie has quit [Ping timeout: 255 seconds]
RagingDave has quit [Quit: Ex-Chat]
Submarine__ has quit [Ping timeout: 248 seconds]
Submarine__ has joined #ocaml
Demitar has joined #ocaml
justdit has joined #ocaml
tac has joined #ocaml
justdit has quit [Ping timeout: 248 seconds]
Demitar has quit [Quit: No Ping reply in 180 seconds.]
Demitar has joined #ocaml
tac has quit [Ping timeout: 245 seconds]
cdidd has quit [Remote host closed the connection]
Snark_ has joined #ocaml
Playground has quit [Ping timeout: 248 seconds]
Demitar has quit [Remote host closed the connection]
Submarine__ is now known as Submarine
Submarine has quit [Changing host]
Submarine has joined #ocaml
ulfdoz has quit [Quit: kernel-update]
<flux>
has anyone worked on erlang-like concurrency for ocaml? that is, threads could pass messages by copying (or passing pointers if it can be guaranteed that the pointer is invalid or not used in the sending end after that), and each thread would have their own garbage collector?
<flux>
so the task would be "put n ocaml threads into same address space, have them use their own gcs"
<flux>
in principle I suppose it's not a lot different from having OS processes, but I suppose using threads is lighter
<orbitz>
I think the VM would haveto change dramatically
<orbitz>
I knwo some people are working on doing this for Erlang, but it would be closer to a scheduler in erlang than a process
<orbitz>
since every one is still quite heavy (a whole VM perthread)
<wmeyer>
invariant: in most cases I don't use debugger too, but there is some complicated code with side effects that is known to be debugged under ocamldebug.
<wmeyer>
invariant: and yes, ocamldebug works only with bytecode
Snark_ has quit [Quit: Quitte]
<invariant>
wmeyer, what does this mean? No source file for Str.
Nahra has joined #ocaml
Nahra has quit [Changing host]
Nahra has joined #ocaml
<invariant>
wmeyer, in this case two different kinds of outputs are mixed and as such it's hard to see what comes from the debugger and what comes from the program being debugged.
<wmeyer>
invariant: I'd love to see your problem described in the bug tracker
<wmeyer>
invariant: I hope it gives you some hint. Otherwise gdb and ocaml is getting more and more mature to be able to debug ocaml codes. Please see the branch in svn
<invariant>
wmeyer, yes, you are not interested in hearing issues via IRC.
<invariant>
wmeyer, I think it's just a matter that the tools cannot handle native code.
<invariant>
wmeyer, or perhaps I should say foreign code.
<invariant>
wmeyer, so, all state is lost when you hit the buggy code.
<invariant>
A proper debugger would happily continue running in such a case.
<wmeyer>
invariant: no, I am not, because it will get lost in few hours. We are really interested in professional support from users. If there is a problem, even if it's a user problem, the development teram is very happy to see it reported.
Anarchos has joined #ocaml
<wmeyer>
invariant: this and perhaps other problems
invariant has left #ocaml []
gustav__ has quit [Read error: Connection reset by peer]
<SuperNoeMan>
I want to concatenate a single " with the rest of a string
<SuperNoeMan>
so, I think "\"" ^ my_string
<SuperNoeMan>
but that prints the \ with it. I don't want that.
<SuperNoeMan>
how do I get a single "?
<Qrntz>
SuperNoeMan, the toplevel echoes string values escaped
<Qrntz>
# print_endline ("\"" ^ "foo") ;;
<Qrntz>
"foo
<Qrntz>
- : unit = ()
<Qrntz>
it won't be there when you print or otherwise use it
<SuperNoeMan>
Qrntz: thanks much
<Qrntz>
np
<Reventlov>
Qrntz: hey
<Reventlov>
this is "old"
<invariant>
I thought I had it working, since opam didn't complain, but that was just because it completely wasn't working. Now it is only half broken. Is there something like an opam manual for adding new compilers?
<invariant>
It is ->recommanded<- WRONG that you add eval `opam config env` in the configuration file of your shell (most likely ~/.bashrc or ~/.profile).
<invariant>
rm -rf $(dirname $(opam config var prefix)) MY EYES
xavierm02 has joined #ocaml
<xavierm02>
hey
<xavierm02>
in batteries
<xavierm02>
external of_int : int -> int = "%identity"
<xavierm02>
external to_int : int -> int = "%identity"
<xavierm02>
I don't get the point of this code >_<
<Reventlov>
ty
<Qrntz>
Reventlov, I linked you to the latest manual too, which has the same description for both of these
<Qrntz>
xavierm02, it does exactly what it's supposed to
<Qrntz>
I guess it's a convention in Batteries to have {of,to}_int functions in numeric modules
<invariant>
The supposedly advanced usage of opam is not advanced enough for me.
<invariant>
I do see one way to work around the problem, which is by compiling opam itself with the dwarf compiler which will make it the system compiler.
<invariant>
Still, that's a hack and an option to opam switch to an arbitrary directory containing a ocaml compiler build should work.
<invariant>
I don't quite get the design where a compiler is being built and installed as a mandatory side-effect of opam.
<invariant>
That's just conflating two different steps into one.
<invariant>
Not a problem if it's there just for convenience, but not if the primitive elements are not exported.
nimred has joined #ocaml
nimred has quit [Changing host]
nimred has joined #ocaml
pkrnj has quit [Quit: Computer has gone to sleep.]
Nahra has quit [Quit: leaving]
xavierm02 has quit [Quit: Leaving]
Playground has joined #ocaml
RagingDave has joined #ocaml
leoncamel has quit [Ping timeout: 255 seconds]
<SuperNoeMan>
Hey, I'm working on an ocaml function that I want to have some properties
<SuperNoeMan>
I want to convert my definition of a rexp type (regular expression type)
RagingDave has quit [Read error: Operation timed out]
RagingDave has joined #ocaml
<SuperNoeMan>
nevermind I found the answer
<ousado>
SuperNoeMan: to which question?
<SuperNoeMan>
I was getting an error
<ousado>
ah
<SuperNoeMan>
or how to solve the problem to the error was getting. That's what I should have said
<SuperNoeMan>
sorry, I'm in a rush with some friends. I know how it feels when someone comes with halfway defined questions and they expect others to be able to help
<ousado>
easy
<SuperNoeMan>
I can't figure out how to use the debugger to help solve my problem
<SuperNoeMan>
do I just do let main = ... in order to have main executed when my program is executed?
cyball has quit [Ping timeout: 255 seconds]
<SuperNoeMan>
whenever I do ocamldebug myprog
<SuperNoeMan>
and I try to break main
<SuperNoeMan>
I get an error
<SuperNoeMan>
Unbound identifier main
<SuperNoeMan>
I don't know why... how do I simply debug this like I would gdb? I compiled it with -g. Load the program, break main and then step through execution...
<SuperNoeMan>
also, trace my_func isn't tracing it, it's just saying Error: Unbound value trace
<Qrntz>
01:13:14 < SuperNoeMan> do I just do let main = ... in order to have main executed when my program is executed?
<Qrntz>
no.
<Qrntz>
you use «let () = …»
<SuperNoeMan>
ah ok
<Qrntz>
that's going to be the entry point
<Qrntz>
also
<Qrntz>
01:23:25 < SuperNoeMan> also, trace my_func isn't tracing it, it's just saying Error: Unbound value trace
<Qrntz>
if that's in the toplevel, then the directive is «#trace»
<Qrntz>
not «trace» which would be a value's name
mcsquiggedy has quit [Remote host closed the connection]
<SuperNoeMan>
Qrntz: wow you are awesome thanks!
<Qrntz>
you're welcome
<SuperNoeMan>
very simple tips to someone that is new
<SuperNoeMan>
one more question about how to access functions within functions
<SuperNoeMan>
if I'm going to trace my_func and my_func contains code within it like let sub_func ... in