From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id q0TD9Ah5017037 for ; Sun, 29 Jan 2012 14:09:11 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgQIAPNDJU97fTKGbmdsb2JhbABEhQupTSINCgoJEyaBcgEBBSMPAQUIAQE4DwkCGAICBRYLAgIJAwIBAgFFEwgBAYgBpgdqgzcBjSMHgS+HDgEHBAoDDAQDBAcYCQgagwsEAgoCFFxPggaBFohBhE5OjReNCA X-IronPort-AV: E=Sophos;i="4.71,587,1320620400"; d="scan'208";a="129285408" Received: from m50-134.163.com ([123.125.50.134]) by mail4-smtp-sop.national.inria.fr with ESMTP; 29 Jan 2012 14:09:03 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=Received:Message-ID:Date:From:User-Agent: MIME-Version:To:Subject:References:In-Reply-To:Content-Type: Content-Transfer-Encoding; bh=kj9QY8MmJNop34ejltVlNmtBr3vhmb0jIp iDQkqULCo=; b=hltLgZXEoSkl5olwtngVfvkqXaMPVOVHIdJy2hlqijkPN/BJg0 kFw1O+xpwgndwm9T7lIo3jN1rqKEEnAFXpko89hNCJVZLIOI7ciZ3+tJ5BqPbBbf MMpgIrF34FbNQTgCfhUIEc822QVCc8xcly9naxJObd0bePa+Idl78SWbw= Received: from [192.168.1.102] (unknown [222.208.14.82]) by smtp4 (Coremail) with SMTP id DtGowEDJF0_eRCVPyXXoBw--.56520S2; Sun, 29 Jan 2012 21:08:49 +0800 (CST) Message-ID: <4F254561.8030004@163.com> Date: Sun, 29 Jan 2012 21:10:57 +0800 From: Lin User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.17) Gecko/20110808 Thunderbird/3.1.10 MIME-Version: 1.0 To: caml-list@inria.fr References: <4F22D617.1080802@gmail.com> In-Reply-To: <4F22D617.1080802@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-CM-TRANSID: DtGowEDJF0_eRCVPyXXoBw--.56520S2 X-Coremail-Antispam: 1Uf129KBjvJXoW7tFy7AF13XFyfJF48Xr4xWFg_yoW8GrW5pF W3t39xur1rtryFyrW7K347urWrur4kJ3Wjvr1UWr4vqr1YkFn2qrWUKr40gFW2qry0yr4j yrW7A3y5XayUXFJanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07U-6pQUUUUU= X-CM-SenderInfo: xp1v00xzovqiywtou0bp/1tbiOR5Ebkjh+-iYVgAAsp Subject: Re: [Caml-list] deriving I have no Fedora machine at hand, but from the error message it seems to have something to do with camlp4. Do you have it installed correctly? Check if you have the camlp4 command by `which camlp4`. On 01/28/2012 12:51 AM, Matej Košík wrote: > Hi, > > I would like to play with / evaluate the "deriving" library: > http://code.google.com/p/deriving/wiki/Introduction > > How can I: > - create a Ocaml top-level where I can play with it? > - compile programs which take advantage of this library? > > I am on Fedora 16. > > What I have tried is this: > > $ sudo yum install ocaml-deriving-devel > $ rlwrap ocaml > # #use "topfind";; > # #require "deriving";; > No such package: %{camlp4} - Required by `deriving' > > I am not sure how to proceed. > > ------------------------------------------------ > > Concerning linking against this library, I have tried this: > > $ cat Main.ml > > let s = Show.show 3 > > $ ocamlc -I +deriving -pp "camlp4of -I `ocamlc -where`/deriving > nums.cma deriving.cma" deriving.cma Main.ml -o main > > File "ghost-location", line 7, characters 8--144: > Error: Unbound value Show.show > make: *** [main] Error 2 > > where "Main.ml" is supposed to be a program that uses syntactic sugar > provided by "deriving" library. > > What is the proper way to get things compiled? I have failed to find any > examples. > > Thanks in advance for the help. >