pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Assistance Needed: Error during PostgreSQL Configuration
7+ messages / 4 participants
[nested] [flat]

* Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-10 13:16  Ayush Vatsa <ayushvatsa1810@gmail.com>
  0 siblings, 1 reply; 7+ messages in thread

From: Ayush Vatsa @ 2023-12-10 13:16 UTC (permalink / raw)
  To: pgsql-general@lists.postgresql.org

Hello, PostgreSQL community,
I'm reaching out to you about an issue I've had while trying to configure
PostgreSQL by cloning its files from the GitHub repository.
During the configuration process, I encountered an error message that
appeared to be related to a syntax issue within the 'config.status' file.
Specifically, the error message reads as follows:
./config.status: line 486: syntax error near unexpected token `)'
./config.status: line 486: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed
"s/'/'\\\\\\\\''/g"` ;;'
I have tried to resolve this on my own, but unfortunately, I haven't been
successful in finding a solution.
Could you please provide guidance or assistance in resolving this issue? I
would appreciate any insights or suggestions you have to help me move past
this obstacle.
Looking forward to your response.

Thanks
Ayush Vatsa
SDE Amazon

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-11 11:57  Ian Lawrence Barwick <barwick@gmail.com>
  parent: Ayush Vatsa <ayushvatsa1810@gmail.com>
  0 siblings, 1 reply; 7+ messages in thread

From: Ian Lawrence Barwick @ 2023-12-11 11:57 UTC (permalink / raw)
  To: Ayush Vatsa <ayushvatsa1810@gmail.com>; +Cc: pgsql-general@lists.postgresql.org

2023年12月11日(月) 18:09 Ayush Vatsa <ayushvatsa1810@gmail.com>:
>
> Hello, PostgreSQL community,
> I'm reaching out to you about an issue I've had while trying to configure PostgreSQL by cloning its files from the GitHub repository.
> During the configuration process, I encountered an error message that appeared to be related to a syntax issue within the 'config.status' file.

FWIW 'config.status' is the log file generated by 'configure'.

> Specifically, the error message reads as follows:
> ./config.status: line 486: syntax error near unexpected token `)'
> ./config.status: line 486: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;'
> I have tried to resolve this on my own, but unfortunately, I haven't been successful in finding a solution.
> Could you please provide guidance or assistance in resolving this issue? I would appreciate any insights or suggestions you have to help me move past this obstacle.
> Looking forward to your response.

You should provide, at the very least, the following information:
- the PostgreSQL version you are trying to build
- the environment you are trying to build it in

A very hand-wavy guess, but possibly your local "sed" installation is
not GNU sed?

Regards

Ian Barwick





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-11 14:50  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Ian Lawrence Barwick <barwick@gmail.com>
  0 siblings, 1 reply; 7+ messages in thread

From: Tom Lane @ 2023-12-11 14:50 UTC (permalink / raw)
  To: Ian Lawrence Barwick <barwick@gmail.com>; +Cc: Ayush Vatsa <ayushvatsa1810@gmail.com>; pgsql-general@lists.postgresql.org

Ian Lawrence Barwick <barwick@gmail.com> writes:
> 2023年12月11日(月) 18:09 Ayush Vatsa <ayushvatsa1810@gmail.com>:
>> ./config.status: line 486: syntax error near unexpected token `)'
>> ./config.status: line 486: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;'

> You should provide, at the very least, the following information:
> - the PostgreSQL version you are trying to build
> - the environment you are trying to build it in

+1

> A very hand-wavy guess, but possibly your local "sed" installation is
> not GNU sed?

I'm also wondering if the shell in use is nonstandard.  The configure
script would likely already have failed if you tried to run it with,
say, csh; but maybe more-subtly-incompatible shells could give rise
to this symptom.

			regards, tom lane





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-11 17:17  Ayush Vatsa <ayushvatsa1810@gmail.com>
  parent: Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 2 replies; 7+ messages in thread

From: Ayush Vatsa @ 2023-12-11 17:17 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: Ian Lawrence Barwick <barwick@gmail.com>; pgsql-general@lists.postgresql.org

Hi,
Sorry, I should have included the required information initially itself. I
am new to the database field so please pardon my mistakes :)
What I have done till now is clone the source code files from Gihub in my
Mac laptop and then try to follow this documentation
<https://www.postgresql.org/docs/current/install-make.html;, then I got an
error posted in the mail in the very first step itself i.e. ./configure
command.

The PostgreSQL version is the latest (i.e. 16) as I have cloned the source
code from GitHub.
I have tried using both shells including zsh and bash here but same response
For sed, I am using GNU sed and also included this GNU sed in the PATH
variable

ayuvatsa@bcd0745f2da7 ~ % sed --version

sed (GNU sed) 4.9


The configure script runs fine till the step given below:

configure: using CPPFLAGS=-isysroot $(PG_SYSROOT)

configure: using LDFLAGS=-isysroot $(PG_SYSROOT)   -Wl,-dead_strip_dylibs

configure: creating ./config.status

Thanks
Ayush Vatsa

On Mon, 11 Dec 2023 at 20:20, Tom Lane <tgl@sss.pgh.pa.us> wrote:

> Ian Lawrence Barwick <barwick@gmail.com> writes:
> > 2023年12月11日(月) 18:09 Ayush Vatsa <ayushvatsa1810@gmail.com>:
> >> ./config.status: line 486: syntax error near unexpected token `)'
> >> ./config.status: line 486: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" |
> sed "s/'/'\\\\\\\\''/g"` ;;'
>
> > You should provide, at the very least, the following information:
> > - the PostgreSQL version you are trying to build
> > - the environment you are trying to build it in
>
> +1
>
> > A very hand-wavy guess, but possibly your local "sed" installation is
> > not GNU sed?
>
> I'm also wondering if the shell in use is nonstandard.  The configure
> script would likely already have failed if you tried to run it with,
> say, csh; but maybe more-subtly-incompatible shells could give rise
> to this symptom.
>
>                         regards, tom lane
>

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-12 16:38  Ron Johnson <ronljohnsonjr@gmail.com>
  parent: Ayush Vatsa <ayushvatsa1810@gmail.com>
  1 sibling, 0 replies; 7+ messages in thread

