Opened 12 years ago

Closed 12 years ago

#2202 closed defect (fixed)

No option to disable json-c lookup by ./configure

Reported by: mloskot Owned by: strk
Priority: medium Milestone: PostGIS 2.1.0
Component: build Version: master
Keywords: jsonc Cc:

Description

./configure provides only one option to control searching of json-c library files:

$ ./configure --help|grep json
  --with-jsondir=PATH     specify the json-c installation directory

Assuming json-c is optional, unlike PROJ.4 library, if one wants to build PostGIS without json-c support on a system with json-c library installed, then the ./configure always detects and adds json-c support.

There is no option like —without-jsonc or —disable-jsonc.

Attachments (1)

2202-json-lookup-configure-option.patch (5.0 KB ) - added by mloskot 12 years ago.
Patch that refactors json-c lookup to support —without option. It also implements Sandro's suggestion to rename the option to reflect json-c library name.

Download all attachments as: .zip

Change History (10)

by mloskot, 12 years ago

Patch that refactors json-c lookup to support —without option. It also implements Sandro's suggestion to rename the option to reflect json-c library name.

comment:1 by strk, 12 years ago

A vanilla ./configure bails out: configure: error: Cannot find json dev files in ""

It works fine without the patch

comment:2 by mloskot, 12 years ago

Owner: changed from strk to mloskot

This error is not making the json-c optional.

Currently, if I have json-c installed and I do not want to enable json-c support, the only way to achieve it is to uninstall json-c.

comment:3 by strk, 12 years ago

Milestone: PostGIS 2.0.3PostGIS 2.1.0

change in configure name goes to 2.1.0. If you come up with a working patch I'll apply. By working I mean that no switch enables it if available, —without disables it without complaining and —with complains if not found or uses from given path if found

comment:4 by mloskot, 12 years ago

Sandro, does any of the other switches for 3rd-party deps work the same way? Which one? So I will follow the patter exactly.

comment:5 by strk, 12 years ago

Owner: changed from mloskot to strk
Status: newassigned

I'm afraid none of the other switches work the way I described above. Taking a look at this now.

comment:6 by strk, 12 years ago

In r11144 (trunk) I added —without-json — the existing switch remained. See how you like it.

in reply to:  5 comment:7 by mloskot, 12 years ago

Replying to strk:

I'm afraid none of the other switches work the way I described above. Taking a look at this now.

Sandro, yes, that's what confused me. Thanks for fixing it anyway.

comment:8 by strk, 12 years ago

mloskot: tested ? can we close this ?

comment:9 by mloskot, 12 years ago

Resolution: fixed
Status: assignedclosed

Works for me.

Note: See TracTickets for help on using tickets.