Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id D47CD200CF2 for ; Tue, 8 Aug 2017 17:36:06 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D2D5D167758; Tue, 8 Aug 2017 15:36:06 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 23458167756 for ; Tue, 8 Aug 2017 17:36:05 +0200 (CEST) Received: (qmail 31421 invoked by uid 500); 8 Aug 2017 15:36:05 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 31402 invoked by uid 99); 8 Aug 2017 15:36:04 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Aug 2017 15:36:04 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 5A7EA1A02DE for ; Tue, 8 Aug 2017 15:36:04 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id VXI9sQTkb8rv for ; Tue, 8 Aug 2017 15:36:03 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id DE0425FB3A for ; Tue, 8 Aug 2017 15:36:02 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 63AD8E0E1B for ; Tue, 8 Aug 2017 15:36:01 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 8426F24185 for ; Tue, 8 Aug 2017 15:36:00 +0000 (UTC) Date: Tue, 8 Aug 2017 15:36:00 +0000 (UTC) From: "James Clampffer (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HDFS-12276) libhdfs++: uri parser has clang warnings that break external projects MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Tue, 08 Aug 2017 15:36:07 -0000 [ https://issues.apache.org/jira/browse/HDFS-12276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16118479#comment-16118479 ] James Clampffer commented on HDFS-12276: ---------------------------------------- Nice catch [~anatoli.shein]. It should be sufficient to just add a virtual destructor and define it in one of the .cc files to force a vtable to be instantiated in a single compilation unit. The linker will generally be smart enough to fix this in the same way it can fold generated code for "inline" qualified functions together as an optimization pass but I don't know if clang does by default. I think there's a couple ways to prevent, or at least deal with, these issues in the future: -Find a covering set of all the warnings used by Hadoop related projects like orc, parquet, and arrow (and plenty of others). Then use them in this library. This is always going to be a step behind of anything being added to those libraries. -You can always switch back to a more permissive build for third-party libs for other projects. That's the approach we've taken with the things libhdfs++ depends on; this isn't really a bug in the library as much as it's a difference in how permissive the build should be. > libhdfs++: uri parser has clang warnings that break external projects > --------------------------------------------------------------------- > > Key: HDFS-12276 > URL: https://issues.apache.org/jira/browse/HDFS-12276 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: hdfs-client > Reporter: Anatoli Shein > > When trying to do a clang build of libhdfs++ as part of the ORC project I get some warnings that are treated as errors: > In file included from /home/travis/build/apache/orc/c++/libs/libhdfspp/include/hdfspp/options.h:21: > /home/travis/build/apache/orc/c++/libs/libhdfspp/include/hdfspp/uri.h:30:7: error: 'uri_parse_error' has no out-of-line virtual method definitions; its vtable will be emitted in every translation unit [-Werror,-Wweak-vtables] > class uri_parse_error : public std::invalid_argument { > ^ > 2 errors generated. > These should be fixed. -- This message was sent by Atlassian JIRA (v6.4.14#64029) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org