Skip to contentSkip to conversation

Build failure on FreeBSD-10.1-RELEASE

PATCH Tetsuya Mukawa 4 participants 7 messages Mar 2, 2015 – Mar 5, 2015 4 messages not in the archive

lore
Share & tools
lore
#0 lore raw

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +0 -0
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
"$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

#2 lore raw
In reply to a message not in the archive
Quoted 51 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
Quoted 6 lines

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

/Bruce

#3 lore raw
Quoted 55 lines · Bruce Richardson
Quoted 54 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Quoted 8 lines
Quoted 3 lines

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

/Bruce

Hi Bruce,

It seems we cannot use CONFIG_RTE_EXEC_ENV_LINUXAPP/BSDAPP definition here. Now I am looking for other way to check target OS.
Is it not so good to use $(T) definition value here?

Thanks,
Tetsuya

#5 lore raw
In reply to a message not in the archive

Hi Tetsuya, Hi Bruce,

Quoted 63 lines · Tetsuya Mukawa
Quoted 62 lines · Bruce Richardson
Quoted 51 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
  $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
         $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                 $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                 -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                 if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                         cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                 $(CPP) -undef -P -x assembler-with-cpp \
                  -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
Quoted 6 lines

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

Quoted 6 lines
Quoted 1 line

/Bruce

Hi Bruce,

It seems we cannot use CONFIG_RTE_EXEC_ENV_LINUXAPP/BSDAPP definition here. Now I am looking for other way to check target OS.
Is it not so good to use $(T) definition value here?

Indeed, it seems that the -fdirectives-only option does not exist in freebsd. This is probably because the default cpp is not GNU cpp:

On my version, I have:
FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
Target: x86_64-unknown-freebsd10.0
Thread model: posix

To decide whether using the option, we could check the return value of cpp -fdirectives-only /dev/null > /dev/null 2>/dev/null

But I don't really think it's an issue to remove the option for all OSes. In my opinion, expanding macros when parsing the config files won't add any issue, and it's probably better to have no differences between FreeBSD and Linux.

Regards,
Olivier

#7 lore raw
In reply to a message not in the archive
Quoted 84 lines · Olivier MATZ

Hi Tetsuya, Hi Bruce,

Quoted 63 lines · Tetsuya Mukawa
Quoted 62 lines · Bruce Richardson
Quoted 51 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
Quoted 6 lines

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

Quoted 6 lines
Quoted 1 line

/Bruce

Hi Bruce,

It seems we cannot use CONFIG_RTE_EXEC_ENV_LINUXAPP/BSDAPP definition here. Now I am looking for other way to check target OS.
Is it not so good to use $(T) definition value here?

Indeed, it seems that the -fdirectives-only option does not exist in freebsd. This is probably because the default cpp is not GNU cpp:

On my version, I have:
FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
Target: x86_64-unknown-freebsd10.0
Thread model: posix

To decide whether using the option, we could check the return value of cpp -fdirectives-only /dev/null > /dev/null 2>/dev/null

Quoted 8 lines

But I don't really think it's an issue to remove the option for all OSes. In my opinion, expanding macros when parsing the config files won't add any issue, and it's probably better to have no differences between FreeBSD and Linux.

Regards,
Olivier

+1
I was just going to suggest that this morning! :-)

#8 lore raw
Quoted 76 lines · Bruce Richardson
Quoted 75 lines · Olivier MATZ

Hi Tetsuya, Hi Bruce,

Quoted 63 lines · Tetsuya Mukawa
Quoted 62 lines · Bruce Richardson
Quoted 51 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
Quoted 6 lines

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

Quoted 6 lines
Quoted 1 line

/Bruce

Hi Bruce,

It seems we cannot use CONFIG_RTE_EXEC_ENV_LINUXAPP/BSDAPP definition here. Now I am looking for other way to check target OS.
Is it not so good to use $(T) definition value here?

Indeed, it seems that the -fdirectives-only option does not exist in freebsd. This is probably because the default cpp is not GNU cpp:

Quoted 7 lines
Quoted 7 lines

On my version, I have:
FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
Target: x86_64-unknown-freebsd10.0
Thread model: posix

To decide whether using the option, we could check the return value of cpp -fdirectives-only /dev/null > /dev/null 2>/dev/null

It’s a great idea.

Quoted 10 lines
Quoted 8 lines

But I don't really think it's an issue to remove the option for all OSes. In my opinion, expanding macros when parsing the config files won't add any issue, and it's probably better to have no differences between FreeBSD and Linux.

Regards,
Olivier

+1
I was just going to suggest that this morning! :-)

Thanks for suggestions.
I will send a patch that just removes '-fdirectives-only'.

Thanks,
Tetsuya

#10 lore raw
In reply to a message not in the archive

2015-03-05 16:08, Tetsuya Mukawa:

Quoted 92 lines · Bruce Richardson
Quoted 76 lines · Olivier MATZ
Quoted 75 lines

Hi Tetsuya, Hi Bruce,

Quoted 63 lines · Tetsuya Mukawa
Quoted 62 lines · Bruce Richardson
Quoted 51 lines · Tetsuya Mukawa

Hi,

I got a error while building master branch on FreeBSD. Here is a log.

$ gmake T=x86_64-native-bsdapp-clang config
cc: error: unknown argument: '-fdirectives-only'
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
cp: /usr/home/mukawa/work/dpdk/build/.config_tmp: No such file or directory
gmake[3]: Nothing to be done for 'depdirs'.
Configuration done

Here is log came from 'uname'

$ uname -a
FreeBSD eris.hq.igel.co.jp 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401:
Tue Nov 11 21:02:49 UTC 2014

I've tried to remove '-fdirectives-only' from mk/rte.sdkconfig.mk like below.
With the fixing, It seems I can compile and run testpmd. (Obviously, we should not merge below patch, but I've done just for testing)

mk/rte.sdkconfig.mk +1 -1
index d43c430..f8d95b1 100644
@@ -75,7 +75,7 @@ else
 $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT)
        $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f
 "$(RTE_CONFIG_TEMPLATE)" ]; then \
                $(CPP) -undef -P -x assembler-with-cpp \
-               -fdirectives-only -ffreestanding \
+               -ffreestanding \
                -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
                if ! cmp -s $(RTE_OUTPUT)/.config_tmp
$(RTE_OUTPUT)/.config; then \
                        cp $(RTE_OUTPUT)/.config_tmp

$(RTE_OUTPUT)/.config ; \

Also, I've checked /usr/ports/net/dpdk, and found below line. (It seems above ports dpdk package is based on DPDK-1.8.)

                $(CPP) -undef -P -x assembler-with-cpp \
                 -ffreestanding \
               -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \
Quoted 6 lines

So, I guess we should not add '-fdirectives-only' for flags of $(CPP) for BSD system like dpdk package of ports.

Thanks,
Tetsuya

Yes, that is correct. In most cases I have tested, the extra flag only gives a warning but it appears its now an error. We should conditionally include or omit the flag for BSD vs Linux, I think.

Quoted 6 lines
Quoted 1 line

/Bruce

Hi Bruce,

It seems we cannot use CONFIG_RTE_EXEC_ENV_LINUXAPP/BSDAPP definition here. Now I am looking for other way to check target OS.
Is it not so good to use $(T) definition value here?

Indeed, it seems that the -fdirectives-only option does not exist in freebsd. This is probably because the default cpp is not GNU cpp:

Quoted 7 lines
Quoted 7 lines

On my version, I have:
FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
Target: x86_64-unknown-freebsd10.0
Thread model: posix

To decide whether using the option, we could check the return value of cpp -fdirectives-only /dev/null > /dev/null 2>/dev/null

It’s a great idea.

Quoted 5 lines
Quoted 5 lines

But I don't really think it's an issue to remove the option for all OSes. In my opinion, expanding macros when parsing the config files won't add any issue, and it's probably better to have no differences between FreeBSD and Linux.

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Regards,
Olivier

+1
I was just going to suggest that this morning! :-)

Thanks for suggestions.
I will send a patch that just removes '-fdirectives-only'.

Fixed in http://dpdk.org/browse/dpdk/commit/?id=64702e5f6ff68bff
Thanks