<det>
Now to figure out how to intergrate ocamlbuild and sexplib :/
pr has quit [Ping timeout: 250 seconds]
pr has joined #ocaml
pr has quit [Changing host]
pr has joined #ocaml
<det>
Ocaml tooling is such a nightmare
<det>
maybe this oasis thing makes it easier
ankit9 has joined #ocaml
ankit9 has quit [Client Quit]
arubin has quit [Quit: arubin]
joewilliams_away is now known as joewilliams
Julien_T has quit [Ping timeout: 258 seconds]
haelix has quit [Ping timeout: 246 seconds]
haelix has joined #ocaml
sebz has joined #ocaml
dnolen_ has quit [Quit: dnolen_]
sebz has quit [Quit: Computer has gone to sleep.]
sebz has joined #ocaml
sebz has quit [Client Quit]
sebz has joined #ocaml
sebz has quit [Client Quit]
ulfdoz has joined #ocaml
sebz has joined #ocaml
<adrien>
det: a bit late but ocamlbuild on 3.12 takes -use-ocamlfind, and this lets you put "<foo>: package(sexplib), syntax(camlp4o)" [iirc] in your _tags file
othiym23 has joined #ocaml
larhat1 has joined #ocaml
larhat has quit [Read error: Connection reset by peer]
joewilliams is now known as joewilliams_away
ulfdoz has quit [Read error: Operation timed out]
edwin has joined #ocaml
jamii has joined #ocaml
<det>
adrien, aww, too bad Ubuntu is on 3.11.2 :<
Julien_Tz has joined #ocaml
Julien_Tz is now known as Julien_T
StepanKuzmin has joined #ocaml
sepp2k has quit [Quit: Leaving.]
jamii has quit [Ping timeout: 255 seconds]
<det>
I cant even figure out how to compile this by hand now, the compiler reports a syntax error when it sees "with sexp"
<det>
ahh, complaining on IRC always means I solve it in next 10 seconds :)
bobry1 has joined #ocaml
ftrvxmtrx has quit [Quit: This computer has gone to sleep]
munga has joined #ocaml
<adrien>
det: well, on 3.11.2, you can use a publicly-available myocamlbuild.ml and use "pkg_sexplib, syntax_sexplib" (something _like_ that)
<adrien>
and, you can also use -verbose to help ;-)
<det>
adrien, ya, that's exactly what I did :)
<adrien>
=)
<det>
well, "pkg_sexplib.syntax, syntax_camlp4o"
Submarine has joined #ocaml
StepanKuzmin has quit [Read error: Connection reset by peer]
StepanKuzmin has joined #ocaml
ikaros has joined #ocaml
kerx has joined #ocaml
<kerx>
ML'ers
munga has quit [Ping timeout: 250 seconds]
kerx has quit [Quit: Leaving]
sebz has quit []
eikke has joined #ocaml
f[x] has quit [Ping timeout: 258 seconds]
sebz has joined #ocaml
munga has joined #ocaml
StepanKuzmin has quit [Read error: Connection reset by peer]
StepanKuzmin has joined #ocaml
ankit9 has joined #ocaml
bobry1 is now known as bobry-
Amorphous has quit [Ping timeout: 255 seconds]
todun has joined #ocaml
Amorphous has joined #ocaml
sebz has quit [Quit: Computer has gone to sleep.]
lopex has joined #ocaml
ftrvxmtrx has joined #ocaml
StepanKuzmin has quit [Read error: Connection reset by peer]
StepanKuzmin has joined #ocaml
ztfw has joined #ocaml
Cyanure has joined #ocaml
avsm has joined #ocaml
othiym23 has quit [Ping timeout: 276 seconds]
lopex has quit [Ping timeout: 252 seconds]
lopex has joined #ocaml
munga has quit [Ping timeout: 260 seconds]
ankit9 has quit [Ping timeout: 255 seconds]
eb4890 has joined #ocaml
munga has joined #ocaml
todun has quit [Quit: todun]
StepanKuzmin has quit [Remote host closed the connection]
emmanuelux has joined #ocaml
avsm has quit [Quit: Leaving.]
wagle has quit [Ping timeout: 276 seconds]
eb4890 has quit [Ping timeout: 255 seconds]
wagle has joined #ocaml
dnolen_ has joined #ocaml
Cyanure has quit [Remote host closed the connection]
Submarine has quit [Quit: Leaving.]
64MAAWUH4 has quit [Ping timeout: 250 seconds]
iratsu has joined #ocaml
dnolen_ has quit [Quit: dnolen_]
emmanuelux has quit [Remote host closed the connection]
lopex has quit []
<thelema_>
String.global_replace ~sub ~by str -- any better ideas for labels on arguments?
<adrien>
subst? repl?
<thelema_>
I wish ~from and ~to would work, but ~to is a keyword
<mart>
with?
<thelema_>
also a keyword
<mart>
gah.
<adrien>
actually, subst would be bad here, I had "substitution" in mind; I think "sub" is good
<thelema_>
sub makes me think "subroutine"
avsm has joined #ocaml
<hcarty>
thelema_: You could match PCRE's choices
<thelema_>
hcarty: what's that?
<hcarty>
thelema_: I think PCRE uses ~pat (and ~rex?) and ~tmpl...
<thelema_>
yes, this is pretty extensive. This implementation is a simple substring -> substring replacement
<hcarty>
thelema_: Is there an regexp support here, or only verbatim strings?
<thelema_>
just verbatim strings
<thelema_>
regexps in batteries are still todo
<hcarty>
Maybe ~orig and ~by?
<hcarty>
or ~str ~by
<thelema_>
~str was the name for the main argument.
<thelema_>
maybe I'll just deal with ~sub
<hcarty>
I think ~sub and ~by are a bit confusing together
<hcarty>
You could rename the main argument original or src
impy has quit [Read error: Connection reset by peer]
<thelema_>
global_replace ~src ~dst str
<thelema_>
nah
<hcarty>
dst kind of implies that's where the result is stored
impy has joined #ocaml
<thelema_>
global_replace ~find ~by str
<hcarty>
Why not rename the main argument?
<hcarty>
Its name isn't exposed in the API
<thelema_>
the main argument is (and should be) unlabeled
<hcarty>
The only names a user will see are ~from and ~to (whatever they end up being). No one will ever see the name str unless they read the implementation.
<thelema_>
sure, we can label it original or something, no problem.
<thelema_>
I'm just trying to work on the interface
<hcarty>
My preference is global_replace ~str ~by xxx, as it reads somewhat correctly out loud
ulfdoz has joined #ocaml
lopex has joined #ocaml
larhat1 has quit [Quit: Leaving.]
joewilliams_away is now known as joewilliams
zvrba has joined #ocaml
bobry- has quit [Ping timeout: 255 seconds]
eikke has quit [Ping timeout: 252 seconds]
munga has quit [Ping timeout: 264 seconds]
ulfdoz_ has joined #ocaml
ulfdoz has quit [Ping timeout: 240 seconds]
ulfdoz_ is now known as ulfdoz
<thelema_>
grr, batString.replace has the labels ~str ~sub ~by. Should have fixed it then.
<thelema_>
options: inconsistent labels vs. fixing both in v2
eikke has joined #ocaml
Abbaduxo has joined #ocaml
<hcarty>
thelema_: Fix both in v2 sounds like a good plan
<hcarty>
thelema_: That will at least keep both functions consistent within a major release
<thelema_>
the downside to doing this is that changing from batteries v1 to v2 will be more difficult
<thelema_>
I wonder if a hack like golang uses is reasonable for ocaml - source upgrading for API changes
<hcarty>
It would be a cool thing to have
<thelema_>
probably very difficult because of partial evaluation and passing around functions as values
<hcarty>
thelema_: Is it more important for Batteries to be self-consistent, or easy to upgrade between major versions?
avsm has quit [Quit: Leaving.]
<thelema_>
That was my question. I guess if v2 provides substantial value, people will upgrade, but so far, we've been very successful at extending v1 without breaking compatibility
<hcarty>
I think that self-consistency is more important when it is known that incompatible changes will be made when the major version changes.
<thelema_>
I hope this debate becomes easier after 2.0, although hopefully not too much easier
<thelema_>
We might be overly cautious to make backwards incompatible changes right now.
ftrvxmtrx_ has joined #ocaml
waern has joined #ocaml
othiym23 has joined #ocaml
ftrvxmtrx has quit [*.net *.split]
rwmjones has quit [*.net *.split]
rwmjones has joined #ocaml
rwmjones has quit [*.net *.split]
rwmjones has joined #ocaml
eikke has quit [Ping timeout: 240 seconds]
ftrvxmtrx_ has quit [Quit: This computer has gone to sleep]
bobry has quit [Quit: Leaving.]
bobry has joined #ocaml
iratsu has quit [Quit: Leaving.]
Abbaduxo has quit [Remote host closed the connection]
iratsu has joined #ocaml
iratsu has quit [Remote host closed the connection]
iratsu has joined #ocaml
rwmjones has quit [*.net *.split]
eikke has joined #ocaml
rwmjones has joined #ocaml
iratsu has quit [Quit: Ex-Chat]
iratsu has joined #ocaml
<NaCl>
woohoo Navy Interview
<NaCl>
...
<thelema_>
you?
<NaCl>
that totally went to the wrong tab. xD
<thelema_>
:)
<NaCl>
At least it wasn't as bad as the time I posed a root password for one of my machines to a channel because I forgot that windows doesn't really support focus-follows-mouse
<thelema_>
yup, I double-check where I'm typing my root password exactly because of this
<adrien>
well, entering a root password from windows was the first mistake ;-)
<NaCl>
ssh fail
<bobry>
folks, what's wrong with ocamlforge? it tells me to checkout `svn checkout svn:///svn/ocamlweb/trunk` -- obviously this isn't the correct url :)
<adrien>
as for windows, it does support sloppy-focus (have to go to regedit to do that, it has focus-follows-mouse with a 500ms timer in "accessibility" now)
<NaCl>
adrien: I know, but it breaks some stuff
<adrien>
NaCl: mostly works
<adrien>
NaCl: otoh, I use vim and cmd on that machine
<thelema_>
NaCl: I don't know, I'm about to work some more on this
alang_ has joined #ocaml
<adrien>
ocaml itself is easy, libraries, you know how it goes
<adrien>
thelema_: like what first?
iratsu has left #ocaml []
ftrvxmtrx has joined #ocaml
* adrien
thinks this was poor english
<NaCl>
what about a toplevel with history support?
<adrien>
lwt's? lwt's + changes?
avsm has joined #ocaml
<adrien>
ledit has that, and especially ledit 2 and it should work ;-)
<thelema_>
adrien: I'm going to work more on windows ocaml via godi - I installed mingw yesterday, let's see if godi works under it
* NaCl
really should fiddle with that toplevel
<adrien>
it's a wrapper but then: doskey ocaml=ledit ocaml $*
<thelema_>
adrien: ledit for windows?
<adrien>
(kind of "alias")
* thelema_
realizes how long it's been since "doskey" hit his screen
<adrien>
thelema_: hmmm, at first it sounded like it'd have no issue with portability but I think I completely forgot some stuff like cmd.exe...
<NaCl>
thelema_: that whole "mingw" thing probably shouldn't have to be there. xD
* adrien
wishes it had been more than a couple hours ago that doskey hit his screen
<adrien>
NaCl: well, the C compiler
<thelema_>
NaCl: agreed - I have Visual studio, but have no idea how to use that to bootstrap ocaml
<adrien>
honestly, I prefer mingw(-w64) there, it's free
<thelema_>
as long as the final binary works, I'm happy
<adrien>
you get a familiar environment that works well and which can be used for cross-compilation
<adrien>
I should find a couple of hours to try ocaml with mingw-64, it should work now
<adrien>
hmm
<NaCl>
except *all* windows terms look ugly
<NaCl>
well, all but one
<adrien>
thelema_: keep in mind that 3.12.1 is supposed to be broken with mingw currently
<adrien>
(for godi, 3.12.1 is in "-section dev" at bootstrap stage)
<thelema_>
is 3.12.0 available in godi?
<adrien>
(-)-section 3.12
<thelema_>
great
jamii has joined #ocaml
<adrien>
iirc Gerd said he'd put 3.12.1 in the main section tomorrow if everything was going well (there has been some issues but not many, but it'll probably end up there soon)
<NaCl>
thelema_: the instructions to get it working with MS stuff still requires sygwin
<NaCl>
*cygwin
<thelema_>
is there an easy way to install wget under godi?
<thelema_>
NaCl: ah, okay.
<thelema_>
(i.e. other than downloading its tarball and ./configure && make && make install)
<NaCl>
thelema_: there is a native windows binary somewhere
<thelema_>
but no nice package manager built into mingw
<adrien>
thelema_: dunno but watch out, wget has a bug where "wget -O - $url > file" does not work (it gets outputted to console so if you see that, you know what happens)
<thelema_>
ok, I'll remember that.
<adrien>
there's mingw-get which is getting some kind of traction but imho it sucks (partly because I have yypkg, partly because it doesn't support uninstallation (!) and has a crappy package model)
<NaCl>
:///svn/ocamlweb/trunk` -- obviously this isn't the correct url :)
<NaCl>
14:05:40 < adrien> as for windows, it does support sloppy-focus (have to go to regedit to do that, it has focus-follows-mouse with a 500ms timer in "accessibility" now)
<NaCl>
14:05:59 < NaCl> adrien: I know,:///svn/ocamlweb/trunk` -- obviously this isn't the correct url :)
<NaCl>
14:05:40 < adrien> as for windows, it does support sloppy-focus (have to go to regedit to do that, it has focus-follows-mouse with a 500ms timer in "accessibility" now)
<NaCl>
...
<adrien>
ah, you're in X and not on windows now I take it :-)
<NaCl>
nope, putty
<adrien>
it has copy-on-select?
<thelema_>
and right-click to paste
<NaCl>
and I was cleaning my mouse
<thelema_>
lol.
<flux>
I've been living mouseless for a while.. it's nice, but I haven't been able to copy-paste irc links really :)
<NaCl>
hm. no ocamlbrowser in native windows
<NaCl>
flux: there's some urxvt magic for that
<NaCl>
if you use urxvt
<adrien>
needs tcl/tk, I guess that's really the issue
<NaCl>
* The graphical browser ocamlbrowser is not supported.
<thelema_>
hmm, errors compiling access.c related to R_OK, W_OK, X_OK, F_OK
<flux>
nacl, indeed I do
<flux>
nacl, need to check that out. actually I had hoped the cool scrollback search would've had that, but apparently not..
<flux>
(maybe it could be patched in)
<NaCl>
I don't know what it is, but I've heard some people talk about it before
<flux>
well you should've found out at that point! bah, people can be so inconsiderate!
<flux>
;-)
<adrien>
NaCl: oh, ok
<adrien>
I really plan to get some completion for vim
<hcarty>
adrien: ocamlspotter or a similar project has vim support files for that
<hcarty>
adrien: But last I saw they were provided as more of a starting example than a proper implementation.
<NaCl>
but adrien doesn't want to use ocamlspotter. :P
<adrien>
hcarty: would be a good starting point
<adrien>
NaCl: actually, I'd like to, but that you have to patch ocaml is annoying
<adrien>
I can probably try to improve godi's package
<hcarty>
adrien: Agreed
<hcarty>
adrien: I've been relying on vim's general completion
* NaCl
downloads TCL
<hcarty>
Something context sensitive would be cool
alang_ has quit [Quit: Ex-Chat]
iratsu has joined #ocaml
<hcarty>
ocaide may have some kind of context sensitive completion
<adrien>
hcarty: I'd like completion for use with lablgtk
<NaCl>
lulz
<hcarty>
adrien: A gross simplification of my experience with lablgtk is that it would make a wonderful base for a usable GUI library.
<adrien>
and there was a pretty nice plying for gtk in vim/emacs that automatically loaded the documentation for the class you were typing the name of, like GtkNo would show the documentation for GtkNotebook in a window that was always opened (pretty much a browser, it loaded another page)
<hcarty>
adrien: There are so many optional parameters that it's difficult to find your way around lablgtk.
<adrien>
I've been dealing with Qt, and I don't really like it
<NaCl>
Qt is more cooperative on MS windows
<adrien>
so I've become more gtk-friendly :P
<adrien>
NaCl: mostly because it's built as a huge monolith so it's hard to get something wrong when you download Qt+mingw as a single package
<NaCl>
adrien: of course, the opetional arguments could be avoided if you do it as C does
<NaCl>
which is call a ton of functions
<NaCl>
You may not expose the base programming language as a
<NaCl>
scripting language within your own application program to end users.
<adrien>
NaCl: right, and it's not necessarily better to use one or the other
<NaCl>
poo on you, ActiveState
<flux>
olasd, well, thanks. I need to copy paste that manually or through shell magic from logs, thuogh :)
<adrien>
NaCl: restrictions?
<NaCl>
yup
<adrien>
bah!
<NaCl>
this isn't really FOSS. xD
<adrien>
hmmm, actually, this might even be incompatible with labltk and/or the toplevel
<thelema_>
bah, mingw's unistd.h doesn't include what's needed for access.c, but its presence disables the workarounds there
<adrien>
what pissed me off with mingw.org is the outdated headers
<thelema_>
minimal headers, apparently.
<adrien>
I had tried to compile the bindings to windows functions and found out the headers were going up to IE 5.5 only!
<adrien>
mingw-w64(.sf.net) is going to have *much* more up-to-date headers
<adrien>
they actually have many win7-specific functions and things from wine and reactos
<thelema_>
hmm, where did I get mingw from...
<adrien>
mingw.org most probably ;-)
<adrien>
mingw-w64's triplet is usually i686-w64-mingw32 or x86_64-w64-mingw32(
<adrien>
(blame the binutils people for the bad names)
<thelema_>
you're right. I'll try the mingw-w64 version
<NaCl>
native, or mingw, that is the question
<adrien>
there's a bug opened (closed?) on the caml bug tracker about support for mingw-w64 btw, you might see some issues with it but get on irc (#mingw-w64 on oftc or their mailing-list/forums) and it should get fixed quite quickly if it's caused by mingw-w64
<adrien>
NaCl: mingw _is_ native
<thelema_>
:(
<thelema_>
it seems mingw-w64 is just GCC + headers + libs
<NaCl>
adrien: don't the resulting binaries depend on some mingw library?
<adrien>
when I say "some", I mean "3 issues one year ago"
<adrien>
thelema_: well, yeah. What do you want more?
<thelema_>
I guess I should really install cygwin as a base, and install mingw-w64 on top of that?
<adrien>
NaCl: no, cygwin has a heavy dependency on cygwin1.dll and mingw.org has a possible dependency on a quite small dll when using threading and mingw-w64 doesn't have this dependency anymore
<adrien>
thelema_: that'd work
<adrien>
thelema_: you can also get msys and install mingw-w64 on that
<NaCl>
adrien: orly?
<adrien>
but msys is, hmmm, I think "mostly horrible crap" is a right term
<adrien>
so cygwin is a good choice even if it's a bit slow at spawning executables (i.e. at emulating posix on an OS that doesn't help)
<adrien>
NaCl: pretty sure :-)
todun has joined #ocaml
munga has joined #ocaml
<NaCl>
adrien: mingw64 or mingw-w64?
<adrien>
mingw-w64
<adrien>
(which, of course, works very well on 32bit)
<NaCl>
thelema_: it's in install.exe
<NaCl>
setup.exe
iratsu has quit [Ping timeout: 255 seconds]
* thelema_
is installing a bunch of packages via cygwin's setup.exe, and has found the list of packages he should have installed in GODI's README
* NaCl
thinks that GODI could use a better UI
<hcarty>
NaCl: That's true. But it does have some nice command line tools if you want to avoid godi_console
<adrien>
I find it ok, but slow (I haven't been able to find my way through its makefile last time I tried to make it build as a native executable instead of bytecode [that's all that is required to make it work much faster])
<hcarty>
adrien: It's pretty easy ... "make opt" from the correct directory IIRC
<thelema_>
?? the patch 2.5.8-9 from cygwin cannot process unified patches?
<NaCl>
adrien: it reports as 64-bit, but the compiler seems to make 32-bit stuff
<adrien>
bobry: sorry, NaCl ^ ^
<bobry>
it's okay :)
<adrien>
long is 32bit on windows64
<thelema>
ok, what's the easiest way to plug ocaml's ./configure into the x86_64_w64-mingw32-gcc toolchain?
<thelema>
and why the rediculous prefix?
<NaCl>
adrien: there aren't any long longs either
<NaCl>
thelema: to disginguish from the other gcc's
<thelema>
paths?
<adrien>
NaCl: replace "long" by "uintptr_t" maybe line 30 of this file maybe
<NaCl>
adrien: no effect
<thelema>
huh, ocaml detects its architecture as neither big endian nor little endian. That's a new one for me.
jamii has quit [Ping timeout: 260 seconds]
<adrien>
thelema: the ridiculous prefix has been imposed by the binutils project after mingw-w64 asked for something different than i686-*pc*-mingw32, and the "32" from "mingw32" can't be dropped that easily because of compatibility (but it probably will be soon)
<adrien>
NaCl: and all references to "long" in the file?
<thelema>
adrien: thanks
todun has joined #ocaml
<NaCl>
worked
<adrien>
NaCl: \o/
<NaCl>
but what about long long?
<adrien>
thelema: replace "long" with "uintptr_t" in config/auto-aux/endian.c
<adrien>
long is 32bit on windows64
<adrien>
NaCl: long long where?
<NaCl>
long longs are 64
<thelema>
adrien: really? it said it had detected long long on my computer
<NaCl>
it did not detect them
<NaCl>
here, anyway
<NaCl>
neh, it found it
<thelema>
"./configure -cc x86-64-w64-mingw32-gcc" ... "64-bit "long long" integer type found (printf with %ll).
<NaCl>
yeah, worked for me
<adrien>
NaCl: long longs are 64, but even on 32bit architecures ;-)
<NaCl>
uh
<NaCl>
shouldn't this hit upstream?
<adrien>
it should, yes
<adrien>
need to get into a more type-friendly and can-see-top-of-the-screen (or move the browser address bar to bottom of the screen) position before I can check anything however
<thelema>
adrien: now it reported that something went wrong with endianness determination and that I'd get to figure out endianness myself
<thelema>
adrien: maybe I made a mistake changing that file
<adrien>
thelema: you'll need to prefix as and ld and all the other tools with the x86_64_w64...- prefix
<NaCl>
woohoo!
<NaCl>
shouldn't the host thing pick up on that?
<adrien>
thelema: global search-replace should work I think, I expect that's what NaCl did
<adrien>
thelema: you're with mingw without cygwin, you're supposed to call "make -f Makefile.nt"
<adrien>
and you have a few files with settings
<adrien>
NaCl: hard to do automatically: you have a "gcc" on the system too
<NaCl>
no I don't. :P
<thelema>
adrien: I don't have a gcc
<thelema>
just the crazy mingw-w64 thing
<NaCl>
sweet! no tcl/tk support
<adrien>
thelema: oh, and you're with cygwin actually
* adrien
slaps himself and wakes up
<adrien>
NaCl: might be a version issue
<NaCl>
adrien: it is from 2008
<NaCl>
but: the linker path seemes off
<NaCl>
s/linker/include/
<adrien>
thelema: that's why I like autotools, it gets the configuration right 99.999% of the time