Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

oniguruma.h can't find, what this header-file used for ? #534

Closed
b08060514 opened this issue Aug 6, 2014 · 10 comments
Closed

oniguruma.h can't find, what this header-file used for ? #534

b08060514 opened this issue Aug 6, 2014 · 10 comments

Comments

@b08060514
Copy link

when ./configure, it happend :

checking for oniguruma.h... not found
configure: Oniguruma was not found.
configure:  Try setting the location using '--with-oniguruma=PREFIX' 
configure: error:  oniguruma is required to build jq.
/* confdefs.h.  */
#define PACKAGE_NAME "jq"
#define PACKAGE_TARNAME "jq"
#define PACKAGE_VERSION "1.5.0"
#define PACKAGE_STRING "jq 1.5.0"
#define PACKAGE_BUGREPORT "mu@netsoc.tcd.ie"
#define PACKAGE "jq"
#define VERSION "1.5.0"
#define STDC_HEADERS 1
#define HAVE_SYS_TYPES_H 1
#define HAVE_SYS_STAT_H 1
#define HAVE_STDLIB_H 1
#define HAVE_STRING_H 1
#define HAVE_MEMORY_H 1
#define HAVE_STRINGS_H 1
#define HAVE_INTTYPES_H 1
#define HAVE_STDINT_H 1
#define HAVE_UNISTD_H 1
#define HAVE_DLFCN_H 1
#define LT_OBJDIR ".libs/"
#define YYTEXT_POINTER 1
/* end confdefs.h.  */
 #include <oniguruma.h>
int
main ()
{

  ;
  return 0;
}

#include <oniguruma.h> what this head-file is used for? and how to fix this problem ?

Best regards

@b08060514
Copy link
Author

I can find this oniguruma.h in ~/.rvm/src/ruby-1.9.3-p547/include/ruby/ directory,
and i reexec ./configure --with-oniguruma=/home/b080605/.rvm/src/ruby-1.9.3-p547, it happened:

configure:13115: checking for oniguruma.h
configure:13129: gcc -std=gnu99 -c  -g -O2 -I/home/b080605/.rvm/src/ruby-1.9.3-p547/include -I/home/b080605/.rvm/src/ruby-1.9.3-p547/include/ruby  conftest.c >&5
In file included from conftest.c:23:0:
/home/b080605/.rvm/src/ruby-1.9.3-p547/include/ruby/oniguruma.h:113:1: error: unknown type name 'size_t'
 typedef size_t         OnigDistance;
 ^
configure:13129: $? = 1

Did i got a wrong oniguruma.h, or something else ?

I am tring to involve in your project, but it seams it's a long way to go. ==||
I need you help, please.

Best regards.

@b08060514 b08060514 reopened this Aug 6, 2014
@wtlangford
Copy link
Contributor

What operating system are you using? You need the onigiruma development
headers.
The package is usually either oniguruma-dev or oniguruma-devel.
On Aug 6, 2014 9:38 AM, "b08060514" notifications@github.com wrote:

Reopened #534 #534.


Reply to this email directly or view it on GitHub
#534 (comment).

@pannous
Copy link

pannous commented Aug 6, 2014

try:
brew install -vvv oniguruma
./configure --with-oniguruma=/usr/local/Cellar/oniguruma/5.9.5/

@wtlangford
Copy link
Contributor

@pannous I'd use ./configure --with-oniguruma=$(brew --prefix oniguruma), personally. Just a bit safer.

@pkoppstein
Copy link
Contributor

@wtlangford - I'm not sure how easy it is to find instructions for installing jq1.4+. Would it make sense to add information such as the suggestion you offered above to the Installation section of the FAQ? I'd be happy to do this myself but I'm not sure what "recipes" to offer for non-Mac environments.

@b08060514
Copy link
Author

Thanks all of you, i had fix it.

@wtlangford - My system is Ubuntu
$ uname -a Linux XXXXXXX 3.11.0-26-generic #45-Ubuntu SMP Tue Jul 15 04:02:06 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
There may be no onigiruma package on Ubuntu or my source, so i refered to the Installation section of the FAQ as @pkoppstein told, and downloaded it form http://www.geocities.jp/kosako3/oniguruma, then this problem fixed.

I can move on now.
thanks all of u again.

@pkoppstein
Copy link
Contributor

Could someone please verify that libonig2 is what's needed on ubuntu?

@liaowang11
Copy link

libonig-dev is what's needed on ubuntu.

@textarcana
Copy link

I just got done compiling jq on Mac OSX, thought I'd share what I had to do. Note I use MacPorts not HomeBrew so if that's different for you then you may need compile fewer / more things from source.

Install Bison 3:

cd /tmp
wget http://ftp.gnu.org/gnu/bison/bison-3.0.3.tar.gz
tar -xvzf bison-3.0.3.tar.gz
cd bison-3.0.3
sudo port install m4
./configure --prefix=/usr/local/bison
sudo make install
sudo ln -s /usr/local/bison/bin/bison /usr/bin/bison

Install RVM dependencies:

cd ~/jq/docs
curl -L https://get.rvm.io | bash -s stable --ruby=1.9.3
cd docs
bundle install

Install C headers

wget http://www.geocities.jp/kosako3/oniguruma/archive/onig-5.9.6.tar.gz
tar -xf onig-5.9.6.tar.gz
cd onig-5.9.6
./configure
make
sudo make install

Build jq

cd ~/jq
autoreconf -i
./configure
make -j8
sudo make install

@pkoppstein
Copy link
Contributor

@textarcana - Thanks for the "recipe", which I have incorporated into a new page on the jq wiki: https://github.com/stedolan/jq/wiki/Installation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants