list = new LinkedList<>();
+
+ synchronized (sessionHistoryLock) {
+ for (Session session : sessionHistoryList) {
+ if (session.isMediaInformation()) {
+ list.add((MediaInformationSession) session);
+ }
+ }
+ }
+
+ return list;
+ }
+
/**
* Returns sessions that have the given state.
*
@@ -1124,6 +1278,16 @@ public class FFmpegKitConfig {
FFmpegKitConfig.globalLogRedirectionStrategy = logRedirectionStrategy;
}
+ /**
+ * Converts session state to string.
+ *
+ * @param state session state
+ * @return string value
+ */
+ public static String sessionStateToString(final SessionState state) {
+ return state.toString();
+ }
+
/**
*
Parses the given command into arguments. Uses space character to split the arguments.
* Supports single and double quote characters.
@@ -1265,7 +1429,7 @@ public class FFmpegKitConfig {
native static int nativeFFprobeExecute(final long sessionId, final String[] arguments);
/**
- *
Cancels an ongoing FFmpeg operation natively. This function does not wait for termination
+ *
Cancels an ongoing FFmpeg operation natively. This method does not wait for termination
* to complete and returns immediately.
*
* @param sessionId id of the session
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSession.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSession.java
index 28e7ada..ca7d105 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSession.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSession.java
@@ -28,10 +28,15 @@ import java.util.List;
public class FFmpegSession extends AbstractSession implements Session {
/**
- * Session specific statistics callback function.
+ * Session specific statistics callback.
*/
private final StatisticsCallback statisticsCallback;
+ /**
+ * Session specific complete callback.
+ */
+ private final FFmpegSessionCompleteCallback completeCallback;
+
/**
* Statistics entries received for this session.
*/
@@ -54,44 +59,45 @@ public class FFmpegSession extends AbstractSession implements Session {
/**
* Builds a new FFmpeg session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback function
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
- public FFmpegSession(final String[] arguments, final ExecuteCallback executeCallback) {
- this(arguments, executeCallback, null, null);
+ public FFmpegSession(final String[] arguments, final FFmpegSessionCompleteCallback completeCallback) {
+ this(arguments, completeCallback, null, null);
}
/**
* Builds a new FFmpeg session.
*
* @param arguments command arguments
- * @param executeCallback session specific execute callback function
- * @param logCallback session specific log callback function
- * @param statisticsCallback session specific statistics callback function
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
+ * @param statisticsCallback session specific statistics callback
*/
public FFmpegSession(final String[] arguments,
- final ExecuteCallback executeCallback,
+ final FFmpegSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final StatisticsCallback statisticsCallback) {
- this(arguments, executeCallback, logCallback, statisticsCallback, FFmpegKitConfig.getLogRedirectionStrategy());
+ this(arguments, completeCallback, logCallback, statisticsCallback, FFmpegKitConfig.getLogRedirectionStrategy());
}
/**
* Builds a new FFmpeg session.
*
* @param arguments command arguments
- * @param executeCallback session specific execute callback function
- * @param logCallback session specific log callback function
- * @param statisticsCallback session specific statistics callback function
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
+ * @param statisticsCallback session specific statistics callback
* @param logRedirectionStrategy session specific log redirection strategy
*/
public FFmpegSession(final String[] arguments,
- final ExecuteCallback executeCallback,
+ final FFmpegSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final StatisticsCallback statisticsCallback,
final LogRedirectionStrategy logRedirectionStrategy) {
- super(arguments, executeCallback, logCallback, logRedirectionStrategy);
+ super(arguments, logCallback, logRedirectionStrategy);
+ this.completeCallback = completeCallback;
this.statisticsCallback = statisticsCallback;
this.statistics = new LinkedList<>();
@@ -99,14 +105,23 @@ public class FFmpegSession extends AbstractSession implements Session {
}
/**
- * Returns the session specific statistics callback function.
+ * Returns the session specific statistics callback.
*
- * @return session specific statistics callback function
+ * @return session specific statistics callback
*/
public StatisticsCallback getStatisticsCallback() {
return statisticsCallback;
}
+ /**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+ public FFmpegSessionCompleteCallback getCompleteCallback() {
+ return completeCallback;
+ }
+
/**
* Returns all statistics entries generated for this session. If there are asynchronous
* messages that are not delivered yet, this method waits for them until the given timeout.
@@ -165,7 +180,8 @@ public class FFmpegSession extends AbstractSession implements Session {
}
/**
- * Adds a new statistics entry for this session.
+ * Adds a new statistics entry for this session. It is invoked internally by
+ * FFmpegKit
library methods. Must not be used by user applications.
*
* @param statistics statistics entry
*/
@@ -185,6 +201,11 @@ public class FFmpegSession extends AbstractSession implements Session {
return false;
}
+ @Override
+ public boolean isMediaInformation() {
+ return false;
+ }
+
@Override
public String toString() {
final StringBuilder stringBuilder = new StringBuilder();
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSessionCompleteCallback.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSessionCompleteCallback.java
new file mode 100644
index 0000000..98dd9de
--- /dev/null
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFmpegSessionCompleteCallback.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2018-2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+package com.arthenica.ffmpegkit;
+
+/**
+ *
Callback function that is invoked when an asynchronous FFmpeg
session has ended.
+ */
+@FunctionalInterface
+public interface FFmpegSessionCompleteCallback {
+
+ /**
+ *
Called when an FFmpeg session has ended.
+ *
+ * @param session FFmpeg session
+ */
+ void apply(final FFmpegSession session);
+
+}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeKit.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeKit.java
index 3db4611..d64c0d5 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeKit.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeKit.java
@@ -23,16 +23,16 @@ import java.util.List;
import java.util.concurrent.ExecutorService;
/**
- *
Main class to run FFprobe
commands. Supports executing commands both synchronously and
- * asynchronously.
+ *
Main class to run FFprobe
commands. Supports executing commands both
+ * synchronously and asynchronously.
*
* FFprobeSession session = FFprobeKit.execute("-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4");
*
- * FFprobeSession asyncSession = FFprobeKit.executeAsync("-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4", executeCallback);
+ * FFprobeSession asyncSession = FFprobeKit.executeAsync("-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4", completeCallback);
*
* Provides overloaded execute
methods to define session specific callbacks.
*
- * FFprobeSession session = FFprobeKit.executeAsync("-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4", executeCallback, logCallback);
+ * FFprobeSession session = FFprobeKit.executeAsync("-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4", completeCallback, logCallback);
*
* It can extract media information for a file or a url, using {@link #getMediaInformation(String)} method.
*
@@ -52,13 +52,23 @@ public class FFprobeKit {
private FFprobeKit() {
}
+ /**
+ * Builds the default command used to get media information for a file.
+ *
+ * @param path file path to use in the command
+ * @return default command arguments to get media information
+ */
+ private static String[] defaultGetMediaInformationCommandArguments(final String path) {
+ return new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-show_chapters", "-i", path};
+ }
+
/**
*
Synchronously executes FFprobe with arguments provided.
*
* @param arguments FFprobe command options/arguments as string array
* @return FFprobe session created for this execution
*/
- public static FFprobeSession execute(final String[] arguments) {
+ public static FFprobeSession executeWithArguments(final String[] arguments) {
final FFprobeSession session = new FFprobeSession(arguments);
FFmpegKitConfig.ffprobeExecute(session);
@@ -69,16 +79,17 @@ public class FFprobeKit {
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFprobe session created for this execution
*/
- public static FFprobeSession executeAsync(final String[] arguments,
- final ExecuteCallback executeCallback) {
- final FFprobeSession session = new FFprobeSession(arguments, executeCallback);
+ public static FFprobeSession executeWithArgumentsAsync(final String[] arguments,
+ final FFprobeSessionCompleteCallback completeCallback) {
+ final FFprobeSession session = new FFprobeSession(arguments, completeCallback);
FFmpegKitConfig.asyncFFprobeExecute(session);
@@ -88,18 +99,19 @@ public class FFprobeKit {
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
* @return FFprobe session created for this execution
*/
- public static FFprobeSession executeAsync(final String[] arguments,
- final ExecuteCallback executeCallback,
- final LogCallback logCallback) {
- final FFprobeSession session = new FFprobeSession(arguments, executeCallback, logCallback);
+ public static FFprobeSession executeWithArgumentsAsync(final String[] arguments,
+ final FFprobeSessionCompleteCallback completeCallback,
+ final LogCallback logCallback) {
+ final FFprobeSession session = new FFprobeSession(arguments, completeCallback, logCallback);
FFmpegKitConfig.asyncFFprobeExecute(session);
@@ -109,18 +121,19 @@ public class FFprobeKit {
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
- * @param executorService executor service that will be used to run this asynchronous operation
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param executorService executor service that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
- public static FFprobeSession executeAsync(final String[] arguments,
- final ExecuteCallback executeCallback,
- final ExecutorService executorService) {
- final FFprobeSession session = new FFprobeSession(arguments, executeCallback);
+ public static FFprobeSession executeWithArgumentsAsync(final String[] arguments,
+ final FFprobeSessionCompleteCallback completeCallback,
+ final ExecutorService executorService) {
+ final FFprobeSession session = new FFprobeSession(arguments, completeCallback);
FFmpegKitConfig.asyncFFprobeExecute(session, executorService);
@@ -130,20 +143,21 @@ public class FFprobeKit {
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param executorService executor service that will be used to run this asynchronous operation
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param executorService executor service that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
- public static FFprobeSession executeAsync(final String[] arguments,
- final ExecuteCallback executeCallback,
- final LogCallback logCallback,
- final ExecutorService executorService) {
- final FFprobeSession session = new FFprobeSession(arguments, executeCallback, logCallback);
+ public static FFprobeSession executeWithArgumentsAsync(final String[] arguments,
+ final FFprobeSessionCompleteCallback completeCallback,
+ final LogCallback logCallback,
+ final ExecutorService executorService) {
+ final FFprobeSession session = new FFprobeSession(arguments, completeCallback, logCallback);
FFmpegKitConfig.asyncFFprobeExecute(session, executorService);
@@ -159,59 +173,65 @@ public class FFprobeKit {
* @return FFprobe session created for this execution
*/
public static FFprobeSession execute(final String command) {
- return execute(FFmpegKitConfig.parseArguments(command));
+ return executeWithArguments(FFmpegKitConfig.parseArguments(command));
}
/**
- *
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
- * into arguments. You can use single or double quote characters to specify arguments inside your command.
+ *
Starts an asynchronous FFprobe execution for the given command. Space character is used
+ * to split the command into arguments. You can use single or double quote characters to
+ * specify arguments inside your command.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFprobe session created for this execution
*/
public static FFprobeSession executeAsync(final String command,
- final ExecuteCallback executeCallback) {
- return executeAsync(FFmpegKitConfig.parseArguments(command), executeCallback);
+ final FFprobeSessionCompleteCallback completeCallback) {
+ return executeWithArgumentsAsync(FFmpegKitConfig.parseArguments(command), completeCallback);
}
/**
- *
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
- * into arguments. You can use single or double quote characters to specify arguments inside your command.
+ *
Starts an asynchronous FFprobe execution for the given command. Space character is used
+ * to split the command into arguments. You can use single or double quote characters to
+ * specify arguments inside your command.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
+ * @param command FFprobe command
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
* @return FFprobe session created for this execution
*/
public static FFprobeSession executeAsync(final String command,
- final ExecuteCallback executeCallback,
+ final FFprobeSessionCompleteCallback completeCallback,
final LogCallback logCallback) {
- return executeAsync(FFmpegKitConfig.parseArguments(command), executeCallback, logCallback);
+ return executeWithArgumentsAsync(FFmpegKitConfig.parseArguments(command), completeCallback, logCallback);
}
/**
- *
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
- * into arguments. You can use single or double quote characters to specify arguments inside your command.
+ *
Starts an asynchronous FFprobe execution for the given command. Space character is used
+ * to split the command into arguments. You can use single or double quote characters to
+ * specify arguments inside your command.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
- * @param executorService executor service that will be used to run this asynchronous operation
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param executorService executor service that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
public static FFprobeSession executeAsync(final String command,
- final ExecuteCallback executeCallback,
+ final FFprobeSessionCompleteCallback completeCallback,
final ExecutorService executorService) {
- final FFprobeSession session = new FFprobeSession(FFmpegKitConfig.parseArguments(command), executeCallback);
+ final FFprobeSession session = new FFprobeSession(FFmpegKitConfig.parseArguments(command), completeCallback);
FFmpegKitConfig.asyncFFprobeExecute(session, executorService);
@@ -219,23 +239,25 @@ public class FFprobeKit {
}
/**
- *
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
- * into arguments. You can use single or double quote characters to specify arguments inside your command.
- *
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
- *
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param executorService executor service that will be used to run this asynchronous operation
+ *
Starts an asynchronous FFprobe execution for the given command. Space character is used
+ * to split the command into arguments. You can use single or double quote characters to
+ * specify arguments inside your command.
+ *
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an {@link FFprobeSessionCompleteCallback} if you want to be notified about the
+ * result.
+ *
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param executorService executor service that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
public static FFprobeSession executeAsync(final String command,
- final ExecuteCallback executeCallback,
+ final FFprobeSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final ExecutorService executorService) {
- final FFprobeSession session = new FFprobeSession(FFmpegKitConfig.parseArguments(command), executeCallback, logCallback);
+ final FFprobeSession session = new FFprobeSession(FFmpegKitConfig.parseArguments(command), completeCallback, logCallback);
FFmpegKitConfig.asyncFFprobeExecute(session, executorService);
@@ -249,7 +271,7 @@ public class FFprobeKit {
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformation(final String path) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path});
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path));
FFmpegKitConfig.getMediaInformationExecute(session, AbstractSession.DEFAULT_TIMEOUT_FOR_ASYNCHRONOUS_MESSAGES_IN_TRANSMIT);
@@ -265,7 +287,7 @@ public class FFprobeKit {
*/
public static MediaInformationSession getMediaInformation(final String path,
final int waitTimeout) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path});
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path));
FFmpegKitConfig.getMediaInformationExecute(session, waitTimeout);
@@ -273,18 +295,20 @@ public class FFprobeKit {
}
/**
- *
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
+ *
Starts an asynchronous FFprobe execution to extract the media information for the
+ * specified file.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be called when the execution is completed
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be called when the execution has completed
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformationAsync(final String path,
- final ExecuteCallback executeCallback) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path}, executeCallback);
+ final MediaInformationSessionCompleteCallback completeCallback) {
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path), completeCallback);
FFmpegKitConfig.asyncGetMediaInformationExecute(session, AbstractSession.DEFAULT_TIMEOUT_FOR_ASYNCHRONOUS_MESSAGES_IN_TRANSMIT);
@@ -292,22 +316,24 @@ public class FFprobeKit {
}
/**
- *
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
+ *
Starts an asynchronous FFprobe execution to extract the media information for the
+ * specified file.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param waitTimeout max time to wait until media information is transmitted
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformationAsync(final String path,
- final ExecuteCallback executeCallback,
+ final MediaInformationSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final int waitTimeout) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path}, executeCallback, logCallback);
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path), completeCallback, logCallback);
FFmpegKitConfig.asyncGetMediaInformationExecute(session, waitTimeout);
@@ -315,20 +341,22 @@ public class FFprobeKit {
}
/**
- *
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
+ *
Starts an asynchronous FFprobe execution to extract the media information for the
+ * specified file.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be called when the execution is completed
- * @param executorService executor service that will be used to run this asynchronous operation
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param executorService executor service that will be used to run this asynchronous operation
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformationAsync(final String path,
- final ExecuteCallback executeCallback,
+ final MediaInformationSessionCompleteCallback completeCallback,
final ExecutorService executorService) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path}, executeCallback);
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path), completeCallback);
FFmpegKitConfig.asyncGetMediaInformationExecute(session, executorService, AbstractSession.DEFAULT_TIMEOUT_FOR_ASYNCHRONOUS_MESSAGES_IN_TRANSMIT);
@@ -336,24 +364,26 @@ public class FFprobeKit {
}
/**
- *
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
- *
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
- *
- * @param path path or uri of a media file
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param executorService executor service that will be used to run this asynchronous operation
- * @param waitTimeout max time to wait until media information is transmitted
+ *
Starts an asynchronous FFprobe execution to extract the media information for the
+ * specified file.
+ *
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
+ *
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param executorService executor service that will be used to run this asynchronous operation
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformationAsync(final String path,
- final ExecuteCallback executeCallback,
+ final MediaInformationSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final ExecutorService executorService,
final int waitTimeout) {
- final MediaInformationSession session = new MediaInformationSession(new String[]{"-v", "error", "-hide_banner", "-print_format", "json", "-show_format", "-show_streams", "-i", path}, executeCallback, logCallback);
+ final MediaInformationSession session = new MediaInformationSession(defaultGetMediaInformationCommandArguments(path), completeCallback, logCallback);
FFmpegKitConfig.asyncGetMediaInformationExecute(session, executorService, waitTimeout);
@@ -361,7 +391,7 @@ public class FFprobeKit {
}
/**
- *
Extracts media information using the command provided asynchronously.
+ *
Extracts media information using the command provided.
*
* @param command FFprobe command that prints media information for a file in JSON format
* @return media information session created for this execution
@@ -369,52 +399,57 @@ public class FFprobeKit {
public static MediaInformationSession getMediaInformationFromCommand(final String command) {
final MediaInformationSession session = new MediaInformationSession(FFmpegKitConfig.parseArguments(command));
- FFmpegKitConfig.asyncGetMediaInformationExecute(session, AbstractSession.DEFAULT_TIMEOUT_FOR_ASYNCHRONOUS_MESSAGES_IN_TRANSMIT);
+ FFmpegKitConfig.getMediaInformationExecute(session, AbstractSession.DEFAULT_TIMEOUT_FOR_ASYNCHRONOUS_MESSAGES_IN_TRANSMIT);
return session;
}
/**
- *
Starts an asynchronous FFprobe execution to extract media information using a command. The command passed to
- * this method must generate the output in JSON format in order to successfully extract media information from it.
- *
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
- *
- * @param command FFprobe command that prints media information for a file in JSON format
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param waitTimeout max time to wait until media information is transmitted
+ *
Starts an asynchronous FFprobe execution to extract media information using a command.
+ * The command passed to this method must generate the output in JSON format in order to
+ * successfully extract media information from it.
+ *
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
+ *
+ * @param command FFprobe command that prints media information for a file in JSON
+ * format
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
public static MediaInformationSession getMediaInformationFromCommandAsync(final String command,
- final ExecuteCallback executeCallback,
+ final MediaInformationSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final int waitTimeout) {
- return getMediaInformationFromCommandArgumentsAsync(FFmpegKitConfig.parseArguments(command), executeCallback, logCallback, waitTimeout);
+ return getMediaInformationFromCommandArgumentsAsync(FFmpegKitConfig.parseArguments(command), completeCallback, logCallback, waitTimeout);
}
/**
- *
Starts an asynchronous FFprobe execution to extract media information using command arguments. The command
- * passed to this method must generate the output in JSON format in order to successfully extract media information
- * from it.
- *
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * {@jlink ExecuteCallback} if you want to be notified about the result.
- *
- * @param arguments FFprobe command arguments that print media information for a file in JSON format
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param waitTimeout max time to wait until media information is transmitted
+ *
Starts an asynchronous FFprobe execution to extract media information using command
+ * arguments. The command passed to this method must generate the output in JSON format in
+ * order to successfully extract media information from it.
+ *
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use a {@link MediaInformationSessionCompleteCallback} if you want to be notified
+ * about the result.
+ *
+ * @param arguments FFprobe command arguments that print media information for a file in
+ * JSON format
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
private static MediaInformationSession getMediaInformationFromCommandArgumentsAsync(final String[] arguments,
- final ExecuteCallback executeCallback,
+ final MediaInformationSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final int waitTimeout) {
- final MediaInformationSession session = new MediaInformationSession(arguments, executeCallback, logCallback);
+ final MediaInformationSession session = new MediaInformationSession(arguments, completeCallback, logCallback);
- FFmpegKitConfig.getMediaInformationExecute(session, waitTimeout);
+ FFmpegKitConfig.asyncGetMediaInformationExecute(session, waitTimeout);
return session;
}
@@ -424,8 +459,17 @@ public class FFprobeKit {
*
* @return all FFprobe sessions in the session history
*/
- public static List listSessions() {
+ public static List listFFprobeSessions() {
return FFmpegKitConfig.getFFprobeSessions();
}
+ /**
+ * Lists all MediaInformation sessions in the session history.
+ *
+ * @return all MediaInformation sessions in the session history
+ */
+ public static List listMediaInformationSessions() {
+ return FFmpegKitConfig.getMediaInformationSessions();
+ }
+
}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSession.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSession.java
index 43fe477..2d97220 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSession.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSession.java
@@ -24,6 +24,11 @@ package com.arthenica.ffmpegkit;
*/
public class FFprobeSession extends AbstractSession implements Session {
+ /**
+ * Session specific complete callback.
+ */
+ private final FFprobeSessionCompleteCallback completeCallback;
+
/**
* Builds a new FFprobe session.
*
@@ -36,39 +41,50 @@ public class FFprobeSession extends AbstractSession implements Session {
/**
* Builds a new FFprobe session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback function
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
- public FFprobeSession(final String[] arguments, final ExecuteCallback executeCallback) {
- this(arguments, executeCallback, null);
+ public FFprobeSession(final String[] arguments, final FFprobeSessionCompleteCallback completeCallback) {
+ this(arguments, completeCallback, null);
}
/**
* Builds a new FFprobe session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback function
- * @param logCallback session specific log callback function
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
*/
public FFprobeSession(final String[] arguments,
- final ExecuteCallback executeCallback,
+ final FFprobeSessionCompleteCallback completeCallback,
final LogCallback logCallback) {
- this(arguments, executeCallback, logCallback, FFmpegKitConfig.getLogRedirectionStrategy());
+ this(arguments, completeCallback, logCallback, FFmpegKitConfig.getLogRedirectionStrategy());
}
/**
* Builds a new FFprobe session.
*
* @param arguments command arguments
- * @param executeCallback session specific execute callback function
- * @param logCallback session specific log callback function
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
* @param logRedirectionStrategy session specific log redirection strategy
*/
public FFprobeSession(final String[] arguments,
- final ExecuteCallback executeCallback,
+ final FFprobeSessionCompleteCallback completeCallback,
final LogCallback logCallback,
final LogRedirectionStrategy logRedirectionStrategy) {
- super(arguments, executeCallback, logCallback, logRedirectionStrategy);
+ super(arguments, logCallback, logRedirectionStrategy);
+
+ this.completeCallback = completeCallback;
+ }
+
+ /**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+ public FFprobeSessionCompleteCallback getCompleteCallback() {
+ return completeCallback;
}
@Override
@@ -81,6 +97,11 @@ public class FFprobeSession extends AbstractSession implements Session {
return true;
}
+ @Override
+ public boolean isMediaInformation() {
+ return false;
+ }
+
@Override
public String toString() {
final StringBuilder stringBuilder = new StringBuilder();
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSessionCompleteCallback.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSessionCompleteCallback.java
new file mode 100644
index 0000000..3654916
--- /dev/null
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/FFprobeSessionCompleteCallback.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2018-2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+package com.arthenica.ffmpegkit;
+
+/**
+ * Callback function that is invoked when an asynchronous FFprobe
session has ended.
+ */
+@FunctionalInterface
+public interface FFprobeSessionCompleteCallback {
+
+ /**
+ *
Called when an FFprobe session has ended.
+ *
+ * @param session FFprobe session
+ */
+ void apply(final FFprobeSession session);
+
+}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformation.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformation.java
index 83d04a3..faf6674 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformation.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformation.java
@@ -49,9 +49,15 @@ public class MediaInformation {
*/
private final List streams;
- public MediaInformation(final JSONObject jsonObject, final List streams) {
+ /**
+ * Stores chapters.
+ */
+ private final List chapters;
+
+ public MediaInformation(final JSONObject jsonObject, final List streams, final List chapters) {
this.jsonObject = jsonObject;
this.streams = streams;
+ this.chapters = chapters;
}
/**
@@ -135,6 +141,15 @@ public class MediaInformation {
return streams;
}
+ /**
+ * Returns all chapters.
+ *
+ * @return list of chapters
+ */
+ public List getChapters() {
+ return chapters;
+ }
+
/**
* Returns the media property associated with the key.
*
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationJsonParser.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationJsonParser.java
index 2d78e6c..45a9471 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationJsonParser.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationJsonParser.java
@@ -34,6 +34,9 @@ import java.util.ArrayList;
*/
public class MediaInformationJsonParser {
+ public static final String KEY_STREAMS = "streams";
+ public static final String KEY_CHAPTERS = "chapters";
+
/**
* Extracts MediaInformation
from the given FFprobe json output. Note that this
* method does not throw {@link JSONException} as {@link #fromWithError(String)} does and
@@ -59,18 +62,27 @@ public class MediaInformationJsonParser {
* @throws JSONException if a parsing error occurs
*/
public static MediaInformation fromWithError(final String ffprobeJsonOutput) throws JSONException {
- JSONObject jsonObject = new JSONObject(ffprobeJsonOutput);
- JSONArray streamArray = jsonObject.optJSONArray("streams");
+ final JSONObject jsonObject = new JSONObject(ffprobeJsonOutput);
+ final JSONArray streamArray = jsonObject.optJSONArray(KEY_STREAMS);
+ final JSONArray chapterArray = jsonObject.optJSONArray(KEY_CHAPTERS);
- ArrayList arrayList = new ArrayList<>();
+ ArrayList streamList = new ArrayList<>();
for (int i = 0; streamArray != null && i < streamArray.length(); i++) {
JSONObject streamObject = streamArray.optJSONObject(i);
if (streamObject != null) {
- arrayList.add(new StreamInformation(streamObject));
+ streamList.add(new StreamInformation(streamObject));
+ }
+ }
+
+ ArrayList chapterList = new ArrayList<>();
+ for (int i = 0; chapterArray != null && i < chapterArray.length(); i++) {
+ JSONObject chapterObject = chapterArray.optJSONObject(i);
+ if (chapterObject != null) {
+ chapterList.add(new Chapter(chapterObject));
}
}
- return new MediaInformation(jsonObject, arrayList);
+ return new MediaInformation(jsonObject, streamList, chapterList);
}
}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSession.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSession.java
index 004e1dd..97ed2d2 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSession.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSession.java
@@ -23,13 +23,18 @@ package com.arthenica.ffmpegkit;
* A custom FFprobe session, which produces a MediaInformation
object using the
* FFprobe output.
*/
-public class MediaInformationSession extends FFprobeSession implements Session {
+public class MediaInformationSession extends AbstractSession implements Session {
/**
* Media information extracted in the session.
*/
private MediaInformation mediaInformation;
+ /**
+ * Session specific complete callback.
+ */
+ private final MediaInformationSessionCompleteCallback completeCallback;
+
/**
* Creates a new media information session.
*
@@ -42,22 +47,24 @@ public class MediaInformationSession extends FFprobeSession implements Session {
/**
* Creates a new media information session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback function
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
- public MediaInformationSession(final String[] arguments, final ExecuteCallback executeCallback) {
- this(arguments, executeCallback, null);
+ public MediaInformationSession(final String[] arguments, final MediaInformationSessionCompleteCallback completeCallback) {
+ this(arguments, completeCallback, null);
}
/**
* Creates a new media information session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback function
- * @param logCallback session specific log callback function
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
*/
- public MediaInformationSession(final String[] arguments, final ExecuteCallback executeCallback, final LogCallback logCallback) {
- super(arguments, executeCallback, logCallback, LogRedirectionStrategy.NEVER_PRINT_LOGS);
+ public MediaInformationSession(final String[] arguments, final MediaInformationSessionCompleteCallback completeCallback, final LogCallback logCallback) {
+ super(arguments, logCallback, LogRedirectionStrategy.NEVER_PRINT_LOGS);
+
+ this.completeCallback = completeCallback;
}
/**
@@ -79,6 +86,30 @@ public class MediaInformationSession extends FFprobeSession implements Session {
this.mediaInformation = mediaInformation;
}
+ /**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+ public MediaInformationSessionCompleteCallback getCompleteCallback() {
+ return completeCallback;
+ }
+
+ @Override
+ public boolean isFFmpeg() {
+ return false;
+ }
+
+ @Override
+ public boolean isFFprobe() {
+ return false;
+ }
+
+ @Override
+ public boolean isMediaInformation() {
+ return true;
+ }
+
@Override
public String toString() {
final StringBuilder stringBuilder = new StringBuilder();
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSessionCompleteCallback.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSessionCompleteCallback.java
new file mode 100644
index 0000000..544b58b
--- /dev/null
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/MediaInformationSessionCompleteCallback.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2018-2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+package com.arthenica.ffmpegkit;
+
+/**
+ *
Callback function that is invoked when an asynchronous MediaInformation
session
+ * has ended.
+ */
+@FunctionalInterface
+public interface MediaInformationSessionCompleteCallback {
+
+ /**
+ *
Called when a media information session has ended.
+ *
+ * @param session media information session
+ */
+ void apply(final MediaInformationSession session);
+
+}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/NativeLoader.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/NativeLoader.java
index d82fe6c..1197e83 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/NativeLoader.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/NativeLoader.java
@@ -27,6 +27,7 @@ import java.text.SimpleDateFormat;
import java.util.Collections;
import java.util.Date;
import java.util.List;
+import java.util.Locale;
/**
*
Responsible of loading native libraries.
@@ -35,6 +36,8 @@ public class NativeLoader {
static final String[] FFMPEG_LIBRARIES = {"avutil", "swscale", "swresample", "avcodec", "avformat", "avfilter", "avdevice"};
+ static final String[] LIBRARIES_LINKED_WITH_CXX = {"openh264", "rubberband", "snappy", "srt", "tesseract", "x265", "zimg"};
+
static boolean isTestModeDisabled() {
return (System.getProperty("enable.ffmpeg.kit.test.mode") == null);
}
@@ -82,7 +85,7 @@ public class NativeLoader {
}
static String loadVersion() {
- final String version = "4.5";
+ final String version = "4.5.1";
if (isTestModeDisabled()) {
return FFmpegKitConfig.getVersion();
@@ -113,7 +116,7 @@ public class NativeLoader {
if (isTestModeDisabled()) {
return FFmpegKitConfig.getBuildDate();
} else {
- return new SimpleDateFormat("yyyyMMdd").format(new Date());
+ return new SimpleDateFormat("yyyyMMdd", Locale.getDefault()).format(new Date());
}
}
@@ -135,8 +138,11 @@ public class NativeLoader {
/* LOADING LINKED LIBRARIES MANUALLY ON API < 21 */
final List externalLibrariesEnabled = loadExternalLibraries();
- if (externalLibrariesEnabled.contains("tesseract") || externalLibrariesEnabled.contains("x265") || externalLibrariesEnabled.contains("snappy") || externalLibrariesEnabled.contains("openh264") || externalLibrariesEnabled.contains("rubberband")) {
- loadLibrary("c++_shared");
+ for (String dependantLibrary : LIBRARIES_LINKED_WITH_CXX) {
+ if (externalLibrariesEnabled.contains(dependantLibrary)) {
+ loadLibrary("c++_shared");
+ break;
+ }
}
if (AbiDetect.ARM_V7A.equals(loadNativeAbi())) {
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Packages.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Packages.java
index 6696d1c..70f9dea 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Packages.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Packages.java
@@ -51,6 +51,7 @@ public class Packages {
supportedExternalLibraries.add("libxml2");
supportedExternalLibraries.add("opencore-amr");
supportedExternalLibraries.add("openh264");
+ supportedExternalLibraries.add("openssl");
supportedExternalLibraries.add("opus");
supportedExternalLibraries.add("rubberband");
supportedExternalLibraries.add("sdl2");
@@ -58,11 +59,13 @@ public class Packages {
supportedExternalLibraries.add("snappy");
supportedExternalLibraries.add("soxr");
supportedExternalLibraries.add("speex");
+ supportedExternalLibraries.add("srt");
supportedExternalLibraries.add("tesseract");
supportedExternalLibraries.add("twolame");
supportedExternalLibraries.add("x264");
supportedExternalLibraries.add("x265");
supportedExternalLibraries.add("xvid");
+ supportedExternalLibraries.add("zimg");
}
/**
@@ -134,7 +137,8 @@ public class Packages {
externalLibraryList.contains("twolame") &&
externalLibraryList.contains("x264") &&
externalLibraryList.contains("x265") &&
- externalLibraryList.contains("xvid")) {
+ externalLibraryList.contains("xvid") &&
+ externalLibraryList.contains("zimg")) {
return "full-gpl";
} else {
return "custom";
@@ -164,7 +168,8 @@ public class Packages {
externalLibraryList.contains("snappy") &&
externalLibraryList.contains("soxr") &&
externalLibraryList.contains("speex") &&
- externalLibraryList.contains("twolame")) {
+ externalLibraryList.contains("twolame") &&
+ externalLibraryList.contains("zimg")) {
return "full";
} else {
return "custom";
@@ -182,7 +187,8 @@ public class Packages {
externalLibraryList.contains("libtheora") &&
externalLibraryList.contains("libvpx") &&
externalLibraryList.contains("libwebp") &&
- externalLibraryList.contains("snappy")) {
+ externalLibraryList.contains("snappy") &&
+ externalLibraryList.contains("zimg")) {
return "video";
} else {
return "custom";
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/ReturnCode.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/ReturnCode.java
index a91ff9e..78d6033 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/ReturnCode.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/ReturnCode.java
@@ -43,15 +43,15 @@ public class ReturnCode {
return value;
}
- public boolean isSuccess() {
+ public boolean isValueSuccess() {
return (value == SUCCESS);
}
- public boolean isError() {
+ public boolean isValueError() {
return ((value != SUCCESS) && (value != CANCEL));
}
- public boolean isCancel() {
+ public boolean isValueCancel() {
return (value == CANCEL);
}
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Session.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Session.java
index 2dc73fa..74aa7df 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Session.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/Session.java
@@ -29,16 +29,9 @@ import java.util.concurrent.Future;
public interface Session {
/**
- * Returns the session specific execute callback function.
+ * Returns the session specific log callback.
*
- * @return session specific execute callback function
- */
- ExecuteCallback getExecuteCallback();
-
- /**
- * Returns the session specific log callback function.
- *
- * @return session specific log callback function
+ * @return session specific log callback
*/
LogCallback getLogCallback();
@@ -198,6 +191,9 @@ public interface Session {
/**
* Adds a new log entry for this session.
+ *
+ * It is invoked internally by FFmpegKit
library methods. Must not be used by user
+ * applications.
*
* @param log log entry
*/
@@ -224,6 +220,13 @@ public interface Session {
*/
boolean isFFprobe();
+ /**
+ * Returns whether it is a MediaInformation
session or not.
+ *
+ * @return true if it is a MediaInformation
session, false otherwise
+ */
+ boolean isMediaInformation();
+
/**
* Cancels running the session.
*/
diff --git a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/StreamInformation.java b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/StreamInformation.java
index 487de30..45bd329 100644
--- a/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/StreamInformation.java
+++ b/android/ffmpeg-kit-android-lib/src/main/java/com/arthenica/ffmpegkit/StreamInformation.java
@@ -211,7 +211,7 @@ public class StreamInformation {
/**
* Returns all tags.
*
- * @return tags dictionary
+ * @return tags object
*/
public JSONObject getTags() {
return getProperties(KEY_TAGS);
diff --git a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegKitTest.java b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegKitTest.java
index 24cbba8..29e16ad 100644
--- a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegKitTest.java
+++ b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegKitTest.java
@@ -72,6 +72,85 @@ public class FFmpegKitTest {
" }\n" +
" }\n" +
" ],\n" +
+ " \"chapters\": [\n" +
+ " {\n" +
+ " \"id\": 0,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 0,\n" +
+ " \"start_time\": \"0.000000\",\n" +
+ " \"end\": 11158238,\n" +
+ " \"end_time\": \"506.042540\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"1 Laying Plans - 2 Waging War\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 1,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 11158238,\n" +
+ " \"start_time\": \"506.042540\",\n" +
+ " \"end\": 21433051,\n" +
+ " \"end_time\": \"972.020454\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"3 Attack By Stratagem - 4 Tactical Dispositions\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 2,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 21433051,\n" +
+ " \"start_time\": \"972.020454\",\n" +
+ " \"end\": 35478685,\n" +
+ " \"end_time\": \"1609.010658\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"5 Energy - 6 Weak Points and Strong\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 3,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 35478685,\n" +
+ " \"start_time\": \"1609.010658\",\n" +
+ " \"end\": 47187043,\n" +
+ " \"end_time\": \"2140.001950\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"7 Maneuvering - 8 Variation in Tactics\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 4,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 47187043,\n" +
+ " \"start_time\": \"2140.001950\",\n" +
+ " \"end\": 66635594,\n" +
+ " \"end_time\": \"3022.022404\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"9 The Army on the March - 10 Terrain\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 5,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 66635594,\n" +
+ " \"start_time\": \"3022.022404\",\n" +
+ " \"end\": 83768105,\n" +
+ " \"end_time\": \"3799.007029\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"11 The Nine Situations\"\n" +
+ " }\n" +
+ " },\n" +
+ " {\n" +
+ " \"id\": 6,\n" +
+ " \"time_base\": \"1/22050\",\n" +
+ " \"start\": 83768105,\n" +
+ " \"start_time\": \"3799.007029\",\n" +
+ " \"end\": 95659008,\n" +
+ " \"end_time\": \"4338.277007\",\n" +
+ " \"tags\": {\n" +
+ " \"title\": \"12 The Attack By Fire - 13 The Use of Spies\"\n" +
+ " }\n" +
+ " }\n" +
+ " ],\n" +
" \"format\": {\n" +
" \"filename\": \"sample.mp3\",\n" +
" \"nb_streams\": 1,\n" +
@@ -459,6 +538,11 @@ public class FFmpegKitTest {
Assert.assertNotNull(mediaInformation.getStreams());
Assert.assertEquals(1, mediaInformation.getStreams().size());
assertAudioStream(mediaInformation.getStreams().get(0), 0L, "mp3", "MP3 (MPEG audio layer 3)", "44100", "stereo", "fltp", "320000");
+
+ Assert.assertNotNull(mediaInformation.getChapters());
+ Assert.assertEquals(7, mediaInformation.getChapters().size());
+ assertChapter(mediaInformation.getChapters().get(0), 0L, "1/22050", 0L, "0.000000", 11158238L, "506.042540");
+ assertChapter(mediaInformation.getChapters().get(1), 1L, "1/22050", 11158238L, "506.042540", 21433051L, "972.020454");
}
@Test
@@ -743,4 +827,18 @@ public class FFmpegKitTest {
Assert.assertEquals(codecTimeBase, streamInformation.getCodecTimeBase());
}
+ private void assertChapter(Chapter chapter, Long id, String timeBase, Long start, String startTime, Long end, String endTime) {
+ Assert.assertEquals(id, chapter.getId());
+ Assert.assertEquals(timeBase, chapter.getTimeBase());
+
+ Assert.assertEquals(start, chapter.getStart());
+ Assert.assertEquals(startTime, chapter.getStartTime());
+
+ Assert.assertEquals(end, chapter.getEnd());
+ Assert.assertEquals(endTime, chapter.getEndTime());
+
+ Assert.assertNotNull(chapter.getTags());
+ Assert.assertEquals(1, chapter.getTags().length());
+ }
+
}
diff --git a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegSessionTest.java b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegSessionTest.java
index b387225..488da35 100644
--- a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegSessionTest.java
+++ b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFmpegSessionTest.java
@@ -32,8 +32,8 @@ public class FFmpegSessionTest {
public void constructorTest() {
FFmpegSession ffmpegSession = new FFmpegSession(TEST_ARGUMENTS);
- // 1. getExecuteCallback
- Assert.assertNull(ffmpegSession.getExecuteCallback());
+ // 1. getCompleteCallback
+ Assert.assertNull(ffmpegSession.getCompleteCallback());
// 2. getLogCallback
Assert.assertNull(ffmpegSession.getLogCallback());
@@ -93,17 +93,17 @@ public class FFmpegSessionTest {
@Test
public void constructorTest2() {
- ExecuteCallback executeCallback = new ExecuteCallback() {
+ FFmpegSessionCompleteCallback completeCallback = new FFmpegSessionCompleteCallback() {
@Override
- public void apply(Session session) {
+ public void apply(FFmpegSession session) {
}
};
- FFmpegSession ffmpegSession = new FFmpegSession(TEST_ARGUMENTS, executeCallback);
+ FFmpegSession ffmpegSession = new FFmpegSession(TEST_ARGUMENTS, completeCallback);
- // 1. getExecuteCallback
- Assert.assertEquals(ffmpegSession.getExecuteCallback(), executeCallback);
+ // 1. getCompleteCallback
+ Assert.assertEquals(ffmpegSession.getCompleteCallback(), completeCallback);
// 2. getLogCallback
Assert.assertNull(ffmpegSession.getLogCallback());
@@ -163,10 +163,10 @@ public class FFmpegSessionTest {
@Test
public void constructorTest3() {
- ExecuteCallback executeCallback = new ExecuteCallback() {
+ FFmpegSessionCompleteCallback completeCallback = new FFmpegSessionCompleteCallback() {
@Override
- public void apply(Session session) {
+ public void apply(FFmpegSession session) {
}
};
@@ -184,10 +184,10 @@ public class FFmpegSessionTest {
}
};
- FFmpegSession ffmpegSession = new FFmpegSession(TEST_ARGUMENTS, executeCallback, logCallback, statisticsCallback);
+ FFmpegSession ffmpegSession = new FFmpegSession(TEST_ARGUMENTS, completeCallback, logCallback, statisticsCallback);
- // 1. getExecuteCallback
- Assert.assertEquals(ffmpegSession.getExecuteCallback(), executeCallback);
+ // 1. getCompleteCallback
+ Assert.assertEquals(ffmpegSession.getCompleteCallback(), completeCallback);
// 2. getLogCallback
Assert.assertEquals(ffmpegSession.getLogCallback(), logCallback);
diff --git a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFprobeSessionTest.java b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFprobeSessionTest.java
index 634e901..7374e6c 100644
--- a/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFprobeSessionTest.java
+++ b/android/ffmpeg-kit-android-lib/src/test/java/com/arthenica/ffmpegkit/FFprobeSessionTest.java
@@ -32,8 +32,8 @@ public class FFprobeSessionTest {
public void constructorTest() {
FFprobeSession ffprobeSession = new FFprobeSession(TEST_ARGUMENTS);
- // 1. getExecuteCallback
- Assert.assertNull(ffprobeSession.getExecuteCallback());
+ // 1. getCompleteCallback
+ Assert.assertNull(ffprobeSession.getCompleteCallback());
// 2. getLogCallback
Assert.assertNull(ffprobeSession.getLogCallback());
@@ -90,17 +90,17 @@ public class FFprobeSessionTest {
@Test
public void constructorTest2() {
- ExecuteCallback executeCallback = new ExecuteCallback() {
+ FFprobeSessionCompleteCallback completeCallback = new FFprobeSessionCompleteCallback() {
@Override
- public void apply(Session session) {
+ public void apply(FFprobeSession session) {
}
};
- FFprobeSession ffprobeSession = new FFprobeSession(TEST_ARGUMENTS, executeCallback);
+ FFprobeSession ffprobeSession = new FFprobeSession(TEST_ARGUMENTS, completeCallback);
- // 1. getExecuteCallback
- Assert.assertEquals(ffprobeSession.getExecuteCallback(), executeCallback);
+ // 1. getCompleteCallback
+ Assert.assertEquals(ffprobeSession.getCompleteCallback(), completeCallback);
// 2. getLogCallback
Assert.assertNull(ffprobeSession.getLogCallback());
@@ -157,10 +157,10 @@ public class FFprobeSessionTest {
@Test
public void constructorTest3() {
- ExecuteCallback executeCallback = new ExecuteCallback() {
+ FFprobeSessionCompleteCallback completeCallback = new FFprobeSessionCompleteCallback() {
@Override
- public void apply(Session session) {
+ public void apply(FFprobeSession session) {
}
};
@@ -171,10 +171,10 @@ public class FFprobeSessionTest {
}
};
- FFprobeSession ffprobeSession = new FFprobeSession(TEST_ARGUMENTS, executeCallback, logCallback);
+ FFprobeSession ffprobeSession = new FFprobeSession(TEST_ARGUMENTS, completeCallback, logCallback);
- // 1. getExecuteCallback
- Assert.assertEquals(ffprobeSession.getExecuteCallback(), executeCallback);
+ // 1. getCompleteCallback
+ Assert.assertEquals(ffprobeSession.getCompleteCallback(), completeCallback);
// 2. getLogCallback
Assert.assertEquals(ffprobeSession.getLogCallback(), logCallback);
diff --git a/apple.sh b/apple.sh
index a05295f..8eff418 100755
--- a/apple.sh
+++ b/apple.sh
@@ -12,14 +12,11 @@ enable_default_architecture_variants() {
display_help() {
COMMAND=$(echo "$0" | sed -e 's/\.\///g')
- echo -e "\n'$COMMAND' combines FFmpegKit frameworks created for apple architecture variants in an xcframework. \
+ echo -e "\n'$COMMAND' combines FFmpegKit frameworks created for Apple architecture variants in an xcframework. \
It uses frameworks created under the prebuilt folder for iOS, tvOS and macOS architecture variants (iphoneos, \
iphonesimulator, mac-catalyst, appletvos, appletvsimulator, macosx) as input and builds an umbrella xcframework under \
-the prebuilt folder.\n\n\
-Additional options can be specified to disable architectures or to build xcframeworks for external libraries as well.\
-\n\nPlease note that this script is only responsible of packaging existing frameworks, created by 'ios.sh', 'tvos.sh' \
-and 'macos.sh'. Running it will not compile any of these libraries again. Enabling an external library means building \
-an xcframework for that library. It does not guarantee that ffmpeg has support for it. Top level build scripts \
+the prebuilt folder.\n\nPlease note that this script is only responsible of packaging existing frameworks, created by \
+'ios.sh', 'tvos.sh' and 'macos.sh'. Running it will not compile any of these libraries again. Top level build scripts \
('ios.sh', 'tvos.sh', 'macos.sh') must be used to build ffmpeg with support for a specific external library first. \
After that this script should be used to create an umbrella xcframework.\n"
echo -e "Usage: ./$COMMAND [OPTION]...\n"
@@ -29,10 +26,7 @@ After that this script should be used to create an umbrella xcframework.\n"
echo -e " -h, --help\t\t\tdisplay this help and exit"
echo -e " -v, --version\t\t\tdisplay version information and exit"
echo -e " -f, --force\t\t\tignore warnings"
- echo -e " -l, --lts\t\t\tinclude lts packages to support iOS 9.3+, tvOS 9.2+, macOS 10.11+ devices\n"
-
- echo -e "Licensing options:"
- echo -e " --enable-gpl\t\t\tallow building umbrella xcframeworks for GPL libraries[no]\n"
+ echo -e " -l, --lts\t\t\tinclude lts packages to support iOS 10+, tvOS 10+, macOS 10.12+ devices\n"
echo -e "Architectures:"
echo -e " --disable-iphoneos\t\tdo not include iphoneos architecture variant [yes]"
@@ -41,44 +35,6 @@ After that this script should be used to create an umbrella xcframework.\n"
echo -e " --disable-appletvos\t\tdo not include appletvos architecture variant [yes]"
echo -e " --disable-appletvsimulator\tdo not include appletvsimulator architecture variant [yes]"
echo -e " --disable-macosx\t\tdo not include macosx architecture variant [yes]\n"
-
- echo -e "Libraries:"
- echo -e " --full\t\t\tbuilds umbrella xcframeworks all non-GPL external libraries"
- echo -e " --enable-chromaprint\t\tbuild umbrella xcframework for chromaprint [no]"
- echo -e " --enable-dav1d\t\tbuild umbrella xcframework for dav1d [no]"
- echo -e " --enable-fontconfig\t\tbuild umbrella xcframework for fontconfig [no]"
- echo -e " --enable-freetype\t\tbuild umbrella xcframework for freetype [no]"
- echo -e " --enable-fribidi\t\tbuild umbrella xcframework for fribidi [no]"
- echo -e " --enable-gmp\t\t\tbuild umbrella xcframework for gmp [no]"
- echo -e " --enable-gnutls\t\tbuild umbrella xcframework for gnutls [no]"
- echo -e " --enable-kvazaar\t\tbuild umbrella xcframework for kvazaar [no]"
- echo -e " --enable-lame\t\t\tbuild umbrella xcframework for lame [no]"
- echo -e " --enable-libaom\t\tbuild umbrella xcframework for libaom [no]"
- echo -e " --enable-libass\t\tbuild umbrella xcframework for libass [no]"
- echo -e " --enable-libilbc\t\tbuild umbrella xcframework for libilbc [no]"
- echo -e " --enable-libtheora\t\tbuild umbrella xcframework for libtheora [no]"
- echo -e " --enable-libvorbis\t\tbuild umbrella xcframework for libvorbis [no]"
- echo -e " --enable-libvpx\t\tbuild umbrella xcframework for libvpx [no]"
- echo -e " --enable-libwebp\t\tbuild umbrella xcframework for libwebp [no]"
- echo -e " --enable-libxml2\t\tbuild umbrella xcframework for libxml2 [no]"
- echo -e " --enable-opencore-amr\t\tbuild umbrella xcframework for opencore-amr [no]"
- echo -e " --enable-openh264\t\tbuild umbrella xcframework for openh264 [no]"
- echo -e " --enable-opus\t\t\tbuild umbrella xcframework for opus [no]"
- echo -e " --enable-sdl\t\t\tbuild umbrella xcframework for sdl [no]"
- echo -e " --enable-shine\t\tbuild umbrella xcframework for shine [no]"
- echo -e " --enable-snappy\t\tbuild umbrella xcframework for snappy [no]"
- echo -e " --enable-soxr\t\t\tbuild umbrella xcframework for soxr [no]"
- echo -e " --enable-speex\t\tbuild umbrella xcframework for speex [no]"
- echo -e " --enable-tesseract\t\tbuild umbrella xcframework for tesseract [no]"
- echo -e " --enable-twolame\t\tbuild umbrella xcframework for twolame [no]"
- echo -e " --enable-vo-amrwbenc\t\tbuild umbrella xcframework for vo-amrwbenc [no]\n"
-
- echo -e "GPL libraries:"
- echo -e " --enable-libvidstab\t\tbuild umbrella xcframework for libvidstab [no]"
- echo -e " --enable-rubberband\t\tbuild umbrella xcframework for rubber band [no]"
- echo -e " --enable-x264\t\t\tbuild umbrella xcframework for x264 [no]"
- echo -e " --enable-x265\t\t\tbuild umbrella xcframework for x265 [no]"
- echo -e " --enable-xvidcore\t\tbuild umbrella xcframework for xvidcore [no]\n"
}
initialize_prebuilt_umbrella_xcframework_folders() {
@@ -219,17 +175,6 @@ while [ ! $# -eq 0 ]; do
-f | --force)
export BUILD_FORCE="1"
;;
- --full)
- BUILD_FULL="1"
- ;;
- --enable-gpl)
- GPL_ENABLED="yes"
- ;;
- --enable-*)
- ENABLED_LIBRARY=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
-
- enable_library "${ENABLED_LIBRARY}"
- ;;
--disable-*)
DISABLED_ARCH_VARIANT=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
@@ -242,19 +187,6 @@ while [ ! $# -eq 0 ]; do
shift
done
-# PROCESS FULL OPTION AS LAST OPTION
-if [[ -n ${BUILD_FULL} ]]; then
- for library in {0..58}; do
- if [ ${GPL_ENABLED} == "yes" ]; then
- set_library "$(get_library_name "$library")" 1
- else
- if [[ $(is_gpl_licensed "$library") -eq 1 ]]; then
- set_library "$(get_library_name "$library")" 1
- fi
- fi
- done
-fi
-
# IF HELP DISPLAYED EXIT
if [[ -n ${DISPLAY_HELP} ]]; then
display_help
@@ -271,19 +203,6 @@ print_enabled_xcframeworks
echo ""
-# VALIDATE GPL FLAGS
-for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVIDSTAB,$LIBRARY_RUBBERBAND}; do
- if [[ ${ENABLED_LIBRARIES[$gpl_library]} -eq 1 ]]; then
- library_name=$(get_library_name "${gpl_library}")
-
- if [ ${GPL_ENABLED} != "yes" ]; then
- echo -e "\n(*) Invalid configuration detected. GPL library ${library_name} enabled without --enable-gpl flag.\n"
- echo -e "\n(*) Invalid configuration detected. GPL library ${library_name} enabled without --enable-gpl flag.\n" 1>>"${BASEDIR}"/build.log 2>&1
- exit 1
- fi
- fi
-done
-
# THIS WILL SAVE ARCHITECTURE VARIANTS TO BE INCLUDED
TARGET_ARCHITECTURE_VARIANT_INDEX_ARRAY=()
@@ -309,45 +228,6 @@ if [[ -n ${TARGET_ARCHITECTURE_VARIANT_INDEX_ARRAY[0]} ]]; then
# INITIALIZE TARGET FOLDERS
initialize_prebuilt_umbrella_xcframework_folders
- # BUILD XCFRAMEWORKS FOR ENABLED LIBRARIES ON ENABLED ARCHITECTURE VARIANTS
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[${library}]} -eq 1 ]]; then
-
- if [[ ${LIBRARY_LIBTHEORA} == "${library}" ]]; then
-
- create_umbrella_xcframework "libtheora"
- create_umbrella_xcframework "libtheoraenc"
- create_umbrella_xcframework "libtheoradec"
-
- elif [[ ${LIBRARY_LIBVORBIS} == "${library}" ]]; then
-
- create_umbrella_xcframework "libvorbisfile"
- create_umbrella_xcframework "libvorbisenc"
- create_umbrella_xcframework "libvorbis"
-
- elif [[ ${LIBRARY_LIBWEBP} == "${library}" ]]; then
-
- create_umbrella_xcframework "libwebpmux"
- create_umbrella_xcframework "libwebpdemux"
- create_umbrella_xcframework "libwebp"
-
- elif [[ ${LIBRARY_OPENCOREAMR} == "${library}" ]]; then
-
- create_umbrella_xcframework "libopencore-amrnb"
-
- elif [[ ${LIBRARY_NETTLE} == "${library}" ]]; then
-
- create_umbrella_xcframework "libnettle"
- create_umbrella_xcframework "libhogweed"
-
- else
-
- create_umbrella_xcframework "$(get_static_archive_name "${library}")"
-
- fi
- fi
- done
-
for FFMPEG_LIB in "${FFMPEG_LIBS[@]}"; do
create_umbrella_xcframework "${FFMPEG_LIB}"
done
diff --git a/apple/.gitignore b/apple/.gitignore
index 3e4e1c5..adc4268 100644
--- a/apple/.gitignore
+++ b/apple/.gitignore
@@ -2,9 +2,11 @@
/Makefile
/config.status
/configure.tmp
+/configure~
/.deps/
/.libs/
*.trs
/unittests
/test-driver
/config.log
+/*.tmp
diff --git a/apple/Doxyfile b/apple/Doxyfile
index 38dc890..473ffef 100644
--- a/apple/Doxyfile
+++ b/apple/Doxyfile
@@ -38,7 +38,7 @@ PROJECT_NAME = "FFmpegKit iOS / macOS / tvOS API"
# could be handy for archiving the generated documentation or if some version
# control system is used.
-PROJECT_NUMBER = 4.5
+PROJECT_NUMBER = 4.5.1
# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
diff --git a/apple/Makefile.in b/apple/Makefile.in
index 044d789..f2c68c0 100644
--- a/apple/Makefile.in
+++ b/apple/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -154,12 +154,9 @@ am__define_uniq_tagged_files = \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
-CSCOPE = cscope
DIST_SUBDIRS = $(SUBDIRS)
-am__DIST_COMMON = $(srcdir)/Makefile.in ar-lib compile config.guess \
- config.sub install-sh ltmain.sh missing
+am__DIST_COMMON = $(srcdir)/Makefile.in README.md ar-lib compile \
+ config.guess config.sub install-sh ltmain.sh missing
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
@@ -215,8 +212,9 @@ AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
-CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
@@ -227,8 +225,9 @@ ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
+ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
-FFMPEG_LIBS = @FFMPEG_LIBS@
+FFMPEG_FRAMEWORKS = @FFMPEG_FRAMEWORKS@
FGREP = @FGREP@
GREP = @GREP@
INSTALL = @INSTALL@
@@ -317,6 +316,7 @@ pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
+runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
@@ -478,7 +478,6 @@ cscopelist-am: $(am__tagged_files)
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-rm -f cscope.out cscope.in.out cscope.po.out cscope.files
-
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
diff --git a/apple/README.md b/apple/README.md
index 110b16d..821ae37 100644
--- a/apple/README.md
+++ b/apple/README.md
@@ -2,36 +2,36 @@
### 1. Features
#### 1.1 iOS
-- Supports `iOS SDK 12.1+` on Main releases and `iOS SDK 9.3+` on LTS releases
+- Supports `iOS SDK 12.1+` on Main releases and `iOS SDK 10+` on LTS releases
- Includes `armv7`, `armv7s`, `arm64`, `arm64-simulator`, `arm64e`, `i386`, `x86_64`, `x86_64-mac-catalyst` and
`arm64-mac-catalyst` architectures
- Objective-C API
- Camera access
- `ARC` enabled library
- Built with `-fembed-bitcode` flag
-- Creates static `frameworks`, static `xcframeworks` and static `universal (fat)` libraries (.a)
+- Creates shared `frameworks` and `xcframeworks`
#### 1.2 macOS
-- Supports `macOS SDK 10.15+` on Main releases and `macOS SDK 10.11+` on LTS releases
+- Supports `macOS SDK 10.15+` on Main releases and `macOS SDK 10.12+` on LTS releases
- Includes `arm64` and `x86_64` architectures
- Objective-C API
- Camera access
- `ARC` enabled library
- Built with `-fembed-bitcode` flag
-- Creates static `frameworks`, static `xcframeworks` and static `universal (fat)` libraries (.a)
+- Creates shared `frameworks` and `xcframeworks`
#### 1.3 tvOS
-- Supports `tvOS SDK 10.2+` on Main releases and `tvOS SDK 9.2+` on LTS releases
+- Supports `tvOS SDK 11.0+` on Main releases and `tvOS SDK 10.0+` on LTS releases
- Includes `arm64`, `arm64-simulator` and `x86_64` architectures
- Objective-C API
- `ARC` enabled library
- Built with `-fembed-bitcode` flag
-- Creates static `frameworks`, static `xcframeworks` and static `universal (fat)` libraries (.a)
+- Creates shared `frameworks` and `xcframeworks`
### 2. Building
-Run `ios.sh`/`macos.sh`/`tvos.sh` at project root directory to build `ffmpeg-kit` and `ffmpeg` static libraries for a
-platform.
+Run `ios.sh`/`macos.sh`/`tvos.sh` inside the project root to build `ffmpeg-kit` and `ffmpeg` shared libraries
+for a platform.
Optionally, use `apple.sh` to combine bundles created by these three scripts in a single bundle.
@@ -45,20 +45,20 @@ Please note that `FFmpegKit` project repository includes the source code of `FFm
##### 2.1.1 iOS
-- **Xcode 7.3.1** or later
-- **iOS SDK 9.3** or later
+- **Xcode 8.0** or later
+- **iOS SDK 10** or later
- **Command Line Tools**
##### 2.1.2 macOS
-- **Xcode 7.3.1** or later
-- **macOS SDK 10.11** or later
+- **Xcode 8.0** or later
+- **macOS SDK 10.12** or later
- **Command Line Tools**
##### 2.1.3 tvOS
-- **Xcode 7.3.1** or later
-- **tvOS SDK 9.2** or later
+- **Xcode 8.0** or later
+- **tvOS SDK 10.0** or later
- **Command Line Tools**
##### 2.1.4 Packages
@@ -97,13 +97,10 @@ All libraries created can be found under the `prebuilt` directory.
- `tvOS` `xcframeworks` for `Main` builds are located under the `bundle-apple-xcframework-tvos` folder.
- `iOS` `frameworks` for `Main` builds are located under the `bundle-apple-framework-ios` folder.
- `iOS` `frameworks` for `LTS` builds are located under the `bundle-apple-framework-ios-lts` folder.
-- `iOS` `universal (fat) libraries (.a)` for `LTS` builds are located under the `bundle-apple-universal-ios-lts` folder.
- `macOS` `frameworks` for `Main` builds are located under the `bundle-apple-framework-macos` folder.
- `macOS` `frameworks` for `LTS` builds are located under the `bundle-apple-framework-macos-lts` folder.
-- `macOS` `universal (fat) libraries (.a)` for `LTS` builds are located under the `bundle-apple-universal-macos-lts` folder.
- `tvOS` `frameworks` for `Main` builds are located under the `bundle-apple-framework-tvos` folder.
- `tvOS` `frameworks` for `LTS` builds are located under the `bundle-apple-framework-tvos-lts` folder.
-- `tvOS` `universal (fat) libraries (.a)` for `LTS` builds are located under the `bundle-apple-universal-tvos-lts` folder.
### 3. Using
@@ -114,17 +111,17 @@ All libraries created can be found under the `prebuilt` directory.
- iOS
```yaml
- pod 'ffmpeg-kit-ios-full', '~> 4.5'
+ pod 'ffmpeg-kit-ios-full', '~> 4.5.1'
```
- macOS
```yaml
- pod 'ffmpeg-kit-macos-full', '~> 4.5'
+ pod 'ffmpeg-kit-macos-full', '~> 4.5.1'
```
- tvOS
```yaml
- pod 'ffmpeg-kit-tvos-full', '~> 4.5'
+ pod 'ffmpeg-kit-tvos-full', '~> 4.5.1'
```
2. Execute synchronous `FFmpeg` commands.
@@ -191,7 +188,7 @@ All libraries created can be found under the `prebuilt` directory.
4. Execute asynchronous `FFmpeg` commands by providing session specific `execute`/`log`/`session` callbacks.
```objectivec
- id session = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v mpeg4 file2.mp4" withExecuteCallback:^(id session){
+ FFmpegSession* session = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v mpeg4 file2.mp4" withCompleteCallback:^(FFmpegSession* session){
SessionState state = [session getState];
ReturnCode *returnCode = [session getReturnCode];
@@ -225,7 +222,7 @@ All libraries created can be found under the `prebuilt` directory.
- Asynchronous
```objectivec
- [FFprobeKit executeAsync:ffmpegCommand withExecuteCallback:^(id session) {
+ [FFprobeKit executeAsync:ffmpegCommand withCompleteCallback:^(FFprobeSession* session) {
CALLED WHEN SESSION IS EXECUTED
@@ -268,10 +265,18 @@ All libraries created can be found under the `prebuilt` directory.
9. Enable global callbacks.
- - Execute Callback, called when an async execution is ended
+ - Session type specific Complete Callbacks, called when an async session has been completed
```objectivec
- [FFmpegKitConfig enableExecuteCallback:^(id session) {
+ [FFmpegKitConfig enableFFmpegSessionCompleteCallback:^(FFmpegSession* session) {
+ ...
+ }];
+
+ [FFmpegKitConfig enableFFprobeSessionCompleteCallback:^(FFprobeSession* session) {
+ ...
+ }];
+
+ [FFmpegKitConfig enableMediaInformationSessionCompleteCallback:^(MediaInformationSession* session) {
...
}];
```
diff --git a/apple/aclocal.m4 b/apple/aclocal.m4
index 7afd8cc..aef2b1c 100644
--- a/apple/aclocal.m4
+++ b/apple/aclocal.m4
@@ -1,6 +1,6 @@
-# generated automatically by aclocal 1.16.3 -*- Autoconf -*-
+# generated automatically by aclocal 1.16.5 -*- Autoconf -*-
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2021 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -14,13 +14,13 @@
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
-[m4_warning([this file was generated for autoconf 2.69.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],,
+[m4_warning([this file was generated for autoconf 2.71.
You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically 'autoreconf'.])])
-# Copyright (C) 2002-2020 Free Software Foundation, Inc.
+# Copyright (C) 2002-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -35,7 +35,7 @@ AC_DEFUN([AM_AUTOMAKE_VERSION],
[am__api_version='1.16'
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
dnl require some minimum version. Point them to the right macro.
-m4_if([$1], [1.16.3], [],
+m4_if([$1], [1.16.5], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
@@ -51,12 +51,12 @@ m4_define([_AM_AUTOCONF_VERSION], [])
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.16.3])dnl
+[AM_AUTOMAKE_VERSION([1.16.5])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
-# Copyright (C) 2011-2020 Free Software Foundation, Inc.
+# Copyright (C) 2011-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -118,7 +118,7 @@ AC_SUBST([AR])dnl
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -170,7 +170,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd`
# AM_CONDITIONAL -*- Autoconf -*-
-# Copyright (C) 1997-2020 Free Software Foundation, Inc.
+# Copyright (C) 1997-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -201,7 +201,7 @@ AC_CONFIG_COMMANDS_PRE(
Usually this means the macro was only invoked conditionally.]])
fi])])
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -392,7 +392,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
# Generate code to set up dependency tracking. -*- Autoconf -*-
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -460,7 +460,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
# Do all the work for Automake. -*- Autoconf -*-
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -488,6 +488,10 @@ m4_defn([AC_PROG_CC])
# release and drop the old call support.
AC_DEFUN([AM_INIT_AUTOMAKE],
[AC_PREREQ([2.65])dnl
+m4_ifdef([_$0_ALREADY_INIT],
+ [m4_fatal([$0 expanded multiple times
+]m4_defn([_$0_ALREADY_INIT]))],
+ [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl
dnl Autoconf wants to disallow AM_ names. We explicitly allow
dnl the ones we care about.
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@@ -524,7 +528,7 @@ m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
[_AM_SET_OPTIONS([$1])dnl
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
m4_if(
- m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
+ m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
[ok:ok],,
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
@@ -576,6 +580,20 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
[m4_define([AC_PROG_OBJCXX],
m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
])
+# Variables for tags utilities; see am/tags.am
+if test -z "$CTAGS"; then
+ CTAGS=ctags
+fi
+AC_SUBST([CTAGS])
+if test -z "$ETAGS"; then
+ ETAGS=etags
+fi
+AC_SUBST([ETAGS])
+if test -z "$CSCOPE"; then
+ CSCOPE=cscope
+fi
+AC_SUBST([CSCOPE])
+
AC_REQUIRE([AM_SILENT_RULES])dnl
dnl The testsuite driver may need to know about EXEEXT, so add the
dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
@@ -657,7 +675,7 @@ for _am_header in $config_headers :; do
done
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -678,7 +696,7 @@ if test x"${install_sh+set}" != xset; then
fi
AC_SUBST([install_sh])])
-# Copyright (C) 2003-2020 Free Software Foundation, Inc.
+# Copyright (C) 2003-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -700,7 +718,7 @@ AC_SUBST([am__leading_dot])])
# Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
# From Jim Meyering
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -735,7 +753,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
# Check to see how 'make' treats includes. -*- Autoconf -*-
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -778,7 +796,7 @@ AC_SUBST([am__quote])])
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
-# Copyright (C) 1997-2020 Free Software Foundation, Inc.
+# Copyright (C) 1997-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -812,7 +830,7 @@ fi
# Helper functions for option handling. -*- Autoconf -*-
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -841,7 +859,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
AC_DEFUN([_AM_IF_OPTION],
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -888,7 +906,7 @@ AC_LANG_POP([C])])
# For backward compatibility.
AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -907,7 +925,7 @@ AC_DEFUN([AM_RUN_LOG],
# Check to make sure that the build environment is sane. -*- Autoconf -*-
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -988,7 +1006,7 @@ AC_CONFIG_COMMANDS_PRE(
rm -f conftest.file
])
-# Copyright (C) 2009-2020 Free Software Foundation, Inc.
+# Copyright (C) 2009-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -1048,7 +1066,7 @@ AC_SUBST([AM_BACKSLASH])dnl
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
])
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -1076,7 +1094,7 @@ fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
AC_SUBST([INSTALL_STRIP_PROGRAM])])
-# Copyright (C) 2006-2020 Free Software Foundation, Inc.
+# Copyright (C) 2006-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -1095,7 +1113,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
# Check how to create a tarball. -*- Autoconf -*-
-# Copyright (C) 2004-2020 Free Software Foundation, Inc.
+# Copyright (C) 2004-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
diff --git a/apple/ar-lib b/apple/ar-lib
index 1e9388e..c349042 100755
--- a/apple/ar-lib
+++ b/apple/ar-lib
@@ -4,7 +4,7 @@
me=ar-lib
scriptversion=2019-07-04.01; # UTC
-# Copyright (C) 2010-2020 Free Software Foundation, Inc.
+# Copyright (C) 2010-2021 Free Software Foundation, Inc.
# Written by Peter Rosin .
#
# This program is free software; you can redistribute it and/or modify
diff --git a/apple/compile b/apple/compile
index 23fcba0..df363c8 100755
--- a/apple/compile
+++ b/apple/compile
@@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2021 Free Software Foundation, Inc.
# Written by Tom Tromey .
#
# This program is free software; you can redistribute it and/or modify
diff --git a/apple/config.guess b/apple/config.guess
index 9aff91c..e81d3ae 100755
--- a/apple/config.guess
+++ b/apple/config.guess
@@ -1,8 +1,10 @@
#! /bin/sh
# Attempt to guess a canonical system name.
-# Copyright 1992-2020 Free Software Foundation, Inc.
+# Copyright 1992-2021 Free Software Foundation, Inc.
-timestamp='2020-08-17'
+# shellcheck disable=SC2006,SC2268 # see below for rationale
+
+timestamp='2021-06-03'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -27,11 +29,19 @@ timestamp='2020-08-17'
# Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
#
# You can get the latest version of this script from:
-# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
+# https://git.savannah.gnu.org/cgit/config.git/plain/config.guess
#
# Please send patches to .
+# The "shellcheck disable" line above the timestamp inhibits complaints
+# about features and limitations of the classic Bourne shell that were
+# superseded or lifted in POSIX. However, this script identifies a wide
+# variety of pre-POSIX systems that do not have POSIX shells at all, and
+# even some reasonably current systems (Solaris 10 as case-in-point) still
+# have a pre-POSIX /bin/sh.
+
+
me=`echo "$0" | sed -e 's,.*/,,'`
usage="\
@@ -50,7 +60,7 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright 1992-2020 Free Software Foundation, Inc.
+Copyright 1992-2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -84,6 +94,9 @@ if test $# != 0; then
exit 1
fi
+# Just in case it came from the environment.
+GUESS=
+
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
# compiler to aid in system detection is discouraged as it requires
# temporary files to be created and, as you can see below, it is a
@@ -102,7 +115,7 @@ set_cc_for_build() {
# prevent multiple calls if $tmp is already set
test "$tmp" && return 0
: "${TMPDIR=/tmp}"
- # shellcheck disable=SC2039
+ # shellcheck disable=SC2039,SC3028
{ tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } ||
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } ||
@@ -112,7 +125,7 @@ set_cc_for_build() {
,,) echo "int x;" > "$dummy.c"
for driver in cc gcc c89 c99 ; do
if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then
- CC_FOR_BUILD="$driver"
+ CC_FOR_BUILD=$driver
break
fi
done
@@ -133,14 +146,12 @@ fi
UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
-UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
+UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
-case "$UNAME_SYSTEM" in
+case $UNAME_SYSTEM in
Linux|GNU|GNU/*)
- # If the system lacks a compiler, then just pick glibc.
- # We could probably try harder.
- LIBC=gnu
+ LIBC=unknown
set_cc_for_build
cat <<-EOF > "$dummy.c"
@@ -149,24 +160,37 @@ Linux|GNU|GNU/*)
LIBC=uclibc
#elif defined(__dietlibc__)
LIBC=dietlibc
- #else
+ #elif defined(__GLIBC__)
LIBC=gnu
+ #else
+ #include
+ /* First heuristic to detect musl libc. */
+ #ifdef __DEFINED_va_list
+ LIBC=musl
+ #endif
#endif
EOF
- eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`"
+ cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
+ eval "$cc_set_libc"
- # If ldd exists, use it to detect musl libc.
- if command -v ldd >/dev/null && \
- ldd --version 2>&1 | grep -q ^musl
- then
- LIBC=musl
+ # Second heuristic to detect musl libc.
+ if [ "$LIBC" = unknown ] &&
+ command -v ldd >/dev/null &&
+ ldd --version 2>&1 | grep -q ^musl; then
+ LIBC=musl
+ fi
+
+ # If the system lacks a compiler, then just pick glibc.
+ # We could probably try harder.
+ if [ "$LIBC" = unknown ]; then
+ LIBC=gnu
fi
;;
esac
# Note: order is significant - the case branches are not exclusive.
-case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
+case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in
*:NetBSD:*:*)
# NetBSD (nbsd) targets should (where applicable) match one or
# more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
@@ -178,12 +202,12 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
#
# Note: NetBSD doesn't particularly care about the vendor
# portion of the name. We always set it to "unknown".
- sysctl="sysctl -n hw.machine_arch"
UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
- "/sbin/$sysctl" 2>/dev/null || \
- "/usr/sbin/$sysctl" 2>/dev/null || \
+ /sbin/sysctl -n hw.machine_arch 2>/dev/null || \
+ /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \
echo unknown)`
- case "$UNAME_MACHINE_ARCH" in
+ case $UNAME_MACHINE_ARCH in
+ aarch64eb) machine=aarch64_be-unknown ;;
armeb) machine=armeb-unknown ;;
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
@@ -192,13 +216,13 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
earmv*)
arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'`
- machine="${arch}${endian}"-unknown
+ machine=${arch}${endian}-unknown
;;
- *) machine="$UNAME_MACHINE_ARCH"-unknown ;;
+ *) machine=$UNAME_MACHINE_ARCH-unknown ;;
esac
# The Operating System including object format, if it has switched
# to ELF recently (or will in the future) and ABI.
- case "$UNAME_MACHINE_ARCH" in
+ case $UNAME_MACHINE_ARCH in
earm*)
os=netbsdelf
;;
@@ -219,7 +243,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
;;
esac
# Determine ABI tags.
- case "$UNAME_MACHINE_ARCH" in
+ case $UNAME_MACHINE_ARCH in
earm*)
expr='s/^earmv[0-9]/-eabi/;s/eb$//'
abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"`
@@ -230,7 +254,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
# thus, need a distinct triplet. However, they do not need
# kernel version information, so it can be replaced with a
# suitable tag, in the style of linux-gnu.
- case "$UNAME_VERSION" in
+ case $UNAME_VERSION in
Debian*)
release='-gnu'
;;
@@ -241,51 +265,57 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
- echo "$machine-${os}${release}${abi-}"
- exit ;;
+ GUESS=$machine-${os}${release}${abi-}
+ ;;
*:Bitrig:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
- echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE
+ ;;
*:OpenBSD:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
- echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE
+ ;;
+ *:SecBSD:*:*)
+ UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'`
+ GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE
+ ;;
*:LibertyBSD:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
- echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE
+ ;;
*:MidnightBSD:*:*)
- echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE
+ ;;
*:ekkoBSD:*:*)
- echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE
+ ;;
*:SolidBSD:*:*)
- echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE
+ ;;
*:OS108:*:*)
- echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE
+ ;;
macppc:MirBSD:*:*)
- echo powerpc-unknown-mirbsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE
+ ;;
*:MirBSD:*:*)
- echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE
+ ;;
*:Sortix:*:*)
- echo "$UNAME_MACHINE"-unknown-sortix
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-sortix
+ ;;
*:Twizzler:*:*)
- echo "$UNAME_MACHINE"-unknown-twizzler
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-twizzler
+ ;;
*:Redox:*:*)
- echo "$UNAME_MACHINE"-unknown-redox
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-redox
+ ;;
mips:OSF1:*.*)
- echo mips-dec-osf1
- exit ;;
+ GUESS=mips-dec-osf1
+ ;;
alpha:OSF1:*:*)
+ # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
+ trap '' 0
case $UNAME_RELEASE in
*4.0)
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
@@ -299,7 +329,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
# covers most systems running today. This code pipes the CPU
# types through head -n 1, so we only detect the type of CPU 0.
ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
- case "$ALPHA_CPU_TYPE" in
+ case $ALPHA_CPU_TYPE in
"EV4 (21064)")
UNAME_MACHINE=alpha ;;
"EV4.5 (21064)")
@@ -336,68 +366,69 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
# A Tn.n version is a released field test version.
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
- echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`"
- # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
- exitcode=$?
- trap '' 0
- exit $exitcode ;;
+ OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
+ GUESS=$UNAME_MACHINE-dec-osf$OSF_REL
+ ;;
Amiga*:UNIX_System_V:4.0:*)
- echo m68k-unknown-sysv4
- exit ;;
+ GUESS=m68k-unknown-sysv4
+ ;;
*:[Aa]miga[Oo][Ss]:*:*)
- echo "$UNAME_MACHINE"-unknown-amigaos
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-amigaos
+ ;;
*:[Mm]orph[Oo][Ss]:*:*)
- echo "$UNAME_MACHINE"-unknown-morphos
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-morphos
+ ;;
*:OS/390:*:*)
- echo i370-ibm-openedition
- exit ;;
+ GUESS=i370-ibm-openedition
+ ;;
*:z/VM:*:*)
- echo s390-ibm-zvmoe
- exit ;;
+ GUESS=s390-ibm-zvmoe
+ ;;
*:OS400:*:*)
- echo powerpc-ibm-os400
- exit ;;
+ GUESS=powerpc-ibm-os400
+ ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
- echo arm-acorn-riscix"$UNAME_RELEASE"
- exit ;;
+ GUESS=arm-acorn-riscix$UNAME_RELEASE
+ ;;
arm*:riscos:*:*|arm*:RISCOS:*:*)
- echo arm-unknown-riscos
- exit ;;
+ GUESS=arm-unknown-riscos
+ ;;
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
- echo hppa1.1-hitachi-hiuxmpp
- exit ;;
+ GUESS=hppa1.1-hitachi-hiuxmpp
+ ;;
Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
# akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
- if test "`(/bin/universe) 2>/dev/null`" = att ; then
- echo pyramid-pyramid-sysv3
- else
- echo pyramid-pyramid-bsd
- fi
- exit ;;
+ case `(/bin/universe) 2>/dev/null` in
+ att) GUESS=pyramid-pyramid-sysv3 ;;
+ *) GUESS=pyramid-pyramid-bsd ;;
+ esac
+ ;;
NILE*:*:*:dcosx)
- echo pyramid-pyramid-svr4
- exit ;;
+ GUESS=pyramid-pyramid-svr4
+ ;;
DRS?6000:unix:4.0:6*)
- echo sparc-icl-nx6
- exit ;;
+ GUESS=sparc-icl-nx6
+ ;;
DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
case `/usr/bin/uname -p` in
- sparc) echo sparc-icl-nx7; exit ;;
- esac ;;
+ sparc) GUESS=sparc-icl-nx7 ;;
+ esac
+ ;;
s390x:SunOS:*:*)
- echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL
+ ;;
sun4H:SunOS:5.*:*)
- echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=sparc-hal-solaris2$SUN_REL
+ ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
- echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=sparc-sun-solaris2$SUN_REL
+ ;;
i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
- echo i386-pc-auroraux"$UNAME_RELEASE"
- exit ;;
+ GUESS=i386-pc-auroraux$UNAME_RELEASE
+ ;;
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
set_cc_for_build
SUN_ARCH=i386
@@ -412,41 +443,44 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
SUN_ARCH=x86_64
fi
fi
- echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=$SUN_ARCH-pc-solaris2$SUN_REL
+ ;;
sun4*:SunOS:6*:*)
# According to config.sub, this is the proper way to canonicalize
# SunOS6. Hard to guess exactly what SunOS6 will be like, but
# it's likely to be more like Solaris than SunOS4.
- echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=sparc-sun-solaris3$SUN_REL
+ ;;
sun4*:SunOS:*:*)
- case "`/usr/bin/arch -k`" in
+ case `/usr/bin/arch -k` in
Series*|S4*)
UNAME_RELEASE=`uname -v`
;;
esac
# Japanese Language versions have a version number like `4.1.3-JL'.
- echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'`
+ GUESS=sparc-sun-sunos$SUN_REL
+ ;;
sun3*:SunOS:*:*)
- echo m68k-sun-sunos"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-sun-sunos$UNAME_RELEASE
+ ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3
- case "`/bin/arch`" in
+ case `/bin/arch` in
sun3)
- echo m68k-sun-sunos"$UNAME_RELEASE"
+ GUESS=m68k-sun-sunos$UNAME_RELEASE
;;
sun4)
- echo sparc-sun-sunos"$UNAME_RELEASE"
+ GUESS=sparc-sun-sunos$UNAME_RELEASE
;;
esac
- exit ;;
+ ;;
aushp:SunOS:*:*)
- echo sparc-auspex-sunos"$UNAME_RELEASE"
- exit ;;
+ GUESS=sparc-auspex-sunos$UNAME_RELEASE
+ ;;
# The situation for MiNT is a little confusing. The machine name
# can be virtually everything (everything which is not
# "atarist" or "atariste" at least should have a processor
@@ -456,41 +490,41 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
# MiNT. But MiNT is downward compatible to TOS, so this should
# be no problem.
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
- echo m68k-atari-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-atari-mint$UNAME_RELEASE
+ ;;
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
- echo m68k-atari-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-atari-mint$UNAME_RELEASE
+ ;;
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
- echo m68k-atari-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-atari-mint$UNAME_RELEASE
+ ;;
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
- echo m68k-milan-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-milan-mint$UNAME_RELEASE
+ ;;
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
- echo m68k-hades-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-hades-mint$UNAME_RELEASE
+ ;;
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
- echo m68k-unknown-mint"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-unknown-mint$UNAME_RELEASE
+ ;;
m68k:machten:*:*)
- echo m68k-apple-machten"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-apple-machten$UNAME_RELEASE
+ ;;
powerpc:machten:*:*)
- echo powerpc-apple-machten"$UNAME_RELEASE"
- exit ;;
+ GUESS=powerpc-apple-machten$UNAME_RELEASE
+ ;;
RISC*:Mach:*:*)
- echo mips-dec-mach_bsd4.3
- exit ;;
+ GUESS=mips-dec-mach_bsd4.3
+ ;;
RISC*:ULTRIX:*:*)
- echo mips-dec-ultrix"$UNAME_RELEASE"
- exit ;;
+ GUESS=mips-dec-ultrix$UNAME_RELEASE
+ ;;
VAX*:ULTRIX*:*:*)
- echo vax-dec-ultrix"$UNAME_RELEASE"
- exit ;;
+ GUESS=vax-dec-ultrix$UNAME_RELEASE
+ ;;
2020:CLIX:*:* | 2430:CLIX:*:*)
- echo clipper-intergraph-clix"$UNAME_RELEASE"
- exit ;;
+ GUESS=clipper-intergraph-clix$UNAME_RELEASE
+ ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
@@ -518,29 +552,29 @@ EOF
dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` &&
SYSTEM_NAME=`"$dummy" "$dummyarg"` &&
{ echo "$SYSTEM_NAME"; exit; }
- echo mips-mips-riscos"$UNAME_RELEASE"
- exit ;;
+ GUESS=mips-mips-riscos$UNAME_RELEASE
+ ;;
Motorola:PowerMAX_OS:*:*)
- echo powerpc-motorola-powermax
- exit ;;
+ GUESS=powerpc-motorola-powermax
+ ;;
Motorola:*:4.3:PL8-*)
- echo powerpc-harris-powermax
- exit ;;
+ GUESS=powerpc-harris-powermax
+ ;;
Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
- echo powerpc-harris-powermax
- exit ;;
+ GUESS=powerpc-harris-powermax
+ ;;
Night_Hawk:Power_UNIX:*:*)
- echo powerpc-harris-powerunix
- exit ;;
+ GUESS=powerpc-harris-powerunix
+ ;;
m88k:CX/UX:7*:*)
- echo m88k-harris-cxux7
- exit ;;
+ GUESS=m88k-harris-cxux7
+ ;;
m88k:*:4*:R4*)
- echo m88k-motorola-sysv4
- exit ;;
+ GUESS=m88k-motorola-sysv4
+ ;;
m88k:*:3*:R3*)
- echo m88k-motorola-sysv3
- exit ;;
+ GUESS=m88k-motorola-sysv3
+ ;;
AViiON:dgux:*:*)
# DG/UX returns AViiON for all architectures
UNAME_PROCESSOR=`/usr/bin/uname -p`
@@ -549,44 +583,45 @@ EOF
if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \
test "$TARGET_BINARY_INTERFACE"x = x
then
- echo m88k-dg-dgux"$UNAME_RELEASE"
+ GUESS=m88k-dg-dgux$UNAME_RELEASE
else
- echo m88k-dg-dguxbcs"$UNAME_RELEASE"
+ GUESS=m88k-dg-dguxbcs$UNAME_RELEASE
fi
else
- echo i586-dg-dgux"$UNAME_RELEASE"
+ GUESS=i586-dg-dgux$UNAME_RELEASE
fi
- exit ;;
+ ;;
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
- echo m88k-dolphin-sysv3
- exit ;;
+ GUESS=m88k-dolphin-sysv3
+ ;;
M88*:*:R3*:*)
# Delta 88k system running SVR3
- echo m88k-motorola-sysv3
- exit ;;
+ GUESS=m88k-motorola-sysv3
+ ;;
XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
- echo m88k-tektronix-sysv3
- exit ;;
+ GUESS=m88k-tektronix-sysv3
+ ;;
Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
- echo m68k-tektronix-bsd
- exit ;;
+ GUESS=m68k-tektronix-bsd
+ ;;
*:IRIX*:*:*)
- echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`"
- exit ;;
+ IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'`
+ GUESS=mips-sgi-irix$IRIX_REL
+ ;;
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
- echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
- exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
+ GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id
+ ;; # Note that: echo "'`uname -s`'" gives 'AIX '
i*86:AIX:*:*)
- echo i386-ibm-aix
- exit ;;
+ GUESS=i386-ibm-aix
+ ;;
ia64:AIX:*:*)
if test -x /usr/bin/oslevel ; then
IBM_REV=`/usr/bin/oslevel`
else
- IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
+ IBM_REV=$UNAME_VERSION.$UNAME_RELEASE
fi
- echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV"
- exit ;;
+ GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV
+ ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
set_cc_for_build
@@ -603,16 +638,16 @@ EOF
EOF
if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"`
then
- echo "$SYSTEM_NAME"
+ GUESS=$SYSTEM_NAME
else
- echo rs6000-ibm-aix3.2.5
+ GUESS=rs6000-ibm-aix3.2.5
fi
elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
- echo rs6000-ibm-aix3.2.4
+ GUESS=rs6000-ibm-aix3.2.4
else
- echo rs6000-ibm-aix3.2
+ GUESS=rs6000-ibm-aix3.2
fi
- exit ;;
+ ;;
*:AIX:*:[4567])
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then
@@ -621,48 +656,48 @@ EOF
IBM_ARCH=powerpc
fi
if test -x /usr/bin/lslpp ; then
- IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
+ IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \
awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
else
- IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
+ IBM_REV=$UNAME_VERSION.$UNAME_RELEASE
fi
- echo "$IBM_ARCH"-ibm-aix"$IBM_REV"
- exit ;;
+ GUESS=$IBM_ARCH-ibm-aix$IBM_REV
+ ;;
*:AIX:*:*)
- echo rs6000-ibm-aix
- exit ;;
+ GUESS=rs6000-ibm-aix
+ ;;
ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*)
- echo romp-ibm-bsd4.4
- exit ;;
+ GUESS=romp-ibm-bsd4.4
+ ;;
ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
- echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to
- exit ;; # report: romp-ibm BSD 4.3
+ GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to
+ ;; # report: romp-ibm BSD 4.3
*:BOSX:*:*)
- echo rs6000-bull-bosx
- exit ;;
+ GUESS=rs6000-bull-bosx
+ ;;
DPX/2?00:B.O.S.:*:*)
- echo m68k-bull-sysv3
- exit ;;
+ GUESS=m68k-bull-sysv3
+ ;;
9000/[34]??:4.3bsd:1.*:*)
- echo m68k-hp-bsd
- exit ;;
+ GUESS=m68k-hp-bsd
+ ;;
hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
- echo m68k-hp-bsd4.4
- exit ;;
+ GUESS=m68k-hp-bsd4.4
+ ;;
9000/[34678]??:HP-UX:*:*)
- HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
- case "$UNAME_MACHINE" in
+ HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'`
+ case $UNAME_MACHINE in
9000/31?) HP_ARCH=m68000 ;;
9000/[34]??) HP_ARCH=m68k ;;
9000/[678][0-9][0-9])
if test -x /usr/bin/getconf; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
- case "$sc_cpu_version" in
+ case $sc_cpu_version in
523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
532) # CPU_PA_RISC2_0
- case "$sc_kernel_bits" in
+ case $sc_kernel_bits in
32) HP_ARCH=hppa2.0n ;;
64) HP_ARCH=hppa2.0w ;;
'') HP_ARCH=hppa2.0 ;; # HP-UX 10.20
@@ -729,12 +764,12 @@ EOF
HP_ARCH=hppa64
fi
fi
- echo "$HP_ARCH"-hp-hpux"$HPUX_REV"
- exit ;;
+ GUESS=$HP_ARCH-hp-hpux$HPUX_REV
+ ;;
ia64:HP-UX:*:*)
- HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
- echo ia64-hp-hpux"$HPUX_REV"
- exit ;;
+ HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'`
+ GUESS=ia64-hp-hpux$HPUX_REV
+ ;;
3050*:HI-UX:*:*)
set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
@@ -764,36 +799,36 @@ EOF
EOF
$CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` &&
{ echo "$SYSTEM_NAME"; exit; }
- echo unknown-hitachi-hiuxwe2
- exit ;;
+ GUESS=unknown-hitachi-hiuxwe2
+ ;;
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*)
- echo hppa1.1-hp-bsd
- exit ;;
+ GUESS=hppa1.1-hp-bsd
+ ;;
9000/8??:4.3bsd:*:*)
- echo hppa1.0-hp-bsd
- exit ;;
+ GUESS=hppa1.0-hp-bsd
+ ;;
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
- echo hppa1.0-hp-mpeix
- exit ;;
+ GUESS=hppa1.0-hp-mpeix
+ ;;
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*)
- echo hppa1.1-hp-osf
- exit ;;
+ GUESS=hppa1.1-hp-osf
+ ;;
hp8??:OSF1:*:*)
- echo hppa1.0-hp-osf
- exit ;;
+ GUESS=hppa1.0-hp-osf
+ ;;
i*86:OSF1:*:*)
if test -x /usr/sbin/sysversion ; then
- echo "$UNAME_MACHINE"-unknown-osf1mk
+ GUESS=$UNAME_MACHINE-unknown-osf1mk
else
- echo "$UNAME_MACHINE"-unknown-osf1
+ GUESS=$UNAME_MACHINE-unknown-osf1
fi
- exit ;;
+ ;;
parisc*:Lites*:*:*)
- echo hppa1.1-hp-lites
- exit ;;
+ GUESS=hppa1.1-hp-lites
+ ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
- echo c1-convex-bsd
- exit ;;
+ GUESS=c1-convex-bsd
+ ;;
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
@@ -801,17 +836,18 @@ EOF
fi
exit ;;
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
- echo c34-convex-bsd
- exit ;;
+ GUESS=c34-convex-bsd
+ ;;
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
- echo c38-convex-bsd
- exit ;;
+ GUESS=c38-convex-bsd
+ ;;
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
- echo c4-convex-bsd
- exit ;;
+ GUESS=c4-convex-bsd
+ ;;
CRAY*Y-MP:*:*:*)
- echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'`
+ GUESS=ymp-cray-unicos$CRAY_REL
+ ;;
CRAY*[A-Z]90:*:*:*)
echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
@@ -819,112 +855,124 @@ EOF
-e 's/\.[^.]*$/.X/'
exit ;;
CRAY*TS:*:*:*)
- echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'`
+ GUESS=t90-cray-unicos$CRAY_REL
+ ;;
CRAY*T3E:*:*:*)
- echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'`
+ GUESS=alphaev5-cray-unicosmk$CRAY_REL
+ ;;
CRAY*SV1:*:*:*)
- echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'`
+ GUESS=sv1-cray-unicos$CRAY_REL
+ ;;
*:UNICOS/mp:*:*)
- echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'`
+ GUESS=craynv-cray-unicosmp$CRAY_REL
+ ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'`
- echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit ;;
+ GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}
+ ;;
5000:UNIX_System_V:4.*:*)
FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
- echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit ;;
+ GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}
+ ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
- echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE
+ ;;
sparc*:BSD/OS:*:*)
- echo sparc-unknown-bsdi"$UNAME_RELEASE"
- exit ;;
+ GUESS=sparc-unknown-bsdi$UNAME_RELEASE
+ ;;
*:BSD/OS:*:*)
- echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE
+ ;;
arm:FreeBSD:*:*)
UNAME_PROCESSOR=`uname -p`
set_cc_for_build
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_PCS_VFP
then
- echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi
+ FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'`
+ GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi
else
- echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf
+ FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'`
+ GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf
fi
- exit ;;
+ ;;
*:FreeBSD:*:*)
UNAME_PROCESSOR=`/usr/bin/uname -p`
- case "$UNAME_PROCESSOR" in
+ case $UNAME_PROCESSOR in
amd64)
UNAME_PROCESSOR=x86_64 ;;
i386)
UNAME_PROCESSOR=i586 ;;
esac
- echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
- exit ;;
+ FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'`
+ GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL
+ ;;
i*:CYGWIN*:*)
- echo "$UNAME_MACHINE"-pc-cygwin
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-cygwin
+ ;;
*:MINGW64*:*)
- echo "$UNAME_MACHINE"-pc-mingw64
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-mingw64
+ ;;
*:MINGW*:*)
- echo "$UNAME_MACHINE"-pc-mingw32
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-mingw32
+ ;;
*:MSYS*:*)
- echo "$UNAME_MACHINE"-pc-msys
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-msys
+ ;;
i*:PW*:*)
- echo "$UNAME_MACHINE"-pc-pw32
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-pw32
+ ;;
*:Interix*:*)
- case "$UNAME_MACHINE" in
+ case $UNAME_MACHINE in
x86)
- echo i586-pc-interix"$UNAME_RELEASE"
- exit ;;
+ GUESS=i586-pc-interix$UNAME_RELEASE
+ ;;
authenticamd | genuineintel | EM64T)
- echo x86_64-unknown-interix"$UNAME_RELEASE"
- exit ;;
+ GUESS=x86_64-unknown-interix$UNAME_RELEASE
+ ;;
IA64)
- echo ia64-unknown-interix"$UNAME_RELEASE"
- exit ;;
+ GUESS=ia64-unknown-interix$UNAME_RELEASE
+ ;;
esac ;;
i*:UWIN*:*)
- echo "$UNAME_MACHINE"-pc-uwin
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-uwin
+ ;;
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
- echo x86_64-pc-cygwin
- exit ;;
+ GUESS=x86_64-pc-cygwin
+ ;;
prep*:SunOS:5.*:*)
- echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
- exit ;;
+ SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`
+ GUESS=powerpcle-unknown-solaris2$SUN_REL
+ ;;
*:GNU:*:*)
# the GNU system
- echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`"
- exit ;;
+ GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'`
+ GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'`
+ GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL
+ ;;
*:GNU/*:*:*)
# other systems with GNU libc and userland
- echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
- exit ;;
+ GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"`
+ GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'`
+ GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC
+ ;;
*:Minix:*:*)
- echo "$UNAME_MACHINE"-unknown-minix
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-minix
+ ;;
aarch64:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
aarch64_be:Linux:*:*)
UNAME_MACHINE=aarch64_be
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
alpha:Linux:*:*)
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in
EV5) UNAME_MACHINE=alphaev5 ;;
@@ -937,60 +985,63 @@ EOF
esac
objdump --private-headers /bin/sh | grep -q ld.so.1
if test "$?" = 0 ; then LIBC=gnulibc1 ; fi
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
- arc:Linux:*:* | arceb:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
+ arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*)
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
arm*:Linux:*:*)
set_cc_for_build
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_EABI__
then
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
else
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_PCS_VFP
then
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi
+ GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi
else
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf
+ GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf
fi
fi
- exit ;;
+ ;;
avr32*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
cris:Linux:*:*)
- echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-axis-linux-$LIBC
+ ;;
crisv32:Linux:*:*)
- echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-axis-linux-$LIBC
+ ;;
e2k:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
frv:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
hexagon:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
i*86:Linux:*:*)
- echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-linux-$LIBC
+ ;;
ia64:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
k1om:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
+ loongarch32:Linux:*:* | loongarch64:Linux:*:* | loongarchx32:Linux:*:*)
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
m32r*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
m68*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
mips:Linux:*:* | mips64:Linux:*:*)
set_cc_for_build
IS_GLIBC=0
@@ -1035,65 +1086,66 @@ EOF
#endif
#endif
EOF
- eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`"
+ cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`
+ eval "$cc_set_vars"
test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; }
;;
mips64el:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
openrisc*:Linux:*:*)
- echo or1k-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=or1k-unknown-linux-$LIBC
+ ;;
or32:Linux:*:* | or1k*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
padre:Linux:*:*)
- echo sparc-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=sparc-unknown-linux-$LIBC
+ ;;
parisc64:Linux:*:* | hppa64:Linux:*:*)
- echo hppa64-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=hppa64-unknown-linux-$LIBC
+ ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
- PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;;
- PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;;
- *) echo hppa-unknown-linux-"$LIBC" ;;
+ PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;;
+ PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;;
+ *) GUESS=hppa-unknown-linux-$LIBC ;;
esac
- exit ;;
+ ;;
ppc64:Linux:*:*)
- echo powerpc64-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=powerpc64-unknown-linux-$LIBC
+ ;;
ppc:Linux:*:*)
- echo powerpc-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=powerpc-unknown-linux-$LIBC
+ ;;
ppc64le:Linux:*:*)
- echo powerpc64le-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=powerpc64le-unknown-linux-$LIBC
+ ;;
ppcle:Linux:*:*)
- echo powerpcle-unknown-linux-"$LIBC"
- exit ;;
- riscv32:Linux:*:* | riscv64:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=powerpcle-unknown-linux-$LIBC
+ ;;
+ riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*)
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
s390:Linux:*:* | s390x:Linux:*:*)
- echo "$UNAME_MACHINE"-ibm-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-ibm-linux-$LIBC
+ ;;
sh64*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
sh*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
sparc:Linux:*:* | sparc64:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
tile*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
vax:Linux:*:*)
- echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-dec-linux-$LIBC
+ ;;
x86_64:Linux:*:*)
set_cc_for_build
LIBCABI=$LIBC
@@ -1102,56 +1154,56 @@ EOF
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
grep IS_X32 >/dev/null
then
- LIBCABI="$LIBC"x32
+ LIBCABI=${LIBC}x32
fi
fi
- echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI"
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-linux-$LIBCABI
+ ;;
xtensa*:Linux:*:*)
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
+ ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
# sysname and nodename.
- echo i386-sequent-sysv4
- exit ;;
+ GUESS=i386-sequent-sysv4
+ ;;
i*86:UNIX_SV:4.2MP:2.*)
# Unixware is an offshoot of SVR4, but it has its own version
# number series starting with 2...
# I am not positive that other SVR4 systems won't match this,
# I just have to hope. -- rms.
# Use sysv4.2uw... so that sysv4* matches it.
- echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION"
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION
+ ;;
i*86:OS/2:*:*)
# If we were able to find `uname', then EMX Unix compatibility
# is probably installed.
- echo "$UNAME_MACHINE"-pc-os2-emx
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-os2-emx
+ ;;
i*86:XTS-300:*:STOP)
- echo "$UNAME_MACHINE"-unknown-stop
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-stop
+ ;;
i*86:atheos:*:*)
- echo "$UNAME_MACHINE"-unknown-atheos
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-atheos
+ ;;
i*86:syllable:*:*)
- echo "$UNAME_MACHINE"-pc-syllable
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-syllable
+ ;;
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
- echo i386-unknown-lynxos"$UNAME_RELEASE"
- exit ;;
+ GUESS=i386-unknown-lynxos$UNAME_RELEASE
+ ;;
i*86:*DOS:*:*)
- echo "$UNAME_MACHINE"-pc-msdosdjgpp
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-msdosdjgpp
+ ;;
i*86:*:4.*:*)
UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
- echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL"
+ GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL
else
- echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL"
+ GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL
fi
- exit ;;
+ ;;
i*86:*:5:[678]*)
# UnixWare 7.x, OpenUNIX and OpenServer 6.
case `/bin/uname -X | grep "^Machine"` in
@@ -1159,12 +1211,12 @@ EOF
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
- echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
+ ;;
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then
UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
(/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
@@ -1174,11 +1226,11 @@ EOF
&& UNAME_MACHINE=i686
(/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
&& UNAME_MACHINE=i686
- echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL"
+ GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL
else
- echo "$UNAME_MACHINE"-pc-sysv32
+ GUESS=$UNAME_MACHINE-pc-sysv32
fi
- exit ;;
+ ;;
pc:*:*:*)
# Left here for compatibility:
# uname -m prints for DJGPP always 'pc', but it prints nothing about
@@ -1186,31 +1238,31 @@ EOF
# Note: whatever this is, it MUST be the same as what config.sub
# prints for the "djgpp" host, or else GDB configure will decide that
# this is a cross-build.
- echo i586-pc-msdosdjgpp
- exit ;;
+ GUESS=i586-pc-msdosdjgpp
+ ;;
Intel:Mach:3*:*)
- echo i386-pc-mach3
- exit ;;
+ GUESS=i386-pc-mach3
+ ;;
paragon:*:*:*)
- echo i860-intel-osf1
- exit ;;
+ GUESS=i860-intel-osf1
+ ;;
i860:*:4.*:*) # i860-SVR4
if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
- echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4
+ GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4
else # Add other i860-SVR4 vendors below as they are discovered.
- echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4
+ GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4
fi
- exit ;;
+ ;;
mini*:CTIX:SYS*5:*)
# "miniframe"
- echo m68010-convergent-sysv
- exit ;;
+ GUESS=m68010-convergent-sysv
+ ;;
mc68k:UNIX:SYSTEM5:3.51m)
- echo m68k-convergent-sysv
- exit ;;
+ GUESS=m68k-convergent-sysv
+ ;;
M680?0:D-NIX:5.3:*)
- echo m68k-diab-dnix
- exit ;;
+ GUESS=m68k-diab-dnix
+ ;;
M68*:*:R3V[5678]*:*)
test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
@@ -1235,116 +1287,116 @@ EOF
/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
&& { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;;
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
- echo m68k-unknown-lynxos"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-unknown-lynxos$UNAME_RELEASE
+ ;;
mc68030:UNIX_System_V:4.*:*)
- echo m68k-atari-sysv4
- exit ;;
+ GUESS=m68k-atari-sysv4
+ ;;
TSUNAMI:LynxOS:2.*:*)
- echo sparc-unknown-lynxos"$UNAME_RELEASE"
- exit ;;
+ GUESS=sparc-unknown-lynxos$UNAME_RELEASE
+ ;;
rs6000:LynxOS:2.*:*)
- echo rs6000-unknown-lynxos"$UNAME_RELEASE"
- exit ;;
+ GUESS=rs6000-unknown-lynxos$UNAME_RELEASE
+ ;;
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
- echo powerpc-unknown-lynxos"$UNAME_RELEASE"
- exit ;;
+ GUESS=powerpc-unknown-lynxos$UNAME_RELEASE
+ ;;
SM[BE]S:UNIX_SV:*:*)
- echo mips-dde-sysv"$UNAME_RELEASE"
- exit ;;
+ GUESS=mips-dde-sysv$UNAME_RELEASE
+ ;;
RM*:ReliantUNIX-*:*:*)
- echo mips-sni-sysv4
- exit ;;
+ GUESS=mips-sni-sysv4
+ ;;
RM*:SINIX-*:*:*)
- echo mips-sni-sysv4
- exit ;;
+ GUESS=mips-sni-sysv4
+ ;;
*:SINIX-*:*:*)
if uname -p 2>/dev/null >/dev/null ; then
UNAME_MACHINE=`(uname -p) 2>/dev/null`
- echo "$UNAME_MACHINE"-sni-sysv4
+ GUESS=$UNAME_MACHINE-sni-sysv4
else
- echo ns32k-sni-sysv
+ GUESS=ns32k-sni-sysv
fi
- exit ;;
+ ;;
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
# says
- echo i586-unisys-sysv4
- exit ;;
+ GUESS=i586-unisys-sysv4
+ ;;
*:UNIX_System_V:4*:FTX*)
# From Gerald Hewes .
# How about differentiating between stratus architectures? -djm
- echo hppa1.1-stratus-sysv4
- exit ;;
+ GUESS=hppa1.1-stratus-sysv4
+ ;;
*:*:*:FTX*)
# From seanf@swdc.stratus.com.
- echo i860-stratus-sysv4
- exit ;;
+ GUESS=i860-stratus-sysv4
+ ;;
i*86:VOS:*:*)
# From Paul.Green@stratus.com.
- echo "$UNAME_MACHINE"-stratus-vos
- exit ;;
+ GUESS=$UNAME_MACHINE-stratus-vos
+ ;;
*:VOS:*:*)
# From Paul.Green@stratus.com.
- echo hppa1.1-stratus-vos
- exit ;;
+ GUESS=hppa1.1-stratus-vos
+ ;;
mc68*:A/UX:*:*)
- echo m68k-apple-aux"$UNAME_RELEASE"
- exit ;;
+ GUESS=m68k-apple-aux$UNAME_RELEASE
+ ;;
news*:NEWS-OS:6*:*)
- echo mips-sony-newsos6
- exit ;;
+ GUESS=mips-sony-newsos6
+ ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
if test -d /usr/nec; then
- echo mips-nec-sysv"$UNAME_RELEASE"
+ GUESS=mips-nec-sysv$UNAME_RELEASE
else
- echo mips-unknown-sysv"$UNAME_RELEASE"
+ GUESS=mips-unknown-sysv$UNAME_RELEASE
fi
- exit ;;
+ ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
- echo powerpc-be-beos
- exit ;;
+ GUESS=powerpc-be-beos
+ ;;
BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
- echo powerpc-apple-beos
- exit ;;
+ GUESS=powerpc-apple-beos
+ ;;
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
- echo i586-pc-beos
- exit ;;
+ GUESS=i586-pc-beos
+ ;;
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
- echo i586-pc-haiku
- exit ;;
+ GUESS=i586-pc-haiku
+ ;;
x86_64:Haiku:*:*)
- echo x86_64-unknown-haiku
- exit ;;
+ GUESS=x86_64-unknown-haiku
+ ;;
SX-4:SUPER-UX:*:*)
- echo sx4-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx4-nec-superux$UNAME_RELEASE
+ ;;
SX-5:SUPER-UX:*:*)
- echo sx5-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx5-nec-superux$UNAME_RELEASE
+ ;;
SX-6:SUPER-UX:*:*)
- echo sx6-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx6-nec-superux$UNAME_RELEASE
+ ;;
SX-7:SUPER-UX:*:*)
- echo sx7-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx7-nec-superux$UNAME_RELEASE
+ ;;
SX-8:SUPER-UX:*:*)
- echo sx8-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx8-nec-superux$UNAME_RELEASE
+ ;;
SX-8R:SUPER-UX:*:*)
- echo sx8r-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sx8r-nec-superux$UNAME_RELEASE
+ ;;
SX-ACE:SUPER-UX:*:*)
- echo sxace-nec-superux"$UNAME_RELEASE"
- exit ;;
+ GUESS=sxace-nec-superux$UNAME_RELEASE
+ ;;
Power*:Rhapsody:*:*)
- echo powerpc-apple-rhapsody"$UNAME_RELEASE"
- exit ;;
+ GUESS=powerpc-apple-rhapsody$UNAME_RELEASE
+ ;;
*:Rhapsody:*:*)
- echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE
+ ;;
arm64:Darwin:*:*)
- echo aarch64-apple-darwin"$UNAME_RELEASE"
- exit ;;
+ GUESS=aarch64-apple-darwin$UNAME_RELEASE
+ ;;
*:Darwin:*:*)
UNAME_PROCESSOR=`uname -p`
case $UNAME_PROCESSOR in
@@ -1380,109 +1432,116 @@ EOF
# uname -m returns i386 or x86_64
UNAME_PROCESSOR=$UNAME_MACHINE
fi
- echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE
+ ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
UNAME_PROCESSOR=`uname -p`
if test "$UNAME_PROCESSOR" = x86; then
UNAME_PROCESSOR=i386
UNAME_MACHINE=pc
fi
- echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE
+ ;;
*:QNX:*:4*)
- echo i386-pc-qnx
- exit ;;
+ GUESS=i386-pc-qnx
+ ;;
NEO-*:NONSTOP_KERNEL:*:*)
- echo neo-tandem-nsk"$UNAME_RELEASE"
- exit ;;
+ GUESS=neo-tandem-nsk$UNAME_RELEASE
+ ;;
NSE-*:NONSTOP_KERNEL:*:*)
- echo nse-tandem-nsk"$UNAME_RELEASE"
- exit ;;
+ GUESS=nse-tandem-nsk$UNAME_RELEASE
+ ;;
NSR-*:NONSTOP_KERNEL:*:*)
- echo nsr-tandem-nsk"$UNAME_RELEASE"
- exit ;;
+ GUESS=nsr-tandem-nsk$UNAME_RELEASE
+ ;;
NSV-*:NONSTOP_KERNEL:*:*)
- echo nsv-tandem-nsk"$UNAME_RELEASE"
- exit ;;
+ GUESS=nsv-tandem-nsk$UNAME_RELEASE
+ ;;
NSX-*:NONSTOP_KERNEL:*:*)
- echo nsx-tandem-nsk"$UNAME_RELEASE"
- exit ;;
+ GUESS=nsx-tandem-nsk$UNAME_RELEASE
+ ;;
*:NonStop-UX:*:*)
- echo mips-compaq-nonstopux
- exit ;;
+ GUESS=mips-compaq-nonstopux
+ ;;
BS2000:POSIX*:*:*)
- echo bs2000-siemens-sysv
- exit ;;
+ GUESS=bs2000-siemens-sysv
+ ;;
DS/*:UNIX_System_V:*:*)
- echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE
+ ;;
*:Plan9:*:*)
# "uname -m" is not consistent, so use $cputype instead. 386
# is converted to i386 for consistency with other x86
# operating systems.
- # shellcheck disable=SC2154
- if test "$cputype" = 386; then
+ if test "${cputype-}" = 386; then
UNAME_MACHINE=i386
- else
- UNAME_MACHINE="$cputype"
+ elif test "x${cputype-}" != x; then
+ UNAME_MACHINE=$cputype
fi
- echo "$UNAME_MACHINE"-unknown-plan9
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-plan9
+ ;;
*:TOPS-10:*:*)
- echo pdp10-unknown-tops10
- exit ;;
+ GUESS=pdp10-unknown-tops10
+ ;;
*:TENEX:*:*)
- echo pdp10-unknown-tenex
- exit ;;
+ GUESS=pdp10-unknown-tenex
+ ;;
KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
- echo pdp10-dec-tops20
- exit ;;
+ GUESS=pdp10-dec-tops20
+ ;;
XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
- echo pdp10-xkl-tops20
- exit ;;
+ GUESS=pdp10-xkl-tops20
+ ;;
*:TOPS-20:*:*)
- echo pdp10-unknown-tops20
- exit ;;
+ GUESS=pdp10-unknown-tops20
+ ;;
*:ITS:*:*)
- echo pdp10-unknown-its
- exit ;;
+ GUESS=pdp10-unknown-its
+ ;;
SEI:*:*:SEIUX)
- echo mips-sei-seiux"$UNAME_RELEASE"
- exit ;;
+ GUESS=mips-sei-seiux$UNAME_RELEASE
+ ;;
*:DragonFly:*:*)
- echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
- exit ;;
+ DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'`
+ GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL
+ ;;
*:*VMS:*:*)
UNAME_MACHINE=`(uname -p) 2>/dev/null`
- case "$UNAME_MACHINE" in
- A*) echo alpha-dec-vms ; exit ;;
- I*) echo ia64-dec-vms ; exit ;;
- V*) echo vax-dec-vms ; exit ;;
+ case $UNAME_MACHINE in
+ A*) GUESS=alpha-dec-vms ;;
+ I*) GUESS=ia64-dec-vms ;;
+ V*) GUESS=vax-dec-vms ;;
esac ;;
*:XENIX:*:SysV)
- echo i386-pc-xenix
- exit ;;
+ GUESS=i386-pc-xenix
+ ;;
i*86:skyos:*:*)
- echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`"
- exit ;;
+ SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`
+ GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL
+ ;;
i*86:rdos:*:*)
- echo "$UNAME_MACHINE"-pc-rdos
- exit ;;
- i*86:AROS:*:*)
- echo "$UNAME_MACHINE"-pc-aros
- exit ;;
+ GUESS=$UNAME_MACHINE-pc-rdos
+ ;;
+ *:AROS:*:*)
+ GUESS=$UNAME_MACHINE-unknown-aros
+ ;;
x86_64:VMkernel:*:*)
- echo "$UNAME_MACHINE"-unknown-esx
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-esx
+ ;;
amd64:Isilon\ OneFS:*:*)
- echo x86_64-unknown-onefs
- exit ;;
+ GUESS=x86_64-unknown-onefs
+ ;;
*:Unleashed:*:*)
- echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE"
- exit ;;
+ GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE
+ ;;
esac
+# Do we have a guess based on uname results?
+if test "x$GUESS" != x; then
+ echo "$GUESS"
+ exit
+fi
+
# No uname command or uname output not recognized.
set_cc_for_build
cat > "$dummy.c" </dev/null && SYSTEM_NAME=`$dummy` &&
+$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` &&
{ echo "$SYSTEM_NAME"; exit; }
# Apollos put the system type in the environment.
@@ -1622,7 +1681,7 @@ test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; }
echo "$0: unable to guess system type" >&2
-case "$UNAME_MACHINE:$UNAME_SYSTEM" in
+case $UNAME_MACHINE:$UNAME_SYSTEM in
mips:Linux | mips64:Linux)
# If we got here on MIPS GNU/Linux, output extra information.
cat >&2 <&2 <&2
@@ -1749,8 +1778,12 @@ case $kernel-$os in
;;
kfreebsd*-gnu* | kopensolaris*-gnu*)
;;
+ vxworks-simlinux | vxworks-simwindows | vxworks-spe)
+ ;;
nto-qnx*)
;;
+ os2-emx)
+ ;;
*-eabi* | *-gnueabi*)
;;
-*)
diff --git a/apple/configure b/apple/configure
index 505c466..46b3882 100755
--- a/apple/configure
+++ b/apple/configure
@@ -1,11 +1,12 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for ffmpeg-kit 4.4.
+# Generated by GNU Autoconf 2.71 for ffmpeg-kit 4.5.1.
#
# Report bugs to .
#
#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
+# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
+# Inc.
#
#
# This configure script is free software; the Free Software Foundation
@@ -16,14 +17,16 @@
# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
+as_nop=:
+if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
+then :
emulate sh
NULLCMD=:
# Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
setopt NO_GLOB_SUBST
-else
+else $as_nop
case `(set -o) 2>/dev/null` in #(
*posix*) :
set -o posix ;; #(
@@ -33,46 +36,46 @@ esac
fi
+
+# Reset variables that may have inherited troublesome values from
+# the environment.
+
+# IFS needs to be set, to space, tab, and newline, in precisely that order.
+# (If _AS_PATH_WALK were called with IFS unset, it would have the
+# side effect of setting IFS to empty, thus disabling word splitting.)
+# Quoting is to prevent editors from complaining about space-tab.
as_nl='
'
export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
+IFS=" "" $as_nl"
+
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# Ensure predictable behavior from utilities with locale-dependent output.
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
+
+# We cannot yet rely on "unset" to work, but we need these variables
+# to be unset--not just set to an empty or harmless value--now, to
+# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
+# also avoids known problems related to "unset" and subshell syntax
+# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
+for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
+do eval test \${$as_var+y} \
+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
+done
+
+# Ensure that fds 0, 1, and 2 are open.
+if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
+if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
+if ${PATH_SEPARATOR+false} :; then
PATH_SEPARATOR=:
(PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
(PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
@@ -81,13 +84,6 @@ if test "${PATH_SEPARATOR+set}" != set; then
fi
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
# Find who we are. Look in the path if we contain no directory separator.
as_myself=
case $0 in #((
@@ -96,8 +92,12 @@ case $0 in #((
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ test -r "$as_dir$0" && as_myself=$as_dir$0 && break
done
IFS=$as_save_IFS
@@ -109,30 +109,10 @@ if test "x$as_myself" = x; then
as_myself=$0
fi
if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
exit 1
fi
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
# Use a proper internal environment variable to ensure we don't fall
# into an infinite loop, continuously re-executing ourselves.
@@ -154,20 +134,22 @@ esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
+printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
+exit 255
fi
# We don't want this to propagate to other subprocesses.
{ _as_can_reexec=; unset _as_can_reexec;}
if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
+ as_bourne_compatible="as_nop=:
+if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
+then :
emulate sh
NULLCMD=:
# Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
# is contrary to our usage. Disable this feature.
alias -g '\${1+\"\$@\"}'='\"\$@\"'
setopt NO_GLOB_SUBST
-else
+else \$as_nop
case \`(set -o) 2>/dev/null\` in #(
*posix*) :
set -o posix ;; #(
@@ -187,18 +169,20 @@ as_fn_success || { exitcode=1; echo as_fn_success failed.; }
as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
+if ( set x; as_fn_ret_success y && test x = \"\$1\" )
+then :
-else
+else \$as_nop
exitcode=1; echo positional parameters were not saved.
fi
test x\$exitcode = x0 || exit 1
+blah=\$(echo \$(echo blah))
+test x\"\$blah\" = xblah || exit 1
test -x / || exit 1"
as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
@@ -206,31 +190,40 @@ test \$(( 1 + 1 )) = 2 || exit 1
ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
PATH=/empty FPATH=/empty; export PATH FPATH
test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
+ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1
+test \$(( 1 + 1 )) = 2 || exit 1"
+ if (eval "$as_required") 2>/dev/null
+then :
as_have_required=yes
-else
+else $as_nop
as_have_required=no
fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
+ if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
+then :
-else
+else $as_nop
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
as_found=false
for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
as_found=:
case $as_dir in #(
/*)
for as_base in sh bash ksh sh5; do
# Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
+ as_shell=$as_dir$as_base
if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
+ as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
+then :
CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
+ if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
+then :
break 2
fi
fi
@@ -238,14 +231,21 @@ fi
esac
as_found=false
done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
IFS=$as_save_IFS
+if $as_found
+then :
+
+else $as_nop
+ if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
+ as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
+then :
+ CONFIG_SHELL=$SHELL as_have_required=yes
+fi
+fi
- if test "x$CONFIG_SHELL" != x; then :
+ if test "x$CONFIG_SHELL" != x
+then :
export CONFIG_SHELL
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
@@ -263,18 +263,19 @@ esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
+printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
exit 255
fi
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
+ if test x$as_have_required = xno
+then :
+ printf "%s\n" "$0: This script requires a shell more modern than all"
+ printf "%s\n" "$0: the shells that I found on your system."
+ if test ${ZSH_VERSION+y} ; then
+ printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
+ printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
else
- $as_echo "$0: Please tell bug-autoconf@gnu.org and
+ printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and
$0: https://github.com/tanersener/ffmpeg-kit/issues/new
$0: about your system, including any error possibly output
$0: before this message. Then install a modern shell, or
@@ -303,6 +304,7 @@ as_fn_unset ()
}
as_unset=as_fn_unset
+
# as_fn_set_status STATUS
# -----------------------
# Set $? to STATUS, without forking.
@@ -320,6 +322,14 @@ as_fn_exit ()
as_fn_set_status $1
exit $1
} # as_fn_exit
+# as_fn_nop
+# ---------
+# Do nothing but, unlike ":", preserve the value of $?.
+as_fn_nop ()
+{
+ return $?
+}
+as_nop=as_fn_nop
# as_fn_mkdir_p
# -------------
@@ -334,7 +344,7 @@ as_fn_mkdir_p ()
as_dirs=
while :; do
case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
+ *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
*) as_qdir=$as_dir;;
esac
as_dirs="'$as_qdir' $as_dirs"
@@ -343,7 +353,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
+printf "%s\n" X"$as_dir" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -382,12 +392,13 @@ as_fn_executable_p ()
# advantage of any shell optimizations that allow amortized linear growth over
# repeated appends, instead of the typical quadratic growth present in naive
# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
+then :
eval 'as_fn_append ()
{
eval $1+=\$2
}'
-else
+else $as_nop
as_fn_append ()
{
eval $1=\$$1\$2
@@ -399,18 +410,27 @@ fi # as_fn_append
# Perform arithmetic evaluation on the ARGs, and store the result in the
# global $as_val. Take advantage of shells that can avoid forks. The arguments
# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
+then :
eval 'as_fn_arith ()
{
as_val=$(( $* ))
}'
-else
+else $as_nop
as_fn_arith ()
{
as_val=`expr "$@" || test $? -eq 1`
}
fi # as_fn_arith
+# as_fn_nop
+# ---------
+# Do nothing but, unlike ":", preserve the value of $?.
+as_fn_nop ()
+{
+ return $?
+}
+as_nop=as_fn_nop
# as_fn_error STATUS ERROR [LINENO LOG_FD]
# ----------------------------------------
@@ -422,9 +442,9 @@ as_fn_error ()
as_status=$1; test $as_status -eq 0 && as_status=1
if test "$4"; then
as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
fi
- $as_echo "$as_me: error: $2" >&2
+ printf "%s\n" "$as_me: error: $2" >&2
as_fn_exit $as_status
} # as_fn_error
@@ -451,7 +471,7 @@ as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
+printf "%s\n" X/"$0" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
@@ -495,7 +515,7 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits
s/-\n.*//
' >$as_me.lineno &&
chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
+ { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
# If we had to re-execute with $CONFIG_SHELL, we're ensured to have
# already done that, so ensure we don't try to do so again and fall
@@ -509,6 +529,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits
exit
}
+
+# Determine whether it's possible to make 'echo' print without a newline.
+# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
+# for compatibility with existing Makefiles.
ECHO_C= ECHO_N= ECHO_T=
case `echo -n x` in #(((((
-n*)
@@ -522,6 +546,13 @@ case `echo -n x` in #(((((
ECHO_N='-n';;
esac
+# For backward compatibility with old third-party macros, we provide
+# the shell variables $as_echo and $as_echo_n. New code should use
+# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
+as_echo='printf %s\n'
+as_echo_n='printf %s'
+
+
rm -f conf$$ conf$$.exe conf$$.file
if test -d conf$$.dir; then
rm -f conf$$.dir/conf$$.file
@@ -591,48 +622,44 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='ffmpeg-kit'
PACKAGE_TARNAME='ffmpeg-kit'
-PACKAGE_VERSION='4.4'
-PACKAGE_STRING='ffmpeg-kit 4.4'
+PACKAGE_VERSION='4.5.1'
+PACKAGE_STRING='ffmpeg-kit 4.5.1'
PACKAGE_BUGREPORT='https://github.com/tanersener/ffmpeg-kit/issues/new'
PACKAGE_URL=''
ac_unique_file="src/FFmpegKit.m"
# Factoring default headers for most tests.
ac_includes_default="\
-#include
-#ifdef HAVE_SYS_TYPES_H
-# include
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include
+#include
+#ifdef HAVE_STDIO_H
+# include
#endif
-#ifdef STDC_HEADERS
+#ifdef HAVE_STDLIB_H
# include
-# include
-#else
-# ifdef HAVE_STDLIB_H
-# include
-# endif
#endif
#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include
-# endif
# include
#endif
-#ifdef HAVE_STRINGS_H
-# include
-#endif
#ifdef HAVE_INTTYPES_H
# include
#endif
#ifdef HAVE_STDINT_H
# include
#endif
+#ifdef HAVE_STRINGS_H
+# include
+#endif
+#ifdef HAVE_SYS_TYPES_H
+# include
+#endif
+#ifdef HAVE_SYS_STAT_H
+# include
+#endif
#ifdef HAVE_UNISTD_H
# include
#endif"
+ac_header_c_list=
ac_subst_vars='am__EXEEXT_FALSE
am__EXEEXT_TRUE
LTLIBOBJS
@@ -655,9 +682,11 @@ ac_ct_DUMPBIN
DUMPBIN
LD
FGREP
+EGREP
+GREP
SED
LIBTOOL
-FFMPEG_LIBS
+FFMPEG_FRAMEWORKS
am__fastdepOBJC_FALSE
am__fastdepOBJC_TRUE
OBJCDEPMODE
@@ -666,9 +695,6 @@ OBJCFLAGS
OBJC
ac_ct_AR
AR
-EGREP
-GREP
-CPP
am__fastdepCC_FALSE
am__fastdepCC_TRUE
CCDEPMODE
@@ -700,6 +726,9 @@ AM_BACKSLASH
AM_DEFAULT_VERBOSITY
AM_DEFAULT_V
AM_V
+CSCOPE
+ETAGS
+CTAGS
am__untar
am__tar
AMTAR
@@ -742,6 +771,7 @@ infodir
docdir
oldincludedir
includedir
+runstatedir
localstatedir
sharedstatedir
sysconfdir
@@ -786,7 +816,6 @@ CFLAGS
LDFLAGS
LIBS
CPPFLAGS
-CPP
OBJC
OBJCFLAGS
LT_SYS_LIBRARY_PATH'
@@ -828,6 +857,7 @@ datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
+runstatedir='${localstatedir}/run'
includedir='${prefix}/include'
oldincludedir='/usr/include'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
@@ -857,8 +887,6 @@ do
*) ac_optarg=yes ;;
esac
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
case $ac_dashdash$ac_option in
--)
ac_dashdash=yes ;;
@@ -899,9 +927,9 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
+ as_fn_error $? "invalid feature name: \`$ac_useropt'"
ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
*"
"enable_$ac_useropt"
@@ -925,9 +953,9 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
+ as_fn_error $? "invalid feature name: \`$ac_useropt'"
ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
*"
"enable_$ac_useropt"
@@ -1080,6 +1108,15 @@ do
| -silent | --silent | --silen | --sile | --sil)
silent=yes ;;
+ -runstatedir | --runstatedir | --runstatedi | --runstated \
+ | --runstate | --runstat | --runsta | --runst | --runs \
+ | --run | --ru | --r)
+ ac_prev=runstatedir ;;
+ -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
+ | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
+ | --run=* | --ru=* | --r=*)
+ runstatedir=$ac_optarg ;;
+
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
ac_prev=sbindir ;;
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
@@ -1129,9 +1166,9 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
+ as_fn_error $? "invalid package name: \`$ac_useropt'"
ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
*"
"with_$ac_useropt"
@@ -1145,9 +1182,9 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
+ as_fn_error $? "invalid package name: \`$ac_useropt'"
ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
*"
"with_$ac_useropt"
@@ -1191,9 +1228,9 @@ Try \`$0 --help' for more information"
*)
# FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
+ printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
+ printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
: "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
;;
@@ -1209,7 +1246,7 @@ if test -n "$ac_unrecognized_opts"; then
case $enable_option_checking in
no) ;;
fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
+ *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
esac
fi
@@ -1217,7 +1254,7 @@ fi
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
datadir sysconfdir sharedstatedir localstatedir includedir \
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
+ libdir localedir mandir runstatedir
do
eval ac_val=\$$ac_var
# Remove trailing slashes.
@@ -1273,7 +1310,7 @@ $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_myself" : 'X\(//\)[^/]' \| \
X"$as_myself" : 'X\(//\)$' \| \
X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
+printf "%s\n" X"$as_myself" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -1330,7 +1367,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures ffmpeg-kit 4.4 to adapt to many kinds of systems.
+\`configure' configures ffmpeg-kit 4.5.1 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1370,6 +1407,7 @@ Fine tuning of the installation directories:
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
+ --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
@@ -1400,7 +1438,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of ffmpeg-kit 4.4:";;
+ short | recursive ) echo "Configuration of ffmpeg-kit 4.5.1:";;
esac
cat <<\_ACEOF
@@ -1444,7 +1482,6 @@ Some influential environment variables:
LIBS libraries to pass to the linker, e.g. -l
CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if
you have headers in a nonstandard directory
- CPP C preprocessor
OBJC Objective C compiler command
OBJCFLAGS Objective C compiler flags
LT_SYS_LIBRARY_PATH
@@ -1469,9 +1506,9 @@ if test "$ac_init_help" = "recursive"; then
case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
+ ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
# A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
+ ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
case $ac_top_builddir_sub in
"") ac_top_builddir_sub=. ac_top_build_prefix= ;;
*) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
@@ -1499,7 +1536,8 @@ esac
ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
+ # Check for configure.gnu first; this name is used for a wrapper for
+ # Metaconfig's "Configure" on case-insensitive file systems.
if test -f "$ac_srcdir/configure.gnu"; then
echo &&
$SHELL "$ac_srcdir/configure.gnu" --help=recursive
@@ -1507,7 +1545,7 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
echo &&
$SHELL "$ac_srcdir/configure" --help=recursive
else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
+ printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
fi || ac_status=$?
cd "$ac_pwd" || { ac_status=$?; break; }
done
@@ -1516,10 +1554,10 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-ffmpeg-kit configure 4.4
-generated by GNU Autoconf 2.69
+ffmpeg-kit configure 4.5.1
+generated by GNU Autoconf 2.71
-Copyright (C) 2012 Free Software Foundation, Inc.
+Copyright (C) 2021 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
@@ -1536,14 +1574,14 @@ fi
ac_fn_c_try_compile ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
+ rm -f conftest.$ac_objext conftest.beam
if { { ac_try="$ac_compile"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_compile") 2>conftest.err
ac_status=$?
if test -s conftest.err; then
@@ -1551,14 +1589,15 @@ $as_echo "$ac_try_echo"; } >&5
cat conftest.er1 >&5
mv -f conftest.er1 conftest.err
fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
+ } && test -s conftest.$ac_objext
+then :
ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
+else $as_nop
+ printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=1
@@ -1570,8 +1609,8 @@ fi
# ac_fn_c_try_run LINENO
# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
+# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
+# executables *can* be run.
ac_fn_c_try_run ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
@@ -1581,25 +1620,26 @@ case "(($ac_try" in
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_link") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
{ { case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_try") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; }
+then :
ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
+else $as_nop
+ printf "%s\n" "$as_me: program exited with status $ac_status" >&5
+ printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=$ac_status
@@ -1610,43 +1650,6 @@ fi
} # ac_fn_c_try_run
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
# -------------------------------------------------------
# Tests whether HEADER exists and can be compiled using the include files in
@@ -1654,26 +1657,28 @@ fi
ac_fn_c_check_header_compile ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+printf %s "checking for $2... " >&6; }
+if eval test \${$3+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
#include <$2>
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
eval "$3=yes"
-else
+else $as_nop
eval "$3=no"
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+printf "%s\n" "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_header_compile
@@ -1684,14 +1689,14 @@ $as_echo "$ac_res" >&6; }
ac_fn_objc_try_compile ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
+ rm -f conftest.$ac_objext conftest.beam
if { { ac_try="$ac_compile"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_compile") 2>conftest.err
ac_status=$?
if test -s conftest.err; then
@@ -1699,14 +1704,15 @@ $as_echo "$ac_try_echo"; } >&5
cat conftest.er1 >&5
mv -f conftest.er1 conftest.err
fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && {
test -z "$ac_objc_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
+ } && test -s conftest.$ac_objext
+then :
ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
+else $as_nop
+ printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=1
@@ -1722,14 +1728,14 @@ fi
ac_fn_c_try_link ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
+ rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
if { { ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_link") 2>conftest.err
ac_status=$?
if test -s conftest.err; then
@@ -1737,17 +1743,18 @@ $as_echo "$ac_try_echo"; } >&5
cat conftest.er1 >&5
mv -f conftest.er1 conftest.err
fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest$ac_exeext && {
test "$cross_compiling" = yes ||
test -x conftest$ac_exeext
- }; then :
+ }
+then :
ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
+else $as_nop
+ printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=1
@@ -1768,11 +1775,12 @@ fi
ac_fn_c_check_func ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+printf %s "checking for $2... " >&6; }
+if eval test \${$3+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Define $2 to an innocuous variant, in case declares $2.
@@ -1780,16 +1788,9 @@ else
#define $2 innocuous_$2
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
+ which can conflict with char $2 (); below. */
+#include
#undef $2
/* Override any GCC internal prototype to avoid an error.
@@ -1807,119 +1808,29 @@ choke me
#endif
int
-main ()
+main (void)
{
return $2 ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
eval "$3=yes"
-else
+else $as_nop
eval "$3=no"
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
fi
eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+printf "%s\n" "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_func
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-( $as_echo "## ------------------------------------------------------------------ ##
-## Report this to https://github.com/tanersener/ffmpeg-kit/issues/new ##
-## ------------------------------------------------------------------ ##"
- ) | sed "s/^/$as_me: WARNING: /" >&2
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
# ac_fn_c_find_intX_t LINENO BITS VAR
# -----------------------------------
# Finds a signed integer type with width BITS, setting cache variable VAR
@@ -1927,11 +1838,12 @@ fi
ac_fn_c_find_intX_t ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5
-$as_echo_n "checking for int$2_t... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5
+printf %s "checking for int$2_t... " >&6; }
+if eval test \${$3+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
eval "$3=no"
# Order is important - never check a type that is potentially smaller
# than half of the expected target width.
@@ -1942,7 +1854,7 @@ else
$ac_includes_default
enum { N = $2 / 2 - 1 };
int
-main ()
+main (void)
{
static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))];
test_array [0] = 0;
@@ -1952,13 +1864,14 @@ return test_array [0];
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$ac_includes_default
enum { N = $2 / 2 - 1 };
int
-main ()
+main (void)
{
static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1)
< ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))];
@@ -1969,9 +1882,10 @@ return test_array [0];
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
-else
+else $as_nop
case $ac_type in #(
int$2_t) :
eval "$3=yes" ;; #(
@@ -1979,19 +1893,20 @@ else
eval "$3=\$ac_type" ;;
esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if eval test \"x\$"$3"\" = x"no"; then :
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+ if eval test \"x\$"$3"\" = x"no"
+then :
-else
+else $as_nop
break
fi
done
fi
eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+printf "%s\n" "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_find_intX_t
@@ -2003,17 +1918,18 @@ $as_echo "$ac_res" >&6; }
ac_fn_c_check_type ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+printf %s "checking for $2... " >&6; }
+if eval test \${$3+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
eval "$3=no"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
int
-main ()
+main (void)
{
if (sizeof ($2))
return 0;
@@ -2021,12 +1937,13 @@ if (sizeof ($2))
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
int
-main ()
+main (void)
{
if (sizeof (($2)))
return 0;
@@ -2034,18 +1951,19 @@ if (sizeof (($2)))
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
-else
+else $as_nop
eval "$3=yes"
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+printf "%s\n" "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_type
@@ -2057,11 +1975,12 @@ $as_echo "$ac_res" >&6; }
ac_fn_c_find_uintX_t ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5
-$as_echo_n "checking for uint$2_t... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5
+printf %s "checking for uint$2_t... " >&6; }
+if eval test \${$3+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
eval "$3=no"
# Order is important - never check a type that is potentially smaller
# than half of the expected target width.
@@ -2071,7 +1990,7 @@ else
/* end confdefs.h. */
$ac_includes_default
int
-main ()
+main (void)
{
static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)];
test_array [0] = 0;
@@ -2081,7 +2000,8 @@ return test_array [0];
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
case $ac_type in #(
uint$2_t) :
eval "$3=yes" ;; #(
@@ -2089,28 +2009,49 @@ if ac_fn_c_try_compile "$LINENO"; then :
eval "$3=\$ac_type" ;;
esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if eval test \"x\$"$3"\" = x"no"; then :
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+ if eval test \"x\$"$3"\" = x"no"
+then :
-else
+else $as_nop
break
fi
done
fi
eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+printf "%s\n" "$ac_res" >&6; }
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_find_uintX_t
+ac_configure_args_raw=
+for ac_arg
+do
+ case $ac_arg in
+ *\'*)
+ ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ as_fn_append ac_configure_args_raw " '$ac_arg'"
+done
+
+case $ac_configure_args_raw in
+ *$as_nl*)
+ ac_safe_unquote= ;;
+ *)
+ ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab.
+ ac_unsafe_a="$ac_unsafe_z#~"
+ ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
+ ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
+esac
+
cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by ffmpeg-kit $as_me 4.4, which was
-generated by GNU Autoconf 2.69. Invocation command line was
+It was created by ffmpeg-kit $as_me 4.5.1, which was
+generated by GNU Autoconf 2.71. Invocation command line was
- $ $0 $@
+ $ $0$ac_configure_args_raw
_ACEOF
exec 5>>config.log
@@ -2143,8 +2084,12 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ printf "%s\n" "PATH: $as_dir"
done
IFS=$as_save_IFS
@@ -2179,7 +2124,7 @@ do
| -silent | --silent | --silen | --sile | --sil)
continue ;;
*\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
esac
case $ac_pass in
1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
@@ -2214,11 +2159,13 @@ done
# WARNING: Use '\'' to represent an apostrophe within the trap.
# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
trap 'exit_status=$?
+ # Sanitize IFS.
+ IFS=" "" $as_nl"
# Save into config.log some information that might help in debugging.
{
echo
- $as_echo "## ---------------- ##
+ printf "%s\n" "## ---------------- ##
## Cache variables. ##
## ---------------- ##"
echo
@@ -2229,8 +2176,8 @@ trap 'exit_status=$?
case $ac_val in #(
*${as_nl}*)
case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
+ *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
+printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
esac
case $ac_var in #(
_ | IFS | as_nl) ;; #(
@@ -2254,7 +2201,7 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
)
echo
- $as_echo "## ----------------- ##
+ printf "%s\n" "## ----------------- ##
## Output variables. ##
## ----------------- ##"
echo
@@ -2262,14 +2209,14 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
do
eval ac_val=\$$ac_var
case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
esac
- $as_echo "$ac_var='\''$ac_val'\''"
+ printf "%s\n" "$ac_var='\''$ac_val'\''"
done | sort
echo
if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
+ printf "%s\n" "## ------------------- ##
## File substitutions. ##
## ------------------- ##"
echo
@@ -2277,15 +2224,15 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
do
eval ac_val=\$$ac_var
case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
esac
- $as_echo "$ac_var='\''$ac_val'\''"
+ printf "%s\n" "$ac_var='\''$ac_val'\''"
done | sort
echo
fi
if test -s confdefs.h; then
- $as_echo "## ----------- ##
+ printf "%s\n" "## ----------- ##
## confdefs.h. ##
## ----------- ##"
echo
@@ -2293,8 +2240,8 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
echo
fi
test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
+ printf "%s\n" "$as_me: caught signal $ac_signal"
+ printf "%s\n" "$as_me: exit $exit_status"
} >&5
rm -f core *.core core.conftest.* &&
rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
@@ -2308,63 +2255,48 @@ ac_signal=0
# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -f -r conftest* confdefs.h
-$as_echo "/* confdefs.h */" > confdefs.h
+printf "%s\n" "/* confdefs.h */" > confdefs.h
# Predefined preprocessor variables.
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
+printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
+printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
+printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
+printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
+printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
+printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
# Let the site file select an alternate cache file if it wants to.
# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
+ ac_site_files="$CONFIG_SITE"
elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
+ ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
+ ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
+
+for ac_site_file in $ac_site_files
do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
+ case $ac_site_file in #(
+ */*) :
+ ;; #(
+ *) :
+ ac_site_file=./$ac_site_file ;;
+esac
+ if test -f "$ac_site_file" && test -r "$ac_site_file"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
+printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
sed 's/^/| /' "$ac_site_file" >&5
. "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+ || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "failed to load site script $ac_site_file
See \`config.log' for more details" "$LINENO" 5; }
fi
@@ -2374,122 +2306,511 @@ if test -r "$cache_file"; then
# Some versions of bash will fail to source /dev/null (special files
# actually), so we avoid doing that. DJGPP emulates it as a regular file.
if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
+printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
case $cache_file in
[\\/]* | ?:[\\/]* ) . "$cache_file";;
*) . "./$cache_file";;
esac
fi
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
+printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
>$cache_file
fi
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
+# Test code for whether the C compiler supports C89 (global declarations)
+ac_c_conftest_c89_globals='
+/* Does the compiler advertise C89 conformance?
+ Do not test the value of __STDC__, because some compilers set it to 0
+ while being otherwise adequately conformant. */
+#if !defined __STDC__
+# error "Compiler does not advertise C89 conformance"
+#endif
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
+#include
+#include
+struct stat;
+/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
+struct buf { int x; };
+struct buf * (*rcsopen) (struct buf *, struct stat *, int);
+static char *e (p, i)
+ char **p;
+ int i;
+{
+ return p[i];
+}
+static char *f (char * (*g) (char **, int), char **p, ...)
+{
+ char *s;
+ va_list v;
+ va_start (v,p);
+ s = g (p, va_arg (v,int));
+ va_end (v);
+ return s;
+}
+/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
+ function prototypes and stuff, but not \xHH hex character constants.
+ These do not provoke an error unfortunately, instead are silently treated
+ as an "x". The following induces an error, until -std is added to get
+ proper ANSI mode. Curiously \x00 != x always comes out true, for an
+ array size at least. It is necessary to write \x00 == 0 to get something
+ that is true only with -std. */
+int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
+/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
+ inside strings and character constants. */
+#define FOO(x) '\''x'\''
+int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
+int test (int i, double x);
+struct s1 {int (*f) (int a);};
+struct s2 {int (*f) (double a);};
+int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
+ int, int);'
+# Test code for whether the C compiler supports C89 (body of main).
+ac_c_conftest_c89_main='
+ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
+'
-am__api_version='1.16'
+# Test code for whether the C compiler supports C99 (global declarations)
+ac_c_conftest_c99_globals='
+// Does the compiler advertise C99 conformance?
+#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
+# error "Compiler does not advertise C99 conformance"
+#endif
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
+#include
+extern int puts (const char *);
+extern int printf (const char *, ...);
+extern int dprintf (int, const char *, ...);
+extern void *malloc (size_t);
+
+// Check varargs macros. These examples are taken from C99 6.10.3.5.
+// dprintf is used instead of fprintf to avoid needing to declare
+// FILE and stderr.
+#define debug(...) dprintf (2, __VA_ARGS__)
+#define showlist(...) puts (#__VA_ARGS__)
+#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
+static void
+test_varargs_macros (void)
+{
+ int x = 1234;
+ int y = 5678;
+ debug ("Flag");
+ debug ("X = %d\n", x);
+ showlist (The first, second, and third items.);
+ report (x>y, "x is %d but y is %d", x, y);
+}
-# These three variables are undocumented and unsupported,
+// Check long long types.
+#define BIG64 18446744073709551615ull
+#define BIG32 4294967295ul
+#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
+#if !BIG_OK
+ #error "your preprocessor is broken"
+#endif
+#if BIG_OK
+#else
+ #error "your preprocessor is broken"
+#endif
+static long long int bignum = -9223372036854775807LL;
+static unsigned long long int ubignum = BIG64;
+
+struct incomplete_array
+{
+ int datasize;
+ double data[];
+};
+
+struct named_init {
+ int number;
+ const wchar_t *name;
+ double average;
+};
+
+typedef const char *ccp;
+
+static inline int
+test_restrict (ccp restrict text)
+{
+ // See if C++-style comments work.
+ // Iterate through items via the restricted pointer.
+ // Also check for declarations in for loops.
+ for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
+ continue;
+ return 0;
+}
+
+// Check varargs and va_copy.
+static bool
+test_varargs (const char *format, ...)
+{
+ va_list args;
+ va_start (args, format);
+ va_list args_copy;
+ va_copy (args_copy, args);
+
+ const char *str = "";
+ int number = 0;
+ float fnumber = 0;
+
+ while (*format)
+ {
+ switch (*format++)
+ {
+ case '\''s'\'': // string
+ str = va_arg (args_copy, const char *);
+ break;
+ case '\''d'\'': // int
+ number = va_arg (args_copy, int);
+ break;
+ case '\''f'\'': // float
+ fnumber = va_arg (args_copy, double);
+ break;
+ default:
+ break;
+ }
+ }
+ va_end (args_copy);
+ va_end (args);
+
+ return *str && number && fnumber;
+}
+'
+
+# Test code for whether the C compiler supports C99 (body of main).
+ac_c_conftest_c99_main='
+ // Check bool.
+ _Bool success = false;
+ success |= (argc != 0);
+
+ // Check restrict.
+ if (test_restrict ("String literal") == 0)
+ success = true;
+ char *restrict newvar = "Another string";
+
+ // Check varargs.
+ success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
+ test_varargs_macros ();
+
+ // Check flexible array members.
+ struct incomplete_array *ia =
+ malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
+ ia->datasize = 10;
+ for (int i = 0; i < ia->datasize; ++i)
+ ia->data[i] = i * 1.234;
+
+ // Check named initializers.
+ struct named_init ni = {
+ .number = 34,
+ .name = L"Test wide string",
+ .average = 543.34343,
+ };
+
+ ni.number = 58;
+
+ int dynamic_array[ni.number];
+ dynamic_array[0] = argv[0][0];
+ dynamic_array[ni.number - 1] = 543;
+
+ // work around unused variable warnings
+ ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
+ || dynamic_array[ni.number - 1] != 543);
+'
+
+# Test code for whether the C compiler supports C11 (global declarations)
+ac_c_conftest_c11_globals='
+// Does the compiler advertise C11 conformance?
+#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
+# error "Compiler does not advertise C11 conformance"
+#endif
+
+// Check _Alignas.
+char _Alignas (double) aligned_as_double;
+char _Alignas (0) no_special_alignment;
+extern char aligned_as_int;
+char _Alignas (0) _Alignas (int) aligned_as_int;
+
+// Check _Alignof.
+enum
+{
+ int_alignment = _Alignof (int),
+ int_array_alignment = _Alignof (int[100]),
+ char_alignment = _Alignof (char)
+};
+_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
+
+// Check _Noreturn.
+int _Noreturn does_not_return (void) { for (;;) continue; }
+
+// Check _Static_assert.
+struct test_static_assert
+{
+ int x;
+ _Static_assert (sizeof (int) <= sizeof (long int),
+ "_Static_assert does not work in struct");
+ long int y;
+};
+
+// Check UTF-8 literals.
+#define u8 syntax error!
+char const utf8_literal[] = u8"happens to be ASCII" "another string";
+
+// Check duplicate typedefs.
+typedef long *long_ptr;
+typedef long int *long_ptr;
+typedef long_ptr long_ptr;
+
+// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
+struct anonymous
+{
+ union {
+ struct { int i; int j; };
+ struct { int k; long int l; } w;
+ };
+ int m;
+} v1;
+'
+
+# Test code for whether the C compiler supports C11 (body of main).
+ac_c_conftest_c11_main='
+ _Static_assert ((offsetof (struct anonymous, i)
+ == offsetof (struct anonymous, w.k)),
+ "Anonymous union alignment botch");
+ v1.i = 2;
+ v1.w.k = 5;
+ ok |= v1.i != 5;
+'
+
+# Test code for whether the C compiler supports C11 (complete).
+ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
+${ac_c_conftest_c99_globals}
+${ac_c_conftest_c11_globals}
+
+int
+main (int argc, char **argv)
+{
+ int ok = 0;
+ ${ac_c_conftest_c89_main}
+ ${ac_c_conftest_c99_main}
+ ${ac_c_conftest_c11_main}
+ return ok;
+}
+"
+
+# Test code for whether the C compiler supports C99 (complete).
+ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
+${ac_c_conftest_c99_globals}
+
+int
+main (int argc, char **argv)
+{
+ int ok = 0;
+ ${ac_c_conftest_c89_main}
+ ${ac_c_conftest_c99_main}
+ return ok;
+}
+"
+
+# Test code for whether the C compiler supports C89 (complete).
+ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
+
+int
+main (int argc, char **argv)
+{
+ int ok = 0;
+ ${ac_c_conftest_c89_main}
+ return ok;
+}
+"
+
+as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
+as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
+as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
+as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
+as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
+as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
+as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
+as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
+as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
+
+# Auxiliary files required by this configure script.
+ac_aux_files="ltmain.sh ar-lib compile config.guess config.sub missing install-sh"
+
+# Locations in which to look for auxiliary files.
+ac_aux_dir_candidates="${srcdir}${PATH_SEPARATOR}${srcdir}/..${PATH_SEPARATOR}${srcdir}/../.."
+
+# Search for a directory containing all of the required auxiliary files,
+# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates.
+# If we don't find one directory that contains all the files we need,
+# we report the set of missing files from the *first* directory in
+# $ac_aux_dir_candidates and give up.
+ac_missing_aux_files=""
+ac_first_candidate=:
+printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+as_found=false
+for as_dir in $ac_aux_dir_candidates
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ as_found=:
+
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5
+ ac_aux_dir_found=yes
+ ac_install_sh=
+ for ac_aux in $ac_aux_files
+ do
+ # As a special case, if "install-sh" is required, that requirement
+ # can be satisfied by any of "install-sh", "install.sh", or "shtool",
+ # and $ac_install_sh is set appropriately for whichever one is found.
+ if test x"$ac_aux" = x"install-sh"
+ then
+ if test -f "${as_dir}install-sh"; then
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5
+ ac_install_sh="${as_dir}install-sh -c"
+ elif test -f "${as_dir}install.sh"; then
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5
+ ac_install_sh="${as_dir}install.sh -c"
+ elif test -f "${as_dir}shtool"; then
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5
+ ac_install_sh="${as_dir}shtool install -c"
+ else
+ ac_aux_dir_found=no
+ if $ac_first_candidate; then
+ ac_missing_aux_files="${ac_missing_aux_files} install-sh"
+ else
+ break
+ fi
+ fi
+ else
+ if test -f "${as_dir}${ac_aux}"; then
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5
+ else
+ ac_aux_dir_found=no
+ if $ac_first_candidate; then
+ ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}"
+ else
+ break
+ fi
+ fi
+ fi
+ done
+ if test "$ac_aux_dir_found" = yes; then
+ ac_aux_dir="$as_dir"
+ break
+ fi
+ ac_first_candidate=false
+
+ as_found=false
+done
+IFS=$as_save_IFS
+if $as_found
+then :
+
+else $as_nop
+ as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5
+fi
+
+
+# These three variables are undocumented and unsupported,
# and are intended to be withdrawn in a future Autoconf release.
# They can cause serious problems if a builder's source tree is in a directory
# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
+if test -f "${ac_aux_dir}config.guess"; then
+ ac_config_guess="$SHELL ${ac_aux_dir}config.guess"
+fi
+if test -f "${ac_aux_dir}config.sub"; then
+ ac_config_sub="$SHELL ${ac_aux_dir}config.sub"
+fi
+if test -f "$ac_aux_dir/configure"; then
+ ac_configure="$SHELL ${ac_aux_dir}configure"
+fi
+
+# Check that the precious variables saved in the cache have kept the same
+# value.
+ac_cache_corrupted=false
+for ac_var in $ac_precious_vars; do
+ eval ac_old_set=\$ac_cv_env_${ac_var}_set
+ eval ac_new_set=\$ac_env_${ac_var}_set
+ eval ac_old_val=\$ac_cv_env_${ac_var}_value
+ eval ac_new_val=\$ac_env_${ac_var}_value
+ case $ac_old_set,$ac_new_set in
+ set,)
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
+printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
+ ac_cache_corrupted=: ;;
+ ,set)
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
+printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
+ ac_cache_corrupted=: ;;
+ ,);;
+ *)
+ if test "x$ac_old_val" != "x$ac_new_val"; then
+ # differences in whitespace do not lead to failure.
+ ac_old_val_w=`echo x $ac_old_val`
+ ac_new_val_w=`echo x $ac_new_val`
+ if test "$ac_old_val_w" != "$ac_new_val_w"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
+printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
+ ac_cache_corrupted=:
+ else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
+printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
+ eval $ac_var=\$ac_old_val
+ fi
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
+printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
+printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;}
+ fi;;
+ esac
+ # Pass precious variables to config.status.
+ if test "$ac_new_set" = set; then
+ case $ac_new_val in
+ *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *) ac_arg=$ac_var=$ac_new_val ;;
+ esac
+ case " $ac_configure_args " in
+ *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
+ *) as_fn_append ac_configure_args " '$ac_arg'" ;;
+ esac
+ fi
+done
+if $ac_cache_corrupted; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
+printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
+ as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
+ and start over" "$LINENO" 5
+fi
+## -------------------- ##
+## Main body of script. ##
+## -------------------- ##
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
-# Find a good install program. We prefer a C program (faster),
+
+
+am__api_version='1.16'
+
+
+
+ # Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
@@ -2503,20 +2824,25 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
# OS/2's system install, which has a completely different semantic
# ./install, which can be erroneously created by make from ./install.sh.
# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
+printf %s "checking for a BSD-compatible install... " >&6; }
if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+if test ${ac_cv_path_install+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ # Account for fact that we put trailing slashes in our PATH walk.
+case $as_dir in #((
+ ./ | /[cC]/* | \
/etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
/usr/ucb/* ) ;;
@@ -2526,13 +2852,13 @@ case $as_dir/ in #((
# by default.
for ac_prog in ginstall scoinst install; do
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then
if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
# AIX install. It has an incompatible calling convention.
:
elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
# program-specific install script used by HP pwplus--don't use.
:
else
@@ -2540,12 +2866,12 @@ case $as_dir/ in #((
echo one > conftest.one
echo two > conftest.two
mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
+ if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" &&
test -s conftest.one && test -s conftest.two &&
test -s conftest.dir/conftest.one &&
test -s conftest.dir/conftest.two
then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+ ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c"
break 3
fi
fi
@@ -2561,7 +2887,7 @@ IFS=$as_save_IFS
rm -rf conftest.one conftest.two conftest.dir
fi
- if test "${ac_cv_path_install+set}" = set; then
+ if test ${ac_cv_path_install+y}; then
INSTALL=$ac_cv_path_install
else
# As a last resort, use the slow shell script. Don't cache a
@@ -2571,8 +2897,8 @@ fi
INSTALL=$ac_install_sh
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
+printf "%s\n" "$INSTALL" >&6; }
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
@@ -2582,8 +2908,8 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
+printf %s "checking whether build environment is sane... " >&6; }
# Reject unsafe characters in $srcdir or the absolute working directory
# name. Accept space and tab only in the latter.
am_lf='
@@ -2637,8 +2963,8 @@ else
as_fn_error $? "newly created file is older than distributed files!
Check your system clock" "$LINENO" 5
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
# If we didn't sleep, we still need to ensure time stamps of config.status and
# generated files are strictly newer.
am_sleep_pid=
@@ -2657,12 +2983,14 @@ test "$program_suffix" != NONE &&
# Double any \ or $.
# By default was `s,x,x', remove it if useless.
ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
+program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"`
+
# Expand $ac_aux_dir to an absolute path.
am_aux_dir=`cd "$ac_aux_dir" && pwd`
-if test x"${MISSING+set}" != xset; then
+
+ if test x"${MISSING+set}" != xset; then
MISSING="\${SHELL} '$am_aux_dir/missing'"
fi
# Use eval to expand $SHELL
@@ -2670,8 +2998,8 @@ if eval "$MISSING --is-lightweight"; then
am_missing_run="$MISSING "
else
am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
+printf "%s\n" "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
fi
if test x"${install_sh+set}" != xset; then
@@ -2691,11 +3019,12 @@ if test "$cross_compiling" != no; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_STRIP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$STRIP"; then
ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
@@ -2703,11 +3032,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2718,11 +3051,11 @@ fi
fi
STRIP=$ac_cv_prog_STRIP
if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
+printf "%s\n" "$STRIP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -2731,11 +3064,12 @@ if test -z "$ac_cv_prog_STRIP"; then
ac_ct_STRIP=$STRIP
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_STRIP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_STRIP"; then
ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
else
@@ -2743,11 +3077,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2758,11 +3096,11 @@ fi
fi
ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
+printf "%s\n" "$ac_ct_STRIP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_STRIP" = x; then
@@ -2770,8 +3108,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
STRIP=$ac_ct_STRIP
@@ -2783,25 +3121,31 @@ fi
fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
+
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5
+printf %s "checking for a race-free mkdir -p... " >&6; }
if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ if test ${ac_cv_path_mkdir+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_prog in mkdir gmkdir; do
for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
+ as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue
+ case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #(
+ 'mkdir ('*'coreutils) '* | \
+ 'BusyBox '* | \
'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
+ ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext
break 3;;
esac
done
@@ -2812,7 +3156,7 @@ IFS=$as_save_IFS
fi
test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
+ if test ${ac_cv_path_mkdir+y}; then
MKDIR_P="$ac_cv_path_mkdir -p"
else
# As a last resort, use the slow shell script. Don't cache a
@@ -2822,18 +3166,19 @@ fi
MKDIR_P="$ac_install_sh -d"
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
+printf "%s\n" "$MKDIR_P" >&6; }
for ac_prog in gawk mawk nawk awk
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_AWK+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$AWK"; then
ac_cv_prog_AWK="$AWK" # Let the user override the test.
else
@@ -2841,11 +3186,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2856,24 +3205,25 @@ fi
fi
AWK=$ac_cv_prog_AWK
if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
+printf "%s\n" "$AWK" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
test -n "$AWK" && break
done
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
+printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
+if eval test \${ac_cv_prog_make_${ac_make}_set+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat >conftest.make <<\_ACEOF
SHELL = /bin/sh
all:
@@ -2889,12 +3239,12 @@ esac
rm -f conftest.make
fi
if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
SET_MAKE=
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
SET_MAKE="MAKE=${MAKE-make}"
fi
@@ -2908,7 +3258,8 @@ fi
rmdir .tst 2>/dev/null
# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
+if test ${enable_silent_rules+y}
+then :
enableval=$enable_silent_rules;
fi
@@ -2918,12 +3269,13 @@ case $enable_silent_rules in # (((
*) AM_DEFAULT_VERBOSITY=1;;
esac
am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
+printf %s "checking whether $am_make supports nested variables... " >&6; }
+if test ${am_cv_make_support_nested_variables+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if printf "%s\n" 'TRUE=$(BAR$(V))
BAR0=false
BAR1=true
V=1
@@ -2935,8 +3287,8 @@ else
am_cv_make_support_nested_variables=no
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
+printf "%s\n" "$am_cv_make_support_nested_variables" >&6; }
if test $am_cv_make_support_nested_variables = yes; then
AM_V='$(V)'
AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
@@ -2968,17 +3320,13 @@ fi
# Define the identity of the package.
PACKAGE='ffmpeg-kit'
- VERSION='4.4'
+ VERSION='4.5.1'
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
+printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
+printf "%s\n" "#define VERSION \"$VERSION\"" >>confdefs.h
# Some tools Automake needs.
@@ -3018,6 +3366,20 @@ am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
+# Variables for tags utilities; see am/tags.am
+if test -z "$CTAGS"; then
+ CTAGS=ctags
+fi
+
+if test -z "$ETAGS"; then
+ ETAGS=etags
+fi
+
+if test -z "$CSCOPE"; then
+ CSCOPE=cscope
+fi
+
+
# POSIX will say in a future version that running "rm -f" with no argument
# is OK; and we want to be able to make that assumption in our Makefile
@@ -3062,17 +3424,18 @@ END
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
+printf %s "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
# Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
+if test ${enable_maintainer_mode+y}
+then :
enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
+else $as_nop
USE_MAINTAINER_MODE=no
fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
+printf "%s\n" "$USE_MAINTAINER_MODE" >&6; }
if test $USE_MAINTAINER_MODE = yes; then
MAINTAINER_MODE_TRUE=
MAINTAINER_MODE_FALSE='#'
@@ -3088,32 +3451,33 @@ fi
# Check for os version
VERSION_OS=$(uname -s)
-cat >>confdefs.h <<_ACEOF
-#define VERSION_OS "$VERSION_OS"
-_ACEOF
+printf "%s\n" "#define VERSION_OS \"$VERSION_OS\"" >>confdefs.h
# Check host so we can infer target CPU (and assembly optimizations)
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+
+ # Make sure we can run config.sub.
+$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 ||
+ as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5
+
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
+printf %s "checking build system type... " >&6; }
+if test ${ac_cv_build+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_build_alias=$build_alias
test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
+ ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
test "x$ac_build_alias" = x &&
as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
+ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
+ as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
+printf "%s\n" "$ac_cv_build" >&6; }
case $ac_cv_build in
*-*-*) ;;
*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
@@ -3132,21 +3496,22 @@ IFS=$ac_save_IFS
case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
+printf %s "checking host system type... " >&6; }
+if test ${ac_cv_host+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test "x$host_alias" = x; then
ac_cv_host=$ac_cv_build
else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
+ ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
+ as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
+printf "%s\n" "$ac_cv_host" >&6; }
case $ac_cv_host in
*-*-*) ;;
*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
@@ -3167,12 +3532,21 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
# Check for processor characteristics
+
+
+
+
+
+
+
+
+
DEPDIR="${am__leading_dot}deps"
ac_config_commands="$ac_config_commands depfiles"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
-$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
+printf %s "checking whether ${MAKE-make} supports the include directive... " >&6; }
cat > confinc.mk << 'END'
am__doit:
@echo this is the am__doit target >confinc.out
@@ -3208,11 +3582,12 @@ esac
fi
done
rm -f confinc.* confmf.*
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
-$as_echo "${_am_result}" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
+printf "%s\n" "${_am_result}" >&6; }
# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
+if test ${enable_dependency_tracking+y}
+then :
enableval=$enable_dependency_tracking;
fi
@@ -3238,11 +3613,12 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -3250,11 +3626,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3265,11 +3645,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -3278,11 +3658,12 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
@@ -3290,11 +3671,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3305,11 +3690,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_CC" = x; then
@@ -3317,8 +3702,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -3331,11 +3716,12 @@ if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -3343,11 +3729,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3358,11 +3748,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -3371,11 +3761,12 @@ fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -3384,15 +3775,19 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
fi
ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3408,18 +3803,18 @@ if test $ac_prog_rejected = yes; then
# However, it has the same basename, so the bogon will be chosen
# first if we set CC to just the basename; use the full file name.
shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
+ ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
fi
fi
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -3430,11 +3825,12 @@ if test -z "$CC"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -3442,11 +3838,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3457,11 +3857,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -3474,11 +3874,12 @@ if test -z "$CC"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
@@ -3486,11 +3887,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3501,11 +3906,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -3517,8 +3922,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -3526,57 +3931,161 @@ esac
fi
fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
+if test -z "$CC"; then
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
+set dummy ${ac_tool_prefix}clang; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="${ac_tool_prefix}clang"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
+ break 2
fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
done
+ done
+IFS=$as_save_IFS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
+else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+fi
-int
-main ()
-{
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
+fi
+if test -z "$ac_cv_prog_CC"; then
+ ac_ct_CC=$CC
+ # Extract the first word of "clang", so it can be a program name with args.
+set dummy clang; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if test -n "$ac_ct_CC"; then
+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="clang"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
+else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+fi
+
+ if test "x$ac_ct_CC" = x; then
+ CC=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+ CC=$ac_ct_CC
+ fi
+else
+ CC="$ac_cv_prog_CC"
+fi
+
+fi
+
+
+test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "no acceptable C compiler found in \$PATH
+See \`config.log' for more details" "$LINENO" 5; }
+
+# Provide some information about the compiler.
+printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
+set X $ac_compile
+ac_compiler=$2
+for ac_option in --version -v -V -qversion -version; do
+ { { ac_try="$ac_compiler $ac_option >&5"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+printf "%s\n" "$ac_try_echo"; } >&5
+ (eval "$ac_compiler $ac_option >&5") 2>conftest.err
+ ac_status=$?
+ if test -s conftest.err; then
+ sed '10a\
+... rest of stderr output deleted ...
+ 10q' conftest.err >conftest.er1
+ cat conftest.er1 >&5
+ fi
+ rm -f conftest.er1 conftest.err
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }
+done
+
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+int
+main (void)
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+ac_clean_files_save=$ac_clean_files
+ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
+# Try to create an executable without -o first, disregard a.out.
# It will help us diagnose broken compilers, and finding out an intuition
# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
+printf %s "checking whether the C compiler works... " >&6; }
+ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
# The possible output files:
ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
@@ -3597,11 +4106,12 @@ case "(($ac_try" in
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_link_default") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }
+then :
# Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
# in a Makefile. We should not override ac_cv_exeext if it was cached,
@@ -3618,7 +4128,7 @@ do
# certainly right.
break;;
*.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
+ if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
then :; else
ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
fi
@@ -3634,44 +4144,46 @@ do
done
test "$ac_cv_exeext" = no && ac_cv_exeext=
-else
+else $as_nop
ac_file=''
fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
+if test -z "$ac_file"
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error 77 "C compiler cannot create executables
See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
+printf %s "checking for C compiler default output file name... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
+printf "%s\n" "$ac_file" >&6; }
ac_exeext=$ac_cv_exeext
rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
+printf %s "checking for suffix of executables... " >&6; }
if { { ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_link") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }
+then :
# If both `conftest.exe' and `conftest' are `present' (well, observable)
# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
# work properly (i.e., refer to `conftest.exe'), while it won't with
@@ -3685,15 +4197,15 @@ for ac_file in conftest.exe conftest conftest.*; do
* ) break;;
esac
done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+else $as_nop
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "cannot compute suffix of executables: cannot compile and link
See \`config.log' for more details" "$LINENO" 5; }
fi
rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
+printf "%s\n" "$ac_cv_exeext" >&6; }
rm -f conftest.$ac_ext
EXEEXT=$ac_cv_exeext
@@ -3702,7 +4214,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include
int
-main ()
+main (void)
{
FILE *f = fopen ("conftest.out", "w");
return ferror (f) || fclose (f) != 0;
@@ -3714,8 +4226,8 @@ _ACEOF
ac_clean_files="$ac_clean_files conftest.out"
# Check that the compiler produces executables we can run. If not, either
# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
+printf %s "checking whether we are cross compiling... " >&6; }
if test "$cross_compiling" != yes; then
{ { ac_try="$ac_link"
case "(($ac_try" in
@@ -3723,10 +4235,10 @@ case "(($ac_try" in
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_link") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
if { ac_try='./conftest$ac_cv_exeext'
{ { case "(($ac_try" in
@@ -3734,39 +4246,40 @@ $as_echo "$ac_try_echo"; } >&5
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_try") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; }; then
cross_compiling=no
else
if test "$cross_compiling" = maybe; then
cross_compiling=yes
else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error 77 "cannot run C compiled programs.
If you meant to cross compile, use \`--host'.
See \`config.log' for more details" "$LINENO" 5; }
fi
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
+printf "%s\n" "$cross_compiling" >&6; }
rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
+printf %s "checking for suffix of object files... " >&6; }
+if test ${ac_cv_objext+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
@@ -3780,11 +4293,12 @@ case "(($ac_try" in
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_compile") 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }
+then :
for ac_file in conftest.o conftest.obj conftest.*; do
test -f "$ac_file" || continue;
case $ac_file in
@@ -3793,31 +4307,32 @@ $as_echo "$ac_try_echo"; } >&5
break;;
esac
done
-else
- $as_echo "$as_me: failed program was:" >&5
+else $as_nop
+ printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "cannot compute suffix of object files: cannot compile
See \`config.log' for more details" "$LINENO" 5; }
fi
rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
+printf "%s\n" "$ac_cv_objext" >&6; }
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
+printf %s "checking whether the compiler supports GNU C... " >&6; }
+if test ${ac_cv_c_compiler_gnu+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
#ifndef __GNUC__
choke me
@@ -3827,29 +4342,33 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_compiler_gnu=yes
-else
+else $as_nop
ac_compiler_gnu=no
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
+printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
if test $ac_compiler_gnu = yes; then
GCC=yes
else
GCC=
fi
-ac_test_CFLAGS=${CFLAGS+set}
+ac_test_CFLAGS=${CFLAGS+y}
ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
+printf %s "checking whether $CC accepts -g... " >&6; }
+if test ${ac_cv_prog_cc_g+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_save_c_werror_flag=$ac_c_werror_flag
ac_c_werror_flag=yes
ac_cv_prog_cc_g=no
@@ -3858,57 +4377,60 @@ else
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_g=yes
-else
+else $as_nop
CFLAGS=""
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
-else
+else $as_nop
ac_c_werror_flag=$ac_save_c_werror_flag
CFLAGS="-g"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_g=yes
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag=$ac_save_c_werror_flag
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
+printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
+if test $ac_test_CFLAGS; then
CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
if test "$GCC" = yes; then
@@ -3923,94 +4445,144 @@ else
CFLAGS=
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
+ac_prog_cc_stdc=no
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
+printf %s "checking for $CC option to enable C11 features... " >&6; }
+if test ${ac_cv_prog_cc_c11+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c11=no
ac_save_CC=$CC
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-#include
-#include
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
+$ac_c_conftest_c11_program
+_ACEOF
+for ac_arg in '' -std=gnu11
+do
+ CC="$ac_save_CC $ac_arg"
+ if ac_fn_c_try_compile "$LINENO"
+then :
+ ac_cv_prog_cc_c11=$ac_arg
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam
+ test "x$ac_cv_prog_cc_c11" != "xno" && break
+done
+rm -f conftest.$ac_ext
+CC=$ac_save_CC
+fi
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
+if test "x$ac_cv_prog_cc_c11" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c11" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
+printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
+ CC="$CC $ac_cv_prog_cc_c11"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
+ ac_prog_cc_stdc=c11
+fi
+fi
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
+printf %s "checking for $CC option to enable C99 features... " >&6; }
+if test ${ac_cv_prog_cc_c99+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c99=no
+ac_save_CC=$CC
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$ac_c_conftest_c99_program
+_ACEOF
+for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
+do
+ CC="$ac_save_CC $ac_arg"
+ if ac_fn_c_try_compile "$LINENO"
+then :
+ ac_cv_prog_cc_c99=$ac_arg
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam
+ test "x$ac_cv_prog_cc_c99" != "xno" && break
+done
+rm -f conftest.$ac_ext
+CC=$ac_save_CC
+fi
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
+if test "x$ac_cv_prog_cc_c99" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c99" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
+printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
+ CC="$CC $ac_cv_prog_cc_c99"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
+ ac_prog_cc_stdc=c99
+fi
+fi
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
+printf %s "checking for $CC option to enable C89 features... " >&6; }
+if test ${ac_cv_prog_cc_c89+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c89=no
+ac_save_CC=$CC
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$ac_c_conftest_c89_program
_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
+ if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_c89=$ac_arg
fi
-rm -f core conftest.err conftest.$ac_objext
+rm -f core conftest.err conftest.$ac_objext conftest.beam
test "x$ac_cv_prog_cc_c89" != "xno" && break
done
rm -f conftest.$ac_ext
CC=$ac_save_CC
-
fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
+if test "x$ac_cv_prog_cc_c89" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c89" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
+printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
+ CC="$CC $ac_cv_prog_cc_c89"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
+ ac_prog_cc_stdc=c89
+fi
fi
ac_ext=c
@@ -4019,21 +4591,23 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_ext=c
+
+ ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
+printf %s "checking whether $CC understands -c and -o together... " >&6; }
+if test ${am_cv_prog_cc_c_o+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
@@ -4061,8 +4635,8 @@ _ACEOF
rm -f core conftest*
unset am_i
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
+printf "%s\n" "$am_cv_prog_cc_c_o" >&6; }
if test "$am_cv_prog_cc_c_o" != yes; then
# Losing compiler, so override with the script.
# FIXME: It is wrong to rewrite CC.
@@ -4080,11 +4654,12 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
depcc="$CC" am_compiler_list=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
+printf %s "checking dependency style of $depcc... " >&6; }
+if test ${am_cv_CC_dependencies_compiler_type+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
# making bogus files that we don't know about and never remove. For
@@ -4191,8 +4766,8 @@ else
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
+printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; }
CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
if
@@ -4207,408 +4782,41 @@ fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer to if __STDC__ is defined, since
- # exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer to if __STDC__ is defined, since
- # exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+ac_header= ac_cache=
+for ac_item in $ac_header_c_list
do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
+ if test $ac_cache; then
+ ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
+ if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
+ printf "%s\n" "#define $ac_item 1" >> confdefs.h
fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ ac_header= ac_cache=
+ elif test $ac_header; then
+ ac_cache=$ac_item
+ else
+ ac_header=$ac_item
fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-#include
-#include
-#include
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
+done
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-fi
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include
-#include
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-fi
+if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
+then :
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
+printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
fi
-
-done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
-if ${ac_cv_c_bigendian+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
+printf %s "checking whether byte ordering is bigendian... " >&6; }
+if test ${ac_cv_c_bigendian+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_cv_c_bigendian=unknown
# See if we're dealing with a universal compiler.
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4619,7 +4827,8 @@ else
typedef int dummy;
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
# Check for potential -arch flags. It is not universal unless
# there are at least two -arch flags with different values.
@@ -4643,7 +4852,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
fi
done
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
if test $ac_cv_c_bigendian = unknown; then
# See if sys/param.h defines the BYTE_ORDER macro.
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4652,7 +4861,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
#include
int
-main ()
+main (void)
{
#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
&& defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
@@ -4664,7 +4873,8 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
# It does; now see whether it defined to BIG_ENDIAN or not.
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4672,7 +4882,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
#include
int
-main ()
+main (void)
{
#if BYTE_ORDER != BIG_ENDIAN
not big endian
@@ -4682,14 +4892,15 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_c_bigendian=yes
-else
+else $as_nop
ac_cv_c_bigendian=no
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
if test $ac_cv_c_bigendian = unknown; then
# See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
@@ -4698,7 +4909,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
#include
int
-main ()
+main (void)
{
#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
bogus endian macros
@@ -4708,14 +4919,15 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
# It does; now see whether it defined to _BIG_ENDIAN or not.
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include
int
-main ()
+main (void)
{
#ifndef _BIG_ENDIAN
not big endian
@@ -4725,31 +4937,33 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_c_bigendian=yes
-else
+else $as_nop
ac_cv_c_bigendian=no
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
if test $ac_cv_c_bigendian = unknown; then
# Compile a test program.
- if test "$cross_compiling" = yes; then :
+ if test "$cross_compiling" = yes
+then :
# Try to guess by grepping values from an object file.
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-short int ascii_mm[] =
+unsigned short int ascii_mm[] =
{ 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
- short int ascii_ii[] =
+ unsigned short int ascii_ii[] =
{ 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
int use_ascii (int i) {
return ascii_mm[i] + ascii_ii[i];
}
- short int ebcdic_ii[] =
+ unsigned short int ebcdic_ii[] =
{ 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
- short int ebcdic_mm[] =
+ unsigned short int ebcdic_mm[] =
{ 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
int use_ebcdic (int i) {
return ebcdic_mm[i] + ebcdic_ii[i];
@@ -4757,14 +4971,15 @@ short int ascii_mm[] =
extern int foo;
int
-main ()
+main (void)
{
return use_ascii (foo) == use_ebcdic (foo);
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
ac_cv_c_bigendian=yes
fi
@@ -4777,13 +4992,13 @@ if ac_fn_c_try_compile "$LINENO"; then :
fi
fi
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$ac_includes_default
int
-main ()
+main (void)
{
/* Are we little or big endian? From Harbison&Steele. */
@@ -4799,9 +5014,10 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
+if ac_fn_c_try_run "$LINENO"
+then :
ac_cv_c_bigendian=no
-else
+else $as_nop
ac_cv_c_bigendian=yes
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
@@ -4810,18 +5026,18 @@ fi
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
-$as_echo "$ac_cv_c_bigendian" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
+printf "%s\n" "$ac_cv_c_bigendian" >&6; }
case $ac_cv_c_bigendian in #(
yes)
-$as_echo "#define HIGHFIRST 1" >>confdefs.h
+printf "%s\n" "#define HIGHFIRST 1" >>confdefs.h
;; #(
no)
;; #(
universal)
-$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
+printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
;; #(
*)
@@ -4840,11 +5056,12 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -4852,11 +5069,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4867,11 +5088,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -4880,11 +5101,12 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
@@ -4892,11 +5114,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4907,11 +5133,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_CC" = x; then
@@ -4919,8 +5145,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -4933,11 +5159,12 @@ if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -4945,11 +5172,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4960,11 +5191,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -4973,11 +5204,12 @@ fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -4986,15 +5218,19 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
fi
ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5010,33 +5246,144 @@ if test $ac_prog_rejected = yes; then
# However, it has the same basename, so the bogon will be chosen
# first if we set CC to just the basename; use the full file name.
shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
+ ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
fi
fi
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
+else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+fi
+
+
+fi
+if test -z "$CC"; then
+ if test -n "$ac_tool_prefix"; then
+ for ac_prog in cl.exe
+ do
+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
+else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+fi
+
+
+ test -n "$CC" && break
+ done
+fi
+if test -z "$CC"; then
+ ac_ct_CC=$CC
+ for ac_prog in cl.exe
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if test -n "$ac_ct_CC"; then
+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="$ac_prog"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
+ test -n "$ac_ct_CC" && break
+done
+
+ if test "x$ac_ct_CC" = x; then
+ CC=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+ CC=$ac_ct_CC
+ fi
+fi
+
fi
if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
+set dummy ${ac_tool_prefix}clang; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
@@ -5044,11 +5391,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="${ac_tool_prefix}clang"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5059,28 +5410,25 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+printf "%s\n" "$CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
- test -n "$CC" && break
- done
fi
-if test -z "$CC"; then
+if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ # Extract the first word of "clang", so it can be a program name with args.
+set dummy clang; ac_word=$2
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_CC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
@@ -5088,11 +5436,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="clang"
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5103,50 +5455,48 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+printf "%s\n" "$ac_ct_CC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
-
- test -n "$ac_ct_CC" && break
-done
-
if test "x$ac_ct_CC" = x; then
CC=""
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
fi
+else
+ CC="$ac_cv_prog_CC"
fi
fi
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "no acceptable C compiler found in \$PATH
See \`config.log' for more details" "$LINENO" 5; }
# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
+printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
set X $ac_compile
ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
+for ac_option in --version -v -V -qversion -version; do
{ { ac_try="$ac_compiler $ac_option >&5"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_compiler $ac_option >&5") 2>conftest.err
ac_status=$?
if test -s conftest.err; then
@@ -5156,20 +5506,21 @@ $as_echo "$ac_try_echo"; } >&5
cat conftest.er1 >&5
fi
rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
done
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
+printf %s "checking whether the compiler supports GNU C... " >&6; }
+if test ${ac_cv_c_compiler_gnu+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
#ifndef __GNUC__
choke me
@@ -5179,29 +5530,33 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_compiler_gnu=yes
-else
+else $as_nop
ac_compiler_gnu=no
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
+printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
if test $ac_compiler_gnu = yes; then
GCC=yes
else
GCC=
fi
-ac_test_CFLAGS=${CFLAGS+set}
+ac_test_CFLAGS=${CFLAGS+y}
ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
+printf %s "checking whether $CC accepts -g... " >&6; }
+if test ${ac_cv_prog_cc_g+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_save_c_werror_flag=$ac_c_werror_flag
ac_c_werror_flag=yes
ac_cv_prog_cc_g=no
@@ -5210,57 +5565,60 @@ else
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_g=yes
-else
+else $as_nop
CFLAGS=""
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
-else
+else $as_nop
ac_c_werror_flag=$ac_save_c_werror_flag
CFLAGS="-g"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_g=yes
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag=$ac_save_c_werror_flag
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
+printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
+if test $ac_test_CFLAGS; then
CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
if test "$GCC" = yes; then
@@ -5275,94 +5633,144 @@ else
CFLAGS=
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
+ac_prog_cc_stdc=no
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
+printf %s "checking for $CC option to enable C11 features... " >&6; }
+if test ${ac_cv_prog_cc_c11+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c11=no
ac_save_CC=$CC
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-#include
-#include
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
+$ac_c_conftest_c11_program
+_ACEOF
+for ac_arg in '' -std=gnu11
+do
+ CC="$ac_save_CC $ac_arg"
+ if ac_fn_c_try_compile "$LINENO"
+then :
+ ac_cv_prog_cc_c11=$ac_arg
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam
+ test "x$ac_cv_prog_cc_c11" != "xno" && break
+done
+rm -f conftest.$ac_ext
+CC=$ac_save_CC
+fi
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
+if test "x$ac_cv_prog_cc_c11" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c11" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
+printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
+ CC="$CC $ac_cv_prog_cc_c11"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
+ ac_prog_cc_stdc=c11
+fi
+fi
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
+printf %s "checking for $CC option to enable C99 features... " >&6; }
+if test ${ac_cv_prog_cc_c99+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c99=no
+ac_save_CC=$CC
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$ac_c_conftest_c99_program
+_ACEOF
+for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
+do
+ CC="$ac_save_CC $ac_arg"
+ if ac_fn_c_try_compile "$LINENO"
+then :
+ ac_cv_prog_cc_c99=$ac_arg
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam
+ test "x$ac_cv_prog_cc_c99" != "xno" && break
+done
+rm -f conftest.$ac_ext
+CC=$ac_save_CC
+fi
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
+if test "x$ac_cv_prog_cc_c99" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c99" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
+printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
+ CC="$CC $ac_cv_prog_cc_c99"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
+ ac_prog_cc_stdc=c99
+fi
+fi
+if test x$ac_prog_cc_stdc = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
+printf %s "checking for $CC option to enable C89 features... " >&6; }
+if test ${ac_cv_prog_cc_c89+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ ac_cv_prog_cc_c89=no
+ac_save_CC=$CC
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+$ac_c_conftest_c89_program
_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
+ if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_prog_cc_c89=$ac_arg
fi
-rm -f core conftest.err conftest.$ac_objext
+rm -f core conftest.err conftest.$ac_objext conftest.beam
test "x$ac_cv_prog_cc_c89" != "xno" && break
done
rm -f conftest.$ac_ext
CC=$ac_save_CC
-
fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
+if test "x$ac_cv_prog_cc_c89" = xno
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+printf "%s\n" "unsupported" >&6; }
+else $as_nop
+ if test "x$ac_cv_prog_cc_c89" = x
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+printf "%s\n" "none needed" >&6; }
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
+printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
+ CC="$CC $ac_cv_prog_cc_c89"
+fi
+ ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
+ ac_prog_cc_stdc=c89
+fi
fi
ac_ext=c
@@ -5371,21 +5779,23 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_ext=c
+
+ ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
+printf %s "checking whether $CC understands -c and -o together... " >&6; }
+if test ${am_cv_prog_cc_c_o+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
@@ -5413,8 +5823,8 @@ _ACEOF
rm -f core conftest*
unset am_i
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
+printf "%s\n" "$am_cv_prog_cc_c_o" >&6; }
if test "$am_cv_prog_cc_c_o" != yes; then
# Losing compiler, so override with the script.
# FIXME: It is wrong to rewrite CC.
@@ -5432,11 +5842,12 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
depcc="$CC" am_compiler_list=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
+printf %s "checking dependency style of $depcc... " >&6; }
+if test ${am_cv_CC_dependencies_compiler_type+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
# making bogus files that we don't know about and never remove. For
@@ -5543,8 +5954,8 @@ else
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
+printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; }
CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
if
@@ -5558,16 +5969,18 @@ else
fi
-if test -n "$ac_tool_prefix"; then
+
+ if test -n "$ac_tool_prefix"; then
for ac_prog in ar lib "link -lib"
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_AR+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$AR"; then
ac_cv_prog_AR="$AR" # Let the user override the test.
else
@@ -5575,11 +5988,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5590,11 +6007,11 @@ fi
fi
AR=$ac_cv_prog_AR
if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
+printf "%s\n" "$AR" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -5607,11 +6024,12 @@ if test -z "$AR"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_AR+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_AR"; then
ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
else
@@ -5619,11 +6037,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_AR="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5634,11 +6056,11 @@ fi
fi
ac_ct_AR=$ac_cv_prog_ac_ct_AR
if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
+printf "%s\n" "$ac_ct_AR" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -5650,8 +6072,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
AR=$ac_ct_AR
@@ -5660,11 +6082,12 @@ fi
: ${AR=ar}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5
-$as_echo_n "checking the archiver ($AR) interface... " >&6; }
-if ${am_cv_ar_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5
+printf %s "checking the archiver ($AR) interface... " >&6; }
+if test ${am_cv_ar_interface+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -5676,12 +6099,13 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
/* end confdefs.h. */
int some_variable = 0;
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5'
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
(eval $am_ar_try) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
if test "$ac_status" -eq 0; then
am_cv_ar_interface=ar
@@ -5690,7 +6114,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5
(eval $am_ar_try) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
if test "$ac_status" -eq 0; then
am_cv_ar_interface=lib
@@ -5701,7 +6125,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
rm -f conftest.lib libconftest.a
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -5709,8 +6133,8 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5
-$as_echo "$am_cv_ar_interface" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5
+printf "%s\n" "$am_cv_ar_interface" >&6; }
case $am_cv_ar_interface in
ar)
@@ -5735,15 +6159,16 @@ ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_objc_compiler_gnu
if test -n "$ac_tool_prefix"; then
- for ac_prog in gcc objcc objc cc CC
+ for ac_prog in gcc objcc objc cc CC clang
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_OBJC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$OBJC"; then
ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
else
@@ -5751,11 +6176,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5766,11 +6195,11 @@ fi
fi
OBJC=$ac_cv_prog_OBJC
if test -n "$OBJC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
-$as_echo "$OBJC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
+printf "%s\n" "$OBJC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -5779,15 +6208,16 @@ fi
fi
if test -z "$OBJC"; then
ac_ct_OBJC=$OBJC
- for ac_prog in gcc objcc objc cc CC
+ for ac_prog in gcc objcc objc cc CC clang
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_OBJC+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_OBJC"; then
ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
else
@@ -5795,11 +6225,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OBJC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5810,11 +6244,11 @@ fi
fi
ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
if test -n "$ac_ct_OBJC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
-$as_echo "$ac_ct_OBJC" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
+printf "%s\n" "$ac_ct_OBJC" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -5826,8 +6260,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
OBJC=$ac_ct_OBJC
@@ -5835,7 +6269,7 @@ esac
fi
# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
+printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
set X $ac_compile
ac_compiler=$2
for ac_option in --version -v -V -qversion; do
@@ -5845,7 +6279,7 @@ case "(($ac_try" in
*) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
+printf "%s\n" "$ac_try_echo"; } >&5
(eval "$ac_compiler $ac_option >&5") 2>conftest.err
ac_status=$?
if test -s conftest.err; then
@@ -5855,20 +6289,21 @@ $as_echo "$ac_try_echo"; } >&5
cat conftest.er1 >&5
fi
rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
done
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
-$as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
-if ${ac_cv_objc_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU Objective C" >&5
+printf %s "checking whether the compiler supports GNU Objective C... " >&6; }
+if test ${ac_cv_objc_compiler_gnu+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
#ifndef __GNUC__
choke me
@@ -5878,29 +6313,33 @@ main ()
return 0;
}
_ACEOF
-if ac_fn_objc_try_compile "$LINENO"; then :
+if ac_fn_objc_try_compile "$LINENO"
+then :
ac_compiler_gnu=yes
-else
+else $as_nop
ac_compiler_gnu=no
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_cv_objc_compiler_gnu=$ac_compiler_gnu
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
-$as_echo "$ac_cv_objc_compiler_gnu" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
+printf "%s\n" "$ac_cv_objc_compiler_gnu" >&6; }
+ac_compiler_gnu=$ac_cv_objc_compiler_gnu
+
if test $ac_compiler_gnu = yes; then
GOBJC=yes
else
GOBJC=
fi
-ac_test_OBJCFLAGS=${OBJCFLAGS+set}
+ac_test_OBJCFLAGS=${OBJCFLAGS+y}
ac_save_OBJCFLAGS=$OBJCFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
-$as_echo_n "checking whether $OBJC accepts -g... " >&6; }
-if ${ac_cv_prog_objc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
+printf %s "checking whether $OBJC accepts -g... " >&6; }
+if test ${ac_cv_prog_objc_g+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_save_objc_werror_flag=$ac_objc_werror_flag
ac_objc_werror_flag=yes
ac_cv_prog_objc_g=no
@@ -5909,57 +6348,60 @@ else
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_objc_try_compile "$LINENO"; then :
+if ac_fn_objc_try_compile "$LINENO"
+then :
ac_cv_prog_objc_g=yes
-else
+else $as_nop
OBJCFLAGS=""
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_objc_try_compile "$LINENO"; then :
+if ac_fn_objc_try_compile "$LINENO"
+then :
-else
+else $as_nop
ac_objc_werror_flag=$ac_save_objc_werror_flag
OBJCFLAGS="-g"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_objc_try_compile "$LINENO"; then :
+if ac_fn_objc_try_compile "$LINENO"
+then :
ac_cv_prog_objc_g=yes
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_objc_werror_flag=$ac_save_objc_werror_flag
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
-$as_echo "$ac_cv_prog_objc_g" >&6; }
-if test "$ac_test_OBJCFLAGS" = set; then
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
+printf "%s\n" "$ac_cv_prog_objc_g" >&6; }
+if test $ac_test_OBJCFLAGS; then
OBJCFLAGS=$ac_save_OBJCFLAGS
elif test $ac_cv_prog_objc_g = yes; then
if test "$GOBJC" = yes; then
@@ -5982,11 +6424,12 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
depcc="$OBJC" am_compiler_list='gcc3 gcc'
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_OBJC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
+printf %s "checking dependency style of $depcc... " >&6; }
+if test ${am_cv_OBJC_dependencies_compiler_type+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
# making bogus files that we don't know about and never remove. For
@@ -6091,8 +6534,8 @@ else
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_OBJC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_OBJC_dependencies_compiler_type" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_OBJC_dependencies_compiler_type" >&5
+printf "%s\n" "$am_cv_OBJC_dependencies_compiler_type" >&6; }
OBJCDEPMODE=depmode=$am_cv_OBJC_dependencies_compiler_type
if
@@ -6108,13 +6551,13 @@ fi
CFLAGS="$cflags_bckup"
-FFMPEG_LIBS="-lavcodec -lavfilter -lavformat -lavutil -lswscale -lswresample"
+FFMPEG_FRAMEWORKS="-framework libavcodec -framework libavfilter -framework libavformat -framework libavutil -framework libswscale -framework libswresample"
case `pwd` in
*\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
+printf "%s\n" "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
esac
@@ -6134,6 +6577,7 @@ macro_revision='2.4.6'
+
ltmain=$ac_aux_dir/ltmain.sh
# Backslashify metacharacters that are still active within
@@ -6157,8 +6601,8 @@ ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
+printf %s "checking how to print strings... " >&6; }
# Test print first, because it will be a builtin if present.
if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
@@ -6184,12 +6628,12 @@ func_echo_all ()
}
case $ECHO in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
+ printf*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: printf" >&5
+printf "%s\n" "printf" >&6; } ;;
+ print*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
+printf "%s\n" "print -r" >&6; } ;;
+ *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cat" >&5
+printf "%s\n" "cat" >&6; } ;;
esac
@@ -6205,11 +6649,12 @@ esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
+printf %s "checking for a sed that does not truncate output... " >&6; }
+if test ${ac_cv_path_SED+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
for ac_i in 1 2 3 4 5 6 7; do
ac_script="$ac_script$as_nl$ac_script"
@@ -6223,10 +6668,15 @@ else
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_prog in sed gsed
+ do
for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
+ ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
as_fn_executable_p "$ac_path_SED" || continue
# Check for GNU ac_path_SED and select it if it is found.
# Check for GNU $ac_path_SED
@@ -6235,13 +6685,13 @@ case `"$ac_path_SED" --version 2>&1` in
ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
*)
ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
+ printf %s 0123456789 >"conftest.in"
while :
do
cat "conftest.in" "conftest.in" >"conftest.tmp"
mv "conftest.tmp" "conftest.in"
cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
+ printf "%s\n" '' >> "conftest.nl"
"$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
as_fn_arith $ac_count + 1 && ac_count=$as_val
@@ -6269,29 +6719,172 @@ else
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
+printf "%s\n" "$ac_cv_path_SED" >&6; }
+ SED="$ac_cv_path_SED"
+ rm -f conftest.sed
+
+test -z "$SED" && SED=sed
+Xsed="$SED -e 1s/^X//"
+
+
+
+
+
+
+
+
+
+
+
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
+printf %s "checking for grep that handles long lines and -e... " >&6; }
+if test ${ac_cv_path_GREP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if test -z "$GREP"; then
+ ac_path_GREP_found=false
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_prog in grep ggrep
+ do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
+ as_fn_executable_p "$ac_path_GREP" || continue
+# Check for GNU ac_path_GREP and select it if it is found.
+ # Check for GNU $ac_path_GREP
+case `"$ac_path_GREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
+*)
+ ac_count=0
+ printf %s 0123456789 >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ printf "%s\n" 'GREP' >> "conftest.nl"
+ "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ as_fn_arith $ac_count + 1 && ac_count=$as_val
+ if test $ac_count -gt ${ac_path_GREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_GREP="$ac_path_GREP"
+ ac_path_GREP_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+ $ac_path_GREP_found && break 3
+ done
+ done
+ done
+IFS=$as_save_IFS
+ if test -z "$ac_cv_path_GREP"; then
+ as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ fi
+else
+ ac_cv_path_GREP=$GREP
+fi
+
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
+printf "%s\n" "$ac_cv_path_GREP" >&6; }
+ GREP="$ac_cv_path_GREP"
+
+
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
+printf %s "checking for egrep... " >&6; }
+if test ${ac_cv_path_EGREP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
+ then ac_cv_path_EGREP="$GREP -E"
+ else
+ if test -z "$EGREP"; then
+ ac_path_EGREP_found=false
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
+do
+ IFS=$as_save_IFS
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_prog in egrep
+ do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
+ as_fn_executable_p "$ac_path_EGREP" || continue
+# Check for GNU ac_path_EGREP and select it if it is found.
+ # Check for GNU $ac_path_EGREP
+case `"$ac_path_EGREP" --version 2>&1` in
+*GNU*)
+ ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
+*)
+ ac_count=0
+ printf %s 0123456789 >"conftest.in"
+ while :
+ do
+ cat "conftest.in" "conftest.in" >"conftest.tmp"
+ mv "conftest.tmp" "conftest.in"
+ cp "conftest.in" "conftest.nl"
+ printf "%s\n" 'EGREP' >> "conftest.nl"
+ "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
+ as_fn_arith $ac_count + 1 && ac_count=$as_val
+ if test $ac_count -gt ${ac_path_EGREP_max-0}; then
+ # Best one so far, save it but keep looking for a better one
+ ac_cv_path_EGREP="$ac_path_EGREP"
+ ac_path_EGREP_max=$ac_count
+ fi
+ # 10*(2^10) chars as input seems more than enough
+ test $ac_count -gt 10 && break
+ done
+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
+esac
+
+ $ac_path_EGREP_found && break 3
+ done
+ done
+ done
+IFS=$as_save_IFS
+ if test -z "$ac_cv_path_EGREP"; then
+ as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ fi
+else
+ ac_cv_path_EGREP=$EGREP
+fi
+
+ fi
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
+printf "%s\n" "$ac_cv_path_EGREP" >&6; }
+ EGREP="$ac_cv_path_EGREP"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
+printf %s "checking for fgrep... " >&6; }
+if test ${ac_cv_path_FGREP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
then ac_cv_path_FGREP="$GREP -F"
else
@@ -6302,10 +6895,15 @@ else
for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_prog in fgrep
+ do
for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
+ ac_path_FGREP="$as_dir$ac_prog$ac_exec_ext"
as_fn_executable_p "$ac_path_FGREP" || continue
# Check for GNU ac_path_FGREP and select it if it is found.
# Check for GNU $ac_path_FGREP
@@ -6314,13 +6912,13 @@ case `"$ac_path_FGREP" --version 2>&1` in
ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
*)
ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
+ printf %s 0123456789 >"conftest.in"
while :
do
cat "conftest.in" "conftest.in" >"conftest.tmp"
mv "conftest.tmp" "conftest.in"
cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
+ printf "%s\n" 'FGREP' >> "conftest.nl"
"$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
as_fn_arith $ac_count + 1 && ac_count=$as_val
@@ -6349,8 +6947,8 @@ fi
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
+printf "%s\n" "$ac_cv_path_FGREP" >&6; }
FGREP="$ac_cv_path_FGREP"
@@ -6375,17 +6973,18 @@ test -z "$GREP" && GREP=grep
# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
+if test ${with_gnu_ld+y}
+then :
withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
-else
+else $as_nop
with_gnu_ld=no
fi
ac_prog=ld
if test yes = "$GCC"; then
# Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
+printf %s "checking for ld used by $CC... " >&6; }
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return, which upsets mingw
@@ -6414,15 +7013,16 @@ $as_echo_n "checking for ld used by $CC... " >&6; }
;;
esac
elif test yes = "$with_gnu_ld"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
+printf %s "checking for GNU ld... " >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
+printf %s "checking for non-GNU ld... " >&6; }
fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+if test ${lt_cv_path_LD+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -z "$LD"; then
lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
for ac_dir in $PATH; do
@@ -6451,18 +7051,19 @@ fi
LD=$lt_cv_path_LD
if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
+printf "%s\n" "$LD" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
+printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
+if test ${lt_cv_prog_gnu_ld+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
# I'd rather use --version here, but apparently some GNU lds only accept -v.
case `$LD -v 2>&1 &1 &5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
+printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; }
with_gnu_ld=$lt_cv_prog_gnu_ld
@@ -6485,11 +7086,12 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
+printf %s "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
+if test ${lt_cv_path_NM+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$NM"; then
# Let the user override the test.
lt_cv_path_NM=$NM
@@ -6539,8 +7141,8 @@ else
: ${lt_cv_path_NM=no}
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
+printf "%s\n" "$lt_cv_path_NM" >&6; }
if test no != "$lt_cv_path_NM"; then
NM=$lt_cv_path_NM
else
@@ -6553,11 +7155,12 @@ else
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_DUMPBIN+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$DUMPBIN"; then
ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
else
@@ -6565,11 +7168,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6580,11 +7187,11 @@ fi
fi
DUMPBIN=$ac_cv_prog_DUMPBIN
if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
+printf "%s\n" "$DUMPBIN" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -6597,11 +7204,12 @@ if test -z "$DUMPBIN"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_DUMPBIN+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_DUMPBIN"; then
ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
else
@@ -6609,11 +7217,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6624,11 +7236,11 @@ fi
fi
ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
+printf "%s\n" "$ac_ct_DUMPBIN" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -6640,8 +7252,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
DUMPBIN=$ac_ct_DUMPBIN
@@ -6669,11 +7281,12 @@ test -z "$NM" && NM=nm
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
+printf %s "checking the name lister ($NM) interface... " >&6; }
+if test ${lt_cv_nm_interface+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_nm_interface="BSD nm"
echo "int some_variable = 0;" > conftest.$ac_ext
(eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
@@ -6689,26 +7302,27 @@ else
fi
rm -f conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
+printf "%s\n" "$lt_cv_nm_interface" >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
+printf %s "checking whether ln -s works... " >&6; }
LN_S=$as_ln_s
if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
+printf "%s\n" "no, using $LN_S" >&6; }
fi
# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
+printf %s "checking the maximum length of command line arguments... " >&6; }
+if test ${lt_cv_sys_max_cmd_len+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
i=0
teststring=ABCD
@@ -6835,11 +7449,11 @@ else
fi
if test -n "$lt_cv_sys_max_cmd_len"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
+printf "%s\n" "$lt_cv_sys_max_cmd_len" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
+printf "%s\n" "none" >&6; }
fi
max_cmd_len=$lt_cv_sys_max_cmd_len
@@ -6883,11 +7497,12 @@ esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
-$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-if ${lt_cv_to_host_file_cmd+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
+printf %s "checking how to convert $build file names to $host format... " >&6; }
+if test ${lt_cv_to_host_file_cmd+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
case $host in
*-*-mingw* )
case $build in
@@ -6923,18 +7538,19 @@ esac
fi
to_host_file_cmd=$lt_cv_to_host_file_cmd
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
-$as_echo "$lt_cv_to_host_file_cmd" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
+printf "%s\n" "$lt_cv_to_host_file_cmd" >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
-$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-if ${lt_cv_to_tool_file_cmd+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
+printf %s "checking how to convert $build file names to toolchain format... " >&6; }
+if test ${lt_cv_to_tool_file_cmd+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
#assume ordinary cross tools, or native build.
lt_cv_to_tool_file_cmd=func_convert_file_noop
case $host in
@@ -6950,22 +7566,23 @@ esac
fi
to_tool_file_cmd=$lt_cv_to_tool_file_cmd
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
-$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
+printf "%s\n" "$lt_cv_to_tool_file_cmd" >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
+printf %s "checking for $LD option to reload object files... " >&6; }
+if test ${lt_cv_ld_reload_flag+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_ld_reload_flag='-r'
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
+printf "%s\n" "$lt_cv_ld_reload_flag" >&6; }
reload_flag=$lt_cv_ld_reload_flag
case $reload_flag in
"" | " "*) ;;
@@ -6998,11 +7615,12 @@ esac
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_OBJDUMP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$OBJDUMP"; then
ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
else
@@ -7010,11 +7628,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7025,11 +7647,11 @@ fi
fi
OBJDUMP=$ac_cv_prog_OBJDUMP
if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
+printf "%s\n" "$OBJDUMP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7038,11 +7660,12 @@ if test -z "$ac_cv_prog_OBJDUMP"; then
ac_ct_OBJDUMP=$OBJDUMP
# Extract the first word of "objdump", so it can be a program name with args.
set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_OBJDUMP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_OBJDUMP"; then
ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
else
@@ -7050,11 +7673,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7065,11 +7692,11 @@ fi
fi
ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
+printf "%s\n" "$ac_ct_OBJDUMP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_OBJDUMP" = x; then
@@ -7077,8 +7704,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
OBJDUMP=$ac_ct_OBJDUMP
@@ -7097,11 +7724,12 @@ test -z "$OBJDUMP" && OBJDUMP=objdump
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
+printf %s "checking how to recognize dependent libraries... " >&6; }
+if test ${lt_cv_deplibs_check_method+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_file_magic_cmd='$MAGIC_CMD'
lt_cv_file_magic_test_file=
lt_cv_deplibs_check_method='unknown'
@@ -7297,8 +7925,8 @@ os2*)
esac
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
+printf "%s\n" "$lt_cv_deplibs_check_method" >&6; }
file_magic_glob=
want_nocaseglob=no
@@ -7342,11 +7970,12 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
set dummy ${ac_tool_prefix}dlltool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_DLLTOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$DLLTOOL"; then
ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
else
@@ -7354,11 +7983,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7369,11 +8002,11 @@ fi
fi
DLLTOOL=$ac_cv_prog_DLLTOOL
if test -n "$DLLTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
-$as_echo "$DLLTOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
+printf "%s\n" "$DLLTOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7382,11 +8015,12 @@ if test -z "$ac_cv_prog_DLLTOOL"; then
ac_ct_DLLTOOL=$DLLTOOL
# Extract the first word of "dlltool", so it can be a program name with args.
set dummy dlltool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_DLLTOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_DLLTOOL"; then
ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
else
@@ -7394,11 +8028,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DLLTOOL="dlltool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7409,11 +8047,11 @@ fi
fi
ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
if test -n "$ac_ct_DLLTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
-$as_echo "$ac_ct_DLLTOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
+printf "%s\n" "$ac_ct_DLLTOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_DLLTOOL" = x; then
@@ -7421,8 +8059,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
DLLTOOL=$ac_ct_DLLTOOL
@@ -7442,11 +8080,12 @@ test -z "$DLLTOOL" && DLLTOOL=dlltool
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
-$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
+printf %s "checking how to associate runtime and link libraries... " >&6; }
+if test ${lt_cv_sharedlib_from_linklib_cmd+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_sharedlib_from_linklib_cmd='unknown'
case $host_os in
@@ -7469,8 +8108,8 @@ cygwin* | mingw* | pw32* | cegcc*)
esac
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
-$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
+printf "%s\n" "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
@@ -7485,11 +8124,12 @@ if test -n "$ac_tool_prefix"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_AR+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$AR"; then
ac_cv_prog_AR="$AR" # Let the user override the test.
else
@@ -7497,11 +8137,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7512,11 +8156,11 @@ fi
fi
AR=$ac_cv_prog_AR
if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
+printf "%s\n" "$AR" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7529,11 +8173,12 @@ if test -z "$AR"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_AR+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_AR"; then
ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
else
@@ -7541,11 +8186,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_AR="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7556,11 +8205,11 @@ fi
fi
ac_ct_AR=$ac_cv_prog_ac_ct_AR
if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
+printf "%s\n" "$ac_ct_AR" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7572,8 +8221,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
AR=$ac_ct_AR
@@ -7593,30 +8242,32 @@ fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
-$as_echo_n "checking for archiver @FILE support... " >&6; }
-if ${lt_cv_ar_at_file+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
+printf %s "checking for archiver @FILE support... " >&6; }
+if test ${lt_cv_ar_at_file+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_ar_at_file=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
echo conftest.$ac_objext > conftest.lst
lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
(eval $lt_ar_try) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
if test 0 -eq "$ac_status"; then
# Ensure the archiver fails upon bogus file names.
@@ -7624,7 +8275,7 @@ if ac_fn_c_try_compile "$LINENO"; then :
{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
(eval $lt_ar_try) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
if test 0 -ne "$ac_status"; then
lt_cv_ar_at_file=@
@@ -7633,11 +8284,11 @@ if ac_fn_c_try_compile "$LINENO"; then :
rm -f conftest.* libconftest.a
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
-$as_echo "$lt_cv_ar_at_file" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
+printf "%s\n" "$lt_cv_ar_at_file" >&6; }
if test no = "$lt_cv_ar_at_file"; then
archiver_list_spec=
@@ -7654,11 +8305,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_STRIP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$STRIP"; then
ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
@@ -7666,11 +8318,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7681,11 +8337,11 @@ fi
fi
STRIP=$ac_cv_prog_STRIP
if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
+printf "%s\n" "$STRIP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7694,11 +8350,12 @@ if test -z "$ac_cv_prog_STRIP"; then
ac_ct_STRIP=$STRIP
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_STRIP+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_STRIP"; then
ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
else
@@ -7706,11 +8363,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7721,11 +8382,11 @@ fi
fi
ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
+printf "%s\n" "$ac_ct_STRIP" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_STRIP" = x; then
@@ -7733,8 +8394,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
STRIP=$ac_ct_STRIP
@@ -7753,11 +8414,12 @@ test -z "$STRIP" && STRIP=:
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_RANLIB+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$RANLIB"; then
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
@@ -7765,11 +8427,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7780,11 +8446,11 @@ fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
+printf "%s\n" "$RANLIB" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -7793,11 +8459,12 @@ if test -z "$ac_cv_prog_RANLIB"; then
ac_ct_RANLIB=$RANLIB
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_RANLIB+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_RANLIB"; then
ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
else
@@ -7805,11 +8472,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -7820,11 +8491,11 @@ fi
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
+printf "%s\n" "$ac_ct_RANLIB" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_RANLIB" = x; then
@@ -7832,8 +8503,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
RANLIB=$ac_ct_RANLIB
@@ -7922,11 +8593,12 @@ compiler=$CC
# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
+printf %s "checking command to parse $NM output from $compiler object... " >&6; }
+if test ${lt_cv_sys_global_symbol_pipe+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
# These are sane defaults that work on at least a few old systems.
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
@@ -8078,14 +8750,14 @@ _LT_EOF
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
# Now try to grab the symbols.
nlist=conftest.nm
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
(eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && test -s "$nlist"; then
# Try sorting and uniquifying the output.
if sort "$nlist" | uniq > "$nlist"T; then
@@ -8154,7 +8826,7 @@ _LT_EOF
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
(eval $ac_link) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && test -s conftest$ac_exeext; then
pipe_works=yes
fi
@@ -8189,11 +8861,11 @@ if test -z "$lt_cv_sys_global_symbol_pipe"; then
lt_cv_sys_global_symbol_to_cdecl=
fi
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5
+printf "%s\n" "failed" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
+printf "%s\n" "ok" >&6; }
fi
# Response file support.
@@ -8239,13 +8911,14 @@ fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
-$as_echo_n "checking for sysroot... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
+printf %s "checking for sysroot... " >&6; }
# Check whether --with-sysroot was given.
-if test "${with_sysroot+set}" = set; then :
+if test ${with_sysroot+y}
+then :
withval=$with_sysroot;
-else
+else $as_nop
with_sysroot=no
fi
@@ -8263,24 +8936,25 @@ case $with_sysroot in #(
no|'')
;; #(
*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
-$as_echo "$with_sysroot" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
+printf "%s\n" "$with_sysroot" >&6; }
as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
;;
esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
-$as_echo "${lt_sysroot:-no}" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
+printf "%s\n" "${lt_sysroot:-no}" >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
-$as_echo_n "checking for a working dd... " >&6; }
-if ${ac_cv_path_lt_DD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
+printf %s "checking for a working dd... " >&6; }
+if test ${ac_cv_path_lt_DD+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
printf 0123456789abcdef0123456789abcdef >conftest.i
cat conftest.i conftest.i >conftest2.i
: ${lt_DD:=$DD}
@@ -8291,10 +8965,15 @@ if test -z "$lt_DD"; then
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in dd; do
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ for ac_prog in dd
+ do
for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
+ ac_path_lt_DD="$as_dir$ac_prog$ac_exec_ext"
as_fn_executable_p "$ac_path_lt_DD" || continue
if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then
cmp -s conftest.i conftest.out \
@@ -8314,15 +8993,16 @@ fi
rm -f conftest.i conftest2.i conftest.out
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
-$as_echo "$ac_cv_path_lt_DD" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
+printf "%s\n" "$ac_cv_path_lt_DD" >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
-$as_echo_n "checking how to truncate binary pipes... " >&6; }
-if ${lt_cv_truncate_bin+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
+printf %s "checking how to truncate binary pipes... " >&6; }
+if test ${lt_cv_truncate_bin+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
printf 0123456789abcdef0123456789abcdef >conftest.i
cat conftest.i conftest.i >conftest2.i
lt_cv_truncate_bin=
@@ -8333,8 +9013,8 @@ fi
rm -f conftest.i conftest2.i conftest.out
test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
-$as_echo "$lt_cv_truncate_bin" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
+printf "%s\n" "$lt_cv_truncate_bin" >&6; }
@@ -8357,7 +9037,8 @@ func_cc_basename ()
}
# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
+if test ${enable_libtool_lock+y}
+then :
enableval=$enable_libtool_lock;
fi
@@ -8373,7 +9054,7 @@ ia64-*-hpux*)
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
case `/usr/bin/file conftest.$ac_objext` in
*ELF-32*)
@@ -8393,7 +9074,7 @@ ia64-*-hpux*)
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
if test yes = "$lt_cv_prog_gnu_ld"; then
case `/usr/bin/file conftest.$ac_objext` in
@@ -8431,7 +9112,7 @@ mips64*-*linux*)
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
emul=elf
case `/usr/bin/file conftest.$ac_objext` in
@@ -8472,7 +9153,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
case `/usr/bin/file conftest.o` in
*32-bit*)
@@ -8535,11 +9216,12 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
SAVE_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
+printf %s "checking whether the C compiler needs -belf... " >&6; }
+if test ${lt_cv_cc_needs_belf+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -8550,19 +9232,20 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
lt_cv_cc_needs_belf=yes
-else
+else $as_nop
lt_cv_cc_needs_belf=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
@@ -8571,8 +9254,8 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
+printf "%s\n" "$lt_cv_cc_needs_belf" >&6; }
if test yes != "$lt_cv_cc_needs_belf"; then
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
CFLAGS=$SAVE_CFLAGS
@@ -8585,7 +9268,7 @@ $as_echo "$lt_cv_cc_needs_belf" >&6; }
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
case `/usr/bin/file conftest.o` in
*64-bit*)
@@ -8622,11 +9305,12 @@ need_locks=$enable_libtool_lock
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
set dummy ${ac_tool_prefix}mt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_MANIFEST_TOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$MANIFEST_TOOL"; then
ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
else
@@ -8634,11 +9318,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8649,11 +9337,11 @@ fi
fi
MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
if test -n "$MANIFEST_TOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
-$as_echo "$MANIFEST_TOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
+printf "%s\n" "$MANIFEST_TOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -8662,11 +9350,12 @@ if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
# Extract the first word of "mt", so it can be a program name with args.
set dummy mt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_MANIFEST_TOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_MANIFEST_TOOL"; then
ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
else
@@ -8674,11 +9363,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8689,11 +9382,11 @@ fi
fi
ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
if test -n "$ac_ct_MANIFEST_TOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
-$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
+printf "%s\n" "$ac_ct_MANIFEST_TOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_MANIFEST_TOOL" = x; then
@@ -8701,8 +9394,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
@@ -8712,11 +9405,12 @@ else
fi
test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
-$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-if ${lt_cv_path_mainfest_tool+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
+printf %s "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
+if test ${lt_cv_path_mainfest_tool+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_path_mainfest_tool=no
echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
$MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
@@ -8726,8 +9420,8 @@ else
fi
rm -f conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
-$as_echo "$lt_cv_path_mainfest_tool" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
+printf "%s\n" "$lt_cv_path_mainfest_tool" >&6; }
if test yes != "$lt_cv_path_mainfest_tool"; then
MANIFEST_TOOL=:
fi
@@ -8742,11 +9436,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_DSYMUTIL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$DSYMUTIL"; then
ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
else
@@ -8754,11 +9449,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8769,11 +9468,11 @@ fi
fi
DSYMUTIL=$ac_cv_prog_DSYMUTIL
if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
+printf "%s\n" "$DSYMUTIL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -8782,11 +9481,12 @@ if test -z "$ac_cv_prog_DSYMUTIL"; then
ac_ct_DSYMUTIL=$DSYMUTIL
# Extract the first word of "dsymutil", so it can be a program name with args.
set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_DSYMUTIL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_DSYMUTIL"; then
ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
else
@@ -8794,11 +9494,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8809,11 +9513,11 @@ fi
fi
ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
+printf "%s\n" "$ac_ct_DSYMUTIL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_DSYMUTIL" = x; then
@@ -8821,8 +9525,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
DSYMUTIL=$ac_ct_DSYMUTIL
@@ -8834,11 +9538,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_NMEDIT+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$NMEDIT"; then
ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
else
@@ -8846,11 +9551,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8861,11 +9570,11 @@ fi
fi
NMEDIT=$ac_cv_prog_NMEDIT
if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
+printf "%s\n" "$NMEDIT" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -8874,11 +9583,12 @@ if test -z "$ac_cv_prog_NMEDIT"; then
ac_ct_NMEDIT=$NMEDIT
# Extract the first word of "nmedit", so it can be a program name with args.
set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_NMEDIT+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_NMEDIT"; then
ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
else
@@ -8886,11 +9596,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8901,11 +9615,11 @@ fi
fi
ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
+printf "%s\n" "$ac_ct_NMEDIT" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_NMEDIT" = x; then
@@ -8913,8 +9627,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
NMEDIT=$ac_ct_NMEDIT
@@ -8926,11 +9640,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_LIPO+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$LIPO"; then
ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
else
@@ -8938,11 +9653,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8953,11 +9672,11 @@ fi
fi
LIPO=$ac_cv_prog_LIPO
if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
+printf "%s\n" "$LIPO" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -8966,11 +9685,12 @@ if test -z "$ac_cv_prog_LIPO"; then
ac_ct_LIPO=$LIPO
# Extract the first word of "lipo", so it can be a program name with args.
set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_LIPO+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_LIPO"; then
ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
else
@@ -8978,11 +9698,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -8993,11 +9717,11 @@ fi
fi
ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
+printf "%s\n" "$ac_ct_LIPO" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_LIPO" = x; then
@@ -9005,8 +9729,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
LIPO=$ac_ct_LIPO
@@ -9018,11 +9742,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_OTOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$OTOOL"; then
ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
else
@@ -9030,11 +9755,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -9045,11 +9774,11 @@ fi
fi
OTOOL=$ac_cv_prog_OTOOL
if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
+printf "%s\n" "$OTOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -9058,11 +9787,12 @@ if test -z "$ac_cv_prog_OTOOL"; then
ac_ct_OTOOL=$OTOOL
# Extract the first word of "otool", so it can be a program name with args.
set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_OTOOL+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_OTOOL"; then
ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
else
@@ -9070,11 +9800,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -9085,11 +9819,11 @@ fi
fi
ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
+printf "%s\n" "$ac_ct_OTOOL" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_OTOOL" = x; then
@@ -9097,8 +9831,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
OTOOL=$ac_ct_OTOOL
@@ -9110,11 +9844,12 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_OTOOL64+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$OTOOL64"; then
ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
else
@@ -9122,11 +9857,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -9137,11 +9876,11 @@ fi
fi
OTOOL64=$ac_cv_prog_OTOOL64
if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
+printf "%s\n" "$OTOOL64" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -9150,11 +9889,12 @@ if test -z "$ac_cv_prog_OTOOL64"; then
ac_ct_OTOOL64=$OTOOL64
# Extract the first word of "otool64", so it can be a program name with args.
set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+printf %s "checking for $ac_word... " >&6; }
+if test ${ac_cv_prog_ac_ct_OTOOL64+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test -n "$ac_ct_OTOOL64"; then
ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
else
@@ -9162,11 +9902,15 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -9177,11 +9921,11 @@ fi
fi
ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
+printf "%s\n" "$ac_ct_OTOOL64" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
if test "x$ac_ct_OTOOL64" = x; then
@@ -9189,8 +9933,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
OTOOL64=$ac_ct_OTOOL64
@@ -9225,11 +9969,12 @@ fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
+printf %s "checking for -single_module linker flag... " >&6; }
+if test ${lt_cv_apple_cc_single_mod+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_apple_cc_single_mod=no
if test -z "$LT_MULTI_MODULE"; then
# By default we will add the -single_module flag. You can override
@@ -9258,14 +10003,15 @@ else
rm -f conftest.*
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
+printf "%s\n" "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
+printf %s "checking for -exported_symbols_list linker flag... " >&6; }
+if test ${lt_cv_ld_exported_symbols_list+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_ld_exported_symbols_list=no
save_LDFLAGS=$LDFLAGS
echo "_main" > conftest.sym
@@ -9274,31 +10020,33 @@ else
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
lt_cv_ld_exported_symbols_list=yes
-else
+else $as_nop
lt_cv_ld_exported_symbols_list=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LDFLAGS=$save_LDFLAGS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
+printf "%s\n" "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
+printf %s "checking for -force_load linker flag... " >&6; }
+if test ${lt_cv_ld_force_load+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_ld_force_load=no
cat > conftest.c << _LT_EOF
int forced_loaded() { return 2;}
@@ -9326,8 +10074,8 @@ _LT_EOF
rm -rf conftest.dSYM
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
+printf "%s\n" "$lt_cv_ld_force_load" >&6; }
case $host_os in
rhapsody* | darwin1.[012])
_lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
@@ -9393,19 +10141,14 @@ func_munge_path_list ()
esac
}
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
+ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
+if test "x$ac_cv_header_dlfcn_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h
fi
-done
-
@@ -9421,7 +10164,8 @@ done
# Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
+if test ${enable_shared+y}
+then :
enableval=$enable_shared; p=${PACKAGE-default}
case $enableval in
yes) enable_shared=yes ;;
@@ -9439,7 +10183,7 @@ if test "${enable_shared+set}" = set; then :
IFS=$lt_save_ifs
;;
esac
-else
+else $as_nop
enable_shared=yes
fi
@@ -9452,7 +10196,8 @@ fi
# Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
+if test ${enable_static+y}
+then :
enableval=$enable_static; p=${PACKAGE-default}
case $enableval in
yes) enable_static=yes ;;
@@ -9470,7 +10215,7 @@ if test "${enable_static+set}" = set; then :
IFS=$lt_save_ifs
;;
esac
-else
+else $as_nop
enable_static=yes
fi
@@ -9484,7 +10229,8 @@ fi
# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
+if test ${with_pic+y}
+then :
withval=$with_pic; lt_p=${PACKAGE-default}
case $withval in
yes|no) pic_mode=$withval ;;
@@ -9501,7 +10247,7 @@ if test "${with_pic+set}" = set; then :
IFS=$lt_save_ifs
;;
esac
-else
+else $as_nop
pic_mode=default
fi
@@ -9513,7 +10259,8 @@ fi
# Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
+if test ${enable_fast_install+y}
+then :
enableval=$enable_fast_install; p=${PACKAGE-default}
case $enableval in
yes) enable_fast_install=yes ;;
@@ -9531,7 +10278,7 @@ if test "${enable_fast_install+set}" = set; then :
IFS=$lt_save_ifs
;;
esac
-else
+else $as_nop
enable_fast_install=yes
fi
@@ -9545,11 +10292,12 @@ fi
shared_archive_member_spec=
case $host,$enable_shared in
power*-*-aix[5-9]*,yes)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
-$as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
+printf %s "checking which variant of shared library versioning to provide... " >&6; }
# Check whether --with-aix-soname was given.
-if test "${with_aix_soname+set}" = set; then :
+if test ${with_aix_soname+y}
+then :
withval=$with_aix_soname; case $withval in
aix|svr4|both)
;;
@@ -9558,18 +10306,19 @@ if test "${with_aix_soname+set}" = set; then :
;;
esac
lt_cv_with_aix_soname=$with_aix_soname
-else
- if ${lt_cv_with_aix_soname+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+else $as_nop
+ if test ${lt_cv_with_aix_soname+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_with_aix_soname=aix
fi
with_aix_soname=$lt_cv_with_aix_soname
fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
-$as_echo "$with_aix_soname" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
+printf "%s\n" "$with_aix_soname" >&6; }
if test aix != "$with_aix_soname"; then
# For the AIX way of multilib, we name the shared archive member
# based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
@@ -9651,11 +10400,12 @@ if test -n "${ZSH_VERSION+set}"; then
setopt NO_GLOB_SUBST
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
+printf %s "checking for objdir... " >&6; }
+if test ${lt_cv_objdir+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
rm -f .libs 2>/dev/null
mkdir .libs 2>/dev/null
if test -d .libs; then
@@ -9666,17 +10416,15 @@ else
fi
rmdir .libs 2>/dev/null
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
+printf "%s\n" "$lt_cv_objdir" >&6; }
objdir=$lt_cv_objdir
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
+printf "%s\n" "#define LT_OBJDIR \"$lt_cv_objdir/\"" >>confdefs.h
@@ -9722,11 +10470,12 @@ test -z "$MAGIC_CMD" && MAGIC_CMD=file
case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
+printf %s "checking for ${ac_tool_prefix}file... " >&6; }
+if test ${lt_cv_path_MAGIC_CMD+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
case $MAGIC_CMD in
[\\/*] | ?:[\\/]*)
lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
@@ -9775,11 +10524,11 @@ fi
MAGIC_CMD=$lt_cv_path_MAGIC_CMD
if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
+printf "%s\n" "$MAGIC_CMD" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -9788,11 +10537,12 @@ fi
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for file" >&5
+printf %s "checking for file... " >&6; }
+if test ${lt_cv_path_MAGIC_CMD+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
case $MAGIC_CMD in
[\\/*] | ?:[\\/]*)
lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
@@ -9841,11 +10591,11 @@ fi
MAGIC_CMD=$lt_cv_path_MAGIC_CMD
if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
+printf "%s\n" "$MAGIC_CMD" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
@@ -9930,11 +10680,12 @@ if test yes = "$GCC"; then
lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
+printf %s "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
+if test ${lt_cv_prog_compiler_rtti_exceptions+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_rtti_exceptions=no
ac_outfile=conftest.$ac_objext
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
@@ -9965,8 +10716,8 @@ else
$RM conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
+printf "%s\n" "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
@@ -10323,26 +11074,28 @@ case $host_os in
;;
esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-if ${lt_cv_prog_compiler_pic+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
+printf %s "checking for $compiler option to produce PIC... " >&6; }
+if test ${lt_cv_prog_compiler_pic+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
-$as_echo "$lt_cv_prog_compiler_pic" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
+printf "%s\n" "$lt_cv_prog_compiler_pic" >&6; }
lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
#
# Check to make sure the PIC flag actually works.
#
if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
+printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
+if test ${lt_cv_prog_compiler_pic_works+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_pic_works=no
ac_outfile=conftest.$ac_objext
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
@@ -10373,8 +11126,8 @@ else
$RM conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
+printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; }
if test yes = "$lt_cv_prog_compiler_pic_works"; then
case $lt_prog_compiler_pic in
@@ -10402,11 +11155,12 @@ fi
# Check to make sure the static flag actually works.
#
wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
+if test ${lt_cv_prog_compiler_static_works+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_static_works=no
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
@@ -10430,8 +11184,8 @@ else
LDFLAGS=$save_LDFLAGS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
+printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; }
if test yes = "$lt_cv_prog_compiler_static_works"; then
:
@@ -10445,11 +11199,12 @@ fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
+printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
+if test ${lt_cv_prog_compiler_c_o+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_c_o=no
$RM -r conftest 2>/dev/null
mkdir conftest
@@ -10492,19 +11247,20 @@ else
$RM conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
+printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
+printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
+if test ${lt_cv_prog_compiler_c_o+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler_c_o=no
$RM -r conftest 2>/dev/null
mkdir conftest
@@ -10547,8 +11303,8 @@ else
$RM conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
+printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; }
@@ -10556,19 +11312,19 @@ $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
hard_links=nottested
if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
# do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
+printf %s "checking if we can lock with hard links... " >&6; }
hard_links=yes
$RM conftest*
ln conftest.a conftest.b 2>/dev/null && hard_links=no
touch conftest.a
ln conftest.a conftest.b 2>&5 || hard_links=no
ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
+printf "%s\n" "$hard_links" >&6; }
if test no = "$hard_links"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
+printf "%s\n" "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
need_locks=warn
fi
else
@@ -10580,8 +11336,8 @@ fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
runpath_var=
allow_undefined_flag=
@@ -11136,21 +11892,23 @@ _LT_EOF
if test set = "${lt_cv_aix_libpath+set}"; then
aix_libpath=$lt_cv_aix_libpath
else
- if ${lt_cv_aix_libpath_+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ if test ${lt_cv_aix_libpath_+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
lt_aix_libpath_sed='
/Import File Strings/,/^$/ {
@@ -11165,7 +11923,7 @@ if ac_fn_c_try_link "$LINENO"; then :
lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
fi
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
if test -z "$lt_cv_aix_libpath_"; then
lt_cv_aix_libpath_=/usr/lib:/lib
@@ -11189,21 +11947,23 @@ fi
if test set = "${lt_cv_aix_libpath+set}"; then
aix_libpath=$lt_cv_aix_libpath
else
- if ${lt_cv_aix_libpath_+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ if test ${lt_cv_aix_libpath_+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
lt_aix_libpath_sed='
/Import File Strings/,/^$/ {
@@ -11218,7 +11978,7 @@ if ac_fn_c_try_link "$LINENO"; then :
lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
fi
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
if test -z "$lt_cv_aix_libpath_"; then
lt_cv_aix_libpath_=/usr/lib:/lib
@@ -11469,11 +12229,12 @@ fi
# Older versions of the 11.00 compiler do not understand -b yet
# (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
+printf %s "checking if $CC understands -b... " >&6; }
+if test ${lt_cv_prog_compiler__b+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_prog_compiler__b=no
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -b"
@@ -11497,8 +12258,8 @@ else
LDFLAGS=$save_LDFLAGS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
+printf "%s\n" "$lt_cv_prog_compiler__b" >&6; }
if test yes = "$lt_cv_prog_compiler__b"; then
archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
@@ -11538,28 +12299,30 @@ fi
# work, assume that -exports_file does not work either and
# implicitly export all symbols.
# This should be the same for all languages, so no per-tag cache variable.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
-$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-if ${lt_cv_irix_exported_symbol+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
+printf %s "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
+if test ${lt_cv_irix_exported_symbol+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int foo (void) { return 0; }
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
lt_cv_irix_exported_symbol=yes
-else
+else $as_nop
lt_cv_irix_exported_symbol=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LDFLAGS=$save_LDFLAGS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
-$as_echo "$lt_cv_irix_exported_symbol" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
+printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; }
if test yes = "$lt_cv_irix_exported_symbol"; then
archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
fi
@@ -11839,8 +12602,8 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; }
fi
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
+printf "%s\n" "$ld_shlibs" >&6; }
test no = "$ld_shlibs" && can_build_shared=no
with_gnu_ld=$with_gnu_ld
@@ -11876,18 +12639,19 @@ x|xyes)
# Test whether the compiler implicitly links with -lc since on some
# systems, -lgcc has to come before -lc. If gcc already passes -lc
# to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
+printf %s "checking whether -lc should be explicitly linked in... " >&6; }
+if test ${lt_cv_archive_cmds_need_lc+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
$RM conftest*
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } 2>conftest.err; then
soname=conftest
lib=conftest
@@ -11905,7 +12669,7 @@ else
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
(eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
then
lt_cv_archive_cmds_need_lc=no
@@ -11919,8 +12683,8 @@ else
$RM conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
+printf "%s\n" "$lt_cv_archive_cmds_need_lc" >&6; }
archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
;;
esac
@@ -12079,8 +12843,8 @@ esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
+printf %s "checking dynamic linker characteristics... " >&6; }
if test yes = "$GCC"; then
case $host_os in
@@ -12641,9 +13405,10 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
shlibpath_overrides_runpath=no
# Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ if test ${lt_cv_shlibpath_overrides_runpath+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
lt_cv_shlibpath_overrides_runpath=no
save_LDFLAGS=$LDFLAGS
save_libdir=$libdir
@@ -12653,19 +13418,21 @@ else
/* end confdefs.h. */
int
-main ()
+main (void)
{
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
+if ac_fn_c_try_link "$LINENO"
+then :
+ if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null
+then :
lt_cv_shlibpath_overrides_runpath=yes
fi
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LDFLAGS=$save_LDFLAGS
libdir=$save_libdir
@@ -12897,8 +13664,8 @@ uts4*)
dynamic_linker=no
;;
esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
+printf "%s\n" "$dynamic_linker" >&6; }
test no = "$dynamic_linker" && can_build_shared=no
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
@@ -13019,8 +13786,8 @@ configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
+printf %s "checking how to hardcode library paths into programs... " >&6; }
hardcode_action=
if test -n "$hardcode_libdir_flag_spec" ||
test -n "$runpath_var" ||
@@ -13044,8 +13811,8 @@ else
# directories.
hardcode_action=unsupported
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
+printf "%s\n" "$hardcode_action" >&6; }
if test relink = "$hardcode_action" ||
test yes = "$inherit_rpath"; then
@@ -13089,11 +13856,12 @@ else
darwin*)
# if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
+printf %s "checking for dlopen in -ldl... " >&6; }
+if test ${ac_cv_lib_dl_dlopen+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -13102,32 +13870,31 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
char dlopen ();
int
-main ()
+main (void)
{
return dlopen ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
ac_cv_lib_dl_dlopen=yes
-else
+else $as_nop
ac_cv_lib_dl_dlopen=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
+printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
+if test "x$ac_cv_lib_dl_dlopen" = xyes
+then :
lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
-else
+else $as_nop
lt_cv_dlopen=dyld
lt_cv_dlopen_libs=
@@ -13147,14 +13914,16 @@ fi
*)
ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
+if test "x$ac_cv_func_shl_load" = xyes
+then :
lt_cv_dlopen=shl_load
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
+printf %s "checking for shl_load in -ldld... " >&6; }
+if test ${ac_cv_lib_dld_shl_load+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -13163,41 +13932,42 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
char shl_load ();
int
-main ()
+main (void)
{
return shl_load ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
ac_cv_lib_dld_shl_load=yes
-else
+else $as_nop
ac_cv_lib_dld_shl_load=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
+printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
+if test "x$ac_cv_lib_dld_shl_load" = xyes
+then :
lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
-else
+else $as_nop
ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
+if test "x$ac_cv_func_dlopen" = xyes
+then :
lt_cv_dlopen=dlopen
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
+printf %s "checking for dlopen in -ldl... " >&6; }
+if test ${ac_cv_lib_dl_dlopen+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -13206,37 +13976,37 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
char dlopen ();
int
-main ()
+main (void)
{
return dlopen ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
ac_cv_lib_dl_dlopen=yes
-else
+else $as_nop
ac_cv_lib_dl_dlopen=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
+printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
+if test "x$ac_cv_lib_dl_dlopen" = xyes
+then :
lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
+printf %s "checking for dlopen in -lsvld... " >&6; }
+if test ${ac_cv_lib_svld_dlopen+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_check_lib_save_LIBS=$LIBS
LIBS="-lsvld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -13245,37 +14015,37 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
char dlopen ();
int
-main ()
+main (void)
{
return dlopen ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
ac_cv_lib_svld_dlopen=yes
-else
+else $as_nop
ac_cv_lib_svld_dlopen=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
+printf "%s\n" "$ac_cv_lib_svld_dlopen" >&6; }
+if test "x$ac_cv_lib_svld_dlopen" = xyes
+then :
lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+else $as_nop
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
+printf %s "checking for dld_link in -ldld... " >&6; }
+if test ${ac_cv_lib_dld_dld_link+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -13284,30 +14054,29 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
char dld_link ();
int
-main ()
+main (void)
{
return dld_link ();
;
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
+if ac_fn_c_try_link "$LINENO"
+then :
ac_cv_lib_dld_dld_link=yes
-else
+else $as_nop
ac_cv_lib_dld_dld_link=no
fi
-rm -f core conftest.err conftest.$ac_objext \
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
+printf "%s\n" "$ac_cv_lib_dld_dld_link" >&6; }
+if test "x$ac_cv_lib_dld_dld_link" = xyes
+then :
lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
fi
@@ -13346,11 +14115,12 @@ fi
save_LIBS=$LIBS
LIBS="$lt_cv_dlopen_libs $LIBS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
+printf %s "checking whether a program can dlopen itself... " >&6; }
+if test ${lt_cv_dlopen_self+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test yes = "$cross_compiling"; then :
lt_cv_dlopen_self=cross
else
@@ -13429,7 +14199,7 @@ _LT_EOF
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
(eval $ac_link) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
(./conftest; exit; ) >&5 2>/dev/null
lt_status=$?
@@ -13447,16 +14217,17 @@ rm -fr conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
+printf "%s\n" "$lt_cv_dlopen_self" >&6; }
if test yes = "$lt_cv_dlopen_self"; then
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
+printf %s "checking whether a statically linked program can dlopen itself... " >&6; }
+if test ${lt_cv_dlopen_self_static+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
if test yes = "$cross_compiling"; then :
lt_cv_dlopen_self_static=cross
else
@@ -13535,7 +14306,7 @@ _LT_EOF
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
(eval $ac_link) 2>&5
ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
(./conftest; exit; ) >&5 2>/dev/null
lt_status=$?
@@ -13553,8 +14324,8 @@ rm -fr conftest*
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
+printf "%s\n" "$lt_cv_dlopen_self_static" >&6; }
fi
CPPFLAGS=$save_CPPFLAGS
@@ -13592,13 +14363,13 @@ fi
striplib=
old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
+printf %s "checking whether stripping libraries is possible... " >&6; }
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
else
# FIXME - insert some real tests, host_os isn't really good enough
case $host_os in
@@ -13606,16 +14377,16 @@ else
if test -n "$STRIP"; then
striplib="$STRIP -x"
old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
fi
;;
*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
;;
esac
fi
@@ -13632,13 +14403,13 @@ fi
# Report what library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
+printf %s "checking if libtool supports shared libraries... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
+printf "%s\n" "$can_build_shared" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
+printf %s "checking whether to build shared libraries... " >&6; }
test no = "$can_build_shared" && enable_shared=no
# On AIX, shared libraries and static libraries use the same namespace, and
@@ -13662,15 +14433,15 @@ $as_echo_n "checking whether to build shared libraries... " >&6; }
fi
;;
esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
+printf "%s\n" "$enable_shared" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
+printf %s "checking whether to build static libraries... " >&6; }
# Make sure either enable_shared or enable_static is yes.
test yes = "$enable_shared" || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
+printf "%s\n" "$enable_static" >&6; }
@@ -13708,45 +14479,88 @@ CC=$lt_save_CC
# Checks for header files.
-for ac_header in libavformat/avformat.h libavcodec/avcodec.h libavfilter/avfilter.h libavutil/avutil.h libswresample/swresample.h
+ for ac_header in libavformat/avformat.h libavcodec/avcodec.h libavfilter/avfilter.h libavutil/avutil.h libswresample/swresample.h
do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
+ as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
+if eval test \"x\$"$as_ac_Header"\" = x"yes"
+then :
cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+#define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-else
+else $as_nop
as_fn_error $? "unable to find ffmpeg headers" "$LINENO" 5
fi
done
+ac_fn_c_check_header_compile "$LINENO" "fcntl.h" "ac_cv_header_fcntl_h" "$ac_includes_default"
+if test "x$ac_cv_header_fcntl_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_FCNTL_H 1" >>confdefs.h
-for ac_header in fcntl.h limits.h stdint.h stdlib.h string.h sys/ioctl.h sys/time.h termios.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
+fi
+ac_fn_c_check_header_compile "$LINENO" "limits.h" "ac_cv_header_limits_h" "$ac_includes_default"
+if test "x$ac_cv_header_limits_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_LIMITS_H 1" >>confdefs.h
fi
+ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
+if test "x$ac_cv_header_stdint_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
-done
+fi
+ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
+if test "x$ac_cv_header_stdlib_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_STDLIB_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default"
+if test "x$ac_cv_header_string_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRING_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
+if test "x$ac_cv_header_sys_ioctl_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_SYS_IOCTL_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default"
+if test "x$ac_cv_header_sys_time_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "termios.h" "ac_cv_header_termios_h" "$ac_includes_default"
+if test "x$ac_cv_header_termios_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_TERMIOS_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
+if test "x$ac_cv_header_unistd_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
+
+fi
# Check whether --enable-videotoolbox was given.
-if test "${enable_videotoolbox+set}" = set; then :
+if test ${enable_videotoolbox+y}
+then :
enableval=$enable_videotoolbox; case "${enableval}" in
yes) videotoolbox=true ;;
no) videotoolbox=false ;;
*) as_fn_error $? "bad value ${enableval} for --enable-videotoolbox" "$LINENO" 5 ;;
esac
-else
+else $as_nop
videotoolbox=false
fi
@@ -13760,32 +14574,34 @@ fi
# Checks for typedefs, structures, and compiler characteristics.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
-$as_echo_n "checking for inline... " >&6; }
-if ${ac_cv_c_inline+:} false; then :
- $as_echo_n "(cached) " >&6
-else
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
+printf %s "checking for inline... " >&6; }
+if test ${ac_cv_c_inline+y}
+then :
+ printf %s "(cached) " >&6
+else $as_nop
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#ifndef __cplusplus
typedef int foo_t;
-static $ac_kw foo_t static_foo () {return 0; }
-$ac_kw foo_t foo () {return 0; }
+static $ac_kw foo_t static_foo (void) {return 0; }
+$ac_kw foo_t foo (void) {return 0; }
#endif
_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
+if ac_fn_c_try_compile "$LINENO"
+then :
ac_cv_c_inline=$ac_kw
fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
test "$ac_cv_c_inline" != no && break
done
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
-$as_echo "$ac_cv_c_inline" >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
+printf "%s\n" "$ac_cv_c_inline" >&6; }
case $ac_cv_c_inline in
inline | yes) ;;
@@ -13807,9 +14623,7 @@ case $ac_cv_c_int32_t in #(
no|yes) ;; #(
*)
-cat >>confdefs.h <<_ACEOF
-#define int32_t $ac_cv_c_int32_t
-_ACEOF
+printf "%s\n" "#define int32_t $ac_cv_c_int32_t" >>confdefs.h
;;
esac
@@ -13818,9 +14632,7 @@ case $ac_cv_c_int64_t in #(
no|yes) ;; #(
*)
-cat >>confdefs.h <<_ACEOF
-#define int64_t $ac_cv_c_int64_t
-_ACEOF
+printf "%s\n" "#define int64_t $ac_cv_c_int64_t" >>confdefs.h
;;
esac
@@ -13829,20 +14641,17 @@ case $ac_cv_c_int8_t in #(
no|yes) ;; #(
*)
-cat >>confdefs.h <<_ACEOF
-#define int8_t $ac_cv_c_int8_t
-_ACEOF
+printf "%s\n" "#define int8_t $ac_cv_c_int8_t" >>confdefs.h
;;
esac
ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
-if test "x$ac_cv_type_size_t" = xyes; then :
+if test "x$ac_cv_type_size_t" = xyes
+then :
-else
+else $as_nop
-cat >>confdefs.h <<_ACEOF
-#define size_t unsigned int
-_ACEOF
+printf "%s\n" "#define size_t unsigned int" >>confdefs.h
fi
@@ -13852,9 +14661,7 @@ case $ac_cv_c_uint16_t in #(
*)
-cat >>confdefs.h <<_ACEOF
-#define uint16_t $ac_cv_c_uint16_t
-_ACEOF
+printf "%s\n" "#define uint16_t $ac_cv_c_uint16_t" >>confdefs.h
;;
esac
@@ -13863,12 +14670,10 @@ case $ac_cv_c_uint32_t in #(
no|yes) ;; #(
*)
-$as_echo "#define _UINT32_T 1" >>confdefs.h
+printf "%s\n" "#define _UINT32_T 1" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define uint32_t $ac_cv_c_uint32_t
-_ACEOF
+printf "%s\n" "#define uint32_t $ac_cv_c_uint32_t" >>confdefs.h
;;
esac
@@ -13877,12 +14682,10 @@ case $ac_cv_c_uint64_t in #(
no|yes) ;; #(
*)
-$as_echo "#define _UINT64_T 1" >>confdefs.h
+printf "%s\n" "#define _UINT64_T 1" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define uint64_t $ac_cv_c_uint64_t
-_ACEOF
+printf "%s\n" "#define uint64_t $ac_cv_c_uint64_t" >>confdefs.h
;;
esac
@@ -13891,28 +14694,105 @@ case $ac_cv_c_uint8_t in #(
no|yes) ;; #(
*)
-$as_echo "#define _UINT8_T 1" >>confdefs.h
+printf "%s\n" "#define _UINT8_T 1" >>confdefs.h
-cat >>confdefs.h <<_ACEOF
-#define uint8_t $ac_cv_c_uint8_t
-_ACEOF
+printf "%s\n" "#define uint8_t $ac_cv_c_uint8_t" >>confdefs.h
;;
esac
# Checks for library functions.
-for ac_func in dup2 floor memmove memset select strchr strcspn strerror strrchr strstr strtol malloc strcpy strlen vsnprintf
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
+ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2"
+if test "x$ac_cv_func_dup2" = xyes
+then :
+ printf "%s\n" "#define HAVE_DUP2 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "floor" "ac_cv_func_floor"
+if test "x$ac_cv_func_floor" = xyes
+then :
+ printf "%s\n" "#define HAVE_FLOOR 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
+if test "x$ac_cv_func_memmove" = xyes
+then :
+ printf "%s\n" "#define HAVE_MEMMOVE 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset"
+if test "x$ac_cv_func_memset" = xyes
+then :
+ printf "%s\n" "#define HAVE_MEMSET 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "select" "ac_cv_func_select"
+if test "x$ac_cv_func_select" = xyes
+then :
+ printf "%s\n" "#define HAVE_SELECT 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strchr" "ac_cv_func_strchr"
+if test "x$ac_cv_func_strchr" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRCHR 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strcspn" "ac_cv_func_strcspn"
+if test "x$ac_cv_func_strcspn" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRCSPN 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror"
+if test "x$ac_cv_func_strerror" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRERROR 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strrchr" "ac_cv_func_strrchr"
+if test "x$ac_cv_func_strrchr" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRRCHR 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strstr" "ac_cv_func_strstr"
+if test "x$ac_cv_func_strstr" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRSTR 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol"
+if test "x$ac_cv_func_strtol" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRTOL 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "malloc" "ac_cv_func_malloc"
+if test "x$ac_cv_func_malloc" = xyes
+then :
+ printf "%s\n" "#define HAVE_MALLOC 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strcpy" "ac_cv_func_strcpy"
+if test "x$ac_cv_func_strcpy" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRCPY 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "strlen" "ac_cv_func_strlen"
+if test "x$ac_cv_func_strlen" = xyes
+then :
+ printf "%s\n" "#define HAVE_STRLEN 1" >>confdefs.h
+
+fi
+ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
+if test "x$ac_cv_func_vsnprintf" = xyes
+then :
+ printf "%s\n" "#define HAVE_VSNPRINTF 1" >>confdefs.h
fi
-done
ac_config_files="$ac_config_files Makefile src/Makefile"
@@ -13945,8 +14825,8 @@ _ACEOF
case $ac_val in #(
*${as_nl}*)
case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
+ *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
+printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
esac
case $ac_var in #(
_ | IFS | as_nl) ;; #(
@@ -13976,15 +14856,15 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
/^ac_cv_env_/b end
t clear
:clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
+ s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
t end
s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
:end' >>confcache
if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
if test -w "$cache_file"; then
if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
+printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
if test ! -f "$cache_file" || test -h "$cache_file"; then
cat confcache >"$cache_file"
else
@@ -13998,8 +14878,8 @@ $as_echo "$as_me: updating cache $cache_file" >&6;}
fi
fi
else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
+printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
fi
fi
rm -f confcache
@@ -14052,7 +14932,7 @@ U=
for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
# 1. Remove the extension, and $U if already installed.
ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
+ ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
# 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
# will be set to the directory where LIBOBJS objects are built.
as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
@@ -14063,14 +14943,14 @@ LIBOBJS=$ac_libobjs
LTLIBOBJS=$ac_ltlibobjs
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
+printf %s "checking that generated files are newer than configure... " >&6; }
if test -n "$am_sleep_pid"; then
# Hide warnings about reused PIDs.
wait $am_sleep_pid 2>/dev/null
fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5
+printf "%s\n" "done" >&6; }
if test -n "$EXEEXT"; then
am__EXEEXT_TRUE=
am__EXEEXT_FALSE='#'
@@ -14109,8 +14989,8 @@ fi
ac_write_fail=0
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
+printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
as_write_fail=0
cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
#! $SHELL
@@ -14133,14 +15013,16 @@ cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
+as_nop=:
+if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
+then :
emulate sh
NULLCMD=:
# Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
setopt NO_GLOB_SUBST
-else
+else $as_nop
case `(set -o) 2>/dev/null` in #(
*posix*) :
set -o posix ;; #(
@@ -14150,46 +15032,46 @@ esac
fi
+
+# Reset variables that may have inherited troublesome values from
+# the environment.
+
+# IFS needs to be set, to space, tab, and newline, in precisely that order.
+# (If _AS_PATH_WALK were called with IFS unset, it would have the
+# side effect of setting IFS to empty, thus disabling word splitting.)
+# Quoting is to prevent editors from complaining about space-tab.
as_nl='
'
export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
+IFS=" "" $as_nl"
+
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# Ensure predictable behavior from utilities with locale-dependent output.
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
+
+# We cannot yet rely on "unset" to work, but we need these variables
+# to be unset--not just set to an empty or harmless value--now, to
+# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
+# also avoids known problems related to "unset" and subshell syntax
+# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
+for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
+do eval test \${$as_var+y} \
+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
+done
+
+# Ensure that fds 0, 1, and 2 are open.
+if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
+if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
+if ${PATH_SEPARATOR+false} :; then
PATH_SEPARATOR=:
(PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
(PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
@@ -14198,13 +15080,6 @@ if test "${PATH_SEPARATOR+set}" != set; then
fi
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
# Find who we are. Look in the path if we contain no directory separator.
as_myself=
case $0 in #((
@@ -14213,8 +15088,12 @@ case $0 in #((
for as_dir in $PATH
do
IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+ case $as_dir in #(((
+ '') as_dir=./ ;;
+ */) ;;
+ *) as_dir=$as_dir/ ;;
+ esac
+ test -r "$as_dir$0" && as_myself=$as_dir$0 && break
done
IFS=$as_save_IFS
@@ -14226,30 +15105,10 @@ if test "x$as_myself" = x; then
as_myself=$0
fi
if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
exit 1
fi
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
# as_fn_error STATUS ERROR [LINENO LOG_FD]
@@ -14262,13 +15121,14 @@ as_fn_error ()
as_status=$1; test $as_status -eq 0 && as_status=1
if test "$4"; then
as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
fi
- $as_echo "$as_me: error: $2" >&2
+ printf "%s\n" "$as_me: error: $2" >&2
as_fn_exit $as_status
} # as_fn_error
+
# as_fn_set_status STATUS
# -----------------------
# Set $? to STATUS, without forking.
@@ -14295,18 +15155,20 @@ as_fn_unset ()
{ eval $1=; unset $1;}
}
as_unset=as_fn_unset
+
# as_fn_append VAR VALUE
# ----------------------
# Append the text in VALUE to the end of the definition contained in VAR. Take
# advantage of any shell optimizations that allow amortized linear growth over
# repeated appends, instead of the typical quadratic growth present in naive
# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
+then :
eval 'as_fn_append ()
{
eval $1+=\$2
}'
-else
+else $as_nop
as_fn_append ()
{
eval $1=\$$1\$2
@@ -14318,12 +15180,13 @@ fi # as_fn_append
# Perform arithmetic evaluation on the ARGs, and store the result in the
# global $as_val. Take advantage of shells that can avoid forks. The arguments
# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
+then :
eval 'as_fn_arith ()
{
as_val=$(( $* ))
}'
-else
+else $as_nop
as_fn_arith ()
{
as_val=`expr "$@" || test $? -eq 1`
@@ -14354,7 +15217,7 @@ as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
+printf "%s\n" X/"$0" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
@@ -14376,6 +15239,10 @@ as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+# Determine whether it's possible to make 'echo' print without a newline.
+# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
+# for compatibility with existing Makefiles.
ECHO_C= ECHO_N= ECHO_T=
case `echo -n x` in #(((((
-n*)
@@ -14389,6 +15256,12 @@ case `echo -n x` in #(((((
ECHO_N='-n';;
esac
+# For backward compatibility with old third-party macros, we provide
+# the shell variables $as_echo and $as_echo_n. New code should use
+# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
+as_echo='printf %s\n'
+as_echo_n='printf %s'
+
rm -f conf$$ conf$$.exe conf$$.file
if test -d conf$$.dir; then
rm -f conf$$.dir/conf$$.file
@@ -14430,7 +15303,7 @@ as_fn_mkdir_p ()
as_dirs=
while :; do
case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
+ *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
*) as_qdir=$as_dir;;
esac
as_dirs="'$as_qdir' $as_dirs"
@@ -14439,7 +15312,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
+printf "%s\n" X"$as_dir" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -14501,8 +15374,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by ffmpeg-kit $as_me 4.4, which was
-generated by GNU Autoconf 2.69. Invocation command line was
+This file was extended by ffmpeg-kit $as_me 4.5.1, which was
+generated by GNU Autoconf 2.71. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -14555,14 +15428,16 @@ $config_commands
Report bugs to ."
_ACEOF
+ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
+ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
+ac_cs_config='$ac_cs_config_escaped'
ac_cs_version="\\
-ffmpeg-kit config.status 4.4
-configured by $0, generated by GNU Autoconf 2.69,
+ffmpeg-kit config.status 4.5.1
+configured by $0, generated by GNU Autoconf 2.71,
with options \\"\$ac_cs_config\\"
-Copyright (C) 2012 Free Software Foundation, Inc.
+Copyright (C) 2021 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
@@ -14602,21 +15477,21 @@ do
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
ac_cs_recheck=: ;;
--version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
+ printf "%s\n" "$ac_cs_version"; exit ;;
--config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
+ printf "%s\n" "$ac_cs_config"; exit ;;
--debug | --debu | --deb | --de | --d | -d )
debug=: ;;
--file | --fil | --fi | --f )
$ac_shift
case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
'') as_fn_error $? "missing file argument" ;;
esac
as_fn_append CONFIG_FILES " '$ac_optarg'"
ac_need_defaults=false;;
--he | --h | --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
+ printf "%s\n" "$ac_cs_usage"; exit ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil | --si | --s)
ac_cs_silent=: ;;
@@ -14644,7 +15519,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
if \$ac_cs_recheck; then
set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
+ \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
CONFIG_SHELL='$SHELL'
export CONFIG_SHELL
exec "\$@"
@@ -14658,7 +15533,7 @@ exec 5>>config.log
sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
## Running $as_me. ##
_ASBOX
- $as_echo "$ac_log"
+ printf "%s\n" "$ac_log"
} >&5
_ACEOF
@@ -14974,8 +15849,8 @@ done
# We use the long form for the default assignment because of an extremely
# bizarre bug on SunOS 4.1.3.
if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
+ test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
+ test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands
fi
# Have a temporary directory for convenience. Make it in the build tree
@@ -15203,7 +16078,7 @@ do
esac ||
as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
+ case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
as_fn_append ac_file_inputs " '$ac_f'"
done
@@ -15211,17 +16086,17 @@ do
# use $as_me), people would be surprised to read:
# /* config.h. Generated by config.status. */
configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
+ printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
`' by configure.'
if test x"$ac_file" != x-; then
configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
+printf "%s\n" "$as_me: creating $ac_file" >&6;}
fi
# Neutralize special characters interpreted by sed in replacement strings.
case $configure_input in #(
*\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
+ ac_sed_conf_input=`printf "%s\n" "$configure_input" |
sed 's/[\\\\&|]/\\\\&/g'`;; #(
*) ac_sed_conf_input=$configure_input;;
esac
@@ -15238,7 +16113,7 @@ $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$ac_file" : 'X\(//\)[^/]' \| \
X"$ac_file" : 'X\(//\)$' \| \
X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
+printf "%s\n" X"$ac_file" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -15262,9 +16137,9 @@ $as_echo X"$ac_file" |
case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
+ ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
# A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
+ ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
case $ac_top_builddir_sub in
"") ac_top_builddir_sub=. ac_top_build_prefix= ;;
*) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
@@ -15326,8 +16201,8 @@ ac_sed_dataroot='
case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
*datarootdir*) ac_datarootdir_seen=yes;;
*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
+printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_datarootdir_hack='
@@ -15371,9 +16246,9 @@ test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
{ ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
{ ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
"$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&2;}
rm -f "$ac_tmp/stdin"
@@ -15385,8 +16260,8 @@ which seems to be undefined. Please make sure it is defined" >&2;}
;;
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
+ :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
+printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
;;
esac
@@ -15412,7 +16287,7 @@ esac
for am_mf
do
# Strip MF so we end up with the name of the file.
- am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'`
+ am_mf=`printf "%s\n" "$am_mf" | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile which includes
# dependency-tracking related rules and includes.
# Grep'ing the whole file directly is not great: AIX grep has a line
@@ -15424,7 +16299,7 @@ $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$am_mf" : 'X\(//\)[^/]' \| \
X"$am_mf" : 'X\(//\)$' \| \
X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$am_mf" |
+printf "%s\n" X"$am_mf" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -15446,7 +16321,7 @@ $as_echo X"$am_mf" |
$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \
X"$am_mf" : 'X\(//\)$' \| \
X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$am_mf" |
+printf "%s\n" X/"$am_mf" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
@@ -15471,8 +16346,8 @@ $as_echo X/"$am_mf" |
(exit $ac_status); } || am_rc=$?
done
if test $am_rc -ne 0; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "Something went wrong bootstrapping makefile fragments
for automatic dependency tracking. If GNU make was not used, consider
re-running the configure script with MAKE=\"gmake\" (or whatever is
@@ -16016,6 +16891,7 @@ _LT_EOF
esac
+
ltmain=$ac_aux_dir/ltmain.sh
@@ -16065,7 +16941,8 @@ if test "$no_create" != yes; then
$ac_cs_success || as_fn_exit 1
fi
if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
+printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
fi
+
diff --git a/apple/configure.ac b/apple/configure.ac
index 887f243..ae43e5f 100644
--- a/apple/configure.ac
+++ b/apple/configure.ac
@@ -1,8 +1,8 @@
-# ffmpeg-kit 4.4 configure.ac
+# ffmpeg-kit 4.5.1 configure.ac
-AC_INIT([ffmpeg-kit], [4.4], [https://github.com/tanersener/ffmpeg-kit/issues/new])
-AC_CONFIG_SRCDIR([src/FFmpegKit.m])
+AC_INIT([ffmpeg-kit], [4.5.1], [https://github.com/tanersener/ffmpeg-kit/issues/new])
AC_CONFIG_MACRO_DIR([m4])
+AC_CONFIG_SRCDIR([src/FFmpegKit.m])
AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects])
AM_MAINTAINER_MODE
@@ -24,8 +24,8 @@ AM_PROG_AR
AC_PROG_OBJC
CFLAGS="$cflags_bckup"
-FFMPEG_LIBS="-lavcodec -lavfilter -lavformat -lavutil -lswscale -lswresample"
-AC_SUBST(FFMPEG_LIBS)
+FFMPEG_FRAMEWORKS="-framework libavcodec -framework libavfilter -framework libavformat -framework libavutil -framework libswscale -framework libswresample"
+AC_SUBST(FFMPEG_FRAMEWORKS)
LT_INIT
@@ -58,7 +58,6 @@ AC_TYPE_UINT8_T
# Checks for library functions.
AC_CHECK_FUNCS([dup2 floor memmove memset select strchr strcspn strerror strrchr strstr strtol malloc strcpy strlen vsnprintf])
-AC_CONFIG_FILES([Makefile
- src/Makefile])
+AC_CONFIG_FILES([Makefile src/Makefile])
AC_OUTPUT
diff --git a/apple/depcomp b/apple/depcomp
index 6b39162..715e343 100755
--- a/apple/depcomp
+++ b/apple/depcomp
@@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2021 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
diff --git a/apple/libtool b/apple/libtool
index cf02f8c..c9edd28 100755
--- a/apple/libtool
+++ b/apple/libtool
@@ -1,6 +1,6 @@
#! /bin/sh
-# Generated automatically by config.status (ffmpeg-kit) 4.4
-# Libtool was configured on host mera.local:
+# Generated automatically by config.status (ffmpeg-kit) 4.5
+# Libtool was configured on host MiRA.local:
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
# Provide generalized library-building support services.
@@ -42,10 +42,10 @@ macro_version=2.4.6
macro_revision=2.4.6
# Whether or not to build shared libraries.
-build_libtool_libs=no
+build_libtool_libs=yes
# Whether or not to build static libraries.
-build_old_libs=yes
+build_old_libs=no
# What type of objects to build.
pic_mode=yes
@@ -66,14 +66,14 @@ ECHO="printf %s\\n"
PATH_SEPARATOR=":"
# The host system.
-host_alias=x86_64-ios-darwin
-host=x86_64-ios-darwin
+host_alias=arm64-ios-darwin
+host=aarch64-ios-darwin
host_os=darwin
# The build system.
build_alias=
-build=x86_64-apple-darwin18.5.0
-build_os=darwin18.5.0
+build=aarch64-apple-darwin20.6.0
+build_os=darwin20.6.0
# A sed program that does not truncate output.
SED="/usr/bin/sed"
@@ -91,13 +91,13 @@ EGREP="/usr/bin/grep -E"
FGREP="/usr/bin/grep -F"
# A BSD- or MS-compatible name lister.
-NM="nm"
+NM="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/nm"
# Whether we need soft or hard links.
LN_S="ln -s"
# What is the maximum length of a command?
-max_cmd_len=196608
+max_cmd_len=786432
# Object file suffix (normally "o").
objext=o
@@ -136,25 +136,25 @@ file_magic_glob=""
want_nocaseglob="no"
# DLL creation program.
-DLLTOOL="dlltool"
+DLLTOOL="false"
# Command to associate shared and link libraries.
sharedlib_from_linklib_cmd="printf %s\\n"
# The archiver.
-AR="ar"
+AR="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar"
# Flags to create an archive.
AR_FLAGS="cru"
# How to feed a file listing to the archiver.
-archiver_list_spec="@"
+archiver_list_spec=""
# A symbol stripping program.
-STRIP="strip"
+STRIP="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip"
# Commands used to install an old-style archive.
-RANLIB="ranlib"
+RANLIB="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib"
old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$tool_oldlib"
old_postuninstall_cmds=""
@@ -165,22 +165,22 @@ lock_old_archive_extraction=yes
LTCC="clang"
# LTCC compiler flags.
-LTCFLAGS="-arch x86_64 -target x86_64-ios-darwin -march=x86-64 -msse4.2 -mpopcnt -m64 -mtune=intel -DFFMPEG_KIT_X86_64 -std=c99 -Wno-unused-function -Wall -Wno-deprecated-declarations -Wno-pointer-sign -Wno-switch -Wno-unused-result -Wno-unused-variable -DPIC -fobjc-arc -fstrict-aliasing -DIOS -DFFMPEG_KIT_BUILD_DATE=20190403 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.2.sdk -O2 -Wno-ignored-optimization-argument -mios-simulator-version-min=12.1 -I/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.2.sdk/usr/include -I/Users/taner/Projects/ffmpeg-kit/prebuilt/ios-x86_64-ios-darwin/ffmpeg/include"
+LTCFLAGS="-arch arm64 -target arm64-apple-ios12.1 -march=armv8-a+crc+crypto -mcpu=generic -DFFMPEG_KIT_ARM64 -std=c99 -Wno-unused-function -Wall -Wno-deprecated-declarations -Wno-pointer-sign -Wno-switch -Wno-unused-result -Wno-unused-variable -DPIC -fobjc-arc -fstrict-aliasing -fembed-bitcode -DIOS -DFFMPEG_KIT_BUILD_DATE=20211024 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk -Oz -Wno-ignored-optimization-argument -miphoneos-version-min=12.1 -I/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk/usr/include -I/Users/taner/Projects/ffmpeg-kit/prebuilt/apple-ios-arm64/ffmpeg/include"
# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*_\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 _\\2 \\2/p' | sed '/ __gnu_lto/d'"
+global_symbol_pipe="sed -n -e 's/^.*[ ]\\([BCDEGRST][BCDEGRST]*\\)[ ][ ]*_\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 _\\2 \\2/p' | sed '/ __gnu_lto/d'"
# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl="sed -n -e 's/^T .* \\(.*\\)\$/extern int \\1();/p' -e 's/^[ABCDGIRSTW][ABCDGIRSTW]* .* \\(.*\\)\$/extern char \\1;/p'"
+global_symbol_to_cdecl="sed -n -e 's/^T .* \\(.*\\)\$/extern int \\1();/p' -e 's/^[BCDEGRST][BCDEGRST]* .* \\(.*\\)\$/extern char \\1;/p'"
# Transform the output of nm into a list of symbols to manually relocate.
global_symbol_to_import=""
# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address="sed -n -e 's/^: \\(.*\\) .*\$/ {\"\\1\", (void *) 0},/p' -e 's/^[ABCDGIRSTW][ABCDGIRSTW]* .* \\(.*\\)\$/ {\"\\1\", (void *) \\&\\1},/p'"
+global_symbol_to_c_name_address="sed -n -e 's/^: \\(.*\\) .*\$/ {\"\\1\", (void *) 0},/p' -e 's/^[BCDEGRST][BCDEGRST]* .* \\(.*\\)\$/ {\"\\1\", (void *) \\&\\1},/p'"
# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \\(.*\\) .*\$/ {\"\\1\", (void *) 0},/p' -e 's/^[ABCDGIRSTW][ABCDGIRSTW]* .* \\(lib.*\\)\$/ {\"\\1\", (void *) \\&\\1},/p' -e 's/^[ABCDGIRSTW][ABCDGIRSTW]* .* \\(.*\\)\$/ {\"lib\\1\", (void *) \\&\\1},/p'"
+global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \\(.*\\) .*\$/ {\"\\1\", (void *) 0},/p' -e 's/^[BCDEGRST][BCDEGRST]* .* \\(lib.*\\)\$/ {\"\\1\", (void *) \\&\\1},/p' -e 's/^[BCDEGRST][BCDEGRST]* .* \\(.*\\)\$/ {\"lib\\1\", (void *) \\&\\1},/p'"
# The name lister interface.
nm_interface="BSD nm"
@@ -189,7 +189,7 @@ nm_interface="BSD nm"
nm_file_list_spec="@"
# The root where to search for dependent libraries,and where our libraries should be installed.
-lt_sysroot=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.2.sdk
+lt_sysroot=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk
# Command to truncate a binary pipe.
lt_truncate_bin="/bin/dd bs=4096 count=1"
@@ -213,7 +213,7 @@ DSYMUTIL="dsymutil"
NMEDIT="nmedit"
# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo"
+LIPO="lipo"
# ldd/readelf like tool for Mach-O binaries on Mac OS X.
OTOOL="otool"
@@ -282,7 +282,7 @@ finish_eval=""
hardcode_into_libs=no
# Compile-time system search path for libraries.
-sys_lib_search_path_spec="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/10.0.1 /usr/local/lib"
+sys_lib_search_path_spec="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/13.0.0 /usr/local/lib"
# Detected run-time system search path for libraries.
sys_lib_dlsearch_path_spec="/usr/local/lib /lib /usr/lib"
@@ -300,12 +300,12 @@ dlopen_self=unknown
dlopen_self_static=unknown
# Commands to strip libraries.
-old_striplib="strip --strip-debug"
-striplib="strip --strip-unneeded"
+old_striplib="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip -S"
+striplib="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip -x"
# The linker used to build libraries.
-LD="ld"
+LD="/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld"
# How to create reloadable object files.
reload_flag=" -r"
@@ -345,7 +345,7 @@ allow_libtool_libs_with_static_runtimes=no
export_dynamic_flag_spec=""
# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=""
+whole_archive_flag_spec="\`for conv in \$convenience\\\"\\\"; do test -n \\\"\$conv\\\" && new_convenience=\\\"\$new_convenience \$wl-force_load,\$conv\\\"; done; func_echo_all \\\"\$new_convenience\\\"\`"
# Whether the compiler copes with passing no objects directly.
compiler_needs_object="no"
@@ -357,19 +357,19 @@ old_archive_from_new_cmds=""
old_archive_from_expsyms_cmds=""
# Commands used to build a shared archive.
-archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring \$single_module~\$DSYMUTIL \$lib || :"
-archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring \$single_module \$wl-exported_symbols_list,\$output_objdir/\$libname-symbols.expsym~\$DSYMUTIL \$lib || :"
+archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring \$single_module"
+archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring \$single_module \$wl-exported_symbols_list,\$output_objdir/\$libname-symbols.expsym"
# Commands used to build a loadable module if different from building
# a shared archive.
-module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags~\$DSYMUTIL \$lib || :"
-module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags \$wl-exported_symbols_list,\$output_objdir/\$libname-symbols.expsym~\$DSYMUTIL \$lib || :"
+module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags"
+module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags \$wl-exported_symbols_list,\$output_objdir/\$libname-symbols.expsym"
# Whether we are building with GNU ld or not.
with_gnu_ld="no"
# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=""
+allow_undefined_flag="\$wl-undefined \${wl}dynamic_lookup"
# Flag that enforces no undefined symbols.
no_undefined_flag=""
diff --git a/apple/missing b/apple/missing
index 8d0eaad..1fe1611 100755
--- a/apple/missing
+++ b/apple/missing
@@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2021 Free Software Foundation, Inc.
# Originally written by Fran,cois Pinard , 1996.
# This program is free software; you can redistribute it and/or modify
diff --git a/apple/src/AbstractSession.h b/apple/src/AbstractSession.h
index 31dfc9a..e44ea5e 100644
--- a/apple/src/AbstractSession.h
+++ b/apple/src/AbstractSession.h
@@ -29,8 +29,8 @@
extern int const AbstractSessionDefaultTimeoutForAsynchronousMessagesInTransmit;
/**
- * Abstract session implementation which includes common features shared by FFmpeg
- * and FFprobe
sessions.
+ * Abstract session implementation which includes common features shared by FFmpeg
,
+ * FFprobe
and MediaInformation
sessions.
*/
@interface AbstractSession : NSObject
@@ -38,11 +38,10 @@ extern int const AbstractSessionDefaultTimeoutForAsynchronousMessagesInTransmit;
* Creates a new abstract session.
*
* @param arguments command arguments
- * @param executeCallback session specific execute callback
* @param logCallback session specific log callback
* @param logRedirectionStrategy session specific log redirection strategy
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
+- (instancetype)init:(NSArray*)arguments withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
/**
* Waits for all asynchronous messages to be transmitted until the given timeout.
diff --git a/apple/src/AbstractSession.m b/apple/src/AbstractSession.m
index b60d813..f2e40ac 100644
--- a/apple/src/AbstractSession.m
+++ b/apple/src/AbstractSession.m
@@ -19,7 +19,6 @@
#import "AbstractSession.h"
#import "AtomicLong.h"
-#import "ExecuteCallback.h"
#import "FFmpegKit.h"
#import "FFmpegKitConfig.h"
#import "LogCallback.h"
@@ -33,7 +32,6 @@ extern void addSessionToSessionHistory(id session);
@implementation AbstractSession {
long _sessionId;
- ExecuteCallback _executeCallback;
LogCallback _logCallback;
NSDate* _createTime;
NSDate* _startTime;
@@ -51,11 +49,10 @@ extern void addSessionToSessionHistory(id session);
sessionIdGenerator = [[AtomicLong alloc] initWithValue:1];
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
+- (instancetype)init:(NSArray*)arguments withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
self = [super init];
if (self) {
_sessionId = [sessionIdGenerator getAndIncrement];
- _executeCallback = executeCallback;
_logCallback = logCallback;
_createTime = [NSDate date];
_startTime = nil;
@@ -74,10 +71,6 @@ extern void addSessionToSessionHistory(id session);
return self;
}
-- (ExecuteCallback)getExecuteCallback {
- return _executeCallback;
-}
-
- (LogCallback)getLogCallback {
return _logCallback;
}
@@ -230,6 +223,11 @@ extern void addSessionToSessionHistory(id session);
return false;
}
+- (BOOL)isMediaInformation {
+ // IMPLEMENTED IN SUBCLASSES
+ return false;
+}
+
- (void)cancel {
if (_state == SessionStateRunning) {
[FFmpegKit cancel:_sessionId];
diff --git a/apple/src/Chapter.h b/apple/src/Chapter.h
new file mode 100644
index 0000000..f85e2b7
--- /dev/null
+++ b/apple/src/Chapter.h
@@ -0,0 +1,84 @@
+/*
+ * Copyright (c) 2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+#ifndef FFMPEG_KIT_CHAPTER_H
+#define FFMPEG_KIT_CHAPTER_H
+
+#import
+
+extern NSString* const ChapterKeyId;
+extern NSString* const ChapterKeyTimeBase;
+extern NSString* const ChapterKeyStart;
+extern NSString* const ChapterKeyStartTime;
+extern NSString* const ChapterKeyEnd;
+extern NSString* const ChapterKeyEndTime;
+extern NSString* const ChapterKeyTags;
+
+/**
+ * Chapter class.
+ */
+@interface Chapter : NSObject
+
+- (instancetype)init:(NSDictionary*)chapterDictionary;
+
+- (NSNumber*)getId;
+
+- (NSString*)getTimeBase;
+
+- (NSNumber*)getStart;
+
+- (NSString*)getStartTime;
+
+- (NSNumber*)getEnd;
+
+- (NSString*)getEndTime;
+
+- (NSDictionary*)getTags;
+
+/**
+ * Returns the chapter property associated with the key.
+ *
+ * @return chapter property as string or nil if the key is not found
+ */
+- (NSString*)getStringProperty:(NSString*)key;
+
+/**
+ * Returns the chapter property associated with the key.
+ *
+ * @return chapter property as number or nil if the key is not found
+ */
+- (NSNumber*)getNumberProperty:(NSString*)key;
+
+/**
+ * Returns the chapter properties associated with the key.
+ *
+ * @return chapter properties in a dictionary or nil if the key is not found
+*/
+- (NSDictionary*)getProperties:(NSString*)key;
+
+/**
+ * Returns all chapter properties defined.
+ *
+ * @return all chapter properties in a dictionary or nil if no properties are defined
+*/
+- (NSDictionary*)getAllProperties;
+
+@end
+
+#endif // FFMPEG_KIT_CHAPTER_H
diff --git a/apple/src/Chapter.m b/apple/src/Chapter.m
new file mode 100644
index 0000000..30baf06
--- /dev/null
+++ b/apple/src/Chapter.m
@@ -0,0 +1,107 @@
+/*
+ * Copyright (c) 2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+#import "Chapter.h"
+
+NSString* const ChapterKeyId = @"id";
+NSString* const ChapterKeyTimeBase = @"time_base";
+NSString* const ChapterKeyStart = @"start";
+NSString* const ChapterKeyStartTime = @"start_time";
+NSString* const ChapterKeyEnd = @"end";
+NSString* const ChapterKeyEndTime = @"end_time";
+NSString* const ChapterKeyTags = @"tags";
+
+@implementation Chapter {
+
+ /**
+ * Stores all properties.
+ */
+ NSDictionary *dictionary;
+
+}
+
+- (instancetype)init:(NSDictionary*)chapterDictionary {
+ self = [super init];
+ if (self) {
+ dictionary = chapterDictionary;
+ }
+
+ return self;
+}
+
+- (NSNumber*)getId {
+ return [self getNumberProperty:ChapterKeyId];
+}
+
+- (NSString*)getTimeBase {
+ return [self getStringProperty:ChapterKeyTimeBase];
+}
+
+- (NSNumber*)getStart {
+ return [self getNumberProperty:ChapterKeyStart];
+}
+
+- (NSString*)getStartTime {
+ return [self getStringProperty:ChapterKeyStartTime];
+}
+
+- (NSNumber*)getEnd {
+ return [self getNumberProperty:ChapterKeyEnd];
+}
+
+- (NSString*)getEndTime {
+ return [self getStringProperty:ChapterKeyEndTime];
+}
+
+- (NSDictionary*)getTags {
+ return [self getProperties:ChapterKeyTags];
+}
+
+- (NSString*)getStringProperty:(NSString*)key {
+ NSDictionary* allProperties = [self getAllProperties];
+ if (allProperties == nil) {
+ return nil;
+ }
+
+ return allProperties[key];
+}
+
+- (NSNumber*)getNumberProperty:(NSString*)key {
+ NSDictionary* mediaProperties = [self getAllProperties];
+ if (mediaProperties == nil) {
+ return nil;
+ }
+
+ return mediaProperties[key];
+}
+
+- (NSDictionary*)getProperties:(NSString*)key {
+ NSDictionary* allProperties = [self getAllProperties];
+ if (allProperties == nil) {
+ return nil;
+ }
+
+ return allProperties[key];
+}
+
+- (NSDictionary*)getAllProperties {
+ return dictionary;
+}
+
+@end
diff --git a/apple/src/FFmpegKit.h b/apple/src/FFmpegKit.h
index bcf8c85..9ae4993 100644
--- a/apple/src/FFmpegKit.h
+++ b/apple/src/FFmpegKit.h
@@ -23,7 +23,6 @@
#import
#import
#import
-#import "ExecuteCallback.h"
#import "LogCallback.h"
#import "FFmpegSession.h"
#import "StatisticsCallback.h"
@@ -34,11 +33,11 @@
*
* FFmpegSession *session = [FFmpegKit execute:@"-i file1.mp4 -c:v libxvid file1.avi"];
*
- * FFmpegSession *asyncSession = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v libxvid file1.avi" withExecuteCallback:executeCallback];
+ * FFmpegSession *asyncSession = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v libxvid file1.avi" withCompleteCallback:completeCallback];
*
* Provides overloaded execute
methods to define session specific callbacks.
*
- * FFmpegSession *asyncSession = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v libxvid file1.avi" withExecuteCallback:executeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
+ * FFmpegSession *asyncSession = [FFmpegKit executeAsync:@"-i file1.mp4 -c:v libxvid file1.avi" withCompleteCallback:completeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
*
*/
@interface FFmpegKit : NSObject
@@ -54,56 +53,56 @@
/**
* Starts an asynchronous FFmpeg execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFmpeg command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
+ * @param arguments FFmpeg command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback;
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback;
/**
*
Starts an asynchronous FFmpeg execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFmpeg command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param statisticsCallback callback that will receive statistics
+ * @param arguments FFmpeg command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param statisticsCallback callback that will receive statistics
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
/**
*
Starts an asynchronous FFmpeg execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFmpeg command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param arguments FFmpeg command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Starts an asynchronous FFmpeg execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFmpeg command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param statisticsCallback callback that will receive statistics
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param arguments FFmpeg command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param statisticsCallback callback that will receive statistics
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Synchronously executes FFmpeg command provided. Space character is used to split command
@@ -120,70 +119,70 @@
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFmpeg command
- * @param executeCallback callback that will be called when the execution is completed
+ * @param command FFmpeg command
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback;
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback;
/**
*
Starts an asynchronous FFmpeg execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFmpeg command
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param statisticsCallback callback that will receive statistics
+ * @param command FFmpeg command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param statisticsCallback callback that will receive statistics
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
/**
*
Starts an asynchronous FFmpeg execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFmpeg command
- * @param executeCallback callback that will be called when the execution is completed
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param command FFmpeg command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Starts an asynchronous FFmpeg execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFmpegSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFmpeg command
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param statisticsCallback callback that will receive statistics
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param command FFmpeg command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param statisticsCallback callback that will receive statistics
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFmpeg session created for this execution
*/
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Cancels all running sessions.
*
- *
This function does not wait for termination to complete and returns immediately.
+ *
This method does not wait for termination to complete and returns immediately.
*/
+ (void)cancel;
/**
*
Cancels the session specified with sessionId
.
*
- *
This function does not wait for termination to complete and returns immediately.
+ *
This method does not wait for termination to complete and returns immediately.
*
* @param sessionId id of the session that will be cancelled
*/
diff --git a/apple/src/FFmpegKit.m b/apple/src/FFmpegKit.m
index 9c082c8..562c0af 100644
--- a/apple/src/FFmpegKit.m
+++ b/apple/src/FFmpegKit.m
@@ -40,26 +40,26 @@
return session;
}
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback {
- FFmpegSession* session = [[FFmpegSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback {
+ FFmpegSession* session = [[FFmpegSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFmpegExecute:session];
return session;
}
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
- FFmpegSession* session = [[FFmpegSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
+ FFmpegSession* session = [[FFmpegSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
[FFmpegKitConfig asyncFFmpegExecute:session];
return session;
}
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFmpegSession* session = [[FFmpegSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFmpegSession* session = [[FFmpegSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFmpegExecute:session onDispatchQueue:queue];
return session;
}
-+ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFmpegSession* session = [[FFmpegSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
++ (FFmpegSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFmpegSession* session = [[FFmpegSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
[FFmpegKitConfig asyncFFmpegExecute:session onDispatchQueue:queue];
return session;
}
@@ -70,26 +70,26 @@
return session;
}
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback {
- FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback];
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback {
+ FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFmpegExecute:session];
return session;
}
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
- FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
+ FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
[FFmpegKitConfig asyncFFmpegExecute:session];
return session;
}
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback];
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFmpegExecute:session onDispatchQueue:queue];
return session;
}
-+ (FFmpegSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
++ (FFmpegSession*)executeAsync:(NSString*)command withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFmpegSession* session = [[FFmpegSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback withLogCallback:logCallback withStatisticsCallback:statisticsCallback];
[FFmpegKitConfig asyncFFmpegExecute:session onDispatchQueue:queue];
return session;
}
diff --git a/apple/src/FFmpegKitConfig.h b/apple/src/FFmpegKitConfig.h
index 59ddb62..acfad88 100644
--- a/apple/src/FFmpegKitConfig.h
+++ b/apple/src/FFmpegKitConfig.h
@@ -24,7 +24,6 @@
#import
#import
#import
-#import "ExecuteCallback.h"
#import "FFmpegSession.h"
#import "FFprobeSession.h"
#import "LogCallback.h"
@@ -191,8 +190,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
* Starts an asynchronous FFmpeg execution for the given session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
* @param ffmpegSession FFmpeg session which includes command options/arguments
*/
@@ -201,8 +200,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
*
Starts an asynchronous FFmpeg execution for the given session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
*
* @param ffmpegSession FFmpeg session which includes command options/arguments
* @param queue dispatch queue that will be used to run this asynchronous operation
@@ -212,8 +211,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
*
Starts an asynchronous FFprobe execution for the given session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
* @param ffprobeSession FFprobe session which includes command options/arguments
*/
@@ -222,8 +221,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
*
Starts an asynchronous FFprobe execution for the given session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
* @param ffprobeSession FFprobe session which includes command options/arguments
* @param queue dispatch queue that will be used to run this asynchronous operation
@@ -233,8 +232,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
*
Starts an asynchronous FFprobe execution for the given media information session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
* @param mediaInformationSession media information session which includes command options/arguments
* @param waitTimeout max time to wait until media information is transmitted
@@ -244,8 +243,8 @@ typedef NS_ENUM(NSUInteger, Signal) {
/**
*
Starts an asynchronous FFprobe execution for the given media information session.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
* @param mediaInformationSession media information session which includes command options/arguments
* @param queue dispatch queue that will be used to run this asynchronous operation
@@ -268,18 +267,47 @@ typedef NS_ENUM(NSUInteger, Signal) {
+ (void)enableStatisticsCallback:(StatisticsCallback)statisticsCallback;
/**
- *
Sets a global execute callback to receive execution results.
+ *
Sets a global FFmpegSessionCompleteCallback to receive execution results for FFmpeg sessions.
*
- * @param executeCallback execute callback or nil to disable a previously execute callback
+ * @param ffmpegSessionCompleteCallback complete callback or nil to disable a previously defined callback
*/
-+ (void)enableExecuteCallback:(ExecuteCallback)executeCallback;
++ (void)enableFFmpegSessionCompleteCallback:(FFmpegSessionCompleteCallback)ffmpegSessionCompleteCallback;
/**
- *
Returns the global execute callback.
+ *
Returns the global FFmpegSessionCompleteCallback set.
*
- * @return global execute callback
+ * @return global FFmpegSessionCompleteCallback or nil if it is not set
*/
-+ (ExecuteCallback)getExecuteCallback;
++ (FFmpegSessionCompleteCallback)getFFmpegSessionCompleteCallback;
+
+/**
+ *
Sets a global FFprobeSessionCompleteCallback to receive execution results for FFprobe sessions.
+ *
+ * @param ffprobeSessionCompleteCallback complete callback or nil to disable a previously defined callback
+ */
++ (void)enableFFprobeSessionCompleteCallback:(FFprobeSessionCompleteCallback)ffprobeSessionCompleteCallback;
+
+/**
+ *
Returns the global FFprobeSessionCompleteCallback set.
+ *
+ * @return global FFprobeSessionCompleteCallback or nil if it is not set
+ */
++ (FFprobeSessionCompleteCallback)getFFprobeSessionCompleteCallback;
+
+/**
+ *
Sets a global MediaInformationSessionCompleteCallback to receive execution results for MediaInformation sessions.
+ *
+ * @param mediaInformationSessionCompleteCallback complete callback or nil to disable a previously defined
+ * callback
+ */
++ (void)enableMediaInformationSessionCompleteCallback:(MediaInformationSessionCompleteCallback)mediaInformationSessionCompleteCallback;
+
+/**
+ *
Returns the global MediaInformationSessionCompleteCallback set.
+ *
+ * @return global MediaInformationSessionCompleteCallback or nil if it is not set
+ */
++ (MediaInformationSessionCompleteCallback)getMediaInformationSessionCompleteCallback;
/**
* Returns the current log level.
@@ -367,6 +395,13 @@ typedef NS_ENUM(NSUInteger, Signal) {
*/
+ (NSArray*)getFFprobeSessions;
+/**
+ *
Returns all MediaInformation sessions in the session history.
+ *
+ * @return all MediaInformation sessions in the session history
+ */
++ (NSArray*)getMediaInformationSessions;
+
/**
*
Returns sessions that have the given state.
*
diff --git a/apple/src/FFmpegKitConfig.m b/apple/src/FFmpegKitConfig.m
index b1ecd9c..a9f4296 100644
--- a/apple/src/FFmpegKitConfig.m
+++ b/apple/src/FFmpegKitConfig.m
@@ -21,6 +21,7 @@
#import
#import
#import "libavutil/ffversion.h"
+#import "libavutil/bprint.h"
#import "fftools_ffmpeg.h"
#import "ArchDetect.h"
#import "AtomicLong.h"
@@ -35,7 +36,7 @@
#import "SessionState.h"
/** Global library version */
-NSString* const FFmpegKitVersion = @"4.5";
+NSString* const FFmpegKitVersion = @"4.5.1";
/**
* Prefix of named pipes created by ffmpeg-kit.
@@ -66,8 +67,10 @@ static LogCallback logCallback;
/** Holds callback defined to redirect statistics */
static StatisticsCallback statisticsCallback;
-/** Holds callback defined to redirect asynchronous execution results */
-static ExecuteCallback executeCallback;
+/** Holds complete callbacks defined to redirect asynchronous execution results */
+static FFmpegSessionCompleteCallback ffmpegSessionCompleteCallback;
+static FFprobeSessionCompleteCallback ffprobeSessionCompleteCallback;
+static MediaInformationSessionCompleteCallback mediaInformationSessionCompleteCallback;
static LogRedirectionStrategy globalLogRedirectionStrategy;
@@ -138,7 +141,7 @@ void addSessionToSessionHistory(id session) {
long _sessionId; // session id
int _logLevel; // log level
- NSString* _logData; // log data
+ AVBPrint _logData; // log data
int _statisticsFrameNumber; // statistics frame number
float _statisticsFps; // statistics fps
@@ -149,13 +152,14 @@ void addSessionToSessionHistory(id session) {
double _statisticsSpeed; // statistics speed
}
- - (instancetype)init:(long)sessionId logLevel:(int)logLevel data:(NSString*)logData {
+ - (instancetype)init:(long)sessionId logLevel:(int)logLevel data:(AVBPrint*)data {
self = [super init];
if (self) {
_type = LogType;
_sessionId = sessionId;
_logLevel = logLevel;
- _logData = logData;
+ av_bprint_init(&_logData, 0, AV_BPRINT_SIZE_UNLIMITED);
+ av_bprintf(&_logData, "%s", data->str);
}
return self;
@@ -197,8 +201,8 @@ void addSessionToSessionHistory(id session) {
return _logLevel;
}
-- (NSString*)getLogData {
- return _logData;
+- (AVBPrint*)getLogData {
+ return &_logData;
}
- (int)getStatisticsFrameNumber {
@@ -247,15 +251,80 @@ void callbackNotify() {
dispatch_semaphore_signal(semaphore);
}
+static const char *avutil_log_get_level_str(int level) {
+ switch (level) {
+ case AV_LOG_STDERR:
+ return "stderr";
+ case AV_LOG_QUIET:
+ return "quiet";
+ case AV_LOG_DEBUG:
+ return "debug";
+ case AV_LOG_VERBOSE:
+ return "verbose";
+ case AV_LOG_INFO:
+ return "info";
+ case AV_LOG_WARNING:
+ return "warning";
+ case AV_LOG_ERROR:
+ return "error";
+ case AV_LOG_FATAL:
+ return "fatal";
+ case AV_LOG_PANIC:
+ return "panic";
+ default:
+ return "";
+ }
+}
+
+static void avutil_log_format_line(void *avcl, int level, const char *fmt, va_list vl, AVBPrint part[4], int *print_prefix) {
+ int flags = av_log_get_flags();
+ AVClass* avc = avcl ? *(AVClass **) avcl : NULL;
+ av_bprint_init(part+0, 0, 1);
+ av_bprint_init(part+1, 0, 1);
+ av_bprint_init(part+2, 0, 1);
+ av_bprint_init(part+3, 0, 65536);
+
+ if (*print_prefix && avc) {
+ if (avc->parent_log_context_offset) {
+ AVClass** parent = *(AVClass ***) (((uint8_t *) avcl) +
+ avc->parent_log_context_offset);
+ if (parent && *parent) {
+ av_bprintf(part+0, "[%s @ %p] ",
+ (*parent)->item_name(parent), parent);
+ }
+ }
+ av_bprintf(part+1, "[%s @ %p] ",
+ avc->item_name(avcl), avcl);
+ }
+
+ if (*print_prefix && (level > AV_LOG_QUIET) && (flags & AV_LOG_PRINT_LEVEL))
+ av_bprintf(part+2, "[%s] ", avutil_log_get_level_str(level));
+
+ av_vbprintf(part+3, fmt, vl);
+
+ if(*part[0].str || *part[1].str || *part[2].str || *part[3].str) {
+ char lastc = part[3].len && part[3].len <= part[3].size ? part[3].str[part[3].len - 1] : 0;
+ *print_prefix = lastc == '\n' || lastc == '\r';
+ }
+}
+
+static void avutil_log_sanitize(uint8_t *line) {
+ while(*line){
+ if(*line < 0x08 || (*line > 0x0D && *line < 0x20))
+ *line='?';
+ line++;
+ }
+}
+
/**
* Adds log data to the end of callback data list.
*
* @param level log level
- * @param logData log data
+ * @param data log data
*/
-void logCallbackDataAdd(int level, NSString *logData) {
- CallbackData* callbackData = [[CallbackData alloc] init:globalSessionId logLevel:level data:logData];
-
+void logCallbackDataAdd(int level, AVBPrint *data) {
+ CallbackData* callbackData = [[CallbackData alloc] init:globalSessionId logLevel:level data:data];
+
[lock lock];
[callbackDataArray addObject:callbackData];
[lock unlock];
@@ -361,6 +430,9 @@ void resetMessagesInTransmit(long sessionId) {
* @param vargs arguments
*/
void ffmpegkit_log_callback_function(void *ptr, int level, const char* format, va_list vargs) {
+ AVBPrint fullLine;
+ AVBPrint part[4];
+ int print_prefix = 1;
// DO NOT PROCESS UNWANTED LOGS
if (level >= 0) {
@@ -373,11 +445,26 @@ void ffmpegkit_log_callback_function(void *ptr, int level, const char* format, v
return;
}
- NSString *logData = [[NSString alloc] initWithFormat:[NSString stringWithCString:format encoding:NSUTF8StringEncoding] arguments:vargs];
+ av_bprint_init(&fullLine, 0, AV_BPRINT_SIZE_UNLIMITED);
+
+ avutil_log_format_line(ptr, level, format, vargs, part, &print_prefix);
+ avutil_log_sanitize(part[0].str);
+ avutil_log_sanitize(part[1].str);
+ avutil_log_sanitize(part[2].str);
+ avutil_log_sanitize(part[3].str);
+
+ // COMBINE ALL 4 LOG PARTS
+ av_bprintf(&fullLine, "%s%s%s%s", part[0].str, part[1].str, part[2].str, part[3].str);
- if (logData.length > 0) {
- logCallbackDataAdd(level, logData);
+ if (fullLine.len > 0) {
+ logCallbackDataAdd(level, &fullLine);
}
+
+ av_bprint_finalize(part, NULL);
+ av_bprint_finalize(part+1, NULL);
+ av_bprint_finalize(part+2, NULL);
+ av_bprint_finalize(part+3, NULL);
+ av_bprint_finalize(&fullLine, NULL);
}
/**
@@ -395,9 +482,9 @@ void ffmpegkit_statistics_callback_function(int frameNumber, float fps, float qu
statisticsCallbackDataAdd(frameNumber, fps, quality, size, time, bitrate, speed);
}
-void process_log(long sessionId, int levelValue, NSString* logMessage) {
+void process_log(long sessionId, int levelValue, AVBPrint* logMessage) {
int activeLogLevel = av_log_get_level();
- Log* log = [[Log alloc] init:sessionId:levelValue:logMessage];
+ Log* log = [[Log alloc] init:sessionId:levelValue:[NSString stringWithCString:logMessage->str encoding:NSUTF8StringEncoding]];
BOOL globalCallbackDefined = false;
BOOL sessionCallbackDefined = false;
LogRedirectionStrategy activeLogRedirectionStrategy = globalLogRedirectionStrategy;
@@ -422,7 +509,7 @@ void process_log(long sessionId, int levelValue, NSString* logMessage) {
sessionLogCallback(log);
}
@catch(NSException* exception) {
- NSLog(@"Exception thrown inside session LogCallback block. %@", [exception callStackSymbols]);
+ NSLog(@"Exception thrown inside session log callback. %@", [exception callStackSymbols]);
}
}
}
@@ -436,7 +523,7 @@ void process_log(long sessionId, int levelValue, NSString* logMessage) {
globalLogCallback(log);
}
@catch(NSException* exception) {
- NSLog(@"Exception thrown inside global LogCallback block. %@", [exception callStackSymbols]);
+ NSLog(@"Exception thrown inside global log callback. %@", [exception callStackSymbols]);
}
}
@@ -456,13 +543,16 @@ void process_log(long sessionId, int levelValue, NSString* logMessage) {
return;
}
}
+ break;
case LogRedirectionStrategyPrintLogsWhenNoCallbacksDefined: {
if (globalCallbackDefined || sessionCallbackDefined) {
return;
}
}
+ break;
case LogRedirectionStrategyAlwaysPrintLogs: {
}
+ break;
}
// PRINT LOGS
@@ -472,7 +562,7 @@ void process_log(long sessionId, int levelValue, NSString* logMessage) {
break;
default:
// WRITE TO NSLOG
- NSLog(@"%@: %@", [FFmpegKitConfig logLevelToString:levelValue], logMessage);
+ NSLog(@"%@: %@", [FFmpegKitConfig logLevelToString:levelValue], [NSString stringWithCString:logMessage->str encoding:NSUTF8StringEncoding]);
break;
}
}
@@ -492,7 +582,7 @@ void process_statistics(long sessionId, int videoFrameNumber, float videoFps, fl
sessionStatisticsCallback(statistics);
}
@catch(NSException* exception) {
- NSLog(@"Exception thrown inside session StatisticsCallback block. %@", [exception callStackSymbols]);
+ NSLog(@"Exception thrown inside session statistics callback. %@", [exception callStackSymbols]);
}
}
}
@@ -503,7 +593,7 @@ void process_statistics(long sessionId, int videoFrameNumber, float videoFps, fl
globalStatisticsCallback(statistics);
}
@catch(NSException* exception) {
- NSLog(@"Exception thrown inside global StatisticsCallback block. %@", [exception callStackSymbols]);
+ NSLog(@"Exception thrown inside global statistics callback. %@", [exception callStackSymbols]);
}
}
}
@@ -526,6 +616,7 @@ void callbackBlockFunction() {
if ([callbackData getType] == LogType) {
process_log([callbackData getSessionId], [callbackData getLogLevel], [callbackData getLogData]);
+ av_bprint_finalize([callbackData getLogData], NULL);
} else {
process_statistics([callbackData getSessionId],
[callbackData getStatisticsFrameNumber],
@@ -662,7 +753,9 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
logCallback = nil;
statisticsCallback = nil;
- executeCallback = nil;
+ ffmpegSessionCompleteCallback = nil;
+ ffprobeSessionCompleteCallback = nil;
+ mediaInformationSessionCompleteCallback = nil;
globalLogRedirectionStrategy = LogRedirectionStrategyPrintLogsWhenNoCallbacksDefined;
@@ -901,7 +994,7 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
int returnCodeValue = executeFFprobe([mediaInformationSession getSessionId], [mediaInformationSession getArguments]);
ReturnCode* returnCode = [[ReturnCode alloc] init:returnCodeValue];
[mediaInformationSession complete:returnCode];
- if ([returnCode isSuccess]) {
+ if ([returnCode isValueSuccess]) {
MediaInformation* mediaInformation = [MediaInformationJsonParser from:[mediaInformationSession getAllLogsAsStringWithTimeout:waitTimeout]];
[mediaInformationSession setMediaInformation:mediaInformation];
}
@@ -918,14 +1011,27 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
+ (void)asyncFFmpegExecute:(FFmpegSession*)ffmpegSession onDispatchQueue:(dispatch_queue_t)queue {
dispatch_async(queue, ^{
[FFmpegKitConfig ffmpegExecute:ffmpegSession];
- ExecuteCallback globalExecuteCallback = [FFmpegKitConfig getExecuteCallback];
- if (globalExecuteCallback != nil) {
- globalExecuteCallback(ffmpegSession);
+
+ FFmpegSessionCompleteCallback completeCallback = [ffmpegSession getCompleteCallback];
+ if (completeCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ completeCallback(ffmpegSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside session complete callback. %@", [exception callStackSymbols]);
+ }
}
-
- ExecuteCallback sessionExecuteCallback = [ffmpegSession getExecuteCallback];
- if (sessionExecuteCallback != nil) {
- sessionExecuteCallback(ffmpegSession);
+
+ FFmpegSessionCompleteCallback globalFFmpegSessionCompleteCallback = [FFmpegKitConfig getFFmpegSessionCompleteCallback];
+ if (globalFFmpegSessionCompleteCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ globalFFmpegSessionCompleteCallback(ffmpegSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside global complete callback. %@", [exception callStackSymbols]);
+ }
}
});
}
@@ -937,14 +1043,27 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
+ (void)asyncFFprobeExecute:(FFprobeSession*)ffprobeSession onDispatchQueue:(dispatch_queue_t)queue {
dispatch_async(queue, ^{
[FFmpegKitConfig ffprobeExecute:ffprobeSession];
- ExecuteCallback globalExecuteCallback = [FFmpegKitConfig getExecuteCallback];
- if (globalExecuteCallback != nil) {
- globalExecuteCallback(ffprobeSession);
+
+ FFprobeSessionCompleteCallback completeCallback = [ffprobeSession getCompleteCallback];
+ if (completeCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ completeCallback(ffprobeSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside session complete callback. %@", [exception callStackSymbols]);
+ }
}
-
- ExecuteCallback sessionExecuteCallback = [ffprobeSession getExecuteCallback];
- if (sessionExecuteCallback != nil) {
- sessionExecuteCallback(ffprobeSession);
+
+ FFprobeSessionCompleteCallback globalFFprobeSessionCompleteCallback = [FFmpegKitConfig getFFprobeSessionCompleteCallback];
+ if (globalFFprobeSessionCompleteCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ globalFFprobeSessionCompleteCallback(ffprobeSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside global complete callback. %@", [exception callStackSymbols]);
+ }
}
});
}
@@ -956,14 +1075,27 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
+ (void)asyncGetMediaInformationExecute:(MediaInformationSession*)mediaInformationSession onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
dispatch_async(queue, ^{
[FFmpegKitConfig getMediaInformationExecute:mediaInformationSession withTimeout:waitTimeout];
- ExecuteCallback globalExecuteCallback = [FFmpegKitConfig getExecuteCallback];
- if (globalExecuteCallback != nil) {
- globalExecuteCallback(mediaInformationSession);
+
+ MediaInformationSessionCompleteCallback completeCallback = [mediaInformationSession getCompleteCallback];
+ if (completeCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ completeCallback(mediaInformationSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside session complete callback. %@", [exception callStackSymbols]);
+ }
}
-
- ExecuteCallback sessionExecuteCallback = [mediaInformationSession getExecuteCallback];
- if (sessionExecuteCallback != nil) {
- sessionExecuteCallback(mediaInformationSession);
+
+ MediaInformationSessionCompleteCallback globalMediaInformationSessionCompleteCallback = [FFmpegKitConfig getMediaInformationSessionCompleteCallback];
+ if (globalMediaInformationSessionCompleteCallback != nil) {
+ @try {
+ // NOTIFY SESSION CALLBACK DEFINED
+ globalMediaInformationSessionCompleteCallback(mediaInformationSession);
+ }
+ @catch(NSException* exception) {
+ NSLog(@"Exception thrown inside global complete callback. %@", [exception callStackSymbols]);
+ }
}
});
}
@@ -976,12 +1108,28 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
statisticsCallback = callback;
}
-+ (void)enableExecuteCallback:(ExecuteCallback)callback {
- executeCallback = callback;
++ (void)enableFFmpegSessionCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback {
+ ffmpegSessionCompleteCallback = completeCallback;
}
-+ (ExecuteCallback)getExecuteCallback {
- return executeCallback;
++ (FFmpegSessionCompleteCallback)getFFmpegSessionCompleteCallback {
+ return ffmpegSessionCompleteCallback;
+}
+
++ (void)enableFFprobeSessionCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback {
+ ffprobeSessionCompleteCallback = completeCallback;
+}
+
++ (FFprobeSessionCompleteCallback)getFFprobeSessionCompleteCallback {
+ return ffprobeSessionCompleteCallback;
+}
+
++ (void)enableMediaInformationSessionCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback {
+ mediaInformationSessionCompleteCallback = completeCallback;
+}
+
++ (MediaInformationSessionCompleteCallback)getMediaInformationSessionCompleteCallback {
+ return mediaInformationSessionCompleteCallback;
}
+ (int)getLogLevel {
@@ -1076,6 +1224,7 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
[sessionHistoryLock lock];
[sessionHistoryList removeAllObjects];
+ [sessionHistoryMap removeAllObjects];
[sessionHistoryLock unlock];
}
@@ -1114,6 +1263,23 @@ int executeFFprobe(long sessionId, NSArray* arguments) {
return ffprobeSessions;
}
++ (NSArray*)getMediaInformationSessions {
+ NSMutableArray* mediaInformationSessions = [[NSMutableArray alloc] init];
+
+ [sessionHistoryLock lock];
+
+ for(int i = 0; i < [sessionHistoryList count]; i++) {
+ id session = [sessionHistoryList objectAtIndex:i];
+ if ([session isMediaInformation]) {
+ [mediaInformationSessions addObject:session];
+ }
+ }
+
+ [sessionHistoryLock unlock];
+
+ return mediaInformationSessions;
+}
+
+ (NSArray*)getSessionsByState:(SessionState)state {
NSMutableArray* sessions = [[NSMutableArray alloc] init];
diff --git a/apple/src/FFmpegSession.h b/apple/src/FFmpegSession.h
index f63d225..fac4ff5 100644
--- a/apple/src/FFmpegSession.h
+++ b/apple/src/FFmpegSession.h
@@ -23,6 +23,7 @@
#import
#import "AbstractSession.h"
#import "StatisticsCallback.h"
+#import "FFmpegSessionCompleteCallback.h"
/**
* An FFmpeg session.
@@ -39,31 +40,31 @@
/**
* Builds a new FFmpeg session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback;
/**
* Builds a new FFmpeg session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
- * @param logCallback session specific log callback
- * @param statisticsCallback session specific statistics callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
+ * @param statisticsCallback session specific statistics callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback;
/**
* Builds a new FFmpeg session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
- * @param logCallback session specific log callback
- * @param statisticsCallback session specific statistics callback
- * @param logRedirectionStrategy session specific log redirection strategy
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
+ * @param statisticsCallback session specific statistics callback
+ * @param logRedirectionStrategy session specific log redirection strategy
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
/**
* Returns the session specific statistics callback.
@@ -72,6 +73,13 @@
*/
- (StatisticsCallback)getStatisticsCallback;
+/**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+- (FFmpegSessionCompleteCallback)getCompleteCallback;
+
/**
* Returns all statistics entries generated for this session. If there are asynchronous
* messages that are not delivered yet, this method waits for them until the given timeout.
@@ -108,7 +116,8 @@
- (Statistics*)getLastReceivedStatistics;
/**
- * Adds a new statistics entry for this session.
+ * Adds a new statistics entry for this session. It is invoked internally by FFmpegKit
library methods.
+ * Must not be used by user applications.
*
* @param statistics statistics entry
*/
diff --git a/apple/src/FFmpegSession.m b/apple/src/FFmpegSession.m
index 0290153..6fdcd68 100644
--- a/apple/src/FFmpegSession.m
+++ b/apple/src/FFmpegSession.m
@@ -17,7 +17,6 @@
* along with FFmpegKit. If not, see .
*/
-#import "ExecuteCallback.h"
#import "FFmpegSession.h"
#import "FFmpegKitConfig.h"
#import "LogCallback.h"
@@ -25,6 +24,7 @@
@implementation FFmpegSession {
StatisticsCallback _statisticsCallback;
+ FFmpegSessionCompleteCallback _completeCallback;
NSMutableArray* _statistics;
NSRecursiveLock* _statisticsLock;
}
@@ -35,10 +35,11 @@
- (instancetype)init:(NSArray*)arguments {
- self = [super init:arguments withExecuteCallback:nil withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
if (self) {
_statisticsCallback = nil;
+ _completeCallback = nil;
_statistics = [[NSMutableArray alloc] init];
_statisticsLock = [[NSRecursiveLock alloc] init];
}
@@ -46,12 +47,13 @@
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback {
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
if (self) {
_statisticsCallback = nil;
+ _completeCallback = completeCallback;
_statistics = [[NSMutableArray alloc] init];
_statisticsLock = [[NSRecursiveLock alloc] init];
}
@@ -59,12 +61,13 @@
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback {
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ self = [super init:arguments withLogCallback:logCallback withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
if (self) {
_statisticsCallback = statisticsCallback;
+ _completeCallback = completeCallback;
_statistics = [[NSMutableArray alloc] init];
_statisticsLock = [[NSRecursiveLock alloc] init];
}
@@ -72,12 +75,13 @@
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFmpegSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withStatisticsCallback:(StatisticsCallback)statisticsCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withLogRedirectionStrategy:logRedirectionStrategy];
+ self = [super init:arguments withLogCallback:logCallback withLogRedirectionStrategy:logRedirectionStrategy];
if (self) {
_statisticsCallback = statisticsCallback;
+ _completeCallback = completeCallback;
_statistics = [[NSMutableArray alloc] init];
_statisticsLock = [[NSRecursiveLock alloc] init];
}
@@ -89,6 +93,10 @@
return _statisticsCallback;
}
+- (FFmpegSessionCompleteCallback)getCompleteCallback {
+ return _completeCallback;
+}
+
- (NSArray*)getAllStatisticsWithTimeout:(int)waitTimeout {
[self waitForAsynchronousMessagesInTransmit:waitTimeout];
@@ -137,5 +145,9 @@
return false;
}
+- (BOOL)isMediaInformation {
+ return false;
+}
+
@end
diff --git a/apple/src/ExecuteCallback.h b/apple/src/FFmpegSessionCompleteCallback.h
similarity index 79%
rename from apple/src/ExecuteCallback.h
rename to apple/src/FFmpegSessionCompleteCallback.h
index 44e113d..b874966 100644
--- a/apple/src/ExecuteCallback.h
+++ b/apple/src/FFmpegSessionCompleteCallback.h
@@ -17,13 +17,13 @@
* along with FFmpegKit. If not, see .
*/
-#ifndef FFMPEG_KIT_EXECUTE_CALLBACK_H
-#define FFMPEG_KIT_EXECUTE_CALLBACK_H
+#ifndef FFMPEG_KIT_FFMPEG_SESSION_COMPLETE_CALLBACK_H
+#define FFMPEG_KIT_FFMPEG_SESSION_COMPLETE_CALLBACK_H
-@protocol Session;
+@class FFmpegSession;
/**
- *
Callback invoked when an asynchronous session ends running.
+ *
Callback function that is invoked when an asynchronous FFmpeg
session has ended.
*
Session has either SessionStateCompleted or SessionStateFailed state when
* the callback is invoked.
*
If it has SessionStateCompleted state, ReturnCode
should be checked to
@@ -43,8 +43,8 @@
*
* @param session session of the completed execution
*/
-typedef void (^ExecuteCallback)(id session);
+typedef void (^FFmpegSessionCompleteCallback)(FFmpegSession* session);
-#import "Session.h"
+#import "FFmpegSession.h"
-#endif // FFMPEG_KIT_EXECUTE_CALLBACK_H
+#endif // FFMPEG_KIT_FFMPEG_SESSION_COMPLETE_CALLBACK_H
diff --git a/apple/src/FFprobeKit.h b/apple/src/FFprobeKit.h
index 132e644..dccb7de 100644
--- a/apple/src/FFprobeKit.h
+++ b/apple/src/FFprobeKit.h
@@ -32,11 +32,11 @@
*
* FFprobeSession *session = [FFprobeKit execute:@"-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4"];
*
- * FFprobeSession *asyncSession = [FFprobeKit executeAsync:@"-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4" withExecuteCallback:executeCallback];
+ * FFprobeSession *asyncSession = [FFprobeKit executeAsync:@"-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4" withCompleteCallback:completeCallback];
*
* Provides overloaded execute
methods to define session specific callbacks.
*
- * FFprobeSession *session = [FFprobeKit executeAsync:@"-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4" withExecuteCallback:executeCallback withLogCallback:logCallback];
+ * FFprobeSession *session = [FFprobeKit executeAsync:@"-hide_banner -v error -show_entries format=size -of default=noprint_wrappers=1 file1.mp4" withCompleteCallback:completeCallback withLogCallback:logCallback];
*
* It can extract media information for a file or a url, using getMediaInformation method.
*
@@ -56,54 +56,54 @@
/**
* Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback;
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback;
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback;
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback;
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be called when the execution is completed
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Starts an asynchronous FFprobe execution with arguments provided.
*
- *
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ *
Note that this method returns immediately and does not wait the execution to complete.
+ * You must use an FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param arguments FFprobe command options/arguments as string array
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param arguments FFprobe command options/arguments as string array
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Synchronously executes FFprobe command provided. Space character is used to split command
@@ -120,56 +120,56 @@
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback;
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback;
/**
*
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
+ * @param command FFprobe command
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback;
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback;
/**
*
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Starts an asynchronous FFprobe execution for the given command. Space character is used to split the command
* into arguments. You can use single or double quote characters to specify arguments inside your command.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * FFprobeSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFprobe command
- * @param executeCallback callback that will be called when the execution is completed
- * @param logCallback callback that will receive logs
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param command FFprobe command
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param logCallback callback that will receive logs
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return FFprobe session created for this execution
*/
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Extracts media information for the file specified with path.
@@ -192,55 +192,55 @@
*
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be called when the execution is completed
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be called when the execution has completed
* @return media information session created for this execution
*/
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback;
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback;
/**
*
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param waitTimeout max time to wait until media information is transmitted
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withTimeout:(int)waitTimeout;
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withTimeout:(int)waitTimeout;
/**
*
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be called when the execution is completed
- * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be called when the execution has completed
+ * @param queue dispatch queue that will be used to run this asynchronous operation
* @return media information session created for this execution
*/
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue;
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue;
/**
*
Starts an asynchronous FFprobe execution to extract the media information for the specified file.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
- * @param path path or uri of a media file
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param queue dispatch queue that will be used to run this asynchronous operation
- * @param waitTimeout max time to wait until media information is transmitted
+ * @param path path or uri of a media file
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout;
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout;
/**
*
Extracts media information using the command provided asynchronously.
@@ -255,23 +255,47 @@
* this method must generate the output in JSON format in order to successfully extract media information from it.
*
*
Note that this method returns immediately and does not wait the execution to complete. You must use an
- * ExecuteCallback if you want to be notified about the result.
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
*
- * @param command FFprobe command that prints media information for a file in JSON format
- * @param executeCallback callback that will be notified when execution is completed
- * @param logCallback callback that will receive logs
- * @param queue dispatch queue that will be used to run this asynchronous operation
- * @param waitTimeout max time to wait until media information is transmitted
+ * @param command FFprobe command that prints media information for a file in JSON format
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param waitTimeout max time to wait until media information is transmitted
* @return media information session created for this execution
*/
-+ (MediaInformationSession*)getMediaInformationFromCommandAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout;
++ (MediaInformationSession*)getMediaInformationFromCommandAsync:(NSString*)command withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout;
+
+/**
+ *
Starts an asynchronous FFprobe execution to extract media information using command arguments. The command
+ * passed to this method must generate the output in JSON format in order to successfully extract media information
+ * from it.
+ *
+ *
Note that this method returns immediately and does not wait the execution to complete. You must use an
+ * MediaInformationSessionCompleteCallback if you want to be notified about the result.
+ *
+ * @param command FFprobe command that prints media information for a file in JSON format
+ * @param completeCallback callback that will be notified when execution has completed
+ * @param logCallback callback that will receive logs
+ * @param queue dispatch queue that will be used to run this asynchronous operation
+ * @param waitTimeout max time to wait until media information is transmitted
+ * @return media information session created for this execution
+ */
++ (MediaInformationSession*)getMediaInformationFromCommandArgumentsAsync:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout;
/**
*
Lists all FFprobe sessions in the session history.
*
* @return all FFprobe sessions in the session history
*/
-+ (NSArray*)listSessions;
++ (NSArray*)listFFprobeSessions;
+
+/**
+ *
Lists all MediaInformation sessions in the session history.
+ *
+ * @return all MediaInformation sessions in the session history
+ */
++ (NSArray*)listMediaInformationSessions;
@end
diff --git a/apple/src/FFprobeKit.m b/apple/src/FFprobeKit.m
index 71b6628..59cdeab 100644
--- a/apple/src/FFprobeKit.m
+++ b/apple/src/FFprobeKit.m
@@ -28,32 +28,36 @@
[FFmpegKitConfig class];
}
++ (NSArray*)defaultGetMediaInformationCommandArguments:(NSString*)path {
+ return [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-show_chapters", @"-i", path, nil];
+}
+
+ (FFprobeSession*)executeWithArguments:(NSArray*)arguments {
FFprobeSession* session = [[FFprobeSession alloc] init:arguments];
[FFmpegKitConfig ffprobeExecute:session];
return session;
}
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback {
- FFprobeSession* session = [[FFprobeSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback {
+ FFprobeSession* session = [[FFprobeSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFprobeExecute:session];
return session;
}
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback {
- FFprobeSession* session = [[FFprobeSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback {
+ FFprobeSession* session = [[FFprobeSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncFFprobeExecute:session];
return session;
}
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFprobeSession* session = [[FFprobeSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFprobeSession* session = [[FFprobeSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFprobeExecute:session onDispatchQueue:queue];
return session;
}
-+ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFprobeSession* session = [[FFprobeSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (FFprobeSession*)executeWithArgumentsAsync:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFprobeSession* session = [[FFprobeSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncFFprobeExecute:session onDispatchQueue:queue];
return session;
}
@@ -64,68 +68,68 @@
return session;
}
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback {
- FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback];
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback {
+ FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFprobeExecute:session];
return session;
}
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback {
- FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback {
+ FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncFFprobeExecute:session];
return session;
}
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback];
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncFFprobeExecute:session onDispatchQueue:queue];
return session;
}
-+ (FFprobeSession*)executeAsync:(NSString*)command withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue {
- FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (FFprobeSession*)executeAsync:(NSString*)command withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue {
+ FFprobeSession* session = [[FFprobeSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncFFprobeExecute:session onDispatchQueue:queue];
return session;
}
+ (MediaInformationSession*)getMediaInformation:(NSString*)path {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments];
[FFmpegKitConfig getMediaInformationExecute:session withTimeout:AbstractSessionDefaultTimeoutForAsynchronousMessagesInTransmit];
return session;
}
+ (MediaInformationSession*)getMediaInformation:(NSString*)path withTimeout:(int)waitTimeout {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments];
[FFmpegKitConfig getMediaInformationExecute:session withTimeout:waitTimeout];
return session;
}
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
- MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback {
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncGetMediaInformationExecute:session withTimeout:AbstractSessionDefaultTimeoutForAsynchronousMessagesInTransmit];
return session;
}
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withTimeout:(int)waitTimeout {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
- MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withTimeout:(int)waitTimeout {
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncGetMediaInformationExecute:session withTimeout:waitTimeout];
return session;
}
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback onDispatchQueue:(dispatch_queue_t)queue {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
- MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback onDispatchQueue:(dispatch_queue_t)queue {
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncGetMediaInformationExecute:session onDispatchQueue:queue withTimeout:AbstractSessionDefaultTimeoutForAsynchronousMessagesInTransmit];
return session;
}
-+ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
- NSArray* arguments = [[NSArray alloc] initWithObjects:@"-v", @"error", @"-hide_banner", @"-print_format", @"json", @"-show_format", @"-show_streams", @"-i", path, nil];
- MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withExecuteCallback:executeCallback];
++ (MediaInformationSession*)getMediaInformationAsync:(NSString*)path withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
+ NSArray* arguments = [FFprobeKit defaultGetMediaInformationCommandArguments:path];
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withCompleteCallback:completeCallback];
[FFmpegKitConfig asyncGetMediaInformationExecute:session onDispatchQueue:queue withTimeout:waitTimeout];
return session;
}
@@ -136,14 +140,24 @@
return session;
}
-+ (MediaInformationSession*)getMediaInformationFromCommandAsync:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
- MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback];
++ (MediaInformationSession*)getMediaInformationFromCommandAsync:(NSString*)command withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:[FFmpegKitConfig parseArguments:command] withCompleteCallback:completeCallback withLogCallback:logCallback];
+ [FFmpegKitConfig asyncGetMediaInformationExecute:session onDispatchQueue:queue withTimeout:waitTimeout];
+ return session;
+}
+
++ (MediaInformationSession*)getMediaInformationFromCommandArgumentsAsync:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback onDispatchQueue:(dispatch_queue_t)queue withTimeout:(int)waitTimeout {
+ MediaInformationSession* session = [[MediaInformationSession alloc] init:arguments withCompleteCallback:completeCallback withLogCallback:logCallback];
[FFmpegKitConfig asyncGetMediaInformationExecute:session onDispatchQueue:queue withTimeout:waitTimeout];
return session;
}
-+ (NSArray*)listSessions {
++ (NSArray*)listFFprobeSessions {
return [FFmpegKitConfig getFFprobeSessions];
}
++ (NSArray*)listMediaInformationSessions {
+ return [FFmpegKitConfig getMediaInformationSessions];
+}
+
@end
diff --git a/apple/src/FFprobeSession.h b/apple/src/FFprobeSession.h
index 4565fca..40f62df 100644
--- a/apple/src/FFprobeSession.h
+++ b/apple/src/FFprobeSession.h
@@ -22,6 +22,7 @@
#import
#import "AbstractSession.h"
+#import "FFprobeSessionCompleteCallback.h"
/**
* An FFprobe session.
@@ -38,29 +39,36 @@
/**
* Builds a new FFprobe session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback;
/**
* Builds a new FFprobe session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
- * @param logCallback session specific log callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback;
/**
* Builds a new FFprobe session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
- * @param logCallback session specific log callback
- * @param logRedirectionStrategy session specific log redirection strategy
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
+ * @param logRedirectionStrategy session specific log redirection strategy
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy;
+
+/**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+- (FFprobeSessionCompleteCallback)getCompleteCallback;
@end
diff --git a/apple/src/FFprobeSession.m b/apple/src/FFprobeSession.m
index f6c1582..8036d91 100644
--- a/apple/src/FFprobeSession.m
+++ b/apple/src/FFprobeSession.m
@@ -17,45 +17,66 @@
* along with FFmpegKit. If not, see .
*/
-#import "ExecuteCallback.h"
#import "FFprobeSession.h"
#import "FFmpegKitConfig.h"
#import "LogCallback.h"
-@implementation FFprobeSession
+@implementation FFprobeSession {
+ FFprobeSessionCompleteCallback _completeCallback;
+}
+
++ (void)initialize {
+ // EMPTY INITIALIZE
+}
- (instancetype)init:(NSArray*)arguments {
- self = [super init:arguments withExecuteCallback:nil withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+
+ if (self) {
+ _completeCallback = nil;
+ }
return self;
}
-+ (void)initialize {
- // EMPTY INITIALIZE
-}
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback {
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback {
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:nil withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ if (self) {
+ _completeCallback = completeCallback;
+ }
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback {
+
+ self = [super init:arguments withLogCallback:logCallback withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withLogRedirectionStrategy:[FFmpegKitConfig getLogRedirectionStrategy]];
+ if (self) {
+ _completeCallback = completeCallback;
+ }
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(FFprobeSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback withLogRedirectionStrategy:(LogRedirectionStrategy)logRedirectionStrategy {
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withLogRedirectionStrategy:logRedirectionStrategy];
+ self = [super init:arguments withLogCallback:logCallback withLogRedirectionStrategy:logRedirectionStrategy];
+
+ if (self) {
+ _completeCallback = completeCallback;
+ }
return self;
}
+- (FFprobeSessionCompleteCallback)getCompleteCallback {
+ return _completeCallback;
+}
+
- (BOOL)isFFmpeg {
return false;
}
@@ -64,5 +85,9 @@
return true;
}
+- (BOOL)isMediaInformation {
+ return false;
+}
+
@end
diff --git a/apple/src/FFprobeSessionCompleteCallback.h b/apple/src/FFprobeSessionCompleteCallback.h
new file mode 100644
index 0000000..6189634
--- /dev/null
+++ b/apple/src/FFprobeSessionCompleteCallback.h
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2020-2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+#ifndef FFMPEG_KIT_FFPROBE_SESSION_COMPLETE_CALLBACK_H
+#define FFMPEG_KIT_FFPROBE_SESSION_COMPLETE_CALLBACK_H
+
+@class FFprobeSession;
+
+/**
+ *
Callback function that is invoked when an asynchronous FFprobe
session has ended.
+ *
Session has either SessionStateCompleted or SessionStateFailed state when
+ * the callback is invoked.
+ *
If it has SessionStateCompleted state, ReturnCode
should be checked to
+ * see the execution result.
+ *
If getState
returns SessionStateFailed then
+ * getFailStackTrace
should be used to get the failure reason.
+ *
+ * switch ([session getState]) {
+ * case SessionStateCompleted:
+ * ReturnCode *returnCode = [session getReturnCode];
+ * break;
+ * case SessionStateFailed:
+ * NSString *failStackTrace = [session getFailStackTrace];
+ * break;
+ * }
+ *
+ *
+ * @param session session of the completed execution
+ */
+typedef void (^FFprobeSessionCompleteCallback)(FFprobeSession* session);
+
+#import "FFprobeSession.h"
+
+#endif // FFMPEG_KIT_FFPROBE_SESSION_COMPLETE_CALLBACK_H
diff --git a/apple/src/Makefile.am b/apple/src/Makefile.am
index 9f4e8d3..40ce966 100644
--- a/apple/src/Makefile.am
+++ b/apple/src/Makefile.am
@@ -1,11 +1,12 @@
lib_LTLIBRARIES = libffmpegkit.la
-libffmpegkit_la_LIBADD = @FFMPEG_LIBS@
+libffmpegkit_la_LIBADD = @FFMPEG_FRAMEWORKS@
libffmpegkit_la_SOURCES = \
AbstractSession.m \
ArchDetect.m \
AtomicLong.m \
+ Chapter.m \
FFmpegKit.m \
FFmpegKitConfig.m \
FFmpegSession.m \
@@ -35,28 +36,31 @@ include_HEADERS = \
AbstractSession.h \
ArchDetect.h \
AtomicLong.h \
- ExecuteCallback.h \
+ Chapter.h \
FFmpegKit.h \
FFmpegKitConfig.h \
FFmpegSession.h \
- FFprobeKit.h \
- FFprobeSession.h \
- Level.h \
- Log.h \
- LogCallback.h \
- LogRedirectionStrategy.h \
- MediaInformation.h \
- MediaInformationJsonParser.h \
- MediaInformationSession.h \
- Packages.h \
- ReturnCode.h \
- Session.h \
- SessionState.h \
- Statistics.h \
- StatisticsCallback.h \
- StreamInformation.h \
- ffmpegkit_exception.h \
- fftools_cmdutils.h \
+ FFmpegSessionCompleteCallback.h \
+ FFprobeKit.h \
+ FFprobeSession.h \
+ FFprobeSessionCompleteCallback.h \
+ Level.h \
+ Log.h \
+ LogCallback.h \
+ LogRedirectionStrategy.h \
+ MediaInformation.h \
+ MediaInformationJsonParser.h \
+ MediaInformationSession.h \
+ MediaInformationSessionCompleteCallback.h \
+ Packages.h \
+ ReturnCode.h \
+ Session.h \
+ SessionState.h \
+ Statistics.h \
+ StatisticsCallback.h \
+ StreamInformation.h \
+ ffmpegkit_exception.h \
+ fftools_cmdutils.h \
fftools_ffmpeg.h
libffmpegkit_la_CFLAGS = $(CFLAGS)
diff --git a/apple/src/Makefile.in b/apple/src/Makefile.in
index 102841a..1020462 100644
--- a/apple/src/Makefile.in
+++ b/apple/src/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -134,18 +134,18 @@ am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"
LTLIBRARIES = $(lib_LTLIBRARIES)
libffmpegkit_la_DEPENDENCIES =
am__libffmpegkit_la_SOURCES_DIST = AbstractSession.m ArchDetect.m \
- AtomicLong.m FFmpegKit.m FFmpegKitConfig.m FFmpegSession.m \
- FFprobeKit.m FFprobeSession.m Log.m MediaInformation.m \
- MediaInformationJsonParser.m MediaInformationSession.m \
- Packages.m ReturnCode.m Statistics.m StreamInformation.m \
- ffmpegkit_exception.m fftools_cmdutils.c fftools_ffmpeg.c \
- fftools_ffmpeg_filter.c fftools_ffmpeg_hw.c \
+ AtomicLong.m Chapter.m FFmpegKit.m FFmpegKitConfig.m \
+ FFmpegSession.m FFprobeKit.m FFprobeSession.m Log.m \
+ MediaInformation.m MediaInformationJsonParser.m \
+ MediaInformationSession.m Packages.m ReturnCode.m Statistics.m \
+ StreamInformation.m ffmpegkit_exception.m fftools_cmdutils.c \
+ fftools_ffmpeg.c fftools_ffmpeg_filter.c fftools_ffmpeg_hw.c \
fftools_ffmpeg_opt.c fftools_ffprobe.c \
fftools_ffmpeg_videotoolbox.c
@FFMPEGKIT_VIDEOTOOLBOX_TRUE@am__objects_1 = libffmpegkit_la-fftools_ffmpeg_videotoolbox.lo
am_libffmpegkit_la_OBJECTS = libffmpegkit_la-AbstractSession.lo \
libffmpegkit_la-ArchDetect.lo libffmpegkit_la-AtomicLong.lo \
- libffmpegkit_la-FFmpegKit.lo \
+ libffmpegkit_la-Chapter.lo libffmpegkit_la-FFmpegKit.lo \
libffmpegkit_la-FFmpegKitConfig.lo \
libffmpegkit_la-FFmpegSession.lo libffmpegkit_la-FFprobeKit.lo \
libffmpegkit_la-FFprobeSession.lo libffmpegkit_la-Log.lo \
@@ -189,6 +189,7 @@ am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/libffmpegkit_la-AbstractSession.Plo \
./$(DEPDIR)/libffmpegkit_la-ArchDetect.Plo \
./$(DEPDIR)/libffmpegkit_la-AtomicLong.Plo \
+ ./$(DEPDIR)/libffmpegkit_la-Chapter.Plo \
./$(DEPDIR)/libffmpegkit_la-FFmpegKit.Plo \
./$(DEPDIR)/libffmpegkit_la-FFmpegKitConfig.Plo \
./$(DEPDIR)/libffmpegkit_la-FFmpegSession.Plo \
@@ -272,8 +273,6 @@ am__define_uniq_tagged_files = \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
@@ -287,8 +286,9 @@ AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
-CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
@@ -299,8 +299,9 @@ ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
+ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
-FFMPEG_LIBS = @FFMPEG_LIBS@
+FFMPEG_FRAMEWORKS = @FFMPEG_FRAMEWORKS@
FGREP = @FGREP@
GREP = @GREP@
INSTALL = @INSTALL@
@@ -389,6 +390,7 @@ pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
+runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
@@ -398,10 +400,10 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
lib_LTLIBRARIES = libffmpegkit.la
-libffmpegkit_la_LIBADD = @FFMPEG_LIBS@
+libffmpegkit_la_LIBADD = @FFMPEG_FRAMEWORKS@
libffmpegkit_la_SOURCES = AbstractSession.m ArchDetect.m AtomicLong.m \
- FFmpegKit.m FFmpegKitConfig.m FFmpegSession.m FFprobeKit.m \
- FFprobeSession.m Log.m MediaInformation.m \
+ Chapter.m FFmpegKit.m FFmpegKitConfig.m FFmpegSession.m \
+ FFprobeKit.m FFprobeSession.m Log.m MediaInformation.m \
MediaInformationJsonParser.m MediaInformationSession.m \
Packages.m ReturnCode.m Statistics.m StreamInformation.m \
ffmpegkit_exception.m fftools_cmdutils.c fftools_ffmpeg.c \
@@ -411,28 +413,31 @@ include_HEADERS = \
AbstractSession.h \
ArchDetect.h \
AtomicLong.h \
- ExecuteCallback.h \
+ Chapter.h \
FFmpegKit.h \
FFmpegKitConfig.h \
FFmpegSession.h \
- FFprobeKit.h \
- FFprobeSession.h \
- Level.h \
- Log.h \
- LogCallback.h \
- LogRedirectionStrategy.h \
- MediaInformation.h \
- MediaInformationJsonParser.h \
- MediaInformationSession.h \
- Packages.h \
- ReturnCode.h \
- Session.h \
- SessionState.h \
- Statistics.h \
- StatisticsCallback.h \
- StreamInformation.h \
- ffmpegkit_exception.h \
- fftools_cmdutils.h \
+ FFmpegSessionCompleteCallback.h \
+ FFprobeKit.h \
+ FFprobeSession.h \
+ FFprobeSessionCompleteCallback.h \
+ Level.h \
+ Log.h \
+ LogCallback.h \
+ LogRedirectionStrategy.h \
+ MediaInformation.h \
+ MediaInformationJsonParser.h \
+ MediaInformationSession.h \
+ MediaInformationSessionCompleteCallback.h \
+ Packages.h \
+ ReturnCode.h \
+ Session.h \
+ SessionState.h \
+ Statistics.h \
+ StatisticsCallback.h \
+ StreamInformation.h \
+ ffmpegkit_exception.h \
+ fftools_cmdutils.h \
fftools_ffmpeg.h
libffmpegkit_la_CFLAGS = $(CFLAGS)
@@ -520,6 +525,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-AbstractSession.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-ArchDetect.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-AtomicLong.Plo@am__quote@ # am--include-marker
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-Chapter.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-FFmpegKit.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-FFmpegKitConfig.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libffmpegkit_la-FFmpegSession.Plo@am__quote@ # am--include-marker
@@ -666,6 +672,13 @@ libffmpegkit_la-AtomicLong.lo: AtomicLong.m
@AMDEP_TRUE@@am__fastdepOBJC_FALSE@ DEPDIR=$(DEPDIR) $(OBJCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepOBJC_FALSE@ $(AM_V_OBJC@am__nodep@)$(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(OBJC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libffmpegkit_la_OBJCFLAGS) $(OBJCFLAGS) -c -o libffmpegkit_la-AtomicLong.lo `test -f 'AtomicLong.m' || echo '$(srcdir)/'`AtomicLong.m
+libffmpegkit_la-Chapter.lo: Chapter.m
+@am__fastdepOBJC_TRUE@ $(AM_V_OBJC)$(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(OBJC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libffmpegkit_la_OBJCFLAGS) $(OBJCFLAGS) -MT libffmpegkit_la-Chapter.lo -MD -MP -MF $(DEPDIR)/libffmpegkit_la-Chapter.Tpo -c -o libffmpegkit_la-Chapter.lo `test -f 'Chapter.m' || echo '$(srcdir)/'`Chapter.m
+@am__fastdepOBJC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libffmpegkit_la-Chapter.Tpo $(DEPDIR)/libffmpegkit_la-Chapter.Plo
+@AMDEP_TRUE@@am__fastdepOBJC_FALSE@ $(AM_V_OBJC)source='Chapter.m' object='libffmpegkit_la-Chapter.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepOBJC_FALSE@ DEPDIR=$(DEPDIR) $(OBJCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepOBJC_FALSE@ $(AM_V_OBJC@am__nodep@)$(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(OBJC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libffmpegkit_la_OBJCFLAGS) $(OBJCFLAGS) -c -o libffmpegkit_la-Chapter.lo `test -f 'Chapter.m' || echo '$(srcdir)/'`Chapter.m
+
libffmpegkit_la-FFmpegKit.lo: FFmpegKit.m
@am__fastdepOBJC_TRUE@ $(AM_V_OBJC)$(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(OBJC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libffmpegkit_la_OBJCFLAGS) $(OBJCFLAGS) -MT libffmpegkit_la-FFmpegKit.lo -MD -MP -MF $(DEPDIR)/libffmpegkit_la-FFmpegKit.Tpo -c -o libffmpegkit_la-FFmpegKit.lo `test -f 'FFmpegKit.m' || echo '$(srcdir)/'`FFmpegKit.m
@am__fastdepOBJC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libffmpegkit_la-FFmpegKit.Tpo $(DEPDIR)/libffmpegkit_la-FFmpegKit.Plo
@@ -842,7 +855,6 @@ cscopelist-am: $(am__tagged_files)
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
@@ -922,6 +934,7 @@ distclean: distclean-am
-rm -f ./$(DEPDIR)/libffmpegkit_la-AbstractSession.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-ArchDetect.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-AtomicLong.Plo
+ -rm -f ./$(DEPDIR)/libffmpegkit_la-Chapter.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegKit.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegKitConfig.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegSession.Plo
@@ -991,6 +1004,7 @@ maintainer-clean: maintainer-clean-am
-rm -f ./$(DEPDIR)/libffmpegkit_la-AbstractSession.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-ArchDetect.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-AtomicLong.Plo
+ -rm -f ./$(DEPDIR)/libffmpegkit_la-Chapter.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegKit.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegKitConfig.Plo
-rm -f ./$(DEPDIR)/libffmpegkit_la-FFmpegSession.Plo
diff --git a/apple/src/MediaInformation.h b/apple/src/MediaInformation.h
index 20813cf..6d2ea86 100644
--- a/apple/src/MediaInformation.h
+++ b/apple/src/MediaInformation.h
@@ -21,6 +21,7 @@
#define FFMPEG_KIT_MEDIA_INFORMATION_H
#import
+#import "Chapter.h"
#import "StreamInformation.h"
extern NSString* const MediaKeyMediaProperties;
@@ -38,7 +39,7 @@ extern NSString* const MediaKeyTags;
*/
@interface MediaInformation : NSObject
-- (instancetype)init:(NSDictionary*)mediaDictionary withStreams:(NSArray*)streams;
+- (instancetype)init:(NSDictionary*)mediaDictionary withStreams:(NSArray*)streams withChapters:(NSArray*)chapters;
/**
* Returns file name.
@@ -103,6 +104,13 @@ extern NSString* const MediaKeyTags;
*/
- (NSArray*)getStreams;
+/**
+ * Returns all chapters.
+ *
+ * @return chapters array
+ */
+- (NSArray*)getChapters;
+
/**
* Returns the media property associated with the key.
*
diff --git a/apple/src/MediaInformation.m b/apple/src/MediaInformation.m
index c8ba7a9..a9211db 100644
--- a/apple/src/MediaInformation.m
+++ b/apple/src/MediaInformation.m
@@ -41,13 +41,19 @@ NSString* const MediaKeyTags = @"tags";
*/
NSArray *streamArray;
+ /**
+ * Stores chapters.
+ */
+ NSArray *chapterArray;
+
}
-- (instancetype)init:(NSDictionary*)mediaDictionary withStreams:(NSArray*)streams{
+- (instancetype)init:(NSDictionary*)mediaDictionary withStreams:(NSArray*)streams withChapters:(NSArray*)chapters{
self = [super init];
if (self) {
dictionary = mediaDictionary;
streamArray = streams;
+ chapterArray = chapters;
}
return self;
@@ -89,6 +95,10 @@ NSString* const MediaKeyTags = @"tags";
return streamArray;
}
+- (NSArray*)getChapters {
+ return chapterArray;
+}
+
- (NSString*)getStringProperty:(NSString*)key {
NSDictionary* mediaProperties = [self getMediaProperties];
if (mediaProperties == nil) {
diff --git a/apple/src/MediaInformationJsonParser.m b/apple/src/MediaInformationJsonParser.m
index e7fa171..c7fe7cb 100644
--- a/apple/src/MediaInformationJsonParser.m
+++ b/apple/src/MediaInformationJsonParser.m
@@ -19,6 +19,9 @@
#import "MediaInformationJsonParser.h"
+NSString* const MediaInformationJsonParserKeyStreams = @"streams";
+NSString* const MediaInformationJsonParserKeyChapters = @"chapters";
+
@implementation MediaInformationJsonParser
+ (MediaInformation*)from:(NSString*)ffprobeJsonOutput {
@@ -40,14 +43,21 @@
return nil;
}
- NSArray* array = [jsonDictionary objectForKey:@"streams"];
+ NSArray* jsonStreamArray = [jsonDictionary objectForKey:MediaInformationJsonParserKeyStreams];
NSMutableArray *streamArray = [[NSMutableArray alloc] init];
- for(int i = 0; i
-#import "FFprobeSession.h"
+#import "AbstractSession.h"
#import "MediaInformation.h"
+#import "MediaInformationSessionCompleteCallback.h"
/**
* A custom FFprobe session, which produces a MediaInformation
object using the
* FFprobe output.
*/
-@interface MediaInformationSession : FFprobeSession
+@interface MediaInformationSession : AbstractSession
/**
* Creates a new media information session.
@@ -40,19 +41,19 @@
/**
* Creates a new media information session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback;
/**
* Creates a new media information session.
*
- * @param arguments command arguments
- * @param executeCallback session specific execute callback
- * @param logCallback session specific log callback
+ * @param arguments command arguments
+ * @param completeCallback session specific complete callback
+ * @param logCallback session specific log callback
*/
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback;
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback;
/**
* Returns the media information extracted in this session.
@@ -69,6 +70,13 @@
*/
- (void)setMediaInformation:(MediaInformation*)mediaInformation;
+/**
+ * Returns the session specific complete callback.
+ *
+ * @return session specific complete callback
+ */
+- (MediaInformationSessionCompleteCallback)getCompleteCallback;
+
@end
#endif // FFMPEG_KIT_MEDIA_INFORMATION_SESSION_H
diff --git a/apple/src/MediaInformationSession.m b/apple/src/MediaInformationSession.m
index da59e42..76214b0 100644
--- a/apple/src/MediaInformationSession.m
+++ b/apple/src/MediaInformationSession.m
@@ -17,13 +17,13 @@
* along with FFmpegKit. If not, see .
*/
-#import "ExecuteCallback.h"
+#import "MediaInformationSession.h"
#import "LogCallback.h"
#import "MediaInformation.h"
-#import "MediaInformationSession.h"
@implementation MediaInformationSession {
MediaInformation* _mediaInformation;
+ MediaInformationSessionCompleteCallback _completeCallback;
}
+ (void)initialize {
@@ -32,21 +32,33 @@
- (instancetype)init:(NSArray*)arguments {
- self = [super init:arguments withExecuteCallback:nil withLogCallback:nil withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
+
+ if (self) {
+ _completeCallback = nil;
+ }
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback {
+
+ self = [super init:arguments withLogCallback:nil withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:nil withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
+ if (self) {
+ _completeCallback = completeCallback;
+ }
return self;
}
-- (instancetype)init:(NSArray*)arguments withExecuteCallback:(ExecuteCallback)executeCallback withLogCallback:(LogCallback)logCallback {
+- (instancetype)init:(NSArray*)arguments withCompleteCallback:(MediaInformationSessionCompleteCallback)completeCallback withLogCallback:(LogCallback)logCallback {
- self = [super init:arguments withExecuteCallback:executeCallback withLogCallback:logCallback withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
+ self = [super init:arguments withLogCallback:logCallback withLogRedirectionStrategy:LogRedirectionStrategyNeverPrintLogs];
+
+ if (self) {
+ _completeCallback = completeCallback;
+ }
return self;
}
@@ -59,5 +71,21 @@
_mediaInformation = mediaInformation;
}
+- (MediaInformationSessionCompleteCallback)getCompleteCallback {
+ return _completeCallback;
+}
+
+- (BOOL)isFFmpeg {
+ return false;
+}
+
+- (BOOL)isFFprobe {
+ return false;
+}
+
+- (BOOL)isMediaInformation {
+ return true;
+}
+
@end
diff --git a/apple/src/MediaInformationSessionCompleteCallback.h b/apple/src/MediaInformationSessionCompleteCallback.h
new file mode 100644
index 0000000..aedbe7b
--- /dev/null
+++ b/apple/src/MediaInformationSessionCompleteCallback.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2020-2021 Taner Sener
+ *
+ * This file is part of FFmpegKit.
+ *
+ * FFmpegKit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FFmpegKit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpegKit. If not, see .
+ */
+
+#ifndef FFMPEG_KIT_MEDIA_INFORMATION_SESSION_COMPLETE_CALLBACK_H
+#define FFMPEG_KIT_MEDIA_INFORMATION_SESSION_COMPLETE_CALLBACK_H
+
+@class MediaInformationSession;
+
+/**
+ *
Callback function that is invoked when an asynchronous MediaInformation
session
+ * has ended.
+ *
Session has either SessionStateCompleted or SessionStateFailed state when
+ * the callback is invoked.
+ *
If it has SessionStateCompleted state, ReturnCode
should be checked to
+ * see the execution result.
+ *
If getState
returns SessionStateFailed then
+ * getFailStackTrace
should be used to get the failure reason.
+ *
+ * switch ([session getState]) {
+ * case SessionStateCompleted:
+ * ReturnCode *returnCode = [session getReturnCode];
+ * break;
+ * case SessionStateFailed:
+ * NSString *failStackTrace = [session getFailStackTrace];
+ * break;
+ * }
+ *
+ *
+ * @param session session of the completed execution
+ */
+typedef void (^MediaInformationSessionCompleteCallback)(MediaInformationSession* session);
+
+#import "MediaInformationSession.h"
+
+#endif // FFMPEG_KIT_MEDIA_INFORMATION_SESSION_COMPLETE_CALLBACK_H
diff --git a/apple/src/ReturnCode.h b/apple/src/ReturnCode.h
index 3d47ee4..8047793 100644
--- a/apple/src/ReturnCode.h
+++ b/apple/src/ReturnCode.h
@@ -37,11 +37,11 @@ typedef NS_ENUM(NSUInteger, ReturnCodeEnum) {
- (int)getValue;
-- (BOOL)isSuccess;
+- (BOOL)isValueSuccess;
-- (BOOL)isError;
+- (BOOL)isValueError;
-- (BOOL)isCancel;
+- (BOOL)isValueCancel;
@end
diff --git a/apple/src/ReturnCode.m b/apple/src/ReturnCode.m
index c2e6c3c..e7ca2ef 100644
--- a/apple/src/ReturnCode.m
+++ b/apple/src/ReturnCode.m
@@ -44,15 +44,15 @@
return _value;
}
-- (BOOL)isSuccess {
+- (BOOL)isValueSuccess {
return (_value == ReturnCodeSuccess);
}
-- (BOOL)isError {
+- (BOOL)isValueError {
return ((_value != ReturnCodeSuccess) && (_value != ReturnCodeCancel));
}
-- (BOOL)isCancel {
+- (BOOL)isValueCancel {
return (_value == ReturnCodeCancel);
}
diff --git a/apple/src/Session.h b/apple/src/Session.h
index 6be9665..980fad3 100644
--- a/apple/src/Session.h
+++ b/apple/src/Session.h
@@ -21,7 +21,6 @@
#define FFMPEG_KIT_SESSION_H
#import
-#import "ExecuteCallback.h"
#import "Log.h"
#import "LogCallback.h"
#import "LogRedirectionStrategy.h"
@@ -35,13 +34,6 @@
@required
-/**
- * Returns the session specific execute callback.
- *
- * @return session specific execute callback
- */
-- (ExecuteCallback)getExecuteCallback;
-
/**
* Returns the session specific log callback.
*
@@ -171,7 +163,7 @@
* that end with SessionStateCompleted state. If a session is not started, still running or failed then
* this method returns nil.
*
- * @return the return code for this session if the session is completed, nil if session is
+ * @return the return code for this session if the session has completed, nil if session is
* not started, still running or failed
*/
- (ReturnCode*)getReturnCode;
@@ -206,6 +198,9 @@
/**
* Adds a new log entry for this session.
*
+ * It is invoked internally by FFmpegKit
library methods. Must not be used by user
+ * applications.
+ *
* @param log log entry
*/
- (void)addLog:(Log*)log;
@@ -243,6 +238,13 @@
*/
- (BOOL)isFFprobe;
+/**
+ * Returns whether it is a MediaInformation
session or not.
+ *
+ * @return true if it is a MediaInformation
session, false otherwise
+ */
+- (BOOL)isMediaInformation;
+
/**
* Cancels running the session.
*/
diff --git a/ios.sh b/ios.sh
index 82ba165..09c5aa1 100755
--- a/ios.sh
+++ b/ios.sh
@@ -16,10 +16,10 @@ export BASEDIR="$(pwd)"
export FFMPEG_KIT_BUILD_TYPE="ios"
source "${BASEDIR}"/scripts/variable.sh
source "${BASEDIR}"/scripts/function-${FFMPEG_KIT_BUILD_TYPE}.sh
+disabled_libraries=()
# SET DEFAULTS SETTINGS
enable_default_ios_architectures
-enable_main_build
# SELECT XCODE VERSION USED FOR BUILDING
XCODE_FOR_FFMPEG_KIT=$(ls ~/.xcode.for.ffmpeg.kit.sh 2>>"${BASEDIR}"/build.log)
@@ -28,7 +28,7 @@ if [[ -f ${XCODE_FOR_FFMPEG_KIT} ]]; then
fi
# DETECT IOS SDK VERSION
-DETECTED_IOS_SDK_VERSION="$(xcrun --sdk iphoneos --show-sdk-version 2>>${BASEDIR}/build.log)"
+export DETECTED_IOS_SDK_VERSION="$(xcrun --sdk iphoneos --show-sdk-version 2>>${BASEDIR}/build.log)"
echo -e "\nINFO: Using SDK ${DETECTED_IOS_SDK_VERSION} by Xcode provided at $(xcode-select -p)\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "INFO: Build options: $*\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -45,6 +45,9 @@ if [[ -z ${BUILD_VERSION} ]]; then
exit 1
fi
+# MAIN BUILDS ENABLED BY DEFAULT
+enable_main_build
+
# PROCESS LTS BUILD OPTION FIRST AND SET BUILD TYPE: MAIN OR LTS
for argument in "$@"; do
if [[ "$argument" == "-l" ]] || [[ "$argument" == "--lts" ]]; then
@@ -113,11 +116,24 @@ while [ ! $# -eq 0 ]; do
--enable-gpl)
GPL_ENABLED="yes"
;;
+ --enable-custom-library-*)
+ CUSTOM_LIBRARY_OPTION_KEY=$(echo $1 | sed -e 's/^--enable-custom-//g;s/=.*$//g')
+ CUSTOM_LIBRARY_OPTION_VALUE=$(echo $1 | sed -e 's/^--enable-custom-.*=//g')
+
+ echo -e "INFO: Custom library options detected: ${CUSTOM_LIBRARY_OPTION_KEY} ${CUSTOM_LIBRARY_OPTION_VALUE}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ generate_custom_library_environment_variables "${CUSTOM_LIBRARY_OPTION_KEY}" "${CUSTOM_LIBRARY_OPTION_VALUE}"
+ ;;
--enable-*)
ENABLED_LIBRARY=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
enable_library "${ENABLED_LIBRARY}"
;;
+ --disable-lib-*)
+ DISABLED_LIB=$(echo $1 | sed -e 's/^--[A-Za-z]*-[A-Za-z]*-//g')
+
+ disabled_libraries+=("${DISABLED_LIB}")
+ ;;
--disable-*)
DISABLED_ARCH=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
@@ -142,7 +158,7 @@ done
# PROCESS FULL OPTION AS LAST OPTION
if [[ -n ${BUILD_FULL} ]]; then
- for library in {0..58}; do
+ for library in {0..61}; do
if [ ${GPL_ENABLED} == "yes" ]; then
enable_library "$(get_library_name "$library")" 1
else
@@ -153,6 +169,11 @@ if [[ -n ${BUILD_FULL} ]]; then
done
fi
+# DISABLE SPECIFIED LIBRARIES
+for disabled_library in ${disabled_libraries[@]}; do
+ set_library "${disabled_library}" 0
+done
+
# IF HELP DISPLAYED EXIT
if [[ -n ${DISPLAY_HELP} ]]; then
display_help
@@ -160,41 +181,35 @@ if [[ -n ${DISPLAY_HELP} ]]; then
fi
# DISABLE NOT SUPPORTED ARCHITECTURES
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARMV7}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARMV7S}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_I386}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64E}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_X86_64_MAC_CATALYST}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_MAC_CATALYST}" "${DETECTED_IOS_SDK_VERSION}"
-disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_SIMULATOR}" "${DETECTED_IOS_SDK_VERSION}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARMV7}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARMV7S}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_I386}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64E}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_X86_64_MAC_CATALYST}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_MAC_CATALYST}"
+disable_ios_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_SIMULATOR}"
# CHECK SOME RULES FOR .framework BUNDLES
-# 1. DISABLE arm64-mac-catalyst WHEN arm64 IS ENABLED IN framework BUNDLES
-if [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_MAC_CATALYST}]} -eq 1 ]]; then
- echo -e "INFO: Disabled arm64-mac-catalyst architecture which can not co-exist with arm64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
+# 1. DISABLE arm64-mac-catalyst IN framework BUNDLES
+if [[ ${NO_FRAMEWORK} -ne 1 ]] && [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_MAC_CATALYST}]} -eq 1 ]]; then
+ echo -e "INFO: Disabled arm64-mac-catalyst architecture which cannot exist in a framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "arm64-mac-catalyst"
fi
-# 2. DISABLE arm64-simulator WHEN arm64 IS ENABLED IN framework BUNDLES
-if [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_SIMULATOR}]} -eq 1 ]]; then
- echo -e "INFO: Disabled arm64-simulator architecture which can not co-exist with arm64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
- disable_arch "arm64-simulator"
+# 2. DISABLE x86-64-mac-catalyst IN framework BUNDLES
+if [[ ${NO_FRAMEWORK} -ne 1 ]] && [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_X86_64_MAC_CATALYST}]} -eq 1 ]]; then
+ echo -e "INFO: Disabled x86-64-mac-catalyst architecture which cannot exist in a framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ disable_arch "x86-64-mac-catalyst"
fi
-# 3. DISABLE arm64-simulator WHEN arm64-mac-catalyst IS ENABLED IN framework BUNDLES
-if [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_MAC_CATALYST}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_SIMULATOR}]} -eq 1 ]]; then
- echo -e "INFO: Disabled arm64-simulator architecture which can not co-exist with arm64-mac-catalyst in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
+# 3. DISABLE arm64-simulator WHEN arm64 IS ENABLED IN framework BUNDLES
+if [[ ${NO_FRAMEWORK} -ne 1 ]] && [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_SIMULATOR}]} -eq 1 ]]; then
+ echo -e "INFO: Disabled arm64-simulator architecture which cannot co-exist with arm64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "arm64-simulator"
fi
-# 4. DISABLE x86-64-mac-catalyst WHEN x86-64 IS ENABLED IN framework BUNDLES
-if [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_X86_64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_X86_64_MAC_CATALYST}]} -eq 1 ]]; then
- echo -e "INFO: Disabled x86-64-mac-catalyst architecture which can not co-exist with x86-64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
- disable_arch "x86-64-mac-catalyst"
-fi
-
-echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}static library for iOS\n"
+echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}shared library for iOS\n"
echo -e -n "INFO: Building ffmpeg-kit ${BUILD_VERSION} ${BUILD_TYPE_ID}for iOS: " 1>>"${BASEDIR}"/build.log 2>&1
echo -e "$(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -204,6 +219,7 @@ print_enabled_libraries
print_reconfigure_requested_libraries
print_rebuild_requested_libraries
print_redownload_requested_libraries
+print_custom_libraries
# VALIDATE GPL FLAGS
for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVIDSTAB,$LIBRARY_RUBBERBAND}; do
@@ -219,13 +235,13 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
done
echo -n -e "\nDownloading sources: "
-echo -e "INFO: Downloading source code of ffmpeg and enabled external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
+echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
# DOWNLOAD GNU CONFIG
download_gnu_config
# DOWNLOAD LIBRARY SOURCES
-downloaded_enabled_library_sources "${ENABLED_LIBRARIES[@]}"
+downloaded_library_sources "${ENABLED_LIBRARIES[@]}"
# THIS WILL SAVE ARCHITECTURES TO BUILD
TARGET_ARCH_LIST=()
@@ -244,7 +260,7 @@ for run_arch in {0..12}; do
TARGET_ARCH_LIST+=("${FULL_ARCH}")
# CLEAR FLAGS
- for library in {0..58}; do
+ for library in {0..61}; do
library_name=$(get_library_name "${library}")
unset "$(echo "OK_${library_name}" | sed "s/\-/\_/g")"
unset "$(echo "DEPENDENCY_REBUILT_${library_name}" | sed "s/\-/\_/g")"
diff --git a/macos.sh b/macos.sh
index 0ebbaf5..dec62c8 100755
--- a/macos.sh
+++ b/macos.sh
@@ -16,10 +16,10 @@ export BASEDIR="$(pwd)"
export FFMPEG_KIT_BUILD_TYPE="macos"
source "${BASEDIR}"/scripts/variable.sh
source "${BASEDIR}"/scripts/function-${FFMPEG_KIT_BUILD_TYPE}.sh
+disabled_libraries=()
# SET DEFAULTS SETTINGS
enable_default_macos_architectures
-enable_main_build
# SELECT XCODE VERSION USED FOR BUILDING
XCODE_FOR_FFMPEG_KIT=$(ls ~/.xcode.for.ffmpeg.kit.sh 2>>"${BASEDIR}"/build.log)
@@ -28,7 +28,7 @@ if [[ -f ${XCODE_FOR_FFMPEG_KIT} ]]; then
fi
# DETECT MACOS SDK VERSION
-DETECTED_MACOS_SDK_VERSION="$(xcrun --sdk macosx --show-sdk-version 2>>${BASEDIR}/build.log)"
+export DETECTED_MACOS_SDK_VERSION="$(xcrun --sdk macosx --show-sdk-version 2>>${BASEDIR}/build.log)"
echo -e "\nINFO: Using SDK ${DETECTED_MACOS_SDK_VERSION} by Xcode provided at $(xcode-select -p)\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "\nINFO: Build options: $*\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -45,6 +45,9 @@ if [[ -z ${BUILD_VERSION} ]]; then
exit 1
fi
+# MAIN BUILDS ENABLED BY DEFAULT
+enable_main_build
+
# PROCESS LTS BUILD OPTION FIRST AND SET BUILD TYPE: MAIN OR LTS
for argument in "$@"; do
if [[ "$argument" == "-l" ]] || [[ "$argument" == "--lts" ]]; then
@@ -113,11 +116,24 @@ while [ ! $# -eq 0 ]; do
--enable-gpl)
GPL_ENABLED="yes"
;;
+ --enable-custom-library-*)
+ CUSTOM_LIBRARY_OPTION_KEY=$(echo $1 | sed -e 's/^--enable-custom-//g;s/=.*$//g')
+ CUSTOM_LIBRARY_OPTION_VALUE=$(echo $1 | sed -e 's/^--enable-custom-.*=//g')
+
+ echo -e "INFO: Custom library options detected: ${CUSTOM_LIBRARY_OPTION_KEY} ${CUSTOM_LIBRARY_OPTION_VALUE}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ generate_custom_library_environment_variables "${CUSTOM_LIBRARY_OPTION_KEY}" "${CUSTOM_LIBRARY_OPTION_VALUE}"
+ ;;
--enable-*)
ENABLED_LIBRARY=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
enable_library "${ENABLED_LIBRARY}"
;;
+ --disable-lib-*)
+ DISABLED_LIB=$(echo $1 | sed -e 's/^--[A-Za-z]*-[A-Za-z]*-//g')
+
+ disabled_libraries+=("${DISABLED_LIB}")
+ ;;
--disable-*)
DISABLED_ARCH=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
@@ -137,7 +153,7 @@ done
# PROCESS FULL OPTION AS LAST OPTION
if [[ -n ${BUILD_FULL} ]]; then
- for library in {0..58}; do
+ for library in {0..61}; do
if [ ${GPL_ENABLED} == "yes" ]; then
enable_library "$(get_library_name "$library")" 1
else
@@ -148,6 +164,11 @@ if [[ -n ${BUILD_FULL} ]]; then
done
fi
+# DISABLE SPECIFIED LIBRARIES
+for disabled_library in ${disabled_libraries[@]}; do
+ set_library "${disabled_library}" 0
+done
+
# IF HELP DISPLAYED EXIT
if [[ -n ${DISPLAY_HELP} ]]; then
display_help
@@ -155,9 +176,9 @@ if [[ -n ${DISPLAY_HELP} ]]; then
fi
# DISABLE NOT SUPPORTED ARCHITECTURES
-disable_macos_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64}" "${DETECTED_MACOS_SDK_VERSION}"
+disable_macos_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64}"
-echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}static library for macOS\n"
+echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}shared library for macOS\n"
echo -e -n "INFO: Building ffmpeg-kit ${BUILD_VERSION} ${BUILD_TYPE_ID}for macOS: " 1>>"${BASEDIR}"/build.log 2>&1
echo -e "$(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -167,6 +188,7 @@ print_enabled_libraries
print_reconfigure_requested_libraries
print_rebuild_requested_libraries
print_redownload_requested_libraries
+print_custom_libraries
# VALIDATE GPL FLAGS
for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVIDSTAB,$LIBRARY_RUBBERBAND}; do
@@ -182,13 +204,13 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
done
echo -n -e "\nDownloading sources: "
-echo -e "INFO: Downloading source code of ffmpeg and enabled external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
+echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
# DOWNLOAD GNU CONFIG
download_gnu_config
# DOWNLOAD LIBRARY SOURCES
-downloaded_enabled_library_sources "${ENABLED_LIBRARIES[@]}"
+downloaded_library_sources "${ENABLED_LIBRARIES[@]}"
# THIS WILL SAVE ARCHITECTURES TO BUILD
TARGET_ARCH_LIST=()
@@ -207,7 +229,7 @@ for run_arch in {0..12}; do
TARGET_ARCH_LIST+=("${FULL_ARCH}")
# CLEAR FLAGS
- for library in {0..58}; do
+ for library in {0..61}; do
library_name=$(get_library_name "${library}")
unset "$(echo "OK_${library_name}" | sed "s/\-/\_/g")"
unset "$(echo "DEPENDENCY_REBUILT_${library_name}" | sed "s/\-/\_/g")"
diff --git a/scripts/android/chromaprint.sh b/scripts/android/chromaprint.sh
index 52e0972..947ab55 100755
--- a/scripts/android/chromaprint.sh
+++ b/scripts/android/chromaprint.sh
@@ -14,17 +14,20 @@ cmake -Wno-dev \
-DCMAKE_INSTALL_PREFIX="${LIB_INSTALL_PREFIX}" \
-DCMAKE_SYSTEM_NAME=Generic \
-DCMAKE_C_COMPILER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$CC" \
+ -DCMAKE_CXX_COMPILER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$CXX" \
-DCMAKE_LINKER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$LD" \
-DCMAKE_AR="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AR" \
-DCMAKE_AS="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AS" \
-DCMAKE_SYSTEM_PROCESSOR=$(get_cmake_system_processor) \
-DCMAKE_POSITION_INDEPENDENT_CODE=1 \
-DFFT_LIB=kissfft \
- -DBUILD_SHARED_LIBS=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
+ -DKISSFFT_SOURCE_DIR="${BASEDIR}"/src/"${LIB_NAME}"/src/3rdparty/kissfft \
+ -DBUILD_SHARED_LIBS=0 \
+ -DBUILD_TESTS=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_chromaprint_package_config "1.5.0" || return 1
+create_chromaprint_package_config "1.5.1" || return 1
diff --git a/scripts/android/expat.sh b/scripts/android/expat.sh
index 71d1989..6cf67d4 100755
--- a/scripts/android/expat.sh
+++ b/scripts/android/expat.sh
@@ -7,7 +7,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/configure ]] || [[ ${RECONF_expat} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/ffmpeg.sh b/scripts/android/ffmpeg.sh
index 1ee0277..7b6d2d7 100755
--- a/scripts/android/ffmpeg.sh
+++ b/scripts/android/ffmpeg.sh
@@ -6,9 +6,6 @@ if [ -z "${HOST_PKG_CONFIG_PATH}" ]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
LIB_NAME="ffmpeg"
echo -e "----------------------------------------------------------------" 1>>"${BASEDIR}"/build.log 2>&1
@@ -32,7 +29,7 @@ export CXXFLAGS=$(get_cxxflags "${LIB_NAME}")
export LDFLAGS=$(get_ldflags "${LIB_NAME}")
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
-cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# SET BUILD OPTIONS
TARGET_CPU=""
@@ -72,9 +69,9 @@ CONFIGURE_POSTFIX=""
HIGH_PRIORITY_INCLUDES=""
# SET CONFIGURE OPTIONS
-for library in {1..58}; do
- if [[ ${!library} -eq 1 ]]; then
- ENABLED_LIBRARY=$(get_library_name $((library - 1)))
+for library in {0..61}; do
+ if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
+ ENABLED_LIBRARY=$(get_library_name ${library})
echo -e "INFO: Enabling library ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -161,7 +158,7 @@ for library in {1..58}; do
libvidstab)
CFLAGS+=" $(pkg-config --cflags vidstab 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static vidstab 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libvidstab --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libvidstab"
;;
libvorbis)
CFLAGS+=" $(pkg-config --cflags vorbis 2>>"${BASEDIR}"/build.log)"
@@ -194,6 +191,11 @@ for library in {1..58}; do
LDFLAGS+=" $(pkg-config --libs --static openh264 2>>"${BASEDIR}"/build.log)"
CONFIGURE_POSTFIX+=" --enable-libopenh264"
;;
+ openssl)
+ CFLAGS+=" $(pkg-config --cflags openssl 2>>"${BASEDIR}"/build.log)"
+ LDFLAGS+=" $(pkg-config --libs --static openssl 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-openssl"
+ ;;
opus)
CFLAGS+=" $(pkg-config --cflags opus 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static opus 2>>"${BASEDIR}"/build.log)"
@@ -202,7 +204,7 @@ for library in {1..58}; do
rubberband)
CFLAGS+=" $(pkg-config --cflags rubberband 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static rubberband 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-librubberband --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-librubberband"
;;
sdl)
CFLAGS+=" $(pkg-config --cflags sdl2 2>>"${BASEDIR}"/build.log)"
@@ -229,6 +231,11 @@ for library in {1..58}; do
LDFLAGS+=" $(pkg-config --libs --static speex 2>>"${BASEDIR}"/build.log)"
CONFIGURE_POSTFIX+=" --enable-libspeex"
;;
+ srt)
+ CFLAGS+=" $(pkg-config --cflags srt 2>>"${BASEDIR}"/build.log)"
+ LDFLAGS+=" $(pkg-config --libs --static srt 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-libsrt"
+ ;;
tesseract)
CFLAGS+=" $(pkg-config --cflags tesseract 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static tesseract 2>>"${BASEDIR}"/build.log)"
@@ -249,17 +256,22 @@ for library in {1..58}; do
x264)
CFLAGS+=" $(pkg-config --cflags x264 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static x264 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libx264 --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libx264"
;;
x265)
CFLAGS+=" $(pkg-config --cflags x265 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static x265 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libx265 --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libx265"
;;
xvidcore)
CFLAGS+=" $(pkg-config --cflags xvidcore 2>>"${BASEDIR}"/build.log)"
LDFLAGS+=" $(pkg-config --libs --static xvidcore 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libxvid --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libxvid"
+ ;;
+ zimg)
+ CFLAGS+=" $(pkg-config --cflags zimg 2>>"${BASEDIR}"/build.log)"
+ LDFLAGS+=" $(pkg-config --libs --static zimg 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-libzimg"
;;
expat)
CFLAGS+=" $(pkg-config --cflags expat 2>>"${BASEDIR}"/build.log)"
@@ -296,16 +308,36 @@ for library in {1..58}; do
# THE FOLLOWING LIBRARIES SHOULD BE EXPLICITLY DISABLED TO PREVENT AUTODETECT
# NOTE THAT IDS MUST BE +1 OF THE INDEX VALUE
- if [[ ${library} -eq $((LIBRARY_SDL + 1)) ]]; then
+ if [[ ${library} -eq ${LIBRARY_SDL} ]]; then
CONFIGURE_POSTFIX+=" --disable-sdl2"
- elif [[ ${library} -eq $((LIBRARY_ANDROID_ZLIB + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_ANDROID_ZLIB} ]]; then
CONFIGURE_POSTFIX+=" --disable-zlib"
- elif [[ ${library} -eq $((LIBRARY_ANDROID_MEDIA_CODEC + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_ANDROID_MEDIA_CODEC} ]]; then
CONFIGURE_POSTFIX+=" --disable-mediacodec"
+ elif [[ ${library} -eq ${LIBRARY_OPENSSL} ]]; then
+ CONFIGURE_POSTFIX+=" --disable-openssl"
fi
fi
done
+# SET CONFIGURE OPTIONS FOR CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+ pc_file_name="CUSTOM_LIBRARY_${custom_library_index}_PACKAGE_CONFIG_FILE_NAME"
+ ffmpeg_flag_name="CUSTOM_LIBRARY_${custom_library_index}_FFMPEG_ENABLE_FLAG"
+
+ echo -e "INFO: Enabling custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ CFLAGS+=" $(pkg-config --cflags ${!pc_file_name} 2>>"${BASEDIR}"/build.log)"
+ LDFLAGS+=" $(pkg-config --libs --static ${!pc_file_name} 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-${!ffmpeg_flag_name}"
+done
+
+# SET ENABLE GPL FLAG WHEN REQUESTED
+if [ "$GPL_ENABLED" == "yes" ]; then
+ CONFIGURE_POSTFIX+=" --enable-gpl"
+fi
+
export LDFLAGS+=" -L${ANDROID_NDK_ROOT}/platforms/android-${API}/arch-${TOOLCHAIN_ARCH}/usr/lib"
# LINKING WITH ANDROID LTS SUPPORT LIBRARY IS NECESSARY FOR API < 18
@@ -341,6 +373,13 @@ echo -n -e "\n${LIB_NAME}: "
if [[ -z ${NO_WORKSPACE_CLEANUP_ffmpeg} ]]; then
echo -e "INFO: Cleaning workspace for ${LIB_NAME}\n" 1>>"${BASEDIR}"/build.log 2>&1
make distclean 2>/dev/null 1>/dev/null
+
+ # WORKAROUND TO MANUALLY DELETE UNCLEANED FILES
+ rm -f "${BASEDIR}"/src/"${LIB_NAME}"/libavfilter/opencl/*.o 1>>"${BASEDIR}"/build.log 2>&1
+ rm -f "${BASEDIR}"/src/"${LIB_NAME}"/libavcodec/neon/*.o 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DELETE SHARED FRAMEWORK WORKAROUNDS
+ git checkout "${BASEDIR}/src/ffmpeg/ffbuild" 1>>"${BASEDIR}"/build.log 2>&1
fi
# UPDATE BUILD FLAGS
@@ -350,19 +389,19 @@ export CFLAGS="${HIGH_PRIORITY_INCLUDES} ${CFLAGS}"
ulimit -n 2048 1>>"${BASEDIR}"/build.log 2>&1
########################### CUSTOMIZATIONS #######################
-cd "${BASEDIR}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+cd "${BASEDIR}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
git checkout android/ffmpeg-kit-android-lib/src/main/cpp/ffmpegkit.c 1>>"${BASEDIR}"/build.log 2>&1
-cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
git checkout libavformat/file.c 1>>"${BASEDIR}"/build.log 2>&1
git checkout libavformat/protocols.c 1>>"${BASEDIR}"/build.log 2>&1
git checkout libavutil 1>>"${BASEDIR}"/build.log 2>&1
# 1. Use thread local log levels
-${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR}"/src/"${LIB_NAME}"/libavutil/log.c 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR}"/src/"${LIB_NAME}"/libavutil/log.c 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# 2. Set friendly ffmpeg version
FFMPEG_VERSION="v$(get_user_friendly_ffmpeg_version)"
-${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffbuild/version.sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffbuild/version.sh 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# 3. Enable ffmpeg-kit protocols
if [[ ${NO_FFMPEG_KIT_PROTOCOLS} == "1" ]]; then
@@ -373,7 +412,7 @@ else
cat ../../tools/protocols/libavutil_file.h >> libavutil/file.h
cat ../../tools/protocols/libavutil_file.c >> libavutil/file.c
awk '{gsub(/ff_file_protocol;/,"ff_file_protocol;\nextern const URLProtocol ff_saf_protocol;")}1' libavformat/protocols.c > libavformat/protocols.c.tmp
- awk '{gsub(/ff_file_protocol;/,"ff_file_protocol;\nextern const URLProtocol ff_fd_protocol;")}1' libavformat/protocols.c.tmp > libavformat/protocols.c
+ cat libavformat/protocols.c.tmp > libavformat/protocols.c
echo -e "\nINFO: Enabled custom ffmpeg-kit protocols\n" 1>>"${BASEDIR}"/build.log 2>&1
fi
@@ -387,25 +426,27 @@ fi
--enable-version3 \
--arch="${TARGET_ARCH}" \
--cpu="${TARGET_CPU}" \
+ --target-os=android \
+ ${ASM_OPTIONS} \
+ --ar="${AR}" \
--cc="${CC}" \
--cxx="${CXX}" \
--ranlib="${RANLIB}" \
--strip="${STRIP}" \
--nm="${NM}" \
--extra-libs="$(pkg-config --libs --static cpu-features)" \
- --target-os=android \
- ${ASM_OPTIONS} \
+ --disable-autodetect \
--enable-cross-compile \
--enable-pic \
--enable-jni \
--enable-optimizations \
--enable-swscale \
${BUILD_LIBRARY_OPTIONS} \
+ --enable-pthreads \
--enable-v4l2-m2m \
--disable-outdev=fbdev \
--disable-indev=fbdev \
${SIZE_OPTIONS} \
- --disable-openssl \
--disable-xmm-clobber-test \
${DEBUG_OPTIONS} \
--disable-neon-clobber-test \
@@ -462,7 +503,7 @@ fi
# DELETE THE PREVIOUS BUILD OF THE LIBRARY BEFORE INSTALLING
if [ -d "${FFMPEG_LIBRARY_PATH}" ]; then
- rm -rf "${FFMPEG_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ rm -rf "${FFMPEG_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
make install 1>>"${BASEDIR}"/build.log 2>&1
diff --git a/scripts/android/fontconfig.sh b/scripts/android/fontconfig.sh
index 0b9237f..c490f35 100755
--- a/scripts/android/fontconfig.sh
+++ b/scripts/android/fontconfig.sh
@@ -3,16 +3,19 @@
# ALWAYS CLEAN THE PREVIOUS BUILD
make distclean 2>/dev/null 1>/dev/null
+# WORKAROUND FOR "bad flag in substitute command"
+${SED_INLINE} "s|in \"\$default_fonts\"|in \$default_fonts|g" "${BASEDIR}"/src/"${LIB_NAME}"/configure.ac 1>>"${BASEDIR}"/build.log 2>&1
+
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_fontconfig} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# WORKAROUND TO FIX NOT-APPLIED HAVE_POSIX_FADVISE define ON MACOS
if [[ -n ${FFMPEG_KIT_LTS_BUILD} ]]; then
- ${SED_INLINE} "s/(HAVE_POSIX_FADVISE)/(NO_HAVE_POSIX_FADVISE)/g" "${BASEDIR}"/src/"${LIB_NAME}"/src/fccache.c 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ ${SED_INLINE} "s/(HAVE_POSIX_FADVISE)/(NO_HAVE_POSIX_FADVISE)/g" "${BASEDIR}"/src/"${LIB_NAME}"/src/fccache.c 1>>"${BASEDIR}"/build.log 2>&1 || return 1
else
- ${SED_INLINE} "s/NO_HAVE_POSIX_FADVISE/HAVE_POSIX_FADVISE/g" "${BASEDIR}"/src/"${LIB_NAME}"/src/fccache.c 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ ${SED_INLINE} "s/NO_HAVE_POSIX_FADVISE/HAVE_POSIX_FADVISE/g" "${BASEDIR}"/src/"${LIB_NAME}"/src/fccache.c 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
@@ -34,4 +37,4 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_fontconfig_package_config "2.13.93" || return 1
+create_fontconfig_package_config "2.13.94" || return 1
diff --git a/scripts/android/freetype.sh b/scripts/android/freetype.sh
index e455dfd..03943f0 100755
--- a/scripts/android/freetype.sh
+++ b/scripts/android/freetype.sh
@@ -37,4 +37,4 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_freetype_package_config "24.0.18" || return 1
+create_freetype_package_config "24.1.18" || return 1
diff --git a/scripts/android/fribidi.sh b/scripts/android/fribidi.sh
index 9d5f9bb..ed5bd88 100755
--- a/scripts/android/fribidi.sh
+++ b/scripts/android/fribidi.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_fribidi} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/giflib.sh b/scripts/android/giflib.sh
index d7c47ba..ce75034 100755
--- a/scripts/android/giflib.sh
+++ b/scripts/android/giflib.sh
@@ -8,7 +8,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_giflib} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/gmp.sh b/scripts/android/gmp.sh
index 7967177..3cfc749 100755
--- a/scripts/android/gmp.sh
+++ b/scripts/android/gmp.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_gmp} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/kvazaar.sh b/scripts/android/kvazaar.sh
index a8be508..f668c43 100755
--- a/scripts/android/kvazaar.sh
+++ b/scripts/android/kvazaar.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_kvazaar} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# UPDATE BUILD FLAGS
diff --git a/scripts/android/lame.sh b/scripts/android/lame.sh
index f2b9b04..35b896a 100755
--- a/scripts/android/lame.sh
+++ b/scripts/android/lame.sh
@@ -7,7 +7,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_lame} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/leptonica.sh b/scripts/android/leptonica.sh
index df10530..95301b0 100755
--- a/scripts/android/leptonica.sh
+++ b/scripts/android/leptonica.sh
@@ -23,7 +23,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_leptonica} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libaom.sh b/scripts/android/libaom.sh
index ae5a4d0..6078f97 100755
--- a/scripts/android/libaom.sh
+++ b/scripts/android/libaom.sh
@@ -56,4 +56,4 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_libaom_package_config "3.1.2" || return 1
+create_libaom_package_config "3.2.0" || return 1
diff --git a/scripts/android/libass.sh b/scripts/android/libass.sh
index c11b433..648d589 100755
--- a/scripts/android/libass.sh
+++ b/scripts/android/libass.sh
@@ -19,7 +19,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libass} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libiconv.sh b/scripts/android/libiconv.sh
index a81cfc0..a4dd556 100755
--- a/scripts/android/libiconv.sh
+++ b/scripts/android/libiconv.sh
@@ -8,7 +8,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libiconv} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libilbc.sh b/scripts/android/libilbc.sh
index 40e44a6..c2c14ef 100755
--- a/scripts/android/libilbc.sh
+++ b/scripts/android/libilbc.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libilbc} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libogg.sh b/scripts/android/libogg.sh
index f327ad0..c44ff2b 100755
--- a/scripts/android/libogg.sh
+++ b/scripts/android/libogg.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libogg} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libpng.sh b/scripts/android/libpng.sh
index 8d20888..af42569 100755
--- a/scripts/android/libpng.sh
+++ b/scripts/android/libpng.sh
@@ -22,7 +22,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libpng} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libsamplerate.sh b/scripts/android/libsamplerate.sh
index 55210f3..f527814 100755
--- a/scripts/android/libsamplerate.sh
+++ b/scripts/android/libsamplerate.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libsamplerate} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libsndfile.sh b/scripts/android/libsndfile.sh
index 573093c..9fa645e 100755
--- a/scripts/android/libsndfile.sh
+++ b/scripts/android/libsndfile.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libsndfile} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libuuid.sh b/scripts/android/libuuid.sh
index b395818..ad5c983 100755
--- a/scripts/android/libuuid.sh
+++ b/scripts/android/libuuid.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libuuid} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libvidstab.sh b/scripts/android/libvidstab.sh
index b82c06c..8803af9 100755
--- a/scripts/android/libvidstab.sh
+++ b/scripts/android/libvidstab.sh
@@ -15,7 +15,7 @@ mkdir -p "${BUILD_DIR}" || return 1
cd "${BUILD_DIR}" || return 1
# WORKAROUND TO DETECT ASM FLAGS PROPERLY
-${SED_INLINE} 's/ ${CPUINFO}/ "${CPUINFO}"/g' "${BASEDIR}"/src/"${LIB_NAME}"/CMakeModules/FindSSE.cmake 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} 's/ ${CPUINFO}/ "${CPUINFO}"/g' "${BASEDIR}"/src/"${LIB_NAME}"/CMakeModules/FindSSE.cmake 1>>"${BASEDIR}"/build.log 2>&1 || return 1
cmake -Wno-dev \
-DCMAKE_VERBOSE_MAKEFILE=0 \
diff --git a/scripts/android/libvorbis.sh b/scripts/android/libvorbis.sh
index 1b31497..4e6c8fd 100755
--- a/scripts/android/libvorbis.sh
+++ b/scripts/android/libvorbis.sh
@@ -9,7 +9,7 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libvorbis}
# -mno-ieee-fp OPTION IS NOT COMPATIBLE WITH clang. REMOVING IT
${SED_INLINE} 's/\-mno-ieee-fp//g' "${BASEDIR}"/src/"${LIB_NAME}"/configure.ac || return 1
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
PKG_CONFIG= ./configure \
diff --git a/scripts/android/libwebp.sh b/scripts/android/libwebp.sh
index f4b5a24..0df1311 100755
--- a/scripts/android/libwebp.sh
+++ b/scripts/android/libwebp.sh
@@ -19,7 +19,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libwebp} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/libxml2.sh b/scripts/android/libxml2.sh
index 62650b2..eaa497c 100755
--- a/scripts/android/libxml2.sh
+++ b/scripts/android/libxml2.sh
@@ -11,7 +11,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libxml2} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/nettle.sh b/scripts/android/nettle.sh
index a083552..8461116 100755
--- a/scripts/android/nettle.sh
+++ b/scripts/android/nettle.sh
@@ -20,7 +20,7 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_nettle} -e
# WORKAROUND TO FIX BUILD SYSTEM COMPILER ON macOS
overwrite_file "${BASEDIR}"/tools/patch/make/nettle/aclocal.m4 "${BASEDIR}"/src/"${LIB_NAME}"/aclocal.m4
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/opencore-amr.sh b/scripts/android/opencore-amr.sh
index 8d1d55b..99fe14a 100755
--- a/scripts/android/opencore-amr.sh
+++ b/scripts/android/opencore-amr.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_opencore_amr} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/openssl.sh b/scripts/android/openssl.sh
new file mode 100644
index 0000000..76eb706
--- /dev/null
+++ b/scripts/android/openssl.sh
@@ -0,0 +1,54 @@
+#!/bin/bash
+
+if [[ ${ARCH} == "x86" ]]; then
+
+ # openssl does not support 32-bit apple architectures
+ echo -e "ERROR: openssl is not supported on $ARCH architecture for $FFMPEG_KIT_BUILD_TYPE platform.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ return 200
+fi
+
+# SET BUILD OPTIONS
+ASM_OPTIONS=""
+case ${ARCH} in
+arm-v7a | arm-v7a-neon)
+ ASM_OPTIONS="linux-generic32"
+ ;;
+arm64-v8a)
+ ASM_OPTIONS="linux-generic64 enable-ec_nistp_64_gcc_128"
+ ;;
+x86)
+ ASM_OPTIONS="linux-generic32 386"
+ ;;
+x86-64)
+ ASM_OPTIONS="linux-generic64 enable-ec_nistp_64_gcc_128"
+ ;;
+esac
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+make distclean 2>/dev/null 1>/dev/null
+
+# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
+if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_openssl} -eq 1 ]]; then
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+fi
+
+INT128_AVAILABLE=$($CC -dM -E - >"${BASEDIR}"/build.log | grep __SIZEOF_INT128__)
+
+echo -e "INFO: __uint128_t detection output: $INT128_AVAILABLE\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+./Configure \
+ --prefix="${LIB_INSTALL_PREFIX}" \
+ zlib \
+ no-shared \
+ no-engine \
+ no-dso \
+ no-legacy \
+ ${ASM_OPTIONS} \
+ no-tests || return 1
+
+make -j$(get_cpu_count) build_sw || return 1
+
+make install_sw install_ssldirs || return 1
+
+# MANUALLY COPY PKG-CONFIG FILES
+cp ./*.pc "${INSTALL_PKG_CONFIG_DIR}" || return 1
diff --git a/scripts/android/opus.sh b/scripts/android/opus.sh
index 92720cd..ea1d22f 100755
--- a/scripts/android/opus.sh
+++ b/scripts/android/opus.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_opus} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/rubberband.sh b/scripts/android/rubberband.sh
index b17ac13..77040ce 100755
--- a/scripts/android/rubberband.sh
+++ b/scripts/android/rubberband.sh
@@ -12,7 +12,7 @@ overwrite_file "${BASEDIR}"/tools/patch/make/rubberband/rubberband.pc.in "${BASE
${SED_INLINE} 's/%DEPENDENCIES%/sndfile, samplerate/g' "${BASEDIR}"/src/"${LIB_NAME}"/rubberband.pc.in || return 1
# ALWAYS REGENERATE BUILD FILES - NECESSARY TO APPLY THE WORKAROUNDS
-autoreconf_library "${LIB_NAME}"
+autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
./configure \
--prefix="${LIB_INSTALL_PREFIX}" \
diff --git a/scripts/android/sdl.sh b/scripts/android/sdl.sh
index c71bb1f..6022ab1 100755
--- a/scripts/android/sdl.sh
+++ b/scripts/android/sdl.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_sdl} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/shine.sh b/scripts/android/shine.sh
index 33153f9..7b0087c 100755
--- a/scripts/android/shine.sh
+++ b/scripts/android/shine.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_shine} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/speex.sh b/scripts/android/speex.sh
index a90a17f..8c60cc3 100755
--- a/scripts/android/speex.sh
+++ b/scripts/android/speex.sh
@@ -13,7 +13,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_soxr} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/srt.sh b/scripts/android/srt.sh
new file mode 100644
index 0000000..b12bdca
--- /dev/null
+++ b/scripts/android/srt.sh
@@ -0,0 +1,62 @@
+#!/bin/bash
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+git clean -dfx 2>/dev/null 1>/dev/null
+
+# OVERRIDE SYSTEM PROCESSOR
+SYSTEM_PROCESSOR=""
+case ${ARCH} in
+arm-v7a | arm-v7a-neon)
+ SYSTEM_PROCESSOR="armv7-a"
+ ;;
+arm64-v8a)
+ SYSTEM_PROCESSOR="aarch64"
+ ;;
+x86)
+ SYSTEM_PROCESSOR="i686"
+ ;;
+x86-64)
+ SYSTEM_PROCESSOR="x86_64"
+ ;;
+esac
+
+# WORKAROUND TO GENERATE BASE BUILD FILES
+./configure || echo "" 2>/dev/null 1>/dev/null
+
+cmake -Wno-dev \
+ -DUSE_ENCLIB=openssl \
+ -DCMAKE_VERBOSE_MAKEFILE=0 \
+ -DCMAKE_C_FLAGS="${CFLAGS}" \
+ -DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
+ -DCMAKE_EXE_LINKER_FLAGS="${LDFLAGS}" \
+ -DCMAKE_SYSROOT="${ANDROID_SYSROOT}" \
+ -DCMAKE_FIND_ROOT_PATH="${ANDROID_SYSROOT}" \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_INSTALL_PREFIX="${LIB_INSTALL_PREFIX}" \
+ -DCMAKE_SYSTEM_NAME=Android \
+ -DCMAKE_SYSTEM_VERSION=${API} \
+ -DCMAKE_ANDROID_NDK=${ANDROID_NDK_ROOT} \
+ -DCMAKE_CXX_COMPILER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$CXX" \
+ -DCMAKE_C_COMPILER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$CC" \
+ -DCMAKE_LINKER="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$LD" \
+ -DCMAKE_AR="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AR" \
+ -DCMAKE_AS="${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/${TOOLCHAIN}/bin/$AS" \
+ -DCMAKE_SYSTEM_LOADED=1 \
+ -DCMAKE_SYSTEM_PROCESSOR="${SYSTEM_PROCESSOR}" \
+ -DENABLE_STDCXX_SYNC=1 \
+ -DENABLE_MONOTONIC_CLOCK=1 \
+ -DENABLE_STDCXX_SYNC=1 \
+ -DENABLE_CXX11=1 \
+ -DUSE_OPENSSL_PC=1 \
+ -DENABLE_DEBUG=0 \
+ -DENABLE_LOGGING=0 \
+ -DENABLE_HEAVY_LOGGING=0 \
+ -DENABLE_APPS=0 \
+ -DENABLE_SHARED=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
+
+make -j$(get_cpu_count) || return 1
+
+make install || return 1
+
+# CREATE PACKAGE CONFIG MANUALLY
+create_srt_package_config "1.4.4" || return 1
\ No newline at end of file
diff --git a/scripts/android/tesseract.sh b/scripts/android/tesseract.sh
index a491efd..a99ec0f 100755
--- a/scripts/android/tesseract.sh
+++ b/scripts/android/tesseract.sh
@@ -9,7 +9,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_tesseract} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# WORKAROUND TO MANUALLY SET ENDIANNESS
diff --git a/scripts/android/tiff.sh b/scripts/android/tiff.sh
index 36d9390..b484450 100755
--- a/scripts/android/tiff.sh
+++ b/scripts/android/tiff.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_tiff} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/vo-amrwbenc.sh b/scripts/android/vo-amrwbenc.sh
index 763dea5..914a793 100755
--- a/scripts/android/vo-amrwbenc.sh
+++ b/scripts/android/vo-amrwbenc.sh
@@ -13,7 +13,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_vo_amrwbenc} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/x264.sh b/scripts/android/x264.sh
index 0ae23a3..7115e2a 100755
--- a/scripts/android/x264.sh
+++ b/scripts/android/x264.sh
@@ -28,7 +28,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_x264} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/android/x265.sh b/scripts/android/x265.sh
index 9c31ac8..937fa5a 100755
--- a/scripts/android/x265.sh
+++ b/scripts/android/x265.sh
@@ -42,6 +42,7 @@ cmake -Wno-dev \
-DSTATIC_LINK_CRT=1 \
-DENABLE_PIC=1 \
-DENABLE_CLI=0 \
+ -DHIGH_BIT_DEPTH=1 \
${ASM_OPTIONS} \
-DCMAKE_SYSTEM_PROCESSOR="${ARCH}" \
-DENABLE_SHARED=0 "${BASEDIR}"/src/"${LIB_NAME}"/source || return 1
diff --git a/scripts/android/zimg.sh b/scripts/android/zimg.sh
new file mode 100644
index 0000000..97b71b1
--- /dev/null
+++ b/scripts/android/zimg.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+make distclean 2>/dev/null 1>/dev/null
+
+# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
+if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_zimg} -eq 1 ]]; then
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+fi
+
+./configure \
+ --prefix="${LIB_INSTALL_PREFIX}" \
+ --with-pic \
+ --with-sysroot="${SDK_PATH}" \
+ --enable-static \
+ --disable-shared \
+ --disable-fast-install \
+ --host="${HOST}" || return 1
+
+make -j$(get_cpu_count) || return 1
+
+make install || return 1
+
+# CREATE PACKAGE CONFIG MANUALLY
+create_zimg_package_config "3.0.3" || return 1
diff --git a/scripts/apple/chromaprint.sh b/scripts/apple/chromaprint.sh
index 808275d..9ecb96f 100755
--- a/scripts/apple/chromaprint.sh
+++ b/scripts/apple/chromaprint.sh
@@ -15,14 +15,16 @@ cmake -Wno-dev \
-DCMAKE_SYSTEM_NAME="${CMAKE_SYSTEM_NAME}" \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX="${LIB_INSTALL_PREFIX}" \
+ -DCMAKE_CXX_COMPILER="$CXX" \
-DCMAKE_C_COMPILER="$CC" \
-DCMAKE_LINKER="$LD" \
-DCMAKE_AR="$(xcrun --sdk "$(get_sdk_name)" -f ar)" \
-DCMAKE_AS="$AS" \
-DFFT_LIB=kissfft \
- -DKISSFFT_SOURCE_DIR="${BASEDIR}"/src/"${LIB_NAME}"/vendor/kissfft \
+ -DKISSFFT_SOURCE_DIR="${BASEDIR}"/src/"${LIB_NAME}"/src/3rdparty/kissfft \
-DCMAKE_SYSTEM_PROCESSOR="$(get_target_cpu)" \
- -DBUILD_SHARED_LIBS=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
+ -DBUILD_SHARED_LIBS=0 \
+ -DBUILD_TESTS=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
make -j$(get_cpu_count) || return 1
diff --git a/scripts/apple/expat.sh b/scripts/apple/expat.sh
index add98e4..3d97a82 100755
--- a/scripts/apple/expat.sh
+++ b/scripts/apple/expat.sh
@@ -7,7 +7,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/configure ]] || [[ ${RECONF_expat} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/ffmpeg-kit.sh b/scripts/apple/ffmpeg-kit.sh
index 576663b..96af136 100755
--- a/scripts/apple/ffmpeg-kit.sh
+++ b/scripts/apple/ffmpeg-kit.sh
@@ -1,7 +1,7 @@
#!/bin/bash
# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || return 1
LIB_NAME="ffmpeg-kit"
@@ -22,13 +22,13 @@ set_toolchain_paths "${LIB_NAME}"
HOST=$(get_host)
export CFLAGS="$(get_cflags ${LIB_NAME}) -I${LIB_INSTALL_BASE}/ffmpeg/include"
export CXXFLAGS=$(get_cxxflags ${LIB_NAME})
-export LDFLAGS="$(get_ldflags ${LIB_NAME}) -L${LIB_INSTALL_BASE}/ffmpeg/lib -framework Foundation -framework CoreVideo -lavdevice"
+export LDFLAGS="$(get_ldflags ${LIB_NAME}) -F${LIB_INSTALL_BASE}/ffmpeg/framework -framework Foundation -framework CoreVideo -framework libavdevice"
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
-cd "${BASEDIR}"/apple 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+cd "${BASEDIR}"/apple 1>>"${BASEDIR}"/build.log 2>&1 || return 1
-# ALWAYS BUILD STATIC LIBRARIES
-BUILD_LIBRARY_OPTIONS="--enable-static --disable-shared"
+# ALWAYS BUILD SHARED LIBRARIES
+BUILD_LIBRARY_OPTIONS="--enable-shared --disable-static"
echo -n -e "\n${LIB_NAME}: "
@@ -36,22 +36,27 @@ make distclean 2>/dev/null 1>/dev/null
rm -f "${BASEDIR}"/apple/src/libffmpegkit* 1>>"${BASEDIR}"/build.log 2>&1
-# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
-if [[ ! -f "${BASEDIR}"/apple/configure ]] || [[ ${RECONF_ffmpeg_kit} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}" || exit 1
-fi
-
# CHECK IF VIDEOTOOLBOX IS ENABLED
VIDEOTOOLBOX_SUPPORT_FLAG=""
if [[ ${ENABLED_LIBRARIES[$LIBRARY_APPLE_VIDEOTOOLBOX]} -eq 1 ]]; then
VIDEOTOOLBOX_SUPPORT_FLAG="--enable-videotoolbox"
fi
-# REMOVE OPTIONS FROM CONFIGURE TO FIX THE FOLLOWING ERROR
-# ld: -flat_namespace and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
-${SED_INLINE} 's/$wl-flat_namespace //g' configure 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-${SED_INLINE} 's/$wl-undefined //g' configure 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-${SED_INLINE} 's/${wl}suppress//g' configure 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+# ALWAYS REGENERATE BUILD FILES - NECESSARY TO APPLY THE WORKAROUNDS
+autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+
+# WORKAROUNDS
+if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
+
+ # REMOVE OPTIONS FROM CONFIGURE TO FIX THE FOLLOWING ERROR
+ # ld: -flat_namespace and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
+ ${SED_INLINE} 's/$wl-flat_namespace //g' configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ ${SED_INLINE} 's/$wl-undefined //g' configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ ${SED_INLINE} 's/${wl}suppress//g' configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+
+ # ld: file not found: dynamic_lookup
+ ${SED_INLINE} 's/${wl}dynamic_lookup//g' configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+fi
./configure \
--prefix="${FFMPEG_KIT_LIBRARY_PATH}" \
@@ -63,6 +68,10 @@ ${SED_INLINE} 's/${wl}suppress//g' configure 1>>"${BASEDIR}"/build.log 2>&1 || e
--disable-maintainer-mode \
--host="${HOST}" 1>>"${BASEDIR}"/build.log 2>&1
+# WORKAROUND FOR clang: warning: using sysroot for 'MacOSX' but targeting 'iPhone'
+${SED_INLINE} "s|allow_undefined_flag -o|allow_undefined_flag -target $(get_target) -o|g" libtool 1>>"${BASEDIR}"/build.log 2>&1
+${SED_INLINE} 's|\$rpath/\\$soname|@rpath/ffmpegkit.framework/ffmpegkit|g' libtool 1>>"${BASEDIR}"/build.log 2>&1
+
if [ $? -ne 0 ]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
@@ -70,7 +79,7 @@ fi
# DELETE THE PREVIOUS BUILD OF THE LIBRARY
if [ -d "${FFMPEG_KIT_LIBRARY_PATH}" ]; then
- rm -rf "${FFMPEG_KIT_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ rm -rf "${FFMPEG_KIT_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
diff --git a/scripts/apple/ffmpeg.sh b/scripts/apple/ffmpeg.sh
index 0287335..7142f69 100755
--- a/scripts/apple/ffmpeg.sh
+++ b/scripts/apple/ffmpeg.sh
@@ -6,9 +6,6 @@ if [ -z "${HOST_PKG_CONFIG_PATH}" ]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
LIB_NAME="ffmpeg"
echo -e "----------------------------------------------------------------" 1>>"${BASEDIR}"/build.log 2>&1
@@ -31,7 +28,7 @@ export CXXFLAGS=$(get_cxxflags "${LIB_NAME}")
export LDFLAGS=$(get_ldflags "${LIB_NAME}")
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
-cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# SET EXTRA BUILD FLAGS
FFMPEG_CFLAGS=""
@@ -59,7 +56,9 @@ arm64)
TARGET_CPU="armv8"
TARGET_ARCH="aarch64"
ASM_OPTIONS=" --enable-neon --enable-asm"
- BITCODE_FLAGS="-fembed-bitcode -Wc,-fembed-bitcode"
+ if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
+ BITCODE_FLAGS="-fembed-bitcode -Wc,-fembed-bitcode"
+ fi
;;
arm64-mac-catalyst)
TARGET_CPU="armv8"
@@ -102,9 +101,9 @@ esac
CONFIGURE_POSTFIX=""
# SET CONFIGURE OPTIONS
-for library in {1..59}; do
- if [[ ${!library} -eq 1 ]]; then
- ENABLED_LIBRARY=$(get_library_name $((library - 1)))
+for library in {0..61}; do
+ if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
+ ENABLED_LIBRARY=$(get_library_name ${library})
echo -e "INFO: Enabling library ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -177,7 +176,7 @@ for library in {1..59}; do
libvidstab)
FFMPEG_CFLAGS+=" $(pkg-config --cflags vidstab 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static vidstab 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libvidstab --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libvidstab"
;;
libvorbis)
FFMPEG_CFLAGS+=" $(pkg-config --cflags vorbis 2>>"${BASEDIR}"/build.log)"
@@ -209,6 +208,11 @@ for library in {1..59}; do
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static openh264 2>>"${BASEDIR}"/build.log)"
CONFIGURE_POSTFIX+=" --enable-libopenh264"
;;
+ openssl)
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags openssl 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs --static openssl 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-openssl"
+ ;;
opus)
FFMPEG_CFLAGS+=" $(pkg-config --cflags opus 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static opus 2>>"${BASEDIR}"/build.log)"
@@ -218,7 +222,7 @@ for library in {1..59}; do
FFMPEG_CFLAGS+=" $(pkg-config --cflags rubberband 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static rubberband 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" -framework Accelerate"
- CONFIGURE_POSTFIX+=" --enable-librubberband --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-librubberband"
;;
sdl)
FFMPEG_CFLAGS+=" $(pkg-config --cflags sdl2 2>>"${BASEDIR}"/build.log)"
@@ -245,6 +249,11 @@ for library in {1..59}; do
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static speex 2>>"${BASEDIR}"/build.log)"
CONFIGURE_POSTFIX+=" --enable-libspeex"
;;
+ srt)
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags srt 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs --static srt 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-libsrt"
+ ;;
tesseract)
FFMPEG_CFLAGS+=" $(pkg-config --cflags tesseract 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static tesseract 2>>"${BASEDIR}"/build.log)"
@@ -265,17 +274,22 @@ for library in {1..59}; do
x264)
FFMPEG_CFLAGS+=" $(pkg-config --cflags x264 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static x264 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libx264 --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libx264"
;;
x265)
FFMPEG_CFLAGS+=" $(pkg-config --cflags x265 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static x265 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libx265 --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libx265"
;;
xvidcore)
FFMPEG_CFLAGS+=" $(pkg-config --cflags xvidcore 2>>"${BASEDIR}"/build.log)"
FFMPEG_LDFLAGS+=" $(pkg-config --libs --static xvidcore 2>>"${BASEDIR}"/build.log)"
- CONFIGURE_POSTFIX+=" --enable-libxvid --enable-gpl"
+ CONFIGURE_POSTFIX+=" --enable-libxvid"
+ ;;
+ zimg)
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags zimg 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs --static zimg 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-libzimg"
;;
expat)
FFMPEG_CFLAGS+=" $(pkg-config --cflags expat 2>>"${BASEDIR}"/build.log)"
@@ -317,12 +331,16 @@ for library in {1..59}; do
;;
*-bzip2)
CONFIGURE_POSTFIX+=" --enable-bzlib"
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags bzip2 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs bzip2 2>>"${BASEDIR}"/build.log)"
;;
*-coreimage)
CONFIGURE_POSTFIX+=" --enable-coreimage --enable-appkit"
;;
*-libiconv)
CONFIGURE_POSTFIX+=" --enable-iconv"
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags libiconv 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs libiconv 2>>"${BASEDIR}"/build.log)"
;;
*-opencl)
CONFIGURE_POSTFIX+=" --enable-opencl"
@@ -335,6 +353,8 @@ for library in {1..59}; do
;;
*-zlib)
CONFIGURE_POSTFIX+=" --enable-zlib"
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags zlib 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs zlib 2>>"${BASEDIR}"/build.log)"
;;
esac
;;
@@ -343,32 +363,52 @@ for library in {1..59}; do
# THE FOLLOWING LIBRARIES SHOULD BE EXPLICITLY DISABLED TO PREVENT AUTODETECT
# NOTE THAT IDS MUST BE +1 OF THE INDEX VALUE
- if [[ ${library} -eq $((LIBRARY_SDL + 1)) ]]; then
+ if [[ ${library} -eq ${LIBRARY_SDL} ]]; then
CONFIGURE_POSTFIX+=" --disable-sdl2"
- elif [[ ${library} -eq $((LIBRARY_APPLE_AUDIOTOOLBOX + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_AUDIOTOOLBOX} ]]; then
CONFIGURE_POSTFIX+=" --disable-audiotoolbox"
- elif [[ ${library} -eq $((LIBRARY_APPLE_AVFOUNDATION + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_AVFOUNDATION} ]]; then
CONFIGURE_POSTFIX+=" --disable-avfoundation"
- elif [[ ${library} -eq $((LIBRARY_APPLE_BZIP2 + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_BZIP2} ]]; then
CONFIGURE_POSTFIX+=" --disable-bzlib"
- elif [[ ${library} -eq $((LIBRARY_APPLE_COREIMAGE + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_COREIMAGE} ]]; then
CONFIGURE_POSTFIX+=" --disable-coreimage --disable-appkit"
- elif [[ ${library} -eq $((LIBRARY_APPLE_LIBICONV + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_LIBICONV} ]]; then
CONFIGURE_POSTFIX+=" --disable-iconv"
- elif [[ ${library} -eq $((LIBRARY_APPLE_OPENCL + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_OPENCL} ]]; then
CONFIGURE_POSTFIX+=" --disable-opencl"
- elif [[ ${library} -eq $((LIBRARY_APPLE_OPENGL + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_OPENGL} ]]; then
CONFIGURE_POSTFIX+=" --disable-opengl"
- elif [[ ${library} -eq $((LIBRARY_APPLE_VIDEOTOOLBOX + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_VIDEOTOOLBOX} ]]; then
CONFIGURE_POSTFIX+=" --disable-videotoolbox"
- elif [[ ${library} -eq $((LIBRARY_APPLE_ZLIB + 1)) ]]; then
+ elif [[ ${library} -eq ${LIBRARY_APPLE_ZLIB} ]]; then
CONFIGURE_POSTFIX+=" --disable-zlib"
+ elif [[ ${library} -eq ${LIBRARY_OPENSSL} ]]; then
+ CONFIGURE_POSTFIX+=" --disable-openssl"
fi
fi
done
-# ALWAYS BUILD STATIC LIBRARIES
-BUILD_LIBRARY_OPTIONS="--enable-static --disable-shared"
+# SET CONFIGURE OPTIONS FOR CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+ pc_file_name="CUSTOM_LIBRARY_${custom_library_index}_PACKAGE_CONFIG_FILE_NAME"
+ ffmpeg_flag_name="CUSTOM_LIBRARY_${custom_library_index}_FFMPEG_ENABLE_FLAG"
+
+ echo -e "INFO: Enabling custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ FFMPEG_CFLAGS+=" $(pkg-config --cflags ${!pc_file_name} 2>>"${BASEDIR}"/build.log)"
+ FFMPEG_LDFLAGS+=" $(pkg-config --libs --static ${!pc_file_name} 2>>"${BASEDIR}"/build.log)"
+ CONFIGURE_POSTFIX+=" --enable-${!ffmpeg_flag_name}"
+done
+
+# SET ENABLE GPL FLAG WHEN REQUESTED
+if [ "$GPL_ENABLED" == "yes" ]; then
+ CONFIGURE_POSTFIX+=" --enable-gpl"
+fi
+
+# ALWAYS BUILD SHARED LIBRARIES
+BUILD_LIBRARY_OPTIONS="--enable-shared --disable-static --install-name-dir=@rpath"
# OPTIMIZE FOR SPEED INSTEAD OF SIZE
if [[ -z ${FFMPEG_KIT_OPTIMIZED_FOR_SPEED} ]]; then
@@ -420,6 +460,9 @@ if [[ -z ${NO_WORKSPACE_CLEANUP_ffmpeg} ]]; then
# WORKAROUND TO MANUALLY DELETE UNCLEANED FILES
rm -f "${BASEDIR}"/src/"${LIB_NAME}"/libavfilter/opencl/*.o 1>>"${BASEDIR}"/build.log 2>&1
rm -f "${BASEDIR}"/src/"${LIB_NAME}"/libavcodec/neon/*.o 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DELETE SHARED FRAMEWORK WORKAROUNDS
+ git checkout "${BASEDIR}/src/ffmpeg/ffbuild" 1>>"${BASEDIR}"/build.log 2>&1
fi
########################### CUSTOMIZATIONS #######################
@@ -428,21 +471,21 @@ git checkout libavformat/protocols.c 1>>"${BASEDIR}"/build.log 2>&1
git checkout libavutil 1>>"${BASEDIR}"/build.log 2>&1
# 1. Workaround to prevent adding of -mdynamic-no-pic flag
-${SED_INLINE} 's/check_cflags -mdynamic-no-pic && add_asflags -mdynamic-no-pic;/check_cflags -mdynamic-no-pic;/g' ./configure 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} 's/check_cflags -mdynamic-no-pic && add_asflags -mdynamic-no-pic;/check_cflags -mdynamic-no-pic;/g' ./configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# 2. Workaround for videotoolbox on mac catalyst
if [[ ${ARCH} == *-mac-catalyst ]]; then
- ${SED_INLINE} 's/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' "${BASEDIR}"/src/${LIB_NAME}/libavcodec/videotoolbox.c || exit 1
+ ${SED_INLINE} 's/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' "${BASEDIR}"/src/${LIB_NAME}/libavcodec/videotoolbox.c || return 1
else
- ${SED_INLINE} 's/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' "${BASEDIR}"/src/${LIB_NAME}/libavcodec/videotoolbox.c || exit 1
+ ${SED_INLINE} 's/ \/\/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/ CFDictionarySetValue(buffer_attributes\, kCVPixelBufferOpenGLESCompatibilityKey/g' "${BASEDIR}"/src/${LIB_NAME}/libavcodec/videotoolbox.c || return 1
fi
# 3. Use thread local log levels
-${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR}"/src/${LIB_NAME}/libavutil/log.c 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR}"/src/${LIB_NAME}/libavutil/log.c 1>>"${BASEDIR}"/build.log 2>&1 || return 1
# 4. Set friendly ffmpeg version
FFMPEG_VERSION="v$(get_user_friendly_ffmpeg_version)"
-${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffbuild/version.sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffbuild/version.sh 1>>"${BASEDIR}"/build.log 2>&1 || return 1
###################################################################
@@ -462,9 +505,8 @@ ${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffb
--as="${AS}" \
--ranlib="${RANLIB}" \
--strip="${STRIP}" \
- --ranlib="${RANLIB}" \
- --strip="${STRIP}" \
--nm="${NM}" \
+ --extra-ldflags="$(get_min_version_cflags)" \
--disable-autodetect \
--enable-cross-compile \
--enable-pic \
@@ -479,7 +521,6 @@ ${SED_INLINE} "s/\$version/$FFMPEG_VERSION/g" "${BASEDIR}"/src/"${LIB_NAME}"/ffb
--disable-indev=v4l2 \
--disable-indev=fbdev \
${SIZE_OPTIONS} \
- --disable-openssl \
--disable-xmm-clobber-test \
${DEBUG_OPTIONS} \
--disable-neon-clobber-test \
@@ -512,35 +553,83 @@ if [[ $? -ne 0 ]]; then
exit 1
fi
-if [[ -z ${NO_OUTPUT_REDIRECTION} ]]; then
- make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
+build_ffmpeg() {
+ if [[ -z ${NO_OUTPUT_REDIRECTION} ]]; then
+ make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
- if [[ $? -ne 0 ]]; then
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
+ if [[ $? -ne 0 ]]; then
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+ else
+ echo -e "started\n"
+ make -j$(get_cpu_count)
+
+ if [[ $? -ne 0 ]]; then
+ echo -n -e "\n${LIB_NAME}: failed\n\nSee build.log for details\n"
+ exit 1
+ else
+ echo -n -e "\n${LIB_NAME}: "
+ fi
fi
-else
- echo -e "started\n"
- make -j$(get_cpu_count)
+}
+
+install_ffmpeg() {
+
+ if [[ -n $1 ]]; then
+
+ # DELETE THE PREVIOUS BUILD
+ if [ -d "${FFMPEG_LIBRARY_PATH}" ]; then
+ rm -rf "${FFMPEG_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ fi
+ else
+
+ # LEAVE EVERYTHING EXCEPT frameworks
+ rm -rf "${FFMPEG_LIBRARY_PATH}/include" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ rm -rf "${FFMPEG_LIBRARY_PATH}/lib" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ rm -rf "${FFMPEG_LIBRARY_PATH}/share" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ fi
+ make install 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
- echo -n -e "\n${LIB_NAME}: failed\n\nSee build.log for details\n"
+ echo -e "failed\n\nSee build.log for details\n"
exit 1
- else
- echo -n -e "\n${LIB_NAME}: "
fi
-fi
+}
-# DELETE THE PREVIOUS BUILD OF THE LIBRARY BEFORE INSTALLING
-if [ -d "${FFMPEG_LIBRARY_PATH}" ]; then
- rm -rf "${FFMPEG_LIBRARY_PATH}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-fi
-make install 1>>"${BASEDIR}"/build.log 2>&1
+${SED_INLINE} 's|$(SLIBNAME_WITH_MAJOR),|$(SLIBPREF)$(FULLNAME).framework/$(SLIBPREF)$(FULLNAME),|g' ${BASEDIR}/src/ffmpeg/ffbuild/config.mak 1>>"${BASEDIR}"/build.log 2>&1 || return 1
-if [[ $? -ne 0 ]]; then
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
-fi
+# BUILD DYNAMIC LIBRARIES WITH DEFAULT OPTIONS
+build_ffmpeg
+install_ffmpeg "true"
+
+# CLEAN THE OUTPUT OF FIRST BUILD
+find . -name "*.dylib" -delete 1>>"${BASEDIR}"/build.log 2>&1
+
+echo -e "\nShared libraries built successfully. Building frameworks.\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+create_temporary_framework() {
+ local FRAMEWORK_NAME="$1"
+ mkdir -p "${FFMPEG_LIBRARY_PATH}/framework/${FRAMEWORK_NAME}.framework" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+ cp "${FFMPEG_LIBRARY_PATH}/lib/${FRAMEWORK_NAME}.dylib" "${FFMPEG_LIBRARY_PATH}/framework/${FRAMEWORK_NAME}.framework/${FRAMEWORK_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+}
+
+create_temporary_framework "libavcodec"
+create_temporary_framework "libavdevice"
+create_temporary_framework "libavfilter"
+create_temporary_framework "libavformat"
+create_temporary_framework "libavutil"
+create_temporary_framework "libswresample"
+create_temporary_framework "libswscale"
+
+${SED_INLINE} 's|$(SLIBNAME_WITH_MAJOR),|$(SLIBPREF)$(FULLNAME).framework/$(SLIBPREF)$(FULLNAME),|g' ${BASEDIR}/src/ffmpeg/ffbuild/config.mak 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+${SED_INLINE} "s|^ALLFFLIBS = .*|ALLFFLIBS = ${FFMPEG_LIBRARY_PATH}/framework|g" ${BASEDIR}/src/ffmpeg/ffbuild/common.mak 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+${SED_INLINE} 's|$(LD_LIB)|-framework lib% |g' ${BASEDIR}/src/ffmpeg/ffbuild/common.mak 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+${SED_INLINE} 's|$(LD_PATH)lib|-F |g' ${BASEDIR}/src/ffmpeg/ffbuild/common.mak 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+
+# BUILD FRAMEWORKS AS DYNAMIC LIBRARIES
+build_ffmpeg
+install_ffmpeg
# MANUALLY ADD REQUIRED HEADERS
mkdir -p "${FFMPEG_LIBRARY_PATH}"/include/libavutil/x86 1>>"${BASEDIR}"/build.log 2>&1
diff --git a/scripts/apple/fontconfig.sh b/scripts/apple/fontconfig.sh
index 3d8d0c6..06dc1ee 100755
--- a/scripts/apple/fontconfig.sh
+++ b/scripts/apple/fontconfig.sh
@@ -3,9 +3,12 @@
# ALWAYS CLEAN THE PREVIOUS BUILD
make distclean 2>/dev/null 1>/dev/null
+# WORKAROUND FOR "bad flag in substitute command"
+${SED_INLINE} "s|in \"\$default_fonts\"|in \$default_fonts|g" "${BASEDIR}"/src/"${LIB_NAME}"/configure.ac 1>>"${BASEDIR}"/build.log 2>&1
+
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_fontconfig} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
@@ -31,4 +34,4 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_fontconfig_package_config "2.13.93" || return 1
+create_fontconfig_package_config "2.13.94" || return 1
diff --git a/scripts/apple/freetype.sh b/scripts/apple/freetype.sh
index f70cfcc..dc77a6d 100755
--- a/scripts/apple/freetype.sh
+++ b/scripts/apple/freetype.sh
@@ -41,4 +41,4 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_freetype_package_config "24.0.18" || return 1
+create_freetype_package_config "24.1.18" || return 1
diff --git a/scripts/apple/fribidi.sh b/scripts/apple/fribidi.sh
index 32840c8..abc51f8 100755
--- a/scripts/apple/fribidi.sh
+++ b/scripts/apple/fribidi.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_fribidi} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/giflib.sh b/scripts/apple/giflib.sh
index 110af90..737f084 100755
--- a/scripts/apple/giflib.sh
+++ b/scripts/apple/giflib.sh
@@ -8,7 +8,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_giflib} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/gmp.sh b/scripts/apple/gmp.sh
index 00ddda4..7efaf91 100755
--- a/scripts/apple/gmp.sh
+++ b/scripts/apple/gmp.sh
@@ -17,7 +17,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_gmp} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# UPDATE CONFIG FILES TO SUPPORT APPLE ARCHITECTURES
diff --git a/scripts/apple/gnutls.sh b/scripts/apple/gnutls.sh
index 523f70d..a86fc50 100755
--- a/scripts/apple/gnutls.sh
+++ b/scripts/apple/gnutls.sh
@@ -12,14 +12,6 @@ export HOGWEED_LIBS="-L${LIB_INSTALL_BASE}/nettle/lib -lhogweed -L${LIB_INSTALL_
export GMP_CFLAGS="-I${LIB_INSTALL_BASE}/gmp/include"
export GMP_LIBS="-L${LIB_INSTALL_BASE}/gmp/lib -lgmp"
-# SET BUILD OPTIONS
-case ${ARCH} in
-i386)
- # DISABLING thread_local WHICH IS NOT SUPPORTED ON i386
- export CFLAGS+=" -D__thread="
- ;;
-esac
-
# ALWAYS CLEAN THE PREVIOUS BUILD
make distclean 2>/dev/null 1>/dev/null
@@ -56,4 +48,8 @@ make -j$(get_cpu_count) || return 1
make install || return 1
# CREATE PACKAGE CONFIG MANUALLY
-create_gnutls_package_config "3.6.15.1" || return 1
+if [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
+ create_gnutls_package_config "3.6.15.1" "-framework Security" || return 1
+else
+ create_gnutls_package_config "3.6.15.1" || return 1
+fi
diff --git a/scripts/apple/harfbuzz.sh b/scripts/apple/harfbuzz.sh
index 6416ab0..07dba4c 100755
--- a/scripts/apple/harfbuzz.sh
+++ b/scripts/apple/harfbuzz.sh
@@ -19,8 +19,13 @@ fi
--disable-fast-install \
--host="${HOST}" || return 1
-# WORKAROUND TO REMOVE -bind_at_load FLAG WHICH CAN NOT BE USED WHEN BITCODE IS ENABLED
-${SED_INLINE} 's/$wl-bind_at_load//g' ${BASEDIR}/src/${LIB_NAME}/libtool
+# WORKAROUNDS
+git checkout ${BASEDIR}/src/${LIB_NAME}/libtool 1>>"${BASEDIR}"/build.log 2>&1
+if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
+
+ # WORKAROUND TO REMOVE -bind_at_load FLAG WHICH CAN NOT BE USED WHEN BITCODE IS ENABLED
+ ${SED_INLINE} 's/$wl-bind_at_load//g' ${BASEDIR}/src/${LIB_NAME}/libtool
+fi
make -j$(get_cpu_count) || return 1
diff --git a/scripts/apple/kvazaar.sh b/scripts/apple/kvazaar.sh
index e0d6bef..0f905ac 100755
--- a/scripts/apple/kvazaar.sh
+++ b/scripts/apple/kvazaar.sh
@@ -16,7 +16,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_kvazaar} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/lame.sh b/scripts/apple/lame.sh
index a82704a..28bb2d2 100755
--- a/scripts/apple/lame.sh
+++ b/scripts/apple/lame.sh
@@ -7,7 +7,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_lame} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/leptonica.sh b/scripts/apple/leptonica.sh
index 87832d9..21d9eaa 100755
--- a/scripts/apple/leptonica.sh
+++ b/scripts/apple/leptonica.sh
@@ -17,7 +17,7 @@ export LIBTIFF_CFLAGS="$(pkg-config --cflags libtiff-4)"
export LIBTIFF_LIBS="$(pkg-config --libs --static libtiff-4)"
export ZLIB_CFLAGS="$(pkg-config --cflags zlib)"
-export ZLIB_LIBS="$(pkg-config --libs --static zlib)"
+export ZLIB_LIBS="$(pkg-config --libs zlib)"
export JPEG_CFLAGS="$(pkg-config --cflags libjpeg)"
export JPEG_LIBS="$(pkg-config --libs --static libjpeg)"
@@ -27,7 +27,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_leptonica} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libaom.sh b/scripts/apple/libaom.sh
index 28daa98..3b7347c 100755
--- a/scripts/apple/libaom.sh
+++ b/scripts/apple/libaom.sh
@@ -10,7 +10,7 @@ arm*)
ASM_OPTIONS="-DCONFIG_RUNTIME_CPU_DETECT=0 -DARCH_ARM=1 -DENABLE_NEON=1 -DHAVE_NEON=1"
;;
i386)
- ASM_OPTIONS="-DARCH_X86=1 -DENABLE_SSE=1 -DHAVE_SSE=1 -DENABLE_SSE3=1 -DHAVE_SSE3=1"
+ ASM_OPTIONS="-DARCH_X86=1 -DENABLE_SSE=0 -DHAVE_SSE=0 -DENABLE_SSE3=0 -DHAVE_SSE3=0"
;;
x86-64*)
ASM_OPTIONS="-DARCH_X86_64=0 -DENABLE_SSE=0 -DENABLE_SSE2=0 -DENABLE_SSE3=0 -DENABLE_SSE4_1=0 -DENABLE_SSE4_2=0 -DENABLE_MMX=0"
diff --git a/scripts/apple/libass.sh b/scripts/apple/libass.sh
index 68949a5..0a7daa2 100755
--- a/scripts/apple/libass.sh
+++ b/scripts/apple/libass.sh
@@ -13,7 +13,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libass} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libilbc.sh b/scripts/apple/libilbc.sh
index 37c9b23..ee1792d 100755
--- a/scripts/apple/libilbc.sh
+++ b/scripts/apple/libilbc.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libilbc} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libogg.sh b/scripts/apple/libogg.sh
index 09e537c..13f0051 100755
--- a/scripts/apple/libogg.sh
+++ b/scripts/apple/libogg.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libogg} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# FIX INCLUDE PATHS
diff --git a/scripts/apple/libpng.sh b/scripts/apple/libpng.sh
index b49df51..149632c 100755
--- a/scripts/apple/libpng.sh
+++ b/scripts/apple/libpng.sh
@@ -21,7 +21,7 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libpng} -e
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.guess "${BASEDIR}"/src/"${LIB_NAME}"/config.guess || return 1
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.sub "${BASEDIR}"/src/"${LIB_NAME}"/config.sub || return 1
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libsamplerate.sh b/scripts/apple/libsamplerate.sh
index f9abe2b..f3c73ee 100755
--- a/scripts/apple/libsamplerate.sh
+++ b/scripts/apple/libsamplerate.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libsamplerate} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libsndfile.sh b/scripts/apple/libsndfile.sh
index a61a4c7..a7ce0af 100755
--- a/scripts/apple/libsndfile.sh
+++ b/scripts/apple/libsndfile.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libsndfile} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libvidstab.sh b/scripts/apple/libvidstab.sh
index 8668111..305fea7 100755
--- a/scripts/apple/libvidstab.sh
+++ b/scripts/apple/libvidstab.sh
@@ -15,7 +15,7 @@ mkdir -p "${BUILD_DIR}" || return 1
cd "${BUILD_DIR}" || return 1
# WORKAROUND TO DETECT ASM FLAGS PROPERLY
-${SED_INLINE} 's/ ${CPUINFO}/ "${CPUINFO}"/g' "${BASEDIR}"/src/"${LIB_NAME}"/CMakeModules/FindSSE.cmake 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+${SED_INLINE} 's/ ${CPUINFO}/ "${CPUINFO}"/g' "${BASEDIR}"/src/"${LIB_NAME}"/CMakeModules/FindSSE.cmake 1>>"${BASEDIR}"/build.log 2>&1 || return 1
cmake -Wno-dev \
-DCMAKE_VERBOSE_MAKEFILE=0 \
diff --git a/scripts/apple/libvorbis.sh b/scripts/apple/libvorbis.sh
index d72ab69..00dbee7 100755
--- a/scripts/apple/libvorbis.sh
+++ b/scripts/apple/libvorbis.sh
@@ -3,18 +3,19 @@
# ALWAYS CLEAN THE PREVIOUS BUILD
make distclean 2>/dev/null 1>/dev/null
-# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
-if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libvorbis} -eq 1 ]]; then
+# WORKAROUNDS
+# -mno-ieee-fp OPTION IS NOT COMPATIBLE WITH clang. REMOVING IT
+${SED_INLINE} 's/\-mno-ieee-fp//g' "${BASEDIR}"/src/"${LIB_NAME}"/configure.ac || return 1
- # -mno-ieee-fp OPTION IS NOT COMPATIBLE WITH clang. REMOVING IT
- ${SED_INLINE} 's/\-mno-ieee-fp//g' "${BASEDIR}"/src/"${LIB_NAME}"/configure.ac || return 1
+# ALWAYS REGENERATE BUILD FILES - NECESSARY TO APPLY THE WORKAROUNDS
+autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
- autoreconf_library "${LIB_NAME}"
-fi
+if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
-# WORKAROUND TO REMOVE -force_cpusubtype_ALL FLAG DUE TO THE FOLLOWING ERROR
-# ld: -force_cpusubtype_ALL and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
-${SED_INLINE} 's/-force_cpusubtype_ALL//g' ${BASEDIR}/src/${LIB_NAME}/configure
+ # WORKAROUND TO REMOVE -force_cpusubtype_ALL FLAG DUE TO THE FOLLOWING ERROR
+ # ld: -force_cpusubtype_ALL and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
+ ${SED_INLINE} 's/-force_cpusubtype_ALL//g' ${BASEDIR}/src/${LIB_NAME}/configure
+fi
PKG_CONFIG= ./configure \
--prefix="${LIB_INSTALL_PREFIX}" \
diff --git a/scripts/apple/libwebp.sh b/scripts/apple/libwebp.sh
index de0013f..b5b9b1b 100755
--- a/scripts/apple/libwebp.sh
+++ b/scripts/apple/libwebp.sh
@@ -19,7 +19,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libwebp} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/libxml2.sh b/scripts/apple/libxml2.sh
index 1b93826..a4c4065 100755
--- a/scripts/apple/libxml2.sh
+++ b/scripts/apple/libxml2.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_libxml2} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/nettle.sh b/scripts/apple/nettle.sh
index 126ac36..449619c 100755
--- a/scripts/apple/nettle.sh
+++ b/scripts/apple/nettle.sh
@@ -20,7 +20,7 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_nettle} -e
# WORKAROUND TO FIX BUILD SYSTEM COMPILER ON macOS
overwrite_file "${BASEDIR}"/tools/patch/make/nettle/aclocal.m4 "${BASEDIR}"/src/"${LIB_NAME}"/aclocal.m4
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# UPDATE CONFIG FILES TO SUPPORT APPLE ARCHITECTURES
diff --git a/scripts/apple/opencore-amr.sh b/scripts/apple/opencore-amr.sh
index 02fbb99..e51503f 100755
--- a/scripts/apple/opencore-amr.sh
+++ b/scripts/apple/opencore-amr.sh
@@ -18,7 +18,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_opencore_amr} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/openh264.sh b/scripts/apple/openh264.sh
index 77721f9..1ce66c7 100755
--- a/scripts/apple/openh264.sh
+++ b/scripts/apple/openh264.sh
@@ -1,5 +1,22 @@
#!/bin/bash
+get_local_asm_arch() {
+ case ${ARCH} in
+ armv7*)
+ echo "arm"
+ ;;
+ arm64*)
+ echo "arm64"
+ ;;
+ x86-64*)
+ echo "x86_64"
+ ;;
+ *)
+ echo "${ARCH}"
+ ;;
+ esac
+}
+
# UPDATE BUILD FLAGS AND SET BUILD OPTIONS
ASM_OPTIONS="OS=darwin"
case ${ARCH} in
@@ -14,19 +31,22 @@ arm64*)
;;
esac
+# ALWAYS CLEAN THE PREVIOUS BUILD
+make clean 2>/dev/null 1>/dev/null
+
+# DISCARD APPLE WORKAROUNDS
+git checkout "${BASEDIR}"/src/"${LIB_NAME}"/build || return 1
+git checkout "${BASEDIR}"/src/"${LIB_NAME}"/codec || return 1
+
# MAKE SURE THAT ASM IS ENABLED FOR ALL IOS ARCHITECTURES - EXCEPT x86-64
${SED_INLINE} 's/arm64 aarch64/arm64% aarch64/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
${SED_INLINE} 's/%86 x86_64,/%86 x86_64 x86-64%,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
${SED_INLINE} 's/filter-out arm64,/filter-out arm64%,/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
${SED_INLINE} 's/CFLAGS += -DHAVE_NEON/#CFLAGS += -DHAVE_NEON/g' ${BASEDIR}/src/${LIB_NAME}/build/arch.mk
${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm64)/ifneq (\$(filter arm64%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
-${SED_INLINE} 's/ifeq (\$(ASM_ARCH), arm)/ifneq (\$(filter armv%, \$(ASM_ARCH)),)/g' ${BASEDIR}/src/${LIB_NAME}/codec/common/targets.mk
-
-# ALWAYS CLEAN THE PREVIOUS BUILD
-make clean 2>/dev/null 1>/dev/null
make -j$(get_cpu_count) \
- ASM_ARCH="$(get_target_cpu)" \
+ ASM_ARCH="$(get_local_asm_arch)" \
ARCH="${ARCH}" \
CC="${CC}" \
CFLAGS="$CFLAGS" \
diff --git a/scripts/apple/openssl.sh b/scripts/apple/openssl.sh
new file mode 100644
index 0000000..1043c3d
--- /dev/null
+++ b/scripts/apple/openssl.sh
@@ -0,0 +1,49 @@
+#!/bin/bash
+
+if [[ ${ARCH} == "i386" ]] || [[ ${ARCH} == "armv7"* ]] || [[ ${FFMPEG_KIT_BUILD_TYPE} == "tvos" ]]; then
+
+ # openssl does not support 32-bit apple architectures and tvos yet
+ echo -e "ERROR: openssl is not supported on $ARCH architecture for $FFMPEG_KIT_BUILD_TYPE platform.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ return 200
+fi
+
+# SET BUILD OPTIONS
+ASM_OPTIONS=""
+case ${ARCH} in
+arm64 | arm64e | arm64-mac-catalyst | arm64-simulator | x86-64 | x86-64-mac-catalyst)
+ ASM_OPTIONS="enable-ec_nistp_64_gcc_128"
+ ;;
+i386)
+ ASM_OPTIONS="386"
+ ;;
+esac
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+make distclean 2>/dev/null 1>/dev/null
+
+# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
+if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_openssl} -eq 1 ]]; then
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+fi
+
+INT128_AVAILABLE=$($CC -dM -E - >"${BASEDIR}"/build.log | grep __SIZEOF_INT128__)
+
+echo -e "INFO: __uint128_t detection output: $INT128_AVAILABLE\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+./Configure \
+ --prefix="${LIB_INSTALL_PREFIX}" \
+ zlib \
+ no-shared \
+ no-engine \
+ no-dso \
+ no-legacy \
+ ${ASM_OPTIONS} \
+ no-tests \
+ iphoneos-cross || return 1
+
+make -j$(get_cpu_count) build_sw || return 1
+
+make install_sw install_ssldirs || return 1
+
+# MANUALLY COPY PKG-CONFIG FILES
+cp ./*.pc "${INSTALL_PKG_CONFIG_DIR}" || return 1
diff --git a/scripts/apple/opus.sh b/scripts/apple/opus.sh
index 25710f1..64884a4 100755
--- a/scripts/apple/opus.sh
+++ b/scripts/apple/opus.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_opus} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/rubberband.sh b/scripts/apple/rubberband.sh
index 2849944..251c56a 100755
--- a/scripts/apple/rubberband.sh
+++ b/scripts/apple/rubberband.sh
@@ -12,7 +12,7 @@ overwrite_file "${BASEDIR}"/tools/patch/make/rubberband/rubberband.pc.in "${BASE
${SED_INLINE} 's/%DEPENDENCIES%/sndfile, samplerate/g' "${BASEDIR}"/src/"${LIB_NAME}"/rubberband.pc.in || return 1
# ALWAYS REGENERATE BUILD FILES - NECESSARY TO APPLY THE WORKAROUNDS
-autoreconf_library "${LIB_NAME}"
+autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
./configure \
--prefix="${LIB_INSTALL_PREFIX}" \
diff --git a/scripts/apple/shine.sh b/scripts/apple/shine.sh
index b2b176d..129c2b2 100755
--- a/scripts/apple/shine.sh
+++ b/scripts/apple/shine.sh
@@ -5,7 +5,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_shine} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/speex.sh b/scripts/apple/speex.sh
index b67c065..955baaa 100755
--- a/scripts/apple/speex.sh
+++ b/scripts/apple/speex.sh
@@ -13,7 +13,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_soxr} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/srt.sh b/scripts/apple/srt.sh
new file mode 100644
index 0000000..54e0ede
--- /dev/null
+++ b/scripts/apple/srt.sh
@@ -0,0 +1,54 @@
+#!/bin/bash
+
+mkdir -p "${BUILD_DIR}" || return 1
+cd "${BUILD_DIR}" || return 1
+
+# SET BUILD OPTIONS
+ASM_OPTIONS=""
+case ${ARCH} in
+*-mac-catalyst)
+ ASM_OPTIONS="-DENABLE_MONOTONIC_CLOCK=0"
+ ;;
+*)
+ ASM_OPTIONS="-DENABLE_MONOTONIC_CLOCK=1"
+ ;;
+esac
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+git clean -dfx 2>/dev/null 1>/dev/null
+
+cmake -Wno-dev \
+ -DUSE_ENCLIB=openssl \
+ -DCMAKE_VERBOSE_MAKEFILE=0 \
+ -DCMAKE_C_FLAGS="${CFLAGS}" \
+ -DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
+ -DCMAKE_EXE_LINKER_FLAGS="${LDFLAGS}" \
+ -DCMAKE_SYSROOT="${SDK_PATH}" \
+ -DCMAKE_FIND_ROOT_PATH="${SDK_PATH}" \
+ -DCMAKE_OSX_SYSROOT="$(get_sdk_name)" \
+ -DCMAKE_OSX_ARCHITECTURES="$(get_cmake_osx_architectures)" \
+ -DCMAKE_SYSTEM_NAME="${CMAKE_SYSTEM_NAME}" \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_INSTALL_PREFIX="${LIB_INSTALL_PREFIX}" \
+ -DCMAKE_CXX_COMPILER="$CXX" \
+ -DCMAKE_C_COMPILER="$CC" \
+ -DCMAKE_LINKER="$LD" \
+ -DCMAKE_AR="$(xcrun --sdk $(get_sdk_name) -f ar)" \
+ -DCMAKE_AS="$AS" \
+ -DCMAKE_SYSTEM_PROCESSOR="$(get_target_cpu)" \
+ ${ASM_OPTIONS} \
+ -DENABLE_STDCXX_SYNC=1 \
+ -DENABLE_CXX11=1 \
+ -DUSE_OPENSSL_PC=1 \
+ -DENABLE_DEBUG=0 \
+ -DENABLE_LOGGING=0 \
+ -DENABLE_HEAVY_LOGGING=0 \
+ -DENABLE_APPS=0 \
+ -DENABLE_SHARED=0 "${BASEDIR}"/src/"${LIB_NAME}" || return 1
+
+make -j$(get_cpu_count) || return 1
+
+make install || return 1
+
+# MANUALLY COPY PKG-CONFIG FILES
+cp ./*.pc "${INSTALL_PKG_CONFIG_DIR}" || return 1
\ No newline at end of file
diff --git a/scripts/apple/tesseract.sh b/scripts/apple/tesseract.sh
index caa75c9..60f47b4 100755
--- a/scripts/apple/tesseract.sh
+++ b/scripts/apple/tesseract.sh
@@ -9,7 +9,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_tesseract} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
@@ -26,8 +26,13 @@ fi
--disable-largefile \
--host="${HOST}" || return 1
-# WORKAROUND TO REMOVE -bind_at_load FLAG WHICH CAN NOT BE USED WHEN BITCODE IS ENABLED
-${SED_INLINE} 's/$wl-bind_at_load//g' ${BASEDIR}/src/${LIB_NAME}/libtool
+# WORKAROUNDS
+git checkout ${BASEDIR}/src/${LIB_NAME}/libtool 1>>"${BASEDIR}"/build.log 2>&1
+if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
+
+ # WORKAROUND TO REMOVE -bind_at_load FLAG WHICH CAN NOT BE USED WHEN BITCODE IS ENABLED
+ ${SED_INLINE} 's/$wl-bind_at_load//g' ${BASEDIR}/src/${LIB_NAME}/libtool
+fi
# WORKAROUND TO DISABLE LINKING TO rt
${SED_INLINE} 's/-lrt//g' ${BASEDIR}/src/${LIB_NAME}/api/Makefile
diff --git a/scripts/apple/tiff.sh b/scripts/apple/tiff.sh
index 46fe9ce..37fe273 100755
--- a/scripts/apple/tiff.sh
+++ b/scripts/apple/tiff.sh
@@ -10,7 +10,7 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_tiff} -eq
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.guess "${BASEDIR}"/src/"${LIB_NAME}"/config.guess || return 1
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.sub "${BASEDIR}"/src/"${LIB_NAME}"/config.sub || return 1
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/vo-amrwbenc.sh b/scripts/apple/vo-amrwbenc.sh
index d95f6a4..d0d8fb1 100755
--- a/scripts/apple/vo-amrwbenc.sh
+++ b/scripts/apple/vo-amrwbenc.sh
@@ -15,7 +15,7 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_vo_amrwbenc} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
./configure \
diff --git a/scripts/apple/x264.sh b/scripts/apple/x264.sh
index 4ab7fba..e80ed9c 100755
--- a/scripts/apple/x264.sh
+++ b/scripts/apple/x264.sh
@@ -20,13 +20,16 @@ make distclean 2>/dev/null 1>/dev/null
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_x264} -eq 1 ]]; then
- autoreconf_library "${LIB_NAME}"
+ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
fi
# UPDATE CONFIG FILES TO SUPPORT APPLE ARCHITECTURES
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.guess "${BASEDIR}"/src/"${LIB_NAME}"/config.guess || return 1
overwrite_file "${FFMPEG_KIT_TMPDIR}"/source/config/config.sub "${BASEDIR}"/src/"${LIB_NAME}"/config.sub || return 1
+# WORKAROUND TO FIX arm64 BUILDS
+${SED_INLINE} 's/\-arch arm64//g' "${BASEDIR}"/src/"${LIB_NAME}"/configure 1>>"${BASEDIR}"/build.log 2>&1 || return 1
+
./configure \
--prefix="${LIB_INSTALL_PREFIX}" \
--enable-pic \
diff --git a/scripts/apple/x265.sh b/scripts/apple/x265.sh
index 68bf268..1f24121 100755
--- a/scripts/apple/x265.sh
+++ b/scripts/apple/x265.sh
@@ -11,6 +11,9 @@ arm64*)
x86-64-mac-catalyst)
ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
;;
+i386)
+ ASM_OPTIONS="-DENABLE_ASSEMBLY=0 -DCROSS_COMPILE_ARM=0"
+ ;;
*)
ASM_OPTIONS="-DENABLE_ASSEMBLY=1 -DCROSS_COMPILE_ARM=0"
;;
@@ -30,6 +33,18 @@ ${SED_INLINE} 's/lsr 16/lsr #16/g' ${BASEDIR}/src/x265/source/common/arm/blockco
${SED_INLINE} 's/function x265_/function _x265_/g' ${BASEDIR}/src/x265/source/common/arm/*.S
${SED_INLINE} 's/ x265_/ _x265_/g' ${BASEDIR}/src/x265/source/common/arm/pixel-util.S
+# fixing relocation errors
+${SED_INLINE} 's/sad12_mask:/sad12_mask_bytes:/g' ${BASEDIR}/src/x265/source/common/arm/sad-a.S
+${SED_INLINE} 's/g_lumaFilter:/g_lumaFilter_bytes:/g' ${BASEDIR}/src/x265/source/common/arm/ipfilter8.S
+${SED_INLINE} 's/g_chromaFilter:/g_chromaFilter_bytes:/g' ${BASEDIR}/src/x265/source/common/arm/ipfilter8.S
+${SED_INLINE} 's/\.text/.equ sad12_mask, .-sad12_mask_bytes\
+\
+.text/g' ${BASEDIR}/src/x265/source/common/arm/sad-a.S
+${SED_INLINE} 's/\.text/.equ g_lumaFilter, .-g_lumaFilter_bytes\
+.equ g_chromaFilter, .-g_chromaFilter_bytes\
+\
+.text/g' ${BASEDIR}/src/x265/source/common/arm/ipfilter8.S
+
# WORKAROUND TO USE A CUSTOM BUILD FILE
overwrite_file "${BASEDIR}"/tools/patch/cmake/x265/CMakeLists.txt "${BASEDIR}"/src/"${LIB_NAME}"/source/CMakeLists.txt || return 1
@@ -53,6 +68,7 @@ cmake -Wno-dev \
-DSTATIC_LINK_CRT=1 \
-DENABLE_PIC=1 \
-DENABLE_CLI=0 \
+ -DHIGH_BIT_DEPTH=1 \
${ASM_OPTIONS} \
-DCMAKE_SYSTEM_PROCESSOR="$(get_target_cpu)" \
-DENABLE_SHARED=0 "${BASEDIR}"/src/"${LIB_NAME}"/source || return 1
diff --git a/scripts/apple/xvidcore.sh b/scripts/apple/xvidcore.sh
index 4647f1b..be75087 100755
--- a/scripts/apple/xvidcore.sh
+++ b/scripts/apple/xvidcore.sh
@@ -13,8 +13,9 @@ esac
# ALWAYS CLEAN THE PREVIOUS BUILD
make distclean 2>/dev/null 1>/dev/null
-# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
-if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/build/generic/configure ]] || [[ ${RECONF_xvidcore} -eq 1 ]]; then
+# WORKAROUNDS
+git checkout configure.in 1>>"${BASEDIR}"/build.log 2>&1
+if [[ ${FFMPEG_KIT_BUILD_TYPE} != "macos" ]]; then
# WORKAROUND TO FIX THE FOLLOWING ERROR
# ld: -flat_namespace and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
@@ -23,10 +24,11 @@ if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/build/generic/configure
# WORKAROUND TO FIX THE FOLLOWING ERROR
# ld: -read_only_relocs and -bitcode_bundle (Xcode setting ENABLE_BITCODE=YES) cannot be used together
${SED_INLINE} 's/-Wl,-read_only_relocs,suppress//g' configure.in
-
- ./bootstrap.sh
fi
+# ALWAYS REGENERATE BUILD FILES - NECESSARY TO APPLY THE WORKAROUNDS
+./bootstrap.sh
+
./configure \
--prefix="${LIB_INSTALL_PREFIX}" \
${ASM_OPTIONS} \
diff --git a/scripts/apple/zimg.sh b/scripts/apple/zimg.sh
new file mode 100644
index 0000000..44c5739
--- /dev/null
+++ b/scripts/apple/zimg.sh
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+# SET BUILD OPTIONS
+ASM_OPTIONS=""
+case ${ARCH} in
+armv7 | armv7s)
+ ASM_OPTIONS="--disable-simd"
+ ;;
+esac
+
+# ALWAYS CLEAN THE PREVIOUS BUILD
+make distclean 2>/dev/null 1>/dev/null
+
+# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
+if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/configure ]] || [[ ${RECONF_zimg} -eq 1 ]]; then
+ ./autogen.sh || return 1
+fi
+
+./configure \
+ --prefix="${LIB_INSTALL_PREFIX}" \
+ --with-pic \
+ --with-sysroot="${SDK_PATH}" \
+ --enable-static \
+ --disable-shared \
+ --disable-fast-install \
+ ${ASM_OPTIONS} \
+ --host="${HOST}" || return 1
+
+make -j$(get_cpu_count) || return 1
+
+make install || return 1
+
+# MANUALLY COPY PKG-CONFIG FILES
+cp ./zimg.pc "${INSTALL_PKG_CONFIG_DIR}" || return 1
diff --git a/scripts/function-android.sh b/scripts/function-android.sh
index 8272186..c1c6029 100755
--- a/scripts/function-android.sh
+++ b/scripts/function-android.sh
@@ -2,6 +2,8 @@
source "${BASEDIR}/scripts/function.sh"
+prepare_inline_sed
+
enable_default_android_architectures() {
ENABLED_ARCHITECTURES[ARCH_ARM_V7A]=1
ENABLED_ARCHITECTURES[ARCH_ARM_V7A_NEON]=1
@@ -31,7 +33,7 @@ under the prebuilt folder.\n"
echo -e "Usage: ./$COMMAND [OPTION]... [VAR=VALUE]...\n"
echo -e "Specify environment variables as VARIABLE=VALUE to override default build options.\n"
- display_help_options " -l, --lts\t\t\tbuild lts packages to support API 16+ devices" " --api-level=api\t\toverride Android api level" " --no-ffmpeg-kit-protocols\tdisable custom ffmpeg-kit protocols (fd, saf)"
+ display_help_options " -l, --lts\t\t\tbuild lts packages to support API 16+ devices" " --api-level=api\t\toverride Android api level" " --no-ffmpeg-kit-protocols\tdisable custom ffmpeg-kit protocols (saf)"
display_help_licensing
echo -e "Architectures:"
@@ -48,6 +50,7 @@ under the prebuilt folder.\n"
display_help_common_libraries
display_help_gpl_libraries
+ display_help_custom_libraries
display_help_advanced_options " --no-archive\t\t\tdo not build Android archive [no]"
}
@@ -67,7 +70,7 @@ build_application_mk() {
local LTS_BUILD_FLAG="-DFFMPEG_KIT_LTS "
fi
- if [[ ${ENABLED_LIBRARIES[$LIBRARY_X265]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_TESSERACT]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_OPENH264]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_SNAPPY]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_RUBBERBAND]} -eq 1 ]]; then
+ if [[ ${ENABLED_LIBRARIES[$LIBRARY_X265]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_TESSERACT]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_OPENH264]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_SNAPPY]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_RUBBERBAND]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_ZIMG]} -eq 1 ]] || [[ ${ENABLED_LIBRARIES[$LIBRARY_SRT]} -eq 1 ]] || [[ -n ${CUSTOM_LIBRARY_USES_CPP} ]]; then
local APP_STL="c++_shared"
else
local APP_STL="none"
@@ -248,7 +251,7 @@ get_arch_specific_cflags() {
x86)
case ${DETECTED_NDK_VERSION} in
23*)
- echo "-march=i686 -mssse3 -mfpmath=sse -m32 -DFFMPEG_KIT_X86"
+ echo "-march=i686 -mtune=generic -mssse3 -mfpmath=sse -m32 -DFFMPEG_KIT_X86"
;;
*)
echo "-march=i686 -mtune=intel -mssse3 -mfpmath=sse -m32 -DFFMPEG_KIT_X86"
@@ -258,7 +261,7 @@ get_arch_specific_cflags() {
x86-64)
case ${DETECTED_NDK_VERSION} in
23*)
- echo "-march=x86-64 -msse4.2 -mpopcnt -m64 -DFFMPEG_KIT_X86_64"
+ echo "-march=x86-64 -msse4.2 -mpopcnt -m64 -mtune=generic -DFFMPEG_KIT_X86_64"
;;
*)
echo "-march=x86-64 -msse4.2 -mpopcnt -m64 -mtune=intel -DFFMPEG_KIT_X86_64"
@@ -332,7 +335,7 @@ get_app_specific_cflags() {
rubberband)
APP_FLAGS="-std=c99 -Wno-unused-function"
;;
- libvpx | shine)
+ libvpx | openssl | shine | srt)
APP_FLAGS="-Wno-unused-function"
;;
soxr | snappy | libwebp)
@@ -390,7 +393,7 @@ get_cxxflags() {
x265)
echo "-std=c++11 -fno-exceptions ${OPTIMIZATION_FLAGS}"
;;
- rubberband)
+ rubberband | srt | zimg)
echo "-std=c++11 ${OPTIMIZATION_FLAGS}"
;;
*)
@@ -404,16 +407,19 @@ get_common_linked_libraries() {
case $1 in
ffmpeg)
- if [[ -z ${FFMPEG_KIT_LTS_BUILD} ]]; then
+
+ # SUPPORTED ON API LEVEL 24 AND LATER
+ if [[ ${API} -ge 24 ]]; then
echo "-lc -lm -ldl -llog -lcamera2ndk -lmediandk ${COMMON_LIBRARY_PATHS}"
else
echo "-lc -lm -ldl -llog ${COMMON_LIBRARY_PATHS}"
+ echo -e "INFO: Building ffmpeg without native camera API which is not supported on Android API Level ${API}\n" 1>>"${BASEDIR}"/build.log 2>&1
fi
;;
libvpx)
echo "-lc -lm ${COMMON_LIBRARY_PATHS}"
;;
- tesseract | x265)
+ srt | tesseract | x265)
echo "-lc -lm -ldl -llog -lc++_shared ${COMMON_LIBRARY_PATHS}"
;;
*)
@@ -798,6 +804,26 @@ Cflags: -I\${includedir}
EOF
}
+create_srt_package_config() {
+ local SRT_VERSION="$1"
+
+ cat >"${INSTALL_PKG_CONFIG_DIR}/srt.pc" <"${INSTALL_PKG_CONFIG_DIR}/zimg.pc" <>"${BASEDIR}"/build.log 2>&1
fi
-
- prepare_inline_sed
}
build_android_lts_support() {
diff --git a/scripts/function-apple.sh b/scripts/function-apple.sh
index 05bb2ec..1d74b93 100755
--- a/scripts/function-apple.sh
+++ b/scripts/function-apple.sh
@@ -5,7 +5,7 @@ source "${BASEDIR}/scripts/function.sh"
export FFMPEG_LIBS=("libavcodec" "libavdevice" "libavfilter" "libavformat" "libavutil" "libswresample" "libswscale")
get_ffmpeg_kit_version() {
- local FFMPEG_KIT_VERSION=$(grep 'const FFMPEG_KIT_VERSION' "${BASEDIR}"/apple/src/FFmpegKit.m | grep -Eo '\".*\"' | sed -e 's/\"//g')
+ local FFMPEG_KIT_VERSION=$(grep 'const FFmpegKitVersion' "${BASEDIR}"/apple/src/FFmpegKitConfig.m | grep -Eo '\".*\"' | sed -e 's/\"//g')
if [[ -z ${FFMPEG_KIT_LTS_BUILD} ]]; then
echo "${FFMPEG_KIT_VERSION}"
@@ -22,7 +22,6 @@ get_external_library_version() {
#
# 1. architecture index
-# 2. detected sdk version
#
disable_ios_architecture_not_supported_on_detected_sdk_version() {
local ARCH_NAME=$(get_arch_name $1)
@@ -31,7 +30,7 @@ disable_ios_architecture_not_supported_on_detected_sdk_version() {
armv7 | armv7s | i386)
# SUPPORTED UNTIL IOS SDK 10.3.1
- if [[ $(compare_versions "$2" "10.3.1") -le 0 ]]; then
+ if [[ $(compare_versions "$IOS_MIN_VERSION" "10.3.1") -le 0 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
@@ -40,7 +39,7 @@ disable_ios_architecture_not_supported_on_detected_sdk_version() {
arm64e)
# INTRODUCED IN IOS SDK 10.1
- if [[ $(compare_versions "$2" "10.1") -ge 1 ]]; then
+ if [[ $(compare_versions "$DETECTED_IOS_SDK_VERSION" "10.1") -ge 1 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
@@ -49,16 +48,25 @@ disable_ios_architecture_not_supported_on_detected_sdk_version() {
x86-64-mac-catalyst)
# INTRODUCED IN IOS SDK 13.0
- if [[ $(compare_versions "$2" "13") -ge 1 ]]; then
+ if [[ $(compare_versions "$DETECTED_IOS_SDK_VERSION" "13.0") -ge 1 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
fi
;;
- arm64-*)
+ arm64-mac-catalyst)
# INTRODUCED IN IOS SDK 14.0
- if [[ $(compare_versions "$2" "14") -ge 1 ]]; then
+ if [[ $(compare_versions "$DETECTED_IOS_SDK_VERSION" "14.0") -ge 1 ]]; then
+ local SUPPORTED=1
+ else
+ local SUPPORTED=0
+ fi
+ ;;
+ arm64-simulator)
+
+ # INTRODUCED IN IOS SDK 14.0
+ if [[ $(compare_versions "$DETECTED_IOS_SDK_VERSION" "14.0") -ge 1 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
@@ -71,7 +79,7 @@ disable_ios_architecture_not_supported_on_detected_sdk_version() {
if [[ ${SUPPORTED} -ne 1 ]]; then
if [[ -z ${BUILD_FORCE} ]]; then
- echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported on SDK $2\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported with Min iOS Target $IOS_MIN_VERSION and Min Mac Catalyst Target $MAC_CATALYST_MIN_VERSION on iOS SDK $DETECTED_IOS_SDK_VERSION\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "${ARCH_NAME}"
fi
fi
@@ -79,7 +87,6 @@ disable_ios_architecture_not_supported_on_detected_sdk_version() {
#
# 1. architecture index
-# 2. detected sdk version
#
disable_tvos_architecture_not_supported_on_detected_sdk_version() {
local ARCH_NAME=$(get_arch_name $1)
@@ -88,7 +95,7 @@ disable_tvos_architecture_not_supported_on_detected_sdk_version() {
arm64-simulator)
# INTRODUCED IN TVOS SDK 14.0
- if [[ $(compare_versions "$2" "14") -ge 1 ]]; then
+ if [[ $(compare_versions "$DETECTED_TVOS_SDK_VERSION" "14.0") -ge 1 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
@@ -101,7 +108,7 @@ disable_tvos_architecture_not_supported_on_detected_sdk_version() {
if [[ ${SUPPORTED} -ne 1 ]]; then
if [[ -z ${BUILD_FORCE} ]]; then
- echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported on SDK $2\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported on tvOS SDK $DETECTED_TVOS_SDK_VERSION\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "${ARCH_NAME}"
fi
fi
@@ -109,7 +116,6 @@ disable_tvos_architecture_not_supported_on_detected_sdk_version() {
#
# 1. architecture index
-# 2. detected sdk version
#
disable_macos_architecture_not_supported_on_detected_sdk_version() {
local ARCH_NAME=$(get_arch_name $1)
@@ -118,7 +124,7 @@ disable_macos_architecture_not_supported_on_detected_sdk_version() {
arm64)
# INTRODUCED IN MACOS SDK 11.0
- if [[ $(compare_versions "$2" "11") -ge 1 ]]; then
+ if [[ $(compare_versions "$DETECTED_MACOS_SDK_VERSION" "11.0") -ge 1 ]]; then
local SUPPORTED=1
else
local SUPPORTED=0
@@ -131,12 +137,21 @@ disable_macos_architecture_not_supported_on_detected_sdk_version() {
if [[ ${SUPPORTED} -ne 1 ]]; then
if [[ -z ${BUILD_FORCE} ]]; then
- echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported on SDK $2\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "INFO: Disabled ${ARCH_NAME} architecture which is not supported on macOS SDK $DETECTED_MACOS_SDK_VERSION\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "${ARCH_NAME}"
fi
fi
}
+disable_tvos_videotoolbox_on_not_supported_sdk_version() {
+
+ # INTRODUCED IN TVOS SDK 10.2
+ if [[ $(compare_versions "$TVOS_MIN_VERSION" "10.2") -lt 0 ]]; then
+ set_library "tvos-videotoolbox" 0
+ echo -e "INFO: Disabled tvos-videotoolbox which is not supported on tvOS SDK $TVOS_MIN_VERSION\n" 1>>"${BASEDIR}"/build.log 2>&1
+ fi
+}
+
build_apple_architecture_variant_strings() {
export ALL_IOS_ARCHITECTURES="$(get_apple_architectures_for_variant "${ARCH_VAR_IOS}")"
export IPHONEOS_ARCHITECTURES="$(get_apple_architectures_for_variant "${ARCH_VAR_IPHONEOS}")"
@@ -184,109 +199,6 @@ initialize_folder() {
return 0
}
-#
-# 1. library index
-# 2. static library name
-# 3. universal library directory
-# 4. target architectures array
-#
-# DEPENDS TARGET_ARCH_LIST VARIABLE
-#
-create_single_universal_library() {
- local LIBRARY_INDEX="$1"
- local STATIC_LIBRARY_NAME="$2"
- local UNIVERSAL_DIRECTORY_PATH="$3"
- local TARGET_ARCHITECTURES=("$4")
- local LIBRARY_NAME=$(get_library_name "${LIBRARY_INDEX}")
- local LIPO="$(xcrun --sdk "$(get_default_sdk_name)" -f lipo)"
-
- local LIPO_COMMAND="${LIPO} -create"
-
- for ARCH in "${TARGET_ARCH_LIST[@]}"; do
- if [[ " ${TARGET_ARCHITECTURES[*]} " == *" ${ARCH} "* ]]; then
- local FULL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_build_directory)/${LIBRARY_NAME}/lib/${STATIC_LIBRARY_NAME}"
- LIPO_COMMAND+=" ${FULL_LIBRARY_PATH}"
- fi
- done
-
- LIPO_COMMAND+=" -output ${UNIVERSAL_DIRECTORY_PATH}/lib/${STATIC_LIBRARY_NAME}"
-
- mkdir -p "${UNIVERSAL_DIRECTORY_PATH}/lib" 1>>"${BASEDIR}"/build.log 2>&1
-
- ${LIPO_COMMAND} 1>>"${BASEDIR}"/build.log 2>&1
-
- if [[ $? -ne 0 ]]; then
- echo -e "\nINFO: Failed to build universal ${LIBRARY_NAME} library\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
-
- RC=$(copy_external_library_license "$LIBRARY_INDEX" "${UNIVERSAL_DIRECTORY_PATH}")
-
- if [[ ${RC} -ne 0 ]]; then
- echo -e "\nINFO: Failed to build universal ${LIBRARY_NAME} library\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
-}
-
-#
-# 1. library index
-# 2. architecture variant
-#
-# DEPENDS TARGET_ARCH_LIST VARIABLE
-#
-create_universal_library() {
- local LIBRARY_INDEX="$1"
- local ARCHITECTURE_VARIANT="$2"
- local TARGET_ARCHITECTURES=("$(get_apple_architectures_for_variant "${ARCHITECTURE_VARIANT}")")
- local LIBRARY_NAME=$(get_library_name "${LIBRARY_INDEX}")
- local UNIVERSAL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
-
- if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
-
- # THERE ARE NO ARCHITECTURES ENABLED FOR THIS LIBRARY TYPE
- return
- fi
-
- initialize_folder "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}"
-
- if [[ ${LIBRARY_LIBTHEORA} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_universal_library "${LIBRARY_INDEX}" "libtheora.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libtheoraenc.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libtheoradec.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- elif [[ ${LIBRARY_LIBVORBIS} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_universal_library "${LIBRARY_INDEX}" "libvorbisfile.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libvorbisenc.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libvorbis.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- elif [[ ${LIBRARY_LIBWEBP} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_universal_library "${LIBRARY_INDEX}" "libwebpmux.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libwebpdemux.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libwebp.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- elif [[ ${LIBRARY_OPENCOREAMR} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_universal_library "${LIBRARY_INDEX}" "libopencore-amrnb.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- elif [[ ${LIBRARY_NETTLE} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_universal_library "${LIBRARY_INDEX}" "libnettle.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
- create_single_universal_library "${LIBRARY_INDEX}" "libhogweed.a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- else
-
- create_single_universal_library "${LIBRARY_INDEX}" "$(get_static_archive_name "${LIBRARY_INDEX}").a" "${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}" "${TARGET_ARCHITECTURES[@]}"
-
- fi
-
- echo -e "DEBUG: ${LIBRARY_NAME} universal library built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
-}
-
#
# 1. architecture variant
#
@@ -296,8 +208,8 @@ create_ffmpeg_universal_library() {
local ARCHITECTURE_VARIANT="$1"
local TARGET_ARCHITECTURES=("$(get_apple_architectures_for_variant "${ARCHITECTURE_VARIANT}")")
local LIBRARY_NAME="ffmpeg"
- local UNIVERSAL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
- local FFMPEG_UNIVERSAL_LIBRARY_PATH="${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}"
+ local UNIVERSAL_LIBRARY_DIRECTORY="${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
+ local FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY="${UNIVERSAL_LIBRARY_DIRECTORY}/${LIBRARY_NAME}"
local LIPO="$(xcrun --sdk "$(get_default_sdk_name)" -f lipo)"
if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
@@ -307,43 +219,73 @@ create_ffmpeg_universal_library() {
fi
# INITIALIZE UNIVERSAL LIBRARY DIRECTORY
- initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_PATH}"
- initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include"
- initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/lib"
+ initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"
+ initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}/include"
+ initialize_folder "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}/lib"
local FFMPEG_DEFAULT_BUILD_PATH="${BASEDIR}/prebuilt/$(get_default_build_directory)/ffmpeg"
# COPY HEADER FILES
- cp -r "${FFMPEG_DEFAULT_BUILD_PATH}"/include/* "${FFMPEG_UNIVERSAL_LIBRARY_PATH}"/include 1>>"${BASEDIR}"/build.log 2>&1
- cp "${FFMPEG_DEFAULT_BUILD_PATH}"/include/config.h "${FFMPEG_UNIVERSAL_LIBRARY_PATH}"/include 1>>"${BASEDIR}"/build.log 2>&1
+ cp -r "${FFMPEG_DEFAULT_BUILD_PATH}"/include/* "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"/include 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${FFMPEG_DEFAULT_BUILD_PATH}"/include/config.h "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"/include 1>>"${BASEDIR}"/build.log 2>&1
for FFMPEG_LIB in "${FFMPEG_LIBS[@]}"; do
+ local FFMPEG_LIB_UNIVERSAL_LIBRARY_PATH="${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}/lib/${FFMPEG_LIB}.dylib"
+
LIPO_COMMAND="${LIPO} -create"
for ARCH in "${TARGET_ARCH_LIST[@]}"; do
if [[ " ${TARGET_ARCHITECTURES[*]} " == *" ${ARCH} "* ]]; then
- local FULL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_build_directory)/${LIBRARY_NAME}/lib/${FFMPEG_LIB}.a"
+ local FULL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_build_directory)/${LIBRARY_NAME}/lib/${FFMPEG_LIB}.$(get_ffmpeg_library_version ${FFMPEG_LIB}).dylib"
LIPO_COMMAND+=" ${FULL_LIBRARY_PATH}"
fi
done
- LIPO_COMMAND+=" -output ${FFMPEG_UNIVERSAL_LIBRARY_PATH}/lib/${FFMPEG_LIB}.a"
+ LIPO_COMMAND+=" -output ${FFMPEG_LIB_UNIVERSAL_LIBRARY_PATH}"
${LIPO_COMMAND} 1>>"${BASEDIR}"/build.log 2>&1
- if [[ $? -ne 0 ]]; then
- echo -e "\nINFO: Failed to build universal ${LIBRARY_NAME} library\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
+ [[ $? -ne 0 ]] && exit_universal_library "${FFMPEG_LIB}"
+
done
# COPY UNIVERSAL LIBRARY LICENSES
if [[ ${GPL_ENABLED} == "yes" ]]; then
- cp "${BASEDIR}"/LICENSE.GPLv3 "${FFMPEG_UNIVERSAL_LIBRARY_PATH}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${BASEDIR}"/LICENSE.GPLv3 "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
else
- cp "${BASEDIR}"/LICENSE.LGPLv3 "${FFMPEG_UNIVERSAL_LIBRARY_PATH}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${BASEDIR}"/LICENSE.LGPLv3 "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
fi
+ for library in {0..49}; do
+ if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
+ local ENABLED_LIBRARY_NAME="$(get_library_name ${library})"
+ local ENABLED_LIBRARY_NAME_UPPERCASE=$(echo "${ENABLED_LIBRARY_NAME}" | tr '[a-z]' '[A-Z]')
+
+ RC=$(copy_external_library_license "${library}" "${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}"/LICENSE.${ENABLED_LIBRARY_NAME_UPPERCASE})
+
+ [[ ${RC} -ne 0 ]] && exit_universal_library "${LIBRARY_NAME}"
+ fi
+ done
+
+ # COPY CUSTOM LIBRARY LICENSES
+ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+ library_name_uppercase=$(echo "${!library_name}" | tr '[a-z]' '[A-Z]')
+ relative_license_path="CUSTOM_LIBRARY_${custom_library_index}_LICENSE_FILE"
+
+ destination_license_path="${FFMPEG_UNIVERSAL_LIBRARY_DIRECTORY}/LICENSE.${library_name_uppercase}"
+
+ cp "${BASEDIR}/src/${!library_name}/${!relative_license_path}" "${destination_license_path}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ if [[ ${RC} -ne 0 ]]; then
+ echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+
+ echo -e "DEBUG: Copied the license file of custom library ${!library_name} successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
+ done
echo -e "DEBUG: ${LIBRARY_NAME} universal library built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
}
@@ -357,8 +299,8 @@ create_ffmpeg_kit_universal_library() {
local ARCHITECTURE_VARIANT="$1"
local TARGET_ARCHITECTURES=("$(get_apple_architectures_for_variant "${ARCHITECTURE_VARIANT}")")
local LIBRARY_NAME="ffmpeg-kit"
- local UNIVERSAL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
- local FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH="${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}"
+ local UNIVERSAL_LIBRARY_DIRECTORY="${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
+ local FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY="${UNIVERSAL_LIBRARY_DIRECTORY}/${LIBRARY_NAME}"
local LIPO="$(xcrun --sdk "$(get_default_sdk_name)" -f lipo)"
if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
@@ -368,92 +310,50 @@ create_ffmpeg_kit_universal_library() {
fi
# INITIALIZE UNIVERSAL LIBRARY DIRECTORY
- initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"
- initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}/include"
- initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}/lib"
+ initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"
+ initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}/include"
+ initialize_folder "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}/lib"
local FFMPEG_KIT_DEFAULT_BUILD_PATH="${BASEDIR}/prebuilt/$(get_default_build_directory)/ffmpeg-kit"
# COPY HEADER FILES
- cp -r "${FFMPEG_KIT_DEFAULT_BUILD_PATH}"/include/* "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"/include 1>>"${BASEDIR}"/build.log 2>&1
+ cp -r "${FFMPEG_KIT_DEFAULT_BUILD_PATH}"/include/* "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"/include 1>>"${BASEDIR}"/build.log 2>&1
+
+ local FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH="${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}/lib/libffmpegkit.dylib"
LIPO_COMMAND="${LIPO} -create"
for ARCH in "${TARGET_ARCH_LIST[@]}"; do
if [[ " ${TARGET_ARCHITECTURES[*]} " == *" ${ARCH} "* ]]; then
- local FULL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_build_directory)/${LIBRARY_NAME}/lib/libffmpegkit.a"
+ local FULL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_build_directory)/${LIBRARY_NAME}/lib/libffmpegkit.dylib"
LIPO_COMMAND+=" ${FULL_LIBRARY_PATH}"
fi
done
- LIPO_COMMAND+=" -output ${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}/lib/libffmpegkit.a"
+ LIPO_COMMAND+=" -output ${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"
${LIPO_COMMAND} 1>>"${BASEDIR}"/build.log 2>&1
- if [[ $? -ne 0 ]]; then
- echo -e "\nINFO: Failed to build universal ${LIBRARY_NAME} library\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
+ [[ $? -ne 0 ]] && exit_universal_library "${LIBRARY_NAME}"
# COPY UNIVERSAL LIBRARY LICENSES
if [[ ${GPL_ENABLED} == "yes" ]]; then
- cp "${BASEDIR}"/LICENSE.GPLv3 "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${BASEDIR}"/LICENSE.GPLv3 "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
else
- cp "${BASEDIR}"/LICENSE.LGPLv3 "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${BASEDIR}"/LICENSE.LGPLv3 "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"/LICENSE 1>>"${BASEDIR}"/build.log 2>&1
fi
echo -e "DEBUG: ${LIBRARY_NAME} universal library built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
}
#
-# 1. library index
-# 2. library version
-# 3. static library name
-# 4. framework name
-# 5. architecture variant
-#
-create_single_framework() {
- local LIBRARY_INDEX="$1"
- local LIBRARY_VERSION="$2"
- local STATIC_LIBRARY_NAME="$3"
- local FRAMEWORK_NAME="$4"
- local ARCHITECTURE_VARIANT="$5"
- local LIBRARY_NAME=$(get_library_name "${LIBRARY_INDEX}")
- local FRAMEWORK_PATH=${BASEDIR}/prebuilt/$(get_framework_directory "${ARCHITECTURE_VARIANT}")/${FRAMEWORK_NAME}.framework
-
- initialize_folder "${FRAMEWORK_PATH}"
-
- local CAPITAL_CASE_FRAMEWORK_NAME=$(to_capital_case "${FRAMEWORK_NAME}")
-
- build_info_plist "${FRAMEWORK_PATH}/Info.plist" "${LIBRARY_NAME}" "com.arthenica.ffmpegkit.${CAPITAL_CASE_FRAMEWORK_NAME}" "${LIBRARY_VERSION}" "${LIBRARY_VERSION}"
-
- cp "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")/${LIBRARY_NAME}/lib/${STATIC_LIBRARY_NAME}.a" "${FRAMEWORK_PATH}/${FRAMEWORK_NAME}" 1>>"${BASEDIR}/build.log" 2>&1
-
- if [[ $? -ne 0 ]]; then
- echo -e "\nINFO: Failed to build ${LIBRARY_NAME} framework\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
-
- RC=$(copy_external_library_license "$LIBRARY_INDEX" "${FRAMEWORK_PATH}")
-
- if [[ ${RC} -ne 0 ]]; then
- echo -e "\nINFO: Failed to build ${LIBRARY_NAME} framework\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
-}
-
-#
-# 1. library index
-# 2. architecture variant
+# 1. architecture variant
#
-create_framework() {
- local LIBRARY_INDEX="$1"
- local ARCHITECTURE_VARIANT="$2"
- local LIBRARY_NAME=$(get_library_name "${LIBRARY_INDEX}")
- local PACKAGE_CONFIG_FILE_NAME=$(get_package_config_file_name "${LIBRARY_INDEX}")
+create_ffmpeg_framework() {
+ local ARCHITECTURE_VARIANT="$1"
+ local LIBRARY_NAME="ffmpeg"
+ local UNIVERSAL_LIBRARY_DIRECTORY="${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
+ local FFMPEG_UNIVERSAL_LIBRARY_PATH="${UNIVERSAL_LIBRARY_DIRECTORY}/${LIBRARY_NAME}"
if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
@@ -461,94 +361,97 @@ create_framework() {
return
fi
- # EACH ENABLED LIBRARY HAS TO HAVE A .pc FILE AND A VERSION
- local LIBRARY_VERSION=$(get_external_library_version "${PACKAGE_CONFIG_FILE_NAME}")
- if [[ -z ${LIBRARY_VERSION} ]]; then
- echo -e "Failed to detect the version off ${LIBRARY_NAME} from ${PACKAGE_CONFIG_FILE_NAME}.pc\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
+ for FFMPEG_LIB in "${FFMPEG_LIBS[@]}"; do
+ local FFMPEG_LIB_UPPERCASE=$(echo "${FFMPEG_LIB}" | tr '[a-z]' '[A-Z]')
+ local CAPITAL_CASE_FFMPEG_LIB_NAME=$(to_capital_case "${FFMPEG_LIB}")
- if [[ ${LIBRARY_LIBTHEORA} == "${LIBRARY_INDEX}" ]]; then
+ # EXTRACT FFMPEG VERSION
+ local FFMPEG_LIB_VERSION="$(get_ffmpeg_library_version $FFMPEG_LIB)"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libtheora" "libtheora" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libtheoraenc" "libtheoraenc" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libtheoradec" "libtheoradec" "${ARCHITECTURE_VARIANT}"
+ # INITIALIZE FRAMEWORK DIRECTORY
+ local FFMPEG_LIB_FRAMEWORK_PATH="${BASEDIR}/prebuilt/$(get_framework_directory "${ARCHITECTURE_VARIANT}")/${FFMPEG_LIB}.framework"
+ initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}"
- elif [[ ${LIBRARY_LIBVORBIS} == "${LIBRARY_INDEX}" ]]; then
+ if [[ ${ARCHITECTURE_VARIANT} -eq ${ARCH_VAR_MAC_CATALYST} ]] || [[ ${ARCHITECTURE_VARIANT} -eq ${ARCH_VAR_MACOS} ]]; then
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libvorbisfile" "libvorbisfile" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libvorbisenc" "libvorbisenc" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libvorbis" "libvorbis" "${ARCHITECTURE_VARIANT}"
+ # VERSIONED FRAMEWORK
- elif [[ ${LIBRARY_LIBWEBP} == "${LIBRARY_INDEX}" ]]; then
+ local FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH="${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/A/Resources"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libwebpmux" "libwebpmux" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libwebpdemux" "libwebpdemux" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libwebp" "libwebp" "${ARCHITECTURE_VARIANT}"
+ initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/A/Headers"
+ initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/A/Resources"
- elif [[ ${LIBRARY_OPENCOREAMR} == "${LIBRARY_INDEX}" ]]; then
+ # LINK CURRENT VERSION
+ ln -s "A" "${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/Current" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/Headers" "${FFMPEG_LIB_FRAMEWORK_PATH}/Headers" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/Resources" "${FFMPEG_LIB_FRAMEWORK_PATH}/Resources" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/${FFMPEG_LIB}" "${FFMPEG_LIB_FRAMEWORK_PATH}/${FFMPEG_LIB}" 1>>"${BASEDIR}"/build.log 2>&1
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libopencore-amrnb" "libopencore-amrnb" "${ARCHITECTURE_VARIANT}"
+ # COPY HEADER FILES
+ cp -r "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}"/* "${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/A/Headers" 1>>"${BASEDIR}"/build.log 2>&1
- elif [[ ${LIBRARY_NETTLE} == "${LIBRARY_INDEX}" ]]; then
+ # COPY LIBRARY FILE
+ cp "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/lib/${FFMPEG_LIB}.dylib" "${FFMPEG_LIB_FRAMEWORK_PATH}/Versions/A/${FFMPEG_LIB}" 1>>"${BASEDIR}"/build.log 2>&1
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libnettle" "libnettle" "${ARCHITECTURE_VARIANT}"
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "libhogweed" "libhogweed" "${ARCHITECTURE_VARIANT}"
+ else
- else
+ # DEFAULT FRAMEWORK
- create_single_framework "${LIBRARY_INDEX}" "${LIBRARY_VERSION}" "$(get_static_archive_name "${LIBRARY_INDEX}")" "${LIBRARY_NAME}" "${ARCHITECTURE_VARIANT}"
+ local FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH="${FFMPEG_LIB_FRAMEWORK_PATH}"
- fi
+ initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}/Headers"
- echo -e "DEBUG: ${LIBRARY_NAME} framework built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
-}
+ # COPY HEADER FILES
+ cp -r "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}"/* "${FFMPEG_LIB_FRAMEWORK_PATH}"/Headers 1>>"${BASEDIR}"/build.log 2>&1
-#
-# 1. architecture variant
-#
-create_ffmpeg_framework() {
- local ARCHITECTURE_VARIANT="$1"
- local LIBRARY_NAME="ffmpeg"
- local UNIVERSAL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
- local FFMPEG_UNIVERSAL_LIBRARY_PATH="${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}"
+ # COPY LIBRARY FILE
+ cp "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/lib/${FFMPEG_LIB}.dylib" "${FFMPEG_LIB_FRAMEWORK_PATH}/${FFMPEG_LIB}" 1>>"${BASEDIR}"/build.log 2>&1
- if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
+ fi
- # THERE ARE NO ARCHITECTURES ENABLED FOR THIS LIBRARY TYPE
- return
- fi
+ # COPY FRAMEWORK LICENSES
+ if [[ "${GPL_ENABLED}" == "yes" ]]; then
+ cp "${BASEDIR}/LICENSE.GPLv3" "${FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
+ else
+ cp "${BASEDIR}/LICENSE.LGPLv3" "${FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
+ fi
- for FFMPEG_LIB in "${FFMPEG_LIBS[@]}"; do
- local FFMPEG_LIB_UPPERCASE=$(echo "${FFMPEG_LIB}" | tr '[a-z]' '[A-Z]')
- local CAPITAL_CASE_FFMPEG_LIB_NAME=$(to_capital_case "${FFMPEG_LIB}")
+ # COPY EXTERNAL LIBRARY LICENSES
+ if [[ "${FFMPEG_LIB}" == "libavcodec" ]]; then
+ for library in {0..49}; do
+ if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
+ local ENABLED_LIBRARY_NAME="$(get_library_name ${library})"
+ local ENABLED_LIBRARY_NAME_UPPERCASE=$(echo "${ENABLED_LIBRARY_NAME}" | tr '[a-z]' '[A-Z]')
- # EXTRACT FFMPEG VERSION
- local FFMPEG_LIB_MAJOR=$(grep "#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MAJOR" "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}/version.h" | sed -e "s/#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MAJOR//g;s/\ //g")
- local FFMPEG_LIB_MINOR=$(grep "#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MINOR" "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}/version.h" | sed -e "s/#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MINOR//g;s/\ //g")
- local FFMPEG_LIB_MICRO=$(grep "#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MICRO" "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}/version.h" | sed "s/#define ${FFMPEG_LIB_UPPERCASE}_VERSION_MICRO//g;s/\ //g")
- local FFMPEG_LIB_VERSION="${FFMPEG_LIB_MAJOR}.${FFMPEG_LIB_MINOR}.${FFMPEG_LIB_MICRO}"
+ RC=$(copy_external_library_license "${library}" ${FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH}/LICENSE.${ENABLED_LIBRARY_NAME_UPPERCASE})
- # INITIALIZE FRAMEWORK DIRECTORY
- local FFMPEG_LIB_FRAMEWORK_PATH="${BASEDIR}/prebuilt/$(get_framework_directory "${ARCHITECTURE_VARIANT}")/${FFMPEG_LIB}.framework"
- initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}"
- initialize_folder "${FFMPEG_LIB_FRAMEWORK_PATH}/Headers"
+ [[ ${RC} -ne 0 ]] && exit_universal_library "${LIBRARY_NAME}"
+ fi
+ done
- # COPY HEADER FILES
- cp -r "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/include/${FFMPEG_LIB}"/* "${FFMPEG_LIB_FRAMEWORK_PATH}"/Headers 1>>"${BASEDIR}"/build.log 2>&1
+ # COPY CUSTOM LIBRARY LICENSES
+ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+ library_name_uppercase=$(echo "${!library_name}" | tr '[a-z]' '[A-Z]')
+ relative_license_path="CUSTOM_LIBRARY_${custom_library_index}_LICENSE_FILE"
- # COPY LIBRARY FILE
- cp "${FFMPEG_UNIVERSAL_LIBRARY_PATH}/lib/${FFMPEG_LIB}.a" "${FFMPEG_LIB_FRAMEWORK_PATH}/${FFMPEG_LIB}" 1>>"${BASEDIR}"/build.log 2>&1
+ destination_license_path="${FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH}/LICENSE.${ENABLED_LIBRARY_NAME_UPPERCASE}"
- # COPY FRAMEWORK LICENSES
- if [[ "${GPL_ENABLED}" == "yes" ]]; then
- cp "${BASEDIR}/LICENSE.GPLv3" "${FFMPEG_LIB_FRAMEWORK_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
- else
- cp "${BASEDIR}/LICENSE.LGPLv3" "${FFMPEG_LIB_FRAMEWORK_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
+ cp "${BASEDIR}/src/${!library_name}/${!relative_license_path}" "${destination_license_path}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ if [[ ${RC} -ne 0 ]]; then
+ echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+
+ echo -e "DEBUG: Copied the license file of custom library ${!library_name} successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
+ done
fi
- build_info_plist "${FFMPEG_LIB_FRAMEWORK_PATH}/Info.plist" "${FFMPEG_LIB}" "com.arthenica.ffmpegkit.${CAPITAL_CASE_FFMPEG_LIB_NAME}" "${FFMPEG_LIB_VERSION}" "${FFMPEG_LIB_VERSION}"
+ build_info_plist "${FFMPEG_LIB_FRAMEWORK_RESOURCE_PATH}/Info.plist" "${FFMPEG_LIB}" "com.arthenica.ffmpegkit.${CAPITAL_CASE_FFMPEG_LIB_NAME}" "${FFMPEG_LIB_VERSION}" "${FFMPEG_LIB_VERSION}" "${ARCHITECTURE_VARIANT}"
echo -e "DEBUG: ${FFMPEG_LIB} framework built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
done
@@ -560,8 +463,8 @@ create_ffmpeg_framework() {
create_ffmpeg_kit_framework() {
local ARCHITECTURE_VARIANT="$1"
local LIBRARY_NAME="ffmpeg-kit"
- local UNIVERSAL_LIBRARY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
- local FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH="${UNIVERSAL_LIBRARY_PATH}/${LIBRARY_NAME}"
+ local UNIVERSAL_LIBRARY_DIRECTORY="${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCHITECTURE_VARIANT}")"
+ local FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY="${UNIVERSAL_LIBRARY_DIRECTORY}/${LIBRARY_NAME}"
if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 0 ]]; then
@@ -574,108 +477,61 @@ create_ffmpeg_kit_framework() {
# INITIALIZE FRAMEWORK DIRECTORY
local FFMPEG_KIT_FRAMEWORK_PATH="${BASEDIR}/prebuilt/$(get_framework_directory "${ARCHITECTURE_VARIANT}")/ffmpegkit.framework"
initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}"
- initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Headers"
- initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Modules"
-
- # COPY HEADER FILES
- cp -r "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}"/include/* "${FFMPEG_KIT_FRAMEWORK_PATH}"/Headers 1>>"${BASEDIR}"/build.log 2>&1
-
- # COPY LIBRARY FILE
- cp "${FFMPEG_KIT_UNIVERSAL_LIBRARY_PATH}/lib/libffmpegkit.a" "${FFMPEG_KIT_FRAMEWORK_PATH}"/ffmpegkit 1>>"${BASEDIR}"/build.log 2>&1
-
- # COPY FRAMEWORK LICENSES
- if [[ "${GPL_ENABLED}" == "yes" ]]; then
- cp "${BASEDIR}/LICENSE.GPLv3" "${FFMPEG_KIT_FRAMEWORK_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
- else
- cp "${BASEDIR}/LICENSE.LGPLv3" "${FFMPEG_KIT_FRAMEWORK_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
- fi
-
- build_info_plist "${FFMPEG_KIT_FRAMEWORK_PATH}/Info.plist" "ffmpegkit" "com.arthenica.ffmpegkit.FFmpegKit" "${FFMPEG_KIT_VERSION}" "${FFMPEG_KIT_VERSION}"
- build_modulemap "${FFMPEG_KIT_FRAMEWORK_PATH}/Modules/module.modulemap"
-
- echo -e "DEBUG: ffmpeg-kit framework built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
-}
-
-#
-# 1. framework name
-#
-create_single_xcframework() {
- local FRAMEWORK_NAME="$1"
- local XCFRAMEWORK_PATH=${BASEDIR}/prebuilt/$(get_xcframework_directory)/${FRAMEWORK_NAME}.xcframework
-
- initialize_folder "${XCFRAMEWORK_PATH}"
- local BUILD_COMMAND="xcodebuild -create-xcframework "
+ if [[ ${ARCHITECTURE_VARIANT} -eq ${ARCH_VAR_MAC_CATALYST} ]] || [[ ${ARCHITECTURE_VARIANT} -eq ${ARCH_VAR_MACOS} ]]; then
- for ARCHITECTURE_VARIANT in "${ARCHITECTURE_VARIANT_ARRAY[@]}"; do
- if [[ $(is_apple_architecture_variant_supported "${ARCHITECTURE_VARIANT}") -eq 1 ]]; then
- local FRAMEWORK_PATH=${BASEDIR}/prebuilt/$(get_framework_directory "${ARCHITECTURE_VARIANT}")/${FRAMEWORK_NAME}.framework
- BUILD_COMMAND+=" -framework ${FRAMEWORK_PATH}"
- fi
- done
+ # VERSIONED FRAMEWORK
- BUILD_COMMAND+=" -output ${XCFRAMEWORK_PATH}"
+ local FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH="${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/Resources"
- # EXECUTE CREATE FRAMEWORK COMMAND
- COMMAND_OUTPUT=$(${BUILD_COMMAND} 2>&1)
- RC=$?
- echo -e "DEBUG: ${COMMAND_OUTPUT}\n" 1>>"${BASEDIR}"/build.log 2>&1
+ initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/Headers"
+ initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/Modules"
+ initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/Resources"
- if [[ ${RC} -ne 0 ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
+ # LINK CURRENT VERSION
+ ln -s "A" "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/Current" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/Headers" "${FFMPEG_KIT_FRAMEWORK_PATH}/Headers" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/Modules" "${FFMPEG_KIT_FRAMEWORK_PATH}/Modules" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/Resources" "${FFMPEG_KIT_FRAMEWORK_PATH}/Resources" 1>>"${BASEDIR}"/build.log 2>&1
+ ln -s "Versions/Current/ffmpegkit" "${FFMPEG_KIT_FRAMEWORK_PATH}/ffmpegkit" 1>>"${BASEDIR}"/build.log 2>&1
- # DO NOT ALLOW EMPTY FRAMEWORKS
- if [[ ${COMMAND_OUTPUT} == *"is empty in library"* ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
- fi
-}
-
-#
-# 1. library index
-#
-create_xcframework() {
- local LIBRARY_INDEX="$1"
- local LIBRARY_NAME=$(get_library_name "${LIBRARY_INDEX}")
-
- if [[ ${LIBRARY_LIBTHEORA} == "${LIBRARY_INDEX}" ]]; then
-
- create_single_xcframework "libtheora"
- create_single_xcframework "libtheoraenc"
- create_single_xcframework "libtheoradec"
+ # COPY HEADER FILES
+ cp -r "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"/include/* "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/Headers" 1>>"${BASEDIR}"/build.log 2>&1
- elif [[ ${LIBRARY_LIBVORBIS} == "${LIBRARY_INDEX}" ]]; then
+ # COPY LIBRARY FILE
+ cp "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}/lib/libffmpegkit.dylib" "${FFMPEG_KIT_FRAMEWORK_PATH}/Versions/A/ffmpegkit" 1>>"${BASEDIR}"/build.log 2>&1
- create_single_xcframework "libvorbisfile"
- create_single_xcframework "libvorbisenc"
- create_single_xcframework "libvorbis"
+ else
- elif [[ ${LIBRARY_LIBWEBP} == "${LIBRARY_INDEX}" ]]; then
+ # DEFAULT FRAMEWORK
- create_single_xcframework "libwebpmux"
- create_single_xcframework "libwebpdemux"
- create_single_xcframework "libwebp"
+ local FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH="${FFMPEG_KIT_FRAMEWORK_PATH}"
- elif [[ ${LIBRARY_OPENCOREAMR} == "${LIBRARY_INDEX}" ]]; then
+ initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Headers"
+ initialize_folder "${FFMPEG_KIT_FRAMEWORK_PATH}/Modules"
- create_single_xcframework "libopencore-amrnb"
+ # COPY HEADER FILES
+ cp -r "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}"/include/* "${FFMPEG_KIT_FRAMEWORK_PATH}"/Headers 1>>"${BASEDIR}"/build.log 2>&1
- elif [[ ${LIBRARY_NETTLE} == "${LIBRARY_INDEX}" ]]; then
+ # COPY LIBRARY FILE
+ cp "${FFMPEG_KIT_UNIVERSAL_LIBRARY_DIRECTORY}/lib/libffmpegkit.dylib" "${FFMPEG_KIT_FRAMEWORK_PATH}"/ffmpegkit 1>>"${BASEDIR}"/build.log 2>&1
- create_single_xcframework "libnettle"
- create_single_xcframework "libhogweed"
+ fi
+ # COPY FRAMEWORK LICENSES
+ if [[ "${GPL_ENABLED}" == "yes" ]]; then
+ cp "${BASEDIR}/LICENSE.GPLv3" "${FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
else
+ cp "${BASEDIR}/LICENSE.LGPLv3" "${FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH}/LICENSE" 1>>"${BASEDIR}"/build.log 2>&1
+ fi
- create_single_xcframework "${LIBRARY_NAME}"
+ # COPYING STRIP SCRIPT FOR SHARED LIBRARY
+ cp ${BASEDIR}/tools/release/apple/strip-frameworks.sh ${FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH} 1>>${BASEDIR}/build.log 2>&1
- fi
+ build_info_plist "${FFMPEG_KIT_FRAMEWORK_RESOURCE_PATH}/Info.plist" "ffmpegkit" "com.arthenica.ffmpegkit.FFmpegKit" "${FFMPEG_KIT_VERSION}" "${FFMPEG_KIT_VERSION}" "${ARCHITECTURE_VARIANT}"
+ build_modulemap "${FFMPEG_KIT_FRAMEWORK_PATH}/Modules/module.modulemap"
- echo -e "DEBUG: xcframework for ${LIBRARY_NAME} built successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "DEBUG: ffmpeg-kit framework built for $(get_apple_architecture_variant "${ARCHITECTURE_VARIANT}") platform successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
}
create_ffmpeg_xcframework() {
@@ -704,16 +560,12 @@ create_ffmpeg_xcframework() {
echo -e "DEBUG: ${COMMAND_OUTPUT}\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
+ exit_xcframework "${FRAMEWORK_NAME}"
fi
# DO NOT ALLOW EMPTY FRAMEWORKS
if [[ ${COMMAND_OUTPUT} == *"is empty in library"* ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
+ exit_xcframework "${FRAMEWORK_NAME}"
fi
echo -e "DEBUG: xcframework for ${FFMPEG_LIB} built successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -744,16 +596,12 @@ create_ffmpeg_kit_xcframework() {
echo -e "DEBUG: ${COMMAND_OUTPUT}\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
+ exit_xcframework "${FRAMEWORK_NAME}"
fi
# DO NOT ALLOW EMPTY FRAMEWORKS
if [[ ${COMMAND_OUTPUT} == *"is empty in library"* ]]; then
- echo -e "INFO: Building ${FRAMEWORK_NAME} xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
- echo -e "failed\n\nSee build.log for details\n"
- exit 1
+ exit_xcframework "${FRAMEWORK_NAME}"
fi
echo -e "DEBUG: xcframework for ffmpeg-kit built successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -1034,12 +882,14 @@ framework module ffmpegkit {
header "AbstractSession.h"
header "ArchDetect.h"
header "AtomicLong.h"
- header "ExecuteCallback.h"
+ header "Chapter.h"
header "FFmpegKit.h"
header "FFmpegKitConfig.h"
header "FFmpegSession.h"
+ header "FFmpegSessionCompleteCallback.h"
header "FFprobeKit.h"
header "FFprobeSession.h"
+ header "FFprobeSessionCompleteCallback.h"
header "Level.h"
header "Log.h"
header "LogCallback.h"
@@ -1047,6 +897,7 @@ framework module ffmpegkit {
header "MediaInformation.h"
header "MediaInformationJsonParser.h"
header "MediaInformationSession.h"
+ header "MediaInformationSessionCompleteCallback.h"
header "Packages.h"
header "ReturnCode.h"
header "Session.h"
@@ -1067,16 +918,29 @@ build_info_plist() {
local FRAMEWORK_ID="$3"
local FRAMEWORK_SHORT_VERSION="$4"
local FRAMEWORK_VERSION="$5"
+ local ARCHITECTURE_VARIANT="$6"
+
case ${FFMPEG_KIT_BUILD_TYPE} in
ios)
+ case ${ARCHITECTURE_VARIANT} in
+ "${ARCH_VAR_MAC_CATALYST}")
+ local MINIMUM_VERSION_KEY="LSMinimumSystemVersion"
+ ;;
+ *)
+ local MINIMUM_VERSION_KEY="MinimumOSVersion"
+ ;;
+ esac
+
local MINIMUM_OS_VERSION="${IOS_MIN_VERSION}"
local SUPPORTED_PLATFORMS="iPhoneOS"
;;
tvos)
+ local MINIMUM_VERSION_KEY="MinimumOSVersion"
local MINIMUM_OS_VERSION="${TVOS_MIN_VERSION}"
local SUPPORTED_PLATFORMS="AppleTVOS"
;;
macos)
+ local MINIMUM_VERSION_KEY="LSMinimumSystemVersion"
local MINIMUM_OS_VERSION="${MACOS_MIN_VERSION}"
local SUPPORTED_PLATFORMS="MacOSX"
;;
@@ -1105,7 +969,7 @@ build_info_plist() {
${FRAMEWORK_VERSION}
CFBundleSignature
????
- MinimumOSVersion
+ ${MINIMUM_VERSION_KEY}
${MINIMUM_OS_VERSION}
CFBundleSupportedPlatforms
@@ -1257,6 +1121,33 @@ get_sdk_path() {
echo "$(xcrun --sdk "$(get_sdk_name)" --show-sdk-path 2>>"${BASEDIR}"/build.log)"
}
+#
+# 1. XCFRAMEWORK NAME
+#
+exit_xcframework() {
+ echo -e "INFO: Building $1 xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+}
+
+#
+# 1. FRAMEWORK NAME
+#
+exit_framework() {
+ echo -e "INFO: Building $1 framework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+}
+
+#
+# 1. UNIVERSAL LIBRARY NAME
+#
+exit_universal_library() {
+ echo -e "\nINFO: Failed to build universal $1 library\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+}
+
create_mason_cross_file() {
cat >"$1" <"${INSTALL_PKG_CONFIG_DIR}/gnutls.pc" <>"${BASEDIR}"/build.log 2>&1) || exit 1
+ (chmod +x "${FFMPEG_KIT_TMPDIR}"/gas-preprocessor.pl 1>>"${BASEDIR}"/build.log 2>&1) || return 1
# patch gas-preprocessor.pl against the following warning
# Unescaped left brace in regex is deprecated here (and will be fatal in Perl 5.32), passed through in regex; marked by <-- HERE in m/(?:ld|st)\d\s+({ <-- HERE \s*v(\d+)\.(\d[bhsdBHSD])\s*-\s*v(\d+)\.(\d[bhsdBHSD])\s*})/ at /Users/taner/Projects/ffmpeg-kit/.tmp/gas-preprocessor.pl line 1065.
@@ -463,8 +481,6 @@ set_toolchain_paths() {
if [ ! -f "${LIB_UUID_PACKAGE_CONFIG_PATH}" ]; then
create_libuuid_system_package_config
fi
-
- prepare_inline_sed
}
initialize_prebuilt_ios_folders() {
@@ -473,15 +489,15 @@ initialize_prebuilt_ios_folders() {
echo -e "DEBUG: Initializing universal directories and frameworks for xcf builds\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_IPHONEOS}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_IPHONEOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_IPHONEOS}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_IPHONEOS}")"
fi
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_IPHONESIMULATOR}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_IPHONESIMULATOR}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_IPHONESIMULATOR}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_IPHONESIMULATOR}")"
fi
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_MAC_CATALYST}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_MAC_CATALYST}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_MAC_CATALYST}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_MAC_CATALYST}")"
fi
@@ -491,10 +507,10 @@ initialize_prebuilt_ios_folders() {
initialize_folder "${BASEDIR}/prebuilt/$(get_xcframework_directory)"
else
- echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_IOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_IOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
# DEFAULT BUILDS GENERATE UNIVERSAL LIBRARIES AND FRAMEWORKS
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_IOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_IOS}")"
echo -e "DEBUG: Initializing framework directory at ${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_IOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -506,16 +522,10 @@ initialize_prebuilt_ios_folders() {
# DEPENDS TARGET_ARCH_LIST VARIABLE
#
create_universal_libraries_for_ios_default_frameworks() {
- local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory 1)"
+ local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/.tmp/$(get_universal_library_directory 1)"
echo -e "INFO: Building universal libraries in ${ROOT_UNIVERSAL_DIRECTORY_PATH} for default frameworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_IOS}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_IOS}"
create_ffmpeg_kit_universal_library "${ARCH_VAR_IOS}"
@@ -526,12 +536,6 @@ create_universal_libraries_for_ios_default_frameworks() {
create_ios_default_frameworks() {
echo -e "INFO: Building default frameworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_IOS}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_IOS}"
create_ffmpeg_kit_framework "${ARCH_VAR_IOS}"
@@ -542,14 +546,6 @@ create_ios_default_frameworks() {
create_universal_libraries_for_ios_xcframeworks() {
echo -e "INFO: Building universal libraries for xcframeworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_IPHONEOS}"
- create_universal_library "${library}" "${ARCH_VAR_IPHONESIMULATOR}"
- create_universal_library "${library}" "${ARCH_VAR_MAC_CATALYST}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_IPHONEOS}"
create_ffmpeg_universal_library "${ARCH_VAR_IPHONESIMULATOR}"
create_ffmpeg_universal_library "${ARCH_VAR_MAC_CATALYST}"
@@ -564,14 +560,6 @@ create_universal_libraries_for_ios_xcframeworks() {
create_frameworks_for_ios_xcframeworks() {
echo -e "INFO: Building frameworks for xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_IPHONEOS}"
- create_framework "${library}" "${ARCH_VAR_IPHONESIMULATOR}"
- create_framework "${library}" "${ARCH_VAR_MAC_CATALYST}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_IPHONEOS}"
create_ffmpeg_framework "${ARCH_VAR_IPHONESIMULATOR}"
create_ffmpeg_framework "${ARCH_VAR_MAC_CATALYST}"
@@ -587,12 +575,6 @@ create_ios_xcframeworks() {
export ARCHITECTURE_VARIANT_ARRAY=("${ARCH_VAR_IPHONEOS}" "${ARCH_VAR_IPHONESIMULATOR}" "${ARCH_VAR_MAC_CATALYST}")
echo -e "INFO: Building xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_xcframework "${library}"
- fi
- done
-
create_ffmpeg_xcframework
create_ffmpeg_kit_xcframework
diff --git a/scripts/function-macos.sh b/scripts/function-macos.sh
index 5a226f6..8683674 100755
--- a/scripts/function-macos.sh
+++ b/scripts/function-macos.sh
@@ -2,6 +2,8 @@
source "${BASEDIR}/scripts/function-apple.sh"
+prepare_inline_sed
+
enable_default_macos_architectures() {
ENABLED_ARCHITECTURES[ARCH_ARM64]=1
ENABLED_ARCHITECTURES[ARCH_X86_64]=1
@@ -17,7 +19,7 @@ When compilation ends, libraries are created under the prebuilt folder.\n"
echo -e "Usage: ./$COMMAND [OPTION]...\n"
echo -e "Specify environment variables as VARIABLE=VALUE to override default build options.\n"
- display_help_options " -x, --xcframework\t\tbuild xcframework bundles instead of framework bundles and universal libraries" " -l, --lts build lts packages to support sdk 10.11+ devices" " --target=macos sdk version\toverride minimum deployment target"
+ display_help_options " -x, --xcframework\t\tbuild xcframework bundles instead of framework bundles and universal libraries" " -l, --lts build lts packages to support sdk 10.12+ devices" " --target=macos sdk version\toverride minimum deployment target [10.15]"
display_help_licensing
echo -e "Architectures:"
@@ -39,6 +41,7 @@ When compilation ends, libraries are created under the prebuilt folder.\n"
display_help_common_libraries
display_help_gpl_libraries
+ display_help_custom_libraries
if [[ -n ${FFMPEG_KIT_XCF_BUILD} ]]; then
display_help_advanced_options " --no-framework\t\tdo not build xcframework bundles [no]"
else
@@ -47,14 +50,23 @@ When compilation ends, libraries are created under the prebuilt folder.\n"
}
enable_main_build() {
- export MACOS_MIN_VERSION=10.15
+ if [[ $(compare_versions "$DETECTED_MACOS_SDK_VERSION" "10.15") -le 0 ]]; then
+ export MACOS_MIN_VERSION=$DETECTED_MACOS_SDK_VERSION
+ else
+ export MACOS_MIN_VERSION=10.15
+ fi
}
enable_lts_build() {
export FFMPEG_KIT_LTS_BUILD="1"
- # XCODE 7.3 HAS MACOS SDK 10.11
- export MACOS_MIN_VERSION=10.11
+ if [[ $(compare_versions "$DETECTED_MACOS_SDK_VERSION" "10.12") -le 0 ]]; then
+ export MACOS_MIN_VERSION=$DETECTED_MACOS_SDK_VERSION
+ else
+
+ # XCODE 8.0 HAS MACOS SDK 10.12
+ export MACOS_MIN_VERSION=10.12
+ fi
}
get_common_includes() {
@@ -70,7 +82,7 @@ get_common_cflags() {
case ${ARCH} in
arm64)
- echo "-fstrict-aliasing -fembed-bitcode -DMACOSX ${LTS_BUILD_FLAG}${BUILD_DATE} -isysroot ${SDK_PATH}"
+ echo "-fstrict-aliasing -DMACOSX ${LTS_BUILD_FLAG}${BUILD_DATE} -isysroot ${SDK_PATH}"
;;
*)
echo "-fstrict-aliasing -DMACOSX ${LTS_BUILD_FLAG}${BUILD_DATE} -isysroot ${SDK_PATH}"
@@ -209,7 +221,7 @@ get_cxxflags() {
local OPTIMIZATION_FLAGS="${FFMPEG_KIT_DEBUG}"
fi
- local BITCODE_FLAGS="-fembed-bitcode"
+ local BITCODE_FLAGS=""
case $1 in
x265)
@@ -230,6 +242,9 @@ get_cxxflags() {
rubberband)
echo "-fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
;;
+ srt | zimg)
+ echo "-std=c++11 ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
+ ;;
*)
echo "-std=c++11 -fno-exceptions -fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
;;
@@ -241,7 +256,7 @@ get_common_linked_libraries() {
}
get_common_ldflags() {
- echo "-isysroot ${SDK_PATH}"
+ echo "-isysroot ${SDK_PATH} $(get_min_version_cflags)"
}
get_size_optimization_ldflags() {
@@ -262,7 +277,7 @@ get_size_optimization_ldflags() {
get_arch_specific_ldflags() {
case ${ARCH} in
arm64)
- echo "-arch arm64 -march=armv8-a+crc+crypto -fembed-bitcode -target $(get_target)"
+ echo "-arch arm64 -march=armv8-a+crc+crypto -target $(get_target)"
;;
x86-64)
echo "-arch x86_64 -march=x86-64 -target $(get_target)"
@@ -284,7 +299,7 @@ get_ldflags() {
ffmpeg-kit)
case ${ARCH} in
arm64)
- echo "${ARCH_FLAGS} ${LINKED_LIBRARIES} ${COMMON_FLAGS} -fembed-bitcode -Wc,-fembed-bitcode ${OPTIMIZATION_FLAGS}"
+ echo "${ARCH_FLAGS} ${LINKED_LIBRARIES} ${COMMON_FLAGS} ${OPTIMIZATION_FLAGS}"
;;
x86-64)
echo "${ARCH_FLAGS} ${LINKED_LIBRARIES} ${COMMON_FLAGS} ${OPTIMIZATION_FLAGS}"
@@ -303,7 +318,7 @@ set_toolchain_paths() {
if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
exit 1
fi
- (chmod +x "${FFMPEG_KIT_TMPDIR}"/gas-preprocessor.pl 1>>"${BASEDIR}"/build.log 2>&1) || exit 1
+ (chmod +x "${FFMPEG_KIT_TMPDIR}"/gas-preprocessor.pl 1>>"${BASEDIR}"/build.log 2>&1) || return 1
# patch gas-preprocessor.pl against the following warning
# Unescaped left brace in regex is deprecated here (and will be fatal in Perl 5.32), passed through in regex; marked by <-- HERE in m/(?:ld|st)\d\s+({ <-- HERE \s*v(\d+)\.(\d[bhsdBHSD])\s*-\s*v(\d+)\.(\d[bhsdBHSD])\s*})/ at /Users/taner/Projects/ffmpeg-kit/.tmp/gas-preprocessor.pl line 1065.
@@ -366,8 +381,6 @@ set_toolchain_paths() {
if [ ! -f "${LIB_UUID_PACKAGE_CONFIG_PATH}" ]; then
create_libuuid_system_package_config
fi
-
- prepare_inline_sed
}
initialize_prebuilt_macos_folders() {
@@ -376,7 +389,7 @@ initialize_prebuilt_macos_folders() {
echo -e "DEBUG: Initializing universal directories and frameworks for xcf builds\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_MACOS}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_MACOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_MACOS}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_MACOS}")"
fi
@@ -386,10 +399,10 @@ initialize_prebuilt_macos_folders() {
initialize_folder "${BASEDIR}/prebuilt/$(get_xcframework_directory)"
else
- echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_MACOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_MACOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
# DEFAULT BUILDS GENERATE UNIVERSAL LIBRARIES AND FRAMEWORKS
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_MACOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_MACOS}")"
echo -e "DEBUG: Initializing framework directory at ${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_MACOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -401,16 +414,10 @@ initialize_prebuilt_macos_folders() {
# DEPENDS TARGET_ARCH_LIST VARIABLE
#
create_universal_libraries_for_macos_default_frameworks() {
- local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory 1)"
+ local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/.tmp/$(get_universal_library_directory 1)"
echo -e "INFO: Building universal libraries in ${ROOT_UNIVERSAL_DIRECTORY_PATH} for default frameworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_MACOS}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_MACOS}"
create_ffmpeg_kit_universal_library "${ARCH_VAR_MACOS}"
@@ -421,12 +428,6 @@ create_universal_libraries_for_macos_default_frameworks() {
create_macos_default_frameworks() {
echo -e "INFO: Building default frameworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_MACOS}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_MACOS}"
create_ffmpeg_kit_framework "${ARCH_VAR_MACOS}"
@@ -437,12 +438,6 @@ create_macos_default_frameworks() {
create_universal_libraries_for_macos_xcframeworks() {
echo -e "INFO: Building universal libraries for xcframeworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_MACOS}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_MACOS}"
create_ffmpeg_kit_universal_library "${ARCH_VAR_MACOS}"
@@ -453,12 +448,6 @@ create_universal_libraries_for_macos_xcframeworks() {
create_frameworks_for_macos_xcframeworks() {
echo -e "INFO: Building frameworks for xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_MACOS}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_MACOS}"
create_ffmpeg_kit_framework "${ARCH_VAR_MACOS}"
@@ -470,12 +459,6 @@ create_macos_xcframeworks() {
export ARCHITECTURE_VARIANT_ARRAY=("${ARCH_VAR_MACOS}")
echo -e "INFO: Building xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_xcframework "${library}"
- fi
- done
-
create_ffmpeg_xcframework
create_ffmpeg_kit_xcframework
diff --git a/scripts/function-tvos.sh b/scripts/function-tvos.sh
index 57ea64f..6016b42 100755
--- a/scripts/function-tvos.sh
+++ b/scripts/function-tvos.sh
@@ -2,6 +2,8 @@
source "${BASEDIR}/scripts/function-apple.sh"
+prepare_inline_sed
+
enable_default_tvos_architectures() {
ENABLED_ARCHITECTURES[ARCH_ARM64]=1
ENABLED_ARCHITECTURES[ARCH_X86_64]=1
@@ -18,7 +20,7 @@ set explicitly. When compilation ends, libraries are created under the prebuilt
echo -e "Usage: ./$COMMAND [OPTION]...\n"
echo -e "Specify environment variables as VARIABLE=VALUE to override default build options.\n"
- display_help_options " -x, --xcframework\t\tbuild xcframework bundles instead of framework bundles and universal libraries" " -l, --lts build lts packages to support sdk 9.2+ devices" " --target=tvos sdk version\toverride minimum deployment target"
+ display_help_options " -x, --xcframework\t\tbuild xcframework bundles instead of framework bundles and universal libraries" " -l, --lts build lts packages to support sdk 10.0+ devices" " --target=tvos sdk version\toverride minimum deployment target [11.0]"
display_help_licensing
echo -e "Architectures:"
@@ -39,6 +41,7 @@ set explicitly. When compilation ends, libraries are created under the prebuilt
display_help_common_libraries
display_help_gpl_libraries
+ display_help_custom_libraries
if [[ -n ${FFMPEG_KIT_XCF_BUILD} ]]; then
display_help_advanced_options " --no-framework\t\tdo not build xcframework bundles [no]"
else
@@ -47,17 +50,23 @@ set explicitly. When compilation ends, libraries are created under the prebuilt
}
enable_main_build() {
- export TVOS_MIN_VERSION=11.0
+ if [[ $(compare_versions "$DETECTED_TVOS_SDK_VERSION" "11.0") -le 0 ]]; then
+ export TVOS_MIN_VERSION=$DETECTED_TVOS_SDK_VERSION
+ else
+ export TVOS_MIN_VERSION=11.0
+ fi
}
enable_lts_build() {
export FFMPEG_KIT_LTS_BUILD="1"
- # XCODE 7.3 HAS TVOS SDK 9.2
- export TVOS_MIN_VERSION=9.2
+ if [[ $(compare_versions "$DETECTED_TVOS_SDK_VERSION" "10.0") -le 0 ]]; then
+ export TVOS_MIN_VERSION=$DETECTED_TVOS_SDK_VERSION
+ else
- # TVOS SDK 9.2 DOES NOT INCLUDE VIDEOTOOLBOX
- ENABLED_LIBRARIES[LIBRARY_VIDEOTOOLBOX]=0
+ # XCODE 8.0 HAS TVOS SDK 10.0
+ export TVOS_MIN_VERSION=10.0
+ fi
}
get_common_includes() {
@@ -268,6 +277,9 @@ get_cxxflags() {
rubberband)
echo "-fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
;;
+ srt | zimg)
+ echo "-std=c++11 ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
+ ;;
*)
echo "-std=c++11 -fno-exceptions -fno-rtti ${BITCODE_FLAGS} ${COMMON_CFLAGS} ${OPTIMIZATION_FLAGS}"
;;
@@ -279,7 +291,7 @@ get_common_linked_libraries() {
}
get_common_ldflags() {
- echo "-isysroot ${SDK_PATH}"
+ echo "-isysroot ${SDK_PATH} $(get_min_version_cflags)"
}
get_size_optimization_ldflags() {
@@ -343,6 +355,7 @@ get_ldflags() {
esac
;;
*)
+ # NOTE THAT ffmpeg ALSO NEEDS BITCODE, IT IS ENABLED IN ffmpeg.sh
echo "${ARCH_FLAGS} ${LINKED_LIBRARIES} ${COMMON_FLAGS} ${OPTIMIZATION_FLAGS}"
;;
esac
@@ -354,7 +367,7 @@ set_toolchain_paths() {
if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
exit 1
fi
- (chmod +x "${FFMPEG_KIT_TMPDIR}"/gas-preprocessor.pl 1>>"${BASEDIR}"/build.log 2>&1) || exit 1
+ (chmod +x "${FFMPEG_KIT_TMPDIR}"/gas-preprocessor.pl 1>>"${BASEDIR}"/build.log 2>&1) || return 1
# patch gas-preprocessor.pl against the following warning
# Unescaped left brace in regex is deprecated here (and will be fatal in Perl 5.32), passed through in regex; marked by <-- HERE in m/(?:ld|st)\d\s+({ <-- HERE \s*v(\d+)\.(\d[bhsdBHSD])\s*-\s*v(\d+)\.(\d[bhsdBHSD])\s*})/ at /Users/taner/Projects/ffmpeg-kit/.tmp/gas-preprocessor.pl line 1065.
@@ -419,8 +432,6 @@ set_toolchain_paths() {
if [ ! -f "${LIB_UUID_PACKAGE_CONFIG_PATH}" ]; then
create_libuuid_system_package_config
fi
-
- prepare_inline_sed
}
initialize_prebuilt_tvos_folders() {
@@ -429,11 +440,11 @@ initialize_prebuilt_tvos_folders() {
echo -e "DEBUG: Initializing universal directories and frameworks for xcf builds\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_APPLETVOS}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_APPLETVOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_APPLETVOS}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_APPLETVOS}")"
fi
if [[ $(is_apple_architecture_variant_supported "${ARCH_VAR_APPLETVSIMULATOR}") -eq 1 ]]; then
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_APPLETVSIMULATOR}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_APPLETVSIMULATOR}")"
initialize_folder "${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_APPLETVSIMULATOR}")"
fi
@@ -443,10 +454,10 @@ initialize_prebuilt_tvos_folders() {
initialize_folder "${BASEDIR}/prebuilt/$(get_xcframework_directory)"
else
- echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_TVOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo -e "DEBUG: Initializing default universal directory at ${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_TVOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
# DEFAULT BUILDS GENERATE UNIVERSAL LIBRARIES AND FRAMEWORKS
- initialize_folder "${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_TVOS}")"
+ initialize_folder "${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_TVOS}")"
echo -e "DEBUG: Initializing framework directory at ${BASEDIR}/prebuilt/$(get_framework_directory "${ARCH_VAR_TVOS}")\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -458,16 +469,10 @@ initialize_prebuilt_tvos_folders() {
# DEPENDS TARGET_ARCH_LIST VARIABLE
#
create_universal_libraries_for_tvos_default_frameworks() {
- local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/prebuilt/$(get_universal_library_directory "${ARCH_VAR_TVOS}")"
+ local ROOT_UNIVERSAL_DIRECTORY_PATH="${BASEDIR}/.tmp/$(get_universal_library_directory "${ARCH_VAR_TVOS}")"
echo -e "INFO: Building universal libraries in ${ROOT_UNIVERSAL_DIRECTORY_PATH} for default frameworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_TVOS}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_TVOS}"
create_ffmpeg_kit_universal_library "${ARCH_VAR_TVOS}"
@@ -478,12 +483,6 @@ create_universal_libraries_for_tvos_default_frameworks() {
create_tvos_default_frameworks() {
echo -e "INFO: Building default frameworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_TVOS}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_TVOS}"
create_ffmpeg_kit_framework "${ARCH_VAR_TVOS}"
@@ -494,13 +493,6 @@ create_tvos_default_frameworks() {
create_universal_libraries_for_tvos_xcframeworks() {
echo -e "INFO: Building universal libraries for xcframeworks using ${TARGET_ARCH_LIST[@]}\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_universal_library "${library}" "${ARCH_VAR_APPLETVOS}"
- create_universal_library "${library}" "${ARCH_VAR_APPLETVSIMULATOR}"
- fi
- done
-
create_ffmpeg_universal_library "${ARCH_VAR_APPLETVOS}"
create_ffmpeg_universal_library "${ARCH_VAR_APPLETVSIMULATOR}"
@@ -513,13 +505,6 @@ create_universal_libraries_for_tvos_xcframeworks() {
create_frameworks_for_tvos_xcframeworks() {
echo -e "INFO: Building frameworks for xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_framework "${library}" "${ARCH_VAR_APPLETVOS}"
- create_framework "${library}" "${ARCH_VAR_APPLETVSIMULATOR}"
- fi
- done
-
create_ffmpeg_framework "${ARCH_VAR_APPLETVOS}"
create_ffmpeg_framework "${ARCH_VAR_APPLETVSIMULATOR}"
@@ -533,12 +518,6 @@ create_tvos_xcframeworks() {
export ARCHITECTURE_VARIANT_ARRAY=("${ARCH_VAR_APPLETVOS}" "${ARCH_VAR_APPLETVSIMULATOR}")
echo -e "INFO: Building xcframeworks\n" 1>>"${BASEDIR}"/build.log 2>&1
- for library in {0..46}; do
- if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
- create_xcframework "${library}"
- fi
- done
-
create_ffmpeg_xcframework
create_ffmpeg_kit_xcframework
diff --git a/scripts/function.sh b/scripts/function.sh
index 85b23c4..02f1ff3 100755
--- a/scripts/function.sh
+++ b/scripts/function.sh
@@ -82,22 +82,25 @@ get_library_name() {
31) echo "tesseract" ;;
32) echo "openh264" ;;
33) echo "vo-amrwbenc" ;;
- 34) echo "giflib" ;;
- 35) echo "jpeg" ;;
- 36) echo "libogg" ;;
- 37) echo "libpng" ;;
- 38) echo "libuuid" ;;
- 39) echo "nettle" ;;
- 40) echo "tiff" ;;
- 41) echo "expat" ;;
- 42) echo "libsndfile" ;;
- 43) echo "leptonica" ;;
- 44) echo "libsamplerate" ;;
- 45) echo "harfbuzz" ;;
- 46) echo "cpu-features" ;;
- 47) echo "android-zlib" ;;
- 48) echo "android-media-codec" ;;
- 49)
+ 34) echo "zimg" ;;
+ 35) echo "openssl" ;;
+ 36) echo "srt" ;;
+ 37) echo "giflib" ;;
+ 38) echo "jpeg" ;;
+ 39) echo "libogg" ;;
+ 40) echo "libpng" ;;
+ 41) echo "libuuid" ;;
+ 42) echo "nettle" ;;
+ 43) echo "tiff" ;;
+ 44) echo "expat" ;;
+ 45) echo "libsndfile" ;;
+ 46) echo "leptonica" ;;
+ 47) echo "libsamplerate" ;;
+ 48) echo "harfbuzz" ;;
+ 49) echo "cpu-features" ;;
+ 50) echo "android-zlib" ;;
+ 51) echo "android-media-codec" ;;
+ 52)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-zlib"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -106,7 +109,7 @@ get_library_name() {
echo "tvos-zlib"
fi
;;
- 50)
+ 53)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-audiotoolbox"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -115,7 +118,7 @@ get_library_name() {
echo "tvos-audiotoolbox"
fi
;;
- 51)
+ 54)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-bzip2"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -124,7 +127,7 @@ get_library_name() {
echo "tvos-bzip2"
fi
;;
- 52)
+ 55)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-videotoolbox"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -133,14 +136,14 @@ get_library_name() {
echo "tvos-videotoolbox"
fi
;;
- 53)
+ 56)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-avfoundation"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "macos-avfoundation"
fi
;;
- 54)
+ 57)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-libiconv"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -149,7 +152,7 @@ get_library_name() {
echo "tvos-libiconv"
fi
;;
- 55)
+ 58)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]]; then
echo "ios-libuuid"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
@@ -158,17 +161,17 @@ get_library_name() {
echo "tvos-libuuid"
fi
;;
- 56)
+ 59)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "macos-coreimage"
fi
;;
- 57)
+ 60)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "macos-opencl"
fi
;;
- 58)
+ 61)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "macos-opengl"
fi
@@ -212,31 +215,34 @@ from_library_name() {
tesseract) echo 31 ;;
openh264) echo 32 ;;
vo-amrwbenc) echo 33 ;;
- giflib) echo 34 ;;
- jpeg) echo 35 ;;
- libogg) echo 36 ;;
- libpng) echo 37 ;;
- libuuid) echo 38 ;;
- nettle) echo 39 ;;
- tiff) echo 40 ;;
- expat) echo 41 ;;
- libsndfile) echo 42 ;;
- leptonica) echo 43 ;;
- libsamplerate) echo 44 ;;
- harfbuzz) echo 45 ;;
- cpu-features) echo 46 ;;
- android-zlib) echo 47 ;;
- android-media-codec) echo 48 ;;
- ios-zlib | macos-zlib | tvos-zlib) echo 49 ;;
- ios-audiotoolbox | macos-audiotoolbox | tvos-audiotoolbox) echo 50 ;;
- ios-bzip2 | macos-bzip2 | tvos-bzip2) echo 51 ;;
- ios-videotoolbox | macos-videotoolbox | tvos-videotoolbox) echo 52 ;;
- ios-avfoundation | macos-avfoundation) echo 53 ;;
- ios-libiconv | macos-libiconv | tvos-libiconv) echo 54 ;;
- ios-libuuid | macos-libuuid | tvos-libuuid) echo 55 ;;
- macos-coreimage) echo 56 ;;
- macos-opencl) echo 57 ;;
- macos-opengl) echo 58 ;;
+ zimg) echo 34 ;;
+ openssl) echo 35 ;;
+ srt) echo 36 ;;
+ giflib) echo 37 ;;
+ jpeg) echo 38 ;;
+ libogg) echo 39 ;;
+ libpng) echo 40 ;;
+ libuuid) echo 41 ;;
+ nettle) echo 42 ;;
+ tiff) echo 43 ;;
+ expat) echo 44 ;;
+ libsndfile) echo 45 ;;
+ leptonica) echo 46 ;;
+ libsamplerate) echo 47 ;;
+ harfbuzz) echo 48 ;;
+ cpu-features) echo 49 ;;
+ android-zlib) echo 50 ;;
+ android-media-codec) echo 51 ;;
+ ios-zlib | macos-zlib | tvos-zlib) echo 52 ;;
+ ios-audiotoolbox | macos-audiotoolbox | tvos-audiotoolbox) echo 53 ;;
+ ios-bzip2 | macos-bzip2 | tvos-bzip2) echo 54 ;;
+ ios-videotoolbox | macos-videotoolbox | tvos-videotoolbox) echo 55 ;;
+ ios-avfoundation | macos-avfoundation) echo 56 ;;
+ ios-libiconv | macos-libiconv | tvos-libiconv) echo 57 ;;
+ ios-libuuid | macos-libuuid | tvos-libuuid) echo 58 ;;
+ macos-coreimage) echo 59 ;;
+ macos-opencl) echo 60 ;;
+ macos-opengl) echo 61 ;;
esac
}
@@ -249,15 +255,15 @@ is_library_supported_on_platform() {
0 | 1 | 2 | 3 | 4 | 5 | 6 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20)
echo "0"
;;
- 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 39 | 40)
+ 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40)
echo "0"
;;
- 41 | 42 | 43 | 44 | 45)
+ 42 | 43 | 44 | 45 | 46 | 47 | 48)
echo "0"
;;
# ANDROID
- 7 | 38 | 46 | 47 | 48)
+ 7 | 41 | 49 | 50 | 51)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "android" ]]; then
echo "0"
else
@@ -265,21 +271,8 @@ is_library_supported_on_platform() {
fi
;;
- # ONLY IOS, MACOS AND TVOS MAIN
- 52)
- if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]] && [[ $1 == "ios-videotoolbox" ]] && [[ -z ${FFMPEG_KIT_LTS_BUILD} ]]; then
- echo "0"
- elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]] && [[ $1 == "macos-videotoolbox" ]]; then
- echo "0"
- elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "tvos" ]] && [[ $1 == "tvos-videotoolbox" ]] && [[ -z ${FFMPEG_KIT_LTS_BUILD} ]]; then
- echo "0"
- else
- echo "1"
- fi
- ;;
-
# ONLY IOS AND MACOS
- 53)
+ 56)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]] && [[ $1 == "ios-avfoundation" ]]; then
echo "0"
elif [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]] && [[ $1 == "macos-avfoundation" ]]; then
@@ -290,7 +283,7 @@ is_library_supported_on_platform() {
;;
# IOS, MACOS AND TVOS
- 49 | 50 | 51 | 54 | 55)
+ 52 | 53 | 54 | 55 | 57 | 58)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "ios" ]] || [[ ${FFMPEG_KIT_BUILD_TYPE} == "tvos" ]] || [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "0"
else
@@ -299,7 +292,7 @@ is_library_supported_on_platform() {
;;
# ONLY MACOS
- 56 | 57 | 58)
+ 59 | 60 | 61)
if [[ ${FFMPEG_KIT_BUILD_TYPE} == "macos" ]]; then
echo "0"
else
@@ -376,13 +369,13 @@ get_package_config_file_name() {
27) echo "aom" ;;
28) echo "libchromaprint" ;;
30) echo "sdl2" ;;
- 35) echo "libjpeg" ;;
- 36) echo "ogg" ;;
- 40) echo "libtiff-4" ;;
- 42) echo "sndfile" ;;
- 43) echo "lept" ;;
- 44) echo "samplerate" ;;
- 55) echo "uuid" ;;
+ 38) echo "libjpeg" ;;
+ 39) echo "ogg" ;;
+ 43) echo "libtiff-4" ;;
+ 45) echo "sndfile" ;;
+ 46) echo "lept" ;;
+ 47) echo "samplerate" ;;
+ 58) echo "uuid" ;;
*) echo "$(get_library_name "$1")" ;;
esac
}
@@ -503,6 +496,19 @@ get_host() {
esac
}
+#
+# 1. key
+# 2. value
+#
+generate_custom_library_environment_variables() {
+ CUSTOM_KEY=$(echo "CUSTOM_$1" | sed "s/\-/\_/g" | tr '[a-z]' '[A-Z]')
+ CUSTOM_VALUE="$2"
+
+ export "${CUSTOM_KEY}"="${CUSTOM_VALUE}"
+
+ echo -e "INFO: Custom library env variable generated: ${CUSTOM_KEY}=${CUSTOM_VALUE}\n" 1>>"${BASEDIR}"/build.log 2>&1
+}
+
skip_library() {
SKIP_VARIABLE=$(echo "SKIP_$1" | sed "s/\-/\_/g")
@@ -571,6 +577,162 @@ GNU Lesser General Public License as published by the Free Software Foundation,
either version 3 of the License, or (at your option) any later version."
}
+get_ffmpeg_libavcodec_version() {
+ local MAJOR=$(grep -Eo ' LIBAVCODEC_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavcodec/version.h | sed -e 's|LIBAVCODEC_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBAVCODEC_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libavcodec/version.h | sed -e 's|LIBAVCODEC_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBAVCODEC_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libavcodec/version.h | sed -e 's|LIBAVCODEC_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libavcodec_major_version() {
+ local MAJOR=$(grep -Eo ' LIBAVCODEC_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavcodec/version.h | sed -e 's|LIBAVCODEC_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libavdevice_version() {
+ local MAJOR=$(grep -Eo ' LIBAVDEVICE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavdevice/version.h | sed -e 's|LIBAVDEVICE_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBAVDEVICE_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libavdevice/version.h | sed -e 's|LIBAVDEVICE_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBAVDEVICE_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libavdevice/version.h | sed -e 's|LIBAVDEVICE_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libavdevice_major_version() {
+ local MAJOR=$(grep -Eo ' LIBAVDEVICE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavdevice/version.h | sed -e 's|LIBAVDEVICE_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libavfilter_version() {
+ local MAJOR=$(grep -Eo ' LIBAVFILTER_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavfilter/version.h | sed -e 's|LIBAVFILTER_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBAVFILTER_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libavfilter/version.h | sed -e 's|LIBAVFILTER_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBAVFILTER_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libavfilter/version.h | sed -e 's|LIBAVFILTER_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libavfilter_major_version() {
+ local MAJOR=$(grep -Eo ' LIBAVFILTER_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavfilter/version.h | sed -e 's|LIBAVFILTER_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libavformat_version() {
+ local MAJOR=$(grep -Eo ' LIBAVFORMAT_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavformat/version.h | sed -e 's|LIBAVFORMAT_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBAVFORMAT_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libavformat/version.h | sed -e 's|LIBAVFORMAT_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBAVFORMAT_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libavformat/version.h | sed -e 's|LIBAVFORMAT_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libavformat_major_version() {
+ local MAJOR=$(grep -Eo ' LIBAVFORMAT_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavformat/version.h | sed -e 's|LIBAVFORMAT_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libavutil_version() {
+ local MAJOR=$(grep -Eo ' LIBAVUTIL_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavutil/version.h | sed -e 's|LIBAVUTIL_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBAVUTIL_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libavutil/version.h | sed -e 's|LIBAVUTIL_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBAVUTIL_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libavutil/version.h | sed -e 's|LIBAVUTIL_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libavutil_major_version() {
+ local MAJOR=$(grep -Eo ' LIBAVUTIL_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libavutil/version.h | sed -e 's|LIBAVUTIL_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libswresample_version() {
+ local MAJOR=$(grep -Eo ' LIBSWRESAMPLE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libswresample/version.h | sed -e 's|LIBSWRESAMPLE_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBSWRESAMPLE_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libswresample/version.h | sed -e 's|LIBSWRESAMPLE_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBSWRESAMPLE_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libswresample/version.h | sed -e 's|LIBSWRESAMPLE_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libswresample_major_version() {
+ local MAJOR=$(grep -Eo ' LIBSWRESAMPLE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libswresample/version.h | sed -e 's|LIBSWRESAMPLE_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+get_ffmpeg_libswscale_version() {
+ local MAJOR=$(grep -Eo ' LIBSWSCALE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libswscale/version.h | sed -e 's|LIBSWSCALE_VERSION_MAJOR||g;s| ||g')
+ local MINOR=$(grep -Eo ' LIBSWSCALE_VERSION_MINOR .*' "${BASEDIR}"/src/ffmpeg/libswscale/version.h | sed -e 's|LIBSWSCALE_VERSION_MINOR||g;s| ||g')
+ local MICRO=$(grep -Eo ' LIBSWSCALE_VERSION_MICRO .*' "${BASEDIR}"/src/ffmpeg/libswscale/version.h | sed -e 's|LIBSWSCALE_VERSION_MICRO||g;s| ||g')
+
+ echo "${MAJOR}.${MINOR}.${MICRO}"
+}
+
+get_ffmpeg_libswscale_major_version() {
+ local MAJOR=$(grep -Eo ' LIBSWSCALE_VERSION_MAJOR .*' "${BASEDIR}"/src/ffmpeg/libswscale/version.h | sed -e 's|LIBSWSCALE_VERSION_MAJOR||g;s| ||g')
+
+ echo "${MAJOR}"
+}
+
+#
+# 1. LIBRARY NAME
+#
+get_ffmpeg_library_version() {
+ case $1 in
+ libavcodec)
+ echo "$(get_ffmpeg_libavcodec_version)"
+ ;;
+ libavdevice)
+ echo "$(get_ffmpeg_libavdevice_version)"
+ ;;
+ libavfilter)
+ echo "$(get_ffmpeg_libavfilter_version)"
+ ;;
+ libavformat)
+ echo "$(get_ffmpeg_libavformat_version)"
+ ;;
+ libavutil)
+ echo "$(get_ffmpeg_libavutil_version)"
+ ;;
+ libswresample)
+ echo "$(get_ffmpeg_libswresample_version)"
+ ;;
+ libswscale)
+ echo "$(get_ffmpeg_libswscale_version)"
+ ;;
+ esac
+}
+
+#
+# 1. LIBRARY NAME
+#
+get_ffmpeg_library_major_version() {
+ case $1 in
+ libavcodec)
+ echo "$(get_ffmpeg_libavcodec_major_version)"
+ ;;
+ libavdevice)
+ echo "$(get_ffmpeg_libavdevice_major_version)"
+ ;;
+ libavfilter)
+ echo "$(get_ffmpeg_libavfilter_major_version)"
+ ;;
+ libavformat)
+ echo "$(get_ffmpeg_libavformat_major_version)"
+ ;;
+ libavutil)
+ echo "$(get_ffmpeg_libavutil_major_version)"
+ ;;
+ libswresample)
+ echo "$(get_ffmpeg_libswresample_major_version)"
+ ;;
+ libswscale)
+ echo "$(get_ffmpeg_libswscale_major_version)"
+ ;;
+ esac
+}
+
display_help_options() {
echo -e "Options:"
echo -e " -h, --help\t\t\tdisplay this help and exit"
@@ -625,15 +787,18 @@ display_help_common_libraries() {
echo -e " --enable-libxml2\t\tbuild with libxml2 [no]"
echo -e " --enable-opencore-amr\t\tbuild with opencore-amr [no]"
echo -e " --enable-openh264\t\tbuild with openh264 [no]"
+ echo -e " --enable-openssl\t\tbuild with openssl [no]"
echo -e " --enable-opus\t\t\tbuild with opus [no]"
echo -e " --enable-sdl\t\t\tbuild with sdl [no]"
echo -e " --enable-shine\t\tbuild with shine [no]"
echo -e " --enable-snappy\t\tbuild with snappy [no]"
echo -e " --enable-soxr\t\t\tbuild with soxr [no]"
echo -e " --enable-speex\t\tbuild with speex [no]"
+ echo -e " --enable-srt\t\t\tbuild with srt [no]"
echo -e " --enable-tesseract\t\tbuild with tesseract [no]"
echo -e " --enable-twolame\t\tbuild with twolame [no]"
- echo -e " --enable-vo-amrwbenc\t\tbuild with vo-amrwbenc [no]\n"
+ echo -e " --enable-vo-amrwbenc\t\tbuild with vo-amrwbenc [no]"
+ echo -e " --enable-zimg\t\t\tbuild with zimg [no]\n"
}
display_help_gpl_libraries() {
@@ -645,6 +810,22 @@ display_help_gpl_libraries() {
echo -e " --enable-xvidcore\t\tbuild with xvidcore [no]\n"
}
+display_help_custom_libraries() {
+ echo -e "Custom libraries:"
+ echo -e " --enable-custom-library-[n]-name=value\t\t\tname of the custom library []"
+ echo -e " --enable-custom-library-[n]-repo=value\t\t\tgit repository of the source code []"
+ echo -e " --enable-custom-library-[n]-repo-commit=value\t\t\tgit commit to download the source code from []"
+ echo -e " --enable-custom-library-[n]-repo-tag=value\t\t\tgit tag to download the source code from []"
+ echo -e " --enable-custom-library-[n]-package-config-file-name=value\tpackage config file installed by the build script []"
+ echo -e " --enable-custom-library-[n]-ffmpeg-enable-flag=value\tlibrary name used in ffmpeg configure script to enable the library []"
+ echo -e " --enable-custom-library-[n]-license-file=value\t\tlicence file path relative to the library source folder []"
+ if [ ${FFMPEG_KIT_BUILD_TYPE} == "android" ]; then
+ echo -e " --enable-custom-library-[n]-uses-cpp\t\t\t\tflag to specify that the library uses libc++ []\n"
+ else
+ echo ""
+ fi
+}
+
display_help_advanced_options() {
echo -e "Advanced options:"
echo -e " --reconf-LIBRARY\t\trun autoreconf before building LIBRARY [no]"
@@ -663,7 +844,7 @@ reconf_library() {
local RECONF_VARIABLE=$(echo "RECONF_$1" | sed "s/\-/\_/g")
local library_supported=0
- for library in {0..46}; do
+ for library in {0..49}; do
library_name=$(get_library_name ${library})
local library_supported_on_platform=$(is_library_supported_on_platform "${library_name}")
@@ -675,7 +856,11 @@ reconf_library() {
done
if [[ ${library_supported} -ne 1 ]]; then
- echo -e "INFO: --reconf flag detected for library $1 is not supported.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ export ${RECONF_VARIABLE}=1
+ RECONF_LIBRARIES+=($1)
+ echo -e "INFO: --reconf flag detected for custom library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ else
+ echo -e "INFO: --reconf flag detected for library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
fi
}
@@ -686,7 +871,7 @@ rebuild_library() {
local REBUILD_VARIABLE=$(echo "REBUILD_$1" | sed "s/\-/\_/g")
local library_supported=0
- for library in {0..46}; do
+ for library in {0..49}; do
library_name=$(get_library_name ${library})
local library_supported_on_platform=$(is_library_supported_on_platform "${library_name}")
@@ -698,7 +883,11 @@ rebuild_library() {
done
if [[ ${library_supported} -ne 1 ]]; then
- echo -e "INFO: --rebuild flag detected for library $1 is not supported.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ export ${REBUILD_VARIABLE}=1
+ REBUILD_LIBRARIES+=($1)
+ echo -e "INFO: --rebuild flag detected for custom library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ else
+ echo -e "INFO: --rebuild flag detected for library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
fi
}
@@ -709,7 +898,7 @@ redownload_library() {
local REDOWNLOAD_VARIABLE=$(echo "REDOWNLOAD_$1" | sed "s/\-/\_/g")
local library_supported=0
- for library in {0..46}; do
+ for library in {0..49}; do
library_name=$(get_library_name ${library})
local library_supported_on_platform=$(is_library_supported_on_platform "${library_name}")
@@ -727,7 +916,11 @@ redownload_library() {
fi
if [[ ${library_supported} -ne 1 ]]; then
- echo -e "INFO: --redownload flag detected for library $1 is not supported.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ export ${REDOWNLOAD_VARIABLE}=1
+ REDOWNLOAD_LIBRARIES+=($1)
+ echo -e "INFO: --redownload flag detected for custom library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
+ else
+ echo -e "INFO: --redownload flag detected for library $1.\n" 1>>"${BASEDIR}"/build.log 2>&1
fi
}
@@ -736,11 +929,13 @@ redownload_library() {
# 2. ignore unknown libraries
#
enable_library() {
- local library_supported_on_platform=$(is_library_supported_on_platform "$1")
- if [[ $library_supported_on_platform == 0 ]]; then
- set_library "$1" 1
- elif [[ $2 -ne 1 ]]; then
- print_unknown_library "$1"
+ if [ -n "$1" ]; then
+ local library_supported_on_platform=$(is_library_supported_on_platform "$1")
+ if [[ $library_supported_on_platform == 0 ]]; then
+ set_library "$1" 1
+ elif [[ $2 -ne 1 ]]; then
+ print_unknown_library "$1"
+ fi
fi
}
@@ -895,6 +1090,9 @@ set_library() {
openh264)
ENABLED_LIBRARIES[LIBRARY_OPENH264]=$2
;;
+ openssl)
+ ENABLED_LIBRARIES[LIBRARY_OPENSSL]=$2
+ ;;
opus)
ENABLED_LIBRARIES[LIBRARY_OPUS]=$2
;;
@@ -919,6 +1117,10 @@ set_library() {
speex)
ENABLED_LIBRARIES[LIBRARY_SPEEX]=$2
;;
+ srt)
+ ENABLED_LIBRARIES[LIBRARY_SRT]=$2
+ set_library "openssl" $2
+ ;;
tesseract)
ENABLED_LIBRARIES[LIBRARY_TESSERACT]=$2
ENABLED_LIBRARIES[LIBRARY_LEPTONICA]=$2
@@ -945,6 +1147,9 @@ set_library() {
xvidcore)
ENABLED_LIBRARIES[LIBRARY_XVIDCORE]=$2
;;
+ zimg)
+ ENABLED_LIBRARIES[LIBRARY_ZIMG]=$2
+ ;;
expat | giflib | jpeg | leptonica | libogg | libsamplerate | libsndfile)
# THESE LIBRARIES ARE NOT ENABLED DIRECTLY
;;
@@ -1134,6 +1339,9 @@ check_if_dependency_rebuilt() {
nettle)
set_dependency_rebuilt_flag "gnutls"
;;
+ openssl)
+ set_dependency_rebuilt_flag "srt"
+ ;;
tiff)
set_dependency_rebuilt_flag "libwebp"
set_dependency_rebuilt_flag "leptonica"
@@ -1195,7 +1403,7 @@ print_enabled_libraries() {
let enabled=0
# SUPPLEMENTARY LIBRARIES NOT PRINTED
- for library in {47..54} {56..58} {0..33}; do
+ for library in {50..57} {59..61} {0..36}; do
if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
if [[ ${enabled} -ge 1 ]]; then
echo -n ", "
@@ -1218,7 +1426,7 @@ print_enabled_xcframeworks() {
let enabled=0
# SUPPLEMENTARY LIBRARIES NOT PRINTED
- for library in {0..46}; do
+ for library in {0..49}; do
if [[ ${ENABLED_LIBRARIES[$library]} -eq 1 ]]; then
if [[ ${enabled} -ge 1 ]]; then
echo -n ", "
@@ -1299,29 +1507,99 @@ print_redownload_requested_libraries() {
fi
}
+print_custom_libraries() {
+ local counter=0
+
+ for index in {1..20}; do
+ LIBRARY_NAME="CUSTOM_LIBRARY_${index}_NAME"
+ LIBRARY_REPO="CUSTOM_LIBRARY_${index}_REPO"
+ LIBRARY_REPO_COMMIT="CUSTOM_LIBRARY_${index}_REPO_COMMIT"
+ LIBRARY_REPO_TAG="CUSTOM_LIBRARY_${index}_REPO_TAG"
+ LIBRARY_PACKAGE_CONFIG_FILE_NAME="CUSTOM_LIBRARY_${index}_PACKAGE_CONFIG_FILE_NAME"
+ LIBRARY_FFMPEG_ENABLE_FLAG="CUSTOM_LIBRARY_${index}_FFMPEG_ENABLE_FLAG"
+ LIBRARY_LICENSE_FILE="CUSTOM_LIBRARY_${index}_LICENSE_FILE"
+ LIBRARY_USES_CPP="CUSTOM_LIBRARY_${index}_USES_CPP"
+
+ if [[ -z "${!LIBRARY_NAME}" ]]; then
+ echo -e "INFO: Custom library ${index} not detected\n" 1>>"${BASEDIR}"/build.log 2>&1
+ break
+ fi
+
+ if [[ -z "${!LIBRARY_REPO}" ]]; then
+ echo -e "INFO: Custom library ${index} repo not set\n" 1>>"${BASEDIR}"/build.log 2>&1
+ continue
+ fi
+
+ if [[ -z "${!LIBRARY_REPO_COMMIT}" ]] && [[ -z "${!LIBRARY_REPO_TAG}" ]]; then
+ echo -e "INFO: Custom library ${index} repo source not set. Both commit id and tag are empty\n" 1>>"${BASEDIR}"/build.log 2>&1
+ continue
+ fi
+
+ if [[ -z "${!LIBRARY_PACKAGE_CONFIG_FILE_NAME}" ]]; then
+ echo -e "INFO: Custom library ${index} package config file not set\n" 1>>"${BASEDIR}"/build.log 2>&1
+ continue
+ fi
+
+ if [[ -z "${!LIBRARY_FFMPEG_ENABLE_FLAG}" ]]; then
+ echo -e "INFO: Custom library ${index} ffmpeg enable flag not set\n" 1>>"${BASEDIR}"/build.log 2>&1
+ continue
+ fi
+
+ if [[ -z "${!LIBRARY_LICENSE_FILE}" ]]; then
+ echo -e "INFO: Custom library ${index} license file not set\n" 1>>"${BASEDIR}"/build.log 2>&1
+ continue
+ fi
+
+ if [[ -n "${!LIBRARY_USES_CPP}" ]] && [[ ${FFMPEG_KIT_BUILD_TYPE} == "android" ]]; then
+ echo -e "INFO: Custom library ${index} is marked as uses libc++ \n" 1>>"${BASEDIR}"/build.log 2>&1
+ export CUSTOM_LIBRARY_USES_CPP=1
+ fi
+
+ CUSTOM_LIBRARIES+=("${index}")
+
+ if [[ ${counter} -eq 0 ]]; then
+ echo -n "Custom libraries: "
+ else
+ echo -n ", "
+ fi
+
+ echo -n "${!LIBRARY_NAME}"
+
+ echo -e "INFO: Custom library options found for ${!LIBRARY_NAME}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ counter=$((${counter} + 1))
+ done
+
+ if [[ ${counter} -gt 0 ]]; then
+ echo -e "INFO: ${counter} valid custom library definitions found\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo ""
+ fi
+}
+
# 1 - library index
get_external_library_license_path() {
case $1 in
1) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE.TXT" ;;
- 3 | 39) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYING.LESSERv3" ;;
- 5 | 41) echo "${BASEDIR}/src/$(get_library_name "$1")/$(get_library_name "$1")/COPYING" ;;
+ 35) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE.txt" ;;
+ 3 | 42) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYING.LESSERv3" ;;
+ 5 | 44) echo "${BASEDIR}/src/$(get_library_name "$1")/$(get_library_name "$1")/COPYING" ;;
19) echo "${BASEDIR}/src/$(get_library_name "$1")/$(get_library_name "$1")/LICENSE" ;;
26) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYING.LGPL" ;;
- 28 | 35) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE.md " ;;
+ 28 | 38) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE.md " ;;
30) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYING.txt" ;;
- 40) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYRIGHT" ;;
- 43) echo "${BASEDIR}/src/$(get_library_name "$1")/leptonica-license.txt" ;;
- 4 | 10 | 13 | 21 | 27 | 31 | 32 | 37 | 46) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE" ;;
+ 43) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYRIGHT" ;;
+ 46) echo "${BASEDIR}/src/$(get_library_name "$1")/leptonica-license.txt" ;;
+ 4 | 10 | 13 | 17 | 21 | 27 | 31 | 32 | 36 | 40 | 49) echo "${BASEDIR}/src/$(get_library_name "$1")/LICENSE" ;;
*) echo "${BASEDIR}/src/$(get_library_name "$1")/COPYING" ;;
esac
}
# 1 - library index
-# 2 - output directory
+# 2 - license path
copy_external_library_license() {
- output_path_array=("$2")
- for output_path in "${output_path_array[@]}"; do
- RESULT=$(copy_external_library_license_file "$1" "${output_path}/LICENSE")
+ license_path_array=("$2")
+ for license_path in "${license_path_array[@]}"; do
+ RESULT=$(copy_external_library_license_file "$1" "${license_path}")
if [[ ${RESULT} -ne 0 ]]; then
echo 1
return
@@ -1554,7 +1832,7 @@ is_gpl_licensed() {
echo 1
}
-downloaded_enabled_library_sources() {
+downloaded_library_sources() {
# DOWNLOAD FFMPEG SOURCE CODE FIRST
DOWNLOAD_RESULT=$(download_library_source "ffmpeg")
@@ -1563,7 +1841,7 @@ downloaded_enabled_library_sources() {
exit 1
fi
- for library in {1..47}; do
+ for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
library_name=$(get_library_name $((library - 1)))
@@ -1577,6 +1855,18 @@ downloaded_enabled_library_sources() {
fi
done
+ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+
+ echo -e "\nDEBUG: Downloading custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ DOWNLOAD_RESULT=$(download_custom_library_source "${custom_library_index}")
+ if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
+ echo -e "failed\n"
+ exit 1
+ fi
+ done
+
echo -e "ok"
}
@@ -1653,6 +1943,57 @@ download_library_source() {
fi
}
+#
+# 1. custom library index
+#
+download_custom_library_source() {
+ local LIBRARY_NAME="CUSTOM_LIBRARY_$1_NAME"
+ local LIBRARY_REPO="CUSTOM_LIBRARY_$1_REPO"
+ local LIBRARY_REPO_COMMIT="CUSTOM_LIBRARY_$1_REPO_COMMIT"
+ local LIBRARY_REPO_TAG="CUSTOM_LIBRARY_$1_REPO_TAG"
+
+ local SOURCE_REPO_URL=""
+ local LIB_NAME="${!LIBRARY_NAME}"
+ local LIB_LOCAL_PATH=${BASEDIR}/src/${LIB_NAME}
+ local SOURCE_ID=""
+ local LIBRARY_RC=""
+ local DOWNLOAD_RC=""
+ local SOURCE_TYPE=""
+
+ echo -e "DEBUG: Downloading custom library source: ${LIB_NAME}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ SOURCE_REPO_URL=${!LIBRARY_REPO}
+ if [ -n "${!LIBRARY_REPO_TAG}" ]; then
+ SOURCE_ID=${!LIBRARY_REPO_TAG}
+ SOURCE_TYPE="TAG"
+ else
+ SOURCE_ID=${!LIBRARY_REPO_COMMIT}
+ SOURCE_TYPE="COMMIT"
+ fi
+
+ LIBRARY_RC=$(library_is_downloaded "${LIB_NAME}")
+
+ if [ ${LIBRARY_RC} -eq 0 ]; then
+ echo -e "INFO: ${LIB_NAME} already downloaded. Source folder found at ${LIB_LOCAL_PATH}" 1>>"${BASEDIR}"/build.log 2>&1
+ echo 0
+ return
+ fi
+
+ if [ "${SOURCE_TYPE}" == "TAG" ]; then
+ DOWNLOAD_RC=$(clone_git_repository_with_tag "${SOURCE_REPO_URL}" "${SOURCE_ID}" "${LIB_LOCAL_PATH}")
+ else
+ DOWNLOAD_RC=$(clone_git_repository_with_commit_id "${SOURCE_REPO_URL}" "${LIB_LOCAL_PATH}" "${SOURCE_ID}")
+ fi
+
+ if [ ${DOWNLOAD_RC} -ne 0 ]; then
+ echo -e "INFO: Downloading custom library ${LIB_NAME} failed. Can not get library from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
+ echo ${DOWNLOAD_RC}
+ else
+ echo -e "\nINFO: ${LIB_NAME} custom library downloaded" 1>>"${BASEDIR}"/build.log 2>&1
+ echo 0
+ fi
+}
+
download_gnu_config() {
local SOURCE_REPO_URL=""
local LIB_NAME="config"
@@ -1825,23 +2166,26 @@ compare_versions() {
for((i=0;(i<${#VERSION_PARTS_1[@]})&&(i<${#VERSION_PARTS_2[@]});i++))
do
- if [[ ${VERSION_PARTS_1[$i]} -gt ${VERSION_PARTS_2[$i]} ]]; then
+ local CURRENT_PART_1=${VERSION_PARTS_1[$i]}
+ local CURRENT_PART_2=${VERSION_PARTS_2[$i]}
+
+ if [[ -z ${CURRENT_PART_1} ]]; then
+ CURRENT_PART_1=0
+ fi
+
+ if [[ -z ${CURRENT_PART_2} ]]; then
+ CURRENT_PART_2=0
+ fi
+
+ if [[ CURRENT_PART_1 -gt CURRENT_PART_2 ]]; then
echo "1"
return;
- elif [[ ${VERSION_PARTS_1[$i]} -lt ${VERSION_PARTS_2[$i]} ]]; then
+ elif [[ CURRENT_PART_1 -lt CURRENT_PART_2 ]]; then
echo "-1"
return;
fi
done
- if [[ ${#VERSION_PARTS_1[@]} -gt ${#VERSION_PARTS_2[@]} ]]; then
- echo "1"
- return;
- elif [[ ${#VERSION_PARTS_1[@]} -lt ${#VERSION_PARTS_2[@]} ]]; then
- echo "-1"
- return;
- else
- echo "0"
- return;
- fi
+ echo "0"
+ return;
}
diff --git a/scripts/main-android.sh b/scripts/main-android.sh
index 180a187..7266dbd 100755
--- a/scripts/main-android.sh
+++ b/scripts/main-android.sh
@@ -25,9 +25,6 @@ if [[ -z ${TOOLCHAIN_ARCH} ]]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
echo -e "\nBuilding ${ARCH} platform on API level ${API}\n"
echo -e "\nINFO: Starting new build for ${ARCH} on API level ${API} at $(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -37,13 +34,13 @@ export LIB_INSTALL_BASE="${BASEDIR}/prebuilt/$(get_build_directory)"
# CREATE PACKAGE CONFIG DIRECTORY FOR THIS ARCHITECTURE
PKG_CONFIG_DIRECTORY="${LIB_INSTALL_BASE}/pkgconfig"
if [ ! -d "${PKG_CONFIG_DIRECTORY}" ]; then
- mkdir -p "${PKG_CONFIG_DIRECTORY}" || exit 1
+ mkdir -p "${PKG_CONFIG_DIRECTORY}" || return 1
fi
# FILTER WHICH EXTERNAL LIBRARIES WILL BE BUILT
# NOTE THAT BUILT-IN LIBRARIES ARE FORWARDED TO FFMPEG SCRIPT WITHOUT ANY PROCESSING
enabled_library_list=()
-for library in {1..47}; do
+for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
ENABLED_LIBRARY=$(get_library_name $((library - 1)))
enabled_library_list+=(${ENABLED_LIBRARY})
@@ -138,6 +135,11 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
run=1
fi
;;
+ srt)
+ if [[ $OK_openssl -eq 1 ]]; then
+ run=1
+ fi
+ ;;
tesseract)
if [[ $OK_leptonica -eq 1 ]]; then
run=1
@@ -175,12 +177,17 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
"${BASEDIR}"/scripts/run-android.sh "${library}" 1>>"${BASEDIR}"/build.log 2>&1
+ RC=$?
+
# SET SOME FLAGS AFTER THE BUILD
- if [ $? -eq 0 ]; then
+ if [ $RC -eq 0 ]; then
((completed += 1))
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
@@ -196,11 +203,46 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
done
done
+# BUILD CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+
+ echo -e "\nDEBUG: Custom library ${!library_name} will be built\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DEFINE SOME FLAGS TO REBUILD OPTIONS
+ REBUILD_FLAG=$(echo "REBUILD_${!library_name}" | sed "s/\-/\_/g")
+ LIBRARY_IS_INSTALLED=$(library_is_installed "${LIB_INSTALL_BASE}" "${!library_name}")
+
+ echo -e "INFO: Flags detected for custom library ${!library_name}: already installed=${LIBRARY_IS_INSTALLED}, rebuild requested by user=${!REBUILD_FLAG}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ if [[ ${LIBRARY_IS_INSTALLED} -ne 1 ]] || [[ ${!REBUILD_FLAG} -eq 1 ]]; then
+
+ echo -n "${!library_name}: "
+
+ "${BASEDIR}"/scripts/run-android.sh "${!library_name}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ # SET SOME FLAGS AFTER THE BUILD
+ if [ $RC -eq 0 ]; then
+ echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
+ else
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+ else
+ echo "${!library_name}: already built"
+ fi
+done
+
# SKIP TO SPEED UP THE BUILD
if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
# BUILD FFMPEG
- "${BASEDIR}"/scripts/android/ffmpeg.sh "$@"
+ source "${BASEDIR}"/scripts/android/ffmpeg.sh
if [[ $? -ne 0 ]]; then
exit 1
diff --git a/scripts/main-ios.sh b/scripts/main-ios.sh
index 1eb1ca6..1a4f693 100755
--- a/scripts/main-ios.sh
+++ b/scripts/main-ios.sh
@@ -20,9 +20,6 @@ if [[ -z ${SDK_PATH} ]]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
echo -e "\nBuilding ${ARCH} platform targeting iOS SDK ${IOS_MIN_VERSION} and Mac Catalyst ${MAC_CATALYST_MIN_VERSION}\n"
echo -e "\nINFO: Starting new build for ${ARCH} targeting iOS SDK ${IOS_MIN_VERSION} and Mac Catalyst ${MAC_CATALYST_MIN_VERSION} at $(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -32,13 +29,13 @@ export LIB_INSTALL_BASE="${BASEDIR}/prebuilt/$(get_build_directory)"
# CREATE PACKAGE CONFIG DIRECTORY FOR THIS ARCHITECTURE
PKG_CONFIG_DIRECTORY="${LIB_INSTALL_BASE}/pkgconfig"
if [ ! -d "${PKG_CONFIG_DIRECTORY}" ]; then
- mkdir -p "${PKG_CONFIG_DIRECTORY}" || exit 1
+ mkdir -p "${PKG_CONFIG_DIRECTORY}" || return 1
fi
# FILTER WHICH EXTERNAL LIBRARIES WILL BE BUILT
# NOTE THAT BUILT-IN LIBRARIES ARE FORWARDED TO FFMPEG SCRIPT WITHOUT ANY PROCESSING
enabled_library_list=()
-for library in {1..47}; do
+for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
ENABLED_LIBRARY=$(get_library_name $((library - 1)))
enabled_library_list+=(${ENABLED_LIBRARY})
@@ -108,6 +105,11 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
run=1
fi
;;
+ srt)
+ if [[ $OK_openssl -eq 1 ]]; then
+ run=1
+ fi
+ ;;
tesseract)
if [[ $OK_leptonica -eq 1 ]]; then
run=1
@@ -145,12 +147,17 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
"${BASEDIR}"/scripts/run-apple.sh "${library}" 1>>"${BASEDIR}"/build.log 2>&1
+ RC=$?
+
# SET SOME FLAGS AFTER THE BUILD
- if [ $? -eq 0 ]; then
+ if [ $RC -eq 0 ]; then
((completed += 1))
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
@@ -166,6 +173,41 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
done
done
+# BUILD CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+
+ echo -e "\nDEBUG: Custom library ${!library_name} will be built\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DEFINE SOME FLAGS TO REBUILD OPTIONS
+ REBUILD_FLAG=$(echo "REBUILD_${!library_name}" | sed "s/\-/\_/g")
+ LIBRARY_IS_INSTALLED=$(library_is_installed "${LIB_INSTALL_BASE}" "${!library_name}")
+
+ echo -e "INFO: Flags detected for custom library ${!library_name}: already installed=${LIBRARY_IS_INSTALLED}, rebuild requested by user=${!REBUILD_FLAG}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ if [[ ${LIBRARY_IS_INSTALLED} -ne 1 ]] || [[ ${!REBUILD_FLAG} -eq 1 ]]; then
+
+ echo -n "${!library_name}: "
+
+ "${BASEDIR}"/scripts/run-apple.sh "${!library_name}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ # SET SOME FLAGS AFTER THE BUILD
+ if [ $RC -eq 0 ]; then
+ echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
+ else
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+ else
+ echo "${!library_name}: already built"
+ fi
+done
+
# SKIP TO SPEED UP THE BUILD
if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
@@ -180,12 +222,12 @@ if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
export LDFLAGS=$(get_ldflags "${LIB_NAME}")
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
- cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
- LIB_INSTALL_PREFIX="${LIB_INSTALL_BASE}"/"${LIB_NAME}"
+ LIB_INSTALL_PREFIX="${LIB_INSTALL_BASE}/${LIB_NAME}"
# BUILD FFMPEG
- source "${BASEDIR}"/scripts/apple/ffmpeg.sh "$@"
+ source "${BASEDIR}"/scripts/apple/ffmpeg.sh
if [[ $? -ne 0 ]]; then
exit 1
@@ -198,7 +240,7 @@ fi
if [[ ${SKIP_ffmpeg_kit} -ne 1 ]]; then
# BUILD FFMPEG KIT
- . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || exit 1
+ . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || return 1
else
echo -e "\nffmpeg-kit: skipped"
fi
diff --git a/scripts/main-macos.sh b/scripts/main-macos.sh
index ac25bb7..96481ab 100755
--- a/scripts/main-macos.sh
+++ b/scripts/main-macos.sh
@@ -20,9 +20,6 @@ if [[ -z ${SDK_PATH} ]]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
echo -e "\nBuilding ${ARCH} platform targeting macOS SDK ${MACOS_MIN_VERSION}\n"
echo -e "\nINFO: Starting new build for ${ARCH} targeting macOS SDK ${MACOS_MIN_VERSION} at $(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -32,13 +29,13 @@ export LIB_INSTALL_BASE="${BASEDIR}/prebuilt/$(get_build_directory)"
# CREATE PACKAGE CONFIG DIRECTORY FOR THIS ARCHITECTURE
PKG_CONFIG_DIRECTORY="${LIB_INSTALL_BASE}/pkgconfig"
if [ ! -d "${PKG_CONFIG_DIRECTORY}" ]; then
- mkdir -p "${PKG_CONFIG_DIRECTORY}" || exit 1
+ mkdir -p "${PKG_CONFIG_DIRECTORY}" || return 1
fi
# FILTER WHICH EXTERNAL LIBRARIES WILL BE BUILT
# NOTE THAT BUILT-IN LIBRARIES ARE FORWARDED TO FFMPEG SCRIPT WITHOUT ANY PROCESSING
enabled_library_list=()
-for library in {1..47}; do
+for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
ENABLED_LIBRARY=$(get_library_name $((library - 1)))
enabled_library_list+=(${ENABLED_LIBRARY})
@@ -108,6 +105,11 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
run=1
fi
;;
+ srt)
+ if [[ $OK_openssl -eq 1 ]]; then
+ run=1
+ fi
+ ;;
tesseract)
if [[ $OK_leptonica -eq 1 ]]; then
run=1
@@ -144,12 +146,17 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
"${BASEDIR}"/scripts/run-apple.sh "${library}" 1>>"${BASEDIR}"/build.log 2>&1
+ RC=$?
+
# SET SOME FLAGS AFTER THE BUILD
- if [ $? -eq 0 ]; then
+ if [ $RC -eq 0 ]; then
((completed += 1))
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
@@ -165,6 +172,41 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
done
done
+# BUILD CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+
+ echo -e "\nDEBUG: Custom library ${!library_name} will be built\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DEFINE SOME FLAGS TO REBUILD OPTIONS
+ REBUILD_FLAG=$(echo "REBUILD_${!library_name}" | sed "s/\-/\_/g")
+ LIBRARY_IS_INSTALLED=$(library_is_installed "${LIB_INSTALL_BASE}" "${!library_name}")
+
+ echo -e "INFO: Flags detected for custom library ${!library_name}: already installed=${LIBRARY_IS_INSTALLED}, rebuild requested by user=${!REBUILD_FLAG}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ if [[ ${LIBRARY_IS_INSTALLED} -ne 1 ]] || [[ ${!REBUILD_FLAG} -eq 1 ]]; then
+
+ echo -n "${!library_name}: "
+
+ "${BASEDIR}"/scripts/run-apple.sh "${!library_name}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ # SET SOME FLAGS AFTER THE BUILD
+ if [ $RC -eq 0 ]; then
+ echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
+ else
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+ else
+ echo "${!library_name}: already built"
+ fi
+done
+
# SKIP TO SPEED UP THE BUILD
if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
@@ -179,12 +221,12 @@ if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
export LDFLAGS=$(get_ldflags "${LIB_NAME}")
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
- cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
- LIB_INSTALL_PREFIX="${LIB_INSTALL_BASE}"/"${LIB_NAME}"
+ LIB_INSTALL_PREFIX="${LIB_INSTALL_BASE}/${LIB_NAME}"
# BUILD FFMPEG
- source "${BASEDIR}"/scripts/apple/ffmpeg.sh "$@"
+ source "${BASEDIR}"/scripts/apple/ffmpeg.sh
if [[ $? -ne 0 ]]; then
exit 1
@@ -197,7 +239,7 @@ fi
if [[ ${SKIP_ffmpeg_kit} -ne 1 ]]; then
# BUILD FFMPEG KIT
- . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || exit 1
+ . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || return 1
else
echo -e "\nffmpeg-kit: skipped"
fi
diff --git a/scripts/main-tvos.sh b/scripts/main-tvos.sh
index da6b876..c11d177 100755
--- a/scripts/main-tvos.sh
+++ b/scripts/main-tvos.sh
@@ -20,9 +20,6 @@ if [[ -z ${SDK_PATH} ]]; then
exit 1
fi
-# ENABLE COMMON FUNCTIONS
-source "${BASEDIR}"/scripts/function-"${FFMPEG_KIT_BUILD_TYPE}".sh 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
-
echo -e "\nBuilding ${ARCH} platform targeting tvOS SDK ${TVOS_MIN_VERSION}\n"
echo -e "\nINFO: Starting new build for ${ARCH} targeting tvOS SDK ${TVOS_MIN_VERSION} at $(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -32,13 +29,13 @@ export LIB_INSTALL_BASE="${BASEDIR}/prebuilt/$(get_build_directory)"
# CREATE PACKAGE CONFIG DIRECTORY FOR THIS ARCHITECTURE
PKG_CONFIG_DIRECTORY="${LIB_INSTALL_BASE}/pkgconfig"
if [ ! -d "${PKG_CONFIG_DIRECTORY}" ]; then
- mkdir -p "${PKG_CONFIG_DIRECTORY}" || exit 1
+ mkdir -p "${PKG_CONFIG_DIRECTORY}" || return 1
fi
# FILTER WHICH EXTERNAL LIBRARIES WILL BE BUILT
# NOTE THAT BUILT-IN LIBRARIES ARE FORWARDED TO FFMPEG SCRIPT WITHOUT ANY PROCESSING
enabled_library_list=()
-for library in {1..47}; do
+for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
ENABLED_LIBRARY=$(get_library_name $((library - 1)))
enabled_library_list+=(${ENABLED_LIBRARY})
@@ -108,6 +105,11 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
run=1
fi
;;
+ srt)
+ if [[ $OK_openssl -eq 1 ]]; then
+ run=1
+ fi
+ ;;
tesseract)
if [[ $OK_leptonica -eq 1 ]]; then
run=1
@@ -143,12 +145,17 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
"${BASEDIR}"/scripts/run-apple.sh "${library}" 1>>"${BASEDIR}"/build.log 2>&1
+ RC=$?
+
# SET SOME FLAGS AFTER THE BUILD
- if [ $? -eq 0 ]; then
+ if [ $RC -eq 0 ]; then
((completed += 1))
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
@@ -164,6 +171,41 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
done
done
+# BUILD CUSTOM LIBRARIES
+for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
+ library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
+
+ echo -e "\nDEBUG: Custom library ${!library_name} will be built\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ # DEFINE SOME FLAGS TO REBUILD OPTIONS
+ REBUILD_FLAG=$(echo "REBUILD_${!library_name}" | sed "s/\-/\_/g")
+ LIBRARY_IS_INSTALLED=$(library_is_installed "${LIB_INSTALL_BASE}" "${!library_name}")
+
+ echo -e "INFO: Flags detected for custom library ${!library_name}: already installed=${LIBRARY_IS_INSTALLED}, rebuild requested by user=${!REBUILD_FLAG}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ if [[ ${LIBRARY_IS_INSTALLED} -ne 1 ]] || [[ ${!REBUILD_FLAG} -eq 1 ]]; then
+
+ echo -n "${!library_name}: "
+
+ "${BASEDIR}"/scripts/run-apple.sh "${!library_name}" 1>>"${BASEDIR}"/build.log 2>&1
+
+ RC=$?
+
+ # SET SOME FLAGS AFTER THE BUILD
+ if [ $RC -eq 0 ]; then
+ echo "ok"
+ elif [ $RC -eq 200 ]; then
+ echo -e "not supported\n\nSee build.log for details\n"
+ exit 1
+ else
+ echo -e "failed\n\nSee build.log for details\n"
+ exit 1
+ fi
+ else
+ echo "${!library_name}: already built"
+ fi
+done
+
# SKIP TO SPEED UP THE BUILD
if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
@@ -178,12 +220,12 @@ if [[ ${SKIP_ffmpeg} -ne 1 ]]; then
export LDFLAGS=$(get_ldflags "${LIB_NAME}")
export PKG_CONFIG_LIBDIR="${INSTALL_PKG_CONFIG_DIR}"
- cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || exit 1
+ cd "${BASEDIR}"/src/"${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
LIB_INSTALL_PREFIX="${LIB_INSTALL_BASE}/${LIB_NAME}"
# BUILD FFMPEG
- source "${BASEDIR}"/scripts/apple/ffmpeg.sh "$@"
+ source "${BASEDIR}"/scripts/apple/ffmpeg.sh
if [[ $? -ne 0 ]]; then
exit 1
@@ -196,7 +238,7 @@ fi
if [[ ${SKIP_ffmpeg_kit} -ne 1 ]]; then
# BUILD FFMPEG
- . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || exit 1
+ . "${BASEDIR}"/scripts/apple/ffmpeg-kit.sh "$@" || return 1
else
echo -e "\nffmpeg-kit: skipped"
fi
diff --git a/scripts/source.sh b/scripts/source.sh
index 9e4e1fd..bec2696 100755
--- a/scripts/source.sh
+++ b/scripts/source.sh
@@ -13,7 +13,7 @@ get_library_source() {
;;
chromaprint)
SOURCE_REPO_URL="https://github.com/tanersener/chromaprint"
- SOURCE_ID="v1.5.0"
+ SOURCE_ID="v1.5.1"
SOURCE_TYPE="TAG"
;;
cpu-features)
@@ -28,28 +28,28 @@ get_library_source() {
;;
expat)
SOURCE_REPO_URL="https://github.com/tanersener/libexpat"
- SOURCE_ID="R_2_4_1"
+ SOURCE_ID="R_2_4_2"
SOURCE_TYPE="TAG"
;;
ffmpeg)
SOURCE_REPO_URL="https://github.com/tanersener/FFmpeg"
- SOURCE_ID="90da43557f7257d72e95504f63ae6504406d6eab"
+ SOURCE_ID="30322ebe3c55d0fb18bea4ae04d0fcaf1f97d27f"
SOURCE_TYPE="COMMIT"
- SOURCE_GIT_DESCRIBE="n4.5-dev-2008-g90da43557f" # git describe --tags
+ SOURCE_GIT_DESCRIBE="n4.5-dev-3393-g30322ebe3c" # git describe --tags
;;
fontconfig)
SOURCE_REPO_URL="https://github.com/tanersener/fontconfig"
- SOURCE_ID="2.13.93"
+ SOURCE_ID="2.13.94"
SOURCE_TYPE="TAG"
;;
freetype)
SOURCE_REPO_URL="https://github.com/tanersener/freetype2"
- SOURCE_ID="VER-2-11-0"
+ SOURCE_ID="VER-2-11-1"
SOURCE_TYPE="TAG"
;;
fribidi)
SOURCE_REPO_URL="https://github.com/tanersener/fribidi"
- SOURCE_ID="v1.0.10"
+ SOURCE_ID="v1.0.11"
SOURCE_TYPE="TAG"
;;
giflib)
@@ -69,17 +69,17 @@ get_library_source() {
;;
harfbuzz)
SOURCE_REPO_URL="https://github.com/tanersener/harfbuzz"
- SOURCE_ID="2.9.1"
+ SOURCE_ID="3.2.0"
SOURCE_TYPE="TAG"
;;
jpeg)
SOURCE_REPO_URL="https://github.com/tanersener/libjpeg-turbo"
- SOURCE_ID="2.1.1"
+ SOURCE_ID="2.1.2"
SOURCE_TYPE="TAG"
;;
kvazaar)
SOURCE_REPO_URL="https://github.com/tanersener/kvazaar"
- SOURCE_ID="v2.0.0"
+ SOURCE_ID="v2.1.0"
SOURCE_TYPE="TAG"
;;
lame)
@@ -94,7 +94,7 @@ get_library_source() {
;;
libaom)
SOURCE_REPO_URL="https://github.com/tanersener/libaom"
- SOURCE_ID="v3.1.2"
+ SOURCE_ID="v3.2.0"
SOURCE_TYPE="TAG"
;;
libass)
@@ -154,7 +154,7 @@ get_library_source() {
;;
libvpx)
SOURCE_REPO_URL="https://github.com/tanersener/libvpx"
- SOURCE_ID="v1.10.0"
+ SOURCE_ID="v1.11.0"
SOURCE_TYPE="TAG"
;;
libwebp)
@@ -182,6 +182,11 @@ get_library_source() {
SOURCE_ID="v2.1.1"
SOURCE_TYPE="TAG"
;;
+ openssl)
+ SOURCE_REPO_URL="https://github.com/tanersener/openssl"
+ SOURCE_ID="openssl-3.0.1"
+ SOURCE_TYPE="TAG"
+ ;;
opus)
SOURCE_REPO_URL="https://github.com/tanersener/opus"
SOURCE_ID="v1.3.1"
@@ -217,6 +222,11 @@ get_library_source() {
SOURCE_ID="Speex-1.2.0"
SOURCE_TYPE="TAG"
;;
+ srt)
+ SOURCE_REPO_URL="https://github.com/tanersener/srt"
+ SOURCE_ID="v1.4.4"
+ SOURCE_TYPE="TAG"
+ ;;
tesseract)
SOURCE_REPO_URL="https://github.com/tanersener/tesseract"
SOURCE_ID="3.05.02"
@@ -239,7 +249,7 @@ get_library_source() {
;;
x264)
SOURCE_REPO_URL="https://github.com/tanersener/x264"
- SOURCE_ID="55d517bc4569272a2c9a367a4106c234aba2ffbc"
+ SOURCE_ID="5db6aa6cab1b146e07b60cc1736a01f21da01154"
SOURCE_TYPE="COMMIT" # COMMIT -> r3027
;;
x265)
@@ -252,6 +262,11 @@ get_library_source() {
SOURCE_ID="release-1_3_7"
SOURCE_TYPE="TAG"
;;
+ zimg)
+ SOURCE_REPO_URL="https://github.com/tanersener/zimg"
+ SOURCE_ID="release-3.0.3"
+ SOURCE_TYPE="TAG"
+ ;;
esac
case $2 in
diff --git a/scripts/variable.sh b/scripts/variable.sh
index ef295f9..70c2a92 100755
--- a/scripts/variable.sh
+++ b/scripts/variable.sh
@@ -10,7 +10,7 @@ ENABLED_ARCHITECTURES=(0 0 0 0 0 0 0 0 0 0 0 0 0)
ENABLED_ARCHITECTURE_VARIANTS=(0 0 0 0 0 0 0 0)
# ARRAY OF ENABLED LIBRARIES
-ENABLED_LIBRARIES=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
+ENABLED_LIBRARIES=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
# ARRAY OF LIBRARIES THAT WILL BE RE-CONFIGURED
RECONF_LIBRARIES=()
@@ -21,6 +21,9 @@ REBUILD_LIBRARIES=()
# ARRAY OF LIBRARIES THAT WILL BE RE-DOWNLOADED
REDOWNLOAD_LIBRARIES=()
+# ARRAY OF CUSTOM LIBRARIES
+CUSTOM_LIBRARIES=()
+
# ARCH INDEXES
ARCH_ARM_V7A=0 # android
ARCH_ARM_V7A_NEON=1 # android
@@ -81,28 +84,31 @@ LIBRARY_SDL=30
LIBRARY_TESSERACT=31
LIBRARY_OPENH264=32
LIBRARY_VO_AMRWBENC=33
-LIBRARY_GIFLIB=34
-LIBRARY_JPEG=35
-LIBRARY_LIBOGG=36
-LIBRARY_LIBPNG=37
-LIBRARY_LIBUUID=38
-LIBRARY_NETTLE=39
-LIBRARY_TIFF=40
-LIBRARY_EXPAT=41
-LIBRARY_SNDFILE=42
-LIBRARY_LEPTONICA=43
-LIBRARY_LIBSAMPLERATE=44
-LIBRARY_HARFBUZZ=45
-LIBRARY_CPU_FEATURES=46
-LIBRARY_ANDROID_ZLIB=47
-LIBRARY_ANDROID_MEDIA_CODEC=48
-LIBRARY_APPLE_ZLIB=49
-LIBRARY_APPLE_AUDIOTOOLBOX=50
-LIBRARY_APPLE_BZIP2=51
-LIBRARY_APPLE_VIDEOTOOLBOX=52
-LIBRARY_APPLE_AVFOUNDATION=53
-LIBRARY_APPLE_LIBICONV=54
-LIBRARY_APPLE_LIBUUID=55
-LIBRARY_APPLE_COREIMAGE=56
-LIBRARY_APPLE_OPENCL=57
-LIBRARY_APPLE_OPENGL=58
+LIBRARY_ZIMG=34
+LIBRARY_OPENSSL=35
+LIBRARY_SRT=36
+LIBRARY_GIFLIB=37
+LIBRARY_JPEG=38
+LIBRARY_LIBOGG=39
+LIBRARY_LIBPNG=40
+LIBRARY_LIBUUID=41
+LIBRARY_NETTLE=42
+LIBRARY_TIFF=43
+LIBRARY_EXPAT=44
+LIBRARY_SNDFILE=45
+LIBRARY_LEPTONICA=46
+LIBRARY_LIBSAMPLERATE=47
+LIBRARY_HARFBUZZ=48
+LIBRARY_CPU_FEATURES=49
+LIBRARY_ANDROID_ZLIB=50
+LIBRARY_ANDROID_MEDIA_CODEC=51
+LIBRARY_APPLE_ZLIB=52
+LIBRARY_APPLE_AUDIOTOOLBOX=53
+LIBRARY_APPLE_BZIP2=54
+LIBRARY_APPLE_VIDEOTOOLBOX=55
+LIBRARY_APPLE_AVFOUNDATION=56
+LIBRARY_APPLE_LIBICONV=57
+LIBRARY_APPLE_LIBUUID=58
+LIBRARY_APPLE_COREIMAGE=59
+LIBRARY_APPLE_OPENCL=60
+LIBRARY_APPLE_OPENGL=61
diff --git a/src/.gitignore b/src/.gitignore
index 828d4e3..33662f5 100644
--- a/src/.gitignore
+++ b/src/.gitignore
@@ -1,48 +1 @@
-chromaprint
-cpu-features
-dav1d
-expat
-ffmpeg
-fontconfig
-freetype
-fribidi
-giflib
-gmp
-gnutls
-harfbuzz
-jpeg
-kvazaar
-lame
-leptonica
-libaom
-libass
-libiconv
-libilbc
-libogg
-libpng
-libsamplerate
-libsndfile
-libtheora
-libuuid
-libvidstab
-libvorbis
-libvpx
-libwebp
-libxml2
-nettle
-opencore-amr
-openh264
-opus
-rubberband
-sdl
-shine
-snappy
-soxr
-speex
-tesseract
-tiff
-twolame
-vo-amrwbenc
-x264
-x265
-xvidcore
+/*
diff --git a/tools/create_ios_universal_test_package.sh b/tools/create_ios_universal_test_package.sh
deleted file mode 100755
index 7fcd60e..0000000
--- a/tools/create_ios_universal_test_package.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-cd ../prebuilt/bundle-apple-universal-ios || exit 1
-find . -name "*.a" -not -path "./ffmpeg-kit/*" -exec cp {} ./ffmpeg-kit/lib \; || exit 1
-cp -r ffmpeg/include/* ffmpeg-kit/include || exit 1
-
-# COPY LICENSE FILE OF EACH LIBRARY
-LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-for LICENSE_FILE in ${LICENSE_FILES[@]}
-do
- LIBRARY_NAME=$(echo ${LICENSE_FILE} | sed 's/\.\///g;s/\/LICENSE//g')
- cp ${LICENSE_FILE} ffmpeg-kit/LICENSE.${LIBRARY_NAME} || exit 1
-done
-
-zip -r "../ffmpeg-kit-ios-universal.zip" ffmpeg-kit || exit 1
\ No newline at end of file
diff --git a/tools/create_macos_universal_test_package.sh b/tools/create_macos_universal_test_package.sh
deleted file mode 100755
index 5742d4a..0000000
--- a/tools/create_macos_universal_test_package.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-cd ../prebuilt/bundle-apple-universal-macos || exit 1
-find . -name "*.a" -not -path "./ffmpeg-kit/*" -exec cp {} ./ffmpeg-kit/lib \; || exit 1
-cp -r ffmpeg/include/* ffmpeg-kit/include || exit 1
-
-# COPY LICENSE FILE OF EACH LIBRARY
-LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-for LICENSE_FILE in ${LICENSE_FILES[@]}
-do
- LIBRARY_NAME=$(echo ${LICENSE_FILE} | sed 's/\.\///g;s/\/LICENSE//g')
- cp ${LICENSE_FILE} ffmpeg-kit/LICENSE.${LIBRARY_NAME} || exit 1
-done
-
-zip -r "../ffmpeg-kit-macos-universal.zip" ffmpeg-kit || exit 1
\ No newline at end of file
diff --git a/tools/create_tvos_universal_test_package.sh b/tools/create_tvos_universal_test_package.sh
deleted file mode 100755
index 0fa0322..0000000
--- a/tools/create_tvos_universal_test_package.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-cd ../prebuilt/bundle-apple-universal-tvos || exit 1
-find . -name "*.a" -not -path "./ffmpeg-kit/*" -exec cp {} ./ffmpeg-kit/lib \; || exit 1
-cp -r ffmpeg/include/* ffmpeg-kit/include || exit 1
-
-# COPY LICENSE FILE OF EACH LIBRARY
-LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-for LICENSE_FILE in ${LICENSE_FILES[@]}
-do
- LIBRARY_NAME=$(echo ${LICENSE_FILE} | sed 's/\.\///g;s/\/LICENSE//g')
- cp ${LICENSE_FILE} ffmpeg-kit/LICENSE.${LIBRARY_NAME} || exit 1
-done
-
-zip -r "../ffmpeg-kit-tvos-universal.zip" ffmpeg-kit || exit 1
\ No newline at end of file
diff --git a/tools/protocols/libavformat_file.c b/tools/protocols/libavformat_file.c
index 6f068d4..ccd07d9 100644
--- a/tools/protocols/libavformat_file.c
+++ b/tools/protocols/libavformat_file.c
@@ -38,26 +38,35 @@ static int64_t fd_seek(URLContext *h, int64_t pos, int whence)
static int fd_open(URLContext *h, const char *filename, int flags)
{
FileContext *c = h->priv_data;
- int fd;
+ int saf_id;
struct stat st;
char *final;
char *saveptr = NULL;
- char *fd_string = NULL;
+ char *saf_id_string = NULL;
char filename_backup[128];
- av_strstart(filename, "fd:", &filename);
av_strstart(filename, "saf:", &filename);
av_strlcpy(filename_backup, filename, FFMIN(sizeof(filename), sizeof(filename_backup)));
- fd_string = av_strtok(filename_backup, ".", &saveptr);
+ saf_id_string = av_strtok(filename_backup, ".", &saveptr);
- fd = strtol(fd_string, &final, 10);
- if ((fd_string == final) || *final ) {
- fd = -1;
+ saf_id = strtol(saf_id_string, &final, 10);
+ if ((saf_id_string == final) || *final ) {
+ saf_id = -1;
}
- c->fd = fd;
+ saf_open_function custom_saf_open = av_get_saf_open();
+ if (custom_saf_open != NULL) {
+ int rc = custom_saf_open(saf_id);
+ if (rc) {
+ c->fd = rc;
+ } else {
+ c->fd = saf_id;
+ }
+ } else {
+ c->fd = saf_id;
+ }
- h->is_streamed = !fstat(fd, &st) && S_ISFIFO(st.st_mode);
+ h->is_streamed = !fstat(saf_id, &st) && S_ISFIFO(st.st_mode);
/* Buffer writes more than the default 32k to improve throughput especially
* with networked file systems */
@@ -74,7 +83,6 @@ static int fd_check(URLContext *h, int mask)
{
int ret = 0;
const char *filename = h->filename;
- av_strstart(filename, "fd:", &filename);
av_strstart(filename, "saf:", &filename);
{
@@ -109,7 +117,6 @@ static int fd_delete(URLContext *h)
#if HAVE_UNISTD_H
int ret;
const char *filename = h->filename;
- av_strstart(filename, "fd:", &filename);
av_strstart(filename, "saf:", &filename);
ret = rmdir(filename);
@@ -132,9 +139,7 @@ static int fd_move(URLContext *h_src, URLContext *h_dst)
{
const char *filename_src = h_src->filename;
const char *filename_dst = h_dst->filename;
- av_strstart(filename_src, "fd:", &filename_src);
av_strstart(filename_src, "saf:", &filename_src);
- av_strstart(filename_dst, "fd:", &filename_dst);
av_strstart(filename_dst, "saf:", &filename_dst);
if (rename(filename_src, filename_dst) < 0)
@@ -147,11 +152,11 @@ static int fd_close(URLContext *h)
{
FileContext *c = h->priv_data;
- fd_close_function custom_fd_close = av_get_fd_close();
- if (custom_fd_close != NULL) {
- return custom_fd_close(c->fd);
+ saf_close_function custom_saf_close = av_get_saf_close();
+ if (custom_saf_close != NULL) {
+ return custom_saf_close(c->fd);
} else {
- return close(c->fd);
+ return 0;
}
}
@@ -162,13 +167,6 @@ static const AVClass saf_class = {
.version = LIBAVUTIL_VERSION_INT,
};
-static const AVClass fd_class = {
- .class_name = "fd",
- .item_name = av_default_item_name,
- .option = file_options,
- .version = LIBAVUTIL_VERSION_INT,
-};
-
const URLProtocol ff_saf_protocol = {
.name = "saf",
.url_open = fd_open,
@@ -184,19 +182,3 @@ const URLProtocol ff_saf_protocol = {
.priv_data_class = &saf_class,
.default_whitelist = "saf,crypto,data"
};
-
-const URLProtocol ff_fd_protocol = {
- .name = "fd",
- .url_open = fd_open,
- .url_read = file_read,
- .url_write = file_write,
- .url_seek = fd_seek,
- .url_close = fd_close,
- .url_get_file_handle = file_get_handle,
- .url_check = fd_check,
- .url_delete = fd_delete,
- .url_move = fd_move,
- .priv_data_size = sizeof(FileContext),
- .priv_data_class = &fd_class,
- .default_whitelist = "fd,crypto,data"
-};
diff --git a/tools/protocols/libavutil_file.c b/tools/protocols/libavutil_file.c
index 7192efb..8430a1d 100644
--- a/tools/protocols/libavutil_file.c
+++ b/tools/protocols/libavutil_file.c
@@ -17,12 +17,21 @@
* along with FFmpegKit. If not, see .
*/
-static fd_close_function _fd_close_function = NULL;
+static saf_open_function _saf_open_function = NULL;
+static saf_close_function _saf_close_function = NULL;
-fd_close_function av_get_fd_close() {
- return _fd_close_function;
+saf_open_function av_get_saf_open() {
+ return _saf_open_function;
}
-void av_set_fd_close(fd_close_function close_function) {
- _fd_close_function = close_function;
+saf_close_function av_get_saf_close() {
+ return _saf_close_function;
+}
+
+void av_set_saf_open(saf_open_function open_function) {
+ _saf_open_function = open_function;
+}
+
+void av_set_saf_close(saf_close_function close_function) {
+ _saf_close_function = close_function;
}
diff --git a/tools/protocols/libavutil_file.h b/tools/protocols/libavutil_file.h
index 7fa12ec..897290b 100644
--- a/tools/protocols/libavutil_file.h
+++ b/tools/protocols/libavutil_file.h
@@ -20,10 +20,16 @@
#ifndef AVUTIL_FILE_FFMPEG_KIT_PROTOCOLS_H
#define AVUTIL_FILE_FFMPEG_KIT_PROTOCOLS_H
-typedef int (*fd_close_function)(int);
+typedef int (*saf_open_function)(int);
-fd_close_function av_get_fd_close(void);
+typedef int (*saf_close_function)(int);
-void av_set_fd_close(fd_close_function);
+saf_open_function av_get_saf_open(void);
+
+saf_close_function av_get_saf_close(void);
+
+void av_set_saf_open(saf_open_function);
+
+void av_set_saf_close(saf_close_function);
#endif /* AVUTIL_FILE_FFMPEG_KIT_PROTOCOLS_H */
diff --git a/tools/release/android.lts.sh b/tools/release/android.lts.sh
index 72e0213..4e03eab 100755
--- a/tools/release/android.lts.sh
+++ b/tools/release/android.lts.sh
@@ -22,7 +22,8 @@ if [ $# -ne 1 ]; then
exit 1
fi
-export VERSION_CODE="${ANDROID_LTS_MIN_SDK}0"$(echo $1 | sed "s/\.//g")"0"
+VERSION_CODE="${ANDROID_LTS_MIN_SDK}0"$(echo $1 | sed "s/\.//g")"0"
+export VERSION_CODE=${VERSION_CODE:0:6}
# VALIDATE VERSIONS
if [[ "${ANDROID_FFMPEG_KIT_VERSION}" != "$1" ]]; then
diff --git a/tools/release/android.sh b/tools/release/android.sh
index b39d8aa..df2581a 100755
--- a/tools/release/android.sh
+++ b/tools/release/android.sh
@@ -22,7 +22,8 @@ if [ $# -ne 1 ]; then
exit 1
fi
-export VERSION_CODE="${ANDROID_MAIN_MIN_SDK}0"$(echo $1 | sed "s/\.//g")"0"
+VERSION_CODE="${ANDROID_MAIN_MIN_SDK}0"$(echo $1 | sed "s/\.//g")"0"
+export VERSION_CODE=${VERSION_CODE:0:6}
# VALIDATE VERSIONS
if [[ "${ANDROID_FFMPEG_KIT_VERSION}" != "$1" ]]; then
diff --git a/tools/release/android/build.gradle b/tools/release/android/build.gradle
index be18375..927cf4a 100644
--- a/tools/release/android/build.gradle
+++ b/tools/release/android/build.gradle
@@ -2,13 +2,13 @@ apply plugin: 'com.android.library'
android {
compileSdkVersion 30
- ndkVersion "23.0.7599858"
+ ndkVersion "23.1.7779620"
defaultConfig {
minSdkVersion 24
targetSdkVersion 30
- versionCode 240450
- versionName "4.5"
+ versionCode 240451
+ versionName "4.5.1"
project.archivesBaseName = "ffmpeg-kit"
consumerProguardFiles 'proguard-rules.pro'
}
@@ -44,8 +44,8 @@ task javadoc(type: Javadoc) {
}
dependencies {
- implementation 'com.arthenica:smart-exception-java:0.1.0'
- testImplementation "androidx.test.ext:junit:1.1.2"
+ implementation 'com.arthenica:smart-exception-java:0.1.1'
+ testImplementation "androidx.test.ext:junit:1.1.3"
testImplementation "org.json:json:20201115"
}
diff --git a/tools/release/android/build.lts.gradle b/tools/release/android/build.lts.gradle
index a0d146f..e916858 100644
--- a/tools/release/android/build.lts.gradle
+++ b/tools/release/android/build.lts.gradle
@@ -2,13 +2,13 @@ apply plugin: 'com.android.library'
android {
compileSdkVersion 30
- ndkVersion "23.0.7599858"
+ ndkVersion "23.1.7779620"
defaultConfig {
minSdkVersion 16
targetSdkVersion 30
- versionCode 160450
- versionName "4.5.LTS"
+ versionCode 160451
+ versionName "4.5.1.LTS"
project.archivesBaseName = "ffmpeg-kit"
consumerProguardFiles 'proguard-rules.pro'
}
@@ -44,8 +44,8 @@ task javadoc(type: Javadoc) {
}
dependencies {
- implementation 'com.arthenica:smart-exception-java:0.1.0'
- testImplementation "androidx.test.ext:junit:1.1.2"
+ implementation 'com.arthenica:smart-exception-java:0.1.1'
+ testImplementation "androidx.test.ext:junit:1.1.3"
testImplementation "org.json:json:20201115"
}
diff --git a/tools/release/apple/ffmpeg-kit-ios-audio.podspec b/tools/release/apple/ffmpeg-kit-ios-audio.podspec
index b171d48..666141c 100644
--- a/tools/release/apple/ffmpeg-kit-ios-audio.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-audio.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-audio"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Audio Static Framework"
+ s.summary = "FFmpeg Kit iOS Audio Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-audio-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'lame.framework', 'libilbc.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libsndfile.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'opus.framework', 'shine.framework', 'soxr.framework', 'speex.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-full-gpl.podspec b/tools/release/apple/ffmpeg-kit-ios-full-gpl.podspec
index 548506f..55e6e9a 100644
--- a/tools/release/apple/ffmpeg-kit-ios-full-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-full-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-full-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Full GPL Static Framework"
+ s.summary = "FFmpeg Kit iOS Full GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-gpl-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-full.podspec b/tools/release/apple/ffmpeg-kit-ios-full.podspec
index 38f08ac..7530ae1 100644
--- a/tools/release/apple/ffmpeg-kit-ios-full.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-full.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-full"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Full Static Framework"
+ s.summary = "FFmpeg Kit iOS Full Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-https-gpl.podspec b/tools/release/apple/ffmpeg-kit-ios-https-gpl.podspec
index 218bbe3..edccda2 100644
--- a/tools/release/apple/ffmpeg-kit-ios-https-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-https-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-https-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Https GPL Static Framework"
+ s.summary = "FFmpeg Kit iOS Https GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-gpl-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-https.podspec b/tools/release/apple/ffmpeg-kit-ios-https.podspec
index 7cc5db3..9c4fb91 100644
--- a/tools/release/apple/ffmpeg-kit-ios-https.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-https.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-https"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Https Static Framework"
+ s.summary = "FFmpeg Kit iOS Https Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-min-gpl.podspec b/tools/release/apple/ffmpeg-kit-ios-min-gpl.podspec
index 6b1ff4b..0a25acb 100644
--- a/tools/release/apple/ffmpeg-kit-ios-min-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-min-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-min-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Min GPL Static Framework"
+ s.summary = "FFmpeg Kit iOS Min GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-gpl-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-ios-min.podspec b/tools/release/apple/ffmpeg-kit-ios-min.podspec
index d800b40..a11e9cd 100644
--- a/tools/release/apple/ffmpeg-kit-ios-min.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-min.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-min"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Min Static Framework"
+ s.summary = "FFmpeg Kit iOS Min Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,7 +17,7 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
diff --git a/tools/release/apple/ffmpeg-kit-ios-video.podspec b/tools/release/apple/ffmpeg-kit-ios-video.podspec
index 0beacb2..722014f 100644
--- a/tools/release/apple/ffmpeg-kit-ios-video.podspec
+++ b/tools/release/apple/ffmpeg-kit-ios-video.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-ios-video"
s.version = "VERSION"
- s.summary = "FFmpeg Kit iOS Video Static Framework"
+ s.summary = "FFmpeg Kit iOS Video Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-video-VERSION-ios-framework.zip" }
- s.ios.deployment_target = '9.3'
+ s.ios.deployment_target = '10'
s.ios.frameworks = 'AudioToolbox','AVFoundation','CoreMedia','VideoToolbox'
- s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'libass.framework', 'libogg.framework', 'libpng.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'snappy.framework', 'tiff.framework'
+ s.ios.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-audio.podspec b/tools/release/apple/ffmpeg-kit-macos-audio.podspec
index a4b42f1..4e15dbb 100644
--- a/tools/release/apple/ffmpeg-kit-macos-audio.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-audio.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-audio"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Audio Static Framework"
+ s.summary = "FFmpeg Kit macOS Audio Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-audio-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
+ s.osx.deployment_target = '10.12'
s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'lame.framework', 'libilbc.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libsndfile.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'opus.framework', 'shine.framework', 'soxr.framework', 'speex.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-full-gpl.podspec b/tools/release/apple/ffmpeg-kit-macos-full-gpl.podspec
index ea16246..71f1d1e 100644
--- a/tools/release/apple/ffmpeg-kit-macos-full-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-full-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-full-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Full GPL Static Framework"
+ s.summary = "FFmpeg Kit macOS Full GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-gpl-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
- s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.osx.deployment_target = '10.12'
+ s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL', 'Security', 'VideoToolbox'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-full.podspec b/tools/release/apple/ffmpeg-kit-macos-full.podspec
index 54f7a44..10fee8a 100644
--- a/tools/release/apple/ffmpeg-kit-macos-full.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-full.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-full"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Full Static Framework"
+ s.summary = "FFmpeg Kit macOS Full Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
- s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.osx.deployment_target = '10.12'
+ s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL', 'Security', 'VideoToolbox'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-https-gpl.podspec b/tools/release/apple/ffmpeg-kit-macos-https-gpl.podspec
index 5deb092..c847856 100644
--- a/tools/release/apple/ffmpeg-kit-macos-https-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-https-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-https-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Https GPL Static Framework"
+ s.summary = "FFmpeg Kit macOS Https GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-gpl-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
- s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.osx.deployment_target = '10.12'
+ s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL', 'Security', 'VideoToolbox'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-https.podspec b/tools/release/apple/ffmpeg-kit-macos-https.podspec
index f4a4170..f67a845 100644
--- a/tools/release/apple/ffmpeg-kit-macos-https.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-https.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-https"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Https Static Framework"
+ s.summary = "FFmpeg Kit macOS Https Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
- s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework'
+ s.osx.deployment_target = '10.12'
+ s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL', 'Security', 'VideoToolbox'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-min-gpl.podspec b/tools/release/apple/ffmpeg-kit-macos-min-gpl.podspec
index f6a2da7..88d9725 100644
--- a/tools/release/apple/ffmpeg-kit-macos-min-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-min-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-min-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Min GPL Static Framework"
+ s.summary = "FFmpeg Kit macOS Min GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-gpl-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
+ s.osx.deployment_target = '10.12'
s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-macos-min.podspec b/tools/release/apple/ffmpeg-kit-macos-min.podspec
index 0ef2562..4297dd7 100644
--- a/tools/release/apple/ffmpeg-kit-macos-min.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-min.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-min"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Min Static Framework"
+ s.summary = "FFmpeg Kit macOS Min Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,7 +17,7 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
+ s.osx.deployment_target = '10.12'
s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
diff --git a/tools/release/apple/ffmpeg-kit-macos-video.podspec b/tools/release/apple/ffmpeg-kit-macos-video.podspec
index 012b968..817b612 100644
--- a/tools/release/apple/ffmpeg-kit-macos-video.podspec
+++ b/tools/release/apple/ffmpeg-kit-macos-video.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-macos-video"
s.version = "VERSION"
- s.summary = "FFmpeg Kit macOS Video Static Framework"
+ s.summary = "FFmpeg Kit macOS Video Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-video-VERSION-macos-framework.zip" }
- s.osx.deployment_target = '10.11'
+ s.osx.deployment_target = '10.12'
s.osx.frameworks = 'AudioToolbox','AVFoundation','CoreAudio','CoreImage','CoreMedia','OpenCL','OpenGL','VideoToolbox'
- s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'libass.framework', 'libogg.framework', 'libpng.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'snappy.framework', 'tiff.framework'
+ s.osx.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-audio.podspec b/tools/release/apple/ffmpeg-kit-tvos-audio.podspec
index 98cbf65..2c02d50 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-audio.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-audio.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-audio"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Audio Static Framework"
+ s.summary = "FFmpeg Kit tvOS Audio Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-audio-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'lame.framework', 'libilbc.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libsndfile.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'opus.framework', 'shine.framework', 'soxr.framework', 'speex.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-full-gpl.podspec b/tools/release/apple/ffmpeg-kit-tvos-full-gpl.podspec
index 577d857..3213801 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-full-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-full-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-full-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Full GPL Static Framework"
+ s.summary = "FFmpeg Kit tvOS Full GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-gpl-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-full.podspec b/tools/release/apple/ffmpeg-kit-tvos-full.podspec
index 63b1946..7150f2c 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-full.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-full.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-full"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Full Static Framework"
+ s.summary = "FFmpeg Kit tvOS Full Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-full-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'gmp.framework', 'gnutls.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'lame.framework', 'libass.framework', 'libhogweed.framework', 'libilbc.framework', 'libnettle.framework', 'libogg.framework', 'libopencore-amrnb.framework', 'libpng.framework', 'libsndfile.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'libxml2.framework', 'opus.framework', 'shine.framework', 'snappy.framework', 'soxr.framework', 'speex.framework', 'tiff.framework', 'twolame.framework', 'vo-amrwbenc.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-https-gpl.podspec b/tools/release/apple/ffmpeg-kit-tvos-https-gpl.podspec
index 98b27c5..ac0077f 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-https-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-https-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-https-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Https GPL Static Framework"
+ s.summary = "FFmpeg Kit tvOS Https GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-gpl-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-https.podspec b/tools/release/apple/ffmpeg-kit-tvos-https.podspec
index d00368b..3fa42bc 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-https.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-https.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-https"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Https Static Framework"
+ s.summary = "FFmpeg Kit tvOS Https Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-https-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'gmp.framework', 'gnutls.framework', 'libhogweed.framework', 'libnettle.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-min-gpl.podspec b/tools/release/apple/ffmpeg-kit-tvos-min-gpl.podspec
index 9bb5698..c11ae15 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-min-gpl.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-min-gpl.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-min-gpl"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Min GPL Static Framework"
+ s.summary = "FFmpeg Kit tvOS Min GPL Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-gpl-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'libvidstab.framework', 'x264.framework', 'x265.framework', 'xvidcore.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/ffmpeg-kit-tvos-min.podspec b/tools/release/apple/ffmpeg-kit-tvos-min.podspec
index 9c8676a..6f7586b 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-min.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-min.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-min"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Min Static Framework"
+ s.summary = "FFmpeg Kit tvOS Min Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,7 +17,7 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-min-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
diff --git a/tools/release/apple/ffmpeg-kit-tvos-video.podspec b/tools/release/apple/ffmpeg-kit-tvos-video.podspec
index e785c5a..56448ec 100644
--- a/tools/release/apple/ffmpeg-kit-tvos-video.podspec
+++ b/tools/release/apple/ffmpeg-kit-tvos-video.podspec
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "ffmpeg-kit-tvos-video"
s.version = "VERSION"
- s.summary = "FFmpeg Kit tvOS Video Static Framework"
+ s.summary = "FFmpeg Kit tvOS Video Shared Framework"
s.description = <<-DESC
DESCRIPTION
DESC
@@ -17,8 +17,8 @@ Pod::Spec.new do |s|
s.source = { :http => "https://github.com/tanersener/ffmpeg-kit/releases/download/vVERSION/ffmpeg-kit-video-VERSION-tvos-framework.zip" }
- s.tvos.deployment_target = '9.2'
+ s.tvos.deployment_target = '10.0'
s.tvos.frameworks = 'AudioToolbox','VideoToolbox','CoreMedia'
- s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework', 'dav1d.framework', 'expat.framework', 'fontconfig.framework', 'freetype.framework', 'fribidi.framework', 'giflib.framework', 'harfbuzz.framework', 'jpeg.framework', 'kvazaar.framework', 'libass.framework', 'libogg.framework', 'libpng.framework', 'libtheora.framework', 'libtheoradec.framework', 'libtheoraenc.framework', 'libvorbis.framework', 'libvorbisenc.framework', 'libvorbisfile.framework', 'libvpx.framework', 'libwebp.framework', 'libwebpmux.framework', 'libwebpdemux.framework', 'snappy.framework', 'tiff.framework'
+ s.tvos.vendored_frameworks = 'ffmpegkit.framework', 'libavcodec.framework', 'libavdevice.framework', 'libavfilter.framework', 'libavformat.framework', 'libavutil.framework', 'libswresample.framework', 'libswscale.framework'
end
diff --git a/tools/release/apple/strip-frameworks.sh b/tools/release/apple/strip-frameworks.sh
new file mode 100755
index 0000000..2c23237
--- /dev/null
+++ b/tools/release/apple/strip-frameworks.sh
@@ -0,0 +1,62 @@
+################################################################################
+#
+# Copyright 2015 Realm Inc.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+################################################################################
+
+# This script strips all non-valid architectures from dynamic libraries in
+# the application's `Frameworks` directory.
+#
+# The following environment variables are required:
+#
+# BUILT_PRODUCTS_DIR
+# FRAMEWORKS_FOLDER_PATH
+# VALID_ARCHS
+# EXPANDED_CODE_SIGN_IDENTITY
+
+
+# Signs a framework with the provided identity
+code_sign() {
+# Use the current code_sign_identitiy
+echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}"
+echo "/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} --preserve-metadata=identifier,entitlements $1"
+/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} --preserve-metadata=identifier,entitlements "$1"
+}
+
+echo "Stripping frameworks"
+cd "${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}"
+
+for file in $(find . -type f -perm +111); do
+# Skip non-dynamic libraries
+if ! [[ "$(file "$file")" == *"dynamically linked shared library"* ]]; then
+continue
+fi
+# Get architectures for current file
+archs="$(lipo -info "${file}" | rev | cut -d ':' -f1 | rev)"
+stripped=""
+for arch in $archs; do
+if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then
+# Strip non-valid architectures in-place
+lipo -remove "$arch" -output "$file" "$file" || exit 1
+stripped="$stripped $arch"
+fi
+done
+if [[ "$stripped" != "" ]]; then
+echo "Stripped $file of architectures:$stripped"
+if [ "${CODE_SIGNING_REQUIRED}" == "YES" ]; then
+code_sign "${file}"
+fi
+fi
+done
diff --git a/tools/release/common.sh b/tools/release/common.sh
index 1e092ff..857bed9 100755
--- a/tools/release/common.sh
+++ b/tools/release/common.sh
@@ -6,7 +6,7 @@ export ANDROID_MAIN_OPTIONS="--disable-arm-v7a --enable-android-media-codec --en
export ANDROID_LTS_OPTIONS="--lts --enable-android-media-codec --enable-android-zlib"
export IOS_MAIN_OPTIONS="--xcframework --disable-armv7 --disable-armv7s --disable-i386 --disable-arm64e --enable-ios-audiotoolbox --enable-ios-avfoundation --enable-ios-bzip2 --enable-ios-libiconv --enable-ios-videotoolbox --enable-ios-zlib"
-export IOS_LTS_OPTIONS="--disable-armv7s --lts --enable-ios-audiotoolbox --enable-ios-bzip2 --enable-ios-libiconv --enable-ios-zlib"
+export IOS_LTS_OPTIONS="--disable-armv7s --disable-arm64e --lts --enable-ios-audiotoolbox --enable-ios-bzip2 --enable-ios-libiconv --enable-ios-zlib"
export TVOS_MAIN_OPTIONS="--xcframework --enable-tvos-bzip2 --enable-tvos-audiotoolbox --enable-tvos-libiconv --enable-tvos-videotoolbox --enable-tvos-zlib"
export TVOS_LTS_OPTIONS="--disable-arm64-simulator --lts --enable-tvos-bzip2 --enable-tvos-audiotoolbox --enable-tvos-libiconv --enable-tvos-zlib"
@@ -25,8 +25,8 @@ fi
export GPL_PACKAGES="--enable-gpl --enable-libvidstab --enable-x264 --enable-x265 --enable-xvidcore"
export HTTPS_PACKAGES="--enable-gnutls --enable-gmp"
export AUDIO_PACKAGES="--enable-lame --enable-libilbc --enable-libvorbis --enable-opencore-amr --enable-opus --enable-shine --enable-soxr --enable-speex --enable-twolame --enable-vo-amrwbenc"
-export VIDEO_PACKAGES="--enable-dav1d --enable-fontconfig --enable-freetype --enable-fribidi --enable-kvazaar --enable-libass ${ANDROID_EXTRA_VIDEO_PACKAGES} --enable-libtheora --enable-libvpx --enable-snappy --enable-libwebp"
-export FULL_PACKAGES="--enable-dav1d --enable-fontconfig --enable-freetype --enable-fribidi --enable-gmp --enable-gnutls --enable-kvazaar --enable-lame --enable-libass ${ANDROID_EXTRA_VIDEO_PACKAGES} --enable-libilbc --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-opencore-amr --enable-opus --enable-shine --enable-snappy --enable-soxr --enable-speex --enable-twolame --enable-vo-amrwbenc"
+export VIDEO_PACKAGES="--enable-dav1d --enable-fontconfig --enable-freetype --enable-fribidi --enable-kvazaar --enable-libass ${ANDROID_EXTRA_VIDEO_PACKAGES} --enable-libtheora --enable-libvpx --enable-snappy --enable-libwebp --enable-zimg"
+export FULL_PACKAGES="--enable-dav1d --enable-fontconfig --enable-freetype --enable-fribidi --enable-gmp --enable-gnutls --enable-kvazaar --enable-lame --enable-libass ${ANDROID_EXTRA_VIDEO_PACKAGES} --enable-libilbc --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-zimg --enable-libxml2 --enable-opencore-amr --enable-opus --enable-shine --enable-snappy --enable-soxr --enable-speex --enable-twolame --enable-vo-amrwbenc"
export ANDROID_FFMPEG_KIT_VERSION=$(grep '#define FFMPEG_KIT_VERSION' "${BASEDIR}"/../../android/ffmpeg-kit-android-lib/src/main/cpp/ffmpegkit.h | grep -Eo '\".*\"' | sed -e 's/\"//g')
export APPLE_FFMPEG_KIT_VERSION=$(grep 'FFmpegKitVersion ' ${BASEDIR}/../../apple/src/FFmpegKitConfig.m | grep -Eo '\".*\"' | sed -e 's/\"//g')
@@ -40,6 +40,6 @@ export LIBRARY_DESCRIPTION_MIN_GPL="Includes FFmpeg with libvid.stab, x264, x265
export LIBRARY_DESCRIPTION_HTTPS="Includes FFmpeg with gmp and gnutls libraries enabled."
export LIBRARY_DESCRIPTION_HTTPS_GPL="Includes FFmpeg with gmp, gnutls, libvid.stab, x264, x265 and xvidcore libraries enabled."
export LIBRARY_DESCRIPTION_AUDIO="Includes FFmpeg with lame, libilbc, libvorbis, opencore-amr, opus, shine, soxr, speex, twolame and vo-amrwbenc libraries enabled."
-export LIBRARY_DESCRIPTION_VIDEO="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, kvazaar, libass, ${ANDROID_EXTRA_DESCRIPTION}libtheora, libvpx, snappy and libwebp libraries enabled."
-export LIBRARY_DESCRIPTION_FULL="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, gmp, gnutls, kvazaar, lame, libass, ${ANDROID_EXTRA_DESCRIPTION}libilbc, libtheora, libvorbis, libvpx, libwebp, libxml2, opencore-amr, opus, shine, snappy, soxr, speex, twolame and vo-amrwbenc libraries enabled."
-export LIBRARY_DESCRIPTION_FULL_GPL="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, gmp, gnutls, kvazaar, lame, libass, ${ANDROID_EXTRA_DESCRIPTION}libilbc, libtheora, libvid.stab, libvorbis, libvpx, libwebp, libxml2, opencore-amr, opus, shine, snappy, soxr, speex, twolame, vo-amrwbenc, x264, x265 and xvidcore libraries enabled."
+export LIBRARY_DESCRIPTION_VIDEO="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, kvazaar, libass, ${ANDROID_EXTRA_DESCRIPTION}libtheora, libvpx, snappy, libwebp and zimg libraries enabled."
+export LIBRARY_DESCRIPTION_FULL="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, gmp, gnutls, kvazaar, lame, libass, ${ANDROID_EXTRA_DESCRIPTION}libilbc, libtheora, libvorbis, libvpx, libwebp, zimg, libxml2, opencore-amr, opus, shine, snappy, soxr, speex, twolame and vo-amrwbenc libraries enabled."
+export LIBRARY_DESCRIPTION_FULL_GPL="Includes FFmpeg with dav1d, fontconfig, freetype, fribidi, gmp, gnutls, kvazaar, lame, libass, ${ANDROID_EXTRA_DESCRIPTION}libilbc, libtheora, libvid.stab, libvorbis, libvpx, libwebp, zimg, libxml2, opencore-amr, opus, shine, snappy, soxr, speex, twolame, vo-amrwbenc, x264, x265 and xvidcore libraries enabled."
diff --git a/tools/release/flutter/create_packages.sh b/tools/release/flutter/create_packages.sh
index e89e624..5867cef 100755
--- a/tools/release/flutter/create_packages.sh
+++ b/tools/release/flutter/create_packages.sh
@@ -19,7 +19,7 @@ create_main_releases() {
for CURRENT_PACKAGE in "${PACKAGES[@]}"; do
local FLUTTER_PACKAGE_NAME="$(echo "${CURRENT_PACKAGE}" | sed "s/\-/\_/g")"
local PACKAGE_PATH="${PACKAGES_DIR}/${CURRENT_PACKAGE}"
- cp -r ${SOURCE_DIR} ${PACKAGE_PATH}
+ cp -R ${SOURCE_DIR} ${PACKAGE_PATH}
# 1. pubspec
$SED_INLINE "s|name: ffmpeg_kit_flutter|name: ffmpeg_kit_flutter_$FLUTTER_PACKAGE_NAME|g" ${PACKAGE_PATH}/pubspec.yaml
@@ -54,7 +54,7 @@ create_lts_releases() {
for CURRENT_PACKAGE in "${PACKAGES[@]}"; do
local FLUTTER_PACKAGE_NAME="$(echo "${CURRENT_PACKAGE}" | sed "s/\-/\_/g")"
local PACKAGE_PATH="${PACKAGES_DIR}/${CURRENT_PACKAGE}-lts"
- cp -r ${SOURCE_DIR} ${PACKAGE_PATH}
+ cp -R ${SOURCE_DIR} ${PACKAGE_PATH}
# 1. pubspec
$SED_INLINE "s|name: ffmpeg_kit_flutter|name: ffmpeg_kit_flutter_$FLUTTER_PACKAGE_NAME|g" ${PACKAGE_PATH}/pubspec.yaml
@@ -103,4 +103,4 @@ create_main_releases;
create_lts_releases;
-cp -r "${BASEDIR}/flutter/flutter_platform_interface" "$PACKAGES_DIR"
\ No newline at end of file
+cp -R "${BASEDIR}/flutter/flutter_platform_interface" "$PACKAGES_DIR"
\ No newline at end of file
diff --git a/tools/release/ios.lts.sh b/tools/release/ios.lts.sh
index e1a78a8..c5ad8de 100755
--- a/tools/release/ios.lts.sh
+++ b/tools/release/ios.lts.sh
@@ -6,8 +6,6 @@
source ./common.sh
export SOURCE_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-framework-ios-lts"
export COCOAPODS_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-cocoapods-ios-lts"
-export SOURCE_UNIVERSAL_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-universal-ios-lts"
-export ALL_UNIVERSAL_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-all-universal-ios-lts"
create_package() {
local PACKAGE_NAME="ffmpeg-kit-ios-$1"
@@ -18,9 +16,9 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-ios-framework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-ios-framework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
@@ -28,31 +26,6 @@ create_package() {
sed -i '' "s/DESCRIPTION/${PACKAGE_DESCRIPTION}/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/\,\'AVFoundation\'//g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/\,\'VideoToolbox\'//g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
-
- mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- local CURRENT_UNIVERSAL_PACKAGE="${ALL_UNIVERSAL_DIRECTORY}/${PACKAGE_NAME}-universal"
- rm -rf "${CURRENT_UNIVERSAL_PACKAGE}"
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/lib || exit 1
-
- cd "${SOURCE_UNIVERSAL_PACKAGE}" || exit 1
- find . -name "*.a" -exec cp {} "${CURRENT_UNIVERSAL_PACKAGE}"/lib \; || exit 1
-
- # COPY THE LICENSE FILE OF EACH LIBRARY
- LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-
- for LICENSE_FILE in ${LICENSE_FILES[@]}
- do
- LIBRARY_NAME=$(echo "${LICENSE_FILE}" | sed 's/\.\///g;s/\/LICENSE//g')
- cp "${LICENSE_FILE}" "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE."${LIBRARY_NAME}" || exit 1
- done
-
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg-kit/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/LICENSE "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE || exit 1
-
- cd "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- zip -r "ffmpeg-kit-$1-${PACKAGE_VERSION}-ios-static-universal.zip" "${PACKAGE_NAME}"-universal || exit 1
}
if [[ $# -ne 1 ]];
@@ -77,9 +50,6 @@ fi
rm -rf "${COCOAPODS_DIRECTORY}"
mkdir -p "${COCOAPODS_DIRECTORY}" || exit 1
-rm -rf "${ALL_UNIVERSAL_DIRECTORY}"
-mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
-
# MIN RELEASE
cd "${BASEDIR}/../.." || exit 1
./ios.sh ${IOS_LTS_OPTIONS} || exit 1
diff --git a/tools/release/ios.sh b/tools/release/ios.sh
index e4954a0..74db917 100755
--- a/tools/release/ios.sh
+++ b/tools/release/ios.sh
@@ -16,9 +16,9 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-ios-xcframework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-ios-xcframework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
@@ -27,7 +27,7 @@ create_package() {
sed -i '' "s/\.framework/\.xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/-framework/-xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/ios\.xcframeworks/ios\.frameworks/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
- sed -i '' "s/9\.3/12\.1/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
+ sed -i '' "s/10/12\.1/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/ffmpegkit\.xcframework\/LICENSE/ffmpegkit\.xcframework\/ios-arm64\/ffmpegkit\.framework\/LICENSE/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
}
diff --git a/tools/release/macos.lts.sh b/tools/release/macos.lts.sh
index 150ec28..0b60ebe 100755
--- a/tools/release/macos.lts.sh
+++ b/tools/release/macos.lts.sh
@@ -6,8 +6,6 @@
source ./common.sh
export SOURCE_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-framework-macos-lts"
export COCOAPODS_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-cocoapods-macos-lts"
-export SOURCE_UNIVERSAL_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-universal-macos-lts"
-export ALL_UNIVERSAL_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-all-universal-macos-lts"
create_package() {
local PACKAGE_NAME="ffmpeg-kit-macos-$1"
@@ -18,40 +16,16 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-macos-framework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-macos-framework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
sed -i '' "s/VERSION/${PACKAGE_VERSION}/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/DESCRIPTION/${PACKAGE_DESCRIPTION}/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
+ sed -i '' "s|ffmpegkit\.framework\/LICENSE|ffmpegkit\.framework\/Resources\/LICENSE|g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/\,\'AVFoundation\'//g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
-
- mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- local CURRENT_UNIVERSAL_PACKAGE="${ALL_UNIVERSAL_DIRECTORY}/${PACKAGE_NAME}-universal"
- rm -rf "${CURRENT_UNIVERSAL_PACKAGE}"
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/lib || exit 1
-
- cd "${SOURCE_UNIVERSAL_PACKAGE}" || exit 1
- find . -name "*.a" -exec cp {} "${CURRENT_UNIVERSAL_PACKAGE}"/lib \; || exit 1
-
- # COPY THE LICENSE FILE OF EACH LIBRARY
- LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-
- for LICENSE_FILE in ${LICENSE_FILES[@]}
- do
- LIBRARY_NAME=$(echo "${LICENSE_FILE}" | sed 's/\.\///g;s/\/LICENSE//g')
- cp "${LICENSE_FILE}" "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE."${LIBRARY_NAME}" || exit 1
- done
-
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg-kit/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/LICENSE "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE || exit 1
-
- cd "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- zip -r "ffmpeg-kit-$1-${PACKAGE_VERSION}-macos-static-universal.zip" "${PACKAGE_NAME}"-universal || exit 1
}
if [[ $# -ne 1 ]];
@@ -76,9 +50,6 @@ fi
rm -rf "${COCOAPODS_DIRECTORY}"
mkdir -p "${COCOAPODS_DIRECTORY}" || exit 1
-rm -rf "${ALL_UNIVERSAL_DIRECTORY}"
-mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
-
# MIN RELEASE
cd "${BASEDIR}/../.." || exit 1
./macos.sh ${MACOS_LTS_OPTIONS} || exit 1
diff --git a/tools/release/macos.sh b/tools/release/macos.sh
index 1df773d..036266c 100755
--- a/tools/release/macos.sh
+++ b/tools/release/macos.sh
@@ -16,9 +16,9 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-macos-xcframework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-macos-xcframework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
@@ -27,7 +27,7 @@ create_package() {
sed -i '' "s/\.framework/\.xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/-framework/-xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/osx\.xcframeworks/osx\.frameworks/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
- sed -i '' "s/10\.11/10\.15/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
+ sed -i '' "s/10\.12/10\.15/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/ffmpegkit\.xcframework\/LICENSE/ffmpegkit\.xcframework\/macos-arm64_x86_64\/ffmpegkit\.framework\/LICENSE/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
}
diff --git a/tools/release/tvos.lts.sh b/tools/release/tvos.lts.sh
index a71f472..c386f29 100755
--- a/tools/release/tvos.lts.sh
+++ b/tools/release/tvos.lts.sh
@@ -6,8 +6,6 @@
source ./common.sh
export SOURCE_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-framework-tvos-lts"
export COCOAPODS_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-cocoapods-tvos-lts"
-export SOURCE_UNIVERSAL_PACKAGE="${BASEDIR}/../../prebuilt/bundle-apple-universal-tvos-lts"
-export ALL_UNIVERSAL_DIRECTORY="${BASEDIR}/../../prebuilt/bundle-apple-all-universal-tvos-lts"
create_package() {
local PACKAGE_NAME="ffmpeg-kit-tvos-$1"
@@ -18,40 +16,15 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-tvos-framework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-tvos-framework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
sed -i '' "s/VERSION/${PACKAGE_VERSION}/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/DESCRIPTION/${PACKAGE_DESCRIPTION}/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/\,\'VideoToolbox\'//g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
-
- mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- local CURRENT_UNIVERSAL_PACKAGE="${ALL_UNIVERSAL_DIRECTORY}/${PACKAGE_NAME}-universal"
- rm -rf "${CURRENT_UNIVERSAL_PACKAGE}"
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- mkdir -p "${CURRENT_UNIVERSAL_PACKAGE}"/lib || exit 1
-
- cd "${SOURCE_UNIVERSAL_PACKAGE}" || exit 1
- find . -name "*.a" -exec cp {} "${CURRENT_UNIVERSAL_PACKAGE}"/lib \; || exit 1
-
- # COPY LICENSE FILE OF EACH LIBRARY
- LICENSE_FILES=$(find . -name LICENSE | grep -vi ffmpeg)
-
- for LICENSE_FILE in ${LICENSE_FILES[@]}
- do
- LIBRARY_NAME=$(echo "${LICENSE_FILE}" | sed 's/\.\///g;s/\/LICENSE//g')
- cp "${LICENSE_FILE}" "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE."${LIBRARY_NAME}" || exit 1
- done
-
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg-kit/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp -r "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/include/* "${CURRENT_UNIVERSAL_PACKAGE}"/include || exit 1
- cp "${SOURCE_UNIVERSAL_PACKAGE}"/ffmpeg/LICENSE "${CURRENT_UNIVERSAL_PACKAGE}"/LICENSE || exit 1
-
- cd "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
- zip -r "ffmpeg-kit-$1-${PACKAGE_VERSION}-tvos-static-universal.zip" "${PACKAGE_NAME}"-universal || exit 1
}
if [[ $# -ne 1 ]];
@@ -76,9 +49,6 @@ fi
rm -rf "${COCOAPODS_DIRECTORY}"
mkdir -p "${COCOAPODS_DIRECTORY}" || exit 1
-rm -rf "${ALL_UNIVERSAL_DIRECTORY}"
-mkdir -p "${ALL_UNIVERSAL_DIRECTORY}" || exit 1
-
# MIN RELEASE
cd "${BASEDIR}/../.." || exit 1
./tvos.sh ${TVOS_LTS_OPTIONS} || exit 1
diff --git a/tools/release/tvos.sh b/tools/release/tvos.sh
index 5c35b70..8f635a1 100755
--- a/tools/release/tvos.sh
+++ b/tools/release/tvos.sh
@@ -16,9 +16,9 @@ create_package() {
rm -rf "${CURRENT_PACKAGE}"
mkdir -p "${CURRENT_PACKAGE}" || exit 1
- cp -r "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
+ cp -R "${SOURCE_PACKAGE}"/* "${CURRENT_PACKAGE}" || exit 1
cd "${CURRENT_PACKAGE}" || exit 1
- zip -r "../ffmpeg-kit-$1-${PACKAGE_VERSION}-tvos-xcframework.zip" * || exit 1
+ zip -r -y "../ffmpeg-kit-$1-${PACKAGE_VERSION}-tvos-xcframework.zip" * || exit 1
# COPY PODSPEC AS THE LAST ITEM
cp "${BASEDIR}"/apple/"${PACKAGE_NAME}".podspec "${CURRENT_PACKAGE}" || exit 1
@@ -27,7 +27,7 @@ create_package() {
sed -i '' "s/\.framework/\.xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/-framework/-xcframework/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/tvos\.xcframeworks/tvos\.frameworks/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
- sed -i '' "s/9\.2/10\.2/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
+ sed -i '' "s/10\.0/11\.0/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
sed -i '' "s/ffmpegkit\.xcframework\/LICENSE/ffmpegkit\.xcframework\/tvos-arm64\/ffmpegkit\.framework\/LICENSE/g" "${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec || exit 1
}
diff --git a/tvos.sh b/tvos.sh
index 51e9a91..aefecde 100755
--- a/tvos.sh
+++ b/tvos.sh
@@ -16,10 +16,10 @@ export BASEDIR="$(pwd)"
export FFMPEG_KIT_BUILD_TYPE="tvos"
source "${BASEDIR}"/scripts/variable.sh
source "${BASEDIR}"/scripts/function-${FFMPEG_KIT_BUILD_TYPE}.sh
+disabled_libraries=()
# SET DEFAULTS SETTINGS
enable_default_tvos_architectures
-enable_main_build
# SELECT XCODE VERSION USED FOR BUILDING
XCODE_FOR_FFMPEG_KIT=$(ls ~/.xcode.for.ffmpeg.kit.sh 2>>"${BASEDIR}"/build.log)
@@ -28,7 +28,7 @@ if [[ -f ${XCODE_FOR_FFMPEG_KIT} ]]; then
fi
# DETECT TVOS SDK VERSION
-DETECTED_TVOS_SDK_VERSION="$(xcrun --sdk appletvos --show-sdk-version 2>>${BASEDIR}/build.log)"
+export DETECTED_TVOS_SDK_VERSION="$(xcrun --sdk appletvos --show-sdk-version 2>>${BASEDIR}/build.log)"
echo -e "\nINFO: Using SDK ${DETECTED_TVOS_SDK_VERSION} by Xcode provided at $(xcode-select -p)\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "\nINFO: Build options: $*\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -45,6 +45,9 @@ if [[ -z ${BUILD_VERSION} ]]; then
exit 1
fi
+# MAIN BUILDS ENABLED BY DEFAULT
+enable_main_build
+
# PROCESS LTS BUILD OPTION FIRST AND SET BUILD TYPE: MAIN OR LTS
for argument in "$@"; do
if [[ "$argument" == "-l" ]] || [[ "$argument" == "--lts" ]]; then
@@ -113,11 +116,24 @@ while [ ! $# -eq 0 ]; do
--enable-gpl)
GPL_ENABLED="yes"
;;
+ --enable-custom-library-*)
+ CUSTOM_LIBRARY_OPTION_KEY=$(echo $1 | sed -e 's/^--enable-custom-//g;s/=.*$//g')
+ CUSTOM_LIBRARY_OPTION_VALUE=$(echo $1 | sed -e 's/^--enable-custom-.*=//g')
+
+ echo -e "INFO: Custom library options detected: ${CUSTOM_LIBRARY_OPTION_KEY} ${CUSTOM_LIBRARY_OPTION_VALUE}\n" 1>>"${BASEDIR}"/build.log 2>&1
+
+ generate_custom_library_environment_variables "${CUSTOM_LIBRARY_OPTION_KEY}" "${CUSTOM_LIBRARY_OPTION_VALUE}"
+ ;;
--enable-*)
ENABLED_LIBRARY=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
enable_library "${ENABLED_LIBRARY}"
;;
+ --disable-lib-*)
+ DISABLED_LIB=$(echo $1 | sed -e 's/^--[A-Za-z]*-[A-Za-z]*-//g')
+
+ disabled_libraries+=("${DISABLED_LIB}")
+ ;;
--disable-*)
DISABLED_ARCH=$(echo $1 | sed -e 's/^--[A-Za-z]*-//g')
@@ -137,7 +153,7 @@ done
# PROCESS FULL OPTION AS LAST OPTION
if [[ -n ${BUILD_FULL} ]]; then
- for library in {0..58}; do
+ for library in {0..61}; do
if [ ${GPL_ENABLED} == "yes" ]; then
enable_library "$(get_library_name "$library")" 1
else
@@ -148,6 +164,11 @@ if [[ -n ${BUILD_FULL} ]]; then
done
fi
+# DISABLE SPECIFIED LIBRARIES
+for disabled_library in ${disabled_libraries[@]}; do
+ set_library "${disabled_library}" 0
+done
+
# IF HELP DISPLAYED EXIT
if [[ -n ${DISPLAY_HELP} ]]; then
display_help
@@ -155,17 +176,20 @@ if [[ -n ${DISPLAY_HELP} ]]; then
fi
# DISABLE NOT SUPPORTED ARCHITECTURES
-disable_tvos_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_SIMULATOR}" "${DETECTED_TVOS_SDK_VERSION}"
+disable_tvos_architecture_not_supported_on_detected_sdk_version "${ARCH_ARM64_SIMULATOR}"
+
+# DISABLE NOT SUPPORTED LIBRARIES
+disable_tvos_videotoolbox_on_not_supported_sdk_version
# CHECK SOME RULES FOR .framework BUNDLES
# 1. DISABLE arm64-simulator WHEN arm64 IS ENABLED IN framework BUNDLES
-if [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_SIMULATOR}]} -eq 1 ]]; then
- echo -e "INFO: Disabled arm64-simulator architecture which can not co-exist with arm64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
+if [[ ${NO_FRAMEWORK} -ne 1 ]] && [[ -z ${FFMPEG_KIT_XCF_BUILD} ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64}]} -eq 1 ]] && [[ ${ENABLED_ARCHITECTURES[${ARCH_ARM64_SIMULATOR}]} -eq 1 ]]; then
+ echo -e "INFO: Disabled arm64-simulator architecture which cannot co-exist with arm64 in the same framework bundle.\n" 1>>"${BASEDIR}"/build.log 2>&1
disable_arch "arm64-simulator"
fi
-echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}static library for tvOS\n"
+echo -e "\nBuilding ffmpeg-kit ${BUILD_TYPE_ID}shared library for tvOS\n"
echo -e -n "INFO: Building ffmpeg-kit ${BUILD_VERSION} ${BUILD_TYPE_ID}for tvOS: " 1>>"${BASEDIR}"/build.log 2>&1
echo -e "$(date)\n" 1>>"${BASEDIR}"/build.log 2>&1
@@ -175,6 +199,7 @@ print_enabled_libraries
print_reconfigure_requested_libraries
print_rebuild_requested_libraries
print_redownload_requested_libraries
+print_custom_libraries
# VALIDATE GPL FLAGS
for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVIDSTAB,$LIBRARY_RUBBERBAND}; do
@@ -190,13 +215,13 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
done
echo -n -e "\nDownloading sources: "
-echo -e "INFO: Downloading source code of ffmpeg and enabled external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
+echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
# DOWNLOAD GNU CONFIG
download_gnu_config
# DOWNLOAD LIBRARY SOURCES
-downloaded_enabled_library_sources "${ENABLED_LIBRARIES[@]}"
+downloaded_library_sources "${ENABLED_LIBRARIES[@]}"
# THIS WILL SAVE ARCHITECTURES TO BUILD
TARGET_ARCH_LIST=()
@@ -215,7 +240,7 @@ for run_arch in {0..12}; do
TARGET_ARCH_LIST+=("${FULL_ARCH}")
# CLEAR FLAGS
- for library in {0..58}; do
+ for library in {0..61}; do
library_name=$(get_library_name "${library}")
unset "$(echo "OK_${library_name}" | sed "s/\-/\_/g")"
unset "$(echo "DEPENDENCY_REBUILT_${library_name}" | sed "s/\-/\_/g")"