From: Ron Johnson @ 2023-12-12 16:38 UTC (permalink / raw)
  To: Ayush Vatsa <ayushvatsa1810@gmail.com>; +Cc: Tom Lane <tgl@sss.pgh.pa.us>; Ian Lawrence Barwick <barwick@gmail.com>; pgsql-general@lists.postgresql.org

On Tue, Dec 12, 2023 at 11:02 AM Ayush Vatsa <ayushvatsa1810@gmail.com>
wrote:

> Hi,
> Sorry, I should have included the required information initially itself. I
> am new to the database field so please pardon my mistakes
>

Why are you building from source instead of using a packaged solution?
https://www.postgresql.org/download/macosx/

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-12 16:40  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Ayush Vatsa <ayushvatsa1810@gmail.com>
  1 sibling, 1 reply; 7+ messages in thread

From: Tom Lane @ 2023-12-12 16:40 UTC (permalink / raw)
  To: Ayush Vatsa <ayushvatsa1810@gmail.com>; +Cc: Ian Lawrence Barwick <barwick@gmail.com>; pgsql-general@lists.postgresql.org

Ayush Vatsa <ayushvatsa1810@gmail.com> writes:
> Sorry, I should have included the required information initially itself. I
> am new to the database field so please pardon my mistakes :)

You still didn't mention the platform/environment, but I guess from
the reference to -isysroot that it must be macOS (Darwin).  I further
guess that you're using Homebrew or MacPorts, because bare macOS
doesn't supply GNU sed.  That doesn't get us much further though;
plenty of Postgres developers use one or the other of those setups
without difficulty.

One idea that comes to mind is that you might be trying to build in
a directory path that contains spaces or other odd characters.
That's generally not well supported by Unix-based tooling.
However, I'm not sure how that'd lead to this particular failure.

The only other idea I have is that maybe you have some weird
Homebrew or MacPorts package installed that changes the behavior
of your shell.  I have no idea what that would be though.

FWIW, on my own Mac laptop, line 486 in config.status in a
current build looks like

    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;

which seems identical to what you reported.  So that takes some
steam out of the idea that the file was generated incorrectly
in your build, pointing more to the idea that your shell is not
reading it as-expected.

			regards, tom lane





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: Assistance Needed: Error during PostgreSQL Configuration
@ 2023-12-12 17:55  Ayush Vatsa <ayushvatsa1810@gmail.com>
  parent: Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 7+ messages in thread

From: Ayush Vatsa @ 2023-12-12 17:55 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; ronljohnsonjr@gmail.com; +Cc: Ian Lawrence Barwick <barwick@gmail.com>; pgsql-general@lists.postgresql.org

Hi all,
@Ron Johnson, I am building from the source because I wanted to contribute
to the open-source community, and for that, I want the source files. I had
a few things in mind currently for the same :).
@Tom Lane <tgl@sss.pgh.pa.us>, Thanks I am using a directory path with
spaces in it, and removing them solved my issue. Next time I will use '_'
in paths to be on the safer side.

Thanks and regards
Ayush Vatsa
SDE Amazon

On Tue, 12 Dec 2023 at 22:10, Tom Lane <tgl@sss.pgh.pa.us> wrote:

> Ayush Vatsa <ayushvatsa1810@gmail.com> writes:
> > Sorry, I should have included the required information initially itself.
> I
> > am new to the database field so please pardon my mistakes :)
>
> You still didn't mention the platform/environment, but I guess from
> the reference to -isysroot that it must be macOS (Darwin).  I further
> guess that you're using Homebrew or MacPorts, because bare macOS
> doesn't supply GNU sed.  That doesn't get us much further though;
> plenty of Postgres developers use one or the other of those setups
> without difficulty.
>
> One idea that comes to mind is that you might be trying to build in
> a directory path that contains spaces or other odd characters.
> That's generally not well supported by Unix-based tooling.
> However, I'm not sure how that'd lead to this particular failure.
>
> The only other idea I have is that maybe you have some weird
> Homebrew or MacPorts package installed that changes the behavior
> of your shell.  I have no idea what that would be though.
>
> FWIW, on my own Mac laptop, line 486 in config.status in a
> current build looks like
>
>     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
>
> which seems identical to what you reported.  So that takes some
> steam out of the idea that the file was generated incorrectly
> in your build, pointing more to the idea that your shell is not
> reading it as-expected.
>
>                         regards, tom lane
>

^ permalink  raw  reply  [nested|flat] 7+ messages in thread


end of thread, other threads:[~2023-12-12 17:55 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2023-12-10 13:16 Assistance Needed: Error during PostgreSQL Configuration Ayush Vatsa <ayushvatsa1810@gmail.com>
2023-12-11 11:57 ` Ian Lawrence Barwick <barwick@gmail.com>
2023-12-11 14:50   ` Tom Lane <tgl@sss.pgh.pa.us>
2023-12-11 17:17     ` Ayush Vatsa <ayushvatsa1810@gmail.com>
2023-12-12 16:38       ` Ron Johnson <ronljohnsonjr@gmail.com>
2023-12-12 16:40       ` Tom Lane <tgl@sss.pgh.pa.us>
2023-12-12 17:55         ` Ayush Vatsa <ayushvatsa1810@gmail.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox